Merge branch 'V7_7_BR' into hydro/imps_2015
@ -30,8 +30,8 @@ CMAKE_POLICY(SET CMP0003 NEW)
|
|||||||
STRING(TOUPPER ${PROJECT_NAME} PROJECT_NAME_UC)
|
STRING(TOUPPER ${PROJECT_NAME} PROJECT_NAME_UC)
|
||||||
|
|
||||||
SET(${PROJECT_NAME_UC}_MAJOR_VERSION 7)
|
SET(${PROJECT_NAME_UC}_MAJOR_VERSION 7)
|
||||||
SET(${PROJECT_NAME_UC}_MINOR_VERSION 6)
|
SET(${PROJECT_NAME_UC}_MINOR_VERSION 7)
|
||||||
SET(${PROJECT_NAME_UC}_PATCH_VERSION 0)
|
SET(${PROJECT_NAME_UC}_PATCH_VERSION 1)
|
||||||
SET(${PROJECT_NAME_UC}_VERSION
|
SET(${PROJECT_NAME_UC}_VERSION
|
||||||
${${PROJECT_NAME_UC}_MAJOR_VERSION}.${${PROJECT_NAME_UC}_MINOR_VERSION}.${${PROJECT_NAME_UC}_PATCH_VERSION})
|
${${PROJECT_NAME_UC}_MAJOR_VERSION}.${${PROJECT_NAME_UC}_MINOR_VERSION}.${${PROJECT_NAME_UC}_PATCH_VERSION})
|
||||||
SET(${PROJECT_NAME_UC}_VERSION_DEV 0)
|
SET(${PROJECT_NAME_UC}_VERSION_DEV 0)
|
||||||
@ -108,7 +108,9 @@ IF(SALOME_BUILD_GUI)
|
|||||||
IF(EXISTS ${GUI_ROOT_DIR})
|
IF(EXISTS ${GUI_ROOT_DIR})
|
||||||
LIST(APPEND CMAKE_MODULE_PATH "${GUI_ROOT_DIR}/adm_local/cmake_files")
|
LIST(APPEND CMAKE_MODULE_PATH "${GUI_ROOT_DIR}/adm_local/cmake_files")
|
||||||
FIND_PACKAGE(SalomeGUI)
|
FIND_PACKAGE(SalomeGUI)
|
||||||
FULL_GUI(TRUE) #check whether GUI builded in full mode and with CORBA
|
SALOME_GUI_WITH_CORBA() #check whether GUI builded with CORBA
|
||||||
|
SALOME_GUI_MODE(SALOME_USE_OCCVIEWER SALOME_USE_VTKVIEWER SALOME_USE_SALOMEOBJECT
|
||||||
|
OPTIONAL SALOME_USE_PLOT2DVIEWER SALOME_USE_GRAPHICSVIEW SALOME_USE_PYCONSOLE)
|
||||||
ADD_DEFINITIONS(${GUI_DEFINITIONS})
|
ADD_DEFINITIONS(${GUI_DEFINITIONS})
|
||||||
INCLUDE_DIRECTORIES(${GUI_INCLUDE_DIRS})
|
INCLUDE_DIRECTORIES(${GUI_INCLUDE_DIRS})
|
||||||
ELSE(EXISTS ${GUI_ROOT_DIR})
|
ELSE(EXISTS ${GUI_ROOT_DIR})
|
||||||
@ -125,12 +127,6 @@ IF(SALOME_BUILD_GUI)
|
|||||||
|
|
||||||
# Qt4
|
# Qt4
|
||||||
FIND_PACKAGE(SalomeQt4 REQUIRED COMPONENTS QtCore QtGui QtXml)
|
FIND_PACKAGE(SalomeQt4 REQUIRED COMPONENTS QtCore QtGui QtXml)
|
||||||
|
|
||||||
# Optional prerequisites for GUI
|
|
||||||
IF(SALOME_USE_GLVIEWER)
|
|
||||||
FIND_PACKAGE(SalomeOpenGL)
|
|
||||||
SALOME_LOG_OPTIONAL_PACKAGE(OpenGL SALOME_USE_GLVIEWER)
|
|
||||||
ENDIF()
|
|
||||||
ENDIF(SALOME_BUILD_GUI)
|
ENDIF(SALOME_BUILD_GUI)
|
||||||
|
|
||||||
##
|
##
|
||||||
@ -231,9 +227,12 @@ IF(SALOME_BUILD_GUI)
|
|||||||
LIST(APPEND _${PROJECT_NAME}_exposed_targets
|
LIST(APPEND _${PROJECT_NAME}_exposed_targets
|
||||||
AdvancedGUI BasicGUI BlocksGUI BooleanGUI BuildGUI DisplayGUI DlgRef CurveCreator EntityGUI GEOMBase
|
AdvancedGUI BasicGUI BlocksGUI BooleanGUI BuildGUI DisplayGUI DlgRef CurveCreator EntityGUI GEOMBase
|
||||||
GEOMFiltersSelection GEOM GEOMToolsGUI GenerationGUI GroupGUI Material MeasureGUI GEOMObject
|
GEOMFiltersSelection GEOM GEOMToolsGUI GenerationGUI GroupGUI Material MeasureGUI GEOMObject
|
||||||
OperationGUI PrimitiveGUI RepairGUI TransformationGUI DependencyTree
|
OperationGUI PrimitiveGUI RepairGUI TransformationGUI
|
||||||
STLPluginGUI BREPPluginGUI STEPPluginGUI IGESPluginGUI XAOPluginGUI VTKPluginGUI
|
STLPluginGUI BREPPluginGUI STEPPluginGUI IGESPluginGUI XAOPluginGUI VTKPluginGUI
|
||||||
)
|
)
|
||||||
|
IF(SALOME_USE_GRAPHICSVIEW)
|
||||||
|
LIST(APPEND _${PROJECT_NAME}_exposed_targets DependencyTree)
|
||||||
|
ENDIF(SALOME_USE_GRAPHICSVIEW)
|
||||||
ENDIF(SALOME_BUILD_GUI)
|
ENDIF(SALOME_BUILD_GUI)
|
||||||
|
|
||||||
IF(SALOME_GEOM_USE_OPENCV)
|
IF(SALOME_GEOM_USE_OPENCV)
|
||||||
|
@ -68,6 +68,7 @@ SET(GOOD_TESTS
|
|||||||
complex_objs_ex09.py
|
complex_objs_ex09.py
|
||||||
complex_objs_ex10.py
|
complex_objs_ex10.py
|
||||||
complex_objs_ex11.py
|
complex_objs_ex11.py
|
||||||
|
fast_intersection.py
|
||||||
free_boundaries.py
|
free_boundaries.py
|
||||||
free_faces.py
|
free_faces.py
|
||||||
GEOM_box.py
|
GEOM_box.py
|
||||||
@ -131,9 +132,9 @@ SET(GOOD_TESTS
|
|||||||
working_with_groups_ex05.py
|
working_with_groups_ex05.py
|
||||||
working_with_groups_ex06.py
|
working_with_groups_ex06.py
|
||||||
)
|
)
|
||||||
IF(CAS_VERSION_STR VERSION_GREATER "6.8.0")
|
IF(CAS_VERSION_STR VERSION_GREATER "6.9.0")
|
||||||
LIST(APPEND GOOD_TESTS
|
LIST(APPEND GOOD_TESTS
|
||||||
fast_intersection.py
|
check_self_intersections_fast.py
|
||||||
)
|
)
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
|
@ -7,9 +7,15 @@ from salome.geom import geomBuilder
|
|||||||
geompy = geomBuilder.New(salome.myStudy)
|
geompy = geomBuilder.New(salome.myStudy)
|
||||||
|
|
||||||
# create a box
|
# create a box
|
||||||
box = geompy.MakeBoxDXDYDZ(100,30,100)
|
box = geompy.MakeBoxDXDYDZ(100,100,100)
|
||||||
IsValid = geompy.CheckSelfIntersections(box)
|
# create a cylinder
|
||||||
if IsValid == 0:
|
cylinder = geompy.MakeCylinderRH(100, 300)
|
||||||
raise RuntimeError, "Box with self-intersections created"
|
# make a compound
|
||||||
|
compound = geompy.MakeCompound([box, cylinder])
|
||||||
|
|
||||||
|
# check self-intersection
|
||||||
|
IsValid = geompy.CheckSelfIntersections(compound)
|
||||||
|
if not IsValid:
|
||||||
|
print "Shape is self-intersected!"
|
||||||
else:
|
else:
|
||||||
print "\nBox is valid"
|
print "No self-intersection detected in a shape"
|
||||||
|
21
doc/salome/examples/check_self_intersections_fast.py
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
# Detect Self-intersections fast
|
||||||
|
|
||||||
|
import salome
|
||||||
|
salome.salome_init()
|
||||||
|
import GEOM
|
||||||
|
from salome.geom import geomBuilder
|
||||||
|
geompy = geomBuilder.New(salome.myStudy)
|
||||||
|
|
||||||
|
# create a box
|
||||||
|
box = geompy.MakeBoxDXDYDZ(100,100,100)
|
||||||
|
# create a cylinder
|
||||||
|
cylinder = geompy.MakeCylinderRH(100, 300)
|
||||||
|
# make a compound
|
||||||
|
compound = geompy.MakeCompound([box, cylinder])
|
||||||
|
|
||||||
|
# check self-intersection
|
||||||
|
IsValid = geompy.CheckSelfIntersectionsFast(compound)
|
||||||
|
if not IsValid:
|
||||||
|
print "Shape is self-intersected!"
|
||||||
|
else:
|
||||||
|
print "No self-intersection detected in a shape"
|
@ -18,18 +18,22 @@ circles.append(geompy.MakeCircle(vertices[1], edges[0], 40))
|
|||||||
circles.append(geompy.MakeCircle(vertices[2], edges[2], 30))
|
circles.append(geompy.MakeCircle(vertices[2], edges[2], 30))
|
||||||
circles.append(geompy.MakeCircle(vertices[3], edges[2], 20))
|
circles.append(geompy.MakeCircle(vertices[3], edges[2], 20))
|
||||||
|
|
||||||
# create pipe
|
# create pipes
|
||||||
Pipe = geompy.MakePipeWithDifferentSections(circles, vertices, Wire_1, 0, 0)
|
Pipe1 = geompy.MakePipeWithDifferentSections(circles, vertices, Wire_1, 0, 0)
|
||||||
|
Pipe2 = geompy.MakePipeWithDifferentSectionsBySteps(circles, vertices, Wire_1)
|
||||||
|
|
||||||
# add objects in the study
|
# add objects in the study
|
||||||
geompy.addToStudy(circles[0], "circles1")
|
geompy.addToStudy(circles[0], "circles1")
|
||||||
geompy.addToStudy(circles[1], "circles2")
|
geompy.addToStudy(circles[1], "circles2")
|
||||||
geompy.addToStudy(circles[2], "circles3")
|
geompy.addToStudy(circles[2], "circles3")
|
||||||
geompy.addToStudy(circles[3], "circles4")
|
geompy.addToStudy(circles[3], "circles4")
|
||||||
id_wire = geompy.addToStudy(Wire_1, "Path")
|
id_wire = geompy.addToStudy(Wire_1, "Path")
|
||||||
id_pipe = geompy.addToStudy(Pipe, "Pipe")
|
id_pipe1 = geompy.addToStudy(Pipe1, "Pipe1")
|
||||||
|
id_pipe2 = geompy.addToStudy(Pipe2, "Pipe2")
|
||||||
|
|
||||||
# display the wire(path) and the pipe
|
# display the wire(path) and the pipe
|
||||||
gg.createAndDisplayGO(id_wire)
|
gg.createAndDisplayGO(id_wire)
|
||||||
gg.createAndDisplayGO(id_pipe)
|
gg.createAndDisplayGO(id_pipe1)
|
||||||
gg.setDisplayMode(id_pipe,1)
|
gg.createAndDisplayGO(id_pipe2)
|
||||||
|
gg.setDisplayMode(id_pipe1,1)
|
||||||
|
gg.setDisplayMode(id_pipe2,1)
|
||||||
|
@ -117,16 +117,22 @@ if __name__ == "__main__":
|
|||||||
if len( args ) < 1: sys.exit("Plugin name is not specified")
|
if len( args ) < 1: sys.exit("Plugin name is not specified")
|
||||||
|
|
||||||
f = open(options.output, "w")
|
f = open(options.output, "w")
|
||||||
|
|
||||||
|
if len(args) > 1:
|
||||||
|
plugins_names = " ".join(args) + " plugins"
|
||||||
|
elif len(args) == 1:
|
||||||
|
plugins_names = args[0] + " plugin"
|
||||||
|
else:
|
||||||
|
plugins_names = ""
|
||||||
output = []
|
output = []
|
||||||
if options.dummygeomhelp:
|
if options.dummygeomhelp:
|
||||||
output.append( "## @package geomBuilder" )
|
output.append( "## @package geomBuilder" )
|
||||||
output.append( "# Documentation of the methods dynamically added by the " + plugin_name + " Geometry plug-in to the geomBuilder class." )
|
output.append( "# Documentation of the methods dynamically added by the " + plugins_names + " to the @b %geomBuilder class." )
|
||||||
# Add dummy Geometry help
|
# Add dummy Geometry help
|
||||||
# This is supposed to be done when generating documentation for Geometry module plug-ins
|
# This is supposed to be done when generating documentation for Geometry module plug-ins
|
||||||
output.append( "# @note The documentation below does not provide complete description of class @b %geomBuilder" )
|
output.append( "# @note The documentation below does not provide complete description of class @b %geomBuilder" )
|
||||||
output.append( "# from @b geomBuilder package. This documentation provides only information about" )
|
output.append( "# from @b geomBuilder package. This documentation provides only information about" )
|
||||||
output.append( "# the methods dynamically added to the %geomBuilder class by the " + plugin_name + " plugin" )
|
output.append( "# the methods dynamically added to the %geomBuilder class by the " + plugins_names + "." )
|
||||||
output.append( "# For more details on the %geomBuilder class, please refer to the SALOME %Geometry module" )
|
output.append( "# For more details on the %geomBuilder class, please refer to the SALOME %Geometry module" )
|
||||||
output.append( "# documentation." )
|
output.append( "# documentation." )
|
||||||
pass
|
pass
|
||||||
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 1.7 MiB |
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 1.2 MiB |
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 35 KiB |
BIN
doc/salome/gui/GEOM/images/measures13.png
Normal file
After Width: | Height: | Size: 36 KiB |
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 30 KiB |
BIN
doc/salome/gui/GEOM/images/point3.png
Executable file → Normal file
Before Width: | Height: | Size: 23 KiB After Width: | Height: | Size: 26 KiB |
BIN
doc/salome/gui/GEOM/images/proj_on_cyl_angles.png
Normal file
After Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 27 KiB |
BIN
doc/salome/gui/GEOM/images/shape_statistics.png
Normal file
After Width: | Height: | Size: 380 KiB |
BIN
doc/salome/gui/GEOM/images/shape_statistics_simple.png
Normal file
After Width: | Height: | Size: 240 KiB |
@ -10,25 +10,24 @@ This operation is available in <b>OCC Viewer</b> only.
|
|||||||
|
|
||||||
The \b Result will be a \b GEOM_Object.
|
The \b Result will be a \b GEOM_Object.
|
||||||
|
|
||||||
\n Location of a new vertex on a selected edge can be defined two ways:
|
\n The location of a new vertex on the selected edge can be defined in two ways:
|
||||||
<ol>
|
<ol>
|
||||||
<li> We can specify a position (ranging from 0.0 to 1.0) of the
|
<li> By specifying the position (ranging from 0.0 to 1.0) by length or by parameter.
|
||||||
vertex on the selected edge either by length or by parameter.
|
|
||||||
<p>
|
<p>
|
||||||
<b>TUI Command:</b> <em>geompy.DivideEdge(Shape, EdgeID, Value,
|
<b>TUI Command:</b> <em>geompy.DivideEdge(Shape, EdgeID, Value,
|
||||||
IsByParameter)</em>
|
IsByParameter)</em>
|
||||||
<ul>
|
<ul>
|
||||||
<li> \em Shape is a shape which contains an edge to be divided</li>
|
<li> \em Shape is a shape, which contains an edge to be divided;</li>
|
||||||
<li>\em EdgeID is the ID of the edge to be divided, if it is = -1,
|
<li>\em EdgeID is the ID of the edge to be divided, if it is = -1,
|
||||||
then \em Shape should be an edge itself.</li>
|
then \em Shape should be an edge itself;</li>
|
||||||
<li> \em Value is a value of parameter on edge or length parameter,
|
<li> \em Value is a value of parameter on edge or length parameter,
|
||||||
depending on \em IsByParameter. </li>
|
depending on \em IsByParameter;</li>
|
||||||
<li> \em IsByParameter is a boolean flag, specifying operation mode:
|
<li> \em IsByParameter is a boolean flag, specifying the operation mode:
|
||||||
- \c True: \em Value is treated as a curve parameter [0..1]
|
- \c True: \em Value is treated as a curve parameter; [0..1]
|
||||||
- \c False: \em Value is treated as a length parameter [0..1] </li>
|
- \c False: \em Value is treated as a length parameter. [0..1] </li>
|
||||||
</ul>
|
</ul>
|
||||||
\b Arguments: Name + 1 Edge + 1 Value setting the position of
|
\b Arguments: Name + 1 Edge + 1 Value setting the position of
|
||||||
the point according to one of the selected modes.
|
the point according to the selected mode.
|
||||||
|
|
||||||
The difference between "by parameter" and "by length" modes becomes
|
The difference between "by parameter" and "by length" modes becomes
|
||||||
apparent on the edges with irregular parametrization (for example,
|
apparent on the edges with irregular parametrization (for example,
|
||||||
@ -41,15 +40,15 @@ The \b Result will be a \b GEOM_Object.
|
|||||||
\image html repair8.png
|
\image html repair8.png
|
||||||
\n\n
|
\n\n
|
||||||
</li>
|
</li>
|
||||||
<li>We can select several points that will be projected to the selected
|
<li> By selecting several points that will be projected to the selected
|
||||||
edge to find the location of new vertices.
|
edge to find the location of new vertices.
|
||||||
<p>
|
<p>
|
||||||
<b>TUI Command:</b> <em>geompy.DivideEdgeByPoint(Shape, Edge, Points)</em>
|
<b>TUI Command:</b> <em>geompy.DivideEdgeByPoint(Shape, Edge, Points):</em>
|
||||||
<ul>
|
<ul>
|
||||||
<li> \em Shape is a shape which contains an edge to be divided</li>
|
<li> \em Shape is a shape, which contains an edge to be divided;</li>
|
||||||
<li>\em Edge is an edge to be divided (or it's ID, if it is = -1,
|
<li>\em Edge is an edge to be divided (or its ID, if it is = -1,
|
||||||
then \em Shape should be an edge itself).</li>
|
then \em Shape should be an edge itself);</li>
|
||||||
<li> \em Points is a list of points to project to \a Edge. </li>
|
<li> \em Points is a list of points to be projected to the \a Edge.</li>
|
||||||
</ul>
|
</ul>
|
||||||
\b Arguments: Name + 1 Edge + 1 or more Points.
|
\b Arguments: Name + 1 Edge + 1 or more Points.
|
||||||
|
|
||||||
|
@ -2,16 +2,17 @@
|
|||||||
|
|
||||||
\page check_compound_of_blocks_page Check Compound of Blocks
|
\page check_compound_of_blocks_page Check Compound of Blocks
|
||||||
|
|
||||||
This operation checks whether a shape is a compound of glued blocks.
|
This operation checks whether a shape is a compound of glued blocks
|
||||||
|
and tries to improve the shape to make it include only valid blocks.
|
||||||
|
|
||||||
\image html measures10.png
|
\image html measures10.png
|
||||||
|
|
||||||
To be considered as a compound of blocks, the given shape must satisfy the
|
To be considered as a compound of blocks, the given shape must satisfy the
|
||||||
following conditions:
|
following conditions:
|
||||||
- Each element of the compound should be a Block (6 quadrangle faces);
|
- Each element of the compound should be a Block, i.e. have 6 quadrangle faces;
|
||||||
- Each quadrangle face is a face that has 1 wire with 4 edges. If there are
|
- Each quadrangle face should have one wire with four edges. If there are
|
||||||
more than 4 edges in a single wire and C1 continuity mode is switched on,
|
more than four edges in a single wire and C1 continuity mode is switched on,
|
||||||
a face is quadrangular if it has 4 bounds of C1 continuity.
|
a face is quadrangular if it has four bounds with C1 continuity.
|
||||||
- Blocks can be connected only via an entire quadrangle face or an entire edge;
|
- Blocks can be connected only via an entire quadrangle face or an entire edge;
|
||||||
- The compound should be connected;
|
- The compound should be connected;
|
||||||
- Each couple of connecting quadrangle faces should be glued.
|
- Each couple of connecting quadrangle faces should be glued.
|
||||||
@ -20,14 +21,22 @@ a face is quadrangular if it has 4 bounds of C1 continuity.
|
|||||||
In this dialog:
|
In this dialog:
|
||||||
|
|
||||||
- \b Object - the checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
- \b Object - the checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
||||||
- <b>Use C1 criterion</b> - option that shitches on/off the C1 continuity mode.
|
- <b>Use C1 criterion</b> - option switches on/off the C1 continuity mode.
|
||||||
- <b>Angular Tolerance</b> - angular tolerance to check C1 continuity between neighbor edges in a wire.
|
- <b>Angular Tolerance</b> - angular tolerance to check C1 continuity between neighbor edges in a wire.
|
||||||
- \b Errors list informs of possible errors, for example:
|
- \b Errors list informs of possible errors, for example:
|
||||||
- Not a block;
|
- Not a block;
|
||||||
- Not glued;
|
- Not glued;
|
||||||
- Not connected;
|
- Not connected;
|
||||||
- Extra or degenerated edge.
|
- Extra or degenerated edge.
|
||||||
- <b>Incriminated Sub-shapes</b> field outputs the list of sub-shapes that cause problem. It is possible to select them in the list and publish in the study for further analysis by clicking \b Apply or <b>Apply and Close</b> button.
|
- <b>Incriminated Sub-shapes</b> field outputs the list of sub-shapes that cause problem.
|
||||||
|
- \b Apply and <b>Apply and Close</b> buttons launch an improving process
|
||||||
|
and publish a result shape which includes valid blocks only. The
|
||||||
|
improving process tries to
|
||||||
|
- remove seam edges and degenerated edges of surfaces of revolution;
|
||||||
|
- re-approximate surfaces to exclude singularities on boundaries;
|
||||||
|
- unite edges and faces;
|
||||||
|
- glue faces.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
\n <b>TUI Command:</b>
|
\n <b>TUI Command:</b>
|
||||||
@ -38,4 +47,4 @@ is returned, and encountered errors are printed in the python console.
|
|||||||
See also a \ref tui_check_compound_of_blocks_page "TUI example".
|
See also a \ref tui_check_compound_of_blocks_page "TUI example".
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
@ -2,6 +2,14 @@
|
|||||||
|
|
||||||
\page check_self_intersections_page Detect Self-intersections
|
\page check_self_intersections_page Detect Self-intersections
|
||||||
|
|
||||||
|
\n To <b>Detect Self-intersections</b> in the <b>Main Menu</b> select
|
||||||
|
<b>Inspection - > Detect Self-intersections</b>.
|
||||||
|
|
||||||
|
There are two ways to check self-intersections.
|
||||||
|
|
||||||
|
\anchor check_self_intersections_topological
|
||||||
|
<br><h3>Check topological intersections</h3>
|
||||||
|
|
||||||
This operation checks the topology of the selected shape to detect self-intersections.
|
This operation checks the topology of the selected shape to detect self-intersections.
|
||||||
|
|
||||||
\image html measures11.png
|
\image html measures11.png
|
||||||
@ -9,17 +17,14 @@ This operation checks the topology of the selected shape to detect self-intersec
|
|||||||
In this dialog:
|
In this dialog:
|
||||||
|
|
||||||
- \b Object - the checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
- \b Object - the checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
||||||
- <b>Level of check</b> - The combo box that allows to set the level of checking shape on self-interference.
|
- <b>Level of check</b> - combo box allows setting the level of self-interference checking. It defines, which interferences will be checked. The default value is "All interferences".
|
||||||
It defines which interferferences will be checked. Default value is "All interferences".
|
- <b>Compute self-intersections</b> button performs the computation.
|
||||||
- <b>Compute self-intersections</b> button computes self-interferences.
|
- \b Summary section contains the general report about self-intersections of the object and/or errors that occurred during the computation.
|
||||||
- \b Summary section contains the general report if the object has self-intersections and/or if errors are occured during computation.
|
- \b Self-intersections list contains the list of detected self-intersections. Select the intersection to show <b>Sub-shapes</b> in the field to the right.
|
||||||
- \b Self-intersections list contains the list of self-intersections detected.
|
- \b Apply and <b>Apply and Close</b> buttons store the interferences selected in the <b>Self-intersections</b> list box in the study for further analysis.
|
||||||
Select the intersection(s) to show <b>Sub-shapes</b> in the field to the right.
|
If no interferences are selected, all of them are published in the study. Each interference is published as a child compound of the source shape and contains a couple of intersecting sub-shapes.
|
||||||
- \b Apply and <b>Apply and Close</b> buttons are used to store interferences selected in the "Self-intersections" list box in the study for further analysis.
|
|
||||||
If no any interference is selected, all interferences are published in the study. Each interference is published as a child
|
|
||||||
compound of the source shape and contains a couple of intersecting sub-shapes.
|
|
||||||
|
|
||||||
\note This tool is useful for detection of shapes, not suitable for
|
\note This tool is useful for detection of shapes that are not suitable as
|
||||||
arguments of Boolean operations and Partition algorithm.
|
arguments of Boolean operations and Partition algorithm.
|
||||||
For more information about Partition and Boolean Operations Algorithms
|
For more information about Partition and Boolean Operations Algorithms
|
||||||
and their limitations refer to <a href="SALOME_BOA_PA.pdf">this document</a>.
|
and their limitations refer to <a href="SALOME_BOA_PA.pdf">this document</a>.
|
||||||
@ -32,5 +37,28 @@ where: \n
|
|||||||
|
|
||||||
See also a \ref tui_check_self_intersections_page "TUI example".
|
See also a \ref tui_check_self_intersections_page "TUI example".
|
||||||
|
|
||||||
|
\anchor check_self_intersections_fast
|
||||||
|
<br><h3>Fast intersection</h3>
|
||||||
|
|
||||||
*/
|
This operations allows to quickly detect self-interferences of the given shape by means of algorithm based on mesh intersections.
|
||||||
|
|
||||||
|
\image html measures13.png
|
||||||
|
|
||||||
|
This algorithm works on the faces level, i.e. it computes only face-to-face intersections. No additional types of intersections is computed.
|
||||||
|
This case can be useful in order to detect all the intersections between the subshapes of type "surface" inside assembly.
|
||||||
|
Quality of result will depend on the quality of tesselation (managed via the deflection parameter). However, small values of deflection can
|
||||||
|
significantly decrease performance of the algorithm.
|
||||||
|
Nevertheless, performance of Fast Intersect algorithm is much higher than topological intersection.
|
||||||
|
|
||||||
|
\n <b>Result:</b> Boolean.
|
||||||
|
\n <b>TUI Command:</b> <em>geompy.CheckSelfIntersectionsFast(theShape, theDeflection, theTolerance),</em> \n
|
||||||
|
where: \n
|
||||||
|
\em theShape is the shape checked for validity. \n
|
||||||
|
\em theDeflection is a linear deflection coefficient that specifies quality of tesselation. If theDeflection <= 0, default deflection 0.001 is used.
|
||||||
|
\em theTolerance Specifies a distance between shapes used for detecting gaps:
|
||||||
|
- if theTolerance <= 0, algorithm detects intersections;
|
||||||
|
- if theTolerance > 0, algorithm detects gaps.
|
||||||
|
|
||||||
|
See also a \ref tui_check_self_intersections_fast_page "TUI example".
|
||||||
|
|
||||||
|
*/
|
||||||
|
@ -15,10 +15,8 @@ axis, creating a body of revolution.</li>
|
|||||||
<li>\subpage create_extrusion_alongpath_page "Extrude an object along a path",
|
<li>\subpage create_extrusion_alongpath_page "Extrude an object along a path",
|
||||||
creating a more complex trajectory object.</li>
|
creating a more complex trajectory object.</li>
|
||||||
<li>\subpage create_pipe_path_page "Restore Path" of a pipe-like shape.</li>
|
<li>\subpage create_pipe_path_page "Restore Path" of a pipe-like shape.</li>
|
||||||
<li>\subpage create_thickness_page "Thickness" operation that allows to add a thickness to objects.</li>
|
<li>\subpage create_thickness_page "Add thickness" to objects.</li>
|
||||||
|
<li>\subpage create_groups_page "Generate Groups" for certain generation operations.</li>
|
||||||
<li>\subpage create_groups_page "Generate Groups".
|
|
||||||
This cross-operation functionality allows creation of groups for certain generation operations.</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<b> New entity -> Advanced </b> sub-menu allows creating new geometric
|
<b> New entity -> Advanced </b> sub-menu allows creating new geometric
|
||||||
|
@ -16,7 +16,7 @@ obtain from it.
|
|||||||
The \b Result of the operation will be a List of \b GEOM_Objects
|
The \b Result of the operation will be a List of \b GEOM_Objects
|
||||||
(vertexes, edges, wires, faces, shells or solids).
|
(vertexes, edges, wires, faces, shells or solids).
|
||||||
|
|
||||||
Available choices in the <b>Sub Shapes Type</b> combo box depend on the type
|
The choices available in the <b>Sub Shapes Type</b> combo box depend on the type
|
||||||
of selected <b>Main Object</b>:
|
of selected <b>Main Object</b>:
|
||||||
- \b Compound: to extract compounds;
|
- \b Compound: to extract compounds;
|
||||||
- \b Compsolid: to extract compsolids;
|
- \b Compsolid: to extract compsolids;
|
||||||
@ -29,72 +29,70 @@ of selected <b>Main Object</b>:
|
|||||||
- \b Shape: to extract top-level contents of the compound shape;
|
- \b Shape: to extract top-level contents of the compound shape;
|
||||||
- \b Flat: to extract "flat" contents of the compound shape.
|
- \b Flat: to extract "flat" contents of the compound shape.
|
||||||
|
|
||||||
Note: "flat" contents means top-level simple-type sub-shapes extracted from
|
Note: "flat" contents means that top-level simple-type sub-shapes are extracted from
|
||||||
the compound object recursively (i.e. there is no compounds in the result).
|
the compound object recursively (i.e. there are no compounds in the result).
|
||||||
For example, if a compound C1 contains a solid S1 and another compound C2 that
|
|
||||||
contains solids S2 and S3 (see picture below):
|
Let us take, for example, compound C1 that contains solid S1 and another compound C2 that
|
||||||
|
contains solids S2 and S3 (see the picture below):
|
||||||
- Explode operation with \b Shape type given as parameter will return S1 and C2;
|
- Explode operation with \b Shape type given as parameter will return S1 and C2;
|
||||||
- Explode operation with \b Flat type given as parameter will return S1, S2 and S3.
|
- Explode operation with \b Flat type given as parameter will return S1, S2 and S3.
|
||||||
|
|
||||||
\image html flat_contents.png
|
\image html flat_contents.png
|
||||||
|
|
||||||
Switching on <b>Select Sub-shapes</b> check box allows manual selection of sub-shapes
|
Switching on <b>Select Sub-shapes</b> check box allows manual selection of sub-shapes
|
||||||
to be extracted from the main object. In this mode the user can select sub-shapes
|
to be extracted from the main object. In this mode it is possible to select sub-shapes
|
||||||
directly in 3D viewer.
|
directly in 3D viewer.
|
||||||
|
|
||||||
When <b>Select Sub-shapes</b> check box is switched on, additional \b Filter controls
|
When <b>Select Sub-shapes</b> check box is switched on, additional \b Filter controls
|
||||||
allow to automatically pick up entites which satisfy specified threshold value(s).
|
allow to automatically pick up entities, which satisfy the specified threshold value(s).
|
||||||
The numerical functor for each sub-shape that is compared with threshold value(s)
|
The numerical functor for each sub-shape that is compared with the threshold value(s)
|
||||||
is computed according to the shape's topological properties:
|
is computed according to the topological properties of the shape:
|
||||||
- length for edges and wires
|
- length for edges and wires;
|
||||||
- area for faces and shells
|
- area for faces and shells;
|
||||||
- volume for solids, compounds, compsolids
|
- volume for solids, compounds and compsolids.
|
||||||
|
|
||||||
Filtering capabilities are not available for vertices.
|
Filtering capabilities are not available for vertices.
|
||||||
|
|
||||||
In order to filter out some entities:
|
To filter out some entities it is necessary to do the following:
|
||||||
- Activate one or two filtering controls by switching on corresponding check boxes;
|
- Activate one or two filtering controls by switching on the corresponding check boxes;
|
||||||
- Select required threshold comparator type; the following choices are available:
|
- Select the required threshold comparator type; the following choices are available:
|
||||||
- <b>Less Than</b> or <b>Equal or Less Than</b> for the first comparator;
|
- <b>Less Than</b> or <b>Equal or Less Than</b> for the first comparator;
|
||||||
- <b>Greater Than</b> or <b>Equal or Greater Than</b> for the second comparator;
|
- <b>Greater Than</b> or <b>Equal or Greater Than</b> for the second comparator;
|
||||||
- Enter required threshold value (values);
|
- Enter the required threshold value (values);
|
||||||
- Press \b Apply button in the \b Filter group.
|
- Press \b Apply button in the \b Filter group.
|
||||||
|
|
||||||
The entities which satisfy entered filtering parameters will be automatically highlighted
|
The entities, which correspond to the entered filtering parameters, will be automatically highlighted
|
||||||
in the 3D viewer.
|
in the 3D viewer.
|
||||||
|
|
||||||
Using <b>TUI Commands</b> you can perform this operation in a
|
Using <b>TUI Commands</b> you can perform this operation in a
|
||||||
variety of ways:
|
variety of ways:
|
||||||
- <em>geompy.ExtractShapes(Shape, Type, isSorted)</em> explodes a
|
- <em>geompy.ExtractShapes(Shape, Type, isSorted)</em> explodes a
|
||||||
Shape into sub-shapes of a given Type and returns a List of sub-shapes.
|
Shape into sub-shapes of a given Type and returns a List of sub-shapes.
|
||||||
This method does not return the Shape itself if it matches the
|
This method does not return the Shape itself if it matches the Type.
|
||||||
Type.
|
- <em>geompy.SubShapeAll(Shape, Type)</em> explodes a Shape into
|
||||||
- <em>geompy.SubShapeAll(Shape, Type)</em> explodes a Shape on
|
|
||||||
sub-shapes of a given Type and returns a List of sub-shapes.
|
sub-shapes of a given Type and returns a List of sub-shapes.
|
||||||
- <em>geompy.SubShapeAllIDs(Shape, Type)</em> explodes a Shape on
|
- <em>geompy.SubShapeAllIDs(Shape, Type)</em> explodes a Shape into sub-shapes of a given Type and returns a List of IDs of sub-shapes.
|
||||||
sub-shapes of a given Type and returns a List of IDs of
|
|
||||||
sub-shapes.
|
|
||||||
- <em>geompy.SubShapeAllSortedCentres(Shape, Type)</em> explodes a
|
- <em>geompy.SubShapeAllSortedCentres(Shape, Type)</em> explodes a
|
||||||
shape on sub-shapes of a given type and sorts them taking into account
|
shape into sub-shapes of a given type and sorts them taking into account
|
||||||
their gravity centers, to provide a stable order of sub-shapes.
|
their gravity centers, to provide a stable order of sub-shapes.
|
||||||
It returns a list of sub-shapes.
|
It returns a list of sub-shapes.
|
||||||
- <em>geompy.SubShapeAllSortedCentresIDs(Shape, Type)</em> explodes
|
- <em>geompy.SubShapeAllSortedCentresIDs(Shape, Type)</em> explodes
|
||||||
a shape on sub-shapes of a given type and sorts them taking into
|
a shape into sub-shapes of a given type and sorts them taking into
|
||||||
account their gravity centers, to provide a stable order of sub-shapes.
|
account their gravity centers, to provide a stable order of sub-shapes.
|
||||||
It returns a List of IDs of sub-shapes.
|
It returns a List of IDs of sub-shapes.
|
||||||
- <em>geompy.SubShape(Shape, Type, ListOfInd)</em> allows to obtain
|
- <em>geompy.SubShape(Shape, Type, ListOfInd)</em> allows to obtain
|
||||||
a compound of sub-shapes of the Shape, selected by they indices in a
|
a compound of sub-shapes of the Shape, selected by their indexes in a
|
||||||
list of all sub-shapes of the given Type. Each index is in the range
|
list of all sub-shapes of the given Type. Each index is in the range
|
||||||
[1, Nb_Sub-Shapes_Of_Given_Type].
|
[1, Nb_Sub-Shapes_Of_Given_Type].
|
||||||
- <em>geompy.SubShapeSortedCentres(Shape, Type, ListOfInd)</em>
|
- <em>geompy.SubShapeSortedCentres(Shape, Type, ListOfInd)</em>
|
||||||
allows to obtain a compound of sub-shapes of the Shape, selected by
|
allows to obtain a compound of sub-shapes of the Shape, selected by
|
||||||
they indices in sorted list of all sub-shapes of the given Type. Each
|
their indexes in a sorted list of all sub-shapes of the given Type. Each
|
||||||
index is in the range [1, Nb_Sub-Shapes_Of_Given_Type]
|
index is in the range [1, Nb_Sub-Shapes_Of_Given_Type]
|
||||||
|
|
||||||
<b>Arguments: </b>1 SHAPE + 1 type of SubShape.
|
<b>Arguments: </b>1 SHAPE + 1 type of SubShape.
|
||||||
|
|
||||||
<b>Example:</b>
|
<b>Example:</b>
|
||||||
|
|
||||||
\image html explode.png "A box, exploded into faces"
|
\image html explode.png "A box exploded into faces"
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
@ -72,18 +72,33 @@ Additional controls:
|
|||||||
- If <b>With contact</b> is checked, the section is translated in contact with the spine.
|
- If <b>With contact</b> is checked, the section is translated in contact with the spine.
|
||||||
- If <b>With correction</b> is checked, the section is rotated to be orthogonal to the spine
|
- If <b>With correction</b> is checked, the section is rotated to be orthogonal to the spine
|
||||||
tangent in the corresponding point.
|
tangent in the corresponding point.
|
||||||
|
- If <b>Step-by-step generation</b> is checked, the result is created
|
||||||
|
step-by-step, i.e. it creates pipes between each pair of neighbor sections and
|
||||||
|
fuses them into a single shape.
|
||||||
|
|
||||||
|
\note If <b>Step-by-step generation</b> is checked, <b>With contact</b> and
|
||||||
|
<b>With correction</b> controls are disabled as corrections of bases are
|
||||||
|
not allowed in step-by-step mode.
|
||||||
|
|
||||||
<b>Generate groups</b> checkbox - if checked allows to create groups of
|
<b>Generate groups</b> checkbox - if checked allows to create groups of
|
||||||
sub-shapes. For more details on groups creation please refer to
|
sub-shapes. For more details on groups creation please refer to
|
||||||
\ref create_groups_page "this description".
|
\ref create_groups_page "this description".
|
||||||
\n The \b Result of the operation will be a shell or a solid.
|
\n The \b Result of the operation will be a shell or a solid.
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakePipeWithDifferentSections(baseShape, locations, pathShape, withContact, withCorrection,
|
\n <b>TUI Commands:</b>
|
||||||
|
- <em>geompy.MakePipeWithDifferentSections(baseShape, locations, pathShape, withContact, withCorrection,
|
||||||
IsGenerateGroups=False)</em>
|
IsGenerateGroups=False)</em>
|
||||||
\n <b>Arguments:</b> Name + list of shapes (edges, planar wires, faces or shells) serving as base object +
|
\n <b>Arguments:</b> Name + list of shapes (edges, planar wires, faces or shells) serving as base object +
|
||||||
list of locations (vertices) on the path corresponding specified list of the shapes +
|
list of locations (vertices) on the path corresponding specified list of the shapes +
|
||||||
1 shape (edge or wire) for definition of the path +
|
1 shape (edge or wire) for definition of the path +
|
||||||
3 Boolean parameters (withContact, withCorrection, IsGenerateGroups).
|
3 Boolean parameters (withContact, withCorrection, IsGenerateGroups).
|
||||||
|
- <em>geompy.MakePipeWithDifferentSectionsBySteps(baseShape, locations, pathShape,
|
||||||
|
IsGenerateGroups=False)</em>
|
||||||
|
\n <b>Arguments:</b> Name + list of shapes (edges, planar wires, faces or shells) serving as base object +
|
||||||
|
list of locations (vertices) on the path corresponding specified list of the shapes +
|
||||||
|
1 shape (edge or wire) for definition of the path +
|
||||||
|
Boolean parameter.
|
||||||
|
|
||||||
\n <b>Advanced options</b> \ref preview_anchor "Preview"
|
\n <b>Advanced options</b> \ref preview_anchor "Preview"
|
||||||
|
|
||||||
\image html pipe3.png
|
\image html pipe3.png
|
||||||
|
@ -11,7 +11,7 @@ of the operation will be a GEOM_Object (FACE).
|
|||||||
\n Firstly, to create a \b Face you need to select input shape(s). The list of
|
\n Firstly, to create a \b Face you need to select input shape(s). The list of
|
||||||
input shapes can include shapes of any type except vertices; if the shapes are
|
input shapes can include shapes of any type except vertices; if the shapes are
|
||||||
neither wires nor edges, the algorithm extracts all edges from
|
neither wires nor edges, the algorithm extracts all edges from
|
||||||
the input shapes and works on the obtaineed edges.
|
the input shapes and works on the obtained edges.
|
||||||
\n The edges and wires do not necessarily have to be closed, the
|
\n The edges and wires do not necessarily have to be closed, the
|
||||||
algorithm automatically builds a wire of maximum length from all
|
algorithm automatically builds a wire of maximum length from all
|
||||||
given edges and wires. If several closed wires are detected the algorithm tries
|
given edges and wires. If several closed wires are detected the algorithm tries
|
||||||
@ -26,7 +26,7 @@ exceeds 1e-06, a warning will be shown, but the face will be created
|
|||||||
and published in the study in a normal way. Using such faces can lead to failures
|
and published in the study in a normal way. Using such faces can lead to failures
|
||||||
or unpredictable results in most operations.
|
or unpredictable results in most operations.
|
||||||
|
|
||||||
\n The \b Result will be a \b GEOM_Object (FACE).
|
\n The \b Result will be a \b GEOM_Object. It can be either a single face or, in specific cases, a compound of faces.
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeFaceWires([list of Shapes], isPlanarWanted)</em>
|
\n <b>TUI Command:</b> <em>geompy.MakeFaceWires([list of Shapes], isPlanarWanted)</em>
|
||||||
\n <b>Arguments:</b> Name + 1 wire.
|
\n <b>Arguments:</b> Name + 1 wire.
|
||||||
@ -35,7 +35,7 @@ or unpredictable results in most operations.
|
|||||||
|
|
||||||
\n Secondly, it is possible to create a face based on another face's surface and bounded by a wire.
|
\n Secondly, it is possible to create a face based on another face's surface and bounded by a wire.
|
||||||
|
|
||||||
\n The \b Result will be a \b GEOM_Object (FACE).
|
\n The \b Result will be a \b GEOM_Object (face).
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeFaceFromSurface(theFace, theWire)</em>
|
\n <b>TUI Command:</b> <em>geompy.MakeFaceFromSurface(theFace, theWire)</em>
|
||||||
\n <b>Arguments:</b> Name + 1 face + 1 wire.
|
\n <b>Arguments:</b> Name + 1 face + 1 wire.
|
||||||
@ -50,7 +50,7 @@ and constraints:
|
|||||||
|
|
||||||
\note Please note, that the constraint face must be connected to a reference edge.
|
\note Please note, that the constraint face must be connected to a reference edge.
|
||||||
|
|
||||||
\n The \b Result will be a \b GEOM_Object (FACE).
|
\n The \b Result will be a \b GEOM_Object (face).
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeFaceWithConstraints([List of constraints])</em>
|
\n <b>TUI Command:</b> <em>geompy.MakeFaceWithConstraints([List of constraints])</em>
|
||||||
\n <b>Arguments:</b> Name + List of input edges and constraint faces. If a constraint
|
\n <b>Arguments:</b> Name + List of input edges and constraint faces. If a constraint
|
||||||
|
@ -3,7 +3,9 @@
|
|||||||
\page create_isoline_page Isoline
|
\page create_isoline_page Isoline
|
||||||
|
|
||||||
\b Isoline is a 3D curve built on a bounded face limited by <em> [Umin, Umax] </em> and <em> [Vmin, Vmax] </em>
|
\b Isoline is a 3D curve built on a bounded face limited by <em> [Umin, Umax] </em> and <em> [Vmin, Vmax] </em>
|
||||||
values of U and V parameters. For all points of the isoline U or V parameter value is constant.
|
values of U and V parameters. For all points of the isoline U or V parameter value is constant.
|
||||||
|
|
||||||
|
Result of this operation is either a single edge or a compound of edges.
|
||||||
|
|
||||||
To create an \b Isoline of a face in the <b>Main Menu</b> select <b>New Entity - > Basic - > Isoline</b>.
|
To create an \b Isoline of a face in the <b>Main Menu</b> select <b>New Entity - > Basic - > Isoline</b>.
|
||||||
|
|
||||||
|
@ -28,9 +28,10 @@ the position of this point regarding the reference one.
|
|||||||
\n Thirdly, we can define a point by an \b Edge and a \b Parameter
|
\n Thirdly, we can define a point by an \b Edge and a \b Parameter
|
||||||
indicating its position on the Edge, ranging from 0.0 to 1.0. For example, 0.5 means that the
|
indicating its position on the Edge, ranging from 0.0 to 1.0. For example, 0.5 means that the
|
||||||
point is located in the middle of the edge.
|
point is located in the middle of the edge.
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeVertexOnCurve(Edge,Parameter).</em>
|
\n <b>TUI Command:</b> <em>geompy.MakeVertexOnCurve(Edge,Parameter,takeOrientationIntoAccount).</em>
|
||||||
\n <b>Arguments:</b> Name + 1 edge + 1 Parameter defining the
|
\n <b>Arguments:</b> Name + 1 edge + 1 Parameter defining the
|
||||||
position of the point on the given edge.
|
position of the point on the given edge + flag that tells if it is necessary
|
||||||
|
to take the edge orientation into account.
|
||||||
\image html point3.png
|
\image html point3.png
|
||||||
|
|
||||||
Alternatively, it is possible to define a point by an \b Edge and a \b Length.
|
Alternatively, it is possible to define a point by an \b Edge and a \b Length.
|
||||||
|
@ -6,7 +6,7 @@ To create a \b Shell in the <b>Main Menu</b> select <b>New Entity - >
|
|||||||
Build - > Shell</b>
|
Build - > Shell</b>
|
||||||
|
|
||||||
\n You can create a \b Shell from a compound of faces or a list of faces or shells.
|
\n You can create a \b Shell from a compound of faces or a list of faces or shells.
|
||||||
\n The \b Result will be a \b GEOM_Object (shell).
|
\n The \b Result will be a \b GEOM_Object. It can be either a single shell or, in specific cases, a compound of shells.
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeShell(ListOfShape)</em>
|
\n <b>TUI Command:</b> <em>geompy.MakeShell(ListOfShape)</em>
|
||||||
\n <b>Arguments:</b> Name + Compound of faces or List of faces having connected edges.
|
\n <b>Arguments:</b> Name + Compound of faces or List of faces having connected edges.
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
|
|
||||||
To create a <b>Surface From Face</B> in the <b>Main Menu</b> select <b>New Entity - > Basic - > Surface From Face</b>
|
To create a <b>Surface From Face</B> in the <b>Main Menu</b> select <b>New Entity - > Basic - > Surface From Face</b>
|
||||||
|
|
||||||
\n This function takes some face as input parameter and creates new
|
\n This function takes a face at input and creates a new
|
||||||
GEOM_Object, i.e. topological shape by extracting underlying surface
|
<b>GEOM_Object</b>, i.e. topological shape by extracting the underlying surface
|
||||||
of the source face and limiting it by the Umin, Umax, Vmin, Vmax
|
of the source face and limiting it by the <b>Umin, Umax, Vmin</b> and <b>Vmax</b>
|
||||||
parameters of the source face (in the parametrical space).
|
parameters of the source face (in the parametric space).
|
||||||
\n
|
\n
|
||||||
\ref restore_presentation_parameters_page "Advanced options".
|
\ref restore_presentation_parameters_page "Advanced options".
|
||||||
|
|
||||||
|
@ -2,26 +2,28 @@
|
|||||||
|
|
||||||
\page create_thickness_page Thickness Construction
|
\page create_thickness_page Thickness Construction
|
||||||
|
|
||||||
To add a \b Thickness to a shape in the <b>Main Menu</b> select <b>New Entity - > Generation - > Thickness</b>
|
To add \b Thickness to a shape in the <b>Main Menu</b> select <b>New Entity - > Generation - > Thickness</b>.
|
||||||
\n
|
|
||||||
It is possible to create a Solid from a Face or a Shell by applying a
|
Switch between adding thickness to a Face (Shell) or a Solid using radio buttons.
|
||||||
\b Thickness. To do it you should define an \b Object that is a Face or a
|
|
||||||
Shell, \b Thickness and to define the thickness direction by means of
|
Firstly, \b Thickness can be applied to a Face or a Shell to create a Solid.
|
||||||
<b>Thicken towards the inside</b> check box.
|
|
||||||
|
|
||||||
\image html thickness.png
|
\image html thickness.png
|
||||||
|
|
||||||
|
It is necessary to define an \b Object (Face or Shell) and the value of \b Thickness.
|
||||||
|
<b>Thicken towards the inside</b> check box allows changing the thickness direction.
|
||||||
|
|
||||||
<b>Example:</b>
|
<b>Example:</b>
|
||||||
|
|
||||||
\image html thickness_result.png "Thickness of Shell"
|
\image html thickness_result.png "Thickness of Shell"
|
||||||
|
|
||||||
It is possible to apply \b Thickness to a Solid. The result of this operation
|
Secondly, the \b Thickness can be applied to a Solid to create a hollowed Solid.
|
||||||
is the hollowed Solid. To do it you should define an \b Object that is a Solid,
|
|
||||||
\b Faces to be removed from result, \b Thickness and the thickness direction by
|
|
||||||
means of <b>Thicken towards the inside</b> check box.
|
|
||||||
|
|
||||||
\image html thicksolid.png
|
\image html thicksolid.png
|
||||||
|
|
||||||
|
It is necessary to define a Solid \b Object \b Faces to be removed from the result and \b Thickness.
|
||||||
|
<b>Thicken towards the inside</b> check box allows changing the thickness direction.
|
||||||
|
|
||||||
<b>Example:</b>
|
<b>Example:</b>
|
||||||
|
|
||||||
\image html thicksolid_result.png "Thickness of Solid"
|
\image html thicksolid_result.png "Thickness of Solid"
|
||||||
@ -36,8 +38,8 @@ Modifies a shape to make it a thick solid.
|
|||||||
|
|
||||||
<b>Arguments:</b> Name + 1 shape (face, shell or solid) + thickness +
|
<b>Arguments:</b> Name + 1 shape (face, shell or solid) + thickness +
|
||||||
the list of face IDs.
|
the list of face IDs.
|
||||||
\n If the shape is face or shell the list of face IDs is not used.
|
\n If the shape is a face or a shell the list of face IDs is not used.
|
||||||
The thickness can be positive or negative for thicken towards the inside.
|
The thickness can be positive or negative for thickening towards the inside.
|
||||||
\n\n <b>Advanced options</b> \ref preview_anchor "Preview"
|
\n\n <b>Advanced options</b> \ref preview_anchor "Preview"
|
||||||
|
|
||||||
Our <b>TUI Scripts</b> provide you with useful examples of creation of
|
Our <b>TUI Scripts</b> provide you with useful examples of creation of
|
||||||
|
@ -28,13 +28,15 @@ It is also possible to select an object(s) directly in the "Dependency Tree" vie
|
|||||||
|
|
||||||
All necessary parameters of Dependency Tree Viewer can be edited in the \ref pref_dependency_tree "Preferences".
|
All necessary parameters of Dependency Tree Viewer can be edited in the \ref pref_dependency_tree "Preferences".
|
||||||
|
|
||||||
|
\note This functionality is available only if GUI module is builded with Graphics view (set option SALOME_USE_GRAPHICSVIEW to ON when building GUI module).
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
\anchor dependency_tree_nodes_anchor <h2>Nodes</h2>
|
\anchor dependency_tree_nodes_anchor <h2>Nodes</h2>
|
||||||
|
|
||||||
Tree nodes in the Dependency Viewer are named according to the study
|
Tree nodes in the Dependency Viewer are named according to the study
|
||||||
names of the corresponding objects.
|
names of the corresponding objects.
|
||||||
|
|
||||||
All nodes have fixed size, so long names are cut; the full object name can be seen in the tooltip
|
All nodes have fixed size, so long names are cut; the full object name can be seen in the tool-tip
|
||||||
when the cursor is hovered over the node.
|
when the cursor is hovered over the node.
|
||||||
|
|
||||||
"Dependency Tree" view supports the following states of nodes:
|
"Dependency Tree" view supports the following states of nodes:
|
||||||
@ -61,11 +63,11 @@ Browser, OCC Viewer or Dependency Tree Viewer;</li></ul>
|
|||||||
Dependency Tree Viewer shows oriented links between nodes to
|
Dependency Tree Viewer shows oriented links between nodes to
|
||||||
represent the dependency direction. The viewer supports the following states of links:
|
represent the dependency direction. The viewer supports the following states of links:
|
||||||
|
|
||||||
<ul><li><b>Unidirectional link</b> - shows that object B depends on object A;</li></ul>
|
<ul><li><b>Unidirectional link</b> - shows that object \b B depends on object \b A;</li></ul>
|
||||||
\image html tree_unidir_link.png
|
\image html tree_unidir_link.png
|
||||||
|
|
||||||
<ul><li><b>Bidirectional link</b> - shows that object B depends on
|
<ul><li><b>Bidirectional link</b> - shows that object \b B depends on
|
||||||
object A and, at the same time, object A depends on object B;</li></ul>
|
object \b A and, at the same time, object \b A depends on object \b B;</li></ul>
|
||||||
\image html tree_bidir_link.png
|
\image html tree_bidir_link.png
|
||||||
|
|
||||||
<ul><li><b>Self-dependency link</b> - shows that an object depends on itself;</li></ul>
|
<ul><li><b>Self-dependency link</b> - shows that an object depends on itself;</li></ul>
|
||||||
|
@ -29,7 +29,7 @@ functionality for all objects in the current view via the main menu
|
|||||||
|
|
||||||
\n <b>TUI Command:</b> <em>gg.setVectorsMode(ID, Bool)</em>
|
\n <b>TUI Command:</b> <em>gg.setVectorsMode(ID, Bool)</em>
|
||||||
|
|
||||||
\n Also it is possible to show the vertices of the selected
|
\n It is possible to show the vertices of the selected
|
||||||
shape. For this, choose in the context menu of the shape
|
shape. For this, choose in the context menu of the shape
|
||||||
<b>Display mode -> Show Vertices</b>, or apply this
|
<b>Display mode -> Show Vertices</b>, or apply this
|
||||||
functionality for all objects in the current view via the main menu
|
functionality for all objects in the current view via the main menu
|
||||||
@ -40,10 +40,9 @@ functionality for all objects in the current view via the main menu
|
|||||||
|
|
||||||
\n <b>TUI Command:</b> <em>gg.setVerticesMode(ID, Bool)</em>
|
\n <b>TUI Command:</b> <em>gg.setVerticesMode(ID, Bool)</em>
|
||||||
|
|
||||||
\n Moreover user can show the name of the selected
|
\n To show the name of the selected shape, choose in its context menu
|
||||||
shape. For this, choose in the context menu of the shape
|
|
||||||
<b>Display mode -> Show Name</b>, or apply this
|
<b>Display mode -> Show Name</b>, or apply this
|
||||||
functionality for all objects in the current view via the main menu
|
functionality for all objects in the current view via the main menu option
|
||||||
<b> View -> Display Mode -> Show/Hide Name.</b>
|
<b> View -> Display Mode -> Show/Hide Name.</b>
|
||||||
|
|
||||||
\image html name_mode.png
|
\image html name_mode.png
|
||||||
|
@ -1,25 +1,20 @@
|
|||||||
/*!
|
/*!
|
||||||
|
|
||||||
\page extension_operation_page Extension of an Edge or a Face
|
\page extension_operation_page Extension
|
||||||
|
|
||||||
\n To produce an \b Extension in the <b>Main Menu</b> select
|
\n To produce an \b Extension of an Edge or a Face select in the <b>Main Menu</b>
|
||||||
<b>Operations - > Transformation - > Extension</b>
|
<b>Operations - > Transformation - > Extension</b>. The type of extension is defined using the radio buttons.
|
||||||
|
|
||||||
\n This operation resizes an \b Edge by means of first
|
Firstly it is possible to resize an \b Edge by modifying its first
|
||||||
and last parameters modification or a \b Face by means of modification
|
and last parameters
|
||||||
of minimal and maximal U- and V-Parameters. \n
|
|
||||||
\ref restore_presentation_parameters_page "Advanced options".
|
|
||||||
|
|
||||||
The type of extension is defined using the radio buttons.
|
\image html extension1.png "Edge Extension"
|
||||||
|
|
||||||
Firstly it is possible to resize an \b Edge.
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.ExtendEdge(theEdge, theMin, theMax)</em>,
|
\n <b>TUI Command:</b> <em>geompy.ExtendEdge(theEdge, theMin, theMax)</em>,
|
||||||
where \em theEdge the input edge to be resized, \em theMin the minimal
|
where \em theEdge the input edge to be resized, \em theMin the minimal
|
||||||
parameter value, \em theMax the maximal parameter value.
|
parameter value, \em theMax the maximal parameter value.
|
||||||
\n <b>Arguments:</b> Name + Object (Edge) + 2 values (Min and Max Parameters).
|
\n <b>Arguments:</b> Name + Object (Edge) + 2 values (Min and Max Parameters).
|
||||||
|
|
||||||
\image html extension1.png "Extension of an Edge"
|
|
||||||
|
|
||||||
\n <b>Example:</b>
|
\n <b>Example:</b>
|
||||||
|
|
||||||
\image html extend_edge_example.png "Original edge (white) and extended edge"
|
\image html extend_edge_example.png "Original edge (white) and extended edge"
|
||||||
@ -28,8 +23,12 @@ parameter value, \em theMax the maximal parameter value.
|
|||||||
negative, the input Edge is extended, otherwise it is shrinked by
|
negative, the input Edge is extended, otherwise it is shrinked by
|
||||||
\b theMin parameter. If \b theMax is greater than 1, the Edge is
|
\b theMin parameter. If \b theMax is greater than 1, the Edge is
|
||||||
extended, otherwise it is shrinked by \b theMax parameter.
|
extended, otherwise it is shrinked by \b theMax parameter.
|
||||||
|
|
||||||
|
Secondly it is possible to resize a \b Face by modifying its
|
||||||
|
minimal and maximal U- and V-Parameters.
|
||||||
|
|
||||||
Secondly it is possible to resize a \b Face.
|
\image html extension2.png "Face Extension"
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.ExtendFace(theFace, theUMin, theUMax,
|
\n <b>TUI Command:</b> <em>geompy.ExtendFace(theFace, theUMin, theUMax,
|
||||||
theVMin, theVMax)</em>, where \em theFace the input face to be resized,
|
theVMin, theVMax)</em>, where \em theFace the input face to be resized,
|
||||||
\em theUMin the minimal U-Parameter value, \em theUMax the maximal U-Parameter
|
\em theUMin the minimal U-Parameter value, \em theUMax the maximal U-Parameter
|
||||||
@ -38,18 +37,16 @@ V-Parameter value.
|
|||||||
\n <b>Arguments:</b> Name + Object (Face) + 4 values (Min and Max U- and
|
\n <b>Arguments:</b> Name + Object (Face) + 4 values (Min and Max U- and
|
||||||
V-Parameters).
|
V-Parameters).
|
||||||
|
|
||||||
\image html extension2.png "Extension of a Face"
|
|
||||||
|
|
||||||
\n <b>Example:</b>
|
\n <b>Example:</b>
|
||||||
|
|
||||||
\image html extend_face_example.png "The original face (gray) and a result
|
\image html extend_face_example.png "The original face (gray) and a result face shrinked along U-Direction and extended along V-Direction"
|
||||||
face shrinked along U-Direction and extended along V-Direction"
|
|
||||||
|
|
||||||
\note The input Face U- and V-Parameters range is [0, 1]. If \b theUMin
|
\note The input Face U- and V-Parameters range is [0, 1]. If \b theUMin
|
||||||
parameter is negative, the input Face is extended, otherwise it is
|
parameter is negative, the input Face is extended, otherwise it is
|
||||||
shrinked along U-Direction by \b theUMin parameter. If theUMax is
|
shrinked along U-Direction by \b theUMin parameter. If \b theUMax is
|
||||||
greater than 1, the Face is extended, otherwise it is shrinked along
|
greater than 1, the Face is extended, otherwise it is shrinked along
|
||||||
U-Direction by \b theUMax parameter. So as for \b theVMin, \b theVMax
|
U-Direction by \b theUMax parameter. The same applies to \b theVMin, \b theVMax
|
||||||
and V-Direction of the input Face.
|
and V-Direction of the input Face.
|
||||||
|
|
||||||
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
/*!
|
/*!
|
||||||
\page fast_intersection_page Fast intersection
|
\page fast_intersection_page Fast intersection
|
||||||
|
|
||||||
This operation checks whether or not two selected shapes are overlapped.
|
This operation checks if two selected shapes are overlapped.
|
||||||
|
|
||||||
This tool is useful for fast detection of intersections and gaps.
|
This tool is useful for fast detection of intersections and gaps.
|
||||||
In contrast to Boolean Operations, Partition and Detect Self-intersection
|
In contrast to Boolean Operations, Partition and Detect Self-intersection
|
||||||
algorithms that compute topological intersections, this algoritm computes
|
algorithms that compute topological intersections, this algorithm computes
|
||||||
intersections by generating tessellation (triangulation) of the source
|
intersections by generating tessellation (triangulation) of the source
|
||||||
shapes and detecting overlapping of resulting meshes. High performance is
|
shapes and detecting overlapping of resulting meshes. High performance is
|
||||||
achieved through the use of existing triangulation of faces.
|
achieved through the use of existing triangulation of faces.
|
||||||
@ -28,22 +28,21 @@ of the GUI module's documentation.
|
|||||||
|
|
||||||
In this dialog:
|
In this dialog:
|
||||||
|
|
||||||
- \b Object 1 - first checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
- <b> Object 1 </b> and <b> Object 2 </b> the checked objects. \b Selection button allows picking them in the viewer or in the object browser.
|
||||||
- \b Object 2 - second checked object. \b Selection button allows picking it in the viewer or in the object browser.
|
|
||||||
- <b>Deflection coefficient</b> specifies the quality of shapes tessellation.
|
- <b>Deflection coefficient</b> specifies the quality of shapes tessellation.
|
||||||
- <b>Detect gaps</b> - when switched on, allows detecting gaps between shapes.
|
- <b>Detect gaps</b> - when switched on, allows detecting gaps between shapes.
|
||||||
- <b>Tolerance</b> - specifies a distance between shapes used for detecting gaps.
|
- <b>Tolerance</b> - specifies the distance between shapes used for detecting gaps.
|
||||||
- <b>Compute intersections</b> - press this button to compute interferences.
|
- <b>Compute intersections</b> - press this button to compute interferences.
|
||||||
- <b>Sub-shapes of Object 1</b> - list of sub-shapes from the first source shape that localize the intersection.
|
- <b>Sub-shapes of Object 1</b> - list of sub-shapes from the first source shape that localize the intersection.
|
||||||
- <b>Sub-shapes of Object 2</b> - list of sub-shapes from the second source shape that localize the intersection.
|
- <b>Sub-shapes of Object 2</b> - list of sub-shapes from the second source shape that localize the intersection.
|
||||||
- \b Apply and <b>Apply and Close</b> buttons are used to store selected intersected shapes in the study for
|
- \b Apply and <b>Apply and Close</b> buttons are used to store selected intersected shapes in the study for
|
||||||
further analysis (see below).
|
further analysis (see below).
|
||||||
|
|
||||||
\note Quality of the result depends on the quality of triangulation. Changing a value of the deflection coefficient
|
\note The result quality depends on the quality of triangulation. Changing the value of the deflection coefficient
|
||||||
parameter can strongly affect the result. On the other hand, small values of deflection coefficient might lead to
|
parameter can strongly affect the result. However, small values of the deflection coefficient might lead to
|
||||||
some performance loss of the algorithm, as number of triangles of the tesselation mesh depends on this parameter.
|
some performance loss of the algorithm, as number of triangles of the tesselation mesh depends on this parameter.
|
||||||
|
|
||||||
It is possible to store sub-shapes selected by the user in the study, for the further analysis.
|
Press <b>Apply and Close</b> or \b Apply button to store the selected sub-shapes in the study for further analysis.
|
||||||
The selection will be published as a compound containing intersected sub-shapes from both source objects.
|
The selection will be published as a compound containing intersected sub-shapes from both source objects.
|
||||||
|
|
||||||
<b>TUI Command:</b> <em>geompy.FastIntersect(theShape1, theShape2, theTolerance = 0.0, theDeflection = 0.001),</em> \n
|
<b>TUI Command:</b> <em>geompy.FastIntersect(theShape1, theShape2, theTolerance = 0.0, theDeflection = 0.001),</em> \n
|
||||||
|
@ -17,7 +17,7 @@ given tolerance value.
|
|||||||
|
|
||||||
\n <b>TUI Command:</b>
|
\n <b>TUI Command:</b>
|
||||||
<p><em>geompy.MakeGlueEdges( theShapes, theTolerance )</em>,
|
<p><em>geompy.MakeGlueEdges( theShapes, theTolerance )</em>,
|
||||||
\n where \em theShapes is either a list or compound of shapes to be
|
\n where \em theShapes is a list or compound of shapes to be
|
||||||
glued, and \em theTolerance is a maximum distance between two
|
glued, and \em theTolerance is a maximum distance between two
|
||||||
edges, which can be considered as coincident.
|
edges, which can be considered as coincident.
|
||||||
|
|
||||||
@ -41,12 +41,12 @@ The selected edges will be marked in white.
|
|||||||
theTolerance is a maximum distance between two edges, which can
|
theTolerance is a maximum distance between two edges, which can
|
||||||
be considered as coincident. The \b Result will be a list of \b
|
be considered as coincident. The \b Result will be a list of \b
|
||||||
GEOM_Objects (edges), containing one sub-shape per each detected set of
|
GEOM_Objects (edges), containing one sub-shape per each detected set of
|
||||||
coincident sub-shapes. For example if there are two coincident edges
|
coincident sub-shapes. For example, if there are two coincident edges
|
||||||
in selected shapes, the result list contains one of the two coincident edges.
|
in the selected shapes, the result list contains one of the two coincident edges.
|
||||||
|
|
||||||
<em>geompy.MakeGlueEdgesByList( theShapes, theTolerance, theEdges )</em>,
|
<em>geompy.MakeGlueEdgesByList( theShapes, theTolerance, theEdges )</em>,
|
||||||
\n where \em theShape is either a list or compound of shapes to be glued, \em
|
\n where \em theShape is a list or compound of shapes to be glued,
|
||||||
theTolerance is a maximum distance between two edges, which can
|
\em theTolerance is a maximum distance between two edges, which can
|
||||||
be considered as coincident, \em theEdges is a list of
|
be considered as coincident, \em theEdges is a list of
|
||||||
edges to be glued.
|
edges to be glued.
|
||||||
|
|
||||||
|
@ -41,12 +41,12 @@ The selected faces will be marked in white.
|
|||||||
|
|
||||||
When the faces are glued their edges are glued as well. By default, other
|
When the faces are glued their edges are glued as well. By default, other
|
||||||
edges are not glued. To force gluing of all edges, check <b>Glue all coincident edges</b>
|
edges are not glued. To force gluing of all edges, check <b>Glue all coincident edges</b>
|
||||||
checkbox.
|
check-box.
|
||||||
|
|
||||||
\n <b>TUI Commands:</b>
|
\n <b>TUI Commands:</b>
|
||||||
|
|
||||||
<em>geompy.GetGlueFaces( theShapes, theTolerance )</em>,
|
<em>geompy.GetGlueFaces( theShapes, theTolerance )</em>,
|
||||||
\n where \em theShapes is either a list or compound of shapes to be glued, \em
|
\n where \em theShapes is a list or compound of shapes to be glued, \em
|
||||||
theTolerance is a maximum distance between two faces, which can
|
theTolerance is a maximum distance between two faces, which can
|
||||||
be considered as coincident. The \b Result will be a list of \b
|
be considered as coincident. The \b Result will be a list of \b
|
||||||
GEOM_Objects (faces), containing one sub-shape per each detected set of
|
GEOM_Objects (faces), containing one sub-shape per each detected set of
|
||||||
|
@ -12,11 +12,11 @@ In this dialog:
|
|||||||
- Click on the "selection" button and select an object to inspect in the Object Browser or in the viewer.
|
- Click on the "selection" button and select an object to inspect in the Object Browser or in the viewer.
|
||||||
- Show/hide sub-shape(s) in the 3D viewer, by pressing “eye” icon in the first column of the tree view.
|
- Show/hide sub-shape(s) in the 3D viewer, by pressing “eye” icon in the first column of the tree view.
|
||||||
- Show/hide all sub-shapes in the 3D viewer, by pressing “eye” icon in the first column of the tree view header.
|
- Show/hide all sub-shapes in the 3D viewer, by pressing “eye” icon in the first column of the tree view header.
|
||||||
- Rename selected sub-shape by double-clicking on the item or pressing <F2> key.
|
- Rename the selected sub-shape by double-clicking on the item or pressing <F2> key.
|
||||||
- Show selected sub-shape(s) in the 3D viewer by pressing <b>Show Selected</b> button.
|
- Show the selected sub-shape(s) in the 3D viewer by pressing <b>Show Selected</b> button.
|
||||||
- Show selected sub-shape(s) in the 3D viewer and erase all currently shown objects by pressing <b>Show Only Selected</b> button.
|
- Show the selected sub-shape(s) in the 3D viewer and erase all currently shown objects by pressing <b>Show Only Selected</b> button.
|
||||||
- Hide selected sub-shape(s) from the 3D viewer by pressing <b>Hide Selected</b> button.
|
- Hide the selected sub-shape(s) from the 3D viewer by pressing <b>Hide Selected</b> button.
|
||||||
- Publish selected sub-shapes in the study, by pressing <b>Publish Selected</b> button.
|
- Publish the selected sub-shapes in the study, by pressing <b>Publish Selected</b> button.
|
||||||
- Close dialog box, by pressing <b>Close</b> button.
|
- Close dialog box, by pressing <b>Close</b> button.
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
@ -14,24 +14,31 @@ To make a projection it is necessary to define:
|
|||||||
- \b Object to be projected. It can be either a planar wire or a face;
|
- \b Object to be projected. It can be either a planar wire or a face;
|
||||||
- \b Radius of the cylinder;
|
- \b Radius of the cylinder;
|
||||||
- <b>Starting angle</b> from the cylinder's X axis around Z axis. This is
|
- <b>Starting angle</b> from the cylinder's X axis around Z axis. This is
|
||||||
the angle of the projection starting.
|
the angle of the projection start.
|
||||||
- <b>Length angle</b> in which to project the total length of
|
- <b>Length angle</b> where the total length of
|
||||||
the wire. If it is unchecked the projection is not scaled and natural
|
the wire should be projected. If it is unchecked the projection is not scaled and the natural
|
||||||
wire length is kept for the projection.
|
wire length is kept for the projection.
|
||||||
|
- <b>Rotation angle</b> the desired angle between the tangent vector to
|
||||||
\ref restore_presentation_parameters_page "Advanced options".
|
the first curve at the first point of the theObject's projection in 2D space
|
||||||
|
and U-direction of cylinder's 2D space.
|
||||||
|
- \ref restore_presentation_parameters_page "Advanced options".
|
||||||
|
|
||||||
\image html proj_on_cyl_dlg.png
|
\image html proj_on_cyl_dlg.png
|
||||||
|
|
||||||
|
\n The following figure explains meaning of each input angle:
|
||||||
|
|
||||||
|
\image html proj_on_cyl_angles.png "Input angles of projection on the cylinder"
|
||||||
|
|
||||||
\n <b>Example:</b>
|
\n <b>Example:</b>
|
||||||
|
|
||||||
\image html proj_on_cyl_preview.png "The curve (in red) and its projection on the cylinder"
|
\image html proj_on_cyl_preview.png "The curve (in red) and its projection on the cylinder"
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.MakeProjectionOnCylinder(theObject, theRadius,
|
\n <b>TUI Command:</b> <em>geompy.MakeProjectionOnCylinder(theObject, theRadius,
|
||||||
theStartAngle=0.0, theAngleLength=-1.0),</em>
|
theStartAngle=0.0, theAngleLength=-1.0, theAngleRotation=0.0),</em>
|
||||||
where \em theObject is a shape which has to be projected, \em theRadius
|
where \em theObject is a shape to be projected, \em theRadius
|
||||||
is a cylinder radius, \em theStartAngle the starting angle of projection in
|
is a cylinder radius, \em theStartAngle is the starting angle of projection in
|
||||||
radians, \em theAngleLength the projection length angle in radians.
|
radians, \em theAngleLength the projection length angle in radians,
|
||||||
|
\em theAngleRotation projection rotation angle in radians.
|
||||||
The \em Result will be a \em GEOM_Object.
|
The \em Result will be a \em GEOM_Object.
|
||||||
|
|
||||||
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
||||||
|
@ -3,18 +3,18 @@
|
|||||||
\page sewing_operation_page Sewing
|
\page sewing_operation_page Sewing
|
||||||
|
|
||||||
\b Sewing operation allows uniting several faces (possibly contained
|
\b Sewing operation allows uniting several faces (possibly contained
|
||||||
in a shell, solid or compound) into one shell while geometrically
|
in a shell, solid or compound) into one shell. Geometrically
|
||||||
coincident (within a specified tolerance) edges (or parts of edges) of
|
coincident (within a specified tolerance) edges (or parts of edges) of
|
||||||
different faces are replaced by one edge thus producing a shell of
|
different faces are replaced by one edge thus producing a shell of
|
||||||
faces with shared boundaries.<p>
|
faces with shared boundaries.<p>
|
||||||
This operation is similar to <b>New Entity - > Build - > Shell</b>
|
This operation is similar to <b>New Entity - > Build - > Shell</b>
|
||||||
operation, the difference is that with \b Sewing you can specify the
|
operation, the difference is that with \b Sewing you can specify the
|
||||||
tolerance and can get a non-manifold result. <p>
|
tolerance and get a non-manifold result. <p>
|
||||||
Possibility to create a non-manifold shell can be used e.g. to create a
|
The possibility to create a non-manifold shell can be used e.g. to create a
|
||||||
shell forming several closed domains and then to create several solids
|
shell forming several closed domains and then to create several solids
|
||||||
with shared boundaries from this shell.
|
with shared boundaries from this shell.
|
||||||
|
|
||||||
\note Geometrically coincident faces (or part of faces) won't be
|
\note Geometrically coincident faces (or parts of faces) will not be
|
||||||
replaced by one face during \b Sewing.
|
replaced by one face during \b Sewing.
|
||||||
|
|
||||||
To produce a \b Sewing operation in the <b>Main Menu</b> select <b>Repair - > Sewing</b>.
|
To produce a \b Sewing operation in the <b>Main Menu</b> select <b>Repair - > Sewing</b>.
|
||||||
|
@ -56,22 +56,22 @@ merge with neighboring edges.</li>
|
|||||||
<li><b>3D Tolerance</b> (DropSmallEdges.Tolerance3d) - defines minimum
|
<li><b>3D Tolerance</b> (DropSmallEdges.Tolerance3d) - defines minimum
|
||||||
possible distance between two parallel edges.</li>
|
possible distance between two parallel edges.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<li><b>Drop Small Solids</b> (DropSmallSolids) - either removes small
|
<li><b>Drop Small Solids</b> (DropSmallSolids) - removes small
|
||||||
solids or merges them with neighboring ones.</li>
|
solids or merges them with neighboring ones.</li>
|
||||||
<ul>
|
<ul>
|
||||||
<li><b>Width factor tol.</b> (DropSmallSolids.WidthFactorThreshold) -
|
<li><b>Width factor tol.</b> (DropSmallSolids.WidthFactorThreshold) -
|
||||||
defines maximum value of <em>2V/S</em> of a solid which is
|
defines the maximum value of <em>2V/S</em> of a solid, which is
|
||||||
considered small, where \a V is volume and \a S is surface area of
|
considered small, where \a V is the volume and \a S is the surface area of
|
||||||
the solid.</li>
|
the solid.</li>
|
||||||
<li><b>Volume tol.</b> (DropSmallSolids.VolumeThreshold) - defines
|
<li><b>Volume tol.</b> (DropSmallSolids.VolumeThreshold) - defines
|
||||||
maximum volume of a solid which is considered small.</li>
|
the maximum volume of a solid, which is considered small.</li>
|
||||||
<li><b>To merge solids</b> (DropSmallSolids.MergeSolids) - if
|
<li><b>To merge solids</b> (DropSmallSolids.MergeSolids) - if
|
||||||
activated, small solids are removed, else small solids are merged to
|
activated, small solids are removed, else small solids are merged to
|
||||||
adjacent non-small solids or left untouched if cannot be merged.
|
adjacent non-small solids or left untouched if they cannot be merged.
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
If the both tolerances are activated a solid is considered small if
|
If the both tolerances are activated a solid is considered small if
|
||||||
it meets the both criteria.
|
it meets both criteria.
|
||||||
<li><b>Split Angle</b> (SplitAngle) - splits faces based on conical
|
<li><b>Split Angle</b> (SplitAngle) - splits faces based on conical
|
||||||
surfaces, surfaces of revolution and cylindrical surfaces in segments
|
surfaces, surfaces of revolution and cylindrical surfaces in segments
|
||||||
using a certain angle.</li>
|
using a certain angle.</li>
|
||||||
|
30
doc/salome/gui/GEOM/input/shape_statistics_operation.doc
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
/*!
|
||||||
|
|
||||||
|
\page shape_statistics_operation_page Shape Statistics
|
||||||
|
|
||||||
|
This operation allows plotting a distribution histogram for the numerical parameters and creating the corresponding geometrical groups of the given shape.
|
||||||
|
|
||||||
|
To call <b>Shape Statistics</b> dialog box, in the <b>Main Menu</b> select <b>Inspection - > Shape Statistics</b>.
|
||||||
|
|
||||||
|
\image html shape_statistics.png
|
||||||
|
|
||||||
|
In this dialog:
|
||||||
|
- "Selected objects" standard selection box allows selecting one or more geometrical objects.
|
||||||
|
|
||||||
|
- "Type" combo-box with the following items: "Edges length", "Faces area", "Solids volume".
|
||||||
|
\note "Type" combo-box includes only parameters applied to the currently selected shape (e.g. "Solids volume" will not be available for face or shell being selected); multiple selection is processed correspondingly (i.e. only types applicable for all selected shapes will be available).
|
||||||
|
|
||||||
|
- "Number of intervals" spin box is used to specify number of distribution histogram ranges.
|
||||||
|
|
||||||
|
- "Scalar range" checkable group box that, when switched ON, allows specifying custom values range used for plotting and creating groups.
|
||||||
|
\note By default, "Scalar range" controls is empty; pressing "Compute" button allows automatic computing initial range of the chosen parameter. This is needed as computation of the parameters range can be time-consuming for large or complex models. In case of multiple selection, scalar range is computed as common from all selected shapes.
|
||||||
|
|
||||||
|
- "Plot" button opens or uses an opened Plot2d viewer and plots the distribution histogram for the selected shape(s).
|
||||||
|
|
||||||
|
- "Create groups" button allows creating a groups according to the currently specified parameters. The groups names will include numerical values of the range, e.g. "Edges_length_0-20", "Edges_length_20-40", etc. Empty groups are not created.
|
||||||
|
|
||||||
|
- Close dialog box, by pressing <b>Close</b> button.
|
||||||
|
|
||||||
|
\note This functionality is available only if GUI module is builded with Plot 2D Viewer (set option SALOME_USE_PLOT2DVIEWER to ON when building GUI module).
|
||||||
|
|
||||||
|
*/
|
@ -15,22 +15,22 @@ Shared Shapes.</b> The following dialog box will appear.
|
|||||||
|
|
||||||
In this dialog:
|
In this dialog:
|
||||||
- <b>Name</b> is the base name of the resulting shapes.
|
- <b>Name</b> is the base name of the resulting shapes.
|
||||||
- <b>Shapes</b> are the shapes to fing shared sub-shapes of.
|
- <b>Shapes</b> are the shapes whose shared sub-shapes should be found.
|
||||||
- <b>Sub-shapes Type</b> is the type of required sub-shapes.
|
- <b>Sub-shapes Type</b> is the type of required sub-shapes.
|
||||||
- <b>Shared by all</b> option specifies what type of shared sub-shapes should be checked:
|
- <b>Shared by all</b> option specifies what type of shared sub-shapes should be checked:
|
||||||
- \b On: causes to search sub-shapes from the first input shape shared with all other input shapes;
|
- \b On: searches for sub-shapes from the first input shape shared with all other input shapes;
|
||||||
- \b Off: causes to search sub-shapes shared between couples of input shapes.
|
- \b Off: searches for sub-shapes shared between couples of input shapes.
|
||||||
|
|
||||||
\note For the case when "Shared by all" option is switched off - if an input list of shapes
|
\note For the case when "Shared by all" option is switched off - if an input list of shapes
|
||||||
contains single compound, the sub-shapes shared between all possible couples of its top-level shapes
|
contains a single compound, the sub-shapes shared between all possible couples of its top-level shapes
|
||||||
are searched; otherwise, only sub-shapes that are shared between first input shape and all rest input
|
are searched for; otherwise, only sub-shapes that are shared between the first input shape and
|
||||||
shapes are searched.
|
all other input shapes are searched.
|
||||||
|
|
||||||
<b>Advanced options:</b> \ref preview_anchor "Preview"
|
<b>Advanced options:</b> \ref preview_anchor "Preview"
|
||||||
|
|
||||||
<b>TUI Command:</b> <em> geompy.GetSharedShapesMulti( Shapes, Type ),</em>
|
<b>TUI Command:</b> <em> geompy.GetSharedShapesMulti( Shapes, Type ),</em>
|
||||||
<br> where \em Shapes is a list or compound of shapes to fing shared sub-
|
<br> where \em Shapes is a list or compound of shapes, whose shared sub-
|
||||||
shapes of and \em Type is the type of required sub-shapes.
|
shapes should be found and \em Type is the type of required sub-shapes.
|
||||||
|
|
||||||
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
Our <b>TUI Scripts</b> provide you with useful examples of the use of
|
||||||
Get Shared Shapes functionality:
|
Get Shared Shapes functionality:
|
||||||
|
@ -4,37 +4,33 @@
|
|||||||
|
|
||||||
\tableofcontents
|
\tableofcontents
|
||||||
|
|
||||||
This document determines the range of numbers (tolerances, locations
|
In Salome and Open CASCADE Technology (OCCT), which is a modeling core
|
||||||
and sizes) that are to be taken into account for any 3D model design
|
of Salome %GEOM module, any model has its location in the 3D-space and size.
|
||||||
in Salome. Although it is not obligatory to create models within this range,
|
|
||||||
algorithms can fail or return unexpected result in this case.
|
This document defines the range of values (tolerances, locations
|
||||||
|
and sizes) that should be taken into account for any 3D model design.
|
||||||
|
|
||||||
This document refers mainly to Open CASCADE Technology (OCCT). However it
|
It is not obligatory to create models within this range,
|
||||||
concerns Salome as well as OCCT is a modeling core of Salome %GEOM module.
|
however, algorithms can fail or return unexpected results if the
|
||||||
|
recommendations are not followed.
|
||||||
Any model in 3D-space has its location and sizes. The last two things in Salome
|
|
||||||
and OCCT are represented by the double precision floating point numbers.
|
|
||||||
|
|
||||||
The goal of the document is to define the range of numbers that can be used in
|
|
||||||
modeling algorithms provided by Salome and Open CASCADE Technology.
|
|
||||||
|
|
||||||
\section sec1 Maximal Size of the Model
|
\section sec1 Maximal Size of the Model
|
||||||
|
|
||||||
The Maximal Size of the model is a number defined as the maximal diameter of
|
The Maximal Size of the model corresponds to the maximal diameter of
|
||||||
enclosed sphere built for the model. In OCCT any model has a location defined
|
enclosed sphere built for the model. In OCCT any model has a location defined
|
||||||
relative the absolute origin. Thus the maximal diameter above should be built
|
relatively to the absolute origin. Thus the maximal diameter should be built
|
||||||
taking into account the model itself and its location.
|
taking into account the model itself and its location.
|
||||||
|
|
||||||
In Open CASCADE there are two tolerances: Tolerance Confusion (TolC)
|
In OCCT there are two tolerances: Tolerance Confusion (TolC)
|
||||||
and Tolerance Angular (TolA) (see OCCT Precision package for more details).
|
and Tolerance Angular (TolA) (see OCCT Precision package for more details).
|
||||||
These values are used for geometric comparisons. They are not used inside
|
These values are used for geometric comparisons. However, they are not used inside
|
||||||
low-level algorithms (intersection for e.g.), where more precise values are
|
low-level algorithms (e.g. intersection), where more precise values are
|
||||||
used instead. The value TolC guarantees that the error associated with
|
used instead. The value TolC guarantees that the error associated with
|
||||||
the computations for given geometric entity is not greater than TolC.
|
the computations for a given geometric entity is not greater than TolC.
|
||||||
|
|
||||||
- TolC - precision value when checking coincidence of two points
|
- TolC - precision value used to check the coincidence of two points
|
||||||
[by default 1.e-7];
|
[by default 1.e-7];
|
||||||
- TolA - precision value when checking the equality of two angles
|
- TolA - precision value used to check the equality of two angles
|
||||||
[by default 1.e-12].
|
[by default 1.e-12].
|
||||||
|
|
||||||
For more information on tolerance definition please see
|
For more information on tolerance definition please see
|
||||||
@ -43,8 +39,8 @@ that are due to modeling errors or inaccuracies of tolerance usage please
|
|||||||
refer to <a href="SALOME_BOA_PA.pdf">Chapter 9.2.2 of the same document</a>.
|
refer to <a href="SALOME_BOA_PA.pdf">Chapter 9.2.2 of the same document</a>.
|
||||||
|
|
||||||
To provide robust geometric modeling the computations should be consistent,
|
To provide robust geometric modeling the computations should be consistent,
|
||||||
i.e. the one tolerance value should be used for all computations. To provide
|
i.e. the one tolerance value should be used for all computations. Thus, the
|
||||||
consistent computations the values TolC and TolA should be consistent:
|
TolC and TolA values should be consistent:
|
||||||
|
|
||||||
<CENTER><B><PRE>Smax = TolC / TolA (1)</PRE></B></CENTER>
|
<CENTER><B><PRE>Smax = TolC / TolA (1)</PRE></B></CENTER>
|
||||||
|
|
||||||
@ -56,16 +52,16 @@ In accordance with <B>(1)</B> the Maximal Size for the Model is [by default]:
|
|||||||
|
|
||||||
\section sec2 Minimal Size of the Model
|
\section sec2 Minimal Size of the Model
|
||||||
|
|
||||||
The Minimal Size of the Model is defined as maximal diameter of enclosed
|
The Minimal Size of the Model is defined as the maximal diameter of enclosed
|
||||||
sphere built for the smallest BRep entity of the Model.
|
sphere built for the smallest BRep entity of the Model.
|
||||||
|
|
||||||
All models in Open CASCADE Technology are represented using double precision
|
All models in OCCT are represented using double precision
|
||||||
floating point numbers. This representation contains approximately 14-16
|
floating point numbers. This representation contains approximately 14-16
|
||||||
significant digits.
|
significant digits.
|
||||||
|
|
||||||
From the experience of using it is considered that the least four significant
|
From the experience, it is considered that the last four significant
|
||||||
digits contain rounding-off errors occurring during the computation. So
|
digits contain rounding-off errors occurring during the computation. So
|
||||||
(taking in account the worst cases), there are ten reliable significant digits
|
(taking into account the worst cases), there are ten reliable significant digits
|
||||||
for double precision floating point numbers. Having the estimation it is
|
for double precision floating point numbers. Having the estimation it is
|
||||||
possible to compute the value of the Minimal size of the model:
|
possible to compute the value of the Minimal size of the model:
|
||||||
|
|
||||||
@ -78,7 +74,7 @@ In accordance with <B>(2)</B> for the default value it will be [by default]:
|
|||||||
\section sec3 Full Range of Sizes
|
\section sec3 Full Range of Sizes
|
||||||
|
|
||||||
The values <B>Smax (2)</B>, <B>Smin (4)</B> are theoretical. Taking into
|
The values <B>Smax (2)</B>, <B>Smin (4)</B> are theoretical. Taking into
|
||||||
account the practical purposes of improving the reliability the lower limit
|
account the practical purposes of improving the reliability, the lower limit
|
||||||
should be restricted by one order. Thus, the full Range of Sizes of the Models
|
should be restricted by one order. Thus, the full Range of Sizes of the Models
|
||||||
is:
|
is:
|
||||||
|
|
||||||
|
@ -21,24 +21,23 @@ In this dialog:
|
|||||||
<ul>
|
<ul>
|
||||||
<li> <b>Source Shape</b> is an object that is a source of non-topological data.</li>
|
<li> <b>Source Shape</b> is an object that is a source of non-topological data.</li>
|
||||||
<li> <b>Destination Shape</b> is a data destination object. </li>
|
<li> <b>Destination Shape</b> is a data destination object. </li>
|
||||||
<li> <b>Type of detection operation</b> is the method to search sub-shapes of
|
<li> <b>Type of detection operation</b> allows choosing how to search sub-shapes of the
|
||||||
<b>Source Shape</b> in <b>Destination Shape</b>. Data are transferred
|
<b>Source Shape</b> in the <b>Destination Shape</b>. The data are transferred
|
||||||
from these corresponding sub-shapes. This is a combo-box with the following
|
from these corresponding sub-shapes. The following methods are possible:
|
||||||
possible values:
|
|
||||||
<ul>
|
<ul>
|
||||||
<li><b>Get In Place</b> - current implementation of Get In Place algorithm
|
<li><b>Get In Place</b> - the current implementation of Get In Place algorithm
|
||||||
(default value).</li>
|
(default value).</li>
|
||||||
<li><b>Get In Place (old)</b> - old implementation of Get In Place
|
<li><b>Get In Place (old)</b> - the old implementation of Get In Place
|
||||||
algorithm.</li>
|
algorithm.</li>
|
||||||
<li><b>Get In Place By History</b> - Get In Place By History algorithm.</li>
|
<li><b>Get In Place By History</b> - Get In Place By History algorithm.</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
To copy data click on \b Apply or <b>Apply and Close</b> button. As the result
|
To copy the data click on \b Apply or <b>Apply and Close</b> button.
|
||||||
it is possible to see how many names and materials are copied as well as
|
It is possible to see how many names and materials are copied as well as
|
||||||
maximum number of names and materials available for copying. This information is
|
the maximum number of names and materials available for copying. This information is
|
||||||
provided on the following message box:
|
provided in the following message box:
|
||||||
|
|
||||||
\image html transfer_data2.png "Transfer Data Information"
|
\image html transfer_data2.png "Transfer Data Information"
|
||||||
|
|
||||||
|
@ -0,0 +1,6 @@
|
|||||||
|
/*!
|
||||||
|
|
||||||
|
\page tui_check_self_intersections_fast_page Detect Self-intersections fast
|
||||||
|
\tui_script{check_self_intersections_fast.py}
|
||||||
|
|
||||||
|
*/
|
@ -19,6 +19,7 @@
|
|||||||
<li>\subpage tui_check_compound_of_blocks_page</li>
|
<li>\subpage tui_check_compound_of_blocks_page</li>
|
||||||
<li>\subpage tui_get_non_blocks_page</li>
|
<li>\subpage tui_get_non_blocks_page</li>
|
||||||
<li>\subpage tui_check_self_intersections_page</li>
|
<li>\subpage tui_check_self_intersections_page</li>
|
||||||
|
<li>\subpage tui_check_self_intersections_fast_page</li>
|
||||||
<li>\subpage tui_fast_intersection_page</li>
|
<li>\subpage tui_fast_intersection_page</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
@ -17,7 +17,10 @@
|
|||||||
\until Detect Self-intersections
|
\until Detect Self-intersections
|
||||||
|
|
||||||
\anchor swig_CheckSelfIntersections
|
\anchor swig_CheckSelfIntersections
|
||||||
\until Detect Fast intersection
|
\until Detect Self-intersections fast
|
||||||
|
|
||||||
|
\anchor swig_CheckSelfIntersectionsFast
|
||||||
|
\until Fast intersection
|
||||||
|
|
||||||
\anchor swig_FastIntersection
|
\anchor swig_FastIntersection
|
||||||
\until WhatIs
|
\until WhatIs
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
<li>\subpage managing_dimensions_page "Dimensions"</li>
|
<li>\subpage managing_dimensions_page "Dimensions"</li>
|
||||||
<li>\subpage whatis_page "WhatIs"</li>
|
<li>\subpage whatis_page "WhatIs"</li>
|
||||||
<li>\subpage inspect_object_operation_page "Inspect Object"</li>
|
<li>\subpage inspect_object_operation_page "Inspect Object"</li>
|
||||||
|
<li>\subpage shape_statistics_operation_page "Shape Statistics"</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
\n To check their integrity:
|
\n To check their integrity:
|
||||||
|
@ -5,13 +5,13 @@
|
|||||||
This operation provides the list of types and quantities of all topological
|
This operation provides the list of types and quantities of all topological
|
||||||
entities, composing the selected geometrical object.
|
entities, composing the selected geometrical object.
|
||||||
|
|
||||||
For the \em COMPOUND or \em COMPSOLID shape, additionally the information about
|
The information about \em COMPOUND or \em COMPSOLID shapes additionally shows
|
||||||
"flat" content is shown - a number of "simple" top-level shapes enclosed into the compound.
|
"flat" content - the number of "simple" top-level shapes enclosed into the compound.
|
||||||
|
|
||||||
\image html measures8.png
|
\image html measures8.png
|
||||||
|
|
||||||
\note This dialog supports navigation through the selectable objects (in OCC 3D viewer only):
|
\note This dialog supports navigation through the selectable objects (in OCC 3D viewer only):
|
||||||
- Scroll mouse wheel with pressed \em Ctrl key or press \em "S", \em "P" keys when input focus is
|
- Scroll mouse wheel with pressed \em Ctrl key or press \em "S", \em "P" keys when the input focus is
|
||||||
in the viewer to navigate between selectable objects.
|
in the viewer to navigate between selectable objects.
|
||||||
- Press left mouse button to select an appropriate object to the dialog box.
|
- Press left mouse button to select an appropriate object to the dialog box.
|
||||||
.
|
.
|
||||||
|
@ -24,7 +24,7 @@ This functionality is available in OCC viewer only.
|
|||||||
|
|
||||||
To create a group of sub-shapes of a geometrical object in the main
|
To create a group of sub-shapes of a geometrical object in the main
|
||||||
menu select <b>New entity > Group > Create</b>
|
menu select <b>New entity > Group > Create</b>
|
||||||
\n The following menu will appear:
|
\n The following dialog box will appear:
|
||||||
|
|
||||||
\image html geomcreategroup.png
|
\image html geomcreategroup.png
|
||||||
|
|
||||||
@ -81,26 +81,31 @@ creation of other groups), or skip it by clicking \b Close button.
|
|||||||
|
|
||||||
\n The Result of the operation will be a \b GEOM_Object.
|
\n The Result of the operation will be a \b GEOM_Object.
|
||||||
|
|
||||||
The \b Filter controls allow to automatically pick up entites which satisfy specified
|
The \b Filter controls allow to automatically pick up entities, which satisfy specified
|
||||||
threshold value(s). The numerical functor for each sub-shape that is compared with
|
threshold value(s). The numerical functor for each sub-shape that is compared with
|
||||||
threshold value(s) is computed according to the shape's topological properties:
|
threshold value(s) is computed according to the shape's topological properties:
|
||||||
- length for edges and wires
|
- length for edges and wires;
|
||||||
- area for faces and shells
|
- area for faces and shells;
|
||||||
- volume for solids, compounds, compsolids
|
- volume for solids, compounds, compsolids.
|
||||||
|
|
||||||
Filtering capabilities are not available for vertices.
|
Filtering capabilities are not available for vertices.
|
||||||
|
|
||||||
In order to filter out some entities:
|
In order to filter out some entities:
|
||||||
- Activate one or two filtering controls by switching on corresponding check boxes;
|
- Activate one or two filtering controls by switching on the corresponding check boxes;
|
||||||
- Select required threshold comparator type; the following choices are available:
|
- Select the required threshold comparator type; the following choices are available:
|
||||||
- <b>Less Than</b> or <b>Equal or Less Than</b> for the first comparator;
|
- <b>Less Than</b> or <b>Equal or Less Than</b> for the first comparator;
|
||||||
- <b>Greater Than</b> or <b>Equal or Greater Than</b> for the second comparator;
|
- <b>Greater Than</b> or <b>Equal or Greater Than</b> for the second comparator;
|
||||||
- Enter required threshold value (values);
|
- Enter the required threshold value (values);
|
||||||
- Press \b Apply button in the \b Filter group.
|
- Press \b Apply button in the \b Filter group.
|
||||||
|
|
||||||
The entities which satisfy entered filtering parameters will be automatically highlighted
|
The entities, which satisfy the entered filtering parameters, will be automatically highlighted
|
||||||
in the 3D viewer.
|
in the 3D viewer.
|
||||||
|
|
||||||
|
\b Plot button into "Filter" group box provides an access
|
||||||
|
to the \ref shape_statistics_operation_page "Shape Statistics" functionality with simplified look-n-feel:
|
||||||
|
|
||||||
|
\image html shape_statistics_simple.png
|
||||||
|
|
||||||
\n <b>TUI Command:</b> <em>geompy.CreateGroup(MainShape,
|
\n <b>TUI Command:</b> <em>geompy.CreateGroup(MainShape,
|
||||||
ShapeType),</em> where MainShape is a shape for which the group is
|
ShapeType),</em> where MainShape is a shape for which the group is
|
||||||
created, ShapeType is a type of shapes in the created group.
|
created, ShapeType is a type of shapes in the created group.
|
||||||
|
@ -732,10 +732,13 @@ module GEOM
|
|||||||
* Create a point, corresponding to the given parameter on the given curve.
|
* Create a point, corresponding to the given parameter on the given curve.
|
||||||
* \param theRefCurve The referenced curve.
|
* \param theRefCurve The referenced curve.
|
||||||
* \param theParameter Value of parameter on the referenced curve.
|
* \param theParameter Value of parameter on the referenced curve.
|
||||||
|
* \param takeOrientationIntoAccount flag that tells if it is necessary
|
||||||
|
* to take the curve's orientation into account.
|
||||||
* \return New GEOM_Object, containing the created point.
|
* \return New GEOM_Object, containing the created point.
|
||||||
*/
|
*/
|
||||||
GEOM_Object MakePointOnCurve (in GEOM_Object theRefCurve,
|
GEOM_Object MakePointOnCurve (in GEOM_Object theRefCurve,
|
||||||
in double theParameter);
|
in double theParameter,
|
||||||
|
in boolean takeOrientationIntoAccount);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Create a point, corresponding to the given length on the given curve.
|
* \brief Create a point, corresponding to the given length on the given curve.
|
||||||
@ -1439,13 +1442,17 @@ module GEOM
|
|||||||
* to project the total length of the wire. If it is negative the
|
* to project the total length of the wire. If it is negative the
|
||||||
* projection is not scaled and natural wire length is kept for
|
* projection is not scaled and natural wire length is kept for
|
||||||
* the projection.
|
* the projection.
|
||||||
|
* \param theAngleRotation the desired angle between the tangent vector
|
||||||
|
* to the first curve at the first point of the theObject's
|
||||||
|
* projection in 2D space and U-direction of cylinder's 2D space.
|
||||||
* \return A wire or a face or a compound of faces that represents a
|
* \return A wire or a face or a compound of faces that represents a
|
||||||
* projection of the source shape onto a cylinder.
|
* projection of the source shape onto a cylinder.
|
||||||
*/
|
*/
|
||||||
GEOM_Object MakeProjectionOnCylinder (in GEOM_Object theObject,
|
GEOM_Object MakeProjectionOnCylinder (in GEOM_Object theObject,
|
||||||
in double theRadius,
|
in double theRadius,
|
||||||
in double theStartAngle,
|
in double theStartAngle,
|
||||||
in double theAngleLength);
|
in double theAngleLength,
|
||||||
|
in double theAngleRotation);
|
||||||
};
|
};
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@ -1801,9 +1808,13 @@ module GEOM
|
|||||||
* should be equal to number of bases or list of locations can be empty.
|
* should be equal to number of bases or list of locations can be empty.
|
||||||
* \param thePath - Path shape to extrude the base shape along it.
|
* \param thePath - Path shape to extrude the base shape along it.
|
||||||
* \param theWithContact - the mode defining that the section is translated to be in
|
* \param theWithContact - the mode defining that the section is translated to be in
|
||||||
* contact with the spine.
|
* contact with the spine. Ignored if IsBySteps is set.
|
||||||
* \param theWithCorrection - defining that the section is rotated to be
|
* \param theWithCorrection - defining that the section is rotated to be
|
||||||
* orthogonal to the spine tangent in the correspondent point
|
* orthogonal to the spine tangent in
|
||||||
|
* the correspondent point. Ignored if IsBySteps is set.
|
||||||
|
* \param IsBySteps - flag that tells if the result should be created
|
||||||
|
* step by step or as a whole. If IsBySteps is set no correction
|
||||||
|
* of bases is allowed.
|
||||||
* \param IsGenerateGroups flag that tells if it is necessary to
|
* \param IsGenerateGroups flag that tells if it is necessary to
|
||||||
* return groups (true) or not (false).
|
* return groups (true) or not (false).
|
||||||
* \return The list of objects. The first one is a result pipe,
|
* \return The list of objects. The first one is a result pipe,
|
||||||
@ -1816,6 +1827,7 @@ module GEOM
|
|||||||
in GEOM_Object thePath,
|
in GEOM_Object thePath,
|
||||||
in boolean theWithContact ,
|
in boolean theWithContact ,
|
||||||
in boolean theWithCorrection,
|
in boolean theWithCorrection,
|
||||||
|
in boolean IsBySteps,
|
||||||
in boolean IsGenerateGroups);
|
in boolean IsGenerateGroups);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
@ -4204,6 +4216,7 @@ module GEOM
|
|||||||
// VERTEX
|
// VERTEX
|
||||||
VERTEX,
|
VERTEX,
|
||||||
// ADVANCED shapes
|
// ADVANCED shapes
|
||||||
|
LCS,
|
||||||
/*! all advanced shapes (temporary implementation) */
|
/*! all advanced shapes (temporary implementation) */
|
||||||
ADVANCED
|
ADVANCED
|
||||||
};
|
};
|
||||||
@ -4448,6 +4461,21 @@ module GEOM
|
|||||||
in long theCheckLevel,
|
in long theCheckLevel,
|
||||||
out ListOfLong theIntersections);
|
out ListOfLong theIntersections);
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* \brief Detect self-intersections of the given shape with algorithm based on mesh intersections.
|
||||||
|
* \param theShape Shape to check validity of.
|
||||||
|
* \param theDeflection Linear deflection coefficient that specifies quality of tesselation.
|
||||||
|
* \param theTolerance Specifies a distance between sub-shapes used for detecting gaps:
|
||||||
|
* - if \a theTolerance <= 0, algorithm detects intersections
|
||||||
|
* - if \a theTolerance > 0, algorithm detects gaps
|
||||||
|
* \param theIntersections Output. List of intersected sub-shapes IDs, it contains pairs of IDs.
|
||||||
|
* \return TRUE, if the shape does not have any self-intersections.
|
||||||
|
*/
|
||||||
|
boolean CheckSelfIntersectionsFast (in GEOM_Object theShape,
|
||||||
|
in float theDeflection,
|
||||||
|
in double theTolerance,
|
||||||
|
out ListOfLong theIntersections);
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Detect intersections of the given shapes with algorithm based on mesh intersections.
|
* \brief Detect intersections of the given shapes with algorithm based on mesh intersections.
|
||||||
* \param theShape1 First source object
|
* \param theShape1 First source object
|
||||||
|
@ -35,6 +35,7 @@ SET( _res_files
|
|||||||
GEOM.config
|
GEOM.config
|
||||||
GEOMDS_Resources
|
GEOMDS_Resources
|
||||||
ShHealing
|
ShHealing
|
||||||
|
Y14.5M-2009.ttf
|
||||||
3dsketch.png
|
3dsketch.png
|
||||||
isoline.png
|
isoline.png
|
||||||
isoline_v.png
|
isoline_v.png
|
||||||
@ -113,6 +114,7 @@ SET( _res_files
|
|||||||
fuse_collinear_edges.png
|
fuse_collinear_edges.png
|
||||||
geometry.png
|
geometry.png
|
||||||
import_picture.png
|
import_picture.png
|
||||||
|
import.png
|
||||||
limit_tolerance.png
|
limit_tolerance.png
|
||||||
line.png
|
line.png
|
||||||
line2points.png
|
line2points.png
|
||||||
|
@ -92,12 +92,13 @@
|
|||||||
<!-- Dimension presentation properties -->
|
<!-- Dimension presentation properties -->
|
||||||
<parameter name="dimensions_color" value="#ffffff" />
|
<parameter name="dimensions_color" value="#ffffff" />
|
||||||
<parameter name="dimensions_line_width" value="1" />
|
<parameter name="dimensions_line_width" value="1" />
|
||||||
<parameter name="dimensions_font_height" value="10" />
|
<parameter name="dimensions_font" value="Y14.5M-2009,14" />
|
||||||
<parameter name="dimensions_arrow_length" value="5" />
|
<parameter name="dimensions_arrow_length" value="5" />
|
||||||
<parameter name="dimensions_show_units" value="0" />
|
<parameter name="dimensions_show_units" value="0" />
|
||||||
<parameter name="dimensions_length_units" value="m" />
|
<parameter name="dimensions_length_units" value="m" />
|
||||||
<parameter name="dimensions_angle_units" value="deg" />
|
<parameter name="dimensions_angle_units" value="deg" />
|
||||||
<parameter name="dimensions_default_flyout" value="20" />
|
<parameter name="dimensions_default_flyout" value="20" />
|
||||||
|
<parameter name="dimensions_use_text3d" value="0" />
|
||||||
|
|
||||||
<!-- Scalar bar for field step presentation -->
|
<!-- Scalar bar for field step presentation -->
|
||||||
<parameter name="scalar_bar_x_position" value="0.05" />
|
<parameter name="scalar_bar_x_position" value="0.05" />
|
||||||
|
BIN
resources/Y14.5M-2009.ttf
Normal file
BIN
resources/import.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
@ -335,11 +335,11 @@ void AdvancedGUI_DividedDiskDlg::SetEditCurrentArgument()
|
|||||||
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
|
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
|
||||||
if (myEditCurrentArgument == GroupPntVecR->LineEdit2) {
|
if (myEditCurrentArgument == GroupPntVecR->LineEdit2) {
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE);
|
localSelection(TopAbs_EDGE);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
}
|
}
|
||||||
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
this, SLOT(SelectionIntoArgument()));
|
this, SLOT(SelectionIntoArgument()));
|
||||||
|
@ -642,7 +642,7 @@ void AdvancedGUI_PipeTShapeDlg::SetEditCurrentArgument()
|
|||||||
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
|
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
|
||||||
//globalSelection(GEOM_POINT);
|
//globalSelection(GEOM_POINT);
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
this, SLOT(SelectionIntoArgument()));
|
this, SLOT(SelectionIntoArgument()));
|
||||||
}
|
}
|
||||||
|
@ -120,7 +120,7 @@ void AdvancedGUI_SmoothingSurfaceDlg::Init()
|
|||||||
showOnlyPreviewControl();
|
showOnlyPreviewControl();
|
||||||
|
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
//@@ initialize dialog box widgets here @@//
|
//@@ initialize dialog box widgets here @@//
|
||||||
|
|
||||||
// Signal/slot connections
|
// Signal/slot connections
|
||||||
@ -163,7 +163,7 @@ bool AdvancedGUI_SmoothingSurfaceDlg::ClickOnApply()
|
|||||||
|
|
||||||
initName();
|
initName();
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -175,7 +175,7 @@ void AdvancedGUI_SmoothingSurfaceDlg::ActivateThisDialog()
|
|||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
//displayPreview();
|
//displayPreview();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -363,6 +363,6 @@ void AdvancedGUI_SmoothingSurfaceDlg::SetEditCurrentArgument()
|
|||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
SelectionIntoArgument();
|
SelectionIntoArgument();
|
||||||
}
|
}
|
||||||
|
@ -36,10 +36,13 @@
|
|||||||
#include "GEOM_Operation.h"
|
#include "GEOM_Operation.h"
|
||||||
#include "GEOMBase.h"
|
#include "GEOMBase.h"
|
||||||
#include "GEOM_Displayer.h"
|
#include "GEOM_Displayer.h"
|
||||||
|
#include "GEOM_GenericObjPtr.h"
|
||||||
|
|
||||||
#include <SALOMEconfig.h>
|
#include <SALOMEconfig.h>
|
||||||
#include CORBA_SERVER_HEADER(BREPPlugin)
|
#include CORBA_SERVER_HEADER(BREPPlugin)
|
||||||
|
|
||||||
|
typedef GEOM::GenericObjPtr<GEOM::IBREPOperations> BREPOpPtr;
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
// function : BREPPlugin_GUI()
|
// function : BREPPlugin_GUI()
|
||||||
// purpose : Constructor
|
// purpose : Constructor
|
||||||
@ -111,8 +114,8 @@ bool BREPPlugin_GUI::importBREP( SUIT_Desktop* parent )
|
|||||||
|
|
||||||
SALOMEDS::Study_var dsStudy = GeometryGUI::ClientStudyToStudy( study->studyDS() );
|
SALOMEDS::Study_var dsStudy = GeometryGUI::ClientStudyToStudy( study->studyDS() );
|
||||||
GEOM::GEOM_IOperations_var op = GeometryGUI::GetGeomGen()->GetPluginOperations( dsStudy->StudyId(), "BREPPluginEngine" );
|
GEOM::GEOM_IOperations_var op = GeometryGUI::GetGeomGen()->GetPluginOperations( dsStudy->StudyId(), "BREPPluginEngine" );
|
||||||
GEOM::IBREPOperations_var brepOp = GEOM::IBREPOperations::_narrow( op );
|
BREPOpPtr brepOp = GEOM::IBREPOperations::_narrow( op );
|
||||||
if ( CORBA::is_nil( brepOp ) ) return false;
|
if ( brepOp.isNull() ) return false;
|
||||||
|
|
||||||
QStringList fileNames = app->getOpenFileNames( SUIT_FileDlg::getLastVisitedPath().isEmpty() ? QDir::currentPath() : QString(""),
|
QStringList fileNames = app->getOpenFileNames( SUIT_FileDlg::getLastVisitedPath().isEmpty() ? QDir::currentPath() : QString(""),
|
||||||
tr( "BREP_FILES" ),
|
tr( "BREP_FILES" ),
|
||||||
@ -126,7 +129,7 @@ bool BREPPlugin_GUI::importBREP( SUIT_Desktop* parent )
|
|||||||
foreach( QString fileName, fileNames )
|
foreach( QString fileName, fileNames )
|
||||||
{
|
{
|
||||||
SUIT_OverrideCursor wc;
|
SUIT_OverrideCursor wc;
|
||||||
GEOM_Operation transaction( app, brepOp.in() );
|
GEOM_Operation transaction( app, brepOp.get() );
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@ -145,6 +148,7 @@ bool BREPPlugin_GUI::importBREP( SUIT_Desktop* parent )
|
|||||||
entryList.append( so->GetID() );
|
entryList.append( so->GetID() );
|
||||||
transaction.commit();
|
transaction.commit();
|
||||||
GEOM_Displayer( study ).Display( main.in() );
|
GEOM_Displayer( study ).Display( main.in() );
|
||||||
|
main->UnRegister();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -183,8 +187,8 @@ bool BREPPlugin_GUI::exportBREP( SUIT_Desktop* parent )
|
|||||||
|
|
||||||
SALOMEDS::Study_var dsStudy = GeometryGUI::ClientStudyToStudy( study->studyDS() );
|
SALOMEDS::Study_var dsStudy = GeometryGUI::ClientStudyToStudy( study->studyDS() );
|
||||||
GEOM::GEOM_IOperations_var op = GeometryGUI::GetGeomGen()->GetPluginOperations( dsStudy->StudyId(), "BREPPluginEngine" );
|
GEOM::GEOM_IOperations_var op = GeometryGUI::GetGeomGen()->GetPluginOperations( dsStudy->StudyId(), "BREPPluginEngine" );
|
||||||
GEOM::IBREPOperations_var brepOp = GEOM::IBREPOperations::_narrow( op );
|
BREPOpPtr brepOp = GEOM::IBREPOperations::_narrow( op );
|
||||||
if ( CORBA::is_nil( brepOp ) ) return false;
|
if ( brepOp.isNull() ) return false;
|
||||||
|
|
||||||
LightApp_SelectionMgr* sm = app->selectionMgr();
|
LightApp_SelectionMgr* sm = app->selectionMgr();
|
||||||
if ( !sm ) return false;
|
if ( !sm ) return false;
|
||||||
@ -212,7 +216,7 @@ bool BREPPlugin_GUI::exportBREP( SUIT_Desktop* parent )
|
|||||||
|
|
||||||
SUIT_OverrideCursor wc;
|
SUIT_OverrideCursor wc;
|
||||||
|
|
||||||
GEOM_Operation transaction( app, brepOp.in() );
|
GEOM_Operation transaction( app, brepOp.get() );
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@ -330,7 +330,7 @@ void BasicGUI_ArcDlg::SelectionIntoArgument()
|
|||||||
void BasicGUI_ArcDlg::SetEditCurrentArgument()
|
void BasicGUI_ArcDlg::SetEditCurrentArgument()
|
||||||
{
|
{
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
|
|
||||||
QPushButton* send = (QPushButton*)sender();
|
QPushButton* send = (QPushButton*)sender();
|
||||||
switch ( getConstructorId() ) {
|
switch ( getConstructorId() ) {
|
||||||
@ -580,7 +580,7 @@ void BasicGUI_ArcDlg::ConstructorsClicked( int constructorId )
|
|||||||
}
|
}
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX ); //Select Vertex on All Shapes
|
localSelection( TopAbs_VERTEX ); //Select Vertex on All Shapes
|
||||||
|
|
||||||
qApp->processEvents();
|
qApp->processEvents();
|
||||||
updateGeometry();
|
updateGeometry();
|
||||||
|
@ -283,7 +283,7 @@ void BasicGUI_CircleDlg::ConstructorsClicked( int constructorId )
|
|||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
|
|
||||||
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged() ),
|
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged() ),
|
||||||
this, SLOT( SelectionIntoArgument() ) );
|
this, SLOT( SelectionIntoArgument() ) );
|
||||||
@ -471,7 +471,7 @@ void BasicGUI_CircleDlg::SetEditCurrentArgument()
|
|||||||
TopAbs_ShapeEnum aNeedType = ( myEditCurrentArgument == GroupPntVecR->LineEdit2 ) ?
|
TopAbs_ShapeEnum aNeedType = ( myEditCurrentArgument == GroupPntVecR->LineEdit2 ) ?
|
||||||
TopAbs_EDGE : TopAbs_VERTEX;
|
TopAbs_EDGE : TopAbs_VERTEX;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), aNeedType );
|
localSelection( aNeedType );
|
||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
// SelectionIntoArgument();
|
// SelectionIntoArgument();
|
||||||
|
@ -280,15 +280,15 @@ void BasicGUI_CurveDlg::SetEditCurrentArgument()
|
|||||||
|
|
||||||
if (sender() == myGroupPoints->PushButton1) {
|
if (sender() == myGroupPoints->PushButton1) {
|
||||||
myEditCurrentArgument = myGroupPoints->LineEdit1;
|
myEditCurrentArgument = myGroupPoints->LineEdit1;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
}
|
}
|
||||||
else if (sender() == myPushBtnV1) {
|
else if (sender() == myPushBtnV1) {
|
||||||
myEditCurrentArgument = myLineEditV1;
|
myEditCurrentArgument = myLineEditV1;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE);
|
localSelection(TopAbs_EDGE);
|
||||||
}
|
}
|
||||||
else if (sender() == myPushBtnV2) {
|
else if (sender() == myPushBtnV2) {
|
||||||
myEditCurrentArgument = myLineEditV2;
|
myEditCurrentArgument = myLineEditV2;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE);
|
localSelection(TopAbs_EDGE);
|
||||||
}
|
}
|
||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
|
@ -155,7 +155,7 @@ void BasicGUI_EllipseDlg::Init()
|
|||||||
initName( tr( "GEOM_ELLIPSE" ) );
|
initName( tr( "GEOM_ELLIPSE" ) );
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
|
|
||||||
resize( minimumSizeHint() );
|
resize( minimumSizeHint() );
|
||||||
SelectionIntoArgument();
|
SelectionIntoArgument();
|
||||||
@ -212,7 +212,7 @@ bool BasicGUI_EllipseDlg::ClickOnApply()
|
|||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
displayPreview(true);
|
displayPreview(true);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
@ -303,7 +303,7 @@ void BasicGUI_EllipseDlg::SetEditCurrentArgument()
|
|||||||
myEditCurrentArgument == GroupPoints->LineEdit3 ) ?
|
myEditCurrentArgument == GroupPoints->LineEdit3 ) ?
|
||||||
TopAbs_EDGE : TopAbs_VERTEX;
|
TopAbs_EDGE : TopAbs_VERTEX;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), aNeedType );
|
localSelection( aNeedType );
|
||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
//SelectionIntoArgument();
|
//SelectionIntoArgument();
|
||||||
@ -333,7 +333,7 @@ void BasicGUI_EllipseDlg::ActivateThisDialog()
|
|||||||
myDir.nullify();
|
myDir.nullify();
|
||||||
//globalSelection( GEOM_POINT );
|
//globalSelection( GEOM_POINT );
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
|
@ -220,7 +220,7 @@ void BasicGUI_LineDlg::ConstructorsClicked( int constructorId )
|
|||||||
myEditCurrentArgument == GroupFaces->LineEdit2 ) ?
|
myEditCurrentArgument == GroupFaces->LineEdit2 ) ?
|
||||||
TopAbs_FACE : TopAbs_VERTEX;
|
TopAbs_FACE : TopAbs_VERTEX;
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), aNeedType );
|
localSelection( aNeedType );
|
||||||
|
|
||||||
qApp->processEvents();
|
qApp->processEvents();
|
||||||
updateGeometry();
|
updateGeometry();
|
||||||
@ -318,7 +318,7 @@ void BasicGUI_LineDlg::SetEditCurrentArgument()
|
|||||||
myEditCurrentArgument == GroupFaces->LineEdit2 ) ?
|
myEditCurrentArgument == GroupFaces->LineEdit2 ) ?
|
||||||
TopAbs_FACE : TopAbs_VERTEX;
|
TopAbs_FACE : TopAbs_VERTEX;
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), aNeedType );
|
localSelection( aNeedType );
|
||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
// SelectionIntoArgument();
|
// SelectionIntoArgument();
|
||||||
|
@ -228,7 +228,7 @@ void BasicGUI_MarkerDlg::ConstructorsClicked( int constructorId )
|
|||||||
{
|
{
|
||||||
if ( myConstructorId == constructorId && myConstructorId == 0 ) {
|
if ( myConstructorId == constructorId && myConstructorId == 0 ) {
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
activate( GEOM_MARKER );
|
activate( GEOM_MARKER );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -244,7 +244,7 @@ void BasicGUI_MarkerDlg::ConstructorsClicked( int constructorId )
|
|||||||
Group2->hide();
|
Group2->hide();
|
||||||
aMainGrp->show();
|
aMainGrp->show();
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
activate( GEOM_MARKER );
|
activate( GEOM_MARKER );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -269,7 +269,7 @@ void BasicGUI_MarkerDlg::ConstructorsClicked( int constructorId )
|
|||||||
Group2->PushButton2->setDown( false );
|
Group2->PushButton2->setDown( false );
|
||||||
Group2->PushButton3->setDown( false );
|
Group2->PushButton3->setDown( false );
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
myEditCurrentArgument = Group2->LineEdit1;
|
myEditCurrentArgument = Group2->LineEdit1;
|
||||||
Group2->LineEdit1->setText( "" );
|
Group2->LineEdit1->setText( "" );
|
||||||
Group2->LineEdit2->setText( "" );
|
Group2->LineEdit2->setText( "" );
|
||||||
@ -442,7 +442,7 @@ void BasicGUI_MarkerDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
else if ( send == Group2->PushButton1 ) {
|
else if ( send == Group2->PushButton1 ) {
|
||||||
myEditCurrentArgument = Group2->LineEdit1;
|
myEditCurrentArgument = Group2->LineEdit1;
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
Group2->PushButton2->setDown( false );
|
Group2->PushButton2->setDown( false );
|
||||||
Group2->PushButton3->setDown( false );
|
Group2->PushButton3->setDown( false );
|
||||||
Group2->LineEdit1->setEnabled( true );
|
Group2->LineEdit1->setEnabled( true );
|
||||||
@ -451,7 +451,7 @@ void BasicGUI_MarkerDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
else if ( send == Group2->PushButton2 ) {
|
else if ( send == Group2->PushButton2 ) {
|
||||||
myEditCurrentArgument = Group2->LineEdit2;
|
myEditCurrentArgument = Group2->LineEdit2;
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
Group2->PushButton1->setDown( false );
|
Group2->PushButton1->setDown( false );
|
||||||
Group2->PushButton3->setDown( false );
|
Group2->PushButton3->setDown( false );
|
||||||
Group2->LineEdit1->setEnabled( false );
|
Group2->LineEdit1->setEnabled( false );
|
||||||
@ -460,7 +460,7 @@ void BasicGUI_MarkerDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
else if ( send == Group2->PushButton3 ) {
|
else if ( send == Group2->PushButton3 ) {
|
||||||
myEditCurrentArgument = Group2->LineEdit3;
|
myEditCurrentArgument = Group2->LineEdit3;
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
Group2->PushButton1->setDown( false );
|
Group2->PushButton1->setDown( false );
|
||||||
Group2->PushButton2->setDown( false );
|
Group2->PushButton2->setDown( false );
|
||||||
Group2->LineEdit1->setEnabled( false );
|
Group2->LineEdit1->setEnabled( false );
|
||||||
|
@ -291,7 +291,7 @@ void BasicGUI_PlaneDlg::ConstructorsClicked( int constructorId )
|
|||||||
|
|
||||||
/* for the first argument */
|
/* for the first argument */
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 1: /* plane from 3 points */
|
case 1: /* plane from 3 points */
|
||||||
@ -315,7 +315,7 @@ void BasicGUI_PlaneDlg::ConstructorsClicked( int constructorId )
|
|||||||
|
|
||||||
/* for the first argument */
|
/* for the first argument */
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2: /* plane from a planar face */
|
case 2: /* plane from a planar face */
|
||||||
@ -331,7 +331,7 @@ void BasicGUI_PlaneDlg::ConstructorsClicked( int constructorId )
|
|||||||
GroupFace->PushButton1->setDown( true );
|
GroupFace->PushButton1->setDown( true );
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_FACE );
|
localSelection( TopAbs_FACE );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 3: /* plane from a 2 Vectors */
|
case 3: /* plane from a 2 Vectors */
|
||||||
@ -347,7 +347,7 @@ void BasicGUI_PlaneDlg::ConstructorsClicked( int constructorId )
|
|||||||
Group2Vec->PushButton1->setDown( true );
|
Group2Vec->PushButton1->setDown( true );
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 4: /* plane from a LCS */
|
case 4: /* plane from a LCS */
|
||||||
@ -575,7 +575,7 @@ void BasicGUI_PlaneDlg::SetEditCurrentArgument()
|
|||||||
if ( myEditCurrentArgument == GroupPntDir->LineEdit2 ||
|
if ( myEditCurrentArgument == GroupPntDir->LineEdit2 ||
|
||||||
myEditCurrentArgument == Group2Vec->LineEdit1 ||
|
myEditCurrentArgument == Group2Vec->LineEdit1 ||
|
||||||
myEditCurrentArgument == Group2Vec->LineEdit2 ) {
|
myEditCurrentArgument == Group2Vec->LineEdit2 ) {
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
} else if ( myEditCurrentArgument == GroupFace->LineEdit1 ) {
|
} else if ( myEditCurrentArgument == GroupFace->LineEdit1 ) {
|
||||||
TColStd_MapOfInteger aMap;
|
TColStd_MapOfInteger aMap;
|
||||||
aMap.Add( GEOM_PLANE );
|
aMap.Add( GEOM_PLANE );
|
||||||
@ -585,7 +585,7 @@ void BasicGUI_PlaneDlg::SetEditCurrentArgument()
|
|||||||
globalSelection( GEOM_MARKER );
|
globalSelection( GEOM_MARKER );
|
||||||
}
|
}
|
||||||
else { // 3 Pnts
|
else { // 3 Pnts
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
}
|
}
|
||||||
|
|
||||||
// SelectionIntoArgument();
|
// SelectionIntoArgument();
|
||||||
|
@ -125,13 +125,17 @@ BasicGUI_PointDlg::BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* paren
|
|||||||
GroupXYZ->TextLabel2->setText(tr("GEOM_Y"));
|
GroupXYZ->TextLabel2->setText(tr("GEOM_Y"));
|
||||||
GroupXYZ->TextLabel3->setText(tr("GEOM_Z"));
|
GroupXYZ->TextLabel3->setText(tr("GEOM_Z"));
|
||||||
|
|
||||||
GroupOnCurve = new DlgRef_2Sel1Spin(centralWidget());
|
GroupOnCurve = new DlgRef_2Sel1Spin2Check(centralWidget());
|
||||||
GroupOnCurve->GroupBox1->setTitle(tr("GEOM_POINT_ON_EDGE"));
|
GroupOnCurve->GroupBox1->setTitle(tr("GEOM_POINT_ON_EDGE"));
|
||||||
GroupOnCurve->TextLabel1->setText(tr("GEOM_EDGE"));
|
GroupOnCurve->TextLabel1->setText(tr("GEOM_EDGE"));
|
||||||
GroupOnCurve->TextLabel2->setText(tr("GEOM_START_POINT"));
|
GroupOnCurve->TextLabel2->setText(tr("GEOM_START_POINT"));
|
||||||
GroupOnCurve->TextLabel3->setText(tr("GEOM_PARAMETER"));
|
GroupOnCurve->TextLabel3->setText(tr("GEOM_PARAMETER"));
|
||||||
GroupOnCurve->PushButton1->setIcon(image2);
|
GroupOnCurve->PushButton1->setIcon(image2);
|
||||||
GroupOnCurve->PushButton2->setIcon(image2);
|
GroupOnCurve->PushButton2->setIcon(image2);
|
||||||
|
GroupOnCurve->TextLabel3->setText(tr("GEOM_PARAMETER"));
|
||||||
|
GroupOnCurve->CheckButton1->setText(tr("GEOM_TAKE_ORIENTATION_INTO_ACCOUNT"));
|
||||||
|
GroupOnCurve->CheckButton2->setAttribute( Qt::WA_DeleteOnClose );
|
||||||
|
GroupOnCurve->CheckButton2->close();
|
||||||
|
|
||||||
GroupOnSurface = new DlgRef_1Sel2Spin(centralWidget());
|
GroupOnSurface = new DlgRef_1Sel2Spin(centralWidget());
|
||||||
GroupOnSurface->GroupBox1->setTitle(tr("GEOM_POINT_ON_FACE"));
|
GroupOnSurface->GroupBox1->setTitle(tr("GEOM_POINT_ON_FACE"));
|
||||||
@ -258,6 +262,7 @@ void BasicGUI_PointDlg::Init()
|
|||||||
|
|
||||||
initSpinBox(GroupOnCurve->SpinBox_DX, 0., 1., step, "parametric_precision");
|
initSpinBox(GroupOnCurve->SpinBox_DX, 0., 1., step, "parametric_precision");
|
||||||
GroupOnCurve->SpinBox_DX->setValue(0.5);
|
GroupOnCurve->SpinBox_DX->setValue(0.5);
|
||||||
|
GroupOnCurve->CheckButton1->setChecked(true);
|
||||||
|
|
||||||
initSpinBox(GroupOnSurface->SpinBox_DX, 0., 1., step, "parametric_precision");
|
initSpinBox(GroupOnSurface->SpinBox_DX, 0., 1., step, "parametric_precision");
|
||||||
GroupOnSurface->SpinBox_DX->setValue(0.5);
|
GroupOnSurface->SpinBox_DX->setValue(0.5);
|
||||||
@ -275,6 +280,8 @@ void BasicGUI_PointDlg::Init()
|
|||||||
|
|
||||||
connect(myParamCoord, SIGNAL(buttonClicked(int)), this, SLOT(ClickParamCoord(int)));
|
connect(myParamCoord, SIGNAL(buttonClicked(int)), this, SLOT(ClickParamCoord(int)));
|
||||||
|
|
||||||
|
connect(GroupOnCurve->CheckButton1, SIGNAL(toggled(bool)), this, SLOT(CheckBoxClicked()));
|
||||||
|
|
||||||
connect(GroupOnCurve->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
connect(GroupOnCurve->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
||||||
connect(GroupOnCurve->PushButton2, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
connect(GroupOnCurve->PushButton2, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
||||||
connect(GroupOnSurface->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
connect(GroupOnSurface->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
||||||
@ -328,7 +335,7 @@ void BasicGUI_PointDlg::ConstructorsClicked(int constructorId)
|
|||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_VERTEX;
|
myNeedType = TopAbs_VERTEX;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
|
|
||||||
GroupRefPoint->hide();
|
GroupRefPoint->hide();
|
||||||
GroupOnCurve->hide();
|
GroupOnCurve->hide();
|
||||||
@ -343,7 +350,7 @@ void BasicGUI_PointDlg::ConstructorsClicked(int constructorId)
|
|||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_VERTEX;
|
myNeedType = TopAbs_VERTEX;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupRefPoint->LineEdit1;
|
myEditCurrentArgument = GroupRefPoint->LineEdit1;
|
||||||
myEditCurrentArgument->setText("");
|
myEditCurrentArgument->setText("");
|
||||||
@ -362,7 +369,7 @@ void BasicGUI_PointDlg::ConstructorsClicked(int constructorId)
|
|||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_EDGE;
|
myNeedType = TopAbs_EDGE;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
||||||
myEditCurrentArgument->setText("");
|
myEditCurrentArgument->setText("");
|
||||||
@ -385,7 +392,7 @@ void BasicGUI_PointDlg::ConstructorsClicked(int constructorId)
|
|||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
std::list<int> needTypes;
|
std::list<int> needTypes;
|
||||||
needTypes.push_back( TopAbs_EDGE ), needTypes.push_back( TopAbs_WIRE );
|
needTypes.push_back( TopAbs_EDGE ), needTypes.push_back( TopAbs_WIRE );
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), needTypes );
|
localSelection(needTypes );
|
||||||
|
|
||||||
myEditCurrentArgument = GroupLineIntersection->LineEdit1;
|
myEditCurrentArgument = GroupLineIntersection->LineEdit1;
|
||||||
GroupLineIntersection->LineEdit1->setText("");
|
GroupLineIntersection->LineEdit1->setText("");
|
||||||
@ -409,7 +416,7 @@ void BasicGUI_PointDlg::ConstructorsClicked(int constructorId)
|
|||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_FACE;
|
myNeedType = TopAbs_FACE;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupOnSurface->LineEdit1;
|
myEditCurrentArgument = GroupOnSurface->LineEdit1;
|
||||||
myEditCurrentArgument->setText("");
|
myEditCurrentArgument->setText("");
|
||||||
@ -568,14 +575,14 @@ void BasicGUI_PointDlg::SetEditCurrentArgument()
|
|||||||
GroupRefPoint->LineEdit1->setFocus();
|
GroupRefPoint->LineEdit1->setFocus();
|
||||||
myEditCurrentArgument = GroupRefPoint->LineEdit1;
|
myEditCurrentArgument = GroupRefPoint->LineEdit1;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
}
|
}
|
||||||
else if (send == GroupOnCurve->PushButton1) {
|
else if (send == GroupOnCurve->PushButton1) {
|
||||||
GroupOnCurve->LineEdit1->setFocus();
|
GroupOnCurve->LineEdit1->setFocus();
|
||||||
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_EDGE;
|
myNeedType = TopAbs_EDGE;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
GroupOnCurve->PushButton2->setDown(false);
|
GroupOnCurve->PushButton2->setDown(false);
|
||||||
GroupOnCurve->LineEdit1->setEnabled(true);
|
GroupOnCurve->LineEdit1->setEnabled(true);
|
||||||
GroupOnCurve->LineEdit2->setEnabled(false);
|
GroupOnCurve->LineEdit2->setEnabled(false);
|
||||||
@ -585,7 +592,7 @@ void BasicGUI_PointDlg::SetEditCurrentArgument()
|
|||||||
myEditCurrentArgument = GroupOnCurve->LineEdit2;
|
myEditCurrentArgument = GroupOnCurve->LineEdit2;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
myNeedType = TopAbs_VERTEX;
|
myNeedType = TopAbs_VERTEX;
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection(myNeedType);
|
||||||
GroupOnCurve->PushButton1->setDown(false);
|
GroupOnCurve->PushButton1->setDown(false);
|
||||||
GroupOnCurve->LineEdit2->setEnabled(true);
|
GroupOnCurve->LineEdit2->setEnabled(true);
|
||||||
GroupOnCurve->LineEdit1->setEnabled(false);
|
GroupOnCurve->LineEdit1->setEnabled(false);
|
||||||
@ -595,7 +602,7 @@ void BasicGUI_PointDlg::SetEditCurrentArgument()
|
|||||||
GroupOnSurface->LineEdit1->setFocus();
|
GroupOnSurface->LineEdit1->setFocus();
|
||||||
myEditCurrentArgument = GroupOnSurface->LineEdit1;
|
myEditCurrentArgument = GroupOnSurface->LineEdit1;
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_FACE);
|
localSelection(TopAbs_FACE);
|
||||||
}
|
}
|
||||||
else if (send == GroupLineIntersection->PushButton1) {
|
else if (send == GroupLineIntersection->PushButton1) {
|
||||||
GroupLineIntersection->LineEdit1->setFocus();
|
GroupLineIntersection->LineEdit1->setFocus();
|
||||||
@ -669,7 +676,7 @@ void BasicGUI_PointDlg::ValueChangedInSpinBox(double newValue)
|
|||||||
// function : CheckBoxClicked()
|
// function : CheckBoxClicked()
|
||||||
// purpose : Check Boxes Management
|
// purpose : Check Boxes Management
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PointDlg::CheckBoxClicked(int State)
|
void BasicGUI_PointDlg::CheckBoxClicked()
|
||||||
{
|
{
|
||||||
displayPreview(true);
|
displayPreview(true);
|
||||||
}
|
}
|
||||||
@ -821,7 +828,9 @@ bool BasicGUI_PointDlg::execute(ObjectList& objects)
|
|||||||
case GEOM_POINT_EDGE :
|
case GEOM_POINT_EDGE :
|
||||||
{
|
{
|
||||||
if (myParamCoord->checkedId() == PARAM_VALUE) {
|
if (myParamCoord->checkedId() == PARAM_VALUE) {
|
||||||
anObj = anOper->MakePointOnCurve(myEdge.get(), getParameter());
|
bool isUseOrientation = GroupOnCurve->CheckButton1->isChecked();
|
||||||
|
|
||||||
|
anObj = anOper->MakePointOnCurve(myEdge.get(), getParameter(), isUseOrientation);
|
||||||
aParameters<<GroupOnCurve->SpinBox_DX->text();
|
aParameters<<GroupOnCurve->SpinBox_DX->text();
|
||||||
}
|
}
|
||||||
else if (myParamCoord->checkedId() == LENGTH_VALUE) {
|
else if (myParamCoord->checkedId() == LENGTH_VALUE) {
|
||||||
@ -973,6 +982,7 @@ void BasicGUI_PointDlg::updateParamCoord(bool theIsUpdate)
|
|||||||
GroupOnCurve->LineEdit2->setVisible(isLength);
|
GroupOnCurve->LineEdit2->setVisible(isLength);
|
||||||
GroupOnCurve->TextLabel3->setVisible(isParam || isLength);
|
GroupOnCurve->TextLabel3->setVisible(isParam || isLength);
|
||||||
GroupOnCurve->SpinBox_DX->setVisible(isParam || isLength);
|
GroupOnCurve->SpinBox_DX->setVisible(isParam || isLength);
|
||||||
|
GroupOnCurve->CheckButton1->setVisible(isParam);
|
||||||
if (isParam){
|
if (isParam){
|
||||||
initSpinBox(GroupOnCurve->SpinBox_DX, 0., 1., 0.1, "parametric_precision");
|
initSpinBox(GroupOnCurve->SpinBox_DX, 0., 1., 0.1, "parametric_precision");
|
||||||
GroupOnCurve->SpinBox_DX->setValue(0.5);
|
GroupOnCurve->SpinBox_DX->setValue(0.5);
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
#include "GEOM_GenericObjPtr.h"
|
#include "GEOM_GenericObjPtr.h"
|
||||||
#include <QMap>
|
#include <QMap>
|
||||||
|
|
||||||
class DlgRef_2Sel1Spin;
|
class DlgRef_2Sel1Spin2Check;
|
||||||
class DlgRef_3Spin;
|
class DlgRef_3Spin;
|
||||||
class DlgRef_2Sel;
|
class DlgRef_2Sel;
|
||||||
class DlgRef_1Sel3Spin;
|
class DlgRef_1Sel3Spin;
|
||||||
@ -88,7 +88,7 @@ private:
|
|||||||
|
|
||||||
DlgRef_3Spin* GroupXYZ;
|
DlgRef_3Spin* GroupXYZ;
|
||||||
DlgRef_1Sel3Spin* GroupRefPoint;
|
DlgRef_1Sel3Spin* GroupRefPoint;
|
||||||
DlgRef_2Sel1Spin* GroupOnCurve;
|
DlgRef_2Sel1Spin2Check* GroupOnCurve;
|
||||||
DlgRef_2Sel* GroupLineIntersection;
|
DlgRef_2Sel* GroupLineIntersection;
|
||||||
DlgRef_1Sel2Spin* GroupOnSurface;
|
DlgRef_1Sel2Spin* GroupOnSurface;
|
||||||
|
|
||||||
@ -115,7 +115,7 @@ private slots:
|
|||||||
void ValueChangedInSpinBox( double );
|
void ValueChangedInSpinBox( double );
|
||||||
void SetDoubleSpinBoxStep( double );
|
void SetDoubleSpinBoxStep( double );
|
||||||
void ClickParamCoord( int );
|
void ClickParamCoord( int );
|
||||||
void CheckBoxClicked( int );
|
void CheckBoxClicked();
|
||||||
void updateSize();
|
void updateSize();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -204,7 +204,7 @@ void BasicGUI_VectorDlg::ConstructorsClicked( int constructorId )
|
|||||||
GroupPoints->LineEdit2->setEnabled( false );
|
GroupPoints->LineEdit2->setEnabled( false );
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
connect( myGeomGUI->getApp()->selectionMgr(),
|
connect( myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
|
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
|
||||||
break;
|
break;
|
||||||
@ -325,7 +325,7 @@ void BasicGUI_VectorDlg::SetEditCurrentArgument()
|
|||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
// SelectionIntoArgument();
|
// SelectionIntoArgument();
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
send->setDown(true);
|
send->setDown(true);
|
||||||
displayPreview(true);
|
displayPreview(true);
|
||||||
}
|
}
|
||||||
|
@ -88,6 +88,37 @@
|
|||||||
|
|
||||||
#include "utilities.h"
|
#include "utilities.h"
|
||||||
|
|
||||||
|
//=======================================================================
|
||||||
|
//function : IsToMerge
|
||||||
|
//purpose : This method return Standard_True if two edges have common
|
||||||
|
// vertex. This vertex is returned by output parameter. The
|
||||||
|
// difference with the method TopExp::CommonVertex is only in
|
||||||
|
// the case if there are two common vertices. In this case
|
||||||
|
// this method returns the last vertex of theEdge1, not the first
|
||||||
|
// one that TopExp::CommonVertex does.
|
||||||
|
//=======================================================================
|
||||||
|
static Standard_Boolean GetCommonVertex(const TopoDS_Edge &theEdge1,
|
||||||
|
const TopoDS_Edge &theEdge2,
|
||||||
|
TopoDS_Vertex &theCommon)
|
||||||
|
{
|
||||||
|
Standard_Boolean isFound = Standard_True;
|
||||||
|
ShapeAnalysis_Edge aSae;
|
||||||
|
TopoDS_Vertex aVF1 = aSae.FirstVertex(theEdge1);
|
||||||
|
TopoDS_Vertex aVL1 = aSae.LastVertex(theEdge1);
|
||||||
|
TopoDS_Vertex aVF2 = aSae.FirstVertex(theEdge2);
|
||||||
|
TopoDS_Vertex aVL2 = aSae.LastVertex(theEdge2);
|
||||||
|
|
||||||
|
if (aVL1.IsSame(aVF2) || aVL1.IsSame(aVL2)) {
|
||||||
|
theCommon = aVL1;
|
||||||
|
} else if (aVF1.IsSame(aVL2) || aVF1.IsSame(aVF2)) {
|
||||||
|
theCommon = aVF1;
|
||||||
|
} else {
|
||||||
|
theCommon.Nullify();
|
||||||
|
isFound = Standard_False;
|
||||||
|
}
|
||||||
|
|
||||||
|
return isFound;
|
||||||
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : IsToMerge
|
//function : IsToMerge
|
||||||
@ -148,7 +179,7 @@ static Standard_Boolean IsToMerge
|
|||||||
// that are connected to the common vertex.
|
// that are connected to the common vertex.
|
||||||
TopoDS_Vertex aVCommon;
|
TopoDS_Vertex aVCommon;
|
||||||
|
|
||||||
if (TopExp::CommonVertex(theEdge1, theEdge2, aVCommon)) {
|
if (GetCommonVertex(theEdge1, theEdge2, aVCommon)) {
|
||||||
TopTools_IndexedDataMapOfShapeListOfShape aMapVE;
|
TopTools_IndexedDataMapOfShapeListOfShape aMapVE;
|
||||||
|
|
||||||
TopExp::MapShapesAndAncestors
|
TopExp::MapShapesAndAncestors
|
||||||
@ -328,7 +359,7 @@ static TopoDS_Edge GlueEdgesWithPCurves(const TopTools_SequenceOfShape& aChain,
|
|||||||
|
|
||||||
if (i > 1)
|
if (i > 1)
|
||||||
{
|
{
|
||||||
TopExp::CommonVertex(PrevEdge, anEdge, CV);
|
GetCommonVertex(PrevEdge, anEdge, CV);
|
||||||
Standard_Real Tol = BRep_Tool::Tolerance(CV);
|
Standard_Real Tol = BRep_Tool::Tolerance(CV);
|
||||||
tabtolvertex(i-2) = Tol;
|
tabtolvertex(i-2) = Tol;
|
||||||
}
|
}
|
||||||
|
@ -138,8 +138,9 @@ static Standard_Boolean AddOrdinaryEdges(TopTools_SequenceOfShape& edges,
|
|||||||
{
|
{
|
||||||
//map of edges
|
//map of edges
|
||||||
TopTools_MapOfShape aNewEdges;
|
TopTools_MapOfShape aNewEdges;
|
||||||
|
TopExp_Explorer exp(aShape,TopAbs_EDGE);
|
||||||
//add edges without seams
|
//add edges without seams
|
||||||
for(TopExp_Explorer exp(aShape,TopAbs_EDGE); exp.More(); exp.Next()) {
|
for(; exp.More(); exp.Next()) {
|
||||||
TopoDS_Shape edge = exp.Current();
|
TopoDS_Shape edge = exp.Current();
|
||||||
if(aNewEdges.Contains(edge))
|
if(aNewEdges.Contains(edge))
|
||||||
aNewEdges.Remove(edge);
|
aNewEdges.Remove(edge);
|
||||||
@ -164,9 +165,14 @@ static Standard_Boolean AddOrdinaryEdges(TopTools_SequenceOfShape& edges,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//add edges to the sequemce
|
//add edges to the sequence
|
||||||
for(TopTools_MapIteratorOfMapOfShape anIter(aNewEdges); anIter.More(); anIter.Next())
|
for(exp.ReInit(); exp.More(); exp.Next()) {
|
||||||
edges.Append(anIter.Key());
|
const TopoDS_Shape &anEdge = exp.Current();
|
||||||
|
|
||||||
|
if (aNewEdges.Contains(anEdge)) {
|
||||||
|
edges.Append(anEdge);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return isDropped;
|
return isDropped;
|
||||||
}
|
}
|
||||||
|
@ -387,7 +387,7 @@ void BlocksGUI_BlockDlg::SetEditCurrentArgument()
|
|||||||
aSender->setDown(true);
|
aSender->setDown(true);
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_FACE); //Select Faces on All Shapes
|
localSelection(TopAbs_FACE); //Select Faces on All Shapes
|
||||||
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
this, SLOT(SelectionIntoArgument()));
|
this, SLOT(SelectionIntoArgument()));
|
||||||
}
|
}
|
||||||
@ -400,7 +400,7 @@ void BlocksGUI_BlockDlg::ActivateThisDialog()
|
|||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_FACE); //Select Faces on All Shapes
|
localSelection(TopAbs_FACE); //Select Faces on All Shapes
|
||||||
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
this, SLOT(SelectionIntoArgument()));
|
this, SLOT(SelectionIntoArgument()));
|
||||||
displayPreview(true);
|
displayPreview(true);
|
||||||
|
@ -46,7 +46,7 @@
|
|||||||
// purpose : Constructs a BlocksGUI_ExplodeDlg which is a child of 'parent'.
|
// purpose : Constructs a BlocksGUI_ExplodeDlg which is a child of 'parent'.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_ExplodeDlg::BlocksGUI_ExplodeDlg( GeometryGUI* theGeometryGUI, QWidget* parent )
|
BlocksGUI_ExplodeDlg::BlocksGUI_ExplodeDlg( GeometryGUI* theGeometryGUI, QWidget* parent )
|
||||||
: GEOMBase_Skeleton( theGeometryGUI, parent )
|
: GEOMBase_Skeleton( theGeometryGUI, parent ), myNbBlocks( 0 )
|
||||||
{
|
{
|
||||||
QPixmap image1( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_BLOCK_EXPLODE" ) ) );
|
QPixmap image1( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_BLOCK_EXPLODE" ) ) );
|
||||||
QPixmap imageS( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) );
|
QPixmap imageS( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) );
|
||||||
@ -189,7 +189,7 @@ bool BlocksGUI_ExplodeDlg::ClickOnApply()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( !onAccept() )
|
if ( !onAccept( true, true, false ) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
activateSelection();
|
activateSelection();
|
||||||
@ -351,7 +351,7 @@ void BlocksGUI_ExplodeDlg::updateButtonState()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
bool BlocksGUI_ExplodeDlg::isAllSubShapes() const
|
bool BlocksGUI_ExplodeDlg::isAllSubShapes() const
|
||||||
{
|
{
|
||||||
return !myGrp1->CheckBox1->isChecked() || !myGrp1->CheckBox1->isEnabled();
|
return !(myGrp1->CheckBox1->isEnabled() && myGrp1->CheckBox1->isChecked());
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
|
@ -466,11 +466,11 @@ void BlocksGUI_QuadFaceDlg::activateSelection()
|
|||||||
myEditCurrentArgument == mySelName[Vertex3] ||
|
myEditCurrentArgument == mySelName[Vertex3] ||
|
||||||
myEditCurrentArgument == mySelName[Vertex4])
|
myEditCurrentArgument == mySelName[Vertex4])
|
||||||
{
|
{
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX); //Select Vertices on All Shapes
|
localSelection(TopAbs_VERTEX); //Select Vertices on All Shapes
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE); //Select Edges on All Shapes
|
localSelection(TopAbs_EDGE); //Select Edges on All Shapes
|
||||||
}
|
}
|
||||||
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
this, SLOT(SelectionIntoArgument()));
|
this, SLOT(SelectionIntoArgument()));
|
||||||
|
@ -219,7 +219,6 @@ bool BlocksGUI_TrsfDlg::ClickOnApply()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BlocksGUI_TrsfDlg::SelectionIntoArgument()
|
void BlocksGUI_TrsfDlg::SelectionIntoArgument()
|
||||||
{
|
{
|
||||||
erasePreview();
|
|
||||||
myEditCurrentArgument->setText("");
|
myEditCurrentArgument->setText("");
|
||||||
|
|
||||||
// Get index of current selection focus
|
// Get index of current selection focus
|
||||||
@ -273,7 +272,6 @@ void BlocksGUI_TrsfDlg::SelectionIntoArgument()
|
|||||||
}
|
}
|
||||||
myEditCurrentArgument->setText(aName);
|
myEditCurrentArgument->setText(aName);
|
||||||
myFaces[aCurrFocus] = anIndex;
|
myFaces[aCurrFocus] = anIndex;
|
||||||
processPreview();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (aCurrFocus) {
|
switch (aCurrFocus) {
|
||||||
@ -316,6 +314,8 @@ void BlocksGUI_TrsfDlg::SelectionIntoArgument()
|
|||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
processPreview();
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -379,6 +379,8 @@ void BlocksGUI_TrsfDlg::SetEditCurrentArgument()
|
|||||||
aSender->setDown(true);
|
aSender->setDown(true);
|
||||||
|
|
||||||
activateSelection();
|
activateSelection();
|
||||||
|
|
||||||
|
processPreview();
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
|
@ -198,10 +198,7 @@ void BooleanGUI_Dialog::Init()
|
|||||||
mainFrame()->RadioButton1->setFocus();
|
mainFrame()->RadioButton1->setFocus();
|
||||||
|
|
||||||
globalSelection(GEOM_ALLSHAPES);
|
globalSelection(GEOM_ALLSHAPES);
|
||||||
|
//localSelection(TopAbs_SHAPE); // VSR 24/09/2015: dectivate local selection in BOP (CoTech decision)
|
||||||
std::list<int> needTypes;
|
|
||||||
needTypes.push_back( TopAbs_VERTEX ), needTypes.push_back( TopAbs_EDGE ), needTypes.push_back( TopAbs_WIRE ), needTypes.push_back( TopAbs_FACE ), needTypes.push_back( TopAbs_SHELL ), needTypes.push_back( TopAbs_SOLID ), needTypes.push_back( TopAbs_COMPOUND );
|
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), needTypes );
|
|
||||||
|
|
||||||
myGroup->PushButton1->click();
|
myGroup->PushButton1->click();
|
||||||
resize(100,100);
|
resize(100,100);
|
||||||
@ -341,10 +338,7 @@ void BooleanGUI_Dialog::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
|
|
||||||
globalSelection(GEOM_ALLSHAPES);
|
globalSelection(GEOM_ALLSHAPES);
|
||||||
|
//localSelection(TopAbs_SHAPE); // VSR 24/09/2015: dectivate local selection in BOP (CoTech decision)
|
||||||
std::list<int> needTypes;
|
|
||||||
needTypes.push_back( TopAbs_VERTEX ), needTypes.push_back( TopAbs_EDGE ), needTypes.push_back( TopAbs_WIRE ), needTypes.push_back( TopAbs_FACE ), needTypes.push_back( TopAbs_SHELL ), needTypes.push_back( TopAbs_SOLID ), needTypes.push_back( TopAbs_COMPOUND );
|
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), needTypes );
|
|
||||||
|
|
||||||
// enable line edit
|
// enable line edit
|
||||||
myEditCurrentArgument->setEnabled(true);
|
myEditCurrentArgument->setEnabled(true);
|
||||||
|
@ -145,7 +145,7 @@ void BuildGUI_EdgeDlg::Init()
|
|||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
GroupPoints->PushButton1->setDown(true);
|
GroupPoints->PushButton1->setDown(true);
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
|
|
||||||
// signals and slots connections
|
// signals and slots connections
|
||||||
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
@ -210,7 +210,7 @@ void BuildGUI_EdgeDlg::ConstructorsClicked(int constructorId)
|
|||||||
case 0:
|
case 0:
|
||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
GroupPoints->LineEdit1->setText("");
|
GroupPoints->LineEdit1->setText("");
|
||||||
@ -229,7 +229,7 @@ void BuildGUI_EdgeDlg::ConstructorsClicked(int constructorId)
|
|||||||
case 1:
|
case 1:
|
||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_WIRE);
|
localSelection(TopAbs_WIRE);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupWire->LineEdit1;
|
myEditCurrentArgument = GroupWire->LineEdit1;
|
||||||
GroupWire->LineEdit1->setText("");
|
GroupWire->LineEdit1->setText("");
|
||||||
@ -244,7 +244,7 @@ void BuildGUI_EdgeDlg::ConstructorsClicked(int constructorId)
|
|||||||
case 2:
|
case 2:
|
||||||
{
|
{
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE);
|
localSelection(TopAbs_EDGE);
|
||||||
|
|
||||||
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
myEditCurrentArgument = GroupOnCurve->LineEdit1;
|
||||||
GroupOnCurve->LineEdit1->setText("");
|
GroupOnCurve->LineEdit1->setText("");
|
||||||
@ -302,7 +302,7 @@ void BuildGUI_EdgeDlg::SelectionIntoArgument()
|
|||||||
myEditCurrentArgument->setText(aName);
|
myEditCurrentArgument->setText(aName);
|
||||||
|
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), aNeedType);
|
localSelection(aNeedType);
|
||||||
|
|
||||||
if (myEditCurrentArgument == GroupPoints->LineEdit1) {
|
if (myEditCurrentArgument == GroupPoints->LineEdit1) {
|
||||||
myPoint1 = aSelectedObject;
|
myPoint1 = aSelectedObject;
|
||||||
@ -359,7 +359,7 @@ void BuildGUI_EdgeDlg::SetEditCurrentArgument()
|
|||||||
GroupOnCurve->LineEdit2->setEnabled(false);
|
GroupOnCurve->LineEdit2->setEnabled(false);
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_EDGE);
|
localSelection(TopAbs_EDGE);
|
||||||
}
|
}
|
||||||
else if (send == GroupOnCurve->PushButton2) {
|
else if (send == GroupOnCurve->PushButton2) {
|
||||||
myEditCurrentArgument = GroupOnCurve->LineEdit2;
|
myEditCurrentArgument = GroupOnCurve->LineEdit2;
|
||||||
@ -367,7 +367,7 @@ void BuildGUI_EdgeDlg::SetEditCurrentArgument()
|
|||||||
GroupOnCurve->LineEdit1->setEnabled(false);
|
GroupOnCurve->LineEdit1->setEnabled(false);
|
||||||
|
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
}
|
}
|
||||||
|
|
||||||
// enable line edit
|
// enable line edit
|
||||||
|
@ -263,7 +263,7 @@ void BuildGUI_FaceDlg::ConstructorsClicked(int constructorId)
|
|||||||
case 1:
|
case 1:
|
||||||
{
|
{
|
||||||
globalSelection(GEOM_FACE); // For the first element.
|
globalSelection(GEOM_FACE); // For the first element.
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_FACE );
|
localSelection( TopAbs_FACE );
|
||||||
|
|
||||||
myEditCurrentArgument = myGroupSurf->LineEdit1;
|
myEditCurrentArgument = myGroupSurf->LineEdit1;
|
||||||
myGroupSurf->LineEdit1->setText("");
|
myGroupSurf->LineEdit1->setText("");
|
||||||
@ -277,7 +277,7 @@ void BuildGUI_FaceDlg::ConstructorsClicked(int constructorId)
|
|||||||
case 2:
|
case 2:
|
||||||
{
|
{
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_WIRE );
|
localSelection( TopAbs_WIRE );
|
||||||
|
|
||||||
myTreeConstraints->clear();
|
myTreeConstraints->clear();
|
||||||
myCurrentItem = 0;
|
myCurrentItem = 0;
|
||||||
@ -323,7 +323,7 @@ void BuildGUI_FaceDlg::updateConstraintsTree()
|
|||||||
|
|
||||||
myEditCurrentArgument->setEnabled(false);
|
myEditCurrentArgument->setEnabled(false);
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_FACE );
|
localSelection( TopAbs_FACE );
|
||||||
|
|
||||||
myTreeConstraints->resizeColumnToContents(0);
|
myTreeConstraints->resizeColumnToContents(0);
|
||||||
QTreeWidgetItem* firstItem = myTreeConstraints->topLevelItem(0);
|
QTreeWidgetItem* firstItem = myTreeConstraints->topLevelItem(0);
|
||||||
@ -509,21 +509,21 @@ void BuildGUI_FaceDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
else if (send == myGroupSurf->PushButton1) {
|
else if (send == myGroupSurf->PushButton1) {
|
||||||
globalSelection(GEOM_FACE);
|
globalSelection(GEOM_FACE);
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_FACE );
|
localSelection( TopAbs_FACE );
|
||||||
myEditCurrentArgument = myGroupSurf->LineEdit1;
|
myEditCurrentArgument = myGroupSurf->LineEdit1;
|
||||||
myGroupSurf->PushButton2->setDown(false);
|
myGroupSurf->PushButton2->setDown(false);
|
||||||
myGroupSurf->LineEdit2->setEnabled(false);
|
myGroupSurf->LineEdit2->setEnabled(false);
|
||||||
}
|
}
|
||||||
else if (send == myGroupSurf->PushButton2) {
|
else if (send == myGroupSurf->PushButton2) {
|
||||||
globalSelection(GEOM_WIRE);
|
globalSelection(GEOM_WIRE);
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_WIRE );
|
localSelection( TopAbs_WIRE );
|
||||||
myEditCurrentArgument = myGroupSurf->LineEdit2;
|
myEditCurrentArgument = myGroupSurf->LineEdit2;
|
||||||
myGroupSurf->PushButton1->setDown(false);
|
myGroupSurf->PushButton1->setDown(false);
|
||||||
myGroupSurf->LineEdit1->setEnabled(false);
|
myGroupSurf->LineEdit1->setEnabled(false);
|
||||||
}
|
}
|
||||||
else if (send == myGroupWireConstraints->PushButton1) {
|
else if (send == myGroupWireConstraints->PushButton1) {
|
||||||
globalSelection();
|
globalSelection();
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_WIRE );
|
localSelection( TopAbs_WIRE );
|
||||||
myEditCurrentArgument = myGroupWireConstraints->LineEdit1;
|
myEditCurrentArgument = myGroupWireConstraints->LineEdit1;
|
||||||
myCurrentItem = 0;
|
myCurrentItem = 0;
|
||||||
}
|
}
|
||||||
@ -659,8 +659,6 @@ bool BuildGUI_FaceDlg::execute( ObjectList& objects )
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!anObj->_is_nil()) {
|
if (!anObj->_is_nil()) {
|
||||||
objects.push_back(anObj._retn());
|
|
||||||
|
|
||||||
if ( !anOper->IsDone() && QString(anOper->GetErrorCode()) == "MAKE_FACE_TOLERANCE_TOO_BIG") {
|
if ( !anOper->IsDone() && QString(anOper->GetErrorCode()) == "MAKE_FACE_TOLERANCE_TOO_BIG") {
|
||||||
if ( !IsPreview() ) {
|
if ( !IsPreview() ) {
|
||||||
SUIT_OverrideCursor wc;
|
SUIT_OverrideCursor wc;
|
||||||
@ -670,6 +668,14 @@ bool BuildGUI_FaceDlg::execute( ObjectList& objects )
|
|||||||
}
|
}
|
||||||
anOper->SetErrorCode("PAL_NO_ERROR");
|
anOper->SetErrorCode("PAL_NO_ERROR");
|
||||||
}
|
}
|
||||||
|
else if ( anObj->GetShapeType() == GEOM::COMPOUND ) {
|
||||||
|
if ( !IsPreview() ) {
|
||||||
|
SUIT_MessageBox::warning(this,
|
||||||
|
QObject::tr("GEOM_WRN_WARNING"),
|
||||||
|
QObject::tr("GEOM_WRN_FACES_NOT_FACE"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
objects.push_back(anObj._retn());
|
||||||
}
|
}
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
|
@ -262,10 +262,7 @@ bool BuildGUI_ShellDlg::execute( ObjectList& objects )
|
|||||||
GEOM::GEOM_Object_var anObj = anOper->MakeShell( objlist.in() );
|
GEOM::GEOM_Object_var anObj = anOper->MakeShell( objlist.in() );
|
||||||
|
|
||||||
if ( !anObj->_is_nil() ) {
|
if ( !anObj->_is_nil() ) {
|
||||||
TopoDS_Shape aShell;
|
if (anObj->GetShapeType() == GEOM::COMPOUND) {
|
||||||
GEOMBase::GetShape(anObj, aShell, TopAbs_SHELL);
|
|
||||||
|
|
||||||
if (aShell.IsNull()) {
|
|
||||||
SUIT_MessageBox::warning(this,
|
SUIT_MessageBox::warning(this,
|
||||||
QObject::tr("GEOM_WRN_WARNING"),
|
QObject::tr("GEOM_WRN_WARNING"),
|
||||||
QObject::tr("GEOM_WRN_FACES_NOT_SHELL"));
|
QObject::tr("GEOM_WRN_FACES_NOT_SHELL"));
|
||||||
|
@ -121,7 +121,7 @@ void BuildGUI_WireDlg::Init()
|
|||||||
|
|
||||||
myEdgesAndWires.clear();
|
myEdgesAndWires.clear();
|
||||||
|
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );
|
connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );
|
||||||
@ -177,12 +177,12 @@ void BuildGUI_WireDlg::TypeButtonClicked()
|
|||||||
{
|
{
|
||||||
if ( GroupType->RadioButton1->isChecked() ) {
|
if ( GroupType->RadioButton1->isChecked() ) {
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
|
localSelection( TopAbs_EDGE );
|
||||||
GroupArgs->TextLabel1->setText( tr( "GEOM_EDGE" ) );
|
GroupArgs->TextLabel1->setText( tr( "GEOM_EDGE" ) );
|
||||||
}
|
}
|
||||||
else if ( GroupType->RadioButton2->isChecked() ) {
|
else if ( GroupType->RadioButton2->isChecked() ) {
|
||||||
globalSelection(); // close local contexts, if any
|
globalSelection(); // close local contexts, if any
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_WIRE );
|
localSelection( TopAbs_WIRE );
|
||||||
GroupArgs->TextLabel1->setText( tr( "GEOM_WIRE" ) );
|
GroupArgs->TextLabel1->setText( tr( "GEOM_WIRE" ) );
|
||||||
}
|
}
|
||||||
SelectionIntoArgument();
|
SelectionIntoArgument();
|
||||||
|
@ -42,11 +42,14 @@ ENDIF()
|
|||||||
IF(SALOME_BUILD_GUI)
|
IF(SALOME_BUILD_GUI)
|
||||||
SET(SUBDIRS_GUI
|
SET(SUBDIRS_GUI
|
||||||
OBJECT DlgRef GEOMFiltersSelection Material GEOMGUI
|
OBJECT DlgRef GEOMFiltersSelection Material GEOMGUI
|
||||||
GEOMBase DependencyTree GEOMToolsGUI DisplayGUI BasicGUI PrimitiveGUI GenerationGUI
|
GEOMBase GEOMToolsGUI DisplayGUI BasicGUI PrimitiveGUI GenerationGUI
|
||||||
CurveCreator EntityGUI BuildGUI BooleanGUI TransformationGUI OperationGUI
|
CurveCreator MeasureGUI EntityGUI BuildGUI BooleanGUI TransformationGUI OperationGUI
|
||||||
RepairGUI MeasureGUI GroupGUI BlocksGUI AdvancedGUI
|
RepairGUI GroupGUI BlocksGUI AdvancedGUI
|
||||||
GEOM_SWIG_WITHIHM
|
GEOM_SWIG_WITHIHM
|
||||||
)
|
)
|
||||||
|
IF(SALOME_USE_GRAPHICSVIEW)
|
||||||
|
LIST(APPEND SUBDIRS_GUI DependencyTree)
|
||||||
|
ENDIF()
|
||||||
ENDIF()
|
ENDIF()
|
||||||
|
|
||||||
SET(SUBDIRS
|
SET(SUBDIRS
|
||||||
|
@ -39,6 +39,7 @@ INCLUDE_DIRECTORIES(
|
|||||||
${PROJECT_SOURCE_DIR}/src/GEOMImpl
|
${PROJECT_SOURCE_DIR}/src/GEOMImpl
|
||||||
${PROJECT_SOURCE_DIR}/src/GEOMGUI
|
${PROJECT_SOURCE_DIR}/src/GEOMGUI
|
||||||
${PROJECT_SOURCE_DIR}/src/GEOMBase
|
${PROJECT_SOURCE_DIR}/src/GEOMBase
|
||||||
|
${PROJECT_SOURCE_DIR}/src/MeasureGUI
|
||||||
${PROJECT_SOURCE_DIR}/src/SKETCHER
|
${PROJECT_SOURCE_DIR}/src/SKETCHER
|
||||||
${PROJECT_SOURCE_DIR}/src/CurveCreator
|
${PROJECT_SOURCE_DIR}/src/CurveCreator
|
||||||
${PROJECT_SOURCE_DIR}/src/ShapeRecognition
|
${PROJECT_SOURCE_DIR}/src/ShapeRecognition
|
||||||
@ -67,6 +68,7 @@ SET(_link_LIBRARIES
|
|||||||
DlgRef
|
DlgRef
|
||||||
GEOMSketcher
|
GEOMSketcher
|
||||||
CurveCreator
|
CurveCreator
|
||||||
|
MeasureGUI
|
||||||
)
|
)
|
||||||
|
|
||||||
# optional sources
|
# optional sources
|
||||||
|
@ -327,7 +327,7 @@ void EntityGUI_3DSketcherDlg::Init()
|
|||||||
myLengthPrs = dynamic_cast<SOCC_Prs*>(((SOCC_Viewer*)(vw->getViewManager()->getViewModel()))->CreatePrs(0));
|
myLengthPrs = dynamic_cast<SOCC_Prs*>(((SOCC_Viewer*)(vw->getViewManager()->getViewModel()))->CreatePrs(0));
|
||||||
myTextPrs = dynamic_cast<SOCC_Prs*>(((SOCC_Viewer*)(vw->getViewManager()->getViewModel()))->CreatePrs(0));
|
myTextPrs = dynamic_cast<SOCC_Prs*>(((SOCC_Viewer*)(vw->getViewManager()->getViewModel()))->CreatePrs(0));
|
||||||
|
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
|
|
||||||
/* Get setting of step value from file configuration */
|
/* Get setting of step value from file configuration */
|
||||||
double step = SUIT_Session::session()->resourceMgr()->doubleValue("Geometry", "SettingsGeomStep", 100.0);
|
double step = SUIT_Session::session()->resourceMgr()->doubleValue("Geometry", "SettingsGeomStep", 100.0);
|
||||||
@ -823,7 +823,7 @@ void EntityGUI_3DSketcherDlg::ActivateThisDialog()
|
|||||||
connect(myGeomGUI->getApp()->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_VERTEX);
|
localSelection(TopAbs_VERTEX);
|
||||||
GEOMBase_Helper::displayPreview(true, false, true, true, myLineWidth);
|
GEOMBase_Helper::displayPreview(true, false, true, true, myLineWidth);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -541,7 +541,7 @@ void EntityGUI_SketcherDlg::InitClick()
|
|||||||
Group4Spin->hide();
|
Group4Spin->hide();
|
||||||
GroupRect->hide();
|
GroupRect->hide();
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
|
localSelection( TopAbs_VERTEX );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1571,7 +1571,7 @@ void EntityGUI_SketcherDlg::SetEditCurrentArgument()
|
|||||||
selButton->setDown(true);
|
selButton->setDown(true);
|
||||||
}
|
}
|
||||||
globalSelection(); // close local selection to clear it
|
globalSelection(); // close local selection to clear it
|
||||||
localSelection(GEOM::GEOM_Object::_nil(), myNeedType);
|
localSelection( myNeedType );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,6 +30,9 @@
|
|||||||
#include <GeometryGUI.h>
|
#include <GeometryGUI.h>
|
||||||
#include <GEOMBase.h>
|
#include <GEOMBase.h>
|
||||||
#include <GEOMUtils.hxx>
|
#include <GEOMUtils.hxx>
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
#include <MeasureGUI_ShapeStatisticsDlg.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <OCCViewer_ViewModel.h>
|
#include <OCCViewer_ViewModel.h>
|
||||||
#include <SVTK_ViewModel.h>
|
#include <SVTK_ViewModel.h>
|
||||||
@ -165,6 +168,9 @@ EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidge
|
|||||||
myLessFilterSpin = new SalomeApp_DoubleSpinBox(myFilterGrp);
|
myLessFilterSpin = new SalomeApp_DoubleSpinBox(myFilterGrp);
|
||||||
myGreaterFilterSpin = new SalomeApp_DoubleSpinBox(myFilterGrp);
|
myGreaterFilterSpin = new SalomeApp_DoubleSpinBox(myFilterGrp);
|
||||||
myApplyFilterButton = new QPushButton(tr("GEOM_BUT_APPLY"), myFilterGrp);
|
myApplyFilterButton = new QPushButton(tr("GEOM_BUT_APPLY"), myFilterGrp);
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
myPlotDistributionButton = new QPushButton(tr("GEOM_PLOT_DISTRIBUTION"), myFilterGrp);
|
||||||
|
#endif
|
||||||
|
|
||||||
QGridLayout* filterLayout = new QGridLayout(myFilterGrp);
|
QGridLayout* filterLayout = new QGridLayout(myFilterGrp);
|
||||||
filterLayout->addWidget(myLessFilterCheck, 0, 0);
|
filterLayout->addWidget(myLessFilterCheck, 0, 0);
|
||||||
@ -174,6 +180,9 @@ EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidge
|
|||||||
filterLayout->addWidget(myGreaterFilterCombo, 1, 1);
|
filterLayout->addWidget(myGreaterFilterCombo, 1, 1);
|
||||||
filterLayout->addWidget(myGreaterFilterSpin, 1, 2);
|
filterLayout->addWidget(myGreaterFilterSpin, 1, 2);
|
||||||
filterLayout->addWidget(myApplyFilterButton, 0, 3);
|
filterLayout->addWidget(myApplyFilterButton, 0, 3);
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
filterLayout->addWidget(myPlotDistributionButton, 1, 3);
|
||||||
|
#endif
|
||||||
|
|
||||||
QVBoxLayout* layout = new QVBoxLayout(centralWidget());
|
QVBoxLayout* layout = new QVBoxLayout(centralWidget());
|
||||||
layout->setMargin(0); layout->setSpacing(6);
|
layout->setMargin(0); layout->setSpacing(6);
|
||||||
@ -250,6 +259,9 @@ void EntityGUI_SubShapeDlg::Init()
|
|||||||
connect(GroupPoints->PushButton4, SIGNAL(clicked()), this, SLOT(showOnlySelected()));
|
connect(GroupPoints->PushButton4, SIGNAL(clicked()), this, SLOT(showOnlySelected()));
|
||||||
|
|
||||||
connect(myApplyFilterButton, SIGNAL(clicked()), this, SLOT(ClickOnOkFilter()));
|
connect(myApplyFilterButton, SIGNAL(clicked()), this, SLOT(ClickOnOkFilter()));
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
connect(myPlotDistributionButton, SIGNAL(clicked()), this, SLOT(ClickOnPlot()));
|
||||||
|
#endif
|
||||||
connect(myLessFilterCheck, SIGNAL(stateChanged(int)), this, SLOT(MeasureToggled()));
|
connect(myLessFilterCheck, SIGNAL(stateChanged(int)), this, SLOT(MeasureToggled()));
|
||||||
connect(myGreaterFilterCheck, SIGNAL(stateChanged(int)), this, SLOT(MeasureToggled()));
|
connect(myGreaterFilterCheck, SIGNAL(stateChanged(int)), this, SLOT(MeasureToggled()));
|
||||||
|
|
||||||
@ -322,7 +334,7 @@ void EntityGUI_SubShapeDlg::ClickOnOk()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (isOk)
|
if (isOk)
|
||||||
isOk = onAccept();
|
isOk = onAccept( true, true, false );
|
||||||
|
|
||||||
if (isOk)
|
if (isOk)
|
||||||
ClickOnCancel();
|
ClickOnCancel();
|
||||||
@ -491,6 +503,13 @@ void EntityGUI_SubShapeDlg::SubShapeToggled()
|
|||||||
GroupPoints->CheckButton1->isChecked() &&
|
GroupPoints->CheckButton1->isChecked() &&
|
||||||
shapeType() < GEOM::VERTEX);
|
shapeType() < GEOM::VERTEX);
|
||||||
|
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
myPlotDistributionButton->setEnabled( myFilterGrp->isEnabled() &&
|
||||||
|
( shapeType() == TopAbs_EDGE ||
|
||||||
|
shapeType() == TopAbs_FACE ||
|
||||||
|
shapeType() == TopAbs_SOLID ) );
|
||||||
|
#endif
|
||||||
|
|
||||||
activateSelection();
|
activateSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -936,6 +955,20 @@ void EntityGUI_SubShapeDlg::ClickOnOkFilter()
|
|||||||
updateButtonState();
|
updateButtonState();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
//=================================================================================
|
||||||
|
// function : ClickOnPlot()
|
||||||
|
// purpose : opens "Shape Statistics" dialog box in order to plot sub-shapes distribution.
|
||||||
|
//=================================================================================
|
||||||
|
void EntityGUI_SubShapeDlg::ClickOnPlot()
|
||||||
|
{
|
||||||
|
QDialog* dlg = new MeasureGUI_ShapeStatisticsDlg( this, myShape, (TopAbs_ShapeEnum)shapeType() );
|
||||||
|
if ( dlg ) {
|
||||||
|
dlg->show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : MeasureToggled()
|
// function : MeasureToggled()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -73,6 +73,9 @@ private slots:
|
|||||||
|
|
||||||
void showOnlySelected();
|
void showOnlySelected();
|
||||||
void ClickOnOkFilter();
|
void ClickOnOkFilter();
|
||||||
|
#ifndef DISABLE_PLOT2DVIEWER
|
||||||
|
void ClickOnPlot();
|
||||||
|
#endif
|
||||||
void MeasureToggled();
|
void MeasureToggled();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@ -102,6 +105,7 @@ private:
|
|||||||
SalomeApp_DoubleSpinBox* myLessFilterSpin;
|
SalomeApp_DoubleSpinBox* myLessFilterSpin;
|
||||||
SalomeApp_DoubleSpinBox* myGreaterFilterSpin;
|
SalomeApp_DoubleSpinBox* myGreaterFilterSpin;
|
||||||
QPushButton* myApplyFilterButton;
|
QPushButton* myApplyFilterButton;
|
||||||
|
QPushButton* myPlotDistributionButton;
|
||||||
QGroupBox* myFilterGrp;
|
QGroupBox* myFilterGrp;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -144,7 +144,7 @@ namespace GEOM
|
|||||||
TPythonDump::operator<< (const std::list<Handle(GEOM_Object)>& theObjects)
|
TPythonDump::operator<< (const std::list<Handle(GEOM_Object)>& theObjects)
|
||||||
{
|
{
|
||||||
Standard_Integer aLength = theObjects.size();
|
Standard_Integer aLength = theObjects.size();
|
||||||
if ( aLength > 1 ) {
|
if ( aLength != 1 ) {
|
||||||
myStream << "[";
|
myStream << "[";
|
||||||
}
|
}
|
||||||
std::list<Handle(GEOM_Object)>::const_iterator obj = theObjects.begin();
|
std::list<Handle(GEOM_Object)>::const_iterator obj = theObjects.begin();
|
||||||
@ -152,7 +152,7 @@ namespace GEOM
|
|||||||
*this << *obj;
|
*this << *obj;
|
||||||
if ( i < aLength ) myStream << ", ";
|
if ( i < aLength ) myStream << ", ";
|
||||||
}
|
}
|
||||||
if ( aLength > 1 ) {
|
if ( aLength != 1 ) {
|
||||||
myStream << "]";
|
myStream << "]";
|
||||||
}
|
}
|
||||||
return *this;
|
return *this;
|
||||||
|
@ -59,7 +59,10 @@ SET(GEOMAlgo_HEADERS
|
|||||||
GEOMAlgo_DataMapOfPassKeyInteger.hxx
|
GEOMAlgo_DataMapOfPassKeyInteger.hxx
|
||||||
GEOMAlgo_DataMapOfShapeMapOfShape.hxx
|
GEOMAlgo_DataMapOfShapeMapOfShape.hxx
|
||||||
GEOMAlgo_DataMapOfShapePnt.hxx
|
GEOMAlgo_DataMapOfShapePnt.hxx
|
||||||
|
GEOMAlgo_FinderShapeOn.hxx
|
||||||
|
GEOMAlgo_FinderShapeOn1.hxx
|
||||||
GEOMAlgo_FinderShapeOn2.hxx
|
GEOMAlgo_FinderShapeOn2.hxx
|
||||||
|
GEOMAlgo_FinderShapeOnQuad.hxx
|
||||||
GEOMAlgo_GetInPlace.hxx
|
GEOMAlgo_GetInPlace.hxx
|
||||||
GEOMAlgo_GetInPlaceAPI.hxx
|
GEOMAlgo_GetInPlaceAPI.hxx
|
||||||
GEOMAlgo_GlueAnalyser.hxx
|
GEOMAlgo_GlueAnalyser.hxx
|
||||||
@ -77,6 +80,7 @@ SET(GEOMAlgo_HEADERS
|
|||||||
GEOMAlgo_IndexedDataMapOfShapeState.hxx
|
GEOMAlgo_IndexedDataMapOfShapeState.hxx
|
||||||
GEOMAlgo_KindOfBounds.hxx
|
GEOMAlgo_KindOfBounds.hxx
|
||||||
GEOMAlgo_KindOfClosed.hxx
|
GEOMAlgo_KindOfClosed.hxx
|
||||||
|
GEOMAlgo_KindOfDef.hxx
|
||||||
GEOMAlgo_KindOfName.hxx
|
GEOMAlgo_KindOfName.hxx
|
||||||
GEOMAlgo_KindOfShape.hxx
|
GEOMAlgo_KindOfShape.hxx
|
||||||
GEOMAlgo_ListIteratorOfListOfCoupleOfShapes.hxx
|
GEOMAlgo_ListIteratorOfListOfCoupleOfShapes.hxx
|
||||||
|
@ -11,25 +11,28 @@ GEOMAlgo_ShellSolid.cxx
|
|||||||
GEOMAlgo_AlgoTools.hxx
|
GEOMAlgo_AlgoTools.hxx
|
||||||
GEOMAlgo_AlgoTools.cxx
|
GEOMAlgo_AlgoTools.cxx
|
||||||
GEOMAlgo_AlgoTools_1.cxx
|
GEOMAlgo_AlgoTools_1.cxx
|
||||||
GEOMAlgo_AlgoTools_2.cxx
|
|
||||||
GEOMAlgo_SolidSolid.hxx
|
GEOMAlgo_SolidSolid.hxx
|
||||||
GEOMAlgo_SolidSolid.cxx
|
GEOMAlgo_SolidSolid.cxx
|
||||||
GEOMAlgo_ShapeAlgo.hxx
|
GEOMAlgo_ShapeAlgo.hxx
|
||||||
GEOMAlgo_ShapeAlgo.cxx
|
GEOMAlgo_ShapeAlgo.cxx
|
||||||
|
GEOMAlgo_FinderShapeOn.hxx
|
||||||
|
GEOMAlgo_FinderShapeOn.cxx
|
||||||
|
GEOMAlgo_FinderShapeOn1.hxx
|
||||||
|
GEOMAlgo_FinderShapeOn1.cxx
|
||||||
GEOMAlgo_HAlgo.hxx
|
GEOMAlgo_HAlgo.hxx
|
||||||
GEOMAlgo_HAlgo.cxx
|
GEOMAlgo_HAlgo.cxx
|
||||||
GEOMAlgo_Clsf.hxx
|
GEOMAlgo_Clsf.hxx
|
||||||
GEOMAlgo_Clsf.cxx
|
GEOMAlgo_Clsf.cxx
|
||||||
GEOMAlgo_ClsfBox.hxx
|
GEOMAlgo_ClsfBox.hxx
|
||||||
GEOMAlgo_ClsfBox.cxx
|
GEOMAlgo_ClsfBox.cxx
|
||||||
GEOMAlgo_ClsfQuad.hxx
|
|
||||||
GEOMAlgo_ClsfQuad.cxx
|
|
||||||
GEOMAlgo_ClsfSolid.hxx
|
GEOMAlgo_ClsfSolid.hxx
|
||||||
GEOMAlgo_ClsfSolid.cxx
|
GEOMAlgo_ClsfSolid.cxx
|
||||||
GEOMAlgo_ClsfSurf.hxx
|
GEOMAlgo_ClsfSurf.hxx
|
||||||
GEOMAlgo_ClsfSurf.cxx
|
GEOMAlgo_ClsfSurf.cxx
|
||||||
GEOMAlgo_FinderShapeOn2.hxx
|
GEOMAlgo_FinderShapeOn2.hxx
|
||||||
GEOMAlgo_FinderShapeOn2.cxx
|
GEOMAlgo_FinderShapeOn2.cxx
|
||||||
|
GEOMAlgo_FinderShapeOnQuad.hxx
|
||||||
|
GEOMAlgo_FinderShapeOnQuad.cxx
|
||||||
GEOMAlgo_Gluer.hxx
|
GEOMAlgo_Gluer.hxx
|
||||||
GEOMAlgo_Gluer.cxx
|
GEOMAlgo_Gluer.cxx
|
||||||
GEOMAlgo_GlueAnalyser.hxx
|
GEOMAlgo_GlueAnalyser.hxx
|
||||||
@ -50,8 +53,6 @@ GEOMAlgo_GetInPlace.cxx
|
|||||||
GEOMAlgo_GetInPlace_1.cxx
|
GEOMAlgo_GetInPlace_1.cxx
|
||||||
GEOMAlgo_GetInPlace_2.cxx
|
GEOMAlgo_GetInPlace_2.cxx
|
||||||
GEOMAlgo_GetInPlace_3.cxx
|
GEOMAlgo_GetInPlace_3.cxx
|
||||||
GEOMAlgo_GetInPlaceAPI.hxx
|
|
||||||
GEOMAlgo_GetInPlaceAPI.cxx
|
|
||||||
GEOMAlgo_Splitter.hxx
|
GEOMAlgo_Splitter.hxx
|
||||||
GEOMAlgo_Splitter.cxx
|
GEOMAlgo_Splitter.cxx
|
||||||
GEOMAlgo_ShapeInfoFiller.hxx
|
GEOMAlgo_ShapeInfoFiller.hxx
|
||||||
@ -106,3 +107,5 @@ GEOMAlgo_ShapeInfo.cxx
|
|||||||
GEOMAlgo_IndexedDataMapOfShapeShapeInfo.hxx
|
GEOMAlgo_IndexedDataMapOfShapeShapeInfo.hxx
|
||||||
|
|
||||||
Basics_OCCTVersion.hxx
|
Basics_OCCTVersion.hxx
|
||||||
|
|
||||||
|
GEOMAlgo_KindOfDef.hxx
|
||||||
|
0
src/GEOMAlgo/GEOMAlgo.cdl
Executable file → Normal file
@ -93,15 +93,15 @@ static
|
|||||||
Standard_Integer& iCnt);
|
Standard_Integer& iCnt);
|
||||||
static
|
static
|
||||||
void CopySource(const TopoDS_Shape& aS,
|
void CopySource(const TopoDS_Shape& aS,
|
||||||
TopTools_IndexedDataMapOfShapeShape& aMapSS,
|
TopTools_IndexedDataMapOfShapeShape& aMapSS,
|
||||||
TopoDS_Shape& aSC);
|
TopoDS_Shape& aSC);
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : CopyShape
|
//function : CopyShape
|
||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::CopyShape(const TopoDS_Shape& aS,
|
void GEOMAlgo_AlgoTools::CopyShape(const TopoDS_Shape& aS,
|
||||||
TopoDS_Shape& aSC)
|
TopoDS_Shape& aSC)
|
||||||
{
|
{
|
||||||
TopTools_IndexedDataMapOfShapeShape aMapSS;
|
TopTools_IndexedDataMapOfShapeShape aMapSS;
|
||||||
//
|
//
|
||||||
@ -112,8 +112,8 @@ void GEOMAlgo_AlgoTools::CopyShape(const TopoDS_Shape& aS,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::CopyShape(const TopoDS_Shape& aS,
|
void GEOMAlgo_AlgoTools::CopyShape(const TopoDS_Shape& aS,
|
||||||
TopoDS_Shape& aSC,
|
TopoDS_Shape& aSC,
|
||||||
TopTools_IndexedDataMapOfShapeShape& aMapSS)
|
TopTools_IndexedDataMapOfShapeShape& aMapSS)
|
||||||
{
|
{
|
||||||
CopySource(aS, aMapSS, aSC);
|
CopySource(aS, aMapSS, aSC);
|
||||||
}
|
}
|
||||||
@ -172,9 +172,9 @@ void CopySource(const TopoDS_Shape& aS,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::FaceNormal (const TopoDS_Face& aF,
|
void GEOMAlgo_AlgoTools::FaceNormal (const TopoDS_Face& aF,
|
||||||
const Standard_Real U,
|
const Standard_Real U,
|
||||||
const Standard_Real V,
|
const Standard_Real V,
|
||||||
gp_Vec& aN)
|
gp_Vec& aN)
|
||||||
{
|
{
|
||||||
gp_Pnt aPnt ;
|
gp_Pnt aPnt ;
|
||||||
gp_Vec aD1U, aD1V;
|
gp_Vec aD1U, aD1V;
|
||||||
@ -343,7 +343,7 @@ Standard_Integer GEOMAlgo_AlgoTools::BuildPCurveForEdgeOnFace
|
|||||||
// purpose:
|
// purpose:
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::MakeContainer(const TopAbs_ShapeEnum theType,
|
void GEOMAlgo_AlgoTools::MakeContainer(const TopAbs_ShapeEnum theType,
|
||||||
TopoDS_Shape& theC)
|
TopoDS_Shape& theC)
|
||||||
{
|
{
|
||||||
BRep_Builder aBB;
|
BRep_Builder aBB;
|
||||||
//
|
//
|
||||||
@ -412,9 +412,9 @@ Standard_Boolean GEOMAlgo_AlgoTools::IsUPeriodic(const Handle(Geom_Surface) &aS
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::RefinePCurveForEdgeOnFace(const TopoDS_Edge& aE,
|
void GEOMAlgo_AlgoTools::RefinePCurveForEdgeOnFace(const TopoDS_Edge& aE,
|
||||||
const TopoDS_Face& aF,
|
const TopoDS_Face& aF,
|
||||||
const Standard_Real aUMin,
|
const Standard_Real aUMin,
|
||||||
const Standard_Real aUMax)
|
const Standard_Real aUMax)
|
||||||
{
|
{
|
||||||
Standard_Real aT1, aT2, aTx, aUx, aTol;
|
Standard_Real aT1, aT2, aTx, aUx, aTol;
|
||||||
gp_Pnt2d aP2D;
|
gp_Pnt2d aP2D;
|
||||||
@ -559,7 +559,7 @@ Standard_Boolean GEOMAlgo_AlgoTools::ProjectPointOnShape
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
||||||
gp_Pnt& aP3D)
|
gp_Pnt& aP3D)
|
||||||
{
|
{
|
||||||
Standard_Real aTx, aT1, aT2;
|
Standard_Real aTx, aT1, aT2;
|
||||||
//
|
//
|
||||||
@ -572,8 +572,8 @@ void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
||||||
const Standard_Real aT,
|
const Standard_Real aT,
|
||||||
gp_Pnt& aP3D)
|
gp_Pnt& aP3D)
|
||||||
{
|
{
|
||||||
Standard_Real aT1, aT2;
|
Standard_Real aT1, aT2;
|
||||||
Handle(Geom_Curve) aC3D;
|
Handle(Geom_Curve) aC3D;
|
||||||
@ -586,9 +586,9 @@ void GEOMAlgo_AlgoTools::PointOnEdge(const TopoDS_Edge& aE,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
||||||
const Standard_Real aU,
|
const Standard_Real aU,
|
||||||
const Standard_Real aV,
|
const Standard_Real aV,
|
||||||
gp_Pnt& aP3D)
|
gp_Pnt& aP3D)
|
||||||
{
|
{
|
||||||
Handle(Geom_Surface) aS;
|
Handle(Geom_Surface) aS;
|
||||||
//
|
//
|
||||||
@ -600,7 +600,7 @@ void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
||||||
gp_Pnt& aP3D)
|
gp_Pnt& aP3D)
|
||||||
{
|
{
|
||||||
Standard_Real aU, aV, aUMin, aUMax, aVMin, aVMax;
|
Standard_Real aU, aV, aUMin, aUMax, aVMin, aVMax;
|
||||||
//
|
//
|
||||||
@ -616,7 +616,7 @@ void GEOMAlgo_AlgoTools::PointOnFace(const TopoDS_Face& aF,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_AlgoTools::PointOnShape(const TopoDS_Shape& aS,
|
void GEOMAlgo_AlgoTools::PointOnShape(const TopoDS_Shape& aS,
|
||||||
gp_Pnt& aP3D)
|
gp_Pnt& aP3D)
|
||||||
{
|
{
|
||||||
TopAbs_ShapeEnum aType;
|
TopAbs_ShapeEnum aType;
|
||||||
//
|
//
|
||||||
@ -713,7 +713,7 @@ Standard_Integer GEOMAlgo_AlgoTools::FindSDShapes
|
|||||||
return 0; // Nothing to do
|
return 0; // Nothing to do
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
while(1) {
|
for(;;) {
|
||||||
aNbEProcessed=aMProcessed.Extent();
|
aNbEProcessed=aMProcessed.Extent();
|
||||||
if (aNbEProcessed==aNbE) {
|
if (aNbEProcessed==aNbE) {
|
||||||
break;
|
break;
|
||||||
@ -922,8 +922,8 @@ void GetCount(const TopoDS_Shape& aS,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
Standard_Integer GEOMAlgo_AlgoTools::PntInFace(const TopoDS_Face& aF,
|
Standard_Integer GEOMAlgo_AlgoTools::PntInFace(const TopoDS_Face& aF,
|
||||||
gp_Pnt& theP,
|
gp_Pnt& theP,
|
||||||
gp_Pnt2d& theP2D)
|
gp_Pnt2d& theP2D)
|
||||||
{
|
{
|
||||||
Standard_Boolean bIsDone, bHasFirstPoint, bHasSecondPoint;
|
Standard_Boolean bIsDone, bHasFirstPoint, bHasSecondPoint;
|
||||||
Standard_Integer iErr, aIx, aNbDomains, i;
|
Standard_Integer iErr, aIx, aNbDomains, i;
|
||||||
@ -948,8 +948,8 @@ Standard_Integer GEOMAlgo_AlgoTools::PntInFace(const TopoDS_Face& aF,
|
|||||||
//
|
//
|
||||||
Geom2dHatch_Intersector aIntr(aTotArcIntr, aTolTangfIntr);
|
Geom2dHatch_Intersector aIntr(aTotArcIntr, aTolTangfIntr);
|
||||||
Geom2dHatch_Hatcher aHatcher(aIntr,
|
Geom2dHatch_Hatcher aHatcher(aIntr,
|
||||||
aTolHatch2D, aTolHatch3D,
|
aTolHatch2D, aTolHatch3D,
|
||||||
Standard_True, Standard_False);
|
Standard_True, Standard_False);
|
||||||
//
|
//
|
||||||
iErr=0;
|
iErr=0;
|
||||||
aEpsT=1.e-12;
|
aEpsT=1.e-12;
|
||||||
@ -1004,30 +1004,33 @@ Standard_Integer GEOMAlgo_AlgoTools::PntInFace(const TopoDS_Face& aF,
|
|||||||
}
|
}
|
||||||
//
|
//
|
||||||
// 4.
|
// 4.
|
||||||
|
aVx=aVMin;
|
||||||
aNbDomains=aHatcher.NbDomains(aIx);
|
aNbDomains=aHatcher.NbDomains(aIx);
|
||||||
for (i=1; i<=aNbDomains; ++i) {
|
if (!aNbDomains) {
|
||||||
const HatchGen_Domain& aDomain=aHatcher.Domain (aIx, i) ;
|
iErr=5;
|
||||||
bHasFirstPoint=aDomain.HasFirstPoint();
|
return iErr;
|
||||||
if (!bHasFirstPoint) {
|
|
||||||
iErr=5;
|
|
||||||
return iErr;
|
|
||||||
}
|
|
||||||
//
|
|
||||||
aV1=aDomain.FirstPoint().Parameter();
|
|
||||||
//
|
|
||||||
bHasSecondPoint=aDomain.HasSecondPoint();
|
|
||||||
if (!bHasSecondPoint) {
|
|
||||||
iErr=6;
|
|
||||||
return iErr;
|
|
||||||
}
|
|
||||||
//
|
|
||||||
aV2=aDomain.SecondPoint().Parameter();
|
|
||||||
//
|
|
||||||
aVx=IntTools_Tools::IntermediatePoint(aV1, aV2);
|
|
||||||
//
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
|
i=1;
|
||||||
|
const HatchGen_Domain& aDomain=aHatcher.Domain (aIx, i) ;
|
||||||
|
bHasFirstPoint=aDomain.HasFirstPoint();
|
||||||
|
if (!bHasFirstPoint) {
|
||||||
|
iErr=5;
|
||||||
|
return iErr;
|
||||||
|
}
|
||||||
|
//
|
||||||
|
aV1=aDomain.FirstPoint().Parameter();
|
||||||
|
//
|
||||||
|
bHasSecondPoint=aDomain.HasSecondPoint();
|
||||||
|
if (!bHasSecondPoint) {
|
||||||
|
iErr=6;
|
||||||
|
return iErr;
|
||||||
|
}
|
||||||
|
//
|
||||||
|
aV2=aDomain.SecondPoint().Parameter();
|
||||||
|
//
|
||||||
|
aVx=IntTools_Tools::IntermediatePoint(aV1, aV2);
|
||||||
|
//
|
||||||
aS->D0(aUx, aVx, aPx);
|
aS->D0(aUx, aVx, aPx);
|
||||||
//
|
//
|
||||||
theP2D.SetCoord(aUx, aVx);
|
theP2D.SetCoord(aUx, aVx);
|
||||||
|
@ -62,7 +62,6 @@
|
|||||||
#include <BRepLib_MakeFace.hxx>
|
#include <BRepLib_MakeFace.hxx>
|
||||||
#include <BRepLib_FaceError.hxx>
|
#include <BRepLib_FaceError.hxx>
|
||||||
|
|
||||||
//#include <BOPTools_DSFiller.hxx>
|
|
||||||
|
|
||||||
#include <GEOMAlgo_WireSolid.hxx>
|
#include <GEOMAlgo_WireSolid.hxx>
|
||||||
#include <GEOMAlgo_ShellSolid.hxx>
|
#include <GEOMAlgo_ShellSolid.hxx>
|
||||||
@ -300,7 +299,6 @@ void GEOMAlgo_FinderShapeOn::Find(const TopoDS_Shape& aS)
|
|||||||
{
|
{
|
||||||
myErrorStatus=0;
|
myErrorStatus=0;
|
||||||
//
|
//
|
||||||
Standard_Boolean bIsDone;
|
|
||||||
Standard_Integer i, iErr;
|
Standard_Integer i, iErr;
|
||||||
TopAbs_State aSts[]={TopAbs_IN, TopAbs_OUT, TopAbs_ON};
|
TopAbs_State aSts[]={TopAbs_IN, TopAbs_OUT, TopAbs_ON};
|
||||||
TopTools_ListIteratorOfListOfShape aIt;
|
TopTools_ListIteratorOfListOfShape aIt;
|
||||||
|
@ -309,6 +309,9 @@ void GEOMAlgo_FinderShapeOn1::ProcessEdges()
|
|||||||
aType1=myGAS.GetType();
|
aType1=myGAS.GetType();
|
||||||
//
|
//
|
||||||
TopExp::MapShapes(myShape, TopAbs_EDGE, aM);
|
TopExp::MapShapes(myShape, TopAbs_EDGE, aM);
|
||||||
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aNb=aM.Extent();
|
aNb=aM.Extent();
|
||||||
for (i=1; i<=aNb; ++i) {
|
for (i=1; i<=aNb; ++i) {
|
||||||
GEOMAlgo_ListOfPnt aLP;
|
GEOMAlgo_ListOfPnt aLP;
|
||||||
@ -427,6 +430,8 @@ void GEOMAlgo_FinderShapeOn1::ProcessFaces()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aExp.Init(aF, TopAbs_EDGE);
|
aExp.Init(aF, TopAbs_EDGE);
|
||||||
for (; aExp.More(); aExp.Next()) {
|
for (; aExp.More(); aExp.Next()) {
|
||||||
const TopoDS_Shape& aE=aExp.Current();
|
const TopoDS_Shape& aE=aExp.Current();
|
||||||
@ -500,6 +505,9 @@ void GEOMAlgo_FinderShapeOn1::ProcessSolids()
|
|||||||
const TopoDS_Shape& aSd=aM(i);
|
const TopoDS_Shape& aSd=aM(i);
|
||||||
aMF.Clear();
|
aMF.Clear();
|
||||||
TopExp::MapShapes(aSd, TopAbs_FACE, aMF);
|
TopExp::MapShapes(aSd, TopAbs_FACE, aMF);
|
||||||
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aNbF=aMF.Extent();
|
aNbF=aMF.Extent();
|
||||||
for (j=1; j<=aNbF; ++j) {
|
for (j=1; j<=aNbF; ++j) {
|
||||||
const TopoDS_Shape& aF=aMF(j);
|
const TopoDS_Shape& aF=aMF(j);
|
||||||
@ -660,7 +668,6 @@ void GEOMAlgo_FinderShapeOn1::InnerPoints(const TopoDS_Face& aF,
|
|||||||
}// if (aType==GeomAbs_Plane || aType==GeomAbs_Cylinder)
|
}// if (aType==GeomAbs_Plane || aType==GeomAbs_Cylinder)
|
||||||
}// if (!aNb && myNbPntsMin) {
|
}// if (!aNb && myNbPntsMin) {
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Thu Jan 26 09:56:20 2012f
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : InnerPoints
|
//function : InnerPoints
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -676,7 +683,6 @@ void GEOMAlgo_FinderShapeOn1::InnerPoints(const TopoDS_Edge& aE,
|
|||||||
aLP.Clear();
|
aLP.Clear();
|
||||||
InnerPoints(aE, aNbPntsMin, aLP);
|
InnerPoints(aE, aNbPntsMin, aLP);
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Thu Jan 26 09:56:32 2012t
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : InnerPoints
|
//function : InnerPoints
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -702,16 +708,6 @@ void GEOMAlgo_FinderShapeOn1::InnerPoints(const TopoDS_Edge& aE,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
//modified by NIZNHY-PKV Thu Jan 26 09:51:20 2012f
|
|
||||||
/*
|
|
||||||
aNbT=myNbPntsMin+1;
|
|
||||||
dT=(aT2-aT1)/aNbT;
|
|
||||||
for (j=1; j<=aNbPntsMin; ++j) {
|
|
||||||
aT=aT1+j*dT;
|
|
||||||
aC3D->D0(aT, aP);
|
|
||||||
aLP.Append(aP);
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
aNbT=aNbPntsMin+1;
|
aNbT=aNbPntsMin+1;
|
||||||
dT=(aT2-aT1)/aNbT;
|
dT=(aT2-aT1)/aNbT;
|
||||||
for (j=1; j<aNbT; ++j) {
|
for (j=1; j<aNbT; ++j) {
|
||||||
@ -719,7 +715,6 @@ void GEOMAlgo_FinderShapeOn1::InnerPoints(const TopoDS_Edge& aE,
|
|||||||
aC3D->D0(aT, aP);
|
aC3D->D0(aT, aP);
|
||||||
aLP.Append(aP);
|
aLP.Append(aP);
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Thu Jan 26 09:51:24 2012t
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
|
@ -362,6 +362,8 @@ void GEOMAlgo_FinderShapeOn2::ProcessEdges()
|
|||||||
//
|
//
|
||||||
const TopoDS_Edge& aE=TopoDS::Edge(aM(i));
|
const TopoDS_Edge& aE=TopoDS::Edge(aM(i));
|
||||||
//
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aExp.Init(aE, TopAbs_VERTEX);
|
aExp.Init(aE, TopAbs_VERTEX);
|
||||||
for (; aExp.More(); aExp.Next()) {
|
for (; aExp.More(); aExp.Next()) {
|
||||||
const TopoDS_Shape& aV=aExp.Current();
|
const TopoDS_Shape& aV=aExp.Current();
|
||||||
@ -475,6 +477,9 @@ void GEOMAlgo_FinderShapeOn2::ProcessFaces()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aExp.Init(aF, TopAbs_EDGE);
|
aExp.Init(aF, TopAbs_EDGE);
|
||||||
for (; aExp.More(); aExp.Next()) {
|
for (; aExp.More(); aExp.Next()) {
|
||||||
const TopoDS_Shape& aE=aExp.Current();
|
const TopoDS_Shape& aE=aExp.Current();
|
||||||
@ -558,6 +563,9 @@ void GEOMAlgo_FinderShapeOn2::ProcessSolids()
|
|||||||
const TopoDS_Shape& aSd=aM(i);
|
const TopoDS_Shape& aSd=aM(i);
|
||||||
aMF.Clear();
|
aMF.Clear();
|
||||||
TopExp::MapShapes(aSd, TopAbs_FACE, aMF);
|
TopExp::MapShapes(aSd, TopAbs_FACE, aMF);
|
||||||
|
//
|
||||||
|
bIsConformState=Standard_False;
|
||||||
|
//
|
||||||
aNbF=aMF.Extent();
|
aNbF=aMF.Extent();
|
||||||
for (j=1; j<=aNbF; ++j) {
|
for (j=1; j<=aNbF; ++j) {
|
||||||
const TopoDS_Shape& aF=aMF(j);
|
const TopoDS_Shape& aF=aMF(j);
|
||||||
|
@ -126,93 +126,75 @@ Standard_Integer GEOMAlgo_GetInPlaceAPI::GetInPlaceOld
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
TopoDS_Shape aPntShape;
|
// Check shape type.
|
||||||
TopoDS_Vertex aVertex;
|
TopAbs_ShapeEnum iType = GEOMUtils::GetTypeOfSimplePart(theWhat);
|
||||||
bool isFound = false;
|
|
||||||
TopAbs_ShapeEnum iType = TopAbs_SOLID;
|
|
||||||
//Standard_Real aWhat_Mass = 0., aWhere_Mass = 0.;
|
|
||||||
Standard_Real tab_aWhat[4], tab_aWhere[4];
|
|
||||||
Standard_Real dl_l = 1e-3;
|
|
||||||
Standard_Real min_l, Tol_0D, Tol_1D, Tol_2D, Tol_3D, Tol_Mass;
|
|
||||||
Standard_Real aXmin, aYmin, aZmin, aXmax, aYmax, aZmax;
|
|
||||||
Bnd_Box BoundingBox;
|
|
||||||
gp_Pnt aPnt, aPnt_aWhat, tab_Pnt[2];
|
|
||||||
GProp_GProps aProps;
|
|
||||||
|
|
||||||
iType = GEOMUtils::GetTypeOfSimplePart(theWhat);
|
|
||||||
if (iType == TopAbs_SHAPE) {
|
if (iType == TopAbs_SHAPE) {
|
||||||
// Error: An attempt to extract a shape of not supported type.
|
// Error: An attempt to extract a shape of not supported type.
|
||||||
return 2;
|
return 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
TopExp_Explorer Exp_aWhat ( theWhat, iType );
|
// Compute confusion tolerance.
|
||||||
TopExp_Explorer Exp_aWhere ( theWhere, iType );
|
Standard_Real aTolConf = Precision::Confusion();
|
||||||
TopExp_Explorer Exp_Edge ( theWhere, TopAbs_EDGE );
|
Standard_Integer i;
|
||||||
|
|
||||||
// Find the shortest edge in theShapeWhere shape
|
for (i = 0; i < 2; ++i) {
|
||||||
BRepBndLib::Add(theWhere, BoundingBox);
|
TopExp_Explorer anExp(i == 0 ? theWhere : theWhat, TopAbs_VERTEX);
|
||||||
BoundingBox.Get(aXmin, aYmin, aZmin, aXmax, aYmax, aZmax);
|
|
||||||
min_l = fabs(aXmax - aXmin);
|
for (; anExp.More(); anExp.Next()) {
|
||||||
if( min_l < fabs(aYmax - aYmin) ) min_l = fabs(aYmax - aYmin);
|
const TopoDS_Vertex aVtx = TopoDS::Vertex(anExp.Current());
|
||||||
if( min_l < fabs(aZmax - aZmin) ) min_l = fabs(aZmax - aZmin);
|
const Standard_Real aTolVtx = BRep_Tool::Tolerance(aVtx);
|
||||||
min_l /= dl_l;
|
|
||||||
// Mantis issue 0020908 BEGIN
|
if (aTolVtx > aTolConf) {
|
||||||
if (!Exp_Edge.More()) {
|
aTolConf = aTolVtx;
|
||||||
min_l = Precision::Confusion();
|
}
|
||||||
}
|
|
||||||
// Mantis issue 0020908 END
|
|
||||||
for ( Standard_Integer nbEdge = 0; Exp_Edge.More(); Exp_Edge.Next(), nbEdge++ ) {
|
|
||||||
TopExp_Explorer Exp_Vertex( Exp_Edge.Current(), TopAbs_VERTEX);
|
|
||||||
for ( Standard_Integer nbVertex = 0; Exp_Vertex.More(); Exp_Vertex.Next(), nbVertex++ ) {
|
|
||||||
aPnt = BRep_Tool::Pnt( TopoDS::Vertex( Exp_Vertex.Current() ) );
|
|
||||||
tab_Pnt[nbVertex] = aPnt;
|
|
||||||
}
|
|
||||||
if ( ! tab_Pnt[0].IsEqual(tab_Pnt[1], dl_l) ) {
|
|
||||||
BRepGProp::LinearProperties(Exp_Edge.Current(), aProps);
|
|
||||||
if ( aProps.Mass() < min_l ) min_l = aProps.Mass();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Compute tolerances
|
// Compute mass tolerance.
|
||||||
Tol_0D = dl_l;
|
Bnd_Box aBoundingBox;
|
||||||
Tol_1D = dl_l * min_l;
|
Standard_Real aXmin, aYmin, aZmin, aXmax, aYmax, aZmax;
|
||||||
Tol_2D = dl_l * ( min_l * min_l) * ( 2. + dl_l);
|
Standard_Real aMassTol;
|
||||||
Tol_3D = dl_l * ( min_l * min_l * min_l ) * ( 3. + (3 * dl_l) + (dl_l * dl_l) );
|
|
||||||
|
|
||||||
if (Tol_0D < Precision::Confusion()) Tol_0D = Precision::Confusion();
|
BRepBndLib::Add(theWhere, aBoundingBox);
|
||||||
if (Tol_1D < Precision::Confusion()) Tol_1D = Precision::Confusion();
|
BRepBndLib::Add(theWhat, aBoundingBox);
|
||||||
if (Tol_2D < Precision::Confusion()) Tol_2D = Precision::Confusion();
|
aBoundingBox.Get(aXmin, aYmin, aZmin, aXmax, aYmax, aZmax);
|
||||||
if (Tol_3D < Precision::Confusion()) Tol_3D = Precision::Confusion();
|
aMassTol = Max(aXmax - aXmin, aYmax - aYmin);
|
||||||
|
aMassTol = Max(aMassTol, aZmax - aZmin);
|
||||||
|
aMassTol *= aTolConf;
|
||||||
|
|
||||||
Tol_Mass = Tol_3D;
|
// Compute the result.
|
||||||
if ( iType == TopAbs_VERTEX ) Tol_Mass = Tol_0D;
|
TopExp_Explorer Exp_aWhat (theWhat, iType);
|
||||||
else if ( iType == TopAbs_EDGE ) Tol_Mass = Tol_1D;
|
TopExp_Explorer Exp_aWhere (theWhere, iType);
|
||||||
else if ( iType == TopAbs_FACE ) Tol_Mass = Tol_2D;
|
Standard_Real tab_aWhat[4], tab_aWhere[4];
|
||||||
|
gp_Pnt aPnt, aPnt_aWhat;
|
||||||
// Searching for the sub-shapes inside the ShapeWhere shape
|
TopoDS_Shape aPntShape;
|
||||||
|
TopoDS_Vertex aVertex;
|
||||||
|
bool isFound = false;
|
||||||
TopTools_MapOfShape map_aWhere;
|
TopTools_MapOfShape map_aWhere;
|
||||||
for ( Exp_aWhere.ReInit(); Exp_aWhere.More(); Exp_aWhere.Next() ) {
|
|
||||||
|
for (; Exp_aWhere.More(); Exp_aWhere.Next()) {
|
||||||
if (!map_aWhere.Add(Exp_aWhere.Current()))
|
if (!map_aWhere.Add(Exp_aWhere.Current()))
|
||||||
continue; // skip repeated shape to avoid mass addition
|
continue; // skip repeated shape to avoid mass addition
|
||||||
GetShapeProperties( Exp_aWhere.Current(), tab_aWhere, aPnt );
|
GetShapeProperties( Exp_aWhere.Current(), tab_aWhere, aPnt );
|
||||||
for ( Exp_aWhat.ReInit(); Exp_aWhat.More(); Exp_aWhat.Next() ) {
|
for ( Exp_aWhat.ReInit(); Exp_aWhat.More(); Exp_aWhat.Next() ) {
|
||||||
GetShapeProperties( Exp_aWhat.Current(), tab_aWhat, aPnt_aWhat );
|
GetShapeProperties( Exp_aWhat.Current(), tab_aWhat, aPnt_aWhat );
|
||||||
if ( fabs(tab_aWhat[3] - tab_aWhere[3]) <= Tol_Mass && aPnt_aWhat.Distance(aPnt) <= Tol_1D )
|
if (fabs(tab_aWhat[3] - tab_aWhere[3]) <= aMassTol && aPnt_aWhat.Distance(aPnt) <= aTolConf)
|
||||||
isFound = true;
|
isFound = true;
|
||||||
else {
|
else {
|
||||||
if ( (tab_aWhat[3] - tab_aWhere[3]) > Tol_Mass ) {
|
if (tab_aWhat[3] > tab_aWhere[3]) {
|
||||||
aPntShape = BRepBuilderAPI_MakeVertex( aPnt ).Shape();
|
aPntShape = BRepBuilderAPI_MakeVertex( aPnt ).Shape();
|
||||||
aVertex = TopoDS::Vertex( aPntShape );
|
aVertex = TopoDS::Vertex( aPntShape );
|
||||||
BRepExtrema_DistShapeShape aWhereDistance ( aVertex, Exp_aWhere.Current() );
|
BRepExtrema_DistShapeShape aWhereDistance ( aVertex, Exp_aWhere.Current() );
|
||||||
BRepExtrema_DistShapeShape aWhatDistance ( aVertex, Exp_aWhat.Current() );
|
BRepExtrema_DistShapeShape aWhatDistance ( aVertex, Exp_aWhat.Current() );
|
||||||
if ( aWhereDistance.IsDone() && aWhatDistance.IsDone() &&
|
if (aWhereDistance.IsDone() && aWhatDistance.IsDone() &&
|
||||||
fabs(aWhereDistance.Value() - aWhatDistance.Value()) <= Tol_1D )
|
fabs(aWhereDistance.Value() - aWhatDistance.Value()) <= aTolConf)
|
||||||
{
|
{
|
||||||
// 0020162: "EDF 961 GEOM : Getinplace is getting additionnal orthogonal faces"
|
// 0020162: "EDF 961 GEOM : Getinplace is getting additionnal orthogonal faces"
|
||||||
// aVertex must be projected to the same point on Where and on What
|
// aVertex must be projected to the same point on Where and on What
|
||||||
gp_Pnt pOnWhat = aWhatDistance.PointOnShape2(1);
|
gp_Pnt pOnWhat = aWhatDistance.PointOnShape2(1);
|
||||||
gp_Pnt pOnWhere = aWhereDistance.PointOnShape2(1);
|
gp_Pnt pOnWhere = aWhereDistance.PointOnShape2(1);
|
||||||
isFound = ( pOnWhat.Distance(pOnWhere) <= Tol_1D );
|
isFound = (pOnWhat.Distance(pOnWhere) <= aTolConf);
|
||||||
if ( isFound && iType == TopAbs_FACE )
|
if ( isFound && iType == TopAbs_FACE )
|
||||||
{
|
{
|
||||||
// check normals at pOnWhat and pOnWhere
|
// check normals at pOnWhat and pOnWhere
|
||||||
|
@ -239,7 +239,6 @@ Standard_Integer PntInSolid(const TopoDS_Solid& aZ,
|
|||||||
gp_Pnt aPx;
|
gp_Pnt aPx;
|
||||||
gp_Pnt2d aP2Dx;
|
gp_Pnt2d aP2Dx;
|
||||||
gp_Vec aDNx;
|
gp_Vec aDNx;
|
||||||
|
|
||||||
TopoDS_Face aF;
|
TopoDS_Face aF;
|
||||||
TopExp_Explorer aExp;
|
TopExp_Explorer aExp;
|
||||||
//
|
//
|
||||||
@ -247,9 +246,8 @@ Standard_Integer PntInSolid(const TopoDS_Solid& aZ,
|
|||||||
aCoef=10.;
|
aCoef=10.;
|
||||||
//
|
//
|
||||||
aExp.Init (aZ, TopAbs_FACE);
|
aExp.Init (aZ, TopAbs_FACE);
|
||||||
for (; aExp.More() ; aExp.Next()) {
|
if (aExp.More()) {
|
||||||
aF=*((TopoDS_Face*)&aExp.Current());
|
aF=*((TopoDS_Face*)&aExp.Current());
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
iErr=PntInFace(aF, aPx, aP2Dx);
|
iErr=PntInFace(aF, aPx, aP2Dx);
|
||||||
@ -368,29 +366,31 @@ Standard_Integer PntInFace(const TopoDS_Face& aF,
|
|||||||
//
|
//
|
||||||
// 4.
|
// 4.
|
||||||
aNbDomains=aHatcher.NbDomains(aIx);
|
aNbDomains=aHatcher.NbDomains(aIx);
|
||||||
for (i=1; i<=aNbDomains; ++i) {
|
if (!aNbDomains) {
|
||||||
const HatchGen_Domain& aDomain=aHatcher.Domain (aIx, i) ;
|
iErr=5;
|
||||||
bHasFirstPoint=aDomain.HasFirstPoint();
|
return iErr;
|
||||||
if (!bHasFirstPoint) {
|
|
||||||
iErr=5;
|
|
||||||
return iErr;
|
|
||||||
}
|
|
||||||
//
|
|
||||||
aV1=aDomain.FirstPoint().Parameter();
|
|
||||||
//
|
|
||||||
bHasSecondPoint=aDomain.HasSecondPoint();
|
|
||||||
if (!bHasSecondPoint) {
|
|
||||||
iErr=6;
|
|
||||||
return iErr;
|
|
||||||
}
|
|
||||||
//
|
|
||||||
aV2=aDomain.SecondPoint().Parameter();
|
|
||||||
//
|
|
||||||
aVx=IntTools_Tools::IntermediatePoint(aV1, aV2);
|
|
||||||
//
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
|
i=1;
|
||||||
|
const HatchGen_Domain& aDomain=aHatcher.Domain (aIx, i) ;
|
||||||
|
bHasFirstPoint=aDomain.HasFirstPoint();
|
||||||
|
if (!bHasFirstPoint) {
|
||||||
|
iErr=5;
|
||||||
|
return iErr;
|
||||||
|
}
|
||||||
|
//
|
||||||
|
aV1=aDomain.FirstPoint().Parameter();
|
||||||
|
//
|
||||||
|
bHasSecondPoint=aDomain.HasSecondPoint();
|
||||||
|
if (!bHasSecondPoint) {
|
||||||
|
iErr=6;
|
||||||
|
return iErr;
|
||||||
|
}
|
||||||
|
//
|
||||||
|
aV2=aDomain.SecondPoint().Parameter();
|
||||||
|
//
|
||||||
|
aVx=IntTools_Tools::IntermediatePoint(aV1, aV2);
|
||||||
|
//
|
||||||
aS->D0(aUx, aVx, aPx);
|
aS->D0(aUx, aVx, aPx);
|
||||||
//
|
//
|
||||||
theP2D.SetCoord(aUx, aVx);
|
theP2D.SetCoord(aUx, aVx);
|
||||||
|
@ -90,7 +90,6 @@ GEOMAlgo_GlueDetector::GEOMAlgo_GlueDetector()
|
|||||||
//=======================================================================
|
//=======================================================================
|
||||||
GEOMAlgo_GlueDetector::~GEOMAlgo_GlueDetector()
|
GEOMAlgo_GlueDetector::~GEOMAlgo_GlueDetector()
|
||||||
{}
|
{}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 12:26:50 2012f
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : StickedShapes
|
//function : StickedShapes
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -100,7 +99,6 @@ const TopTools_IndexedDataMapOfShapeListOfShape&
|
|||||||
{
|
{
|
||||||
return myStickedShapes;
|
return myStickedShapes;
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 12:26:54 2012t
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : Perform
|
//function : Perform
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -124,12 +122,10 @@ void GEOMAlgo_GlueDetector::Perform()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
//modified by NIZNHY-PKV Wed Mar 14 08:00:09 2012f
|
|
||||||
CheckDetected();
|
CheckDetected();
|
||||||
if (myErrorStatus) {
|
if (myErrorStatus) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Wed Mar 14 08:00:12 2012t
|
|
||||||
//
|
//
|
||||||
DetectEdges();
|
DetectEdges();
|
||||||
if (myErrorStatus) {
|
if (myErrorStatus) {
|
||||||
@ -206,7 +202,7 @@ void GEOMAlgo_GlueDetector::DetectVertices()
|
|||||||
TColStd_MapIteratorOfMapOfInteger aIt1;
|
TColStd_MapIteratorOfMapOfInteger aIt1;
|
||||||
//
|
//
|
||||||
aMIP.Add(i);
|
aMIP.Add(i);
|
||||||
while(1) {
|
for(;;) {
|
||||||
aNbIP=aMIP.Extent();
|
aNbIP=aMIP.Extent();
|
||||||
aIt1.Initialize(aMIP);
|
aIt1.Initialize(aMIP);
|
||||||
for(; aIt1.More(); aIt1.Next()) {
|
for(; aIt1.More(); aIt1.Next()) {
|
||||||
@ -460,7 +456,6 @@ void GEOMAlgo_GlueDetector::EdgePassKey(const TopoDS_Edge& aE,
|
|||||||
//
|
//
|
||||||
aPK.SetShapes(aLV);
|
aPK.SetShapes(aLV);
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 09:54:18 2012f
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : CheckDetected
|
//function : CheckDetected
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -607,4 +602,3 @@ Standard_Integer CheckAncesstors
|
|||||||
//
|
//
|
||||||
return iRet;
|
return iRet;
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 09:54:59 2012t
|
|
||||||
|
189
src/GEOMAlgo/GEOMAlgo_Gluer.cxx
Executable file → Normal file
@ -20,10 +20,10 @@
|
|||||||
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
|
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
|
||||||
//
|
//
|
||||||
|
|
||||||
// File: GEOMAlgo_Gluer.cxx
|
// File: GEOMAlgo_Gluer.cxx
|
||||||
// Created: Sat Dec 04 12:45:53 2004
|
// Created: Sat Dec 04 12:45:53 2004
|
||||||
// Author: Peter KURNEV
|
// Author: Peter KURNEV
|
||||||
// <peter@PREFEX>
|
// <peter@PREFEX>
|
||||||
//
|
//
|
||||||
#include <GEOMAlgo_Gluer.hxx>
|
#include <GEOMAlgo_Gluer.hxx>
|
||||||
|
|
||||||
@ -100,7 +100,7 @@
|
|||||||
//
|
//
|
||||||
static
|
static
|
||||||
void GetSubShapes(const TopoDS_Shape& aS,
|
void GetSubShapes(const TopoDS_Shape& aS,
|
||||||
TopTools_IndexedMapOfShape& aMSS);
|
TopTools_IndexedMapOfShape& aMSS);
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : GEOMAlgo_Gluer
|
//function : GEOMAlgo_Gluer
|
||||||
@ -228,10 +228,7 @@ void GEOMAlgo_Gluer::MakeVertices()
|
|||||||
TopTools_DataMapIteratorOfDataMapOfShapeListOfShape aItIm;
|
TopTools_DataMapIteratorOfDataMapOfShapeListOfShape aItIm;
|
||||||
TopTools_DataMapOfShapeListOfShape aMVV;
|
TopTools_DataMapOfShapeListOfShape aMVV;
|
||||||
GEOMAlgo_IndexedDataMapOfIntegerShape aMIS;
|
GEOMAlgo_IndexedDataMapOfIntegerShape aMIS;
|
||||||
//modified by NIZNHY-PKV Thu Jan 21 10:03:07 2010f
|
|
||||||
//GEOMAlgo_IndexedDataMapOfShapeBox aMSB;
|
|
||||||
GEOMAlgo_IndexedDataMapOfShapeBndSphere aMSB;
|
GEOMAlgo_IndexedDataMapOfShapeBndSphere aMSB;
|
||||||
//modified by NIZNHY-PKV Thu Jan 21 10:03:10 2010t
|
|
||||||
//
|
//
|
||||||
GEOMAlgo_BndSphereTreeSelector aSelector;
|
GEOMAlgo_BndSphereTreeSelector aSelector;
|
||||||
GEOMAlgo_BndSphereTree aBBTree;
|
GEOMAlgo_BndSphereTree aBBTree;
|
||||||
@ -278,57 +275,54 @@ void GEOMAlgo_Gluer::MakeVertices()
|
|||||||
TColStd_MapIteratorOfMapOfInteger aIt1;
|
TColStd_MapIteratorOfMapOfInteger aIt1;
|
||||||
//
|
//
|
||||||
aMIP.Add(i);
|
aMIP.Add(i);
|
||||||
while(1) {
|
for(;;) {
|
||||||
aNbIP=aMIP.Extent();
|
aNbIP=aMIP.Extent();
|
||||||
aIt1.Initialize(aMIP);
|
aIt1.Initialize(aMIP);
|
||||||
for(; aIt1.More(); aIt1.Next()) {
|
for(; aIt1.More(); aIt1.Next()) {
|
||||||
aIP=aIt1.Key();
|
aIP=aIt1.Key();
|
||||||
if (aMIPC.Contains(aIP)) {
|
if (aMIPC.Contains(aIP)) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
const TopoDS_Shape& aVP=aMIS.FindFromKey(aIP);
|
const TopoDS_Shape& aVP=aMIS.FindFromKey(aIP);
|
||||||
//modified by NIZNHY-PKV Thu Jan 21 10:04:09 2010f
|
const GEOMAlgo_BndSphere& aBoxVP=aMSB.FindFromKey(aVP);
|
||||||
const GEOMAlgo_BndSphere& aBoxVP=aMSB.FindFromKey(aVP);
|
//
|
||||||
//const Bnd_Box& aBoxVP=aMSB.FindFromKey(aVP);
|
aSelector.Clear();
|
||||||
//modified by NIZNHY-PKV Thu Jan 21 10:04:11 2010t
|
aSelector.SetBox(aBoxVP);
|
||||||
//
|
//
|
||||||
aSelector.Clear();
|
aNbVSD=aBBTree.Select(aSelector);
|
||||||
aSelector.SetBox(aBoxVP);
|
if (!aNbVSD) {
|
||||||
//
|
continue; // it must not be
|
||||||
aNbVSD=aBBTree.Select(aSelector);
|
}
|
||||||
if (!aNbVSD) {
|
//
|
||||||
continue; // it must not be
|
const TColStd_ListOfInteger& aLI=aSelector.Indices();
|
||||||
}
|
//
|
||||||
//
|
aIt.Initialize(aLI);
|
||||||
const TColStd_ListOfInteger& aLI=aSelector.Indices();
|
for (; aIt.More(); aIt.Next()) {
|
||||||
//
|
aIP1=aIt.Value();
|
||||||
aIt.Initialize(aLI);
|
if (aMIP.Contains(aIP1)) {
|
||||||
for (; aIt.More(); aIt.Next()) {
|
continue;
|
||||||
aIP1=aIt.Value();
|
}
|
||||||
if (aMIP.Contains(aIP1)) {
|
aMIP1.Add(aIP1);
|
||||||
continue;
|
} //for (; aIt.More(); aIt.Next()) {
|
||||||
}
|
|
||||||
aMIP1.Add(aIP1);
|
|
||||||
} //for (; aIt.More(); aIt.Next()) {
|
|
||||||
}//for(; aIt1.More(); aIt1.Next()) {
|
}//for(; aIt1.More(); aIt1.Next()) {
|
||||||
//
|
//
|
||||||
aNbIP1=aMIP1.Extent();
|
aNbIP1=aMIP1.Extent();
|
||||||
if (!aNbIP1) {
|
if (!aNbIP1) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
aIt1.Initialize(aMIP);
|
aIt1.Initialize(aMIP);
|
||||||
for(; aIt1.More(); aIt1.Next()) {
|
for(; aIt1.More(); aIt1.Next()) {
|
||||||
aIP=aIt1.Key();
|
aIP=aIt1.Key();
|
||||||
aMIPC.Add(aIP);
|
aMIPC.Add(aIP);
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
aMIP.Clear();
|
aMIP.Clear();
|
||||||
aIt1.Initialize(aMIP1);
|
aIt1.Initialize(aMIP1);
|
||||||
for(; aIt1.More(); aIt1.Next()) {
|
for(; aIt1.More(); aIt1.Next()) {
|
||||||
aIP=aIt1.Key();
|
aIP=aIt1.Key();
|
||||||
aMIP.Add(aIP);
|
aMIP.Add(aIP);
|
||||||
}
|
}
|
||||||
aMIP1.Clear();
|
aMIP1.Clear();
|
||||||
}// while(1)
|
}// while(1)
|
||||||
@ -344,13 +338,13 @@ void GEOMAlgo_Gluer::MakeVertices()
|
|||||||
else { // SD vertices founded [ aMIPC ]
|
else { // SD vertices founded [ aMIPC ]
|
||||||
aIt1.Initialize(aMIPC);
|
aIt1.Initialize(aMIPC);
|
||||||
for(j=0; aIt1.More(); aIt1.Next(), ++j) {
|
for(j=0; aIt1.More(); aIt1.Next(), ++j) {
|
||||||
aIP=aIt1.Key();
|
aIP=aIt1.Key();
|
||||||
const TopoDS_Shape& aVP=aMIS.FindFromKey(aIP);
|
const TopoDS_Shape& aVP=aMIS.FindFromKey(aIP);
|
||||||
if (!j) {
|
if (!j) {
|
||||||
aVF=aVP;
|
aVF=aVP;
|
||||||
}
|
}
|
||||||
aLVSD.Append(aVP);
|
aLVSD.Append(aVP);
|
||||||
aMVProcessed.Add(aVP);
|
aMVProcessed.Add(aVP);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
myImages.Bind(aVF, aLVSD);
|
myImages.Bind(aVF, aLVSD);
|
||||||
@ -395,7 +389,7 @@ void GEOMAlgo_Gluer::MakeVertices()
|
|||||||
for (; aItS.More(); aItS.Next()) {
|
for (; aItS.More(); aItS.Next()) {
|
||||||
const TopoDS_Shape& aVSD=aItS.Value();
|
const TopoDS_Shape& aVSD=aItS.Value();
|
||||||
if (!myOrigins.IsBound(aVSD)) {
|
if (!myOrigins.IsBound(aVSD)) {
|
||||||
myOrigins.Bind(aVSD, aV);
|
myOrigins.Bind(aVSD, aV);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -468,7 +462,8 @@ void GEOMAlgo_Gluer::MakeSubShapes (const TopoDS_Shape& theShape,
|
|||||||
aER.Orientation(TopAbs_FORWARD);
|
aER.Orientation(TopAbs_FORWARD);
|
||||||
if (!BRep_Tool::Degenerated(aER)) {
|
if (!BRep_Tool::Degenerated(aER)) {
|
||||||
// orient image
|
// orient image
|
||||||
Standard_Boolean bIsToReverse=GEOMAlgo_AlgoTools::IsSplitToReverse(aER, aE, myContext);
|
Standard_Boolean bIsToReverse=
|
||||||
|
GEOMAlgo_AlgoTools::IsSplitToReverse(aER, aE, myContext);
|
||||||
if (bIsToReverse) {
|
if (bIsToReverse) {
|
||||||
aER.Reverse();
|
aER.Reverse();
|
||||||
}
|
}
|
||||||
@ -490,8 +485,7 @@ void GEOMAlgo_Gluer::MakeSubShapes (const TopoDS_Shape& theShape,
|
|||||||
aBB.Add(theResult, aShapeR);
|
aBB.Add(theResult, aShapeR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else {
|
||||||
{
|
|
||||||
if (myKeepNonSolids) {
|
if (myKeepNonSolids) {
|
||||||
// just add image
|
// just add image
|
||||||
const TopoDS_Shape& aShapeR = myOrigins.Find(theShape);
|
const TopoDS_Shape& aShapeR = myOrigins.Find(theShape);
|
||||||
@ -554,12 +548,12 @@ void GEOMAlgo_Gluer::MakeShells()
|
|||||||
const TopoDS_Face& aF=TopoDS::Face(aExp.Current());
|
const TopoDS_Face& aF=TopoDS::Face(aExp.Current());
|
||||||
aFR=TopoDS::Face(myOrigins.Find(aF));
|
aFR=TopoDS::Face(myOrigins.Find(aF));
|
||||||
if (aFR.IsSame(aF)) {
|
if (aFR.IsSame(aF)) {
|
||||||
aBB.Add(aNewShell, aF);
|
aBB.Add(aNewShell, aF);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
bIsToReverse=IsToReverse(aFR, aF);
|
bIsToReverse=IsToReverse(aFR, aF);
|
||||||
if (bIsToReverse) {
|
if (bIsToReverse) {
|
||||||
aFR.Reverse();
|
aFR.Reverse();
|
||||||
}
|
}
|
||||||
aBB.Add(aNewShell, aFR);
|
aBB.Add(aNewShell, aFR);
|
||||||
}
|
}
|
||||||
@ -660,25 +654,25 @@ void GEOMAlgo_Gluer::MakeShapes(const TopAbs_ShapeEnum aType)
|
|||||||
if (aNbSDF==1) {
|
if (aNbSDF==1) {
|
||||||
bHasNewSubShape=HasNewSubShape(aS1);
|
bHasNewSubShape=HasNewSubShape(aS1);
|
||||||
if (!bHasNewSubShape) {
|
if (!bHasNewSubShape) {
|
||||||
aNewShape=aS1;
|
aNewShape=aS1;
|
||||||
aNewShape.Orientation(TopAbs_FORWARD);
|
aNewShape.Orientation(TopAbs_FORWARD);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
if (bHasNewSubShape) {
|
if (bHasNewSubShape) {
|
||||||
if (aType==TopAbs_FACE) {
|
if (aType==TopAbs_FACE) {
|
||||||
TopoDS_Face aNewFace;
|
TopoDS_Face aNewFace;
|
||||||
//
|
//
|
||||||
const TopoDS_Face& aF1=TopoDS::Face(aS1);
|
const TopoDS_Face& aF1=TopoDS::Face(aS1);
|
||||||
MakeFace(aF1, aNewFace);
|
MakeFace(aF1, aNewFace);
|
||||||
aNewShape=aNewFace;
|
aNewShape=aNewFace;
|
||||||
}
|
}
|
||||||
else if (aType==TopAbs_EDGE) {
|
else if (aType==TopAbs_EDGE) {
|
||||||
TopoDS_Edge aNewEdge;
|
TopoDS_Edge aNewEdge;
|
||||||
//
|
//
|
||||||
const TopoDS_Edge& aE1=TopoDS::Edge(aS1);
|
const TopoDS_Edge& aE1=TopoDS::Edge(aS1);
|
||||||
MakeEdge(aE1, aNewEdge);
|
MakeEdge(aE1, aNewEdge);
|
||||||
aNewShape=aNewEdge;
|
aNewShape=aNewEdge;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
@ -688,7 +682,7 @@ void GEOMAlgo_Gluer::MakeShapes(const TopAbs_ShapeEnum aType)
|
|||||||
for (; aItS.More(); aItS.Next()) {
|
for (; aItS.More(); aItS.Next()) {
|
||||||
const TopoDS_Shape& aFSD=aItS.Value();
|
const TopoDS_Shape& aFSD=aItS.Value();
|
||||||
if (!myOrigins.IsBound(aFSD)) {
|
if (!myOrigins.IsBound(aFSD)) {
|
||||||
myOrigins.Bind(aFSD, aNewShape);
|
myOrigins.Bind(aFSD, aNewShape);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -728,12 +722,12 @@ void GEOMAlgo_Gluer::CheckResult()
|
|||||||
for (j=1; j<=aNbFS; ++j) {
|
for (j=1; j<=aNbFS; ++j) {
|
||||||
const TopoDS_Shape& aFS=aMFS(j);
|
const TopoDS_Shape& aFS=aMFS(j);
|
||||||
if (aMFR.Contains(aFS)) {
|
if (aMFR.Contains(aFS)) {
|
||||||
const TopTools_ListOfShape& aLSx=aMFR.FindFromKey(aFS);
|
const TopTools_ListOfShape& aLSx=aMFR.FindFromKey(aFS);
|
||||||
aNbSx=aLSx.Extent();
|
aNbSx=aLSx.Extent();
|
||||||
if (aNbSx==2) {
|
if (aNbSx==2) {
|
||||||
bFound=!bFound;
|
bFound=!bFound;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
@ -795,7 +789,7 @@ void GEOMAlgo_Gluer::InnerTolerance()
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer::FacePassKey(const TopoDS_Face& aF,
|
void GEOMAlgo_Gluer::FacePassKey(const TopoDS_Face& aF,
|
||||||
GEOMAlgo_PassKeyShape& aPK)
|
GEOMAlgo_PassKeyShape& aPK)
|
||||||
{
|
{
|
||||||
Standard_Integer i, aNbE;
|
Standard_Integer i, aNbE;
|
||||||
TopTools_ListOfShape aLE;
|
TopTools_ListOfShape aLE;
|
||||||
@ -820,7 +814,7 @@ void GEOMAlgo_Gluer::FacePassKey(const TopoDS_Face& aF,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer::EdgePassKey(const TopoDS_Edge& aE,
|
void GEOMAlgo_Gluer::EdgePassKey(const TopoDS_Edge& aE,
|
||||||
GEOMAlgo_PassKeyShape& aPK)
|
GEOMAlgo_PassKeyShape& aPK)
|
||||||
{
|
{
|
||||||
TopoDS_Vertex aV1, aV2;
|
TopoDS_Vertex aV1, aV2;
|
||||||
//
|
//
|
||||||
@ -839,7 +833,7 @@ void GEOMAlgo_Gluer::EdgePassKey(const TopoDS_Edge& aE,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer::MakeVertex(const TopTools_ListOfShape& aLV,
|
void GEOMAlgo_Gluer::MakeVertex(const TopTools_ListOfShape& aLV,
|
||||||
TopoDS_Vertex& aNewVertex)
|
TopoDS_Vertex& aNewVertex)
|
||||||
{
|
{
|
||||||
Standard_Integer aNbV;
|
Standard_Integer aNbV;
|
||||||
Standard_Real aTolV, aD, aDmax;
|
Standard_Real aTolV, aD, aDmax;
|
||||||
@ -885,7 +879,7 @@ void GEOMAlgo_Gluer::MakeVertex(const TopTools_ListOfShape& aLV,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer::MakeEdge(const TopoDS_Edge& aE,
|
void GEOMAlgo_Gluer::MakeEdge(const TopoDS_Edge& aE,
|
||||||
TopoDS_Edge& aNewEdge)
|
TopoDS_Edge& aNewEdge)
|
||||||
{
|
{
|
||||||
myErrorStatus=0;
|
myErrorStatus=0;
|
||||||
//
|
//
|
||||||
@ -939,7 +933,7 @@ void GEOMAlgo_Gluer::MakeEdge(const TopoDS_Edge& aE,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer::MakeFace(const TopoDS_Face& aF,
|
void GEOMAlgo_Gluer::MakeFace(const TopoDS_Face& aF,
|
||||||
TopoDS_Face& aNewFace)
|
TopoDS_Face& aNewFace)
|
||||||
{
|
{
|
||||||
myErrorStatus=0;
|
myErrorStatus=0;
|
||||||
//
|
//
|
||||||
@ -975,20 +969,20 @@ void GEOMAlgo_Gluer::MakeFace(const TopoDS_Face& aF,
|
|||||||
//
|
//
|
||||||
aER.Orientation(TopAbs_FORWARD);
|
aER.Orientation(TopAbs_FORWARD);
|
||||||
if (!BRep_Tool::Degenerated(aER)) {
|
if (!BRep_Tool::Degenerated(aER)) {
|
||||||
// build p-curve
|
// build p-curve
|
||||||
if (bIsUPeriodic) {
|
if (bIsUPeriodic) {
|
||||||
GEOMAlgo_AlgoTools::RefinePCurveForEdgeOnFace(aER, aFFWD, aUMin, aUMax);
|
GEOMAlgo_AlgoTools::RefinePCurveForEdgeOnFace(aER, aFFWD, aUMin, aUMax);
|
||||||
}
|
}
|
||||||
BOPTools_AlgoTools2D::BuildPCurveForEdgeOnFace(aER, aFFWD);
|
BOPTools_AlgoTools2D::BuildPCurveForEdgeOnFace(aER, aFFWD);
|
||||||
|
|
||||||
// orient image
|
// orient image
|
||||||
bIsToReverse=GEOMAlgo_AlgoTools::IsSplitToReverse(aER, aE, myContext);
|
bIsToReverse=GEOMAlgo_AlgoTools::IsSplitToReverse(aER, aE, myContext);
|
||||||
if (bIsToReverse) {
|
if (bIsToReverse) {
|
||||||
aER.Reverse();
|
aER.Reverse();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
aER.Orientation(aE.Orientation());
|
aER.Orientation(aE.Orientation());
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
aBB.Add(newWire, aER);
|
aBB.Add(newWire, aER);
|
||||||
@ -1009,7 +1003,7 @@ void GEOMAlgo_Gluer::MakeFace(const TopoDS_Face& aF,
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
Standard_Boolean GEOMAlgo_Gluer::IsToReverse(const TopoDS_Face& aFR,
|
Standard_Boolean GEOMAlgo_Gluer::IsToReverse(const TopoDS_Face& aFR,
|
||||||
const TopoDS_Face& aF)
|
const TopoDS_Face& aF)
|
||||||
{
|
{
|
||||||
Standard_Boolean bRet;
|
Standard_Boolean bRet;
|
||||||
Standard_Real aT, aT1, aT2, aTR, aScPr;
|
Standard_Real aT, aT1, aT2, aTR, aScPr;
|
||||||
@ -1088,7 +1082,7 @@ Standard_Boolean GEOMAlgo_Gluer::HasNewSubShape(const TopoDS_Shape& aS)const
|
|||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GetSubShapes(const TopoDS_Shape& aS,
|
void GetSubShapes(const TopoDS_Shape& aS,
|
||||||
TopTools_IndexedMapOfShape& aMSS)
|
TopTools_IndexedMapOfShape& aMSS)
|
||||||
{
|
{
|
||||||
Standard_Integer aR;
|
Standard_Integer aR;
|
||||||
TopAbs_ShapeEnum aType;
|
TopAbs_ShapeEnum aType;
|
||||||
@ -1111,7 +1105,8 @@ void GetSubShapes(const TopoDS_Shape& aS,
|
|||||||
//function : Modified
|
//function : Modified
|
||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
const TopTools_ListOfShape& GEOMAlgo_Gluer::Modified (const TopoDS_Shape& aS)
|
const TopTools_ListOfShape& GEOMAlgo_Gluer::Modified
|
||||||
|
(const TopoDS_Shape& aS)
|
||||||
{
|
{
|
||||||
TopAbs_ShapeEnum aType;
|
TopAbs_ShapeEnum aType;
|
||||||
//
|
//
|
||||||
@ -1127,7 +1122,7 @@ const TopTools_ListOfShape& GEOMAlgo_Gluer::Modified (const TopoDS_Shape& aS)
|
|||||||
if(myOrigins.IsBound(aS)) {
|
if(myOrigins.IsBound(aS)) {
|
||||||
const TopoDS_Shape& aSnew=myOrigins.Find(aS);
|
const TopoDS_Shape& aSnew=myOrigins.Find(aS);
|
||||||
if (!aSnew.IsSame(aS)) {
|
if (!aSnew.IsSame(aS)) {
|
||||||
myGenerated.Append(aSnew);
|
myGenerated.Append(aSnew);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -84,11 +84,8 @@ void GEOMAlgo_Gluer2::Clear()
|
|||||||
myImagesToWork.Clear();
|
myImagesToWork.Clear();
|
||||||
myOriginsToWork.Clear();
|
myOriginsToWork.Clear();
|
||||||
myKeepNonSolids=Standard_False;
|
myKeepNonSolids=Standard_False;
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 13:38:28 2012f
|
|
||||||
myDetector.Clear();
|
myDetector.Clear();
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 13:38:30 2012t
|
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 12:26:50 2012f
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : StickedShapes
|
//function : StickedShapes
|
||||||
//purpose :
|
//purpose :
|
||||||
@ -98,12 +95,12 @@ const TopTools_IndexedDataMapOfShapeListOfShape&
|
|||||||
{
|
{
|
||||||
return myDetector.StickedShapes();
|
return myDetector.StickedShapes();
|
||||||
}
|
}
|
||||||
//modified by NIZNHY-PKV Tue Mar 13 12:26:54 2012t
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : SetShapesToGlue
|
//function : SetShapesToGlue
|
||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
void GEOMAlgo_Gluer2::SetShapesToGlue(const TopTools_DataMapOfShapeListOfShape& aM)
|
void GEOMAlgo_Gluer2::SetShapesToGlue
|
||||||
|
(const TopTools_DataMapOfShapeListOfShape& aM)
|
||||||
{
|
{
|
||||||
myShapesToGlue=aM;
|
myShapesToGlue=aM;
|
||||||
}
|
}
|
||||||
@ -241,6 +238,7 @@ void GEOMAlgo_Gluer2::CheckData()
|
|||||||
myWarningStatus=0;
|
myWarningStatus=0;
|
||||||
//
|
//
|
||||||
aNbSG=myShapesToGlue.Extent();
|
aNbSG=myShapesToGlue.Extent();
|
||||||
|
aType=TopAbs_SHAPE;
|
||||||
if (aNbSG) {
|
if (aNbSG) {
|
||||||
// Check myShapesToGlue
|
// Check myShapesToGlue
|
||||||
aItDMSLS.Initialize(myShapesToGlue);
|
aItDMSLS.Initialize(myShapesToGlue);
|
||||||
@ -587,6 +585,7 @@ void GEOMAlgo_Gluer2::BuildResult()
|
|||||||
myErrorStatus=0;
|
myErrorStatus=0;
|
||||||
myWarningStatus=0;
|
myWarningStatus=0;
|
||||||
//
|
//
|
||||||
|
bHasImage=Standard_False;
|
||||||
aItC.Initialize(myArgument);
|
aItC.Initialize(myArgument);
|
||||||
for (; aItC.More(); aItC.Next()) {
|
for (; aItC.More(); aItC.Next()) {
|
||||||
const TopoDS_Shape& aCx=aItC.Value();
|
const TopoDS_Shape& aCx=aItC.Value();
|
||||||
|
37
src/GEOMAlgo/GEOMAlgo_KindOfDef.hxx
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE
|
||||||
|
//
|
||||||
|
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
|
||||||
|
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
|
||||||
|
//
|
||||||
|
// This library is free software; you can redistribute it and/or
|
||||||
|
// modify it under the terms of the GNU Lesser General Public
|
||||||
|
// License as published by the Free Software Foundation; either
|
||||||
|
// version 2.1 of the License, or (at your option) any later version.
|
||||||
|
//
|
||||||
|
// This library is distributed in the hope that it will be useful,
|
||||||
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
// Lesser General Public License for more details.
|
||||||
|
//
|
||||||
|
// You should have received a copy of the GNU Lesser General Public
|
||||||
|
// License along with this library; if not, write to the Free Software
|
||||||
|
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
//
|
||||||
|
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
|
||||||
|
//
|
||||||
|
//GEOMAlgo_KindOfDef
|
||||||
|
#ifndef _GEOMAlgo_KindOfDef_HeaderFile
|
||||||
|
#define _GEOMAlgo_KindOfDef_HeaderFile
|
||||||
|
|
||||||
|
|
||||||
|
enum GEOMAlgo_KindOfDef {
|
||||||
|
GEOMAlgo_KD_UNKNOWN,
|
||||||
|
GEOMAlgo_KD_SPECIFIED,
|
||||||
|
GEOMAlgo_KD_ARBITRARY
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifndef _Standard_PrimitiveTypes_HeaderFile
|
||||||
|
#include <Standard_PrimitiveTypes.hxx>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
@ -44,7 +44,8 @@ GEOMAlgo_KN_DISKELLIPSE,
|
|||||||
GEOMAlgo_KN_RECTANGLE,
|
GEOMAlgo_KN_RECTANGLE,
|
||||||
GEOMAlgo_KN_TRIANGLE,
|
GEOMAlgo_KN_TRIANGLE,
|
||||||
GEOMAlgo_KN_QUADRANGLE,
|
GEOMAlgo_KN_QUADRANGLE,
|
||||||
GEOMAlgo_KN_ARCELLIPSE
|
GEOMAlgo_KN_ARCELLIPSE,
|
||||||
|
GEOMAlgo_KN_SOLID
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifndef _Standard_PrimitiveTypes_HeaderFile
|
#ifndef _Standard_PrimitiveTypes_HeaderFile
|
||||||
|
@ -35,9 +35,7 @@ GEOMAlgo_KS_PLANE,
|
|||||||
GEOMAlgo_KS_CIRCLE,
|
GEOMAlgo_KS_CIRCLE,
|
||||||
GEOMAlgo_KS_LINE,
|
GEOMAlgo_KS_LINE,
|
||||||
GEOMAlgo_KS_DEGENERATED,
|
GEOMAlgo_KS_DEGENERATED,
|
||||||
//modified by NIZNHY-PKV Tue Jul 03 10:28:09 2012f
|
|
||||||
GEOMAlgo_KS_BSPLINE
|
GEOMAlgo_KS_BSPLINE
|
||||||
//modified by NIZNHY-PKV Tue Jul 03 10:28:11 2012t
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifndef _Standard_PrimitiveTypes_HeaderFile
|
#ifndef _Standard_PrimitiveTypes_HeaderFile
|
||||||
|