1 // Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
22 // File : GEOM_Gen.idl
23 // Author : Sergey RUIN
28 #include "SALOME_Exception.idl"
29 #include "SALOME_Component.idl"
30 #include "SALOMEDS.idl"
31 #include "SALOMEDS_Attributes.idl"
33 #include "SALOME_GenericObj.idl"
38 * Topological types of shapes (like Open Cascade types)
40 enum shape_type { COMPOUND, COMPSOLID, SOLID, SHELL,
41 FACE, WIRE, EDGE, VERTEX, SHAPE };
46 enum marker_type { MT_NONE, MT_POINT, MT_PLUS, MT_STAR, MT_O, MT_X, MT_O_POINT, MT_O_PLUS,
47 MT_O_STAR, MT_O_X, MT_BALL, MT_RING1, MT_RING2, MT_RING3, MT_USER };
52 enum marker_size { MS_NONE, MS_10, MS_15, MS_20, MS_25, MS_30, MS_35,
53 MS_40, MS_45, MS_50, MS_55, MS_60, MS_65, MS_70 };
56 * State of shape relatively geometrical surface like plane, sphere or cylinder.
57 * Is used in functions GEOM_IShapesOperations.GetShapesOn<xxx>()
61 /*! Shape is on surface */
65 * Shape is in the direction defined by the normal and not on surface.
66 * For plane it means above the plane,
67 * For sphere and cylinder it means outside of volume, bounded by the surface.
72 * Shape is in the direction defined by the normal and on surface.
78 * Complementary to ONOUT.
79 * For plane it means below the plane,
80 * For sphere and cylinder it means inside the volume, bounded by the surface
81 * (beyond axis and surface for cylinder and beyond cented and surface for sphere).
86 * Complementary to OUT.
93 * Kind of method to find inside one main shape some subshapes,
94 * corresponding to other given shape (its argument)
95 * Is used in functions GEOM_Gen.RestoreSubShapes<xxx>()
97 enum find_shape_method
99 /*! Use GetInPlace functionality. Suits all cases, except transformations */
102 /*! To be used only for transformation result, to find subshapes of argument.
103 * Only this method can be used after transformation.
107 /*! To find only shared subshapes, not modified by the operation */
110 /*! Use GetShapesOnShape method (can work only on solids) */
111 FSM_GetShapesOnShape,
113 /*! Use GetInPlaceByHistory method (can work only after Partition) */
114 FSM_GetInPlaceByHistory
118 typedef sequence<string> string_array;
119 typedef sequence<short> short_array;
120 typedef sequence<long> ListOfLong;
121 typedef sequence<double> ListOfDouble;
123 interface GEOM_Object;
125 typedef sequence<GEOM_Object> ListOfGO;
128 * GEOM_Object: interface of geometric object
130 interface GEOM_Object : SALOME::GenericObj
134 * Get an entry of the object in GEOM component.
139 * Get ID of study, where the object is created.
144 * Get internal type of the object (POINT, BOX, CYLINDER, EXTRUSION...).
149 * Get a <VAR>shape_type</VAR> of the object value.
151 shape_type GetShapeType();
154 * Set name of the object.
155 * \param theName is a name which will be associated with this object.
157 void SetName (in string theName);
160 * Get name of the object associated with this object.
165 * Set color of the object.
166 * \param theColor is a color of the object.
168 void SetColor(in SALOMEDS::Color theColor);
171 * Get color of the object.
173 SALOMEDS::Color GetColor();
176 * Toggle auto color mode on the object.
177 * \param theAtoColor is a flag which toggles auto color mode.
179 void SetAutoColor(in boolean theAutoColor);
182 * Get flag of object's auto color mode.
184 boolean GetAutoColor();
187 * Set standard point marker for the object
188 * \param theType standard marker type
189 * \param theSize marker relative size
191 void SetMarkerStd(in marker_type theType, in marker_size theSize );
194 * Set custom point marker for the object. The texture can be added
195 * by LoadTexture() or AddTexture() functions.
196 * \param theTextureId texture ID
198 void SetMarkerTexture(in long theTextureId);
201 * Get type of the point marker assigned to the object
202 * \return current marker type (MT_NONE if no marker is set)
204 marker_type GetMarkerType();
207 * Get size of the point marker assigned to the object
208 * \return current marker relative size (MS_NONE if no marker is set)
210 marker_size GetMarkerSize();
213 * Get texture idenifier of the point marker assigned to the object
214 * \return marker texture ID (0 if no marker set)
216 long GetMarkerTexture();
219 * Set a Study entry where this object was published.
221 void SetStudyEntry (in string theEntry);
224 * Get a Study entry where this object was published.
226 string GetStudyEntry();
229 * Get a list of all GEOM objects on which were the arguments
230 * when this object was constructed and modified.
231 * \note This method is supposed to be used by GUI only.
233 ListOfGO GetDependency();
236 * Get a list of GEOM objects on which the last function that created or modified the object depends.
237 * \note This method is supposed to be used by GUI only.
239 ListOfGO GetLastDependency();
242 * Get the TopoDS_Shape, for colocated case only.
244 long long getShape();
247 ######################################################################
248 * Internal methods (For sub shape identification)
249 ######################################################################
253 * Get geometric shape of the object as a byte stream
255 SALOMEDS::TMPFile GetShapeStream();
258 * Returns True if this object is not a sub shape of another object.
260 boolean IsMainShape();
263 * Get a list of ID's of sub shapes in the main shape.
264 * \note Internal method, suppopsed to be used only by GEOM_Client
266 ListOfLong GetSubShapeIndices();
269 * Get a main shape object to which this object is a sub shape
270 * \note Internal method, suppopsed to be used only by GEOM_Client
272 GEOM_Object GetMainShape();
275 * Return true if geom object representes a shape.
276 * For example, method return false for GEOM_MARKER
281 * Set list of parameters
282 * \param theParameters is a string containing the notebook variables separated by ":" symbol,
283 * used for object creation
285 void SetParameters (in string theParameters);
288 * Return list of notebook variables used for object creation separated by ":" symbol
290 string GetParameters();
295 * GEOM_IOperations: basic methods of all geometric operations
297 interface GEOM_IOperations : SALOME::GenericObj
300 * To know, if the operation was successfully performed
305 * Set the operation error code
306 * \param theErrorID is a string describing the error occured
307 * \note This method is supposed to be used only by interfaces inheriting from IOperations.
309 void SetErrorCode (in string theErrorID);
312 * Get the operation error code
314 string GetErrorCode();
317 * Get ID of study, where the operation is defined
322 * Opens a new transaction
324 void StartOperation();
327 * Closes the previously opened trasaction
329 void FinishOperation();
332 * Aborts the previously opened transaction
334 void AbortOperation();
338 * GEOM_IBasicOperations: interface for basic geometry creation
339 * (Point, Vector, Plane, Marker)
341 interface GEOM_IBasicOperations : GEOM_IOperations
344 * Create point by three coordinates.
345 * \param theX The X coordinate of the point.
346 * \param theY The Y coordinate of the point.
347 * \param theZ The Z coordinate of the point.
348 * \return New GEOM_Object, containing the created point.
350 GEOM_Object MakePointXYZ (in double theX, in double theY, in double theZ);
353 * Create a point, distant from the referenced point
354 * on the given distances along the coordinate axes.
355 * \param theReference The referenced point.
356 * \param theX Displacement from the referenced point along OX axis.
357 * \param theY Displacement from the referenced point along OY axis.
358 * \param theZ Displacement from the referenced point along OZ axis.
359 * \return New GEOM_Object, containing the created point.
361 GEOM_Object MakePointWithReference (in GEOM_Object theReference,
362 in double theX, in double theY, in double theZ);
365 * Create a point, corresponding to the given parameter on the given curve.
366 * \param theRefCurve The referenced curve.
367 * \param theParameter Value of parameter on the referenced curve.
368 * \return New GEOM_Object, containing the created point.
370 GEOM_Object MakePointOnCurve (in GEOM_Object theRefCurve,
371 in double theParameter);
374 * Create a point on the given curve, projecting given point
375 * \param theRefCurve The referenced curve.
376 * \param theXParameter X co-ordinate of point to project on curve
377 * \param theYParameter Y co-ordinate of point to project on curve
378 * \param theZParameter Z co-ordinate of point to project on curve
379 * \return New GEOM_Object, containing the created point.
381 GEOM_Object MakePointOnCurveByCoord (in GEOM_Object theRefCurve,
382 in double theXParameter,
383 in double theYarameter,
384 in double theZPameter);
387 * Create a point, corresponding to the given parameters on the
389 * \param theRefSurf The referenced surface.
390 * \param theUParameter Value of U-parameter on the referenced surface.
391 * \param theVParameter Value of V-parameter on the referenced surface.
392 * \return New GEOM_Object, containing the created point.
394 GEOM_Object MakePointOnSurface (in GEOM_Object theRefSurf,
395 in double theUParameter,
396 in double theVParameter);
399 * Create a point on the given surface, projecting given point
400 * \param theRefSurf The referenced surface.
401 * \param theXParameter X co-ordinate of point to project on curve
402 * \param theYParameter Y co-ordinate of point to project on curve
403 * \param theZParameter Z co-ordinate of point to project on curve
404 * \return New GEOM_Object, containing the created point.
406 GEOM_Object MakePointOnSurfaceByCoord (in GEOM_Object theRefSurf,
407 in double theXParameter,
408 in double theYarameter,
409 in double theZPameter);
413 * Create a point, on two lines intersection.
414 * \param theRefLine1, theRefLine2 The referenced lines.
415 * \return New GEOM_Object, containing the created point.
417 GEOM_Object MakePointOnLinesIntersection (in GEOM_Object theRefLine1,
418 in GEOM_Object theRefLine2);
421 * Create a vector, corresponding to tangent to the given parameter on the given curve.
422 * \param theRefCurve The referenced curve.
423 * \param theParameter Value of parameter on the referenced curve.This value should be have value
424 * \between 0. and 1.. Value of 0. corresponds first parameter of curve value 1. corresponds
425 * \last parameter of curve.
426 * \return New GEOM_Object, containing the created point.
428 GEOM_Object MakeTangentOnCurve (in GEOM_Object theRefCurve,
429 in double theParameter);
432 * Create a vector with the given components.
433 * \param theDX X component of the vector.
434 * \param theDY Y component of the vector.
435 * \param theDZ Z component of the vector.
436 * \return New GEOM_Object, containing the created vector.
438 GEOM_Object MakeVectorDXDYDZ (in double theDX,
443 * Create a vector between two points.
444 * \param thePnt1 Start point for the vector.
445 * \param thePnt2 End point for the vector.
446 * \return New GEOM_Object, containing the created vector.
448 GEOM_Object MakeVectorTwoPnt (in GEOM_Object thePnt1, in GEOM_Object thePnt2);
451 * Create a line, passing through the given point
452 * and parrallel to the given direction
453 * \param thePnt Point. The resulting line will pass through it.
454 * \param theDir Direction. The resulting line will be parallel to it.
455 * \return New GEOM_Object, containing the created line.
457 GEOM_Object MakeLine (in GEOM_Object thePnt, in GEOM_Object theDir);
460 * Create a line, passing through the given points
461 * \param thePnt1 First of two points, defining the line.
462 * \param thePnt2 Second of two points, defining the line.
463 * \return New GEOM_Object, containing the created line.
465 GEOM_Object MakeLineTwoPnt (in GEOM_Object thePnt1, in GEOM_Object thePnt2);
468 * Create a line, given by two faces intersection.
469 * \param theFace1 First of two faces, defining the line.
470 * \param theFace2 Second of two faces, defining the line.
471 * \return New GEOM_Object, containing the created line.
473 GEOM_Object MakeLineTwoFaces (in GEOM_Object theFace1, in GEOM_Object theFace2);
476 * Create a plane, passing through the three given points
477 * \param thePnt1 First of three points, defining the plane.
478 * \param thePnt2 Second of three points, defining the plane.
479 * \param thePnt3 Fird of three points, defining the plane.
480 * \param theTrimSize Half size of a side of quadrangle face, representing the plane.
481 * \return New GEOM_Object, containing the created plane.
483 GEOM_Object MakePlaneThreePnt (in GEOM_Object thePnt1,
484 in GEOM_Object thePnt2,
485 in GEOM_Object thePnt3,
486 in double theTrimSize);
489 * Create a plane, passing through the given point
490 * and normal to the given vector.
491 * \param thePnt Point, the plane has to pass through.
492 * \param theVec Vector, defining the plane normal direction.
493 * \param theTrimSize Half size of a side of quadrangle face, representing the plane.
494 * \return New GEOM_Object, containing the created plane.
496 GEOM_Object MakePlanePntVec (in GEOM_Object thePnt,
497 in GEOM_Object theVec,
498 in double theTrimSize);
501 * Create a plane, similar to the existing one, but with another size of representing face.
502 * \param theFace Referenced plane or LCS(Marker).
503 * \param theTrimSize New half size of a side of quadrangle face, representing the plane.
504 * \return New GEOM_Object, containing the created plane.
506 GEOM_Object MakePlaneFace (in GEOM_Object theFace,
507 in double theTrimSize);
510 * Create a plane, by two vectors.
511 * \param theVec1 Vector1, the plane has to pass through first point of this vector.
512 * \param theVec Vector2, defining the plane normal direction.
513 * \param theTrimSize Half size of a side of quadrangle face, representing the plane.
514 * \return New GEOM_Object, containing the created plane.
516 GEOM_Object MakePlane2Vec (in GEOM_Object theVec1,
517 in GEOM_Object theVec2,
518 in double theTrimSize);
521 * Create a plane, defined by local coordinate system.
522 * \param theLCS Referenced LCS(Marker).
523 * \param theTrimSize Half size of a side of quadrangle face, representing the plane.
524 * \param theOrientation OXY, OYZ or OZX orientation = (1, 2 or 3).
525 * \return New GEOM_Object, containing the created plane.
527 GEOM_Object MakePlaneLCS (in GEOM_Object theLCS,
528 in double theTrimSize,
529 in double theOrientation);
532 * Create a local coordinate system.
533 * \param theOX,theOY,theOZ Three coordinates of coordinate system origin.
534 * \param theXDX,theXDY,theXDZ Three components of OX direction
535 * \param theYDX,theYDY,theYDZ Three components of OY direction
536 * \return New GEOM_Object, containing the created coordinate system.
538 GEOM_Object MakeMarker (in double theOX , in double theOY , in double theOZ,
539 in double theXDX, in double theXDY, in double theXDZ,
540 in double theYDX, in double theYDY, in double theYDZ);
543 * Create a tangent plane to specified face in the point with specified parameters.
544 * Values of parameters should be between 0. and 1.0
545 * \param theFace - face for which tangent plane shuold be built.
546 * \param theParameterU - value of parameter by U
547 * \param theParameterV - value of parameter Vthe
548 * \param theTrimSize - defines sizes of created face
549 * \return New GEOM_Object, containing the face built on tangent plane.
551 GEOM_Object MakeTangentPlaneOnFace(in GEOM_Object theFace,
552 in double theParameterU,
553 in double theParameterV,
554 in double theTrimSize);
557 interface GEOM_ITransformOperations : GEOM_IOperations
560 * Translate the given object along the vector, specified by its end points.
561 * \param theObject The object to be translated.
562 * \param thePoint1 Start point of translation vector.
563 * \param thePoint2 End point of translation vector.
566 GEOM_Object TranslateTwoPoints (in GEOM_Object theObject,
567 in GEOM_Object thePoint1,
568 in GEOM_Object thePoint2);
571 * Translate the given object along the vector, specified
572 * by its end points, creating its copy before the translation.
573 * \param theObject The object to be translated.
574 * \param thePoint1 Start point of translation vector.
575 * \param thePoint2 End point of translation vector.
576 * \return New GEOM_Object, containing the translated object.
578 GEOM_Object TranslateTwoPointsCopy (in GEOM_Object theObject,
579 in GEOM_Object thePoint1,
580 in GEOM_Object thePoint2);
583 * Translate the given object along the vector, specified by its components.
584 * \param theObject The object to be translated.
585 * \param theDX,theDY,theDZ Components of translation vector.
588 GEOM_Object TranslateDXDYDZ (in GEOM_Object theObject,
589 in double theDX, in double theDY, in double theDZ);
592 * Translate the given object along the vector, specified
593 * by its components, creating its copy before the translation.
594 * \param theObject The object to be translated.
595 * \param theDX,theDY,theDZ Components of translation vector.
596 * \return New GEOM_Object, containing the translated object.
598 GEOM_Object TranslateDXDYDZCopy (in GEOM_Object theObject,
599 in double theDX, in double theDY, in double theDZ);
603 * Translate the given object along the given vector.
604 * \param theObject The object to be translated.
605 * \param theVector Translation vector, giving both direction and distance.
608 GEOM_Object TranslateVector (in GEOM_Object theObject,
609 in GEOM_Object theVector);
612 * Translate the given object along the given vector,
613 * creating its copy before the translation.
614 * \param theObject The object to be translated.
615 * \param theVector Translation vector, giving both direction and distance.
616 * \return New GEOM_Object, containing the translated object.
618 GEOM_Object TranslateVectorCopy (in GEOM_Object theObject,
619 in GEOM_Object theVector);
622 * Translate the given object along the given vector on given distance,
623 * creating its copy before the translation.
624 * \param theObject The object to be translated.
625 * \param theVector Translation vector, giving a direction.
626 * \param theDistance Translation distance, giving a distance.
627 * \param theCope Translation copy, creating its copy if true.
628 * \return New GEOM_Object, containing the translated object.
630 GEOM_Object TranslateVectorDistance (in GEOM_Object theObject,
631 in GEOM_Object theVector,
632 in double theDistance,
636 * Translate the given object along the given vector a given number times
637 * \param theObject The object to be translated.
638 * \param theVector Direction of the translation.
639 * \param theStep Distance to translate on.
640 * \param theNbTimes Quantity of translations to be done.
641 * \return New GEOM_Object, containing compound of all
642 * the shapes, obtained after each translation.
644 GEOM_Object MultiTranslate1D (in GEOM_Object theObject,
645 in GEOM_Object theVector,
650 * Conseqently apply two specified translations to theObject specified number of times.
651 * \param theObject The object to be translated.
652 * \param theVector1 Direction of the first translation.
653 * \param theStep1 Step of the first translation.
654 * \param theNbTimes1 Quantity of translations to be done along theVector1.
655 * \param theVector2 Direction of the second translation.
656 * \param theStep2 Step of the second translation.
657 * \param theNbTimes2 Quantity of translations to be done along theVector2.
658 * \return New GEOM_Object, containing compound of all
659 * the shapes, obtained after each translation.
661 GEOM_Object MultiTranslate2D (in GEOM_Object theObject,
662 in GEOM_Object theVector1,
665 in GEOM_Object theVector2,
667 in long theNbTimes2);
670 * Rotate given object around vector perpendicular to plane containing three points.
671 * \param theObject The object to be rotated.
672 * \param theCentPoint central point - the axis is the vector perpendicular to the plane
673 * containing the three points.
674 * \param thePoint1 and thePoint2 - in a perpendicular plan of the axis.
677 GEOM_Object RotateThreePoints (in GEOM_Object theObject,
678 in GEOM_Object theCentPoint,
679 in GEOM_Object thePoint1,
680 in GEOM_Object thePoint2);
684 * Rotate given object around vector perpendicular to plane containing three points.
685 * Creating its copy before the rotatation.
686 * \param theObject The object to be rotated.
687 * \param theCentPoint central point - the axis is the vector perpendicular to the plane
688 * containing the three points.
689 * \param thePoint1 and thePoint2 - in a perpendicular plan of the axis.
690 * \return New GEOM_Object, containing the rotated object.
692 GEOM_Object RotateThreePointsCopy (in GEOM_Object theObject,
693 in GEOM_Object theCentPoint,
694 in GEOM_Object thePoint1,
695 in GEOM_Object thePoint2);
698 * Rotate the given object around the given axis on the given angle.
699 * \param theObject The object to be rotated.
700 * \param theAxis Rotation axis.
701 * \param theAngle Rotation angle in radians.
704 GEOM_Object Rotate (in GEOM_Object theObject,
705 in GEOM_Object theAxis,
710 * Rotate the given object around the given axis
711 * on the given angle, creating its copy before the rotatation.
712 * \param theObject The object to be rotated.
713 * \param theAxis Rotation axis.
714 * \param theAngle Rotation angle in radians.
715 * \return New GEOM_Object, containing the rotated object.
717 GEOM_Object RotateCopy (in GEOM_Object theObject,
718 in GEOM_Object theAxis,
723 * Rotate the given object around the given axis a given number times.
724 * Rotation angle will be 2*PI/theNbTimes.
725 * \param theObject The object to be rotated.
726 * \param theAxis The rotation axis.
727 * \param theNbTimes Quantity of rotations to be done.
728 * \return New GEOM_Object, containing compound of all the
729 * shapes, obtained after each rotation.
731 GEOM_Object MultiRotate1D (in GEOM_Object theObject,
732 in GEOM_Object theAxis,
736 * Rotate the given object around the
737 * given axis on the given angle a given number
738 * times and multi-translate each rotation result.
739 * Translation direction passes through center of gravity
740 * of rotated shape and its projection on the rotation axis.
741 * \param theObject The object to be rotated.
742 * \param theAxis Rotation axis.
743 * \param theAngle Rotation angle in graduces.
744 * \param theNbTimes1 Quantity of rotations to be done.
745 * \param theStep Translation distance.
746 * \param theNbTimes2 Quantity of translations to be done.
747 * \return New GEOM_Object, containing compound of all the
748 * shapes, obtained after each transformation.
750 GEOM_Object MultiRotate2D (in GEOM_Object theObject,
751 in GEOM_Object theAxis,
755 in long theNbTimes2);
758 * Replace the given object by an object,
759 * symmetrical to it relatively the given plane.
760 * \param theObject The object to be mirrored.
761 * \param thePlane Plane of symmetry.
763 GEOM_Object MirrorPlane (in GEOM_Object theObject, in GEOM_Object thePlane);
766 * Create an object, symmetrical
767 * to the given one relatively the given plane.
768 * \param theObject The object to be mirrored.
769 * \param thePlane Plane of symmetry.
770 * \return New GEOM_Object, containing the mirrored shape.
772 GEOM_Object MirrorPlaneCopy (in GEOM_Object theObject, in GEOM_Object thePlane);
775 * Replace the given object by an object,
776 * symmetrical to it relatively the given axis.
777 * \param theObject The object to be mirrored.
778 * \param theAxis Axis of symmetry.
781 GEOM_Object MirrorAxis (in GEOM_Object theObject, in GEOM_Object theAxis);
784 * Create an object, symmetrical
785 * to the given one relatively the given axis.
786 * \param theObject The object to be mirrored.
787 * \param theAxis Axis of symmetry.
788 * \return New GEOM_Object, containing the mirrored object.
790 GEOM_Object MirrorAxisCopy (in GEOM_Object theObject, in GEOM_Object theAxis);
793 * Replace the given object by an object, symmetrical to it relatively the given point.
794 * \param theObject The object to be mirrored.
795 * \param thePoint Point of symmetry.
798 GEOM_Object MirrorPoint (in GEOM_Object theObject, in GEOM_Object thePoint);
801 * Create an object, symmetrical to the given one relatively the given point.
802 * \param theObject The object to be mirrored.
803 * \param thePoint Point of symmetry.
804 * \return New GEOM_Object, containing the mirrored object.
806 GEOM_Object MirrorPointCopy (in GEOM_Object theObject, in GEOM_Object thePoint);
809 * Replace the given object by its offset.
810 * \param theObject The base object for the offset.
811 * \param theOffset Offset value.
814 GEOM_Object OffsetShape (in GEOM_Object theObject, in double theOffset);
817 * Create new object as offset of the given one.
818 * \param theObject The base object for the offset.
819 * \param theOffset Offset value.
820 * \return New GEOM_Object, containing the offset object.
822 GEOM_Object OffsetShapeCopy (in GEOM_Object theObject, in double theOffset);
825 * Scale the given object by the factor.
826 * \param theObject The object to be scaled.
827 * \param thePoint Center point for scaling.
828 * \param theFactor Scaling factor value.
831 GEOM_Object ScaleShape (in GEOM_Object theObject, in GEOM_Object thePoint,
832 in double theFactor);
835 * Scale the given object by the factor, creating its copy before the scaling.
836 * \param theObject The object to be scaled.
837 * \param thePoint Center point for scaling.
838 * \param theFactor Scaling factor value.
839 * \return New GEOM_Object, containing the scaled shape.
841 GEOM_Object ScaleShapeCopy (in GEOM_Object theObject, in GEOM_Object thePoint,
842 in double theFactor);
845 * Scale the given object by different factors along coordinate axes.
846 * \param theObject The object to be scaled.
847 * \param thePoint Center point for scaling.
848 * \param theFactorX,theFactorY,theFactorZ Scaling factors along each axis.
851 GEOM_Object ScaleShapeAlongAxes (in GEOM_Object theObject,
852 in GEOM_Object thePoint,
853 in double theFactorX,
854 in double theFactorY,
855 in double theFactorZ);
858 * Scale the given object by different factors along coordinate axes,
859 * creating its copy before the scaling.
860 * \param theObject The object to be scaled.
861 * \param thePoint Center point for scaling.
862 * \param theFactorX,theFactorY,theFactorZ Scaling factors along each axis.
863 * \return New GEOM_Object, containing the scaled shape.
865 GEOM_Object ScaleShapeAlongAxesCopy (in GEOM_Object theObject,
866 in GEOM_Object thePoint,
867 in double theFactorX,
868 in double theFactorY,
869 in double theFactorZ);
872 * Modify the Location of the given object by LCS.
873 * \param theObject The object to be displaced.
874 * \param theStartLCS Coordinate system to perform displacement from it.
875 * If \a theStartLCS is NULL, displacement
876 * will be performed from global CS.
877 * If \a theObject itself is used as \a theStartLCS,
878 * its location will be changed to \a theEndLCS.
879 * \param theEndLCS Coordinate system to perform displacement to it.
882 GEOM_Object PositionShape (in GEOM_Object theObject,
883 in GEOM_Object theStartLCS,
884 in GEOM_Object theEndLCS);
887 * Modify the Location of the given object by LCS,
888 * creating its copy before the setting.
889 * \param theObject The object to be displaced.
890 * \param theStartLCS Coordinate system to perform displacement from it.
891 * If \a theStartLCS is NULL, displacement
892 * will be performed from global CS.
893 * If \a theObject itself is used as \a theStartLCS,
894 * its location will be changed to \a theEndLCS.
895 * \param theEndLCS Coordinate system to perform displacement to it.
896 * \return New GEOM_Object, containing the displaced shape.
898 GEOM_Object PositionShapeCopy (in GEOM_Object theObject,
899 in GEOM_Object theStartLCS,
900 in GEOM_Object theEndLCS);
903 * Modify the Location of the given object by Path,
904 * \param theObject The object to be displaced.
905 * \param thePath Wire or Edge along that the object will be translated.
906 * \param theDistance progress of Path (0 = actual location, 1 = end of path location).
907 * \param theCopy is a true or false parameter. true is to create a copy, false to move the object.
908 * \param theCopy is a true or false parameter. true is to reverse direction, false is to move normal direction.
909 * \return New GEOM_Object, containing the displaced shape.
912 GEOM_Object PositionAlongPath (in GEOM_Object theObject,
913 in GEOM_Object thePath,
914 in double theDistance,
916 in boolean theReverse);
919 * Recompute the shape from its arguments.
920 * \param theObject The object to be recomputed.
923 GEOM_Object RecomputeObject (in GEOM_Object theObject);
927 * GEOM_I3DPrimOperations: Interface for 3D primitives creation
928 * Box, Cylinder, Cone, Sphere, Prism (extrusion),
929 * Pipe (extrusion along contour), Revolution, Solid (from shell).
931 interface GEOM_I3DPrimOperations : GEOM_IOperations
934 * Create a box with specified dimensions along the coordinate axes
935 * and with edges, parallel to the coordinate axes.
936 * Center of the box will be at point (DX/2, DY/2, DZ/2).
937 * \param theDX Length of Box edges, parallel to OX axis.
938 * \param theDY Length of Box edges, parallel to OY axis.
939 * \param theDZ Length of Box edges, parallel to OZ axis.
940 * \return New GEOM_Object, containing the created box.
942 GEOM_Object MakeBoxDXDYDZ (in double theDX, in double theDY, in double theDZ);
945 * Create a box with two specified opposite vertices,
946 * and with edges, parallel to the coordinate axes
947 * \param thePnt1 First of two opposite vertices.
948 * \param thePnt2 Second of two opposite vertices.
949 * \return New GEOM_Object, containing the created box.
951 GEOM_Object MakeBoxTwoPnt (in GEOM_Object thePnt1, in GEOM_Object thePnt2);
954 * Create a face specified dimensions along OX-OY coordinate axes,
955 * with edges parallel to the coordinate axes.
956 * Center of the face will be at point (0, 0, 0).
957 * \param theH Height of the Face.
958 * \param theW Width of the Face.
959 * \param theOrientation Orientation belong axis OXY OYZ OZX
960 * \return New GEOM_Object, containing the created face.
962 GEOM_Object MakeFaceHW (in double theH, in double theW, in short theOrientation);
964 * Create a face by normale vector or edge and two specified sizes,
965 * vertical (H) and horisontal (W).
966 * \param theVec defines plane.
967 * \param theH vertical size (height).
968 * \param theW horisontal size (width).
969 * \return New GEOM_Object, containing the created face.
971 GEOM_Object MakeFaceObjHW (in GEOM_Object theObj, in double theH, in double theW);
973 * Create a Disk (circular face) with given center, normal vector and radius.
974 * \param thePnt disk center.
975 * \param theVec Vector, normal to the plane of the disk.
976 * \param theR Disk radius.
977 * \return New GEOM_Object, containing the created disk.
979 GEOM_Object MakeDiskPntVecR (in GEOM_Object thePnt,
980 in GEOM_Object theVec,
983 * Create a disk (circular face), passing through three given points
984 * \param thePnt1, thePnt2, thePnt3 Points, defining the disk.
985 * \return New GEOM_Object, containing the created disk.
987 GEOM_Object MakeDiskThreePnt (in GEOM_Object thePnt1,
988 in GEOM_Object thePnt2,
989 in GEOM_Object thePnt3);
992 * Create a disk specified dimensions along OX-OY coordinate axes,
993 * Center of the disk at point (0, 0, 0).
994 * \param theR of the Disk.
995 * \param theOrientation Orientation belong axis OXY OYZ OZX
996 * \return New GEOM_Object, containing the created disk.
998 GEOM_Object MakeDiskR (in double theR, in short theOrientation);
1001 * Create a cylinder with given radius and height at
1002 * the origin of coordinate system. Axis of the cylinder
1003 * will be collinear to the OZ axis of the coordinate system.
1004 * \param theR Cylinder radius.
1005 * \param theH Cylinder height.
1006 * \return New GEOM_Object, containing the created cylinder.
1008 GEOM_Object MakeCylinderRH (in double theR, in double theH);
1011 * Create a cylinder with given base point, axis, radius and height.
1012 * \param thePnt Central point of cylinder base.
1013 * \param theAxis Cylinder axis.
1014 * \param theR Cylinder radius.
1015 * \param theH Cylinder height.
1016 * \return New GEOM_Object, containing the created cylinder.
1018 GEOM_Object MakeCylinderPntVecRH (in GEOM_Object thePnt,
1019 in GEOM_Object theAxis,
1024 * Create a cone with given height and radiuses at
1025 * the origin of coordinate system. Axis of the cone will
1026 * be collinear to the OZ axis of the coordinate system.
1027 * \param theR1 Radius of the first cone base.
1028 * \param theR2 Radius of the second cone base.
1029 * \note If both radiuses are non-zero, the cone will be truncated.
1030 * \note If the radiuses are equal, a cylinder will be created instead.
1031 * \param theH Cone height.
1032 * \return New GEOM_Object, containing the created cone.
1034 GEOM_Object MakeConeR1R2H (in double theR1, in double theR2, in double theH);
1037 * Create a cone with given base point, axis, height and radiuses.
1038 * \param thePnt Central point of the first cone base.
1039 * \param theAxis Cone axis.
1040 * \param theR1 Radius of the first cone base.
1041 * \param theR2 Radius of the second cone base.
1042 * \note If both radiuses are non-zero, the cone will be truncated.
1043 * \note If the radiuses are equal, a cylinder will be created instead.
1044 * \param theH Cone height.
1045 * \return New GEOM_Object, containing the created cone.
1047 GEOM_Object MakeConePntVecR1R2H (in GEOM_Object thePnt,
1048 in GEOM_Object theAxis,
1054 * Create a torus with given radiuses at the origin of coordinate system.
1055 * \param theRMajor Torus major radius.
1056 * \param theRMinor Torus minor radius.
1057 * \return New GEOM_Object, containing the created torus.
1059 GEOM_Object MakeTorusRR (in double theRMajor,
1060 in double theRMinor);
1063 * Create a torus with given center, normal vector and radiuses.
1064 * \param thePnt Torus central point.
1065 * \param theVec Torus axis of symmetry.
1066 * \param theRMajor Torus major radius.
1067 * \param theRMinor Torus minor radius.
1068 * \return New GEOM_Object, containing the created torus.
1070 GEOM_Object MakeTorusPntVecRR (in GEOM_Object thePnt,
1071 in GEOM_Object theVec,
1072 in double theRMajor,
1073 in double theRMinor);
1076 * Create a sphere with given radius at the origin of coordinate system.
1077 * \param theR Sphere radius.
1078 * \return New GEOM_Object, containing the created sphere.
1080 GEOM_Object MakeSphereR (in double theR);
1083 * Create a sphere with given center and radius.
1084 * \param thePnt Sphere center.
1085 * \param theR Sphere radius.
1086 * \return New GEOM_Object, containing the created .
1088 GEOM_Object MakeSpherePntR (in GEOM_Object thePnt, in double theR);
1091 * Create a shape by extrusion of the base shape along the vector,
1092 * i.e. all the space, transfixed by the base shape during its translation
1093 * along the vector on the given distance.
1094 * \param theBase Base shape to be extruded.
1095 * \param theVec Direction of extrusion.
1096 * \param theH Prism dimension along theVec.
1097 * \return New GEOM_Object, containing the created prism.
1099 GEOM_Object MakePrismVecH (in GEOM_Object theBase,
1100 in GEOM_Object theVec,
1102 /* The Same Prism but in 2 directions (forward&backward) */
1103 GEOM_Object MakePrismVecH2Ways (in GEOM_Object theBase,
1104 in GEOM_Object theVec,
1108 * Create a shape by extrusion of the base shape along a vector, defined by two points.
1109 * \param theBase Base shape to be extruded.
1110 * \param thePoint1 First end of extrusion vector.
1111 * \param thePoint2 Second end of extrusion vector.
1112 * \return New GEOM_Object, containing the created prism.
1114 GEOM_Object MakePrismTwoPnt (in GEOM_Object theBase,
1115 in GEOM_Object thePoint1,
1116 in GEOM_Object thePoint2);
1117 /* The same prism but in two directions forward&backward */
1118 GEOM_Object MakePrismTwoPnt2Ways (in GEOM_Object theBase,
1119 in GEOM_Object thePoint1,
1120 in GEOM_Object thePoint2);
1123 * Create a shape by extrusion of the base shape along a vector, defined by DX DY DZ.
1124 * \param theBase Base shape to be extruded.
1125 * \param DX, DY, DZ end of extrusion vector.
1126 * \return New GEOM_Object, containing the created prism.
1128 GEOM_Object MakePrismDXDYDZ (in GEOM_Object theBase,
1129 in double theDX, in double theDY, in double theDZ);
1130 /* The same prism but in two directions forward&backward */
1131 GEOM_Object MakePrismDXDYDZ2Ways (in GEOM_Object theBase,
1132 in double theDX, in double theDY, in double theDZ);
1135 * Create a shape by extrusion of the base shape along
1136 * the path shape. The path shape can be a wire or an edge.
1137 * \param theBase Base shape to be extruded.
1138 * \param thePath Path shape to extrude the base shape along it.
1139 * \return New GEOM_Object, containing the created pipe.
1141 GEOM_Object MakePipe (in GEOM_Object theBase, in GEOM_Object thePath);
1144 * Create a shape by revolution of the base shape around the axis
1145 * on the given angle, i.e. all the space, transfixed by the base
1146 * shape during its rotation around the axis on the given angle.
1147 * \param theBase Base shape to be rotated.
1148 * \param theAxis Rotation axis.
1149 * \param theAngle Rotation angle in radians.
1150 * \return New GEOM_Object, containing the created revolution.
1152 GEOM_Object MakeRevolutionAxisAngle (in GEOM_Object theBase,
1153 in GEOM_Object theAxis,
1154 in double theAngle);
1155 /* The Same Revolution but in both ways forward&backward */
1156 GEOM_Object MakeRevolutionAxisAngle2Ways (in GEOM_Object theBase,
1157 in GEOM_Object theAxis,
1158 in double theAngle);
1161 * Create a filling from the given compound of contours.
1162 * \param theMinDeg a minimal degree of BSpline surface to create
1163 * \param theMaxDeg a maximal degree of BSpline surface to create
1164 * \param theTol2D a 2d tolerance to be reached
1165 * \param theTol3D a 3d tolerance to be reached
1166 * \param theNbIter a number of iteration of approximation algorithm
1167 * \return New GEOM_Object, containing the created filling surface.
1169 GEOM_Object MakeFilling (in GEOM_Object theShape,
1170 in long theMinDeg, in long theMaxDeg,
1171 in double theTol2D, in double theTol3D,
1172 in long theNbIter, in boolean theApprox);
1175 * Create a shell or solid passing through set of sections.Sections should be wires,edges or vertices.
1176 * \param theSeqSections - set of specified sections.
1177 * \param theModeSolid - mode defining building solid or shell
1178 * \param thePreci - precision 3D used for smoothing by default 1.e-6
1179 * \param theRuled - mode defining type of the result surfaces (ruled or smoothed).
1180 * \return New GEOM_Object, containing the created shell or solid.
1182 GEOM_Object MakeThruSections(in ListOfGO theSeqSections,
1183 in boolean theModeSolid,
1185 in boolean theRuled);
1188 * Create a shape by extrusion of the profile shape along
1189 * the path shape. The path shape can be a wire or an edge.
1190 * the several profiles can be specified in the several locations of path.
1191 * \param theSeqBases - list of Bases shape to be extruded.
1192 * \param theLocations - list of locations on the path corresponding
1193 * specified list of the Bases shapes. Number of locations
1194 * should be equal to number of bases or list of locations can be empty.
1195 * \param thePath - Path shape to extrude the base shape along it.
1196 * \param theWithContact - the mode defining that the section is translated to be in
1197 * contact with the spine.
1198 * \param - WithCorrection - defining that the section is rotated to be
1199 * orthogonal to the spine tangent in the correspondent point
1200 * \return New GEOM_Object, containing the created pipe.
1202 GEOM_Object MakePipeWithDifferentSections (in ListOfGO theSeqBases,
1203 in ListOfGO theLocations,
1204 in GEOM_Object thePath,
1205 in boolean theWithContact ,
1206 in boolean theWithCorrection );
1209 * Create a shape by extrusion of the profile shape along
1210 * the path shape. The path shape can be a shell or a face.
1211 * the several profiles can be specified in the several locations of path.
1212 * \param theSeqBases - list of Bases shape to be extruded.
1213 * \param theSeqSubBases - list of corresponding subshapes of section shapes.
1214 * \param theLocations - list of locations on the path corresponding
1215 * specified list of the Bases shapes. Number of locations
1216 * should be equal to number of bases.
1217 * \param thePath - Path shape to extrude the base shape along it.
1218 * \param theWithContact - the mode defining that the section is translated to be in
1219 * contact with the spine.
1220 * \param - WithCorrection - defining that the section is rotated to be
1221 * orthogonal to the spine tangent in the correspondent point
1222 * \return New GEOM_Object, containing the created pipe.
1224 GEOM_Object MakePipeWithShellSections (in ListOfGO theSeqBases,
1225 in ListOfGO theSeqSubBases,
1226 in ListOfGO theLocations,
1227 in GEOM_Object thePath,
1228 in boolean theWithContact ,
1229 in boolean theWithCorrection );
1232 * Create solids between given sections
1233 * \param theSeqBases - list of sections (shell or face).
1234 * \param theLocations - list of corresponding vertexes
1235 * \return New GEOM_Object, containing the created solids.
1237 GEOM_Object MakePipeShellsWithoutPath (in ListOfGO theSeqBases,
1238 in ListOfGO theLocations);
1241 * Create a shape by extrusion of the base shape along
1242 * the path shape with constant bi-normal direction along the given vector.
1243 * The path shape can be a wire or an edge.
1244 * \param theBase Base shape to be extruded.
1245 * \param thePath Path shape to extrude the base shape along it.
1246 * \param theVec Vector defines a constant binormal direction to keep the
1247 * same angle beetween the Direction and the sections
1248 * along the sweep surface.
1249 * \return New GEOM_Object, containing the created pipe.
1251 GEOM_Object MakePipeBiNormalAlongVector (in GEOM_Object theBase,
1252 in GEOM_Object thePath,
1253 in GEOM_Object theVec);
1258 * GEOM_IShapesOperations: Interface for Shapes creation:
1259 * Edge from two points, Wire from edges, Face from wire,
1260 * Shell from faces, Solid from shells, Compound from shapes
1262 interface GEOM_IShapesOperations : GEOM_IOperations
1265 * Create a linear edge with specified ends.
1266 * \param thePnt1 Point for the first end of edge.
1267 * \param thePnt2 Point for the second end of edge.
1268 * \return New GEOM_Object, containing the created edge.
1270 GEOM_Object MakeEdge (in GEOM_Object thePnt1, in GEOM_Object thePnt2);
1273 * Create a wire from the set of edges and wires.
1274 * \param theEdgesAndWires List of edge and/or wires.
1275 * \param theTolerance Maximum distance between vertices, that will be merged.
1276 * Values less than 1e-07 are equivalent to 1e-07 (Precision::Confusion()).
1277 * \return New GEOM_Object, containing the created wire.
1279 GEOM_Object MakeWire (in ListOfGO theEdgesAndWires,
1280 in double theTolerance);
1283 * Create a face on the given wire.
1284 * \param theWire closed Wire or Edge to build the face on.
1285 * \param isPlanarWanted If TRUE, only planar face will be built.
1286 * If impossible, NULL object will be returned.
1287 * \return New GEOM_Object, containing the created face.
1289 GEOM_Object MakeFace (in GEOM_Object theWire, in boolean isPlanarWanted);
1292 * Create a face on the given wires set.
1293 * \param theWires List of closed wires or edges to build the face on.
1294 * \param isPlanarWanted If TRUE, only planar face will be built.
1295 * If impossible, NULL object will be returned.
1296 * \return New GEOM_Object, containing the created face.
1298 GEOM_Object MakeFaceWires (in ListOfGO theWires, in boolean isPlanarWanted);
1301 * Create a shell from the set of faces and shells.
1302 * \param theFacesAndShells List of faces and/or shells.
1303 * \return New GEOM_Object, containing the created shell.
1305 GEOM_Object MakeShell (in ListOfGO theFacesAndShells);
1308 * Create a solid, bounded by the given shell.
1309 * \param theShell Bounding shell.
1310 * \return New GEOM_Object, containing the created solid.
1312 GEOM_Object MakeSolidShell (in GEOM_Object theShell);
1315 * Create a solid, bounded by the given shells.
1316 * \param theShells Bounding shells.
1317 * \return New GEOM_Object, containing the created solid.
1319 GEOM_Object MakeSolidShells (in ListOfGO theShells);
1322 * Create a compound of the given shapes.
1323 * \param theShapes List of shapes to put in compound.
1324 * \return New GEOM_Object, containing the created compound.
1326 GEOM_Object MakeCompound (in ListOfGO theShapes);
1329 * Replace coincident faces in theShape by one face.
1330 * \param theShape Initial shape.
1331 * \param theTolerance Maximum distance between faces, which can be considered as coincident.
1332 * \param doKeepNonSolids If FALSE, only solids will present in the result, otherwise all initial shapes.
1333 * \return New GEOM_Object, containing a copy of theShape without coincident faces.
1335 GEOM_Object MakeGlueFaces (in GEOM_Object theShape, in double theTolerance, in boolean doKeepNonSolids);
1338 * Find coincident faces in theShape for possible gluing.
1339 * \param theShape Initial shape.
1340 * \param theTolerance Maximum distance between faces, which can be considered as coincident.
1343 ListOfGO GetGlueFaces (in GEOM_Object theShape, in double theTolerance);
1346 * Replace coincident faces in theShape by one face
1347 * in compliance with given list of faces
1348 * \param theShape Initial shape.
1349 * \param theTolerance Maximum distance between faces, which can be considered as coincident.
1350 * \param theFaces List of faces for gluing.
1351 * \param doKeepNonSolids If FALSE, only solids will present in the result, otherwise all initial shapes.
1352 * \return New GEOM_Object, containing a copy of theShape without some faces.
1354 GEOM_Object MakeGlueFacesByList (in GEOM_Object theShape, in double theTolerance,
1355 in ListOfGO theFaces, in boolean doKeepNonSolids);
1358 * Explode a shape on subshapes of a given type.
1359 * \param theShape Shape to be exploded.
1360 * \param theShapeType Type of sub-shapes to be retrieved.
1361 * \param isSorted If this parameter is TRUE, sub-shapes will be
1362 * sorted by coordinates of their gravity centers.
1363 * \return List of sub-shapes of type theShapeType, contained in theShape.
1365 ListOfGO MakeExplode (in GEOM_Object theShape,
1366 in long theShapeType,
1367 in boolean isSorted);
1370 * Explode a shape on subshapes of a given type.
1371 * Does the same, as the above method, but returns IDs of sub-shapes,
1372 * not GEOM_Objects. It works faster.
1373 * \param theShape Shape to be exploded.
1374 * \param theShapeType Type of sub-shapes to be retrieved.
1375 * \param isSorted If this parameter is TRUE, sub-shapes will be
1376 * sorted by coordinates of their gravity centers.
1377 * \return List of IDs of sub-shapes of type theShapeType, contained in theShape.
1379 ListOfLong SubShapeAllIDs (in GEOM_Object theShape,
1380 in long theShapeType,
1381 in boolean isSorted);
1384 * Get a sub shape defined by its unique ID inside \a theMainShape
1385 * \note The sub shape GEOM_Objects can has ONLY ONE function.
1386 * Don't try to apply modification operations on them.
1388 GEOM_Object GetSubShape (in GEOM_Object theMainShape,
1392 * Get global index of \a theSubShape in \a theMainShape.
1393 * \param theMainShape Main shape.
1394 * \param theSubShape Sub-shape of the main shape.
1395 * \return global index of \a theSubShape in \a theMainShape.
1397 long GetSubShapeIndex (in GEOM_Object theMainShape, in GEOM_Object theSubShape);
1400 * Get index of \a theSubShape in \a theMainShape, unique among sub-shapes of the same type.
1401 * Together with method <VAR>GetShapeTypeString()</VAR> it can be used
1402 * to generate automatic names for sub-shapes, when publishing them in a study.
1403 * \param theMainShape Main shape.
1404 * \param theSubShape Sub-shape of the main shape.
1405 * \return index of \a theSubShape in a list of all sub-shapes of \a theMainShape of the same type.
1407 long GetTopologyIndex (in GEOM_Object theMainShape, in GEOM_Object theSubShape);
1410 * \brief Get name of type of \a theShape.
1412 * Use wide type notation, taking into consideration both topology and geometry of the shape.
1413 * Together with method <VAR>GetTopologyIndex()</VAR> it can be used
1414 * to generate automatic names for sub-shapes, when publishing them in a study.
1415 * \param theShape The shape to get a type of.
1416 * \return String, containing a type name of \a theShape.
1418 string GetShapeTypeString (in GEOM_Object theShape);
1421 * Count number of faces in the given shape.
1422 * \param theShape Shape to count faces in.
1423 * \return Number of faces in the given shape.
1425 long NumberOfFaces (in GEOM_Object theShape);
1428 * Count number of edges in the given shape.
1429 * \param theShape Shape to count edges in.
1430 * \return Number of edges in theShape.
1432 long NumberOfEdges (in GEOM_Object theShape);
1435 * Count number of subshapes of type \a theShapeType in the given shape.
1436 * \param theShape Shape to count subshapes in.
1437 * \param theShapeType The type of subshapes to count.
1438 * \return Number of subshapes of type \a theShapeType in \a theShape.
1440 long NumberOfSubShapes (in GEOM_Object theShape,
1441 in long theShapeType);
1444 * Reverses an orientation the given shape.
1445 * \param theShape Shape to be reversed.
1446 * \return The reversed copy of theShape.
1448 GEOM_Object ChangeOrientation (in GEOM_Object theShape);
1451 * Retrieve all free faces from the given shape.
1452 * Free face is a face, which is not shared between two shells of the shape.
1453 * \param theShape Shape to find free faces in.
1454 * \return List of IDs of all free faces, contained in theShape.
1456 ListOfLong GetFreeFacesIDs (in GEOM_Object theShape);
1459 * Get all sub-shapes of theShape1 of the given type, shared with theShape2.
1460 * \param theShape1 Shape to find sub-shapes in.
1461 * \param theShape2 Shape to find shared sub-shapes with.
1462 * \param theShapeType Type of sub-shapes to be retrieved.
1463 * \return List of sub-shapes of theShape1, shared with theShape2.
1465 ListOfGO GetSharedShapes (in GEOM_Object theShape1,
1466 in GEOM_Object theShape2,
1467 in long theShapeType);
1470 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1471 * the specified plane by the certain way, defined through \a theState parameter.
1472 * \param theShape Shape to find sub-shapes of.
1473 * \param theShapeType Type of sub-shapes to be retrieved.
1474 * \param theAx1 Vector (or line, or linear edge), specifying normal
1475 * direction and location of the plane to find shapes on.
1476 * \param theState The state of the subshapes to find.
1477 * \return List of all found sub-shapes.
1479 ListOfGO GetShapesOnPlane (in GEOM_Object theShape,
1480 in long theShapeType,
1481 in GEOM_Object theAx1,
1482 in shape_state theState);
1484 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1485 * the specified plane by the certain way, defined through \a theState parameter.
1486 * \param theShape Shape to find sub-shapes of.
1487 * \param theShapeType Type of sub-shapes to be retrieved.
1488 * \param theAx1 Vector (or line, or linear edge), specifying normal
1489 * direction of the plane to find shapes on.
1490 * \param thePnt Point specifying location of the plane to find shapes on.
1491 * \param theState The state of the subshapes to find.
1492 * \return List of all found sub-shapes.
1494 ListOfGO GetShapesOnPlaneWithLocation (in GEOM_Object theShape,
1495 in long theShapeType,
1496 in GEOM_Object theAx1,
1497 in GEOM_Object thePnt,
1498 in shape_state theState);
1503 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1504 * the specified cylinder by the certain way, defined through \a theState parameter.
1505 * \param theShape Shape to find sub-shapes of.
1506 * \param theShapeType Type of sub-shapes to be retrieved.
1507 * \param theAxis Vector (or line, or linear edge), specifying
1508 * axis of the cylinder to find shapes on.
1509 * \param theRadius Radius of the cylinder to find shapes on.
1510 * \param theState The state of the subshapes to find.
1511 * \return List of all found sub-shapes.
1513 ListOfGO GetShapesOnCylinder (in GEOM_Object theShape,
1514 in long theShapeType,
1515 in GEOM_Object theAxis,
1516 in double theRadius,
1517 in shape_state theState);
1520 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1521 * the specified sphere by the certain way, defined through \a theState parameter.
1522 * \param theShape Shape to find sub-shapes of.
1523 * \param theShapeType Type of sub-shapes to be retrieved.
1524 * \param theCenter Point, specifying center of the sphere to find shapes on.
1525 * \param theRadius Radius of the sphere to find shapes on.
1526 * \param theState The state of the subshapes to find.
1527 * \return List of all found sub-shapes.
1529 ListOfGO GetShapesOnSphere (in GEOM_Object theShape,
1530 in long theShapeType,
1531 in GEOM_Object theCenter,
1532 in double theRadius,
1533 in shape_state theState);
1536 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1537 * the specified quadrangle by the certain way, defined through \a theState parameter.
1538 * \param theShape Shape to find sub-shapes of.
1539 * \param theShapeType Type of sub-shapes to be retrieved.
1540 * \param theTopLeftPoint Top left quadrangle corner
1541 * \param theTopRigthPoint Top right quadrangle corner
1542 * \param theBottomLeftPoint Bottom left quadrangle corner
1543 * \param theBottomRigthPoint Bottom right quadrangle corner
1544 * \param theState The state of the subshapes to find.
1545 * \return List of all found sub-shapes.
1547 ListOfGO GetShapesOnQuadrangle (in GEOM_Object theShape,
1548 in long theShapeType,
1549 in GEOM_Object theTopLeftPoint,
1550 in GEOM_Object theTopRigthPoint,
1551 in GEOM_Object theBottomLeftPoint,
1552 in GEOM_Object theBottomRigthPoint,
1553 in shape_state theState);
1556 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1557 * the specified plane by the certain way, defined through \a theState parameter.
1558 * \param theShape Shape to find sub-shapes of.
1559 * \param theShapeType Type of sub-shapes to be retrieved.
1560 * \param theAx1 Vector (or line, or linear edge), specifying normal
1561 * direction and location of the plane to find shapes on.
1562 * \param theState The state of the subshapes to find.
1563 * \return List of IDs of all found sub-shapes.
1565 ListOfLong GetShapesOnPlaneIDs (in GEOM_Object theShape,
1566 in long theShapeType,
1567 in GEOM_Object theAx1,
1568 in shape_state theState);
1571 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1572 * the specified plane by the certain way, defined through \a theState parameter.
1573 * \param theShape Shape to find sub-shapes of.
1574 * \param theShapeType Type of sub-shapes to be retrieved.
1575 * \param theAx1 Vector (or line, or linear edge), specifying normal
1576 * direction of the plane to find shapes on.
1577 * \param thePnt Point specifying location of the plane to find shapes on.
1578 * \param theState The state of the subshapes to find.
1579 * \return List of IDs of all found sub-shapes.
1581 ListOfLong GetShapesOnPlaneWithLocationIDs (in GEOM_Object theShape,
1582 in long theShapeType,
1583 in GEOM_Object theAx1,
1584 in GEOM_Object thePnt,
1585 in shape_state theState);
1588 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1589 * the specified cylinder by the certain way, defined through \a theState parameter.
1590 * \param theShape Shape to find sub-shapes of.
1591 * \param theShapeType Type of sub-shapes to be retrieved.
1592 * \param theAxis Vector (or line, or linear edge), specifying
1593 * axis of the cylinder to find shapes on.
1594 * \param theRadius Radius of the cylinder to find shapes on.
1595 * \param theState The state of the subshapes to find.
1596 * \return List of IDs of all found sub-shapes.
1598 ListOfLong GetShapesOnCylinderIDs (in GEOM_Object theShape,
1599 in long theShapeType,
1600 in GEOM_Object theAxis,
1601 in double theRadius,
1602 in shape_state theState);
1605 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1606 * the specified sphere by the certain way, defined through \a theState parameter.
1607 * \param theShape Shape to find sub-shapes of.
1608 * \param theShapeType Type of sub-shapes to be retrieved.
1609 * \param theCenter Point, specifying center of the sphere to find shapes on.
1610 * \param theRadius Radius of the sphere to find shapes on.
1611 * \param theState The state of the subshapes to find.
1612 * \return List of IDs of all found sub-shapes.
1614 ListOfLong GetShapesOnSphereIDs (in GEOM_Object theShape,
1615 in long theShapeType,
1616 in GEOM_Object theCenter,
1617 in double theRadius,
1618 in shape_state theState);
1621 * Find in \a theShape all sub-shapes of type \a theShapeType, situated relatively
1622 * the specified quadrangle by the certain way, defined through \a theState parameter.
1623 * \param theShape Shape to find sub-shapes of.
1624 * \param theShapeType Type of sub-shapes to be retrieved.
1625 * \param theTopLeftPoint Top left quadrangle corner
1626 * \param theTopRigthPoint Top right quadrangle corner
1627 * \param theBottomLeftPoint Bottom left quadrangle corner
1628 * \param theBottomRigthPoint Bottom right quadrangle corner
1629 * \param theState The state of the subshapes to find.
1630 * \return List of IDs of all found sub-shapes.
1632 ListOfLong GetShapesOnQuadrangleIDs (in GEOM_Object theShape,
1633 in long theShapeType,
1634 in GEOM_Object theTopLeftPoint,
1635 in GEOM_Object theTopRigthPoint,
1636 in GEOM_Object theBottomLeftPoint,
1637 in GEOM_Object theBottomRigthPoint,
1638 in shape_state theState);
1641 * \brief Find subshapes complying with given status
1642 * \param theBox - the box to check state of subshapes against
1643 * \param theShape - the shape to explore
1644 * \param theShapeType - type of subshape of theShape
1645 * \param theState - required state
1646 * \return List of IDs of all found sub-shapes.
1648 ListOfLong GetShapesOnBoxIDs (in GEOM_Object theBox,
1649 in GEOM_Object theShape,
1650 in long theShapeType,
1651 in shape_state theState);
1654 * \brief Find subshapes complying with given status
1655 * \param theBox - the box to check state of subshapes against
1656 * \param theShape - the shape to explore
1657 * \param theShapeType - type of subshape of theShape
1658 * \param theState - required state
1659 * \return List of all found sub-shapes.
1661 ListOfGO GetShapesOnBox (in GEOM_Object theBox,
1662 in GEOM_Object theShape,
1663 in long theShapeType,
1664 in shape_state theState);
1667 * \brief Find subshapes complying with given status
1668 * \param theCheckShape - the shape to check state of subshapes against
1669 * \param theShape - the shape to explore
1670 * \param theShapeType - type of subshape of theShape
1671 * \param theState - required state
1672 * \return List of IDs of all found sub-shapes.
1674 ListOfLong GetShapesOnShapeIDs (in GEOM_Object theCheckShape,
1675 in GEOM_Object theShape,
1676 in short theShapeType,
1677 in shape_state theState);
1680 * \brief Find subshapes complying with given status
1681 * \param theCheckShape - the shape to check state of subshapes against
1682 * \param theShape - the shape to explore
1683 * \param theShapeType - type of subshape of theShape
1684 * \param theState - required state
1685 * \return List of all found sub-shapes.
1687 ListOfGO GetShapesOnShape (in GEOM_Object theCheckShape,
1688 in GEOM_Object theShape,
1689 in short theShapeType,
1690 in shape_state theState);
1693 * \brief Find subshapes complying with given status
1694 * \param theCheckShape - the shape to check state of subshapes against
1695 * \param theShape - the shape to explore
1696 * \param theShapeType - type of subshape of theShape
1697 * \param theState - required state
1698 * \return compound includes all found sub-shapes.
1700 GEOM_Object GetShapesOnShapeAsCompound (in GEOM_Object theCheckShape,
1701 in GEOM_Object theShape,
1702 in short theShapeType,
1703 in shape_state theState);
1706 * Get sub-shape(s) of \a theShapeWhere, which are
1707 * coincident with \a theShapeWhat or could be a part of it.
1708 * \param theShapeWhere Shape to find sub-shapes of.
1709 * \param theShapeWhat Shape, specifying what to find.
1710 * \return Group of all found sub-shapes or a single found sub-shape.
1712 GEOM_Object GetInPlace (in GEOM_Object theShapeWhere,
1713 in GEOM_Object theShapeWhat);
1716 * Get sub-shape(s) of \a theShapeWhere, which are
1717 * coincident with \a theShapeWhat or could be a part of it.
1719 * Implementation of this method is based on a saved history of an operation,
1720 * produced \a theShapeWhere. The \a theShapeWhat must be among this operation's
1721 * arguments (an argument shape or a sub-shape of an argument shape).
1722 * The operation could be the Partition or one of boolean operations,
1723 * performed on simple shapes (not on compounds).
1725 * \param theShapeWhere Shape to find sub-shapes of.
1726 * \param theShapeWhat Shape, specifying what to find.
1727 * \return Group of all found sub-shapes or a single found sub-shape.
1729 GEOM_Object GetInPlaceByHistory (in GEOM_Object theShapeWhere,
1730 in GEOM_Object theShapeWhat);
1733 * Get sub-shape of theShapeWhere, which are
1734 * coincident with \a theShapeWhat that can either SOLID, FACE, EDGE or VERTEX.
1735 * \param theShapeWhere Shape to find sub-shapes of.
1736 * \param theShapeWhat Shape, specifying what to find.
1737 * \return found sub-shape.
1739 GEOM_Object GetSame (in GEOM_Object theShapeWhere,
1740 in GEOM_Object theShapeWhat);
1744 * GEOM_IBlocksOperations: Interface for Blocks construction
1745 * Face from points or edges, Block from faces,
1746 * Blocks multi-translation and multi-rotation
1748 interface GEOM_IBlocksOperations : GEOM_IOperations
1751 * Creation of blocks
1755 * Create a quadrangle face from four edges. Order of Edges is not
1756 * important. It is not necessary that edges share the same vertex.
1757 * \param theEdge1,theEdge2,theEdge3,theEdge4 Edges for the face bound.
1758 * \return New GEOM_Object, containing the created face.
1760 GEOM_Object MakeQuad (in GEOM_Object theEdge1,
1761 in GEOM_Object theEdge2,
1762 in GEOM_Object theEdge3,
1763 in GEOM_Object theEdge4);
1766 * Create a quadrangle face on two edges.
1767 * The missing edges will be built by creating the shortest ones.
1768 * \param theEdge1,theEdge2 Two opposite edges for the face.
1769 * \return New GEOM_Object, containing the created face.
1771 GEOM_Object MakeQuad2Edges (in GEOM_Object theEdge1,
1772 in GEOM_Object theEdge2);
1775 * Create a quadrangle face with specified corners.
1776 * The missing edges will be built by creating the shortest ones.
1777 * \param thePnt1,thePnt2,thePnt3,thePnt4 Corner vertices for the face.
1778 * \return New GEOM_Object, containing the created face.
1780 GEOM_Object MakeQuad4Vertices (in GEOM_Object thePnt1,
1781 in GEOM_Object thePnt2,
1782 in GEOM_Object thePnt3,
1783 in GEOM_Object thePnt4);
1786 * Create a hexahedral solid, bounded by the six given faces. Order of
1787 * faces is not important. It is not necessary that Faces share the same edge.
1788 * \param theFace1-theFace6 Faces for the hexahedral solid.
1789 * \return New GEOM_Object, containing the created solid.
1791 GEOM_Object MakeHexa (in GEOM_Object theFace1,
1792 in GEOM_Object theFace2,
1793 in GEOM_Object theFace3,
1794 in GEOM_Object theFace4,
1795 in GEOM_Object theFace5,
1796 in GEOM_Object theFace6);
1799 * Create a hexahedral solid between two given faces.
1800 * The missing faces will be built by creating the smallest ones.
1801 * \param theFace1,theFace2 Two opposite faces for the hexahedral solid.
1802 * \return New GEOM_Object, containing the created solid.
1804 GEOM_Object MakeHexa2Faces (in GEOM_Object theFace1,
1805 in GEOM_Object theFace2);
1808 * Extract elements of blocks and blocks compounds
1812 * Get a vertex, found in the given shape by its coordinates.
1813 * \param theShape Block or a compound of blocks.
1814 * \param theX,theY,theZ Coordinates of the sought vertex.
1815 * \param theEpsilon Maximum allowed distance between the resulting
1816 * vertex and point with the given coordinates.
1817 * \return New GEOM_Object, containing the found vertex.
1819 GEOM_Object GetPoint (in GEOM_Object theShape,
1823 in double theEpsilon);
1826 * Get an edge, found in the given shape by two given vertices.
1827 * \param theShape Block or a compound of blocks.
1828 * \param thePoint1,thePoint2 Points, close to the ends of the desired edge.
1829 * \return New GEOM_Object, containing the found edge.
1831 GEOM_Object GetEdge (in GEOM_Object theShape,
1832 in GEOM_Object thePoint1,
1833 in GEOM_Object thePoint2);
1836 * Find an edge of the given shape, which has minimal distance to the given point.
1837 * \param theShape Block or a compound of blocks.
1838 * \param thePoint Point, close to the desired edge.
1839 * \return New GEOM_Object, containing the found edge.
1841 GEOM_Object GetEdgeNearPoint (in GEOM_Object theShape,
1842 in GEOM_Object thePoint);
1845 * Returns a face, found in the given shape by four given corner vertices.
1846 * \param theShape Block or a compound of blocks.
1847 * \param thePoint1-thePoint4 Points, close to the corners of the desired face.
1848 * \return New GEOM_Object, containing the found face.
1850 GEOM_Object GetFaceByPoints (in GEOM_Object theShape,
1851 in GEOM_Object thePoint1,
1852 in GEOM_Object thePoint2,
1853 in GEOM_Object thePoint3,
1854 in GEOM_Object thePoint4);
1857 * Get a face of block, found in the given shape by two given edges.
1858 * \param theShape Block or a compound of blocks.
1859 * \param theEdge1,theEdge2 Edges, close to the edges of the desired face.
1860 * \return New GEOM_Object, containing the found face.
1862 GEOM_Object GetFaceByEdges (in GEOM_Object theShape,
1863 in GEOM_Object theEdge1,
1864 in GEOM_Object theEdge2);
1867 * Find a face, opposite to the given one in the given block.
1868 * \param theBlock Must be a hexahedral solid.
1869 * \param theFace Face of \a theBlock, opposite to the desired face.
1870 * \return New GEOM_Object, containing the found face.
1872 GEOM_Object GetOppositeFace (in GEOM_Object theBlock,
1873 in GEOM_Object theFace);
1876 * Find a face of the given shape, which has minimal distance to the given point.
1877 * \param theShape Block or a compound of blocks.
1878 * \param thePoint Point, close to the desired face.
1879 * \return New GEOM_Object, containing the found face.
1881 GEOM_Object GetFaceNearPoint (in GEOM_Object theShape,
1882 in GEOM_Object thePoint);
1885 * Find a face of block, whose outside normale has minimal angle with the given vector.
1886 * \param theShape Block or a compound of blocks.
1887 * \param theVector Vector, close to the normale of the desired face.
1888 * \return New GEOM_Object, containing the found face.
1890 GEOM_Object GetFaceByNormale (in GEOM_Object theBlock,
1891 in GEOM_Object theVector);
1894 * Extract blocks from blocks compounds
1898 * Check, if the compound contains only specified blocks.
1899 * \param theCompound The compound to check.
1900 * \param theMinNbFaces If solid has lower number of faces, it is not a block.
1901 * \param theMaxNbFaces If solid has higher number of faces, it is not a block.
1902 * \note If theMaxNbFaces = 0, the maximum number of faces is not restricted.
1903 * \return TRUE, if the given compound contains only blocks.
1904 * \return theNbBlocks Number of specified blocks in theCompound.
1906 boolean IsCompoundOfBlocks (in GEOM_Object theCompound,
1907 in long theMinNbFaces,
1908 in long theMaxNbFaces,
1909 out long theNbBlocks);
1912 * Enumeration of Blocks Compound defects.
1916 /* Each element of the compound should be a Block */
1919 /* An element is a potential block, but has degenerated and/or seam edge(s). */
1922 /* A connection between two Blocks should be an entire face or an entire edge */
1925 /* The compound should be connexe */
1928 /* The glue between two quadrangle faces should be applied */
1933 * Description of Blocks Compound defect: type and incriminated sub-shapes.
1938 ListOfLong incriminated;
1942 * Sequence of all Blocks Compound defects.
1944 typedef sequence<BCError> BCErrors;
1947 * Check, if the compound of blocks is given.
1948 * To be considered as a compound of blocks, the
1949 * given shape must satisfy the following conditions:
1950 * - Each element of the compound should be a Block (6 faces and 12 edges).
1951 * - A connection between two Blocks should be an entire quadrangle face or an entire edge.
1952 * - The compound should be connexe.
1953 * - The glue between two quadrangle faces should be applied.
1954 * \note Single block is also accepted as a valid compound of blocks.
1955 * \param theCompound The compound to check.
1956 * \return TRUE, if the given shape is a compound of blocks.
1957 * \return theErrors Structure, containing discovered errors and incriminated sub-shapes.
1959 boolean CheckCompoundOfBlocks (in GEOM_Object theCompound,
1960 out BCErrors theErrors);
1963 * Convert sequence of Blocks Compound errors, returned by
1964 * <VAR>CheckCompoundOfBlocks()</VAR>, into string.
1965 * \param theCompound The bad compound.
1966 * \param theErrors The sequence of \a theCompound errors.
1967 * \return String, describing all the errors in form, suitable for printing.
1969 string PrintBCErrors (in GEOM_Object theCompound,
1970 in BCErrors theErrors);
1973 * Remove all seam and degenerated edges from \a theShape.
1974 * Unite faces and edges, sharing one surface.
1975 * \param theShape The compound or single solid to remove irregular edges from.
1976 * \param theOptimumNbFaces If more than zero, unite faces only for those solids,
1977 * that have more than theOptimumNbFaces faces. If zero, unite faces always,
1978 * regardsless their quantity in the solid. If negative, do not unite faces at all.
1979 * For blocks repairing recommended value is 6.
1980 * \return Improved shape.
1982 GEOM_Object RemoveExtraEdges (in GEOM_Object theShape,
1983 in long theOptimumNbFaces);
1986 * Check, if the given shape is a blocks compound.
1987 * Fix all detected errors.
1988 * \note Single block can be also fixed by this method.
1989 * \param theCompound The compound to check and improve.
1990 * \return Improved compound.
1992 GEOM_Object CheckAndImprove (in GEOM_Object theCompound);
1995 * Get all the blocks, contained in the given compound.
1996 * \param theCompound The compound to explode.
1997 * \param theMinNbFaces If solid has lower number of faces, it is not a block.
1998 * \param theMaxNbFaces If solid has higher number of faces, it is not a block.
1999 * \note If theMaxNbFaces = 0, the maximum number of faces is not restricted.
2000 * \return List of GEOM_Objects, containing the retrieved blocks.
2002 ListOfGO ExplodeCompoundOfBlocks (in GEOM_Object theCompound,
2003 in long theMinNbFaces,
2004 in long theMaxNbFaces);
2007 * Find block, containing the given point inside its volume or on boundary.
2008 * \param theCompound Compound, to find block in.
2009 * \param thePoint Point, close to the desired block. If the point lays on
2010 * boundary between some blocks, we return block with nearest center.
2011 * \return New GEOM_Object, containing the found block.
2013 GEOM_Object GetBlockNearPoint (in GEOM_Object theCompound,
2014 in GEOM_Object thePoint);
2017 * Find block, containing all the elements, passed as the parts, or maximum quantity of them.
2018 * \param theCompound Compound, to find block in.
2019 * \param theParts List of faces and/or edges and/or vertices to be parts of the found block.
2020 * \return New GEOM_Object, containing the found block.
2022 GEOM_Object GetBlockByParts (in GEOM_Object theCompound,
2023 in ListOfGO theParts);
2026 * Return all blocks, containing all the elements, passed as the parts.
2027 * \param theCompound Compound, to find blocks in.
2028 * \param theParts List of faces and/or edges and/or vertices to be parts of the found blocks.
2029 * \return List of GEOM_Objects, containing the found blocks.
2031 ListOfGO GetBlocksByParts (in GEOM_Object theCompound,
2032 in ListOfGO theParts);
2035 * Operations on blocks with gluing of result
2039 * Multi-transformate block and glue the result.
2040 * Transformation is defined so, as to superpose theDirFace1 with theDirFace2.
2041 * \param theBlock Hexahedral solid to be multi-transformed.
2042 * \param theDirFace1 First direction face global index.
2043 * \param theDirFace2 Second direction face global index.
2044 * \param theNbTimes Quantity of transformations to be done.
2045 * \note Global index of sub-shape can be obtained, using method
2046 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2047 * \return New GEOM_Object, containing the result shape.
2049 GEOM_Object MakeMultiTransformation1D (in GEOM_Object theBlock,
2050 in long theDirFace1,
2051 in long theDirFace2,
2052 in long theNbTimes);
2055 * Multi-transformate block and glue the result.
2056 * \param theBlock Hexahedral solid to be multi-transformed.
2057 * \param theDirFace1U,theDirFace2U Direction faces for the first transformation.
2058 * \param theDirFace1V,theDirFace2V Direction faces for the second transformation.
2059 * \param theNbTimesU,theNbTimesV Quantity of transformations to be done.
2060 * \return New GEOM_Object, containing the result shape.
2062 GEOM_Object MakeMultiTransformation2D (in GEOM_Object theBlock,
2063 in long theDirFace1U,
2064 in long theDirFace2U,
2065 in long theNbTimesU,
2066 in long theDirFace1V,
2067 in long theDirFace2V,
2068 in long theNbTimesV);
2071 * Special operation - propagation
2075 * Build all possible propagation groups.
2076 * Propagation group is a set of all edges, opposite to one (main)
2077 * edge of this group directly or through other opposite edges.
2078 * Notion of Opposite Edge make sence only on quadrangle face.
2079 * \param theShape Shape to build propagation groups on.
2080 * \return List of GEOM_Objects, each of them is a propagation group.
2082 ListOfGO Propagate (in GEOM_Object theShape);
2086 * GEOM_IBooleanOperations: Interface for boolean operations (Cut, Fuse, Common)
2088 interface GEOM_IBooleanOperations : GEOM_IOperations
2091 * Perform one of boolean operations on two given shapes.
2092 * \param theShape1 First argument for boolean operation.
2093 * \param theShape2 Second argument for boolean operation.
2094 * \param theOperation Indicates the operation to be done:
2095 * 1 - Common, 2 - Cut, 3 - Fuse, 4 - Section.
2096 * \return New GEOM_Object, containing the result shape.
2098 GEOM_Object MakeBoolean (in GEOM_Object theShape1,
2099 in GEOM_Object theShape2,
2100 in long theOperation);
2103 * Perform partition operation.
2104 * \param theShapes Shapes to be intersected.
2105 * \param theTools Shapes to intersect theShapes.
2106 * \note Each compound from ListShapes and ListTools will be exploded in order
2107 * to avoid possible intersection between shapes from this compound.
2108 * \param theLimit Type of resulting shapes (corresponding to TopAbs_ShapeEnum).
2109 # \param KeepNonlimitShapes: if this parameter == 0 - only shapes with
2110 # type <= Limit are kept in the result,
2111 # else - shapes with type > Limit are kept
2112 # also (if they exist)
2114 * After implementation new version of PartitionAlgo (October 2006)
2115 * other parameters are ignored by current functionality. They are kept
2116 * in this function only for supporting old versions.
2117 * Ignored parameters:
2118 * \param theKeepInside Shapes, outside which the results will be deleted.
2119 * Each shape from theKeepInside must belong to theShapes also.
2120 * \param theRemoveInside Shapes, inside which the results will be deleted.
2121 * Each shape from theRemoveInside must belong to theShapes also.
2122 * \param theRemoveWebs If TRUE, perform Glue 3D algorithm.
2123 * \param theMaterials Material indices for each shape. Make sence, only if theRemoveWebs is TRUE.
2125 * \return New GEOM_Object, containing the result shapes.
2127 GEOM_Object MakePartition (in ListOfGO theShapes,
2128 in ListOfGO theTools,
2129 in ListOfGO theKeepInside,
2130 in ListOfGO theRemoveInside,
2132 in boolean theRemoveWebs,
2133 in ListOfLong theMaterials,
2134 in short theKeepNonlimitShapes);
2137 * Perform partition operation.
2138 * This method may be usefull if it is needed to make a partition for
2139 * a compound containing nonintersected shapes. Performance will be better
2140 * since intersection between shapes from compound is not performed.
2142 * Description of all parameters as in previous method MakePartition()
2144 * \note Passed compounds (via ListShapes or via ListTools)
2145 * have to consist of nonintersecting shapes.
2147 * \return New GEOM_Object, containing the result shapes.
2149 GEOM_Object MakePartitionNonSelfIntersectedShape (in ListOfGO theShapes,
2150 in ListOfGO theTools,
2151 in ListOfGO theKeepInside,
2152 in ListOfGO theRemoveInside,
2154 in boolean theRemoveWebs,
2155 in ListOfLong theMaterials,
2156 in short theKeepNonlimitShapes);
2159 * Perform partition of the Shape with the Plane
2160 * \param theShape Shape to be intersected.
2161 * \param thePlane Tool shape, to intersect theShape.
2162 * \return New GEOM_Object, containing the result shape.
2164 GEOM_Object MakeHalfPartition (in GEOM_Object theShape,
2165 in GEOM_Object thePlane);
2169 * GEOM_ICurvesOperations: Interface for curves creation.
2170 * Polyline, Circle, Spline (Bezier and Interpolation)
2172 interface GEOM_ICurvesOperations : GEOM_IOperations
2175 * Create a circle with given center, normal vector and radius.
2176 * \param thePnt Circle center.
2177 * \param theVec Vector, normal to the plane of the circle.
2178 * \param theR Circle radius.
2179 * \return New GEOM_Object, containing the created circle.
2181 GEOM_Object MakeCirclePntVecR (in GEOM_Object thePnt,
2182 in GEOM_Object theVec,
2185 * Create a circle, passing through three given points
2186 * \param thePnt1,thePnt2,thePnt3 Points, defining the circle.
2187 * \return New GEOM_Object, containing the created circle.
2189 GEOM_Object MakeCircleThreePnt (in GEOM_Object thePnt1,
2190 in GEOM_Object thePnt2,
2191 in GEOM_Object thePnt3);
2193 * Create a circle with given center, with a radius equals the distance from center to Point1
2194 * and on a plane defined by all of three points.
2195 * \param thePnt1,thePnt2,thePnt3 Points, defining the circle.
2196 * \return New GEOM_Object, containing the created circle.
2198 GEOM_Object MakeCircleCenter2Pnt (in GEOM_Object thePnt1,
2199 in GEOM_Object thePnt2,
2200 in GEOM_Object thePnt3);
2202 * Create an ellipse with given center, normal vector and radiuses.
2203 * \param thePnt Ellipse center.
2204 * \param theVec Vector, normal to the plane of the ellipse.
2205 * \param theRMajor Major ellipse radius.
2206 * \param theRMinor Minor ellipse radius.
2207 * \return New GEOM_Object, containing the created ellipse.
2209 GEOM_Object MakeEllipse (in GEOM_Object thePnt,
2210 in GEOM_Object theVec,
2211 in double theRMajor,
2212 in double theRMinor);
2215 * Create an ellipse with given center, normal vector, main axis vector and radiuses.
2216 * \param thePnt Ellipse center.
2217 * \param theVec Vector, normal to the plane of the ellipse.
2218 * \param theRMajor Major ellipse radius.
2219 * \param theRMinor Minor ellipse radius.
2220 * \param theVecMaj Vector, direction of the ellipse's main axis.
2221 * \return New GEOM_Object, containing the created ellipse.
2223 GEOM_Object MakeEllipseVec (in GEOM_Object thePnt,
2224 in GEOM_Object theVec,
2225 in double theRMajor,
2226 in double theRMinor,
2227 in GEOM_Object theVecMaj);
2230 * Create an arc of circle, passing through three given points.
2231 * \param thePnt1 Start point of the arc.
2232 * \param thePnt2 Middle point of the arc.
2233 * \param thePnt3 End point of the arc.
2234 * \return New GEOM_Object, containing the created arc.
2236 GEOM_Object MakeArc (in GEOM_Object thePnt1,
2237 in GEOM_Object thePnt2,
2238 in GEOM_Object thePnt3);
2241 * Create an arc of circle of center C from one point to another
2242 * \param theCenter Center point of the arc.
2243 * \param thePnt1 Start point of the arc.
2244 * \param thePnt2 End point of the arc.
2245 * \param theSense Orientation of the arc
2246 * \return New GEOM_Object, containing the created arc.
2248 GEOM_Object MakeArcCenter (in GEOM_Object theCenter,
2249 in GEOM_Object thePnt1,
2250 in GEOM_Object thePnt2,
2251 in boolean theSense);
2254 * Create an arc of ellipse of center C and two points P1 P2.
2255 * \param theCenter Center point of the arc.
2256 * \param thePnt1 Major radius is distance from center to Pnt1.
2257 * \param thePnt2 define a plane and Minor radius as a shortest distance from Pnt2 to vector Center->Pnt1.
2258 * \return New GEOM_Object, containing the created arc.
2260 GEOM_Object MakeArcOfEllipse (in GEOM_Object theCenter,
2261 in GEOM_Object thePnt1,
2262 in GEOM_Object thePnt2);
2266 * Create a polyline on the set of points.
2267 * \param thePoints Sequence of points for the polyline.
2268 * \return New GEOM_Object, containing the created polyline.
2270 GEOM_Object MakePolyline (in ListOfGO thePoints);
2273 * Create bezier curve on the set of points.
2274 * \param thePoints Sequence of points for the bezier curve.
2275 * \return New GEOM_Object, containing the created bezier curve.
2277 GEOM_Object MakeSplineBezier (in ListOfGO thePoints);
2280 * Create B-Spline curve on the set of points.
2281 * \param thePoints Sequence of points for the B-Spline curve.
2282 * \param theIsClosed If TRUE, build a closed curve.
2283 * \return New GEOM_Object, containing the created B-Spline curve.
2285 GEOM_Object MakeSplineInterpolation (in ListOfGO thePoints,
2286 in boolean theIsClosed);
2289 * Create a sketcher (wire or face), following the textual description,
2290 * passed through \a theCommand argument. \n
2291 * Edges of the resulting wire or face will be arcs of circles and/or linear segments. \n
2292 * Format of the description string have to be the following:
2294 * "Sketcher[:F x1 y1]:CMD[:CMD[:CMD...]]"
2297 * - x1, y1 are coordinates of the first sketcher point (zero by default),
2299 * - "R angle" : Set the direction by angle
2300 * - "D dx dy" : Set the direction by DX & DY
2303 * - "TT x y" : Create segment by point at X & Y
2304 * - "T dx dy" : Create segment by point with DX & DY
2305 * - "L length" : Create segment by direction & Length
2306 * - "IX x" : Create segment by direction & Intersect. X
2307 * - "IY y" : Create segment by direction & Intersect. Y
2310 * - "C radius length" : Create arc by direction, radius and length(in degree)
2313 * - "WW" : Close Wire (to finish)
2314 * - "WF" : Close Wire and build face (to finish)
2316 * \param theCommand String, defining the sketcher in local
2317 * coordinates of the working plane.
2318 * \param theWorkingPlane Nine double values, defining origin,
2319 * OZ and OX directions of the working plane.
2320 * \return New GEOM_Object, containing the created wire.
2322 GEOM_Object MakeSketcher (in string theCommand, in ListOfDouble theWorkingPlane);
2325 * Create a 3D sketcher, following the numerical description,
2326 * passed through points created by \a theCoordinates argument. \n
2327 * Format of the description string have to be the following:
2329 * "Make3DSketcher[x1, y1, z1, x2, y2, z2, ..., xN, yN, zN]"
2332 GEOM_Object Make3DSketcher (in ListOfDouble theCoordinates);
2335 * Create a sketcher (wire or face), following the textual description,
2336 * passed through \a theCommand argument. \n
2337 * For format of the description string see the previous method.\n
2338 * \param theCommand String, defining the sketcher in local
2339 * coordinates of the working plane.
2340 * \param theWorkingPlane Planar Face or LCS(Marker) of the working plane.
2341 * \return New GEOM_Object, containing the created wire.
2343 GEOM_Object MakeSketcherOnPlane (in string theCommand, in GEOM_Object theWorkingPlane);
2347 * GEOM_ILocalOperations: Interface for fillet and chamfer creation.
2349 interface GEOM_ILocalOperations : GEOM_IOperations
2352 * Perform a fillet on all edges of the given shape.
2353 * \param theShape Shape, to perform fillet on.
2354 * \param theR Fillet radius.
2355 * \return New GEOM_Object, containing the result shape.
2357 GEOM_Object MakeFilletAll (in GEOM_Object theShape,
2361 * Perform a fillet on the specified edges of the given shape
2362 * \param theShape Shape, to perform fillet on.
2363 * \param theR Fillet radius.
2364 * \param theEdges Global indices of edges to perform fillet on.
2365 * \note Global index of sub-shape can be obtained, using method
2366 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2367 * \return New GEOM_Object, containing the result shape.
2369 GEOM_Object MakeFilletEdges (in GEOM_Object theShape,
2371 in ListOfLong theEdges);
2372 GEOM_Object MakeFilletEdgesR1R2 (in GEOM_Object theShape,
2375 in ListOfLong theEdges);
2378 * Perform a fillet on all edges of the specified faces of the given shape.
2379 * \param theShape Shape, to perform fillet on.
2380 * \param theR Fillet radius.
2381 * \param theFaces Global indices of faces to perform fillet on.
2382 * \note Global index of sub-shape can be obtained, using method
2383 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2384 * \return New GEOM_Object, containing the result shape.
2386 GEOM_Object MakeFilletFaces (in GEOM_Object theShape,
2388 in ListOfLong theFaces);
2390 GEOM_Object MakeFilletFacesR1R2 (in GEOM_Object theShape,
2393 in ListOfLong theFaces);
2396 * Perform a fillet on face of the specified vertexes of the given shape.
2397 * \param theShape Shape, to perform fillet on.
2398 * \param theR Fillet radius.
2399 * \param theVertexes Global indices of vertexes to perform fillet on.
2400 * \note Global index of sub-shape can be obtained, using method
2401 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2402 * \return New GEOM_Object, containing the result shape.
2404 GEOM_Object MakeFillet2D (in GEOM_Object theShape,
2406 in ListOfLong theVertexes);
2409 * Perform a fillet on edges of the specified vertexes of the given wire.
2410 * \param theShape Shape, to perform fillet on.
2411 * \param theR Fillet radius.
2412 * \param theVertexes Global indices of vertexes to perform fillet on.
2413 * \note Global index of sub-shape can be obtained, using method
2414 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2415 * \note The list of vertices coudl be empty, in this case fillet fill be done
2416 * at all vertices in given wire
2417 * \return New GEOM_Object, containing the result shape.
2419 GEOM_Object MakeFillet1D (in GEOM_Object theShape,
2421 in ListOfLong theVertexes);
2424 * Perform a symmetric chamfer on all edges of the given shape.
2425 * \param theShape Shape, to perform chamfer on.
2426 * \param theD Chamfer size along each face.
2427 * \return New GEOM_Object, containing the result shape.
2429 GEOM_Object MakeChamferAll (in GEOM_Object theShape,
2433 * Perform a chamfer on edges, common to the specified faces.
2434 * with distance D1 on the Face1
2435 * \param theShape Shape, to perform chamfer on.
2436 * \param theD1 Chamfer size along \a theFace1.
2437 * \param theD2 Chamfer size along \a theFace2.
2438 * \param theFace1,theFace2 Global indices of two faces of \a theShape.
2439 * \note Global index of sub-shape can be obtained, using method
2440 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2441 * \return New GEOM_Object, containing the result shape.
2443 GEOM_Object MakeChamferEdge (in GEOM_Object theShape,
2444 in double theD1, in double theD2,
2445 in long theFace1, in long theFace2);
2447 * The Same but with params theD = Chamfer Lenght
2448 * and theAngle = Chamfer Angle (Angle in radians)
2450 GEOM_Object MakeChamferEdgeAD (in GEOM_Object theShape,
2451 in double theD, in double theAngle,
2452 in long theFace1, in long theFace2);
2455 * Perform a chamfer on all edges of the specified faces.
2456 * with distance D1 on the first specified face (if several for one edge)
2457 * \param theShape Shape, to perform chamfer on.
2458 * \param theD1 Chamfer size along face from \a theFaces. If both faces,
2459 * connected to the edge, are in \a theFaces, \a theD1
2460 * will be get along face, which is nearer to \a theFaces beginning.
2461 * \param theD2 Chamfer size along another of two faces, connected to the edge.
2462 * \param theFaces Sequence of global indices of faces of \a theShape.
2463 * \note Global index of sub-shape can be obtained, using method
2464 * <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2465 * \return New GEOM_Object, containing the result shape.
2467 GEOM_Object MakeChamferFaces (in GEOM_Object theShape,
2468 in double theD1, in double theD2,
2469 in ListOfLong theFaces);
2471 * The Same but with params theD = Chamfer Lenght
2472 * and theAngle = Chamfer Angle (Angle in radians)
2474 GEOM_Object MakeChamferFacesAD (in GEOM_Object theShape,
2475 in double theD, in double theAngle,
2476 in ListOfLong theFaces);
2479 * Perform a chamfer on edges,
2480 * with distance D1 on the first specified face (if several for one edge)
2481 * \param theShape Shape, to perform chamfer on.
2482 * \param theD1 theD2 Chamfer size
2483 * \param theEdges Sequence of edges of \a theShape.
2484 * \return New GEOM_Object, containing the result shape.
2486 GEOM_Object MakeChamferEdges (in GEOM_Object theShape,
2487 in double theD1, in double theD2,
2488 in ListOfLong theEdges);
2490 * The Same but with params theD = Chamfer Lenght
2491 * and theAngle = Chamfer Angle (Angle in radians)
2493 GEOM_Object MakeChamferEdgesAD (in GEOM_Object theShape,
2494 in double theD, in double theAngle,
2495 in ListOfLong theEdges);
2498 * Perform an Archimde operation on the given shape with given parameters.
2499 * The object presenting the resulting face is returned
2500 * \param theShape Shape to be put in water.
2501 * \param theWeight Weight og the shape.
2502 * \param theWaterDensity Density of the water.
2503 * \param theMeshDeflection Deflection od the mesh, using to compute the section.
2504 * \return New GEOM_Object, containing a section of \a theShape
2505 * by a plane, corresponding to water level.
2507 GEOM_Object MakeArchimede (in GEOM_Object theShape,
2508 in double theWeight,
2509 in double theWaterDensity,
2510 in double theMeshDeflection);
2513 * Duplicates <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR>.
2514 * Present here only for compatibility.
2516 long GetSubShapeIndex (in GEOM_Object theShape, in GEOM_Object theSubShape);
2520 * GEOM_IHealingOperations: Interface for shape healing operations.
2521 * Shape Processing, SuppressFaces, etc.
2523 interface GEOM_IHealingOperations : GEOM_IOperations
2526 * Apply a sequence of Shape Healing operators to the given object.
2527 * \param theShapes Shape to be processed.
2528 * \param theOperators List of names of operators ("FixShape", "SplitClosedFaces", etc.).
2529 * \param theParameters List of names of parameters
2530 * ("FixShape.Tolerance3d", "SplitClosedFaces.NbSplitPoints", etc.).
2531 * \param theValues List of values of parameters, in the same order
2532 * as parameters are listed in \a theParameters list.
2533 * \return New GEOM_Object, containing processed shape.
2535 GEOM_Object ProcessShape (in GEOM_Object theShapes,
2536 in string_array theOperators,
2537 in string_array theParameters,
2538 in string_array theValues);
2541 * Get default sequence of operators, their parameters and parameters' values
2542 * of Shape Process operation. In the current implementation the defaults are
2543 * read from the file pointed by CSF_ShHealingDefaults environmental variable.
2544 * \param theOperators Output. Default list of names of operators.
2545 * \param theParameters Output. Default list of names of parameters.
2546 * \param theValues Output. List of default values of parameters, in the same order
2547 * as parameters are listed in \a theParameters list.
2549 void GetShapeProcessParameters (out string_array theOperators,
2550 out string_array theParameters,
2551 out string_array theValues);
2553 * Get parameters and parameters' values for the given Shape Process operation.
2554 * In the current implementation the defaults are
2555 * read from the file pointed by CSF_ShHealingDefaults environmental variable.
2556 * \param theOperator Input. The operator's name.
2557 * \param theParameters Output. Default list of names of parameters.
2558 * \param theValues Output. List of default values of parameters, in the same order
2559 * as parameters are listed in \a theParameters list.
2561 void GetOperatorParameters (in string theOperator,
2562 out string_array theParameters,
2563 out string_array theValues);
2566 * Remove faces from the given object (shape).
2567 * \param theObject Shape to be processed.
2568 * \param theFaces Indices of faces to be removed, if EMPTY then the method
2569 * removes ALL faces of the given object.
2570 * \return New GEOM_Object, containing processed shape.
2572 GEOM_Object SuppressFaces (in GEOM_Object theObject, in short_array theFaces);
2575 * Close an open wire.
2576 * \param theObject Shape to be processed.
2577 * \param theWires Indexes of edge(s) and wire(s) to be closed within <VAR>theObject</VAR>'s shape,
2578 * if -1, then theObject itself is a wire.
2579 * \param isCommonVertex If TRUE : closure by creation of a common vertex,
2580 * If FALS : closure by creation of an edge between ends.
2581 * \return New GEOM_Object, containing processed shape.
2583 GEOM_Object CloseContour (in GEOM_Object theObject, in short_array theWires,
2584 in boolean isCommonVertex);
2587 * Remove internal wires and edges from the given object (face).
2588 * \param theObject Shape to be processed.
2589 * \param theWires Indices of wires to be removed, if EMPTY then the method
2590 * removes ALL internal wires of the given object.
2591 * \return New GEOM_Object, containing processed shape.
2593 GEOM_Object RemoveIntWires (in GEOM_Object theObject, in short_array theWires);
2596 * Remove internal closed contours (holes) from the given object.
2597 * \param theObject Shape to be processed.
2598 * \param theWires Indices of wires to be removed, if EMPTY then the method
2599 * removes ALL internal holes of the given object
2600 * \return New GEOM_Object, containing processed shape.
2602 GEOM_Object FillHoles (in GEOM_Object theObject, in short_array theWires);
2605 * Sewing of the given object.
2606 * \param theObject Shape to be processed.
2607 * \param theTolerance Required tolerance value.
2608 * \return New GEOM_Object, containing processed shape.
2610 GEOM_Object Sew (in GEOM_Object theObject, in double theTolerance);
2613 * Addition of a point to a given edge object.
2614 * \param theObject Shape to be processed.
2615 * \param theEdgeIndex Index of edge to be divided within theObject's shape,
2616 * if -1, then theObject itself is the edge.
2617 * \param theValue Value of parameter on edge or length parameter,
2618 * depending on \a isByParameter.
2619 * \param isByParameter If TRUE : \a theValue is treated as a curve parameter [0..1],
2620 * if FALSE : \a theValue is treated as a length parameter [0..1]
2621 * \return New GEOM_Object, containing processed shape.
2623 GEOM_Object DivideEdge (in GEOM_Object theObject, in short theEdgeIndex,
2624 in double theValue, in boolean isByParameter);
2627 * Get a list of wires (wrapped in GEOM_Object-s),
2628 * that constitute a free boundary of the given shape.
2629 * \param theObject Shape to get free boundary of.
2630 * \param theClosedWires Output. Closed wires on the free boundary of the given shape.
2631 * \param theOpenWires Output. Open wires on the free boundary of the given shape.
2632 * \return FALSE, if an error(s) occured during the method execution.
2634 boolean GetFreeBoundary (in GEOM_Object theObject,
2635 out ListOfGO theClosedWires,
2636 out ListOfGO theOpenWires);
2639 * Change orientation of the given object.
2640 * \param theObject Shape to be processed.
2641 * \return New GEOM_Object, containing processed shape.
2643 GEOM_Object ChangeOrientation (in GEOM_Object theObject);
2644 GEOM_Object ChangeOrientationCopy (in GEOM_Object theObject);
2649 * GEOM_IInsertOperations: Interface for shape insert operations (like copy, import).
2652 interface GEOM_IInsertOperations : GEOM_IOperations
2655 * Create a copy of the given object
2657 GEOM_Object MakeCopy (in GEOM_Object theOriginal);
2660 * Export the given shape into a file with given name.
2661 * \param theObject Shape to be stored in the file.
2662 * \param theFileName Name of the file to store the given shape in.
2663 * \param theFormatName Specify format for the shape storage.
2664 * Available formats can be obtained with <VAR>ImportTranslators()</VAR> method.
2666 void Export (in GEOM_Object theObject, in string theFileName, in string theFormatName);
2669 * Import a shape from the BRep or IGES or STEP file
2670 * (depends on given format) with given name.
2671 * \param theFileName The file, containing the shape.
2672 * \param theFormatName Specify format for the file reading.
2673 * Available formats can be obtained with <VAR>ImportTranslators()</VAR> method.
2674 * If format 'IGES_SCALE' is used instead 'IGES' length unit will be
2675 * set to 'meter' and result model will be scaled.
2676 * \return New GEOM_Object, containing the imported shape.
2678 GEOM_Object Import (in string theFileName, in string theFormatName);
2681 * Get the supported import formats and corresponding patterns for File dialog.
2682 * \param theFormats Output. List of formats, available for import.
2683 * \param thePatterns Output. List of file patterns, corresponding to available formats.
2684 * \return Returns available formats and patterns through the arguments.
2686 void ImportTranslators (out string_array theFormats,
2687 out string_array thePatterns);
2690 * Get the supported export formats and corresponding patterns for File dialog.
2691 * \param theFormats Output. List of formats, available for export.
2692 * \param thePatterns Output. List of file patterns, corresponding to available formats.
2693 * \return Returns available formats and patterns through the arguments.
2695 void ExportTranslators (out string_array theFormats,
2696 out string_array thePatterns);
2699 * Load texture from file
2700 * \param theTextureFile texture file name
2701 * \return unique texture identifier
2703 long LoadTexture(in string theTextureFile);
2706 * Add texture to the study
2707 * \param theWidth texture width in pixels
2708 * \param theHeight texture height in pixels
2709 * \param theTexture texture byte array
2710 * \return unique texture identifier
2712 long AddTexture(in long theWidth, in long theHeight, in SALOMEDS::TMPFile theTexture);
2715 * Get previously loaded texture data
2716 * \param theID texture identifier
2717 * \param theWidth texture width in pixels
2718 * \param theHeight texture height in pixels
2719 * \return texture byte array
2721 SALOMEDS::TMPFile GetTexture(in long theID, out long theWidth, out long theHeight);
2724 * Get list of all avaiable texture IDs
2725 * \return list of all texture IDs avaiable for the current study
2727 ListOfLong GetAllTextures();
2731 * GEOM_IKindOfShape: namespace for shape_kind enumeration.
2733 interface GEOM_IKindOfShape
2743 SPHERE, // full sphere
2744 CYLINDER, // cylinder
2745 BOX, // box with faces, parallel to global coordinate planes
2746 ROTATED_BOX, // other box
2747 TORUS, // full torus
2749 POLYHEDRON, // solid, bounded by polygons
2750 SOLID, // other solid
2752 SPHERE2D, // spherical face (closed)
2753 CYLINDER2D, // cylindrical face with defined height
2754 TORUS2D, // toroidal face (closed)
2755 CONE2D, // conical face with defined height
2756 DISK_CIRCLE, // planar, bounded by circle
2757 DISK_ELLIPSE, // planar, bounded by ellipse
2758 POLYGON, // planar, bounded by segments
2759 PLANE, // infinite planar
2760 PLANAR, // other planar
2763 CIRCLE, // full circle
2764 ARC_CIRCLE, // arc of circle
2765 ELLIPSE, // full ellipse
2766 ARC_ELLIPSE, // arc of ellipse
2767 LINE, // infinite segment
2777 * GEOM_IMeasureOperations: Interface for measurement (distance, whatis) and
2778 * properties calculation (like Centre of Mass, Inertia, etc.).
2781 interface GEOM_IMeasureOperations : GEOM_IOperations
2784 * Get kind of theShape.
2785 * \param theShape Shape to get a kind of.
2786 * \param theIntegers Output. Integer and enumerated shape's parameters
2787 * (kind of surface, closed/unclosed, number of edges, etc.)
2788 * \param theDoubles Output. Double shape's parameters (coordinates, dimensions, etc.)
2789 * \note Concrete meaning of each value, returned via \a theIntegers
2790 * or \a theDoubles list depends on the kind of the shape.
2791 * \return Returns a kind of shape in terms of <VAR>GEOM_IKindOfShape.shape_kind</VAR> enumeration.
2793 //short KindOfShape (in GEOM_Object theShape,
2794 GEOM_IKindOfShape::shape_kind KindOfShape (in GEOM_Object theShape,
2795 out ListOfLong theIntegers,
2796 out ListOfDouble theDoubles);
2799 * Get position (LCS) of theShape.
2800 * \param theShape Shape to calculate position of.
2801 * \param Ox,Oy,Oz Output. Coordinates of shape's location origin.
2802 * Origin of the LCS is situated at the shape's center of mass.
2803 * \param Zx,Zy,Zz Output. Coordinates of shape's location normal(main) direction.
2804 * \param Xx,Xy,Xz Output. Coordinates of shape's location X direction.
2805 * Axes of the LCS are obtained from shape's location or,
2806 * if the shape is a planar face, from position of its plane.
2807 * \return Returns position of the shape through the last nine arguments.
2809 void GetPosition (in GEOM_Object theShape,
2810 out double Ox, out double Oy, out double Oz,
2811 out double Zx, out double Zy, out double Zz,
2812 out double Xx, out double Xy, out double Xz);
2815 * Get summarized length of all wires,
2816 * area of surface and volume of the given shape.
2817 * \param theShape Shape to define properties of.
2818 * \param theLength Output. Summarized length of all wires of the given shape.
2819 * \param theSurfArea Output. Area of surface of the given shape.
2820 * \param theVolume Output. Volume of the given shape.
2821 * \return Returns shape properties through the last three arguments.
2823 void GetBasicProperties (in GEOM_Object theShape,
2824 out double theLength,
2825 out double theSurfArea,
2826 out double theVolume);
2829 * Get a point, situated at the centre of mass of theShape.
2830 * \param theShape Shape to define centre of mass of.
2831 * \return New GEOM_Object, containing the created point.
2833 GEOM_Object GetCentreOfMass (in GEOM_Object theShape);
2836 * Get a vector, representing the normal of theFace.
2837 * If the face is not planar, theOptionalPoint is obligatory.
2838 * \param theFace Shape (face) to define the normal of.
2839 * \param theOptionalPoint Shape (point) to define the normal at.
2840 * Can be NULL in case of planar face.
2841 * \return New GEOM_Object, containing the created normal vector.
2843 GEOM_Object GetNormal (in GEOM_Object theFace,
2844 in GEOM_Object theOptionalPoint);
2847 * Get inertia matrix and moments of inertia of theShape.
2848 * \param theShape Shape to calculate inertia of.
2849 * \param I(1-3)(1-3) Output. Components of the inertia matrix of the given shape.
2850 * \param Ix,Iy,Iz Output. Moments of inertia of the given shape.
2851 * \return Returns inertia through the last twelve arguments.
2853 void GetInertia (in GEOM_Object theShape,
2854 out double I11, out double I12, out double I13,
2855 out double I21, out double I22, out double I23,
2856 out double I31, out double I32, out double I33,
2857 out double Ix , out double Iy , out double Iz);
2860 * Get parameters of bounding box of the given shape
2861 * \param theShape Shape to obtain bounding box of.
2862 * \param Xmin,Xmax Output. Limits of shape along OX axis.
2863 * \param Ymin,Ymax Output. Limits of shape along OY axis.
2864 * \param Zmin,Zmax Output. Limits of shape along OZ axis.
2865 * \return Returns parameters of bounding box through the last six arguments.
2867 void GetBoundingBox (in GEOM_Object theShape,
2868 out double Xmin, out double Xmax,
2869 out double Ymin, out double Ymax,
2870 out double Zmin, out double Zmax);
2873 * Get min and max tolerances of sub-shapes of theShape
2874 * \param theShape Shape, to get tolerances of.
2875 * \param FaceMin,FaceMax Output. Min and max tolerances of the faces.
2876 * \param EdgeMin,EdgeMax Output. Min and max tolerances of the edges.
2877 * \param VertMin,VertMax Output. Min and max tolerances of the vertices.
2878 * \return Returns shape tolerances through the last six arguments.
2880 void GetTolerance (in GEOM_Object theShape,
2881 out double FaceMin, out double FaceMax,
2882 out double EdgeMin, out double EdgeMax,
2883 out double VertMin, out double VertMax);
2886 * Check a topology of the given shape.
2887 * \param theShape Shape to check validity of.
2888 * \param theDescription Output. Description of problems in the shape, if they are.
2889 * \return TRUE, if the shape "seems to be valid" from the topological point of view.
2891 boolean CheckShape (in GEOM_Object theShape,
2892 out string theDescription);
2895 * Check a topology and a geometry of the given shape.
2896 * \param theShape Shape to check validity of.
2897 * \param theDescription Output. Description of problems in the shape, if they are.
2898 * \return TRUE, if the shape "seems to be valid".
2900 boolean CheckShapeWithGeometry (in GEOM_Object theShape,
2901 out string theDescription);
2904 * Obtain description of the given shape
2905 * \param theShape Shape to be described.
2906 * \return Description of the given shape.
2908 string WhatIs (in GEOM_Object theShape);
2911 * Get minimal distance between the given shapes.
2912 * \param theShape1,theShape2 Shapes to find minimal distance between.
2913 * \param X1,Y1,Z1 Output. Coordinates of point on theShape1, nearest to theShape2.
2914 * \param X2,Y2,Z2 Output. Coordinates of point on theShape2, nearest to theShape1.
2915 * \return Value of the minimal distance between the given shapes.
2917 double GetMinDistance (in GEOM_Object theShape1, in GEOM_Object theShape2,
2918 out double X1, out double Y1, out double Z1,
2919 out double X2, out double Y2, out double Z2);
2922 * Get angle between the given lines or linear edges.
2923 * \param theShape1,theShape2 Shapes to find angle between. Lines or linear edges.
2924 * \return Value of the angle between the given shapes.
2926 double GetAngle (in GEOM_Object theShape1, in GEOM_Object theShape2);
2929 * Get point coordinates
2931 void PointCoordinates (in GEOM_Object theShape, out double X, out double Y, out double Z);
2934 * Get radius of curvature of curve in the point determinated by param
2935 * \param theShape - curve.
2936 * \param theParam - parameter on curve
2937 * \return Value of curvature.
2939 double CurveCurvatureByParam (in GEOM_Object theShape, in double theParam);
2942 * Get radius of curvature of curve in the given point
2943 * \param theShape - curve.
2944 * \param thePoint - point
2945 * \return Value of curvature.
2947 double CurveCurvatureByPoint (in GEOM_Object theShape, in GEOM_Object thePoint);
2950 * Get max radius of curvature of surface in the point determinated by params
2951 * \param theShape - surface.
2952 * \param theUParam - U-parameter on surface
2953 * \param theVParam - V-parameter on surface
2954 * \return Value of curvature.
2956 double MaxSurfaceCurvatureByParam (in GEOM_Object theShape, in double theUParam,
2957 in double theVParam);
2960 * Get max radius of curvature of surface in the given point
2961 * \param theShape - surface.
2962 * \param thePoint - point
2963 * \return Value of curvature.
2965 double MaxSurfaceCurvatureByPoint (in GEOM_Object theShape, in GEOM_Object thePoint);
2968 * Get min radius of curvature of surface in the point determinated by params
2969 * \param theShape - surface.
2970 * \param theUParam - U-parameter on surface
2971 * \param theVParam - V-parameter on surface
2972 * \return Value of curvature.
2974 double MinSurfaceCurvatureByParam (in GEOM_Object theShape, in double theUParam,
2975 in double theVParam);
2978 * Get min radius of curvature of surface in the given point
2979 * \param theShape - surface.
2980 * \param thePoint - point
2981 * \return Value of curvature.
2983 double MinSurfaceCurvatureByPoint (in GEOM_Object theShape, in GEOM_Object thePoint);
2989 * GEOM_IGroupOperations: Interface for groups creation.
2991 interface GEOM_IGroupOperations : GEOM_IOperations
2994 * Creates a new group which will store sub shapes of theMainShape
2995 * \param theMainShape is a GEOM object on which the group is selected
2996 * \param theShapeType defines a shape type of the group
2997 * \return a newly created GEOM group
2999 GEOM_Object CreateGroup (in GEOM_Object theMainShape, in long theShapeType);
3002 * Adds a sub object with ID theSubShapeId to the group
3003 * \param theGroup is a GEOM group to which the new sub shape is added
3004 * \param theSubShapeId is a sub shape ID in the main object.
3005 * \note Use method <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR> to get an ID by the sub shape
3007 void AddObject (in GEOM_Object theGroup, in long theSubShapeId);
3010 * Removes a sub object with ID \a theSubShapeId from the group
3011 * \param theGroup is a GEOM group from which the sub shape is removed.
3012 * \param theSubShapeId is a sub shape ID in the main object.
3013 * \note Use method <VAR>GEOM_IShapesOperations.GetSubShapeIndex()</VAR> to get an ID by the sub shape
3015 void RemoveObject (in GEOM_Object theGroup, in long theSubShapeId);
3018 * Adds to the group all the given shapes. No errors, if some shapes are alredy included.
3019 * \param theGroup is a GEOM group to which the new sub shapes are added.
3020 * \param theSubShapes is a list of sub shapes to be added.
3022 void UnionList (in GEOM_Object theGroup, in ListOfGO theSubShapes);
3025 * Removes from the group all the given shapes. No errors, if some shapes are not included.
3026 * \param theGroup is a GEOM group from which the sub-shapes are removed.
3027 * \param theSubShapes is a list of sub-shapes to be removed.
3029 void DifferenceList (in GEOM_Object theGroup, in ListOfGO theSubShapes);
3032 * Adds to the group all the given shapes. No errors, if some shapes are alredy included.
3033 * \param theGroup is a GEOM group to which the new sub shapes are added.
3034 * \param theSubShapes is a list of IDs of sub shapes to be added.
3036 void UnionIDs (in GEOM_Object theGroup, in ListOfLong theSubShapes);
3039 * Removes from the group all the given shapes. No errors, if some shapes are not included.
3040 * \param theGroup is a GEOM group from which the sub-shapes are removed.
3041 * \param theSubShapes is a list of IDs of sub-shapes to be removed.
3043 void DifferenceIDs (in GEOM_Object theGroup, in ListOfLong theSubShapes);
3046 * Returns a type of sub objects stored in the group
3047 * \param theGroup is a GEOM group which type is returned.
3049 long GetType (in GEOM_Object theGroup);
3052 * Returns a main shape associated with the group
3053 * \param theGroup is a GEOM group for which a main shape object is requested
3054 * \return a GEOM object which is a main shape for theGroup
3056 GEOM_Object GetMainShape (in GEOM_Object theGroup);
3059 * Returns a list of sub objects ID stored in the group
3060 * \param theGroup is a GEOM group for which a list of IDs is requested
3062 ListOfLong GetObjects (in GEOM_Object theGroup);
3067 * GEOM_Gen: Interface to access other GEOM interfaces.
3068 * Also contains some methods to access and manage GEOM objects.
3070 interface GEOM_Gen : Engines::Component,SALOMEDS::Driver
3073 * Undo/Redo Management
3076 void Undo (in long theStudyID);
3078 void Redo (in long theStudyID);
3081 * Publishing management
3082 * Adds in theStudy a object theObject under with a name theName,
3083 * if theFather is not NULL the object is placed under thFather's SObject.
3084 * Returns a SObject where theObject is placed
3086 SALOMEDS::SObject AddInStudy (in SALOMEDS::Study theStudy,
3087 in GEOM_Object theObject,
3089 in GEOM_Object theFather);
3092 * Publish sub-shapes, standing for arguments and sub-shapes of arguments
3093 * To be used from python scripts out of geompy.addToStudy (non-default usage)
3094 * \param theStudy the study, in which theObject is published already,
3095 * and in which the arguments will be published
3096 * \param theObject published GEOM object, arguments of which will be published
3097 * \param theArgs list of GEOM_Object, operation arguments to be published.
3098 * If this list is empty, all operation arguments will be published
3099 * \param theFindMethod method to search subshapes, corresponding to arguments and
3100 * their subshapes. Value from enumeration GEOM::find_shape_method.
3101 * \param theInheritFirstArg set properties of the first argument for \a theObject.
3102 * Do not publish subshapes in place of arguments, but only
3103 * in place of subshapes of the first argument,
3104 * because the whole shape corresponds to the first argument.
3105 * Mainly to be used after transformations, but it also can be
3106 * usefull after partition with one object shape, and some other
3107 * operations, where only the first argument has to be considered.
3108 * If theObject has only one argument shape, this flag is automatically
3109 * considered as True, not regarding really passed value.
3110 * \return list of published sub-shapes
3112 ListOfGO RestoreSubShapesO (in SALOMEDS::Study theStudy,
3113 in GEOM_Object theObject,
3114 in ListOfGO theArgs,
3115 in find_shape_method theFindMethod,
3116 in boolean theInheritFirstArg);
3119 * Publish sub-shapes, standing for arguments and sub-shapes of arguments
3120 * To be used from GUI and from geompy.addToStudy.
3121 * Work like the above method, but accepts study object theSObject instead of GEOM_Object.
3122 * \param theSObject study object, referencing GEOM object, arguments of which will be published
3124 ListOfGO RestoreSubShapesSO (in SALOMEDS::Study theStudy,
3125 in SALOMEDS::SObject theSObject,
3126 in ListOfGO theArgs,
3127 in find_shape_method theFindMethod,
3128 in boolean theInheritFirstArg);
3131 * Methods to access interfaces for objects creation and transformation
3133 GEOM_IBasicOperations GetIBasicOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3134 GEOM_ITransformOperations GetITransformOperations(in long theStudyID) raises (SALOME::SALOME_Exception);
3135 GEOM_I3DPrimOperations GetI3DPrimOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3136 GEOM_IShapesOperations GetIShapesOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3137 GEOM_IBooleanOperations GetIBooleanOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3138 GEOM_ICurvesOperations GetICurvesOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3139 GEOM_ILocalOperations GetILocalOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3140 GEOM_IHealingOperations GetIHealingOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3141 GEOM_IInsertOperations GetIInsertOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3142 GEOM_IMeasureOperations GetIMeasureOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3143 GEOM_IBlocksOperations GetIBlocksOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3144 GEOM_IGroupOperations GetIGroupOperations (in long theStudyID) raises (SALOME::SALOME_Exception);
3147 * Objects Management
3151 * Removes the object from the GEOM component
3152 * \param theObject is a GEOM object to be removed
3154 void RemoveObject (in GEOM_Object theObject);
3157 * Returns an object defined by the study and its entry in the GEOM component
3158 * \param theStudyID is a SALOMEDS Study ID
3159 * \param theEntry is an entry of the requested GEOM object in the GEOM component
3160 * \note if the object has not previously been created a NULL GEOM object is returned
3162 GEOM_Object GetObject (in long theStudyID, in string theEntry);
3165 * Add a sub shape defined by indices in \a theIndices
3166 * (contains unique IDs of sub shapes inside theMainShape)
3167 * \note The sub shape GEOM_Objects can has ONLY ONE function.
3168 * Don't try to apply modification operations on them.
3169 * \note Internal method
3171 GEOM_Object AddSubShape (in GEOM_Object theMainShape, in ListOfLong theIndices);
3174 * GEOM object's IOR Management
3178 * Returns a GEOM Object defined by its IOR
3179 * \param theIOR a string containg an IOR of the requested GEOM object
3181 GEOM_Object GetIORFromString (in string theIOR);
3184 * Returns a string which contains an IOR of the GEOM object
3185 * \param theObject is a GEOM object which IOR is requested
3187 string GetStringFromIOR (in GEOM_Object theObject);
3190 * Returns a name with which a GEOM object was dumped into python script
3191 * \param theStudyEntry is an entry of the GEOM object in the study
3193 string GetDumpName (in string theStudyEntry);
3196 * Returns all names with which a GEOM objects was dumped
3197 * into python script to avoid the same names in SMESH script
3199 string_array GetAllDumpNames();
3202 * Publishes the named subshapes of given object in the study.
3203 * \param theStudy The study in which the object is published
3204 * \param theObject The object which named subshapes are published
3206 ListOfGO PublishNamedShapesInStudy(in SALOMEDS::Study theStudy,
3207 //in SObject theSObject,
3208 in Object theObject);