Replacing french comments by english one
[occt.git] / src / Graphic3d / Graphic3d_Group.cdl
CommitLineData
7fd59977 1 --
2 -- File: Graphic3d_Group.cdl
3 -- Created: Vendredi 6 Septembre 1991
4 -- Author: NW,JPB,CAL
81bba717 5 -- 27/09/97 ; PCT : add manual control of textures
7fd59977 6 -- 11/97 ; CAL : ajout polyline par 2 points
7 -- 16/06/2000 : ATS: Study G005 - Group store presentations of it's objects in field
8 -- MyListOfPArray to avoid deletion of handle-manipulating
9 -- primitives.
10 --
11 ---Copyright: MatraDatavision 1991,1992,1993,1994
12 --
13 class Group from Graphic3d inherits TShared
14
15 ---Version:
16
17 ---Purpose: This class allows the definition of groups
18 -- of primitives inside of graphic objects (presentations).
19 -- A group contains the primitives and attributes
20 -- for which the range is limited to this group.
21 -- The primitives of a group can be globally suppressed.
22 --
23 -- There are two main group usage models:
24 --
25 -- 1) Non-modifiable, or unbounded, group ('black box').
26 -- Developers can repeat a sequence of
27 -- SetPrimitivesAspect() with AddPrimitiveArray() methods arbitrary number of times
28 -- to define arbitrary number of primitive "blocks" each having individual apect values.
29 -- Any modification of such a group is forbidden, as aspects and primitives are mixed
30 -- in memory without any high-level logical structure, and any modification is very likely to result
31 -- in corruption of the group internal data.
32 -- It is necessary to recreate such a group as a whole when some attribute should be changed.
33 -- (for example, in terms of AIS it is necessary to re-Compute() the whole presentation each time).
34 -- 2) Bounded group. Developers should specify the necessary group aspects with help of
35 -- SetGroupPrimitivesAspect() and then add primitives to the group.
36 -- Such a group have simplified organization in memory (a single block of attributes
37 -- followed by a block of primitives) and therefore it can be modified, if it is necessary to
38 -- change parameters of some aspect that has already been set, using methods:
39 -- IsGroupPrimitivesAspectSet() to detect which aspect was set for primitives;
40 -- GroupPrimitivesAspect() to read current aspect values
41 -- and SetGroupPrimitivesAspect() to set new values.
42 --
43 -- Developers are strongly recommended to take all the above into account when filling Graphic3d_Group
44 -- with aspects and primitives and choose the group usage model beforehand out of application needs.
45
46 ---Warning:
47 ---References:
48
49 uses
50
51 Array1OfInteger from TColStd,
52 Array1OfReal from TColStd,
53 HArray1OfByte from TColStd,
54
55 ExtendedString from TCollection,
56
57 PlaneAngle from Quantity,
58
59 Array1OfEdge from Aspect,
60 Edge from Aspect,
61
62 GroupAspect from Graphic3d,
63 AspectLine3d from Graphic3d,
64 AspectMarker3d from Graphic3d,
65 AspectText3d from Graphic3d,
66 AspectFillArea3d from Graphic3d,
67 HorizontalTextAlignment from Graphic3d,
68 CBitFields4 from Graphic3d,
69 CGroup from Graphic3d,
70 GraphicDriver from Graphic3d,
71 Structure from Graphic3d,
72 TextPath from Graphic3d,
73 TypeOfPolygon from Graphic3d,
74 Vector from Graphic3d,
75 Array1OfVertex from Graphic3d,
76 Array2OfVertex from Graphic3d,
77 Vertex from Graphic3d,
78 Array1OfVertexC from Graphic3d,
79 Array2OfVertexC from Graphic3d,
80 VertexC from Graphic3d,
81 Array1OfVertexN from Graphic3d,
82 Array2OfVertexN from Graphic3d,
83 VertexN from Graphic3d,
84 Array1OfVertexNC from Graphic3d,
85 Array2OfVertexNC from Graphic3d,
86 VertexNC from Graphic3d,
87 VerticalTextAlignment from Graphic3d,
88 VertexNT from Graphic3d,
89 Array1OfVertexNT from Graphic3d,
90 Array2OfVertexNT from Graphic3d,
91 ArrayOfPrimitives from Graphic3d,
92 ListOfPArray from Graphic3d,
93 ListIteratorOfListOfPArray from Graphic3d,
94 TransModeFlags from Graphic3d,
95 CBounds from Graphic3d
96
97 raises
98
99 GroupDefinitionError from Graphic3d,
100 PickIdDefinitionError from Graphic3d,
101 OutOfRange from Standard
102
103 is
104 Create ( AStructure : Structure from Graphic3d )
105 returns mutable Group from Graphic3d;
106 ---Level: Public
107 ---Purpose: Creates a group in the structure <AStructure>.
108
109 ---------------------------------------------------
110 -- Category: Methods to modify the class definition
111 ---------------------------------------------------
112
113 Clear ( me : mutable )
114 is static;
115 ---Level: Public
116 ---Purpose: Supress all primitives and attributes of <me>.
117 ---Category: Methods to modify the class definition
118
119 Destroy ( me : mutable )
120 is static;
121 ---Level: Public
122 ---Purpose: Supress the group <me> in the structure.
123 ---Category: Methods to modify the class definition
124 ---C++: alias ~
125
126 Remove ( me : mutable )
127 is static;
128 ---Level: Public
129 ---Purpose: Supress the group <me> in the structure.
130 -- Warning: No more graphic operations in <me> after this call.
131 ---Category: Methods to modify the class definition
132
133 --SetTransformPersistence( me : mutable;
134 -- AFlag : TransModeFlags from Graphic3d )
135 ---Level: Public
136 ---Purpose: Modifies the current modelling transform persistence (pan, zoom or rotate)
137 --is static;
138
139 --TransformPersistence( me )
140 -- returns TransModeFlags from Graphic3d
141 ---Level: Public
142 ---Purpose: Get the current modelling transform persistence (pan, zoom or rotate)
143 --is static;
144
145 SetGroupPrimitivesAspect ( me : mutable )
146 is static;
147 ---Level: Public
148 ---Purpose: Removes the context for all the line primitives
149 -- of the group.
150 ---Category: Methods to modify the class definition
151
152 SetGroupPrimitivesAspect ( me : mutable;
153 CTX : AspectLine3d from Graphic3d )
154 is static;
155 ---Level: Public
156 ---Purpose: Modifies the context for all the line primitives
157 -- of the group.
158 ---Category: Methods to modify the class definition
159
160 SetGroupPrimitivesAspect ( me : mutable;
161 CTX : AspectFillArea3d from Graphic3d )
162 is static;
163 ---Level: Public
164 ---Purpose: Modifies the context for all the face primitives
165 -- of the group.
166 ---Category: Methods to modify the class definition
167
168 SetGroupPrimitivesAspect ( me : mutable;
169 CTX : AspectText3d from Graphic3d )
170 is static;
171 ---Level: Public
172 ---Purpose: Modifies the context for all the text primitives
173 -- of the group.
174 ---Category: Methods to modify the class definition
175
176 SetGroupPrimitivesAspect ( me : mutable;
177 CTX : AspectMarker3d from Graphic3d )
178 is static;
179 ---Level: Public
180 ---Purpose: Modifies the context for all the marker primitives
181 -- of the group.
182 ---Category: Methods to modify the class definition
183
184 SetPrimitivesAspect ( me : mutable;
185 CTX : AspectLine3d from Graphic3d )
186 is static;
187 ---Level: Public
188 ---Purpose: Modifies the current context of the group to give
189 -- another aspect for all the line primitives created
190 -- after this call in the group.
191 ---Category: Methods to modify the class definition
192
193 SetPrimitivesAspect ( me : mutable;
194 CTX : AspectFillArea3d from Graphic3d )
195 is static;
196 ---Level: Public
197 ---Purpose: Modifies the current context of the group to give
198 -- another aspect for all the face primitives created
199 -- after this call in the group.
200 ---Category: Methods to modify the class definition
201
202 SetPrimitivesAspect ( me : mutable;
203 CTX : AspectText3d from Graphic3d )
204 is static;
205 ---Level: Public
206 ---Purpose: Modifies the current context of the group to give
207 -- another aspect for all the text primitives created
208 -- after this call in the group.
209 ---Category: Methods to modify the class definition
210
211 SetPrimitivesAspect ( me : mutable;
212 CTX : AspectMarker3d from Graphic3d )
213 is static;
214 ---Level: Public
215 ---Purpose: Modifies the current context of the group to give
216 -- another aspect for all the marker primitives created
217 -- after this call in the group.
218 ---Category: Methods to modify the class definition
219
220 SetMinMaxValues ( me : mutable;
221 XMin, YMin, ZMin : Real from Standard;
222 XMax, YMax, ZMax : Real from Standard )
223 is static;
224 ---Level: Public
225 ---Purpose: Sets the coordinates of the boundary box of the
226 -- group <me>.
227 ---Category: Methods to modify the class definition
228
229 --------------------------------------------------
230 -- Category: Methods to manage the pick identifier
231 --------------------------------------------------
232
233 PickId ( me )
234 returns Integer from Standard
235 is static;
236 ---Level: Public
237 ---Purpose: Returns the pick identifier of the group <me>.
238 -- Category: Methods to manage the pick identifier
239 -- Warning: Returns 0 if the pick identifier is not defined.
240
241 RemovePickId ( me : mutable )
242 is static;
243 ---Level: Public
244 ---Purpose: Removes the pick identifier of the group <me>.
245 -- Category: Methods to manage the pick identifier
246 -- Warning: Now the Pick Identifier is null.
247
248 SetPickId ( me : mutable;
249 Id : Integer from Standard )
250 ---Level: Public
251 ---Purpose: Places a pick identifier in the group <me>.
252 -- Category: Methods to manage the pick identifier
253 -- Warning: A Pick Identifier is an integer greater than zero.
254 --- Raises PickIdDefinitionError if <Id> is a negative value.
255 raises PickIdDefinitionError from Graphic3d is static;
256
257 -------------------------------------
258 -- Category: Methods to create Marker
259 -------------------------------------
260
261 ---------------------------------------------
262 -- Summary of Markers --
263 -- --
264 -- They should have one or more vertices. --
265 -- --
266 -- They have the following attributes. --
267 -- --
268 -- Marker Type. --
269 -- Marker Scale Factor. --
270 -- Marker Color. --
271 -- --
272 -- The size, shape and orientation of a --
273 -- marker is not subject to transformation --
274 ---------------------------------------------
275
276 Marker ( me : mutable;
277 APoint : Vertex from Graphic3d;
278 EvalMinMax : Boolean from Standard = Standard_True )
279 is static;
280 ---Level: Public
281 ---Purpose: Creates a marker in position <APoint> which will be drawn
282 -- with the current attribute (AspectMarker).
283 ---Category: Methods to create Marker
284
285 MarkerSet ( me : mutable;
286 ListVertex : Array1OfVertex from Graphic3d;
287 EvalMinMax : Boolean from Standard = Standard_True )
288 is static;
289 ---Purpose: Creates a group of markers defined by a table of
290 -- vertices.
291 ---Category: Methods to create Marker
292
293 --------------------------------------
294 -- Category: Methods to create Polygon
295 --------------------------------------
296
297 --------------------------------------------------
298 -- Summary of Polygons --
299 -- --
300 -- They are limited to one boundary. --
301 -- --
302 -- The boundary should be closed. --
303 -- --
304 -- They should have at least three vertices. --
305 -- --
306 -- They should be planar. --
307 -- --
308 -- They should have a normal. --
309 -- --
310 -- The boundary is drawn only when the interior --
311 -- style is hollow. --
312 -- --
313 -- The boundary have the following attributes : --
314 -- --
315 -- Line Type. --
316 -- Line Width Scale Factor. --
317 -- Line Color. --
318 -- --
319 -- They have only interior attributes : --
320 -- --
321 -- Interior Style. --
322 -- Interior Color. --
323 -- Front Material. --
324 -- Back Material. --
325 --------------------------------------------------
326
327 Polygon ( me : mutable;
328 ListVertex : Array1OfVertex from Graphic3d;
329 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
330 EvalMinMax : Boolean from Standard = Standard_True )
331 is static;
332 ---Level: Public
333 ---Purpose: Links up points to create a face drawn
334 -- using the current fill attributes (AspectFillArea3d))
335 -- The first and last points are not duplicates.
336 ---Category: Methods to create Polygon
337
338 Polygon ( me : mutable;
339 ListVertex : Array1OfVertex from Graphic3d;
340 Normal : Vector from Graphic3d;
341 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
342 EvalMinMax : Boolean from Standard = Standard_True )
343 is static;
344 ---Level: Public
345 ---Purpose: Links up points to create a face drawn
346 -- using the current fill attributes (AspectFillArea3d))
347 -- The first and last points are not duplicates.
348 -- The normal to the polygon is defined normalised.
349 ---Category: Methods to create Polygon
350
351 Polygon ( me : mutable;
352 ListVertex : Array1OfVertexN from Graphic3d;
353 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
354 EvalMinMax : Boolean from Standard = Standard_True )
355 is static;
356 ---Level: Public
357 ---Purpose: Links up points to create a face drawn
358 -- using the current fill attributes (AspectFillArea3d))
359 -- The first and last points are not duplicates.
360 -- The normal is defined and normalised for each vertex.
361 ---Category: Methods to create Polygon
362
363 Polygon ( me : mutable;
364 ListVertex : Array1OfVertexN from Graphic3d;
365 Normal : Vector from Graphic3d;
366 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
367 EvalMinMax : Boolean from Standard = Standard_True )
368 is static;
369 ---Level: Public
370 ---Purpose: Links up points to create a face drawn
371 -- using the current fill attributes (AspectFillArea3d))
372 -- The first and last points are not duplicates.
373 -- The normal is defined for each vertex.
374 -- The normal to the polygon is defined normalised.
375 ---Category: Methods to create Polygon
376
377
378 Polygon ( me : mutable;
379 ListVertex : Array1OfVertexNT from Graphic3d;
380 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
381 EvalMinMax : Boolean from Standard = Standard_True )
382 is static;
383 ---Level: Public
384 ---Purpose: Links up points to create a face drawn
385 -- using the current fill attributes (AspectFillArea3d))
81bba717 386 -- The first and last points are not duplicated.
7fd59977 387 -- The normal is defined and normalised for each vertex.
388 -- The texture coordinate is defined for each vertex.
389 ---Category: Methods to create Polygon
390
391
392
393 --------------------------------------------------
394 -- Summary of Polygons with holes --
395 -- --
396 -- They may have multiple boundaries. --
397 -- --
398 -- Each boundary should be closed. --
399 -- --
400 -- Each boundary should have at least three --
401 -- vertices. --
402 -- --
403 -- They should be planar. --
404 -- --
405 -- They should have a normal. --
406 -- --
407 -- The boundary is drawn only when the interior --
408 -- style is hollow. --
409 -- --
410 -- The boundary have the following attributes : --
411 -- --
412 -- Line Type. --
413 -- Line Width Scale Factor. --
414 -- Line Color. --
415 -- --
416 -- They have only interior attributes : --
417 -- --
418 -- Interior Style. --
419 -- Interior Color. --
420 -- Front Material. --
421 -- Back Material. --
422 --------------------------------------------------
423
424 Polygon ( me : mutable;
425 Bounds : Array1OfInteger from TColStd;
426 ListVertex : Array1OfVertex from Graphic3d;
427 EvalMinMax : Boolean from Standard = Standard_True )
428 is static;
429 ---Level: Public
430 ---Purpose: Creates a face with holes.
431 -- The face is described by the total number
432 -- of vertices on the external contour and around the holes,
433 -- and by the list of vertices.
434 -- The face will be drawn
435 -- using the current fill attributes (AspectFillArea3d))
436 -- The first and last points are not duplicates.
437 -- Bounds : total number of interior and exterior vertices
438 -- ListVertex : a list of the interior and exterior vertices
439 ---Category: Methods to create Polygon
440
441 Polygon ( me : mutable;
442 Bounds : Array1OfInteger from TColStd;
443 ListVertex : Array1OfVertex from Graphic3d;
444 Normal : Vector from Graphic3d;
445 EvalMinMax : Boolean from Standard = Standard_True )
446 is static;
447 ---Level: Public
448 ---Purpose: Creates a face with holes.
449 -- The face is described by the total number
450 -- of vertices on the external contour and around the holes,
451 -- and by the list of vertices.
452 -- The face will be drawn
453 -- using the current fill attributes (AspectFillArea3d))
454 -- The first and last points are not duplicates.
455 -- The normal to the polygon is normalised.
456 -- Bounds : total number of interior and exterior vertices
457 -- ListVertex : a list of the interior and exterior vertices
458 ---Category: Methods to create Polygon
459
460 Polygon ( me : mutable;
461 Bounds : Array1OfInteger from TColStd;
462 ListVertex : Array1OfVertexN from Graphic3d;
463 EvalMinMax : Boolean from Standard = Standard_True )
464 is static;
465 ---Level: Public
466 ---Purpose: Creates a face with holes.
467 -- The face is described by the total number
468 -- of vertices on the external contour and around the holes,
469 -- and by the list of vertices.
470 -- The face will be drawn
471 -- using the current fill attributes (AspectFillArea3d))
472 -- The first and last points are not duplicates.
473 -- Bounds : total number of interior and exterior vertices
474 -- ListVertex : a list of the interior and exterior vertices
475 ---Category: Methods to create Polygon
476
477 Polygon ( me : mutable;
478 Bounds : Array1OfInteger from TColStd;
479 ListVertex : Array1OfVertexN from Graphic3d;
480 Normal : Vector from Graphic3d;
481 EvalMinMax : Boolean from Standard = Standard_True )
482 is static;
483 ---Level: Public
484 ---Purpose: Creates a face with holes.
485 -- The face is described by the total number
486 -- of vertices on the external contour and around the holes,
487 -- and by the list of vertices.
488 -- The face will be drawn
489 -- using the current fill attributes (AspectFillArea3d))
490 -- The first and last points are not duplicates.
491 -- The normal to the polygon is normalised.
492 -- Bounds : total number of interior and exterior vertices
493 -- ListVertex : a list of the interior and exterior vertices
494 ---Category: Methods to create Polygon
495
496 PolygonSet ( me : mutable;
497 Bounds : Array1OfInteger from TColStd;
498 ListVertex : Array1OfVertex from Graphic3d;
499 AType : TypeOfPolygon from Graphic3d = Graphic3d_TOP_CONVEX;
500 EvalMinMax : Boolean from Standard = Standard_True )
501 is static;
502 ---Level: Public
503 ---Purpose: Links up points to create a set of face drawn
504 -- using the current fill attributes (AspectFillArea3d))
505 -- The first and last points are not duplicates.
506 ---Category: Methods to create Polygon
507
508 ---------------------------------------
509 -- Category: Methods to create Polyline
510 ---------------------------------------
511
512 --------------------------------------------
513 -- Summary of Polylines --
514 -- --
515 -- They should have two or more vertices. --
516 -- --
517 -- They have the following attributes. --
518 -- --
519 -- Line Type. --
520 -- Line Width Scale Factor. --
521 -- Line Color. --
522 --------------------------------------------
523
524 Polyline ( me : mutable;
525 APT1 : Vertex from Graphic3d;
526 APT2 : Vertex from Graphic3d;
527 EvalMinMax : Boolean from Standard = Standard_True )
528 is static;
529 ---Level: Public
530 ---Purpose: Links up points to create a line drawn
531 -- using the current line attributes (AspectLine)
532 ---Category: Methods to create Polyline
533
534 Polyline ( me : mutable;
535 ListVertex : Array1OfVertex from Graphic3d;
536 EvalMinMax : Boolean from Standard = Standard_True )
537 is static;
538 ---Level: Public
539 ---Purpose: Links up points to create a line drawn
540 -- using the current line attributes (AspectLine)
541 ---Category: Methods to create Polyline
542
543 Polyline ( me : mutable;
544 ListVertex : Array1OfVertexC from Graphic3d;
545 EvalMinMax : Boolean from Standard = Standard_True )
546 is static;
547 ---Level: Public
548 ---Purpose: Links up points to create a line drawn
549 -- using the current line attributes (AspectLine)
550 -- except for the colour which is defined
551 -- for each vertex.
552 ---Category: Methods to create Polyline
553
554 -----------------------------------------
555 -- Category: Methods to create Quadrangle
556 -----------------------------------------
557
558 QuadrangleMesh ( me : mutable;
559 ListVertex : Array2OfVertex from Graphic3d;
560 EvalMinMax : Boolean from Standard = Standard_True )
561 ---Level: Public
562 ---Purpose: Creates a group of quadrilaterals from a list of
563 -- points, such that their vertices are:
564 -- Ki,j; Ki,j+1; Ki+1,j+1; Ki+1,j.
565 -- The quadrilaterals will be drawn according to the
566 -- current attributes (AspectFillArea3d).
567 -- Category: Methods to create Quadrangle
568 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
569 -- less than four points.
570 raises GroupDefinitionError from Graphic3d is static;
571
572 QuadrangleMesh ( me : mutable;
573 ListVertex : Array2OfVertexN from Graphic3d;
574 EvalMinMax : Boolean from Standard = Standard_True )
575 ---Level: Public
576 ---Purpose: Creates a group of quadrilaterals from a list of
577 -- points, such that their vertices are:
578 -- Ki,j; Ki,j+1; Ki+1,j+1; Ki+1,j.
579 -- The quadrilaterals will be drawn according to the
580 -- current attributes (AspectFillArea3d).
581 -- For each vertex the normal is given.
582 -- Category: Methods to create Quadrangle
583 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
584 -- less than four points.
585 raises GroupDefinitionError from Graphic3d is static;
586
587 QuadrangleMesh ( me : mutable;
588 ListVertex : Array2OfVertexNT from Graphic3d;
589 EvalMinMax : Boolean from Standard = Standard_True )
590 ---Level: Public
591 ---Purpose: Creates a group of quadrilaterals from a list of
592 -- points, such that their vertices are:
593 -- Ki,j; Ki,j+1; Ki+1,j+1; Ki+1,j.
594 -- The quadrilaterals will be drawn according to the
595 -- current attributes (AspectFillArea3d).
596 -- For each vertex the normal is given.
597 -- For each vertex a texture coordinate is given.
598 -- Category: Methods to create Quadrangle
599 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
600 -- less than four points.
601 raises GroupDefinitionError from Graphic3d is static;
602
603 QuadrangleSet ( me : mutable;
604 ListVertex : Array1OfVertex from Graphic3d;
605 ListEdge : Array1OfEdge from Aspect;
606 EvalMinMax : Boolean from Standard = Standard_True )
607 ---Level: Public
608 ---Purpose: Creates a group of quadrangles defined by a table of
609 -- vertices and a table of edges, visible or not.
610 -- Category: Methods to create Quadrangle
611 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
612 -- less than four points or if <ListEdge> contains
613 -- less than four edges.
614 raises GroupDefinitionError from Graphic3d is static;
615
616 QuadrangleSet ( me : mutable;
617 ListVertex : Array1OfVertexN from Graphic3d;
618 ListEdge : Array1OfEdge from Aspect;
619 EvalMinMax : Boolean from Standard = Standard_True )
620 ---Level: Public
621 ---Purpose: Creates a group of quadrangles defined by a table of
622 -- vertices and a table of edges, visible or not.
623 -- For each vertex the normal is given.
624 -- Category: Methods to create Quadrangle
625 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
626 -- less than four points or if <ListEdge> contains
627 -- less than four edges.
628 raises GroupDefinitionError from Graphic3d is static;
629
630 QuadrangleSet ( me : mutable;
631 ListVertex : Array1OfVertexNT from Graphic3d;
632 ListEdge : Array1OfEdge from Aspect;
633 EvalMinMax : Boolean from Standard = Standard_True )
634 ---Level: Public
635 ---Purpose: Creates a group of quadrangles defined by a table of
636 -- vertices and a table of edges, visible or not.
637 -- For each vertex the normal is given.
638 -- For each vertex a texture coordinate is given.
639 -- Category: Methods to create Quadrangle
640 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
641 -- less than four points or if <ListEdge> contains
642 -- less than four edges.
643 raises GroupDefinitionError from Graphic3d is static;
644
645 QuadrangleSet ( me : mutable;
646 ListVertex : Array1OfVertexC from Graphic3d;
647 ListEdge : Array1OfEdge from Aspect;
648 EvalMinMax : Boolean from Standard = Standard_True )
649 ---Level: Public
650 ---Purpose: Creates a group of quadrangles defined by a table of
651 -- vertices and a table of edges, visible or not.
652 -- For each vertex the color is given.
653 -- Category: Methods to create Quadrangle
654 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
655 -- less than four points or if <ListEdge> contains
656 -- less than four edges.
657 raises GroupDefinitionError from Graphic3d is static;
658
659 QuadrangleSet ( me : mutable;
660 ListVertex : Array1OfVertexNC from Graphic3d;
661 ListEdge : Array1OfEdge from Aspect;
662 EvalMinMax : Boolean from Standard = Standard_True )
663 ---Level: Public
664 ---Purpose: Creates a group of quadrangles defined by a table of
665 -- vertices and a table of edges, visible or not.
666 -- For each vertex the normal and the color are given.
667 -- Category: Methods to create Quadrangle
668 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
669 -- less than four points or if <ListEdge> contains
670 -- less than four edges.
671 raises GroupDefinitionError from Graphic3d is static;
672
673 -----------------------------------
674 -- Category: Methods to create Text
675 -----------------------------------
676
677 --------------------------------------------
678 -- Summary of Texts --
679 -- --
680 -- Text has geometric and nongeometric --
681 -- attributes. --
682 -- --
683 -- The geometric text attributes are : --
684 -- --
685 -- Character Height. --
686 -- Character Up Vector. --
687 -- Text Path. --
688 -- Text Alignment Horizontal. --
689 -- Text Alignment Vertical. --
690 -- --
691 -- The nongeometric text attributes are : --
692 -- --
693 -- Text Font. --
694 -- Character Spacing. --
695 -- Character Expansion Factor. --
696 -- Text Color. --
697 --------------------------------------------
698
699 Text ( me : mutable;
700 AText : CString from Standard;
701 APoint : Vertex from Graphic3d;
702 AHeight : Real from Standard;
703 AAngle : PlaneAngle from Quantity;
704 ATp : TextPath from Graphic3d;
705 AHta : HorizontalTextAlignment from Graphic3d;
706 AVta : VerticalTextAlignment from Graphic3d;
707 EvalMinMax : Boolean from Standard = Standard_True )
708 is static;
709 ---Level: Public
710 ---Purpose: Creates the string <AText> at position <APoint>.
711 -- The 3D point of attachment is projected. The text is
712 -- written in the plane of projection.
713 -- The attributes are given with respect to the plane of
714 -- projection.
715 -- AHeight : Height of text.
716 -- (Relative to the Normalized Projection
717 -- Coordinates (NPC) Space).
718 -- AAngle : Orientation of the text
719 -- (with respect to the horizontal).
720 ---Category: Methods to create Text
721
722 Text ( me : mutable;
723 AText : CString from Standard;
724 APoint : Vertex from Graphic3d;
725 AHeight : Real from Standard;
726 EvalMinMax : Boolean from Standard = Standard_True )
727 is static;
728 ---Level: Public
729 ---Purpose: Creates the string <AText> at position <APoint>.
730 -- The 3D point of attachment is projected. The text is
731 -- written in the plane of projection.
732 -- The attributes are given with respect to the plane of
733 -- projection.
734 -- AHeight : Height of text.
735 -- (Relative to the Normalized Projection
736 -- Coordinates (NPC) Space).
737 -- The other attributes have the following default values:
738 -- AAngle : PI / 2.
739 -- ATp : TP_RIGHT
740 -- AHta : HTA_LEFT
741 -- AVta : VTA_BOTTOM
742 ---Category: Methods to create Text
743
744 Text ( me : mutable;
745 AText : ExtendedString from TCollection;
746 APoint : Vertex from Graphic3d;
747 AHeight : Real from Standard;
748 AAngle : PlaneAngle from Quantity;
749 ATp : TextPath from Graphic3d;
750 AHta : HorizontalTextAlignment from Graphic3d;
751 AVta : VerticalTextAlignment from Graphic3d;
752 EvalMinMax : Boolean from Standard = Standard_True )
753 is static;
754 ---Level: Internal
755 ---Purpose: Creates the string <AText> at position <APoint>.
756 -- The 3D point of attachment is projected. The text is
757 -- written in the plane of projection.
758 -- The attributes are given with respect to the plane of
759 -- projection.
760 -- AHeight : Height of text.
761 -- (Relative to the Normalized Projection
762 -- Coordinates (NPC) Space).
763 -- AAngle : Orientation of the text
764 -- (with respect to the horizontal).
765 ---Category: Methods to create Text
766
767 Text ( me : mutable;
768 AText : ExtendedString from TCollection;
769 APoint : Vertex from Graphic3d;
770 AHeight : Real from Standard;
771 EvalMinMax : Boolean from Standard = Standard_True )
772 is static;
773 ---Level: Internal
774 ---Purpose: Creates the string <AText> at position <APoint>.
775 -- The 3D point of attachment is projected. The text is
776 -- written in the plane of projection.
777 -- The attributes are given with respect to the plane of
778 -- projection.
779 -- AHeight : Height of text.
780 -- (Relative to the Normalized Projection
781 -- Coordinates (NPC) Space).
782 -- The other attributes have the following default values:
783 -- AAngle : PI / 2.
784 -- ATp : TP_RIGHT
785 -- AHta : HTA_LEFT
786 -- AVta : VTA_BOTTOM
787 ---Category: Methods to create Text
788
789 ---------------------------------------
790 ---Category: Methods to create Triangle
791 ---------------------------------------
792
793 TriangleMesh ( me : mutable;
794 ListVertex : Array1OfVertex from Graphic3d;
795 EvalMinMax : Boolean from Standard = Standard_True )
796 ---Level: Public
797 ---Purpose: Creates triangles from an array of points such that
798 -- the Kth triangle contains the vertices K, K+1, K+2.
799 -- The triangle will be drawn using the current fill
800 -- attributes (AspectFillArea3d)
801 -- Category: Methods to create Triangle
802 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
803 -- less than three points.
804 raises GroupDefinitionError from Graphic3d is static;
805
806 TriangleMesh ( me : mutable;
807 ListVertex : Array1OfVertexN from Graphic3d;
808 EvalMinMax : Boolean from Standard = Standard_True )
809 ---Level: Public
810 ---Purpose: Creates triangles from an array of points such that
811 -- the Kth triangle contains the vertices K, K+1, K+2.
812 -- The triangle will be drawn using the current fill
813 -- attributes (AspectFillArea3d)
814 -- The normal is given for each vertex.
815 -- Category: Methods to create Triangle
816 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
817 -- less than three points.
818 raises GroupDefinitionError from Graphic3d is static;
819
820 TriangleMesh ( me : mutable;
821 ListVertex : Array1OfVertexNT from Graphic3d;
822 EvalMinMax : Boolean from Standard = Standard_True )
823 ---Level: Public
824 ---Purpose: Creates triangles from an array of points such that
825 -- the Kth triangle contains the vertices K, K+1, K+2.
826 -- The triangle will be drawn using the current fill
827 -- attributes (AspectFillArea3d)
828 -- The normal is given for each vertex.
829 -- A texture coordinate is given for each vertex.
830 -- Category: Methods to create Triangle
831 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
832 -- less than three points.
833 raises GroupDefinitionError from Graphic3d is static;
834
835 TriangleSet ( me : mutable;
836 ListVertex : Array1OfVertex from Graphic3d;
837 ListEdge : Array1OfEdge from Aspect;
838 EvalMinMax : Boolean from Standard = Standard_True )
839 ---Level: Public
840 ---Purpose: Creates a group of triangles defined by a table of
841 -- vertices and a table of edges, visible or not.
842 -- Category: Methods to create Triangle
843 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
844 -- less than three points or if <ListEdge> contains
845 -- less than three edges.
846 raises GroupDefinitionError from Graphic3d is static;
847
848 TriangleSet ( me : mutable;
849 ListVertex : Array1OfVertexN from Graphic3d;
850 ListEdge : Array1OfEdge from Aspect;
851 EvalMinMax : Boolean from Standard = Standard_True )
852 ---Level: Public
853 ---Purpose: Creates a group of triangles defined by a table of
854 -- vertices and a table of edges, visible or not.
855 -- For each vertex the normal is given.
856 -- Category: Methods to create Triangle
857 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
858 -- less than three points or if <ListEdge> contains
859 -- less than three edges.
860 raises GroupDefinitionError from Graphic3d is static;
861
862 TriangleSet ( me : mutable;
863 ListVertex : Array1OfVertexNT from Graphic3d;
864 ListEdge : Array1OfEdge from Aspect;
865 EvalMinMax : Boolean from Standard = Standard_True )
866 ---Level: Public
867 ---Purpose: Creates a group of triangles defined by a table of
868 -- vertices and a table of edges, visible or not.
869 -- For each vertex the normal is given.
870 -- For each vertex a texture coordinate is given.
871 -- Category: Methods to create Triangle
872 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
873 -- less than three points or if <ListEdge> contains
874 -- less than three edges.
875 raises GroupDefinitionError from Graphic3d is static;
876
877 TriangleSet ( me : mutable;
878 ListVertex : Array1OfVertexC from Graphic3d;
879 ListEdge : Array1OfEdge from Aspect;
880 EvalMinMax : Boolean from Standard = Standard_True )
881 ---Level: Public
882 ---Purpose: Creates a group of triangles defined by a table of
883 -- vertices and a table of edges, visible or not.
884 -- For each vertex the color is given.
885 -- Category: Methods to create Triangle
886 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
887 -- less than three points or if <ListEdge> contains
888 -- less than three edges.
889 raises GroupDefinitionError from Graphic3d is static;
890
891 TriangleSet ( me : mutable;
892 ListVertex : Array1OfVertexNC from Graphic3d;
893 ListEdge : Array1OfEdge from Aspect;
894 EvalMinMax : Boolean from Standard = Standard_True )
895 ---Level: Public
896 ---Purpose: Creates a group of triangles defined by a table of
897 -- vertices and a table of edges, visible or not.
898 -- For each vertex the normal and the color are given.
899 -- Category: Methods to create Triangle
900 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
901 -- less than three points or if <ListEdge> contains
902 -- less than three edges.
903 raises GroupDefinitionError from Graphic3d is static;
904
905 AddPrimitiveArray( me : mutable;
906 elem : ArrayOfPrimitives from Graphic3d;
907 EvalMinMax: Boolean from Standard = Standard_True );
908 ---Level: Public
909 ---Purpose: Adds an array of primitives for display
910
911 RemovePrimitiveArray( me : mutable;
912 aRank : Integer from Standard)
913 ---Level: Public
914 ---Purpose: Remove the array of primitives of rank <aRank>
915 raises OutOfRange from Standard is static;
916 -- if <aRank> is < 1 or > ArrayNumber()
917
918 RemovePrimitiveArrays( me : mutable);
919 ---Level: Public
920 ---Purpose: Remove all array of primitives
921
922 UserDraw ( me : mutable;
923 AnObject : Address from Standard;
924 EvalMinMax : Boolean from Standard = Standard_True;
925 -- SAMTECH contribution 5 July 2007 -- BEGIN
926 ContainsFacet: Boolean from Standard = Standard_False
927 -- SAMTECH contribution 5 July 2007 -- END
928 )
929 ---Level: Public
930 ---Purpose: Creates an UserDraw primitive
931 -- Category: Methods to create UserDraw
932 -- Warning: Raises GroupDefinitionError if ...
933 raises GroupDefinitionError from Graphic3d is static;
934
935 ----------------------------
936 -- Category: Inquire methods
937 ----------------------------
938
939 ArrayNumber( me )
940 returns Integer from Standard;
941 ---Level: Public
942 ---Purpose: Returns the number of primitive array added in this group
943
944 InitDefinedArray( me:mutable );
945 ---Level: Public
946 ---Purpose: Initialize the array list iterator.
947
948 NextDefinedArray( me:mutable );
949 ---Level: Public
950 ---Purpose: Increments the array list iterator.
951
952 MoreDefinedArray( me:mutable )
953 returns Boolean from Standard;
954 ---Level: Public
955 ---Purpose: Returns TRUE if more array exists in the list.
956
957 DefinedArray( me )
958 returns mutable ArrayOfPrimitives from Graphic3d;
959 ---Level: Public
960 ---Purpose: Returns the current array of primitives according
961 -- to the array list iterator value.
962
963 IsGroupPrimitivesAspectSet ( me;
964 theAspect : GroupAspect from Graphic3d )
965 returns Boolean from Standard
966 is static;
967 ---Level: Public
968 ---Purpose: Returns TRUE if aspect is set for the group.
969 ---Category: Inquire methods
970
971 GroupPrimitivesAspect ( me;
972 CTXL : AspectLine3d from Graphic3d;
973 CTXT : AspectText3d from Graphic3d;
974 CTXM : AspectMarker3d from Graphic3d;
975 CTXF : AspectFillArea3d from Graphic3d )
976 is static;
977 ---Level: Public
978 ---Purpose: Returns the context of all the primitives of the group.
979 ---Category: Inquire methods
980
981 PrimitivesAspect ( me;
982 CTXL : AspectLine3d from Graphic3d;
983 CTXT : AspectText3d from Graphic3d;
984 CTXM : AspectMarker3d from Graphic3d;
985 CTXF : AspectFillArea3d from Graphic3d )
986 is static;
987 ---Level: Public
988 ---Purpose: Returns the last inserted context in the group <me>
989 -- foreach kind of primitives.
990 ---Category: Inquire methods
991
992 ContainsFacet ( me )
993 returns Boolean from Standard
994 is static;
995 ---Level: Internal
996 ---Purpose: Returns Standard_True if the group <me> contains
997 -- Polygons, Triangles or Quadrangles.
998 ---Category: Inquire methods
999
1000 IsDeleted ( me )
1001 returns Boolean from Standard
1002 is static;
1003 ---Level: Public
1004 ---Purpose: Returns Standard_True if the group <me> is deleted.
1005 -- <me> is deleted after the call Remove (me) or the
1006 -- associated structure is deleted.
1007 ---Category: Inquire methods
1008
1009 IsEmpty ( me )
1010 returns Boolean from Standard
1011 is static;
1012 ---Level: Public
1013 ---Purpose: Returns Standard_True if the group <me> is empty.
1014 ---Warning: A group is empty if the MinMaxValues method returns :
1015 -- XMin = YMin = ZMin = RealFirst ().
1016 -- XMax = YMax = ZMax = RealLast ().
1017 ---Category: Inquire methods
1018
1019 MinMaxValues ( me;
1020 XMin, YMin, ZMin : out Real from Standard;
1021 XMax, YMax, ZMax : out Real from Standard )
1022 is static;
1023 ---Level: Public
1024 ---Purpose: Returns the coordinates of the boundary box of the
1025 -- group <me>.
1026 ---Warning: If the group <me> is empty then :
1027 -- XMin = YMin = ZMin = RealFirst ().
1028 -- XMax = YMax = ZMax = RealLast ().
1029 ---Category: Inquire methods
1030
1031 Structure ( me )
1032 returns mutable Structure from Graphic3d
1033 is static;
1034 ---Level: Public
1035 ---Purpose: Returns the structure containing the group <me>.
1036 ---Category: Inquire methods
1037
1038 ----------------------------
1039 -- Category: Private methods
1040 ----------------------------
1041
1042 Exploration ( me )
1043 is static;
1044 ---Level: Internal
1045 ---Purpose: Prints informations about the group <me>.
1046 ---Category: Private methods
1047
1048 Labels ( me;
1049 LB, LE : in out Integer from Standard )
1050 is static private;
1051 ---Level: Internal
1052 ---Purpose: Returns the position of the group in the structure.
1053 ---Category: Private methods
1054
1055 MinMaxCoord ( me;
1056 XMin, YMin, ZMin : out Real from Standard;
1057 XMax, YMax, ZMax : out Real from Standard )
1058 is static private;
1059 ---Level: Internal
1060 ---Purpose: Returns the extreme coordinates found in the group.
1061 ---Warning: If the group <me> is empty then :
1062 -- XMin = YMin = ZMin = RealFirst ().
1063 -- XMax = YMax = ZMax = RealLast ().
1064 ---Category: Private methods
1065
1066 Update ( me )
1067 is static private;
1068 ---Level: Internal
1069 ---Purpose: Calls the Update method of the StructureManager which
1070 -- contains the associated Structure of the Group <me>.
1071 ---Category: Private methods
1072
1073 -----------------------------
1074 -- Category: Internal methods
1075 -----------------------------
1076
1077 BeginPrimitives ( me : mutable )
1078 is static;
1079 ---Level: Internal
1080 ---Category: Internal methods
1081
1082 EndPrimitives ( me : mutable )
1083 is static;
1084 ---Level: Internal
1085 ---Category: Internal methods
1086
1087 Bezier ( me : mutable;
1088 ListVertex : Array1OfVertex from Graphic3d;
1089 EvalMinMax : Boolean from Standard = Standard_True )
1090 ---Level: Internal
1091 ---Purpose: Creates a non rational Bezier curve with a set of poles :
1092 -- ListVertex. The weights are defaulted to all being 1.
1093 -- Category: Methods to create Curve
1094 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
1095 -- less than two points.
1096 raises GroupDefinitionError from Graphic3d is static;
1097
1098 Bezier ( me : mutable;
1099 ListVertex : Array1OfVertex from Graphic3d;
1100 ListWeight : Array1OfReal from TColStd;
1101 EvalMinMax : Boolean from Standard = Standard_True )
1102 ---Level: Internal
1103 ---Purpose: Creates a non rational Bezier curve with a set of poles :
1104 -- ListVertex and the set of weights ListWeight.
1105 -- If all the weights are identical the curve is considered
1106 -- as non rational.
1107 -- Category: Methods to create Curve
1108 -- Warning: Raises GroupDefinitionError if <ListVertex> contains
1109 -- less than two points or <ListVertex> and <ListWeight>
1110 -- have not the same length or one weight value is lower
1111 -- or equal to Resolution from package gp.
1112 raises GroupDefinitionError from Graphic3d is static;
1113
1114 --
1115
1116 fields
1117
1118 --
1119 -- Class : Graphic3d_Group
1120 --
1121 -- Purpose : Declaration of variables specific to groups
1122 -- of primitives.
1123 --
1124 -- Reminder : A group is defined in a structure
1125 -- It acts as the smallest editable entity.
1126
1127 -- the associated C structure
1128 MyCGroup : CGroup from Graphic3d;
1129
1130 -- the graphic driver used
1131 MyGraphicDriver : GraphicDriver from Graphic3d;
1132
1133 -- the state of the different contexts for primitives
1134 MyCBitFields : CBitFields4 from Graphic3d;
1135
1136 -- the structure contains the group
1137 MyPtrStructure : Address from Standard;
1138
1139 -- the min-max
1140 MyBounds : CBounds from Graphic3d;
1141
1142 MyListOfPArray : ListOfPArray from Graphic3d;
1143 MyListOfPArrayIterator : ListIteratorOfListOfPArray from Graphic3d;
1144
1145 MyMarkArray : HArray1OfByte from TColStd;
1146 MyMarkWidth : Integer from Standard;
1147 MyMarkHeight : Integer from Standard;
1148
1149 friends
1150
1151 Remove from class Structure from Graphic3d
1152 ( me : mutable; AGroup : Group from Graphic3d )
1153
1154 end Group;