Release of 2015-11-08 :
Modification and addition: into "Axis 1/2" ans "Axis 2:2" TAB : In "Enlarge" Extension of the Line in percentage of original length of the Line. If the extension is 50% it means that each side is extended with 25% length. Positive values will enlarge the Axis. Negative values will start to shrink it. In "Two Points Axis", "Cylinder(s) Axis", "Planes(s) Axes", "Face Normal" and "Axis=(Axis,Point)" Extension values can be: Positive values will enlarge the Axis toward OUTSIDE of the Face Object; Negative values will enlarge the Axis toward INSIDE of the Face Object.
This commit is contained in:
parent
751bff1ddc
commit
c2bb2bca6d
Binary file not shown.
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
# Form implementation generated from reading ui file 'WFGui_2015.ui'
|
# Form implementation generated from reading ui file 'WFGui_2015.ui'
|
||||||
#
|
#
|
||||||
# Created: Wed Nov 4 07:10:00 2015
|
# Created: Sat Nov 7 20:09:36 2015
|
||||||
# by: PySide UI code generator 4.11.2
|
# by: PySide UI code generator 4.11.2
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
|
@ -2321,7 +2321,7 @@ class Ui_Form(object):
|
||||||
self.gridLayout_34.addLayout(self.horizontalLayout_43, 1, 0, 1, 1)
|
self.gridLayout_34.addLayout(self.horizontalLayout_43, 1, 0, 1, 1)
|
||||||
|
|
||||||
self.retranslateUi(Form)
|
self.retranslateUi(Form)
|
||||||
self.tabWidget_7.setCurrentIndex(0)
|
self.tabWidget_7.setCurrentIndex(4)
|
||||||
self.point_loc_comboBox.setCurrentIndex(1)
|
self.point_loc_comboBox.setCurrentIndex(1)
|
||||||
self.tabWidget_8.setCurrentIndex(0)
|
self.tabWidget_8.setCurrentIndex(0)
|
||||||
self.transition_comboBox.setCurrentIndex(2)
|
self.transition_comboBox.setCurrentIndex(2)
|
||||||
|
@ -2475,7 +2475,9 @@ class Ui_Form(object):
|
||||||
self.button_object_axis.setText(_translate("Form", "Object(s) X, Y, Z Axes", None))
|
self.button_object_axis.setText(_translate("Form", "Object(s) X, Y, Z Axes", None))
|
||||||
self.button_twopoints_axis.setToolTip(_translate("Form", "Create an Axis crossing 2 Points.", None))
|
self.button_twopoints_axis.setToolTip(_translate("Form", "Create an Axis crossing 2 Points.", None))
|
||||||
self.button_twopoints_axis.setText(_translate("Form", "Two Points Axis", None))
|
self.button_twopoints_axis.setText(_translate("Form", "Two Points Axis", None))
|
||||||
self.extension_twopoints_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema", None))
|
self.extension_twopoints_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it (then reverse when middle reached). ", None))
|
||||||
self.extension_twopoints_axis.setText(_translate("Form", "0.0", None))
|
self.extension_twopoints_axis.setText(_translate("Form", "0.0", None))
|
||||||
self.button_Npoints_axis.setToolTip(_translate("Form", "Axis=(Points):\n"
|
self.button_Npoints_axis.setToolTip(_translate("Form", "Axis=(Points):\n"
|
||||||
"Create a \"best fit\" line from a set of points using Singular Value Decomposition..\n"
|
"Create a \"best fit\" line from a set of points using Singular Value Decomposition..\n"
|
||||||
|
@ -2515,8 +2517,12 @@ class Ui_Form(object):
|
||||||
"(These selections can also be done into the Combined View)", None))
|
"(These selections can also be done into the Combined View)", None))
|
||||||
self.button_face_normal.setText(_translate("Form", "Face Normal", None))
|
self.button_face_normal.setText(_translate("Form", "Face Normal", None))
|
||||||
self.extension_face_normal.setToolTip(_translate("Form", "Length of external part of the (Normal) Axis.\n"
|
self.extension_face_normal.setToolTip(_translate("Form", "Length of external part of the (Normal) Axis.\n"
|
||||||
" If zero In case of cylinder axis the extension will be a percentage of the object length.\n"
|
" If zero In case of cylinder axis the extension will be a percentage (10%) of the object length.\n"
|
||||||
" If zero and plane of face Normal, the extension will be 10 units.", None))
|
" If zero and plane of face Normal, the extension will be 10 units.\n"
|
||||||
|
"\n"
|
||||||
|
"For \"Cylinder Axis\", \"Planes Axes\" and \"Face Normal\"\n"
|
||||||
|
" Positive values will enlarge the Axis toward OUTSIDE of the Face Object;\n"
|
||||||
|
" Negative values will enlarge the Axis toward INSIDE of the Face Object.", None))
|
||||||
self.extension_face_normal.setText(_translate("Form", "0.0", None))
|
self.extension_face_normal.setText(_translate("Form", "0.0", None))
|
||||||
self.button_point_line_axis.setToolTip(_translate("Form", "Create an Axis Parallel to an Axis (as Direction) and crossing a Point.\n"
|
self.button_point_line_axis.setToolTip(_translate("Form", "Create an Axis Parallel to an Axis (as Direction) and crossing a Point.\n"
|
||||||
"- Select one Axis and one (or several) Point(s) NOT on the previous Axis.\n"
|
"- Select one Axis and one (or several) Point(s) NOT on the previous Axis.\n"
|
||||||
|
@ -2536,7 +2542,9 @@ class Ui_Form(object):
|
||||||
self.button_line_point_axis.setToolTip(_translate("Form", "Create an Axis Perpendicular to an Axis and crossing a Point\n"
|
self.button_line_point_axis.setToolTip(_translate("Form", "Create an Axis Perpendicular to an Axis and crossing a Point\n"
|
||||||
"-Select one Axis and one (or several) Point(s) NOT on the previous Axis.", None))
|
"-Select one Axis and one (or several) Point(s) NOT on the previous Axis.", None))
|
||||||
self.button_line_point_axis.setText(_translate("Form", "Axis=(Axis,Point)", None))
|
self.button_line_point_axis.setText(_translate("Form", "Axis=(Axis,Point)", None))
|
||||||
self.extension_line_point_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.", None))
|
self.extension_line_point_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it (then reverse when middle reached). ", None))
|
||||||
self.extension_line_point_axis.setText(_translate("Form", "0.0", None))
|
self.extension_line_point_axis.setText(_translate("Form", "0.0", None))
|
||||||
self.button_twolines_axis.setToolTip(_translate("Form", "Create an Axis between two Axes.\n"
|
self.button_twolines_axis.setToolTip(_translate("Form", "Create an Axis between two Axes.\n"
|
||||||
"-Select two Axes.", None))
|
"-Select two Axes.", None))
|
||||||
|
@ -2631,7 +2639,11 @@ class Ui_Form(object):
|
||||||
"NB: \n"
|
"NB: \n"
|
||||||
" - The percentage of the extension can be defined first.", None))
|
" - The percentage of the extension can be defined first.", None))
|
||||||
self.button_extension_axis.setText(_translate("Form", "Enlarge(Axis)", None))
|
self.button_extension_axis.setText(_translate("Form", "Enlarge(Axis)", None))
|
||||||
self.extension_axis.setToolTip(_translate("Form", "Extension of the Line in percentage.", None))
|
self.extension_axis.setToolTip(_translate("Form", "Extension of the Line in percentage of original length of the Line.\n"
|
||||||
|
"If the extension is 50% it means that each side is extended with 25% length.\n"
|
||||||
|
"\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it. ", None))
|
||||||
self.extension_axis.setText(_translate("Form", "50.0", None))
|
self.extension_axis.setText(_translate("Form", "50.0", None))
|
||||||
self.button_click_for_axis.setToolTip(_translate("Form", "Create a set of Lines on a Plane perpendicular to the view at location of 2 mouse clicks.\n"
|
self.button_click_for_axis.setToolTip(_translate("Form", "Create a set of Lines on a Plane perpendicular to the view at location of 2 mouse clicks.\n"
|
||||||
"- Click first on the Button then at least twice click on the View (with no object in background).\n"
|
"- Click first on the Button then at least twice click on the View (with no object in background).\n"
|
||||||
|
|
|
@ -57,7 +57,7 @@
|
||||||
<enum>QTabWidget::West</enum>
|
<enum>QTabWidget::West</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>0</number>
|
<number>4</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="Origin_Tab_2">
|
<widget class="QWidget" name="Origin_Tab_2">
|
||||||
<attribute name="icon">
|
<attribute name="icon">
|
||||||
|
@ -921,7 +921,9 @@ Then click on this button.</string>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Distance for the extensions on extrema</string>
|
<string>Distance for the extensions on extrema.
|
||||||
|
Positive values will enlarge the Axis.
|
||||||
|
Negative values will start to shrink it (then reverse when middle reached). </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>0.0</string>
|
<string>0.0</string>
|
||||||
|
@ -1106,8 +1108,12 @@ To create several Normal of the face:
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Length of external part of the (Normal) Axis.
|
<string>Length of external part of the (Normal) Axis.
|
||||||
If zero In case of cylinder axis the extension will be a percentage of the object length.
|
If zero In case of cylinder axis the extension will be a percentage (10%) of the object length.
|
||||||
If zero and plane of face Normal, the extension will be 10 units.</string>
|
If zero and plane of face Normal, the extension will be 10 units.
|
||||||
|
|
||||||
|
For "Cylinder Axis", "Planes Axes" and "Face Normal"
|
||||||
|
Positive values will enlarge the Axis toward OUTSIDE of the Face Object;
|
||||||
|
Negative values will enlarge the Axis toward INSIDE of the Face Object.</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>0.0</string>
|
<string>0.0</string>
|
||||||
|
@ -1253,7 +1259,9 @@ End of the Axis.</string>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Distance for the extensions on extrema.</string>
|
<string>Distance for the extensions on extrema.
|
||||||
|
Positive values will enlarge the Axis.
|
||||||
|
Negative values will start to shrink it (then reverse when middle reached). </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>0.0</string>
|
<string>0.0</string>
|
||||||
|
@ -1775,7 +1783,11 @@ NB:
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Extension of the Line in percentage.</string>
|
<string>Extension of the Line in percentage of original length of the Line.
|
||||||
|
If the extension is 50% it means that each side is extended with 25% length.
|
||||||
|
|
||||||
|
Positive values will enlarge the Axis.
|
||||||
|
Negative values will start to shrink it. </string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>50.0</string>
|
<string>50.0</string>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
# Form implementation generated from reading ui file 'WFGui_2015.ui'
|
# Form implementation generated from reading ui file 'WFGui_2015.ui'
|
||||||
#
|
#
|
||||||
# Created: Wed Nov 4 07:10:00 2015
|
# Created: Sat Nov 7 20:09:36 2015
|
||||||
# by: PySide UI code generator 4.11.2
|
# by: PySide UI code generator 4.11.2
|
||||||
#
|
#
|
||||||
# WARNING! All changes made in this file will be lost!
|
# WARNING! All changes made in this file will be lost!
|
||||||
|
@ -2321,7 +2321,7 @@ class Ui_Form(object):
|
||||||
self.gridLayout_34.addLayout(self.horizontalLayout_43, 1, 0, 1, 1)
|
self.gridLayout_34.addLayout(self.horizontalLayout_43, 1, 0, 1, 1)
|
||||||
|
|
||||||
self.retranslateUi(Form)
|
self.retranslateUi(Form)
|
||||||
self.tabWidget_7.setCurrentIndex(0)
|
self.tabWidget_7.setCurrentIndex(4)
|
||||||
self.point_loc_comboBox.setCurrentIndex(1)
|
self.point_loc_comboBox.setCurrentIndex(1)
|
||||||
self.tabWidget_8.setCurrentIndex(0)
|
self.tabWidget_8.setCurrentIndex(0)
|
||||||
self.transition_comboBox.setCurrentIndex(2)
|
self.transition_comboBox.setCurrentIndex(2)
|
||||||
|
@ -2475,7 +2475,9 @@ class Ui_Form(object):
|
||||||
self.button_object_axis.setText(_translate("Form", "Object(s) X, Y, Z Axes", None))
|
self.button_object_axis.setText(_translate("Form", "Object(s) X, Y, Z Axes", None))
|
||||||
self.button_twopoints_axis.setToolTip(_translate("Form", "Create an Axis crossing 2 Points.", None))
|
self.button_twopoints_axis.setToolTip(_translate("Form", "Create an Axis crossing 2 Points.", None))
|
||||||
self.button_twopoints_axis.setText(_translate("Form", "Two Points Axis", None))
|
self.button_twopoints_axis.setText(_translate("Form", "Two Points Axis", None))
|
||||||
self.extension_twopoints_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema", None))
|
self.extension_twopoints_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it (then reverse when middle reached). ", None))
|
||||||
self.extension_twopoints_axis.setText(_translate("Form", "0.0", None))
|
self.extension_twopoints_axis.setText(_translate("Form", "0.0", None))
|
||||||
self.button_Npoints_axis.setToolTip(_translate("Form", "Axis=(Points):\n"
|
self.button_Npoints_axis.setToolTip(_translate("Form", "Axis=(Points):\n"
|
||||||
"Create a \"best fit\" line from a set of points using Singular Value Decomposition..\n"
|
"Create a \"best fit\" line from a set of points using Singular Value Decomposition..\n"
|
||||||
|
@ -2515,8 +2517,12 @@ class Ui_Form(object):
|
||||||
"(These selections can also be done into the Combined View)", None))
|
"(These selections can also be done into the Combined View)", None))
|
||||||
self.button_face_normal.setText(_translate("Form", "Face Normal", None))
|
self.button_face_normal.setText(_translate("Form", "Face Normal", None))
|
||||||
self.extension_face_normal.setToolTip(_translate("Form", "Length of external part of the (Normal) Axis.\n"
|
self.extension_face_normal.setToolTip(_translate("Form", "Length of external part of the (Normal) Axis.\n"
|
||||||
" If zero In case of cylinder axis the extension will be a percentage of the object length.\n"
|
" If zero In case of cylinder axis the extension will be a percentage (10%) of the object length.\n"
|
||||||
" If zero and plane of face Normal, the extension will be 10 units.", None))
|
" If zero and plane of face Normal, the extension will be 10 units.\n"
|
||||||
|
"\n"
|
||||||
|
"For \"Cylinder Axis\", \"Planes Axes\" and \"Face Normal\"\n"
|
||||||
|
" Positive values will enlarge the Axis toward OUTSIDE of the Face Object;\n"
|
||||||
|
" Negative values will enlarge the Axis toward INSIDE of the Face Object.", None))
|
||||||
self.extension_face_normal.setText(_translate("Form", "0.0", None))
|
self.extension_face_normal.setText(_translate("Form", "0.0", None))
|
||||||
self.button_point_line_axis.setToolTip(_translate("Form", "Create an Axis Parallel to an Axis (as Direction) and crossing a Point.\n"
|
self.button_point_line_axis.setToolTip(_translate("Form", "Create an Axis Parallel to an Axis (as Direction) and crossing a Point.\n"
|
||||||
"- Select one Axis and one (or several) Point(s) NOT on the previous Axis.\n"
|
"- Select one Axis and one (or several) Point(s) NOT on the previous Axis.\n"
|
||||||
|
@ -2536,7 +2542,9 @@ class Ui_Form(object):
|
||||||
self.button_line_point_axis.setToolTip(_translate("Form", "Create an Axis Perpendicular to an Axis and crossing a Point\n"
|
self.button_line_point_axis.setToolTip(_translate("Form", "Create an Axis Perpendicular to an Axis and crossing a Point\n"
|
||||||
"-Select one Axis and one (or several) Point(s) NOT on the previous Axis.", None))
|
"-Select one Axis and one (or several) Point(s) NOT on the previous Axis.", None))
|
||||||
self.button_line_point_axis.setText(_translate("Form", "Axis=(Axis,Point)", None))
|
self.button_line_point_axis.setText(_translate("Form", "Axis=(Axis,Point)", None))
|
||||||
self.extension_line_point_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.", None))
|
self.extension_line_point_axis.setToolTip(_translate("Form", "Distance for the extensions on extrema.\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it (then reverse when middle reached). ", None))
|
||||||
self.extension_line_point_axis.setText(_translate("Form", "0.0", None))
|
self.extension_line_point_axis.setText(_translate("Form", "0.0", None))
|
||||||
self.button_twolines_axis.setToolTip(_translate("Form", "Create an Axis between two Axes.\n"
|
self.button_twolines_axis.setToolTip(_translate("Form", "Create an Axis between two Axes.\n"
|
||||||
"-Select two Axes.", None))
|
"-Select two Axes.", None))
|
||||||
|
@ -2631,7 +2639,11 @@ class Ui_Form(object):
|
||||||
"NB: \n"
|
"NB: \n"
|
||||||
" - The percentage of the extension can be defined first.", None))
|
" - The percentage of the extension can be defined first.", None))
|
||||||
self.button_extension_axis.setText(_translate("Form", "Enlarge(Axis)", None))
|
self.button_extension_axis.setText(_translate("Form", "Enlarge(Axis)", None))
|
||||||
self.extension_axis.setToolTip(_translate("Form", "Extension of the Line in percentage.", None))
|
self.extension_axis.setToolTip(_translate("Form", "Extension of the Line in percentage of original length of the Line.\n"
|
||||||
|
"If the extension is 50% it means that each side is extended with 25% length.\n"
|
||||||
|
"\n"
|
||||||
|
"Positive values will enlarge the Axis.\n"
|
||||||
|
"Negative values will start to shrink it. ", None))
|
||||||
self.extension_axis.setText(_translate("Form", "50.0", None))
|
self.extension_axis.setText(_translate("Form", "50.0", None))
|
||||||
self.button_click_for_axis.setToolTip(_translate("Form", "Create a set of Lines on a Plane perpendicular to the view at location of 2 mouse clicks.\n"
|
self.button_click_for_axis.setToolTip(_translate("Form", "Create a set of Lines on a Plane perpendicular to the view at location of 2 mouse clicks.\n"
|
||||||
"- Click first on the Button then at least twice click on the View (with no object in background).\n"
|
"- Click first on the Button then at least twice click on the View (with no object in background).\n"
|
||||||
|
|
|
@ -64,7 +64,7 @@ from WF_Utils_2015 import *
|
||||||
from WF_ObjParCurve_2015 import *
|
from WF_ObjParCurve_2015 import *
|
||||||
|
|
||||||
global myRelease
|
global myRelease
|
||||||
myRelease = "2015_10_20"
|
myRelease = "2015_11_08"
|
||||||
|
|
||||||
import os.path
|
import os.path
|
||||||
import time
|
import time
|
||||||
|
@ -3450,7 +3450,9 @@ def plot_2PointsAxis():
|
||||||
Axis_E2 = Axis_A - Axis_dir.normalize().multiply(m_extensionTwoPointsAxis)
|
Axis_E2 = Axis_A - Axis_dir.normalize().multiply(m_extensionTwoPointsAxis)
|
||||||
else:
|
else:
|
||||||
Axis_E2 = Axis_A + Axis_dir.normalize().multiply(m_extensionTwoPointsAxis)
|
Axis_E2 = Axis_A + Axis_dir.normalize().multiply(m_extensionTwoPointsAxis)
|
||||||
|
if Axis_E1 == Axis_E2:
|
||||||
|
Axis_E1 = Axis_E1 + Axis_dir.multiply(0.1)
|
||||||
|
Axis_E2 = Axis_E2 - Axis_dir.multiply(0.9)
|
||||||
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
||||||
|
|
||||||
print_msg(str(Axis_User_Name) + result_msg )
|
print_msg(str(Axis_User_Name) + result_msg )
|
||||||
|
@ -3605,13 +3607,20 @@ def plot_cylinderAxis():
|
||||||
if m_extensionFaceNormal != 0.0:
|
if m_extensionFaceNormal != 0.0:
|
||||||
Axis_dir_norm = Axis_B - Axis_A
|
Axis_dir_norm = Axis_B - Axis_A
|
||||||
Axis_dir_norm = Axis_dir_norm.normalize()
|
Axis_dir_norm = Axis_dir_norm.normalize()
|
||||||
Axis_dir_norm = Axis_dir_norm.multiply(m_extensionFaceNormal)
|
Axis_dir_norm = Axis_dir_norm.multiply(abs(m_extensionFaceNormal))
|
||||||
|
if m_extensionFaceNormal > 0.0:
|
||||||
Axis_E1 = Axis_B + Axis_dir_norm
|
Axis_E1 = Axis_B + Axis_dir_norm
|
||||||
Axis_E2 = Axis_A - Axis_dir_norm
|
Axis_E2 = Axis_A - Axis_dir_norm
|
||||||
|
else :
|
||||||
|
Axis_E1 = Axis_B - Axis_dir_norm
|
||||||
|
Axis_E2 = Axis_A + Axis_dir_norm
|
||||||
else:
|
else:
|
||||||
Axis_E1 = Axis_B + Axis_dir.multiply(0.1)
|
Axis_E1 = Axis_B + Axis_dir.multiply(0.1)
|
||||||
Axis_E2 = Axis_A - Axis_dir.multiply(0.9)
|
Axis_E2 = Axis_A - Axis_dir.multiply(0.9)
|
||||||
|
|
||||||
|
if Axis_E1 == Axis_E2:
|
||||||
|
Axis_E1 = Axis_E1 + Axis_dir.multiply(0.1)
|
||||||
|
Axis_E2 = Axis_E2 - Axis_dir.multiply(0.9)
|
||||||
|
|
||||||
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
||||||
|
|
||||||
|
@ -4087,6 +4096,9 @@ def plot_linePointAxis():
|
||||||
else:
|
else:
|
||||||
Axis_E2 = Vector_T + Axis_dir.normalize().multiply(m_extensionLinePointAxis)
|
Axis_E2 = Vector_T + Axis_dir.normalize().multiply(m_extensionLinePointAxis)
|
||||||
|
|
||||||
|
if Axis_E1 == Axis_E2:
|
||||||
|
Axis_E1 = Axis_E1 + Axis_dir.multiply(0.1)
|
||||||
|
Axis_E2 = Axis_E2 - Axis_dir.multiply(0.9)
|
||||||
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
Axis_User_Name, axis = plot_axis(Axis_E1, Axis_E2, part, name)
|
||||||
|
|
||||||
print_msg(str(Axis_User_Name) + result_msg )
|
print_msg(str(Axis_User_Name) + result_msg )
|
||||||
|
@ -4400,7 +4412,7 @@ def extensionAxis(value):
|
||||||
m_extensionAxis = float(value)
|
m_extensionAxis = float(value)
|
||||||
print_msg("New Axis extension is :" + str(m_extensionAxis))
|
print_msg("New Axis extension is :" + str(m_extensionAxis))
|
||||||
except ValueError:
|
except ValueError:
|
||||||
printError_msg("Axis extension must be valid number 5percentage)!")
|
printError_msg("Axis extension must be valid number percentage)!")
|
||||||
|
|
||||||
|
|
||||||
def plot_extensionAxis():
|
def plot_extensionAxis():
|
||||||
|
@ -4433,11 +4445,15 @@ def plot_extensionAxis():
|
||||||
print_point(Point_A, msg="Selected_Edge.Vertexes[0] Point_A : ")
|
print_point(Point_A, msg="Selected_Edge.Vertexes[0] Point_A : ")
|
||||||
print_point(Point_B, msg="Selected_Edge.Vertexes[-1] Point_B : ")
|
print_point(Point_B, msg="Selected_Edge.Vertexes[-1] Point_B : ")
|
||||||
AB_Vector = Point_B.sub(Point_A)
|
AB_Vector = Point_B.sub(Point_A)
|
||||||
demi_add_length = Selected_Edge.Length * ((m_extensionAxis/50))
|
demi_add_length = Selected_Edge.Length * ((m_extensionAxis/200))
|
||||||
|
print_msg("demi_add_length=" + str(demi_add_length))
|
||||||
add_Vector = AB_Vector.normalize().multiply(demi_add_length)
|
add_Vector = AB_Vector.normalize().multiply(demi_add_length)
|
||||||
Point_A = Point_A.sub(add_Vector)
|
Point_A = Point_A.sub(add_Vector)
|
||||||
Point_B = Point_B.add(add_Vector)
|
Point_B = Point_B.add(add_Vector)
|
||||||
|
|
||||||
|
if Point_A == Point_B:
|
||||||
|
Point_A = Point_A.sub(add_Vector.multiply(0.1))
|
||||||
|
Point_B = Point_B.add(add_Vector.multiply(0.9))
|
||||||
Axis_User_Name, axis = plot_axis(Point_A, Point_B, part, name)
|
Axis_User_Name, axis = plot_axis(Point_A, Point_B, part, name)
|
||||||
|
|
||||||
print_msg(str(Axis_User_Name) + result_msg )
|
print_msg(str(Axis_User_Name) + result_msg )
|
||||||
|
@ -7774,7 +7790,6 @@ def plot_sectionSweep():
|
||||||
|
|
||||||
if msg != 0:
|
if msg != 0:
|
||||||
print_msg("03-Get the list of sections in case of first section is a Compound")
|
print_msg("03-Get the list of sections in case of first section is a Compound")
|
||||||
print_msg(m_msg)
|
|
||||||
print_msg("m_sections = " + str(m_sections))
|
print_msg("m_sections = " + str(m_sections))
|
||||||
|
|
||||||
# Loop on sections
|
# Loop on sections
|
||||||
|
|
Loading…
Reference in New Issue
Block a user