00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef _SMESH_MESHEDITOR_I_HXX_
00029 #define _SMESH_MESHEDIOTR_I_HXX_
00030
00031 #include "SMESH.hxx"
00032
00033 #include <SALOMEconfig.h>
00034 #include CORBA_SERVER_HEADER(SMESH_MeshEditor)
00035
00036 #include "SMESH_Mesh.hxx"
00037 #include "SMESH_PythonDump.hxx"
00038 #include "SMESH_MeshEditor.hxx"
00039 #include <list>
00040
00041 class SMESH_MeshEditor;
00042 class SMESH_Mesh_i;
00043
00044 class SMESH_MeshEditor_i: public POA_SMESH::SMESH_MeshEditor
00045 {
00046 public:
00047 SMESH_MeshEditor_i(SMESH_Mesh_i * theMesh, bool isPreview);
00048
00049 virtual ~ SMESH_MeshEditor_i();
00050
00051
00052
00056 SMESH::SMESH_IDSource_ptr MakeIDSource(const SMESH::long_array& IDsOfElements,
00057 SMESH::ElementType type);
00058 CORBA::Boolean RemoveElements(const SMESH::long_array & IDsOfElements);
00059 CORBA::Boolean RemoveNodes(const SMESH::long_array & IDsOfNodes);
00060 CORBA::Long RemoveOrphanNodes();
00061
00066 CORBA::Long AddNode(CORBA::Double x, CORBA::Double y, CORBA::Double z);
00067 CORBA::Long Add0DElement(CORBA::Long IDOfNode);
00068 CORBA::Long AddEdge(const SMESH::long_array & IDsOfNodes);
00069 CORBA::Long AddFace(const SMESH::long_array & IDsOfNodes);
00070 CORBA::Long AddPolygonalFace(const SMESH::long_array & IDsOfNodes);
00071 CORBA::Long AddVolume(const SMESH::long_array & IDsOfNodes);
00072 CORBA::Long AddPolyhedralVolume(const SMESH::long_array & IDsOfNodes,
00073 const SMESH::long_array & Quantities);
00074 CORBA::Long AddPolyhedralVolumeByFaces(const SMESH::long_array & IdsOfFaces);
00075
00081 void SetNodeOnVertex(CORBA::Long NodeID, CORBA::Long VertexID)
00082 throw (SALOME::SALOME_Exception);
00089 void SetNodeOnEdge(CORBA::Long NodeID, CORBA::Long EdgeID,
00090 CORBA::Double paramOnEdge)
00091 throw (SALOME::SALOME_Exception);
00099 void SetNodeOnFace(CORBA::Long NodeID, CORBA::Long FaceID,
00100 CORBA::Double u, CORBA::Double v)
00101 throw (SALOME::SALOME_Exception);
00107 void SetNodeInVolume(CORBA::Long NodeID, CORBA::Long SolidID)
00108 throw (SALOME::SALOME_Exception);
00114 void SetMeshElementOnShape(CORBA::Long ElementID, CORBA::Long ShapeID)
00115 throw (SALOME::SALOME_Exception);
00116
00117
00118 CORBA::Boolean MoveNode(CORBA::Long NodeID,
00119 CORBA::Double x, CORBA::Double y, CORBA::Double z);
00120
00121 CORBA::Boolean InverseDiag(CORBA::Long NodeID1, CORBA::Long NodeID2);
00122 CORBA::Boolean DeleteDiag(CORBA::Long NodeID1, CORBA::Long NodeID2);
00123 CORBA::Boolean Reorient(const SMESH::long_array & IDsOfElements);
00124 CORBA::Boolean ReorientObject(SMESH::SMESH_IDSource_ptr theObject);
00125
00126
00127 CORBA::Boolean TriToQuad (const SMESH::long_array & IDsOfElements,
00128 SMESH::NumericalFunctor_ptr Criterion,
00129 CORBA::Double MaxAngle);
00130 CORBA::Boolean TriToQuadObject (SMESH::SMESH_IDSource_ptr theObject,
00131 SMESH::NumericalFunctor_ptr Criterion,
00132 CORBA::Double MaxAngle);
00133 CORBA::Boolean QuadToTri (const SMESH::long_array & IDsOfElements,
00134 SMESH::NumericalFunctor_ptr Criterion);
00135 CORBA::Boolean QuadToTriObject (SMESH::SMESH_IDSource_ptr theObject,
00136 SMESH::NumericalFunctor_ptr Criterion);
00137 CORBA::Boolean SplitQuad (const SMESH::long_array & IDsOfElements,
00138 CORBA::Boolean Diag13);
00139 CORBA::Boolean SplitQuadObject (SMESH::SMESH_IDSource_ptr theObject,
00140 CORBA::Boolean Diag13);
00141 CORBA::Long BestSplit (CORBA::Long IDOfQuad,
00142 SMESH::NumericalFunctor_ptr Criterion);
00143 void SplitVolumesIntoTetra (SMESH::SMESH_IDSource_ptr elems,
00144 CORBA::Short methodFlags) throw (SALOME::SALOME_Exception);
00145
00146 CORBA::Boolean Smooth(const SMESH::long_array & IDsOfElements,
00147 const SMESH::long_array & IDsOfFixedNodes,
00148 CORBA::Long MaxNbOfIterations,
00149 CORBA::Double MaxAspectRatio,
00150 SMESH::SMESH_MeshEditor::Smooth_Method Method);
00151 CORBA::Boolean SmoothObject(SMESH::SMESH_IDSource_ptr theObject,
00152 const SMESH::long_array & IDsOfFixedNodes,
00153 CORBA::Long MaxNbOfIterations,
00154 CORBA::Double MaxAspectRatio,
00155 SMESH::SMESH_MeshEditor::Smooth_Method Method);
00156 CORBA::Boolean SmoothParametric(const SMESH::long_array & IDsOfElements,
00157 const SMESH::long_array & IDsOfFixedNodes,
00158 CORBA::Long MaxNbOfIterations,
00159 CORBA::Double MaxAspectRatio,
00160 SMESH::SMESH_MeshEditor::Smooth_Method Method);
00161 CORBA::Boolean SmoothParametricObject(SMESH::SMESH_IDSource_ptr theObject,
00162 const SMESH::long_array & IDsOfFixedNodes,
00163 CORBA::Long MaxNbOfIterations,
00164 CORBA::Double MaxAspectRatio,
00165 SMESH::SMESH_MeshEditor::Smooth_Method Method);
00166 CORBA::Boolean smooth(const SMESH::long_array & IDsOfElements,
00167 const SMESH::long_array & IDsOfFixedNodes,
00168 CORBA::Long MaxNbOfIterations,
00169 CORBA::Double MaxAspectRatio,
00170 SMESH::SMESH_MeshEditor::Smooth_Method Method,
00171 bool IsParametric);
00172 CORBA::Boolean smoothObject(SMESH::SMESH_IDSource_ptr theObject,
00173 const SMESH::long_array & IDsOfFixedNodes,
00174 CORBA::Long MaxNbOfIterations,
00175 CORBA::Double MaxAspectRatio,
00176 SMESH::SMESH_MeshEditor::Smooth_Method Method,
00177 bool IsParametric);
00178
00179
00180 void ConvertToQuadratic(CORBA::Boolean Force3d);
00181 CORBA::Boolean ConvertFromQuadratic();
00182 void ConvertToQuadraticObject(CORBA::Boolean theForce3d,
00183 SMESH::SMESH_IDSource_ptr theObject)
00184 throw (SALOME::SALOME_Exception);
00185 void ConvertFromQuadraticObject(SMESH::SMESH_IDSource_ptr theObject)
00186 throw (SALOME::SALOME_Exception);
00187
00188 void RenumberNodes();
00189 void RenumberElements();
00190
00191 void RotationSweep(const SMESH::long_array & IDsOfElements,
00192 const SMESH::AxisStruct & Axis,
00193 CORBA::Double AngleInRadians,
00194 CORBA::Long NbOfSteps,
00195 CORBA::Double Tolerance);
00196 void RotationSweepObject(SMESH::SMESH_IDSource_ptr theObject,
00197 const SMESH::AxisStruct & Axis,
00198 CORBA::Double AngleInRadians,
00199 CORBA::Long NbOfSteps,
00200 CORBA::Double Tolerance);
00201 void RotationSweepObject1D(SMESH::SMESH_IDSource_ptr theObject,
00202 const SMESH::AxisStruct & Axis,
00203 CORBA::Double AngleInRadians,
00204 CORBA::Long NbOfSteps,
00205 CORBA::Double Tolerance);
00206 void RotationSweepObject2D(SMESH::SMESH_IDSource_ptr theObject,
00207 const SMESH::AxisStruct & Axis,
00208 CORBA::Double AngleInRadians,
00209 CORBA::Long NbOfSteps,
00210 CORBA::Double Tolerance);
00211
00212 void ExtrusionSweep(const SMESH::long_array & IDsOfElements,
00213 const SMESH::DirStruct & StepVector,
00214 CORBA::Long NbOfSteps);
00215 void ExtrusionSweepObject(SMESH::SMESH_IDSource_ptr theObject,
00216 const SMESH::DirStruct & StepVector,
00217 CORBA::Long NbOfSteps);
00218 void ExtrusionSweepObject1D(SMESH::SMESH_IDSource_ptr theObject,
00219 const SMESH::DirStruct & StepVector,
00220 CORBA::Long NbOfSteps);
00221 void ExtrusionSweepObject2D(SMESH::SMESH_IDSource_ptr theObject,
00222 const SMESH::DirStruct & StepVector,
00223 CORBA::Long NbOfSteps);
00224 void AdvancedExtrusion(const SMESH::long_array & theIDsOfElements,
00225 const SMESH::DirStruct & theStepVector,
00226 CORBA::Long theNbOfSteps,
00227 CORBA::Long theExtrFlags,
00228 CORBA::Double theSewTolerance);
00229
00230 SMESH::SMESH_MeshEditor::Extrusion_Error
00231 ExtrusionAlongPath(const SMESH::long_array & IDsOfElements,
00232 SMESH::SMESH_Mesh_ptr PathMesh,
00233 GEOM::GEOM_Object_ptr PathShape,
00234 CORBA::Long NodeStart,
00235 CORBA::Boolean HasAngles,
00236 const SMESH::double_array & Angles,
00237 CORBA::Boolean HasRefPoint,
00238 const SMESH::PointStruct & RefPoint);
00239
00240 SMESH::SMESH_MeshEditor::Extrusion_Error
00241 ExtrusionAlongPathObject(SMESH::SMESH_IDSource_ptr theObject,
00242 SMESH::SMESH_Mesh_ptr PathMesh,
00243 GEOM::GEOM_Object_ptr PathShape,
00244 CORBA::Long NodeStart,
00245 CORBA::Boolean HasAngles,
00246 const SMESH::double_array & Angles,
00247 CORBA::Boolean HasRefPoint,
00248 const SMESH::PointStruct & RefPoint);
00249 SMESH::SMESH_MeshEditor::Extrusion_Error
00250 ExtrusionAlongPathObject1D(SMESH::SMESH_IDSource_ptr theObject,
00251 SMESH::SMESH_Mesh_ptr PathMesh,
00252 GEOM::GEOM_Object_ptr PathShape,
00253 CORBA::Long NodeStart,
00254 CORBA::Boolean HasAngles,
00255 const SMESH::double_array & Angles,
00256 CORBA::Boolean HasRefPoint,
00257 const SMESH::PointStruct & RefPoint);
00258 SMESH::SMESH_MeshEditor::Extrusion_Error
00259 ExtrusionAlongPathObject2D(SMESH::SMESH_IDSource_ptr theObject,
00260 SMESH::SMESH_Mesh_ptr PathMesh,
00261 GEOM::GEOM_Object_ptr PathShape,
00262 CORBA::Long NodeStart,
00263 CORBA::Boolean HasAngles,
00264 const SMESH::double_array & Angles,
00265 CORBA::Boolean HasRefPoint,
00266 const SMESH::PointStruct & RefPoint);
00267
00268 SMESH::double_array* LinearAnglesVariation(SMESH::SMESH_Mesh_ptr PathMesh,
00269 GEOM::GEOM_Object_ptr PathShape,
00270 const SMESH::double_array & Angles);
00271
00272 void Mirror(const SMESH::long_array & IDsOfElements,
00273 const SMESH::AxisStruct & Axis,
00274 SMESH::SMESH_MeshEditor::MirrorType MirrorType,
00275 CORBA::Boolean Copy);
00276 void MirrorObject(SMESH::SMESH_IDSource_ptr theObject,
00277 const SMESH::AxisStruct & Axis,
00278 SMESH::SMESH_MeshEditor::MirrorType MirrorType,
00279 CORBA::Boolean Copy);
00280 void Translate(const SMESH::long_array & IDsOfElements,
00281 const SMESH::DirStruct & Vector,
00282 CORBA::Boolean Copy);
00283 void TranslateObject(SMESH::SMESH_IDSource_ptr theObject,
00284 const SMESH::DirStruct & Vector,
00285 CORBA::Boolean Copy);
00286 void Rotate(const SMESH::long_array & IDsOfElements,
00287 const SMESH::AxisStruct & Axis,
00288 CORBA::Double Angle,
00289 CORBA::Boolean Copy);
00290 void RotateObject(SMESH::SMESH_IDSource_ptr theObject,
00291 const SMESH::AxisStruct & Axis,
00292 CORBA::Double Angle,
00293 CORBA::Boolean Copy);
00294
00295 SMESH::ListOfGroups* RotationSweepMakeGroups(const SMESH::long_array& IDsOfElements,
00296 const SMESH::AxisStruct& Axix,
00297 CORBA::Double AngleInRadians,
00298 CORBA::Long NbOfSteps,
00299 CORBA::Double Tolerance);
00300 SMESH::ListOfGroups* RotationSweepObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00301 const SMESH::AxisStruct& Axix,
00302 CORBA::Double AngleInRadians,
00303 CORBA::Long NbOfSteps,
00304 CORBA::Double Tolerance);
00305 SMESH::ListOfGroups* RotationSweepObject1DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00306 const SMESH::AxisStruct& Axix,
00307 CORBA::Double AngleInRadians,
00308 CORBA::Long NbOfSteps,
00309 CORBA::Double Tolerance);
00310 SMESH::ListOfGroups* RotationSweepObject2DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00311 const SMESH::AxisStruct& Axix,
00312 CORBA::Double AngleInRadians,
00313 CORBA::Long NbOfSteps,
00314 CORBA::Double Tolerance);
00315 SMESH::ListOfGroups* ExtrusionSweepMakeGroups(const SMESH::long_array& IDsOfElements,
00316 const SMESH::DirStruct& StepVector,
00317 CORBA::Long NbOfSteps);
00318 SMESH::ListOfGroups* AdvancedExtrusionMakeGroups(const SMESH::long_array& IDsOfElements,
00319 const SMESH::DirStruct& StepVector,
00320 CORBA::Long NbOfSteps,
00321 CORBA::Long ExtrFlags,
00322 CORBA::Double SewTolerance);
00323 SMESH::ListOfGroups* ExtrusionSweepObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00324 const SMESH::DirStruct& StepVector,
00325 CORBA::Long NbOfSteps);
00326 SMESH::ListOfGroups* ExtrusionSweepObject1DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00327 const SMESH::DirStruct& StepVector,
00328 CORBA::Long NbOfSteps);
00329 SMESH::ListOfGroups* ExtrusionSweepObject2DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00330 const SMESH::DirStruct& StepVector,
00331 CORBA::Long NbOfSteps);
00332 SMESH::ListOfGroups* ExtrusionAlongPathMakeGroups(const SMESH::long_array& IDsOfElements,
00333 SMESH::SMESH_Mesh_ptr PathMesh,
00334 GEOM::GEOM_Object_ptr PathShape,
00335 CORBA::Long NodeStart,
00336 CORBA::Boolean HasAngles,
00337 const SMESH::double_array& Angles,
00338 CORBA::Boolean HasRefPoint,
00339 const SMESH::PointStruct& RefPoint,
00340 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00341 SMESH::ListOfGroups* ExtrusionAlongPathObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00342 SMESH::SMESH_Mesh_ptr PathMesh,
00343 GEOM::GEOM_Object_ptr PathShape,
00344 CORBA::Long NodeStart,
00345 CORBA::Boolean HasAngles,
00346 const SMESH::double_array& Angles,
00347 CORBA::Boolean HasRefPoint,
00348 const SMESH::PointStruct& RefPoint,
00349 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00350 SMESH::ListOfGroups* ExtrusionAlongPathObject1DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00351 SMESH::SMESH_Mesh_ptr PathMesh,
00352 GEOM::GEOM_Object_ptr PathShape,
00353 CORBA::Long NodeStart,
00354 CORBA::Boolean HasAngles,
00355 const SMESH::double_array& Angles,
00356 CORBA::Boolean HasRefPoint,
00357 const SMESH::PointStruct& RefPoint,
00358 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00359 SMESH::ListOfGroups* ExtrusionAlongPathObject2DMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00360 SMESH::SMESH_Mesh_ptr PathMesh,
00361 GEOM::GEOM_Object_ptr PathShape,
00362 CORBA::Long NodeStart,
00363 CORBA::Boolean HasAngles,
00364 const SMESH::double_array& Angles,
00365 CORBA::Boolean HasRefPoint,
00366 const SMESH::PointStruct& RefPoint,
00367 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00368
00369
00370 SMESH::ListOfGroups* ExtrusionAlongPathObjX(SMESH::SMESH_IDSource_ptr Object,
00371 SMESH::SMESH_IDSource_ptr Path,
00372 CORBA::Long NodeStart,
00373 CORBA::Boolean HasAngles,
00374 const SMESH::double_array& Angles,
00375 CORBA::Boolean LinearVariation,
00376 CORBA::Boolean HasRefPoint,
00377 const SMESH::PointStruct& RefPoint,
00378 CORBA::Boolean MakeGroups,
00379 SMESH::ElementType ElemType,
00380 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00381 SMESH::ListOfGroups* ExtrusionAlongPathX(const SMESH::long_array& IDsOfElements,
00382 SMESH::SMESH_IDSource_ptr Path,
00383 CORBA::Long NodeStart,
00384 CORBA::Boolean HasAngles,
00385 const SMESH::double_array& Angles,
00386 CORBA::Boolean LinearVariation,
00387 CORBA::Boolean HasRefPoint,
00388 const SMESH::PointStruct& RefPoint,
00389 CORBA::Boolean MakeGroups,
00390 SMESH::ElementType ElemType,
00391 SMESH::SMESH_MeshEditor::Extrusion_Error& Error);
00392
00393 SMESH::ListOfGroups* MirrorMakeGroups(const SMESH::long_array& IDsOfElements,
00394 const SMESH::AxisStruct& Mirror,
00395 SMESH::SMESH_MeshEditor::MirrorType MirrorType);
00396 SMESH::ListOfGroups* MirrorObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00397 const SMESH::AxisStruct& Mirror,
00398 SMESH::SMESH_MeshEditor::MirrorType MirrorType);
00399 SMESH::ListOfGroups* TranslateMakeGroups(const SMESH::long_array& IDsOfElements,
00400 const SMESH::DirStruct& Vector);
00401 SMESH::ListOfGroups* TranslateObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00402 const SMESH::DirStruct& Vector);
00403 SMESH::ListOfGroups* RotateMakeGroups(const SMESH::long_array& IDsOfElements,
00404 const SMESH::AxisStruct& Axis,
00405 CORBA::Double AngleInRadians);
00406 SMESH::ListOfGroups* RotateObjectMakeGroups(SMESH::SMESH_IDSource_ptr Object,
00407 const SMESH::AxisStruct& Axis,
00408 CORBA::Double AngleInRadians);
00409
00410 SMESH::SMESH_Mesh_ptr MirrorMakeMesh(const SMESH::long_array& IDsOfElements,
00411 const SMESH::AxisStruct& Mirror,
00412 SMESH::SMESH_MeshEditor::MirrorType MirrorType,
00413 CORBA::Boolean CopyGroups,
00414 const char* MeshName);
00415 SMESH::SMESH_Mesh_ptr MirrorObjectMakeMesh(SMESH::SMESH_IDSource_ptr Object,
00416 const SMESH::AxisStruct& Mirror,
00417 SMESH::SMESH_MeshEditor::MirrorType MirrorType,
00418 CORBA::Boolean CopyGroups,
00419 const char* MeshName);
00420 SMESH::SMESH_Mesh_ptr TranslateMakeMesh(const SMESH::long_array& IDsOfElements,
00421 const SMESH::DirStruct& Vector,
00422 CORBA::Boolean CopyGroups,
00423 const char* MeshName);
00424 SMESH::SMESH_Mesh_ptr TranslateObjectMakeMesh(SMESH::SMESH_IDSource_ptr Object,
00425 const SMESH::DirStruct& Vector,
00426 CORBA::Boolean CopyGroups,
00427 const char* MeshName);
00428 SMESH::SMESH_Mesh_ptr RotateMakeMesh(const SMESH::long_array& IDsOfElements,
00429 const SMESH::AxisStruct& Axis,
00430 CORBA::Double AngleInRadians,
00431 CORBA::Boolean CopyGroups,
00432 const char* MeshName);
00433 SMESH::SMESH_Mesh_ptr RotateObjectMakeMesh(SMESH::SMESH_IDSource_ptr Object,
00434 const SMESH::AxisStruct& Axis,
00435 CORBA::Double AngleInRadians,
00436 CORBA::Boolean CopyGroups,
00437 const char* MeshName);
00438
00439 void Scale(SMESH::SMESH_IDSource_ptr theObject,
00440 const SMESH::PointStruct& thePoint,
00441 const SMESH::double_array& theScaleFact,
00442 CORBA::Boolean theCopy);
00443
00444 SMESH::ListOfGroups* ScaleMakeGroups(SMESH::SMESH_IDSource_ptr theObject,
00445 const SMESH::PointStruct& thePoint,
00446 const SMESH::double_array& theScaleFact);
00447
00448 SMESH::SMESH_Mesh_ptr ScaleMakeMesh(SMESH::SMESH_IDSource_ptr Object,
00449 const SMESH::PointStruct& Point,
00450 const SMESH::double_array& theScaleFact,
00451 CORBA::Boolean CopyGroups,
00452 const char* MeshName);
00453
00454 void FindCoincidentNodes (CORBA::Double Tolerance,
00455 SMESH::array_of_long_array_out GroupsOfNodes);
00456 void FindCoincidentNodesOnPart(SMESH::SMESH_IDSource_ptr Object,
00457 CORBA::Double Tolerance,
00458 SMESH::array_of_long_array_out GroupsOfNodes);
00459 void FindCoincidentNodesOnPartBut(SMESH::SMESH_IDSource_ptr Object,
00460 CORBA::Double Tolerance,
00461 SMESH::array_of_long_array_out GroupsOfNodes,
00462 const SMESH::ListOfIDSources& ExceptSubMeshOrGroups);
00463 void MergeNodes (const SMESH::array_of_long_array& GroupsOfNodes);
00464 void FindEqualElements(SMESH::SMESH_IDSource_ptr Object,
00465 SMESH::array_of_long_array_out GroupsOfElementsID);
00466 void MergeElements(const SMESH::array_of_long_array& GroupsOfElementsID);
00467 void MergeEqualElements();
00468 CORBA::Long MoveClosestNodeToPoint(CORBA::Double x,
00469 CORBA::Double y,
00470 CORBA::Double z,
00471 CORBA::Long nodeID);
00475 CORBA::Long FindNodeClosestTo(CORBA::Double x,
00476 CORBA::Double y,
00477 CORBA::Double z);
00482 SMESH::long_array* FindElementsByPoint(CORBA::Double x,
00483 CORBA::Double y,
00484 CORBA::Double z,
00485 SMESH::ElementType type);
00486
00491 CORBA::Short GetPointState(CORBA::Double x, CORBA::Double y, CORBA::Double z);
00492
00493 SMESH::SMESH_MeshEditor::Sew_Error
00494 SewFreeBorders(CORBA::Long FirstNodeID1,
00495 CORBA::Long SecondNodeID1,
00496 CORBA::Long LastNodeID1,
00497 CORBA::Long FirstNodeID2,
00498 CORBA::Long SecondNodeID2,
00499 CORBA::Long LastNodeID2,
00500 CORBA::Boolean CreatePolygons,
00501 CORBA::Boolean CreatePolyedrs);
00502 SMESH::SMESH_MeshEditor::Sew_Error
00503 SewConformFreeBorders(CORBA::Long FirstNodeID1,
00504 CORBA::Long SecondNodeID1,
00505 CORBA::Long LastNodeID1,
00506 CORBA::Long FirstNodeID2,
00507 CORBA::Long SecondNodeID2);
00508 SMESH::SMESH_MeshEditor::Sew_Error
00509 SewBorderToSide(CORBA::Long FirstNodeIDOnFreeBorder,
00510 CORBA::Long SecondNodeIDOnFreeBorder,
00511 CORBA::Long LastNodeIDOnFreeBorder,
00512 CORBA::Long FirstNodeIDOnSide,
00513 CORBA::Long LastNodeIDOnSide,
00514 CORBA::Boolean CreatePolygons,
00515 CORBA::Boolean CreatePolyedrs);
00516 SMESH::SMESH_MeshEditor::Sew_Error
00517 SewSideElements(const SMESH::long_array& IDsOfSide1Elements,
00518 const SMESH::long_array& IDsOfSide2Elements,
00519 CORBA::Long NodeID1OfSide1ToMerge,
00520 CORBA::Long NodeID1OfSide2ToMerge,
00521 CORBA::Long NodeID2OfSide1ToMerge,
00522 CORBA::Long NodeID2OfSide2ToMerge);
00523
00529 CORBA::Boolean ChangeElemNodes(CORBA::Long ide, const SMESH::long_array& newIDs);
00530
00534 SMESH::MeshPreviewStruct* GetPreviewData();
00535
00541 SMESH::long_array* GetLastCreatedNodes();
00542
00548 SMESH::long_array* GetLastCreatedElems();
00549
00554 int GetMeshId() const { return myMesh->GetId(); }
00555
00556 CORBA::Boolean DoubleNodes( const SMESH::long_array& theNodes,
00557 const SMESH::long_array& theModifiedElems );
00558
00559 CORBA::Boolean DoubleNode( CORBA::Long theNodeId,
00560 const SMESH::long_array& theModifiedElems );
00561
00562 CORBA::Boolean DoubleNodeGroup( SMESH::SMESH_GroupBase_ptr theNodes,
00563 SMESH::SMESH_GroupBase_ptr theModifiedElems );
00564
00573 SMESH::SMESH_Group_ptr DoubleNodeGroupNew( SMESH::SMESH_GroupBase_ptr theNodes,
00574 SMESH::SMESH_GroupBase_ptr theModifiedElems );
00575
00576 CORBA::Boolean DoubleNodeGroups( const SMESH::ListOfGroups& theNodes,
00577 const SMESH::ListOfGroups& theModifiedElems );
00578
00579 SMESH::SMESH_Group_ptr DoubleNodeGroupsNew( const SMESH::ListOfGroups& theNodes,
00580 const SMESH::ListOfGroups& theModifiedElems );
00581
00592 CORBA::Boolean DoubleNodeElem( const SMESH::long_array& theElems,
00593 const SMESH::long_array& theNodesNot,
00594 const SMESH::long_array& theAffectedElems );
00595
00607 CORBA::Boolean DoubleNodeElemInRegion( const SMESH::long_array& theElems,
00608 const SMESH::long_array& theNodesNot,
00609 GEOM::GEOM_Object_ptr theShape );
00610
00620 CORBA::Boolean DoubleNodeElemGroup( SMESH::SMESH_GroupBase_ptr theElems,
00621 SMESH::SMESH_GroupBase_ptr theNodesNot,
00622 SMESH::SMESH_GroupBase_ptr theAffectedElems );
00623
00634 SMESH::SMESH_Group_ptr DoubleNodeElemGroupNew( SMESH::SMESH_GroupBase_ptr theElems,
00635 SMESH::SMESH_GroupBase_ptr theNodesNot,
00636 SMESH::SMESH_GroupBase_ptr theAffectedElems );
00637
00648 CORBA::Boolean DoubleNodeElemGroupInRegion( SMESH::SMESH_GroupBase_ptr theElems,
00649 SMESH::SMESH_GroupBase_ptr theNodesNot,
00650 GEOM::GEOM_Object_ptr theShape );
00651
00662 CORBA::Boolean DoubleNodeElemGroups( const SMESH::ListOfGroups& theElems,
00663 const SMESH::ListOfGroups& theNodesNot,
00664 const SMESH::ListOfGroups& theAffectedElems );
00665
00676 SMESH::SMESH_Group_ptr DoubleNodeElemGroupsNew( const SMESH::ListOfGroups& theElems,
00677 const SMESH::ListOfGroups& theNodesNot,
00678 const SMESH::ListOfGroups& theAffectedElems );
00679
00680
00692 CORBA::Boolean DoubleNodeElemGroupsInRegion( const SMESH::ListOfGroups& theElems,
00693 const SMESH::ListOfGroups& theNodesNot,
00694 GEOM::GEOM_Object_ptr theShape );
00705 CORBA::Boolean DoubleNodesOnGroupBoundaries( const SMESH::ListOfGroups& theDomains,
00706 CORBA::Boolean createJointElems );
00716 CORBA::Boolean CreateFlatElementsOnFacesGroups( const SMESH::ListOfGroups& theGroupsOfFaces );
00717
00723 CORBA::Boolean Make2DMeshFrom3D();
00724
00725 SMESH::SMESH_Mesh_ptr MakeBoundaryMesh(SMESH::SMESH_IDSource_ptr elements,
00726 SMESH::Bnd_Dimension dimension,
00727 const char* groupName,
00728 const char* meshName,
00729 CORBA::Boolean toCopyElements,
00730 CORBA::Boolean toCopyMissingBondary,
00731 SMESH::SMESH_Group_out group);
00732
00733 CORBA::Long MakeBoundaryElements(SMESH::Bnd_Dimension dimension,
00734 const char* groupName,
00735 const char* meshName,
00736 CORBA::Boolean toCopyAll,
00737 const SMESH::ListOfIDSources& groups,
00738 SMESH::SMESH_Mesh_out mesh,
00739 SMESH::SMESH_Group_out group)
00740 throw (SALOME::SALOME_Exception);
00741
00742 private:
00743
00744 SMESHDS_Mesh * GetMeshDS() { return myMesh->GetMeshDS(); }
00745
00750 void storeResult(::SMESH_MeshEditor& anEditor);
00754 void initData(bool deleteSearchers=true);
00755
00759 SMESH::ListOfGroups* getGroups(const std::list<int>* groupIDs);
00760
00761 SMESH::ListOfGroups* rotationSweep(const SMESH::long_array & IDsOfElements,
00762 const SMESH::AxisStruct & Axis,
00763 CORBA::Double AngleInRadians,
00764 CORBA::Long NbOfSteps,
00765 CORBA::Double Tolerance,
00766 const bool MakeGroups,
00767 const SMDSAbs_ElementType ElementType=SMDSAbs_All);
00768 SMESH::ListOfGroups* extrusionSweep(const SMESH::long_array & IDsOfElements,
00769 const SMESH::DirStruct & StepVector,
00770 CORBA::Long NbOfSteps,
00771 bool MakeGroups,
00772 const SMDSAbs_ElementType ElementType=SMDSAbs_All);
00773 SMESH::ListOfGroups* advancedExtrusion(const SMESH::long_array & theIDsOfElements,
00774 const SMESH::DirStruct & theStepVector,
00775 CORBA::Long theNbOfSteps,
00776 CORBA::Long theExtrFlags,
00777 CORBA::Double theSewTolerance,
00778 const bool MakeGroups);
00779 SMESH::ListOfGroups* extrusionAlongPath(const SMESH::long_array & IDsOfElements,
00780 SMESH::SMESH_Mesh_ptr PathMesh,
00781 GEOM::GEOM_Object_ptr PathShape,
00782 CORBA::Long NodeStart,
00783 CORBA::Boolean HasAngles,
00784 const SMESH::double_array & Angles,
00785 CORBA::Boolean HasRefPoint,
00786 const SMESH::PointStruct & RefPoint,
00787 const bool MakeGroups,
00788 SMESH::SMESH_MeshEditor::Extrusion_Error & Error,
00789 const SMDSAbs_ElementType ElementType=SMDSAbs_All);
00790 SMESH::ListOfGroups* extrusionAlongPathX(const SMESH::long_array & IDsOfElements,
00791 SMESH::SMESH_IDSource_ptr Path,
00792 CORBA::Long NodeStart,
00793 CORBA::Boolean HasAngles,
00794 const SMESH::double_array& Angles,
00795 CORBA::Boolean LinearVariation,
00796 CORBA::Boolean HasRefPoint,
00797 const SMESH::PointStruct& RefPoint,
00798 bool MakeGroups,
00799 const SMDSAbs_ElementType ElementType,
00800 SMESH::SMESH_MeshEditor::Extrusion_Error & theError);
00801 SMESH::ListOfGroups* mirror(TIDSortedElemSet & IDsOfElements,
00802 const SMESH::AxisStruct & Axis,
00803 SMESH::SMESH_MeshEditor::MirrorType MirrorType,
00804 CORBA::Boolean Copy,
00805 bool MakeGroups,
00806 ::SMESH_Mesh* TargetMesh=0);
00807 SMESH::ListOfGroups* translate(TIDSortedElemSet & IDsOfElements,
00808 const SMESH::DirStruct & Vector,
00809 CORBA::Boolean Copy,
00810 bool MakeGroups,
00811 ::SMESH_Mesh* TargetMesh=0);
00812 SMESH::ListOfGroups* rotate(TIDSortedElemSet & IDsOfElements,
00813 const SMESH::AxisStruct & Axis,
00814 CORBA::Double Angle,
00815 CORBA::Boolean Copy,
00816 bool MakeGroups,
00817 ::SMESH_Mesh* TargetMesh=0);
00818
00819 SMESH::ListOfGroups* scale(SMESH::SMESH_IDSource_ptr theObject,
00820 const SMESH::PointStruct& thePoint,
00821 const SMESH::double_array& theScaleFact,
00822 CORBA::Boolean theCopy,
00823 bool theMakeGroups,
00824 ::SMESH_Mesh* theTargetMesh=0);
00825
00826 SMESH::SMESH_Mesh_ptr makeMesh(const char* theMeshName);
00827
00828 void DumpGroupsList(SMESH::TPythonDump & theDumpPython,
00829 const SMESH::ListOfGroups * theGroupList);
00830
00831 string generateGroupName(const string& thePrefix);
00832
00833 private:
00834
00835 SMESH_Mesh_i* myMesh_i;
00836 SMESH_Mesh * myMesh;
00837
00838 SMESH::long_array_var myLastCreatedElems;
00839 SMESH::long_array_var myLastCreatedNodes;
00840
00841 SMESH::MeshPreviewStruct_var myPreviewData;
00842 bool myPreviewMode;
00843 };
00844
00845 #endif