|
Open CASCADE Technology
6.7.1
|
This class provides methods to create presentation of nodes with assigned color.
There are two ways of presentation building
More...
#include <MeshVS_NodalColorPrsBuilder.hxx>

Public Member Functions | |
| MeshVS_NodalColorPrsBuilder (const Handle< MeshVS_Mesh > &Parent, const MeshVS_DisplayModeFlags &Flags=MeshVS_DMF_NodalColorDataPrs, const Handle< MeshVS_DataSource > &DS=0, const Standard_Integer Id=-1, const MeshVS_BuilderPriority &Priority=MeshVS_BP_NodalColor) | |
| virtual void | Build (const Handle< Prs3d_Presentation > &Prs, const TColStd_PackedMapOfInteger &IDs, TColStd_PackedMapOfInteger &IDsToExclude, const Standard_Boolean IsElement, const Standard_Integer DisplayMode) const |
| Builds presentation of nodes with assigned color. More... | |
| const MeshVS_DataMapOfIntegerColor & | GetColors () const |
| Returns map of colors assigned to nodes. More... | |
| void | SetColors (const MeshVS_DataMapOfIntegerColor &Map) |
| Sets map of colors assigned to nodes. More... | |
| Standard_Boolean | HasColors () const |
| Returns true, if map isn't empty More... | |
| Standard_Boolean | GetColor (const Standard_Integer ID, Quantity_Color &theColor) const |
| Returns color assigned to single node More... | |
| void | SetColor (const Standard_Integer ID, const Quantity_Color &theColor) |
| Sets color assigned to single node More... | |
| void | UseTexture (const Standard_Boolean theToUse) |
| Specify whether texture must be used to build presentation More... | |
| Standard_Boolean | IsUseTexture () const |
| Verify whether texture is used to build presentation More... | |
| void | SetColorMap (const Aspect_SequenceOfColor &theColors) |
Set colors to be used for texrture presentation <br> theColors - colors for valid coordinates (laying in range [0, 1]) | |
| const Aspect_SequenceOfColor & | GetColorMap () const |
| Return colors used for texrture presentation More... | |
| void | SetInvalidColor (const Quantity_Color &theInvalidColor) |
| Set color representing invalid texture coordinate (laying outside range [0, 1]) More... | |
| Quantity_Color | GetInvalidColor () const |
| Return color representing invalid texture coordinate (laying outside range [0, 1]) More... | |
| void | SetTextureCoords (const TColStd_DataMapOfIntegerReal &theMap) |
| Specify correspondence between node IDs and texture coordinates (range [0, 1]) More... | |
| const TColStd_DataMapOfIntegerReal & | GetTextureCoords () const |
| Get correspondence between node IDs and texture coordinates (range [0, 1]) More... | |
| void | SetTextureCoord (const Standard_Integer theID, const Standard_Real theCoord) |
| Specify correspondence between node ID and texture coordinate (range [0, 1]) More... | |
| Standard_Real | GetTextureCoord (const Standard_Integer theID) |
| Return correspondence between node IDs and texture coordinate (range [0, 1]) More... | |
Public Member Functions inherited from MeshVS_PrsBuilder | |
| virtual void | CustomBuild (const Handle< Prs3d_Presentation > &Prs, const TColStd_PackedMapOfInteger &IDs, TColStd_PackedMapOfInteger &IDsToExclude, const Standard_Integer DisplayMode) const |
This method is called to build presentation of custom elements (they have MeshVS_ET_0D type). <br> IDs is set of numeric identificators of elements for custom building. | |
| virtual Handle_SelectBasics_SensitiveEntity | CustomSensitiveEntity (const Handle< SelectBasics_EntityOwner > &Owner, const Standard_Integer SelectMode) const |
| This method is called to build sensitive of custom elements ( they have MeshVS_ET_0D type ) More... | |
| Standard_Integer | GetFlags () const |
| Returns flags, assigned with builder during creation More... | |
| virtual Standard_Boolean | TestFlags (const Standard_Integer DisplayMode) const |
Test whether display mode has flags assigned with this builder. <br> This method has default implementation and can be redefined for advance behavior | |
| Standard_Integer | GetId () const |
| Returns builder ID More... | |
| Standard_Integer | GetPriority () const |
| Returns priority; as priority bigger, as soon builder will be called. More... | |
| Handle_MeshVS_DataSource | GetDataSource () const |
| Returns custom data source or default ( from MeshVS_Mesh ) if custom is NULL More... | |
| void | SetDataSource (const Handle< MeshVS_DataSource > &newDS) |
| Change custom data source More... | |
| Handle_MeshVS_Drawer | GetDrawer () const |
| Returns custom drawer or default ( from MeshVS_Mesh ) if custom is NULL More... | |
| void | SetDrawer (const Handle< MeshVS_Drawer > &newDr) |
| Change custom drawer More... | |
| void | SetExcluding (const Standard_Boolean state) |
Set excluding state. If it is Standard_True, the nodes or elements, processed by current builder <br> will be noted and next builder won't process its. | |
| Standard_Boolean | IsExcludingOn () const |
| Read excluding state More... | |
| void | SetPresentationManager (const Handle< PrsMgr_PresentationManager3d > &thePrsMgr) |
| Set presentation manager for builder More... | |
| Handle_PrsMgr_PresentationManager3d | GetPresentationManager () const |
| Get presentation manager of builder More... | |
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... | |
Additional Inherited Members | |
Protected Member Functions inherited from MeshVS_PrsBuilder | |
| MeshVS_PrsBuilder (const Handle< MeshVS_Mesh > &Parent, const MeshVS_DisplayModeFlags &Flags, const Handle< MeshVS_DataSource > &DS, const Standard_Integer Id, const MeshVS_BuilderPriority &Priority=MeshVS_BP_Default) | |
Constructor <br> Parent is pointer to MeshVS_Mesh object | |
| Handle_MeshVS_DataSource | DataSource () const |
| Returns only custom data source More... | |
| Handle_MeshVS_Drawer | Drawer () const |
| Returns only custom drawer More... | |
Protected Attributes inherited from MeshVS_PrsBuilder | |
| MeshVS_MeshPtr | myParentMesh |
This class provides methods to create presentation of nodes with assigned color.
There are two ways of presentation building
| MeshVS_NodalColorPrsBuilder::MeshVS_NodalColorPrsBuilder | ( | const Handle< MeshVS_Mesh > & | Parent, |
| const MeshVS_DisplayModeFlags & | Flags = MeshVS_DMF_NodalColorDataPrs, |
||
| const Handle< MeshVS_DataSource > & | DS = 0, |
||
| const Standard_Integer | Id = -1, |
||
| const MeshVS_BuilderPriority & | Priority = MeshVS_BP_NodalColor |
||
| ) |
|
virtual |
Builds presentation of nodes with assigned color.
Implements MeshVS_PrsBuilder.
| Standard_Boolean MeshVS_NodalColorPrsBuilder::GetColor | ( | const Standard_Integer | ID, |
| Quantity_Color & | theColor | ||
| ) | const |
Returns color assigned to single node
| const Aspect_SequenceOfColor& MeshVS_NodalColorPrsBuilder::GetColorMap | ( | ) | const |
Return colors used for texrture presentation
| const MeshVS_DataMapOfIntegerColor& MeshVS_NodalColorPrsBuilder::GetColors | ( | ) | const |
Returns map of colors assigned to nodes.
| Quantity_Color MeshVS_NodalColorPrsBuilder::GetInvalidColor | ( | ) | const |
Return color representing invalid texture coordinate
(laying outside range [0, 1])
| Standard_Real MeshVS_NodalColorPrsBuilder::GetTextureCoord | ( | const Standard_Integer | theID | ) |
Return correspondence between node IDs and texture coordinate (range [0, 1])
| const TColStd_DataMapOfIntegerReal& MeshVS_NodalColorPrsBuilder::GetTextureCoords | ( | ) | const |
Get correspondence between node IDs and texture coordinates (range [0, 1])
| Standard_Boolean MeshVS_NodalColorPrsBuilder::HasColors | ( | ) | const |
Returns true, if map isn't empty
| Standard_Boolean MeshVS_NodalColorPrsBuilder::IsUseTexture | ( | ) | const |
Verify whether texture is used to build presentation
| void MeshVS_NodalColorPrsBuilder::SetColor | ( | const Standard_Integer | ID, |
| const Quantity_Color & | theColor | ||
| ) |
Sets color assigned to single node
| void MeshVS_NodalColorPrsBuilder::SetColorMap | ( | const Aspect_SequenceOfColor & | theColors | ) |
Set colors to be used for texrture presentation <br>
theColors - colors for valid coordinates (laying in range [0, 1])
| void MeshVS_NodalColorPrsBuilder::SetColors | ( | const MeshVS_DataMapOfIntegerColor & | Map | ) |
Sets map of colors assigned to nodes.
| void MeshVS_NodalColorPrsBuilder::SetInvalidColor | ( | const Quantity_Color & | theInvalidColor | ) |
Set color representing invalid texture coordinate
(laying outside range [0, 1])
| void MeshVS_NodalColorPrsBuilder::SetTextureCoord | ( | const Standard_Integer | theID, |
| const Standard_Real | theCoord | ||
| ) |
Specify correspondence between node ID and texture coordinate (range [0, 1])
| void MeshVS_NodalColorPrsBuilder::SetTextureCoords | ( | const TColStd_DataMapOfIntegerReal & | theMap | ) |
Specify correspondence between node IDs and texture coordinates (range [0, 1])
| void MeshVS_NodalColorPrsBuilder::UseTexture | ( | const Standard_Boolean | theToUse | ) |
Specify whether texture must be used to build presentation
1.8.5