|
Open CASCADE Technology
6.7.1
|
This class allows to manage transient graphics
above one View.
A simple way to drawn something very quicly above
a complex scene (Hilighting,Sketching,...)
All transient graphics will be erased at the next
View::BeginDraw().
If RetainMode is active,
All transient graphics will be kept at the
next View::Update(),Redraw(). The transient graphics
is stored by this object and graphic library, the
graphic managed itself exposure,resizing,...
The method View::ClearDraw() is necessary to erase
all transient graphics.
If RetainMode is deactivate,
All transient graphics will be erased at the
next View::Update(),Redraw().
Remember that nothing is stored by this object and
graphic library,the application must managed itself
exposure,resizing,...
If double_buffering is activate,
all graphics are drawn in the back buffer and flushed
in the front buffer at the end of drawing but nothing
is done for to separate transient from structured
graphics,the only way to regenerate the structured
view is to Redraw() the view.
If double_buffering is deactivate,
the back buffer is preserved and used for restoring
the front buffer at begin drawing time.I recommend
to use the second way (without DB) if you want
to preserve the graphics and the performances!
More...
#include <Visual3d_TransientManager.hxx>

Public Member Functions | |
| Visual3d_TransientManager () | |
| Creates a TransientManager <aView>. More... | |
| void | Destroy () |
| Suppress the TransientManager <me>. More... | |
| ~Visual3d_TransientManager () | |
Public Member Functions inherited from MMgt_TShared | |
| virtual void | Delete () const |
| Memory deallocator for transient classes. More... | |
Public Member Functions inherited from Standard_Transient | |
| Standard_Transient () | |
| Empty constructor. More... | |
| Standard_Transient (const Standard_Transient &) | |
| Copy constructor – does nothing. More... | |
| Standard_Transient & | operator= (const Standard_Transient &) |
| Assignment operator, needed to avoid copying reference counter. More... | |
| virtual | ~Standard_Transient () |
| Destructor must be virtual. More... | |
| virtual void | ShallowDump (Standard_OStream &) const |
| virtual const Handle_Standard_Type & | DynamicType () const |
| Returns a type information object about this object. More... | |
| Standard_Boolean | IsInstance (const Handle_Standard_Type &theType) const |
| Returns a true value if this is an instance of Type. More... | |
| Standard_Boolean | IsInstance (const Standard_CString theTypeName) const |
| Returns a true value if this is an instance of TypeName. More... | |
| Standard_Boolean | IsKind (const Handle_Standard_Type &theType) const |
| Returns true if this is an instance of Type or an instance of any class that inherits from Type. Note that multiple inheritance is not supported by OCCT RTTI mechanism. More... | |
| Standard_Boolean | IsKind (const Standard_CString theTypeName) const |
| Returns true if this is an instance of TypeName or an instance of any class that inherits from TypeName. Note that multiple inheritance is not supported by OCCT RTTI mechanism. More... | |
| virtual Handle_Standard_Transient | This () const |
| Returns a Handle which references this object. Must never be called to objects created in stack. More... | |
| Standard_Integer | GetRefCount () const |
| Get the reference counter of this object. More... | |
Static Public Member Functions | |
| static Standard_Boolean | BeginDraw (const Handle< Visual3d_View > &aView, const Standard_Boolean DoubleBuffer=Standard_False, const Standard_Boolean RetainMode=Standard_False) |
Begins any graphics in the view <aView> <br>
Redraw any structured graphics in the back buffer before <br>
if <DoubleBuffer> is TRUE. <br>
Restore the front buffer from the back before <br>
if <DoubleBuffer> is FALSE. <br>
if <RetainMode> is TRUE. <br>
the graphic managed itself exposure,resizing ... <br>
if <RetainMode> is FALSE. <br>
the application must managed itself exposure,resizing ... <br>
| |
| static void | EndDraw (const Standard_Boolean Synchronize=Standard_False) |
Flush all graphics to the front buffer. <br> Synchronize graphics to the screen if <Synchronize> is | |
| static void | ClearDraw (const Handle< Visual3d_View > &aView, const Standard_Boolean aFlush=Standard_True) |
Clear all transient graphics in the view <aView> <br>
updates a scene if <aFlush> = true <br>
Raises TransientDefinitionError from Visual3d; | |
| static Standard_Boolean | BeginAddDraw (const Handle< Visual3d_View > &aView) |
Begins any add graphics in the view <aView> <br>
the application must managed itself exposure,resizing ... <br>
| |
| static void | EndAddDraw () |
Flush all add graphics to the front buffer. <br> Raises TransientDefinitionError from Visual3d; | |
| static void | DrawStructure (const Handle< Graphic3d_Structure > &AStructure) |
Drawn the structure <AStructure>. <br> Raises TransientDefinitionError from Visual3d; | |
This class allows to manage transient graphics
above one View.
A simple way to drawn something very quicly above
a complex scene (Hilighting,Sketching,...)
All transient graphics will be erased at the next
View::BeginDraw().
If RetainMode is active,
All transient graphics will be kept at the
next View::Update(),Redraw(). The transient graphics
is stored by this object and graphic library, the
graphic managed itself exposure,resizing,...
The method View::ClearDraw() is necessary to erase
all transient graphics.
If RetainMode is deactivate,
All transient graphics will be erased at the
next View::Update(),Redraw().
Remember that nothing is stored by this object and
graphic library,the application must managed itself
exposure,resizing,...
If double_buffering is activate,
all graphics are drawn in the back buffer and flushed
in the front buffer at the end of drawing but nothing
is done for to separate transient from structured
graphics,the only way to regenerate the structured
view is to Redraw() the view.
If double_buffering is deactivate,
the back buffer is preserved and used for restoring
the front buffer at begin drawing time.I recommend
to use the second way (without DB) if you want
to preserve the graphics and the performances!
| Visual3d_TransientManager::Visual3d_TransientManager | ( | ) |
Creates a TransientManager <aView>.
|
inline |
|
static |
Begins any add graphics in the view <aView> <br>
the application must managed itself exposure,resizing ... <br>
Warning: Returns TRUE if transient drawing is enabled in
the associated view.
Returns FALSE ,if nothing works because something
is wrong for the transient principle :
Immediat mode is not implemented depending of the
graphic library used.
MBX,PIXMAP double buffering don't works depending of
the graphic board and the visual of the window supporting
the view.
Warning: No default attributes
Raises TransientDefinitionError from Visual3d;
if Drawing is already opened.
or the associated view is not mapped on a window.
|
static |
Begins any graphics in the view <aView> <br>
Redraw any structured graphics in the back buffer before <br>
if <DoubleBuffer> is TRUE. <br>
Restore the front buffer from the back before <br>
if <DoubleBuffer> is FALSE. <br>
if <RetainMode> is TRUE. <br>
the graphic managed itself exposure,resizing ... <br>
if <RetainMode> is FALSE. <br>
the application must managed itself exposure,resizing ... <br>
Warning: Returns TRUE if transient drawing is enabled in
the associated view.
Returns FALSE ,if nothing works because something
is wrong for the transient principle :
Immediat mode is not implemented depending of the
graphic library used.
MBX,PIXMAP double buffering don't works depending of
the graphic board and the visual of the window supporting
the view.
Warning: No default attributes
Raises TransientDefinitionError from Visual3d;
if Drawing is already opened.
or the associated view is not mapped on a window.
|
static |
Clear all transient graphics in the view <aView> <br>
updates a scene if <aFlush> = true <br>
Raises TransientDefinitionError from Visual3d;
if Drawing is already opened.
or the associated view is not mapped on a window.
| void Visual3d_TransientManager::Destroy | ( | ) |
Suppress the TransientManager <me>.
|
static |
Drawn the structure <AStructure>. <br>
Raises TransientDefinitionError from Visual3d;
if Drawing is not opened.
|
static |
Flush all add graphics to the front buffer. <br>
Raises TransientDefinitionError from Visual3d;
if Drawing is not opened.
|
static |
Flush all graphics to the front buffer. <br>
Synchronize graphics to the screen if <Synchronize> is
TRUE (make becarefull to the performances!).
Raises TransientDefinitionError from Visual3d;
if Drawing is not opened.
1.8.5