1 -- Created on: 1991-06-12
2 -- Created by: NW,JPB,CAL
3 -- Copyright (c) 1991-1999 Matra Datavision
4 -- Copyright (c) 1999-2014 OPEN CASCADE SAS
6 -- This file is part of Open CASCADE Technology software library.
8 -- This library is free software; you can redistribute it and/or modify it under
9 -- the terms of the GNU Lesser General Public License version 2.1 as published
10 -- by the Free Software Foundation, with special exception defined in the file
11 -- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 -- distribution for complete text of the license and disclaimer of any warranty.
14 -- Alternatively, this file may be used under the terms of Open CASCADE
15 -- commercial license or contractual agreement.
17 -- 11/97 ; CAL : gestion du GraphicClear
18 -- 11/97 ; CAL : ajout pointer StructPtr
19 -- 11/97 ; CAL : amelioration de l'effacement SetManager
20 -- 01/98 ; CAL : gestion du HLRValidation
21 -- 05/98 ; CAL : gestion du GraphicConnect et Disconnect
22 -- 02/00 ; GG : Made Transform() methode not mutable.
23 -- 31/05/01 ; GG : Add ResetDisplayPriority() method
25 class Structure from Graphic3d inherits TShared
29 ---Purpose: This class allows the definition a graphic object.
30 -- This graphic structure can be displayed,
31 -- erased, or highlighted.
32 -- This graphic structure can be connected with
33 -- another graphic structure.
34 -- Keywords: Structure, StructureManager, Display, Erase, Highlight,
35 -- UnHighlight, Visible, Priority, Selectable, Visible,
36 -- Visual, Connection, Ancestors, Descendants, Transformation
43 Array2OfReal from TColStd,
44 SequenceOfAddress from TColStd,
49 TypeOfHighlightMethod from Aspect,
51 DataStructureManager from Graphic3d,
52 AspectFillArea3d from Graphic3d,
53 AspectLine3d from Graphic3d,
54 AspectMarker3d from Graphic3d,
55 AspectText3d from Graphic3d,
56 CStructure from Graphic3d,
57 GraphicDriver from Graphic3d,
59 SequenceOfGroup from Graphic3d,
60 HSequenceOfGroup from Graphic3d,
61 SequenceOfStructure from Graphic3d,
62 HSequenceOfStructure from Graphic3d,
63 MapOfStructure from Graphic3d,
64 Plotter from Graphic3d,
65 StructureManager from Graphic3d,
66 TypeOfComposition from Graphic3d,
67 TypeOfConnection from Graphic3d,
68 TypeOfPrimitive from Graphic3d,
69 TypeOfStructure from Graphic3d,
70 Vector from Graphic3d,
71 Vertex from Graphic3d,
72 TransModeFlags from Graphic3d,
74 SequenceOfHClipPlane from Graphic3d
78 PriorityDefinitionError from Graphic3d,
79 StructureDefinitionError from Graphic3d,
80 TransformError from Graphic3d
84 ------------------------
85 -- Category: Constructor
86 ------------------------
88 Create ( AManager : StructureManager from Graphic3d )
89 returns mutable Structure from Graphic3d;
91 ---Purpose: Creates a graphic object in the manager <AManager>.
92 -- It will appear in all the views of the visualiser.
93 -- Warning: The default values AspectLine, AspectFillArea,
94 -- AspectText and AspectMarker are NOT applied to the
96 -- The structure is not displayed when it is created.
98 ---------------------------------------------------
99 -- Category: Methods to modify the class definition
100 ---------------------------------------------------
102 --------------------------------------------------------
103 -- Summary of Display Priorities --
105 -- Structure display priorities control the order in --
106 -- which structures are redrawn. --
108 -- When you display a structure, you specify its --
109 -- priority. The lower the value, the lower the --
110 -- display priority. When the display is regenerated, --
111 -- the structures with the lowest priority are drawn --
113 -- For structures with the same display priority, --
114 -- the order in which they were displayed determines --
115 -- determines the drawing order. --
117 -- CAS.CADE supports 11 structure display priorities, --
119 --------------------------------------------------------
121 Clear ( me : mutable;
122 WithDestruction : Boolean from Standard = Standard_True )
125 ---Purpose: if WithDestruction == Standard_True then
126 -- suppress all the groups of primitives in the structure.
127 -- and it is mandatory to create a new group in <me>.
128 -- if WithDestruction == Standard_False then
129 -- clears all the groups of primitives in the structure.
130 -- and all the groups are conserved and empty.
131 -- They will be erased at the next screen update.
132 -- The structure itself is conserved.
133 -- The transformation and the attributes of <me> are conserved.
134 -- The childs of <me> are conserved.
135 ---Category: Methods to modify the class definition
137 Destroy ( me : mutable )
140 ---Purpose: Suppresses the structure <me>.
141 -- It will be erased at the next screen update.
142 ---Category: Methods to modify the class definition
145 Display ( me : mutable )
148 ---Purpose: Displays the structure <me> in all the views of
150 ---Category: Methods to modify the class definition
152 Display ( me : mutable;
153 Priority : Integer from Standard )
155 ---Purpose: Displays the structure <me> in all the views of
156 -- the visualiser, while modifying its current priority.
157 -- Note: Display Priorities
158 -- Structure display priorities control the order in which
159 -- structures are redrawn. When you display a
160 -- structure, you specify its priority. The lower the value,
161 -- the lower the display priority. When the display is
162 -- regenerated, the structures with the lowest priority
163 -- are drawn first. For structures with the same display
164 -- priority, the order in which they were displayed
165 -- determines the drawing order. Open CASCADE
166 -- supports 11 structure display priorities, 0 to 10.
167 -- Warning: Raises PriorityDefinitionError if <Priority> is
168 -- greater than 10 or a negative value.
169 raises PriorityDefinitionError from Graphic3d is static;
171 DisplayPriority ( me )
172 returns Integer from Standard
175 ---Purpose: Returns the current display priority for the
177 ---Category: Methods to modify the class definition
179 Erase ( me : mutable )
182 ---Purpose: Erases the structure <me> in all the views
183 -- of the visualiser.
184 ---Category: Methods to modify the class definition
186 Highlight ( me : mutable;
187 Method : TypeOfHighlightMethod from Aspect )
190 ---Purpose: Highlights the structure <me> in all the
191 -- views of the visualiser, using the following methods:
193 -- TOHM_COLOR = drawn in the highlight color
195 -- TOHM_BLINK = blinking
196 -- TOHM_BOUNDBOX = enclosed by the boundary box
199 ---Category: Methods to modify the class definition
201 Remove ( me : mutable )
204 ---Purpose: Suppress the structure <me>.
205 -- It will be erased at the next screen update.
206 -- Warning: No more graphic operations in <me> after this call.
207 -- Category: Methods to modify the class definition
209 SetHighlightColor ( me : mutable;
210 AColor : Color from Quantity )
213 ---Purpose: Modifies the highlight color for the Highlight method
214 -- with the highlight method TOHM_COLOR or TOHM_BOUNDBOX.
215 ---Category: Methods to modify the class definition
217 SetInfiniteState (me : mutable; theToSet : Boolean from Standard) is static;
219 ---Purpose: If <theToSet> is Standard_True then <me> is infinite and
220 -- the MinMaxValues method method return :
221 -- theXMin = theYMin = theZMin = RealFirst().
222 -- theXMax = theYMax = theZMax = RealLast().
223 -- By default, <me> is not infinite but empty.
224 ---Category: Methods to modify the class definition
226 SetDisplayPriority ( me : mutable;
227 Priority : Integer from Standard )
229 ---Purpose: Modifies the order of displaying the structure.
230 -- Values are between 0 and 10.
231 -- Structures are drawn according to their display priorities
232 -- in ascending order.
233 -- A structure of priority 10 is displayed the last and appears over the others.
234 -- The default value is 5.
235 -- Category: Methods to modify the class definition
236 -- Warning: If <me> is displayed then the SetDisplayPriority
237 -- method erase <me> and display <me> with the
239 -- Raises PriorityDefinitionError if <Priority> is
240 -- greater than 10 or a negative value.
241 raises PriorityDefinitionError from Graphic3d is static;
243 ResetDisplayPriority ( me : mutable)
246 ---Purpose: Reset the current priority of the structure to the
247 -- previous priority.
248 -- Category: Methods to modify the class definition
249 -- Warning: If <me> is displayed then the SetDisplayPriority
250 -- method erase <me> and display <me> with the
251 -- previous priority.
253 SetZLayer ( me : mutable;
254 theLayerId : Integer from Standard )
256 ---Purpose: Set Z layer ID for the structure. The Z layer mechanism
257 -- allows to display structures presented in higher layers in overlay
258 -- of structures in lower layers by switching off z buffer depth
259 -- test between layers
262 returns Integer from Standard is static;
263 ---Purpose: Get Z layer ID of displayed structure. The method
264 -- returns -1 if the structure has no ID (deleted from graphic driver).
266 SetClipPlanes (me : mutable; thePlanes : SequenceOfHClipPlane from Graphic3d) is static;
267 ---Purpose: Changes a sequence of clip planes slicing the structure on rendering.
268 -- @param thePlanes [in] the set of clip planes.
270 GetClipPlanes (me) returns SequenceOfHClipPlane from Graphic3d;
271 ---C++: return const&
272 ---Purpose: Get clip planes slicing the structure on rendering.
273 -- @return set of clip planes.
275 SetPick ( me : mutable;
276 AValue : Boolean from Standard )
279 ---Purpose: Modifies the detectability indicator to Standard_True
280 -- or Standard_False for the structure <me>.
281 -- The default value at the definition of <me> is
283 ---Category: Methods to modify the class definition
285 SetPrimitivesAspect ( me : mutable;
286 CTX : AspectLine3d from Graphic3d )
289 ---Purpose: Modifies the default attributes for lines
290 -- in the structure <me>.
291 ---Category: Methods to modify the class definition
293 SetPrimitivesAspect ( me : mutable;
294 CTX : AspectFillArea3d from Graphic3d )
297 ---Purpose: Modifies the default attributes for faces
298 -- in the structure <me>.
299 ---Category: Methods to modify the class definition
301 SetPrimitivesAspect ( me : mutable;
302 CTX : AspectText3d from Graphic3d )
305 ---Purpose: Modifies the default attributes for text
306 -- in the structure <me>.
307 ---Category: Methods to modify the class definition
309 SetPrimitivesAspect ( me : mutable;
310 CTX : AspectMarker3d from Graphic3d )
313 ---Purpose: Modifies the default attributes for markers
314 -- in the structure <me>.
315 ---Category: Methods to modify the class definition
317 SetVisible ( me : mutable;
318 AValue : Boolean from Standard )
321 ---Purpose: Modifies the visibility indicator to Standard_True or
322 -- Standard_False for the structure <me>.
323 -- The default value at the definition of <me> is
325 ---Category: Methods to modify the class definition
327 SetManager ( me : mutable;
328 AManager : StructureManager from Graphic3d;
329 WithPropagation : Boolean from Standard = Standard_False)
332 ---Purpose: Moves the graphic object <me> in the manager <AManager>.
333 -- If <WithPropagation> is Standard_True then all the connected
334 -- graphic objects to <me> are moved.
336 SetVisual ( me : mutable;
337 AVisual : TypeOfStructure from Graphic3d )
340 ---Purpose: Modifies the visualisation mode for the structure <me>.
341 ---Warning: It is not possible to display a structure with
342 -- an incompatible display mode.
343 -- If the display mode is different from the current one,
344 -- the structure is erased.
346 -- TOS_WIREFRAME for a wireframe visualisation
347 -- TOS_SHADING for a shaded visualisation
348 -- TOS_ALL for all visualisations
349 -- TOS_COMPUTED for a computed visualisation
350 -- The default value is TOS_ALL
352 ---Category: Methods to modify the class definition
354 SetZoomLimit ( me : mutable;
355 LimitInf, LimitSup : Real from Standard )
357 ---Purpose: Modifies the minimum and maximum zoom coefficients
358 -- for the structure <me>.
359 -- The default value at the definition of <me> is unlimited.
360 -- Category: Methods to modify the class definition
361 -- Warning: Raises StructureDefinitionError if <LimitInf> is
362 -- greater than <LimitSup> or if <LimitInf> or
363 -- <LimitSup> is a negative value.
364 raises StructureDefinitionError from Graphic3d is static;
366 UnHighlight ( me : mutable )
369 ---Purpose: Suppresses the highlight for the structure <me>
370 -- in all the views of the visualiser.
371 ---Category: Methods to modify the class definition
373 ----------------------------
374 -- Category: Compute methods
375 ----------------------------
377 Compute (me: mutable)
380 ---Category: Methods to modify the class definition
382 Compute ( me : mutable;
383 aProjector : DataStructureManager from Graphic3d )
384 returns Structure from Graphic3d is virtual;
386 ---Purpose: Returns the new Structure defined for the new visualization
387 ---Category: Methods to modify the class definition
389 Compute ( me : mutable;
390 aProjector : DataStructureManager from Graphic3d;
391 AMatrix : Array2OfReal from TColStd )
392 returns Structure from Graphic3d is virtual;
394 ---Purpose: Returns the new Structure defined for the new visualization
395 ---Category: Methods to modify the class definition
397 Compute ( me : mutable;
398 aProjector : DataStructureManager from Graphic3d;
399 aStructure : in out Structure from Graphic3d )
402 ---Purpose: Returns the new Structure defined for the new visualization
403 ---Category: Methods to modify the class definition
405 Compute ( me : mutable;
406 aProjector : DataStructureManager from Graphic3d;
407 AMatrix : Array2OfReal from TColStd;
408 aStructure : in out Structure from Graphic3d )
411 ---Purpose: Returns the new Structure defined for the new visualization
412 ---Category: Methods to modify the class definition
414 ReCompute ( me : mutable );
416 ---Purpose: Forces a new construction of the structure <me>
417 -- if <me> is displayed and TOS_COMPUTED.
418 ---Category: Methods to modify the class definition
420 ReCompute ( me : mutable;
421 aProjector : DataStructureManager from Graphic3d );
423 ---Purpose: Forces a new construction of the structure <me>
424 -- if <me> is displayed in <aProjetor> and TOS_COMPUTED.
425 ---Category: Methods to modify the class definition
427 ----------------------------
428 -- Category: Inquire methods
429 ----------------------------
432 returns Boolean from Standard
435 ---Purpose: Returns Standard_True if the structure <me> contains
436 -- Polygons, Triangles or Quadrangles.
437 ---Category: Inquire methods
440 FillArea3dAspect ( me )
441 returns AspectFillArea3d from Graphic3d
444 ---Purpose: Returns the values of the current default attributes.
445 ---Category: Inquire methods
448 returns SequenceOfGroup from Graphic3d
450 ---C++: return const &
452 ---Purpose: Returns the groups sequence included in the structure <me> (internal storage).
453 ---Category: Inquire methods
455 NumberOfGroups ( me )
456 returns Integer from Standard
459 ---Purpose: Returns the current number of groups in the
461 ---Category: Inquire methods
463 HighlightColor ( me )
464 returns Color from Quantity
467 ---Purpose: Returns the highlight color for the Highlight method
468 -- with the highlight method TOHM_COLOR or TOHM_BOUNDBOX.
469 ---Category: Inquire methods
472 returns Boolean from Standard
475 ---Purpose: Returns Standard_True if the structure <me> is deleted.
476 -- <me> is deleted after the call Remove (me).
477 ---Category: Inquire methods
480 returns Boolean from Standard
483 ---Purpose: Returns the display indicator for the structure <me>.
484 ---Category: Inquire methods
487 returns Boolean from Standard
490 ---Purpose: Returns Standard_True if the structure <me> is empty.
491 -- Warning: A structure is empty if :
492 -- it do not have group or all the groups are empties
493 -- and it do not have descendant or all the descendants
495 ---Category: Inquire methods
498 returns Boolean from Standard
501 ---Purpose: Returns Standard_True if the structure <me> is infinite.
502 ---Category: Inquire methods
505 returns Boolean from Standard
508 ---Purpose: Returns the highlight indicator for the structure <me>.
509 ---Category: Inquire methods
512 returns Boolean from Standard
515 ---Purpose: Returns the detectability indicator for the structure <me>.
516 ---Category: Inquire methods
519 returns Boolean from Standard
522 ---Purpose: Returns Standard_True if the structure <me> is rotated.
523 -- <=> The transformation != Identity, != Scale, != Translation.
524 ---Category: Inquire methods
527 returns Boolean from Standard
530 ---Purpose: Returns Standard_True if the structure <me> is transformed.
531 -- <=> The transformation != Identity.
532 ---Category: Inquire methods
535 returns Boolean from Standard
538 ---Purpose: Returns the visibility indicator for the structure <me>.
539 ---Category: Inquire methods
542 returns AspectLine3d from Graphic3d
545 ---Purpose: Returns the values of the current default attributes.
546 ---Category: Inquire methods
548 Marker3dAspect ( me )
549 returns AspectMarker3d from Graphic3d
551 ---Purpose: Returns the current group of graphic attributes used
552 -- for 3d marker primitives.
555 theXMin, theYMin, theZMin : out Real from Standard;
556 theXMax, theYMax, theZMax : out Real from Standard;
557 theToIgnoreInfiniteFlag : Boolean from Standard = Standard_False)
560 ---Purpose: Returns the coordinates of the boundary box of the structure <me>.
561 -- If <theToIgnoreInfiniteFlag> is TRUE, the method returns actual graphical
562 -- boundaries of the Graphic3d_Group components. Otherwise, the
563 -- method returns boundaries taking into account infinite state
564 -- of the structure. This approach generally used for application
565 -- specific fit operation (e.g. fitting the model into screen,
566 -- not taking into accout infinite helper elements).
567 -- Warning: If the structure <me> is empty or infinite then :
568 -- theXMin = theYMin = theZMin = RealFirst ().
569 -- theXMax = theYMax = theZMax = RealLast ().
570 ---Category: Inquire methods
572 PrimitivesAspect ( me;
573 CTXL : out AspectLine3d from Graphic3d;
574 CTXT : out AspectText3d from Graphic3d;
575 CTXM : out AspectMarker3d from Graphic3d;
576 CTXF : out AspectFillArea3d from Graphic3d )
579 ---Purpose: Returns the current values of the default attributes.
580 ---Category: Inquire methods
583 returns AspectText3d from Graphic3d
586 ---Purpose: Returns the values of the current default attributes.
587 ---Category: Inquire methods
590 returns TypeOfStructure from Graphic3d
593 ---Purpose: Returns the visualisation mode for the structure <me>.
594 ---Category: Inquire methods
596 ----------------------------------------------------
597 -- Category: Methods to manage the structure network
598 ----------------------------------------------------
600 -----------------------------------------------------
601 -- Summary of Structure Hierarchies --
603 -- The root is the top of a structure hierarchy --
604 -- or structure network. --
606 -- The attributes of a parent structure are passed --
607 -- passed to its descendants. --
609 -- The attributes of the descendant structures --
610 -- don't affect the parent. --
612 -- Recursive structure networks are not supported. --
613 -----------------------------------------------------
615 AcceptConnection ( myclass;
616 AStructure1 : Structure from Graphic3d;
617 AStructure2 : Structure from Graphic3d;
618 AType : TypeOfConnection from Graphic3d )
619 returns Boolean from Standard;
621 ---Purpose: Returns Standard_True if the connection is possible between
622 -- <AStructure1> and <AStructure2> without a creation
625 -- It's not possible to call the method
626 -- AStructure1->Connect (AStructure2, TypeOfConnection)
628 -- - the set of all ancestors of <AStructure1> contains
629 -- <AStructure1> and if the
630 -- TypeOfConnection == TOC_DESCENDANT
631 -- - the set of all descendants of <AStructure1> contains
632 -- <AStructure2> and if the
633 -- TypeOfConnection == TOC_ANCESTOR
634 ---Category: Methods to manage the structure network
636 Ancestors ( me; SG: in out MapOfStructure from Graphic3d )
639 ---Purpose: Returns the group of structures to which <me> is connected.
640 ---Category: Methods to manage the structure network
642 Connect ( me : mutable;
643 AStructure : Structure from Graphic3d;
644 AType : TypeOfConnection from Graphic3d;
645 WithCheck : Boolean from Standard = Standard_False );
647 ---Purpose: If Atype is TOC_DESCENDANT then add <AStructure>
648 -- as a child structure of <me>.
649 -- If Atype is TOC_ANCESTOR then add <AStructure>
650 -- as a parent structure of <me>.
651 -- The connection propagates Display, Highlight, Erase,
652 -- Remove, and stacks the transformations.
653 -- No connection if the graph of the structures
654 -- contains a cycle and <WithCheck> is Standard_True;
655 ---Category: Methods to manage the structure network
657 Descendants ( me; SG : in out MapOfStructure from Graphic3d )
660 ---Purpose: Returns the group of structures connected to <me>.
661 ---Category: Methods to manage the structure network
663 Disconnect ( me : mutable;
664 AStructure : Structure from Graphic3d )
667 ---Purpose: Suppress the connection between <AStructure> and <me>.
668 ---Category: Methods to manage the structure network
670 DisconnectAll ( me : mutable;
671 AType : TypeOfConnection from Graphic3d )
674 ---Purpose: If Atype is TOC_DESCENDANT then suppress all
675 -- the connections with the child structures of <me>.
676 -- If Atype is TOC_ANCESTOR then suppress all
677 -- the connections with the parent structures of <me>.
678 ---Category: Methods to manage the structure network
681 AStructure : Structure from Graphic3d;
682 AType : TypeOfConnection from Graphic3d;
683 ASet : in out MapOfStructure from Graphic3d );
685 ---Purpose: Returns <ASet> the group of structures :
686 -- - directly or indirectly connected to <AStructure> if the
687 -- TypeOfConnection == TOC_DESCENDANT
688 -- - to which <AStructure> is directly or indirectly connected
689 -- if the TypeOfConnection == TOC_ANCESTOR
690 ---Category: Methods to manage the structure network
692 SetOwner ( me : mutable;
693 Owner : Address from Standard )
698 returns Address from Standard
702 SetHLRValidation ( me : mutable;
703 AFlag : Boolean from Standard )
708 returns Boolean from Standard
712 -----------------------------------------------------------
713 -- Category: Methods to manage the structure transformation
714 -----------------------------------------------------------
717 returns TypeOfComposition from Graphic3d
720 ---Purpose: Returns the type of composition applied to matrices
721 -- of transformation of <me>.
722 ---Category: Methods to manage the structure transformation
724 SetTransform ( me : mutable;
725 AMatrix : Array2OfReal from TColStd;
726 AType : TypeOfComposition from Graphic3d )
728 ---Purpose: Modifies the current local modelling transformation
729 -- in the structure <me>.
731 -- It is defined as a 4*4 real matrix.
733 -- -------------------
734 -- | a11 a12 a13 t1 |
735 -- | a21 a22 a23 t2 |
736 -- | a31 a32 a33 t3 |
738 -- -------------------
740 -- TypeOfComposition : TOC_REPLACE
741 -- TOC_POSTCONCATENATE
743 -- Then the modified Local Modelling Transformation is composed
744 -- with the current Global Modelling Transformation to create a
745 -- new Composite Modelling Transformation.
747 -- The compose type specifies the role of the current local
748 -- modelling transformation (L) in composing the new value for
749 -- the current local modelling transformation (L'), which is
750 -- then combined with the current global modelling transforma-
751 -- tion (G) to calculate the new composite modelling transfor-
755 -- The transformation matrix (T) replaces the value of
756 -- current local modelling transformation (L).
761 -- TOC_POSTCONCATENATE
762 -- The current local modelling transformation (L) is multiplied
763 -- by the transformation matrix (T):
768 -- Category: Methods to manage the structure transformation
769 -- Warning: Raises TransformError if the matrix is not a 4x4 matrix.
770 raises TransformError from Graphic3d is static;
772 -- Transform ( me : mutable;
774 AMatrix : in out Array2OfReal from TColStd )
777 ---Purpose: Returns the transformation associated with
778 -- the structure <me>.
779 ---Category: Methods to manage the structure transformation
781 SetTransformPersistence( me : mutable;
782 AFlag : TransModeFlags from Graphic3d;
783 APoint : Pnt from gp )
785 ---Purpose: Modifies the current modelling transform persistence (pan, zoom or rotate)
788 SetTransformPersistence( me : mutable;
789 AFlag : TransModeFlags from Graphic3d )
790 -- Calls previous method with point (0,0,0)
794 TransformPersistenceMode( me )
795 returns TransModeFlags from Graphic3d
797 ---Purpose: Get the current modelling transform persistence (pan, zoom or rotate)
800 TransformPersistencePoint( me )
803 ---Purpose: Get the current point of relative modelling transform persistence
806 ----------------------------
807 -- Category: Private methods
808 ----------------------------
811 AGroup : Group from Graphic3d )
814 ---Purpose: Inserts in the structure <me>, the group <G>.
815 -- It will be erased at the next screen update.
816 ---Category: Private methods
819 returns TypeOfStructure from Graphic3d
822 ---Category: Private methods
824 GroupsWithFacet ( me : mutable;
825 ADelta : Integer from Standard )
828 ---Purpose: Manages the number of groups in the structure <me>
829 -- which contains facet.
830 -- Polygons, Triangles or Quadrangles.
831 -- <ADelta> = +1 or -1
832 ---Category: Private methods
834 GraphicClear ( me : mutable;
835 WithDestruction : Boolean from Standard )
838 ---Purpose: Clears the structure <me>.
839 ---Category: Private methods
841 GraphicConnect ( me : mutable;
842 ADaughter : Structure from Graphic3d )
846 ---Category: Private methods
848 GraphicDisconnect ( me : mutable;
849 ADaughter : Structure from Graphic3d )
853 ---Category: Private methods
855 GraphicHighlight ( me : mutable;
856 Method : TypeOfHighlightMethod from Aspect )
859 ---Purpose: Highlights the structure <me>.
860 ---Category: Private methods
862 GraphicTransform ( me : mutable;
863 AMatrix : Array2OfReal from TColStd )
867 ---Category: Private methods
869 GraphicUnHighlight ( me : mutable )
872 ---Purpose: Suppress the highlight for the structure <me>.
873 ---Category: Private methods
875 Identification ( me )
876 returns Integer from Standard
879 ---Purpose: Returns the identification number of the structure <me>.
880 ---Category: Private methods
883 theXMin, theYMin, theZMin : out Real from Standard;
884 theXMax, theYMax, theZMax : out Real from Standard)
887 ---Purpose: Returns the extreme coordinates found in the structure <me>.
888 -- Warning: If the structure <me> is empty or infinite then :
889 -- theXMin = theYMin = theZMin = RealFirst().
890 -- theXMax = theYMax = theZMax = RealLast().
891 ---Category: Private methods
893 MinMaxCoordWithDescendants (me;
894 theXMin, theYMin, theZMin : out Real from Standard;
895 theXMax, theYMax, theZMax : out Real from Standard)
898 ---Purpose: Returns the extreme coordinates found in the structure <me>
899 -- and its descendants with transformation applied.
900 -- Warning: If the structure <me> is empty or infinite then :
901 -- theXMin = theYMin = theZMin = RealFirst().
902 -- theXMax = theYMax = theZMax = RealLast().
903 ---Category: Private methods
906 aPlotter : Plotter from Graphic3d )
909 ---Category: Private methods
911 PrintNetwork ( myclass;
912 AStructure : Structure from Graphic3d;
913 AType : TypeOfConnection from Graphic3d );
915 ---Purpose: Prints informations about the network associated
916 -- with the structure <AStructure>.
917 ---Category: Private methods
919 Remove ( me : mutable;
920 APtr : Address from Standard;
921 AType : TypeOfConnection from Graphic3d )
924 ---Purpose: Suppress the adress <APtr> in the list
925 -- of descendants or in the list of ancestors.
926 ---Category: Private methods
928 Remove ( me : mutable;
929 AGroup : Group from Graphic3d )
932 ---Purpose: Suppress in the structure <me>, the group <AGroup>.
933 -- It will be erased at the next screen update.
934 ---Category: Private methods
936 SetComputeVisual ( me : mutable;
937 AVisual : TypeOfStructure from Graphic3d )
940 ---Category: Private methods
942 StructureManager ( me )
943 returns StructureManager from Graphic3d
946 ---Purpose: Returns the manager to which <me> is associated.
947 ---Category: Private methods
949 Transforms ( myclass;
950 ATrsf : Array2OfReal from TColStd;
951 X, Y, Z : Real from Standard;
952 NewX, NewY, NewZ : out Real from Standard );
954 ---Purpose: Transforms <X>, <Y>, <Z> with the transformation <ATrsf>.
955 ---Category: Private methods
957 Transforms ( myclass;
958 ATrsf : Array2OfReal from TColStd;
959 Coord : Vector from Graphic3d )
960 returns Vector from Graphic3d;
962 ---Purpose: Transforms <Coord> with the transformation <ATrsf>.
963 ---Category: Private methods
965 Transforms ( myclass;
966 ATrsf : Array2OfReal from TColStd;
967 Coord : Vertex from Graphic3d )
968 returns Vertex from Graphic3d;
970 ---Purpose: Transforms <Coord> with the transformation <ATrsf>.
971 ---Category: Private methods
973 TransformBoundaries (myclass;
974 theTrsf : Array2OfReal from TColStd;
975 theXMin, theYMin, theZMin : in out Real from Standard;
976 theXMax, theYMax, theZMax : in out Real from Standard)
979 ---Purpose: Transforms boundaries with <theTrsf> transformation.
980 ---Category: Private methods
985 ---Purpose: Calls the Update method of the StructureManager which
986 -- contains the Structure <me>.
987 ---Category: Private methods
989 UpdateStructure ( me : mutable;
990 CTXL : AspectLine3d from Graphic3d;
991 CTXT : AspectText3d from Graphic3d;
992 CTXM : AspectMarker3d from Graphic3d;
993 CTXF : AspectFillArea3d from Graphic3d )
996 ---Purpose: Updates the c structure associated to <me>.
997 ---Category: Private methods
999 CStructure ( me : mutable )
1000 returns CStructure from Graphic3d
1003 ---Purpose: Returns the c structure associated to <me>.
1004 ---Category: Private methods
1010 -- Class : Graphic3d_Structure
1012 -- Purpose : Declaration of variables specific to
1013 -- graphic structures.
1014 -- Reminder : A structure is defined in a manager.
1015 -- It is a sequence of groups of primitives.
1018 -- the associated C structure
1019 MyCStructure : CStructure from Graphic3d;
1021 -- the structures to which the structure is attached
1022 MyAncestors : SequenceOfAddress from TColStd;
1024 -- the structures attached to the structure
1025 MyDescendants : SequenceOfAddress from TColStd;
1027 -- the sequence of groups
1028 MyGroups : SequenceOfGroup from Graphic3d;
1030 -- the graphic driver used
1031 MyGraphicDriver : GraphicDriver from Graphic3d;
1033 -- the highlight method of the structure
1034 MyHighlightColor : Color from Quantity;
1035 MyHighlightMethod : TypeOfHighlightMethod from Aspect;
1037 -- the manager accepting the structure
1038 MyPtrStructureManager : Address from Standard is protected;
1039 MyFirstPtrStructureManager : Address from Standard is protected;
1040 MyOwner : Address from Standard;
1042 -- the type of visualisation accepted by the structure
1043 MyVisual : TypeOfStructure from Graphic3d;
1044 MyComputeVisual : TypeOfStructure from Graphic3d is protected;
1048 -- a lot of methods of Group use the methods of Structure
1049 class Group from Graphic3d