0025974: Visualization - fix misprints in method naming of Graphic3d_GraduatedTrihedron
[occt.git] / src / Graphic3d / Graphic3d_GraphicDriver.cdl
CommitLineData
b311480e 1-- Created on: 1997-01-28
2-- Created by: CAL
3-- Copyright (c) 1997-1999 Matra Datavision
973c2be1 4-- Copyright (c) 1999-2014 OPEN CASCADE SAS
7fd59977 5--
973c2be1 6-- This file is part of Open CASCADE Technology software library.
b311480e 7--
d5f74e42 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
973c2be1 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.
b311480e 13--
973c2be1 14-- Alternatively, this file may be used under the terms of Open CASCADE
15-- commercial license or contractual agreement.
b311480e 16
6942f04a 17deferred class GraphicDriver from Graphic3d inherits TShared
7fd59977 18
19 ---Version:
20
2166f0fa 21 ---Purpose: This class allows the definition of a graphic driver
ff8178ef 22 -- for 3d interface (currently only OpenGl driver is used).
7fd59977 23
2166f0fa 24 ---Keywords: OpenGl
7fd59977 25
26 ---Warning:
27 ---References:
28
29uses
30
7fd59977 31 Array1OfInteger from TColStd,
32 Array1OfReal from TColStd,
33 Array2OfReal from TColStd,
34
f0430952 35 AsciiString from TCollection,
7fd59977 36 ExtendedString from TCollection,
37
38 NameOfColor from Quantity,
39 Color from Quantity,
40
41 PlaneAngle from Quantity,
42
692613e5 43 PixMap from Image,
7fd59977 44
7fd59977 45 CLayer2d from Aspect,
7fd59977 46 TypeOfTriedronEcho from Aspect,
47 TypeOfTriedronPosition from Aspect,
48 Handle from Aspect,
49 Display from Aspect,
7edf74fd 50 PrintAlgo from Aspect,
dc3fe572 51 DisplayConnection_Handle from Aspect,
7fd59977 52
a1954302 53 ZLayerId from Graphic3d,
c5751993 54 ZLayerSettings from Graphic3d,
55
7fd59977 56 AspectLine3d from Graphic3d,
57 AspectMarker3d from Graphic3d,
58 AspectText3d from Graphic3d,
59 AspectFillArea3d from Graphic3d,
60 HorizontalTextAlignment from Graphic3d,
61 CBitFields20 from Graphic3d,
b64d84be 62 Group from Graphic3d,
7fd59977 63 CLight from Graphic3d,
7fd59977 64 CPlane from Graphic3d,
65 CStructure from Graphic3d,
63bcc448 66 CStructure_Handle from Graphic3d,
7fd59977 67 CView from Graphic3d,
692613e5 68 BufferType from Graphic3d,
7fd59977 69 Structure from Graphic3d,
63bcc448 70 StructureManager from Graphic3d,
7fd59977 71 TextPath from Graphic3d,
72 TypeOfComposition from Graphic3d,
7fd59977 73 TypeOfPrimitive from Graphic3d,
74 Vector from Graphic3d,
75 Array1OfVertex from Graphic3d,
76 Array2OfVertex from Graphic3d,
77 Vertex from Graphic3d,
7fd59977 78 VerticalTextAlignment from Graphic3d,
7fd59977 79 PtrFrameBuffer from Graphic3d,
80 HArray1OfByte from TColStd,
81 FillMethod from Aspect,
82 GradientFillMethod from Aspect,
83 ExportFormat from Graphic3d,
84 SortType from Graphic3d,
85 HArray1OfReal from TColStd,
86 CUserDraw from Graphic3d,
87 NListOfHAsciiString from Graphic3d,
eeaaaefb 88 FontAspect from Font,
a79f67f8 89 GraduatedTrihedron from Graphic3d,
938d4544 90 ClipPlane from Graphic3d,
a79f67f8 91 Vec3 from Graphic3d,
938d4544 92 Ax2 from gp
7fd59977 93
94raises
95
96 TransformError from Graphic3d
97
98is
fe9fc669 99 Initialize (theDisp : DisplayConnection_Handle from Aspect)
100 returns GraphicDriver from Graphic3d;
101 ---Level: Public
102 ---Purpose: Initialises the Driver
7fd59977 103
104 ----------------------------
105 -- Category: Inquire methods
106 ----------------------------
107
108 InquireLightLimit ( me : mutable )
109 returns Integer from Standard
110 is deferred;
111 ---Purpose: call_togl_inquirelight
112
7fd59977 113 InquirePlaneLimit ( me : mutable )
114 returns Integer from Standard
115 is deferred;
116 ---Purpose: call_togl_inquireplane
117
118 InquireViewLimit ( me : mutable )
119 returns Integer from Standard
120 is deferred;
121 ---Purpose: call_togl_inquireview
122
7fd59977 123 -----------------------------------------
124 -- Category: Structure management methods
125 -----------------------------------------
126
a1954302 127 DisplayStructure ( me : mutable;
128 theCView : CView from Graphic3d;
129 theStructure : Structure from Graphic3d;
130 thePriority : Integer from Standard )
7fd59977 131 is deferred;
132 ---Purpose: call_togl_displaystructure
133
a1954302 134 EraseStructure ( me : mutable;
135 theCView : CView from Graphic3d;
136 theStructure : Structure from Graphic3d )
7fd59977 137 is deferred;
138 ---Purpose: call_togl_erasestructure
139
140 RemoveStructure ( me : mutable;
63bcc448 141 theCStructure : in out CStructure_Handle from Graphic3d )
7fd59977 142 is deferred;
143 ---Purpose: call_togl_removestructure
144
63bcc448 145 Structure (me : mutable;
146 theManager : StructureManager from Graphic3d)
147 returns CStructure_Handle from Graphic3d
7fd59977 148 is deferred;
63bcc448 149 ---Purpose: Creates new empty graphic structure
7fd59977 150
7fd59977 151 ------------------------------------
152 -- Category: Structured mode methods
153 ------------------------------------
154
155 ActivateView ( me : mutable;
156 ACView : CView from Graphic3d )
157 is deferred;
158 ---Purpose: call_togl_activateview
159
160 AntiAliasing ( me : mutable;
161 ACView : CView from Graphic3d;
162 AFlag : Boolean from Standard )
163 is deferred;
164 ---Purpose: call_togl_antialiasing
165
166 Background ( me : mutable;
167 ACView : CView from Graphic3d )
168 is deferred;
169 ---Purpose: call_togl_background
170
171 GradientBackground ( me : mutable;
172 ACView : CView from Graphic3d;
173 AColor1: Color from Quantity;
174 AColor2: Color from Quantity;
175 FillStyle : GradientFillMethod from Aspect
176 )
2166f0fa 177 is deferred;
7fd59977 178 ---Purpose: call_togl_gradient_background
179
180
181 BackgroundImage( me : mutable;
182 FileName : CString from Standard;
183 ACView : CView from Graphic3d;
184 FillStyle : FillMethod from Aspect )
185 is deferred;
186
187 SetBgImageStyle( me : mutable;
188 ACView : CView from Graphic3d;
189 FillStyle : FillMethod from Aspect )
190 is deferred;
191
192 SetBgGradientStyle( me : mutable;
193 ACView : CView from Graphic3d;
194 FillStyle : GradientFillMethod from Aspect )
2166f0fa 195 is deferred;
7fd59977 196
197 ClipLimit ( me : mutable;
198 ACView : CView from Graphic3d;
199 AWait : Boolean from Standard )
200 is deferred;
201 ---Purpose: call_togl_cliplimit
202
203 DeactivateView ( me : mutable;
204 ACView : CView from Graphic3d )
205 is deferred;
206 ---Purpose: call_togl_deactivateview
207
208 DepthCueing ( me : mutable;
209 ACView : CView from Graphic3d;
210 AFlag : Boolean from Standard )
211 is deferred;
212 ---Purpose: call_togl_cliplimit
213
7fd59977 214 RatioWindow ( me : mutable;
215 ACView : CView from Graphic3d )
216 is deferred;
217 ---Purpose: call_togl_ratio_window
218
219 Redraw ( me : mutable;
679ecdee 220 theCView : CView from Graphic3d;
221 theCUnderLayer : CLayer2d from Aspect;
222 theCOverLayer : CLayer2d from Aspect;
223 theX : Integer = 0;
224 theY : Integer = 0;
225 theWidth : Integer = 0;
226 theHeight : Integer = 0 )
227 is deferred;
228 ---Purpose: Redraw content of the view
229
230 RedrawImmediate ( me : mutable;
231 theCView : CView from Graphic3d;
232 theCUnderLayer : CLayer2d from Aspect;
233 theCOverLayer : CLayer2d from Aspect )
234 is deferred;
235 ---Purpose: Redraw layer of immediate presentations
236
237 Invalidate ( me : mutable;
238 theCView : CView from Graphic3d )
239 is deferred;
240 ---Purpose: Invalidates content of the view but does not redraw it
7fd59977 241
242 RemoveView ( me : mutable;
243 ACView : CView from Graphic3d )
244 is deferred;
245 ---Purpose: call_togl_removeview
246
247 SetLight ( me : mutable;
248 ACView : CView from Graphic3d )
249 is deferred;
250 ---Purpose: call_togl_setlight
251
4269bd1b 252 SetClipPlanes (me : mutable; theCView : CView from Graphic3d) is deferred;
253 ---Purpose: Pass clip planes to the associated graphic driver view.
254
b5ac8292 255 SetCamera (me : mutable; theCView : CView from Graphic3d)
256 is deferred;
257 ---Purpose: Inform graphic driver if camera assigned to view changes.
258
7fd59977 259 SetVisualisation ( me : mutable;
260 ACView : CView from Graphic3d )
261 is deferred;
262 ---Purpose: call_togl_setvisualisation
263
7fd59977 264 View ( me : mutable;
265 ACView : in out CView from Graphic3d )
266 returns Boolean from Standard
267 is deferred;
268 ---Purpose: call_togl_view
269
7fd59977 270 Environment ( me : mutable;
271 ACView : CView from Graphic3d )
272 is deferred;
273 ---Purpose:
274
7fd59977 275 ----------------------------------------
276 ---Category: Methods to create Triangle
277 -- for Purpose : see Graphic3d_Group.cdl
278 ----------------------------------------
279
7fd59977 280 EnableVBO( me : mutable;
281 status : Boolean from Standard )
2166f0fa 282 is deferred;
7fd59977 283 ---Purpose: enables/disables usage of OpenGL vertex buffer arrays while drawing primitiev arrays
284
f0430952 285 MemoryInfo (me;
286 theFreeBytes : out Size from Standard;
287 theInfo : out AsciiString from TCollection) returns Boolean from Standard is deferred;
288 ---Purpose: Returns information about GPU memory usage.
289
7fd59977 290 ----------------------------------------
291 ---Category: Methods to create Triedron
292 -- for Purpose : see Graphic3d_Group.cdl
293 ----------------------------------------
294
295 ZBufferTriedronSetup ( me : mutable;
536d98e2 296 theCView : CView from Graphic3d;
7fd59977 297 XColor : NameOfColor from Quantity = Quantity_NOC_RED;
298 YColor : NameOfColor from Quantity = Quantity_NOC_GREEN;
299 ZColor : NameOfColor from Quantity = Quantity_NOC_BLUE1;
300 SizeRatio : Real from Standard = 0.8;
301 AxisDiametr : Real from Standard = 0.05;
302 NbFacettes : Integer from Standard = 12)
303 is deferred;
304 ---Purpose: call_togl_ztriedron_setup
305
306 TriedronDisplay ( me : mutable;
307 ACView : CView from Graphic3d;
308 APosition : TypeOfTriedronPosition from Aspect = Aspect_TOTP_CENTER;
309 AColor : NameOfColor from Quantity = Quantity_NOC_WHITE ;
310 AScale : Real from Standard = 0.02;
311 AsWireframe : Boolean from Standard = Standard_True )
312 is deferred;
313 ---Purpose: call_togl_triedron_display
314
315
316 TriedronErase ( me : mutable;
317 ACView : CView from Graphic3d)
318 is deferred;
319 ---Purpose: call_togl_triedron_erase
320
321
322 TriedronEcho ( me : mutable;
323 ACView : CView from Graphic3d;
324 AType : TypeOfTriedronEcho from Aspect = Aspect_TOTE_NONE )
325 is deferred;
326 ---Purpose: call_togl_triedron_echo
327
328 ---------------------------------
329 ---Category: Graduated trihedron
330 ---------------------------------
331
7fd59977 332 GraduatedTrihedronDisplay(me : mutable;
a79f67f8 333 theView : CView from Graphic3d;
334 theCubic : GraduatedTrihedron from Graphic3d)
7fd59977 335 ---Purpose: call_togl_graduatedtrihedron_display
336 is deferred;
337
338 GraduatedTrihedronErase(me : mutable;
a79f67f8 339 theView : CView from Graphic3d)
7fd59977 340 ---Purpose: call_togl_graduatedtrihedron_erase
341 is deferred;
342
a79f67f8 343 GraduatedTrihedronMinMaxValues (me : mutable;
344 theView : CView from Graphic3d;
345 theMin : Vec3 from Graphic3d;
346 theMax : Vec3 from Graphic3d)
347 ---Purpose: Sets minimum and maximum points of scene bounding box for Graduated Trihedron
348 -- stored in graphic view object.
349 -- @param theView [in] current graphic view
350 -- @param theMin [in] the minimum point of scene.
351 -- @param theMax [in] the maximum point of scene.
352
7fd59977 353 is deferred;
354
7fd59977 355 ----------------------------------
679ecdee 356 -- Category: Immediate mode methods
7fd59977 357 ----------------------------------
358
1981cb22 359 SetImmediateModeDrawToFront (me : mutable;
360 theCView : CView from Graphic3d;
361 theDrawToFrontBuffer : Boolean from Standard)
362 returns Boolean from Standard
363 is deferred;
364 ---Purpose: @param theDrawToFrontBuffer Advanced option to modify rendering mode:
365 -- 1. TRUE. Drawing immediate mode structures directly to the front buffer over the scene image.
366 -- Fast, so preferred for interactive work (used by default).
367 -- However these extra drawings will be missed in image dump since it is performed from back buffer.
368 -- Notice that since no pre-buffering used the V-Sync will be ignored and rendering could be seen
369 -- in run-time (in case of slow hardware) and/or tearing may appear.
370 -- So this is strongly recommended to draw only simple (fast) structures.
371 -- 2. FALSE. Drawing immediate mode structures to the back buffer.
372 -- The complete scene is redrawn first, so this mode is slower if scene contains complex data and/or V-Sync is turned on.
373 -- But it works in any case and is especially useful for view dump because the dump image is read from the back buffer.
374 -- @return previous mode.
375
a1954302 376 DisplayImmediateStructure ( me : mutable;
377 theCView : CView from Graphic3d;
378 theStructure : Structure from Graphic3d )
679ecdee 379 is deferred;
380 ---Purpose: Display structure in immediate mode on top of general presentation
7fd59977 381
679ecdee 382 EraseImmediateStructure ( me : mutable;
383 theCView : CView from Graphic3d;
384 theCStructure : CStructure from Graphic3d )
385 is deferred;
386 ---Purpose: Erases immediate structure
7fd59977 387
7fd59977 388 -------------------------------
389 -- Category: Layer mode methods
390 -------------------------------
391
392 Layer ( me : mutable;
393 ACLayer : in out CLayer2d from Aspect )
394 is deferred;
395 ---Purpose: call_togl_layer2d
396
397 RemoveLayer ( me : mutable;
398 ACLayer : CLayer2d from Aspect )
399 is deferred;
400 ---Purpose: call_togl_removelayer2d
401
402 BeginLayer ( me : mutable;
403 ACLayer : CLayer2d from Aspect )
404 is deferred;
405 ---Purpose: call_togl_begin_layer2d
406
407 BeginPolygon2d ( me : mutable )
408 is deferred;
409 ---Purpose: call_togl_begin_polygon2d
410
411 BeginPolyline2d ( me : mutable )
412 is deferred;
413 ---Purpose: call_togl_begin_polyline2d
414
415 ClearLayer ( me : mutable;
416 ACLayer : CLayer2d from Aspect )
417 is deferred;
418 ---Purpose: call_togl_clear_layer2d
419
420 Draw ( me : mutable;
421 X : ShortReal from Standard;
422 Y : ShortReal from Standard )
423 is deferred;
424 ---Purpose: call_togl_draw2d
425
426 Edge ( me : mutable;
427 X : ShortReal from Standard;
428 Y : ShortReal from Standard )
429 is deferred;
430 ---Purpose: call_togl_edge2d
431
432 EndLayer ( me : mutable )
433 is deferred;
434 ---Purpose: call_togl_end_layer2d
435
436 EndPolygon2d ( me : mutable )
437 is deferred;
438 ---Purpose: call_togl_end_polygon2d
439
440 EndPolyline2d ( me : mutable )
441 is deferred;
442 ---Purpose: call_togl_end_polyline2d
443
444 Move ( me : mutable;
445 X : ShortReal from Standard;
446 Y : ShortReal from Standard )
447 is deferred;
448 ---Purpose: call_togl_move2d
449
450 Rectangle ( me : mutable;
451 X, Y : ShortReal from Standard;
452 Width, Height : ShortReal from Standard )
453 is deferred;
454 ---Purpose: call_togl_rectangle2d
455
456 SetColor ( me : mutable;
457 R : ShortReal from Standard;
458 G : ShortReal from Standard;
459 B : ShortReal from Standard )
460 is deferred;
461 ---Purpose: call_togl_set_color
462
463 SetTransparency ( me : mutable;
464 ATransparency : ShortReal from Standard )
465 is deferred;
466 ---Purpose: call_togl_set_transparency
467
468 UnsetTransparency ( me : mutable )
469 is deferred;
470 ---Purpose: call_togl_unset_transparency
471
472 SetLineAttributes ( me : mutable;
473 Type : Integer from Standard;
474 Width : ShortReal from Standard )
475 is deferred;
476 ---Purpose: call_togl_set_line_attributes
477
478
479 SetTextAttributes ( me : mutable;
480 Font : CString from Standard;
481 Type : Integer from Standard;
482 R : ShortReal from Standard;
483 G : ShortReal from Standard;
484 B : ShortReal from Standard )
2166f0fa 485 is deferred;
25289ec1 486 ---Purpose: Set text attributes for under-/overlayer.
487 -- <Font> argument defines the name of the font to be used,
488 -- <Type> argument defines the display type of the text,
489 -- <R> <G> <B> values define the color of decal or subtitle background.
490 -- To set the color of the text you can use the SetColor method.
7fd59977 491
492 Text ( me : mutable;
493 AText : CString from Standard;
494 X, Y : ShortReal from Standard;
495 AHeight : ShortReal from Standard )
496 is deferred;
497 ---Purpose: call_togl_text2d
498 -- If AHeight < 0 default text height is used by driver (DefaultTextHeight method)
499
500 DefaultTextHeight( me )
501 returns ShortReal from Standard
502 is deferred;
503
504
505 TextSize( me;
506 AText : CString from Standard;
507 AHeight : ShortReal from Standard;
508 AWidth : in out ShortReal from Standard;
509 AnAscent : in out ShortReal from Standard;
510 ADescent : in out ShortReal from Standard )
511 is deferred;
512 ---Purpose: call_togl_textsize2d
513
514 SetBackFacingModel ( me : mutable;
515 aView : CView from Graphic3d )
516 is deferred;
517 ---Purpose: call_togl_backfacing
518
519 SetDepthTestEnabled( me; view : CView from Graphic3d;
520 isEnabled : Boolean from Standard )
521 is deferred;
522 ---Purpose: call_togl_depthtest
523
524 IsDepthTestEnabled( me; view : CView from Graphic3d )
525 returns Boolean from Standard is deferred;
526 ---Purpose: call_togl_isdepthtest
527
528 ReadDepths( me;
529 view : CView from Graphic3d;
530 x, y : Integer;
531 width, height : Integer;
532 buffer : Address )
533 is deferred;
534 ---Purpose: Reads depths of shown pixels of the given
535 -- rectangle (glReadPixels with GL_DEPTH_COMPONENT)
536
537 FBOCreate( me : mutable;
538 view : CView from Graphic3d;
539 width, height : Integer from Standard )
540 returns PtrFrameBuffer from Graphic3d
541 is deferred;
542 ---Purpose: Generate offscreen FBO in the graphic library.
543 -- If not supported on hardware returns NULL.
544
545 FBORelease( me : mutable;
546 view : CView from Graphic3d;
547 fboPtr : in out PtrFrameBuffer from Graphic3d )
548 is deferred;
549 ---Purpose: Remove offscreen FBO from the graphic library
550
551 FBOGetDimensions( me : mutable;
552 view : CView from Graphic3d;
553 fboPtr : PtrFrameBuffer from Graphic3d;
554 width, height : out Integer from Standard;
555 widthMax, heightMax : out Integer from Standard )
556 is deferred;
557 ---Purpose: Read offscreen FBO configuration.
558
559 FBOChangeViewport( me : mutable;
560 view : CView from Graphic3d;
561 fboPtr : in out PtrFrameBuffer from Graphic3d;
562 width, height : Integer from Standard )
563 is deferred;
564 ---Purpose: Change offscreen FBO viewport.
565
566 BufferDump( me : mutable;
692613e5 567 theCView : CView from Graphic3d;
568 theImage : in out PixMap from Image;
569 theBufferType : BufferType from Graphic3d )
7fd59977 570 returns Boolean from Standard
571 is deferred;
572 ---Purpose: Dump active rendering buffer into specified memory buffer.
573
574 SetGLLightEnabled( me; view : CView from Graphic3d;
575 isEnabled : Boolean from Standard )
576 is deferred;
577 ---Purpose: call_togl_gllight
578
579 IsGLLightEnabled( me; view : CView from Graphic3d )
580 returns Boolean from Standard is deferred;
581 ---Purpose: call_togl_isgllight
582
583 Print (me;
584 ACView : CView from Graphic3d;
585 ACUnderLayer : CLayer2d from Aspect;
586 ACOverLayer : CLayer2d from Aspect;
587 hPrnDC : Handle from Aspect;
588 showBackground : Boolean;
7edf74fd
A
589 filename : CString;
590 printAlgorithm : PrintAlgo from Aspect = Aspect_PA_STRETCH;
591 theScaleFactor : Real from Standard = 1.0 )
592 returns Boolean from Standard is deferred;
7fd59977 593 ---Level: Internal
594 ---Purpose: print the contents of all layers of the view to the printer.
595 -- <hPrnDC> : Pass the PrinterDeviceContext (HDC),
596 -- <showBackground> : When set to FALSE then print the view without background color
597 -- (background is white)
598 -- else set to TRUE for printing with current background color.
599 -- <filename>: If != NULL, then the view will be printed to a file.
7edf74fd
A
600 -- <printAlgorithm>: Select print algorithm: stretch, tile.
601 -- <theScaleFactor>: Scaling coefficient, used internally to scale the
602 -- printings accordingly to the scale factor selected in the printer
603 -- properties dialog.
604 -- Returns Standard_True if the data is passed to the printer, otherwise
605 -- Standard_False if the print operation failed due to the printer errors,
606 -- or insufficient system memory available.
7fd59977 607 ---Warning: Works only under Windows.
608
7fd59977 609 Export( me: mutable;
5cedc27f
K
610 theFileName : CString from Standard;
611 theFormat : ExportFormat from Graphic3d;
612 theSortType : SortType from Graphic3d;
613 theWidth, theHeight : Integer from Standard;
614 theView : CView from Graphic3d;
615 theLayerUnder : CLayer2d from Aspect;
616 theLayerOver : CLayer2d from Aspect;
617 thePrecision : Real from Standard = 0.005;
618 theProgressBarFunc : Address from Standard = NULL;
619 theProgressObject : Address from Standard = NULL )
620 returns Boolean from Standard
621 is deferred;
622 ---Purpose:
623 -- Export scene into the one of the Vector graphics formats (SVG, PS, PDF...).
624 -- In contrast to Bitmaps, Vector graphics is scalable (so you may got quality benefits on printing to laser printer).
625 -- Notice however that results may differ a lot and do not contain some elements.
7fd59977 626
b7cd4ba7 627 InvalidateBVHData( me : mutable;
628 theCView : out CView from Graphic3d;
629 theLayerId : Integer from Standard )
630 is deferred;
631 ---Purpose:
632 -- Marks BVH tree and the set of BVH primitives of correspondent priority list with id theLayerId as outdated.
633
59f45b7c 634 AddZLayer( me : mutable;
635 theCView : CView from Graphic3d;
a1954302 636 theLayerId : ZLayerId from Graphic3d )
59f45b7c 637 is deferred;
638 ---Purpose: Add a new top-level z layer with ID <theLayerId> for
639 -- the view. Z layers allow drawing structures in higher layers
640 -- in foreground of structures in lower layers. To add a structure
641 -- to desired layer on display it is necessary to set the layer
642 -- ID for the structure.
643
644 RemoveZLayer( me : mutable;
645 theCView : CView from Graphic3d;
a1954302 646 theLayerId : ZLayerId from Graphic3d )
59f45b7c 647 is deferred;
648 ---Purpose: Remove Z layer from the specified view. All structures
649 -- displayed at the moment in layer will be displayed in default layer
650 -- ( the bottom-level z layer ). To unset layer ID from associated
651 -- structures use method UnsetZLayer (...).
652
653 UnsetZLayer( me : mutable;
a1954302 654 theLayerId : ZLayerId from Graphic3d )
59f45b7c 655 is deferred;
656 ---Purpose: Unset Z layer ID for all structures. The structure
657 -- indexes will be set to default layer ( the bottom-level z layer
658 -- with ID = 0 ).
659
59f45b7c 660 ChangeZLayer( me : mutable;
661 theCStructure : CStructure from Graphic3d;
662 theCView : CView from Graphic3d;
a1954302 663 theNewLayerId : ZLayerId from Graphic3d )
59f45b7c 664 is deferred;
665 ---Purpose: Change Z layer of a structure already presented in view.
666
c5751993 667 SetZLayerSettings( me : mutable;
668 theCView : CView from Graphic3d;
a1954302 669 theLayerId : ZLayerId from Graphic3d;
c5751993 670 theSettings : ZLayerSettings from Graphic3d)
671 is deferred;
672 ---Purpose: Sets the settings for a single Z layer of specified view.
673
b7cd4ba7 674 ChangePriority( me : mutable;
675 theCStructure : CStructure from Graphic3d;
676 theCView : CView from Graphic3d;
677 theNewPriority : Integer from Standard )
678 is deferred;
679 ---Purpose: Changes the priority of a structure within its Z layer
680 -- in the specified view.
681
7fd59977 682 -----------------------------
683 -- Category: Internal methods
684 -----------------------------
685
686 PrintBoolean ( me;
687 AComment : CString from Standard;
688 AValue : Boolean from Standard );
689
7fd59977 690 PrintCLight ( me;
691 ACLight : CLight from Graphic3d;
692 AField : Integer from Standard );
693
7fd59977 694 PrintCStructure ( me;
695 ACStructure : CStructure from Graphic3d;
696 AField : Integer from Standard );
697
698 PrintCView ( me;
699 ACView : CView from Graphic3d;
700 AField : Integer from Standard );
701
702 PrintFunction ( me;
703 AFunc : CString from Standard );
704
705 PrintInteger ( me;
706 AComment : CString from Standard;
707 AValue : Integer from Standard );
708
709 PrintIResult ( me;
710 AFunc : CString from Standard;
711 AResult : Integer from Standard );
712
713 PrintShortReal ( me;
714 AComment : CString from Standard;
715 AValue : ShortReal from Standard );
716
717 PrintMatrix ( me;
718 AComment : CString from Standard;
719 AMatrix : Array2OfReal from TColStd )
720 raises TransformError from Graphic3d;
721
722 PrintString ( me;
723 AComment : CString from Standard;
724 AString : CString from Standard );
725
726 SetTrace ( me : mutable;
727 ALevel : Integer from Standard )
728 is static;
729
730 Trace ( me )
731 returns Integer from Standard
732 is static;
733
dc3fe572 734 GetDisplayConnection (me)
735 returns DisplayConnection_Handle from Aspect;
736 ---C++: return const &
737
738 ---Purpose: returns Handle to display connection
739
eb4320f2 740 IsDeviceLost (me)
741 returns Boolean from Standard;
742 -- Purpose: @return Standard_True in cases when the last view has been removed but some objects still present.
743
744 ResetDeviceLostFlag (me: mutable);
745 -- Purpose: Resets DeviceLostFlag to default (Standard_False) state.
746
7fd59977 747fields
748
dc3fe572 749 MyTraceLevel : Integer from Standard is protected;
dc3fe572 750 myDisplayConnection: DisplayConnection_Handle from Aspect is protected;
eb4320f2 751 myDeviceLostFlag : Boolean from Standard is protected;
7fd59977 752
753end GraphicDriver from Graphic3d;