All Frameworks Class Hierarchy This Framework Previous Next Indexes
VisualizationBase Class CATRep
System.IUnknown
|
+---System.IDispatch
|
+---System.CATBaseUnknown
|
+---CATRep
Usage: you must use this class as is. You should never derive it.
public class CATRep
Class to create a representation of an application object.
Role: This class is the base class for all representation classes,
necessary to visualize application objects.
Representations are organized into representation trees, possess graphic
attributes, and can be manipulated. This class defines these three basic
behaviors.
Predefined representations (for two dimensions and three dimensions spaces)
are available and should satisfy most of your needs.
Constructor and Destructor Index
- o
CATRep()
- Constructs a representation.
- o
~CATRep()
-
Method Index
- o
AddChild(CATRep&)
- Adds a child graphic representation.
- o
AddParent(CATRep&)
- Adds a specific representation to the list of parents.
- o
BuildHightlightLook(CATPathElement&,CATRepPath&)
- Sets the representation path for highlighted state (calls BuildRepPath by default).
- o
ComputeBoundingElement(int)
- Computes the bounding element of the representation.
- o
Destroy()
- Deletes the representation.
- o
GetChildren()
- Returns the list of children representations, if it exists.
- o
GetGraphicAttributeSet()
- Returns the associated set of graphic attributes.
- o
GetInheritanceMode()
- Returns the inheritance mode of the representation.
- o
GetIsValidTC()
- Return the validity of texture coordinates.
- o
GetManipulator()
- Returns the manipulator of the representation.
- o
GetMaterialInheritance()
- Returns the inheritance mode for the material of the rep.
- o
GetNbParents()
- Returns the number of parent representations.
- o
GetParentListCopy()
- Returns a list of parent representations.
- o
GetRepParents(int)
- Iteration method to retreive the parent representations.
- o
IsHidden()
- Indicates that the representation is hidden.
- o
IsOkToDraw(CATRender&,int)
- Tests whether the representation will draw its graphic primitives.
- o
RemoveChild(CATRep&)
- Removes a child representation.
- o
RemoveChildren(CATRep&)
- Removes a child representation but does not compute the new bounding element.
- o
RemoveParent(CATRep&)
- Removes a specific representation from the list of parents.
- o
SetColor(unsigned int)
- Sets the color of the representation.
- o
SetColorRGBA(unsigned int,unsigned int,unsigned int,unsigned int)
- Sets the color of the representation, in RGBA notation.
- o
SetFixedThickness(unsigned int)
- Sets the thickness used for drawing lines of the representation.
- o
SetGraphicAttributeSet(CATGraphicAttributeSet&)
- Sets the associated set of graphic attributes.
- o
SetHighlightMode(int,int)
- Sets the highlight mode of the representation.
- o
SetInheritanceMode(unsigned int)
- Sets the inheritance mode of the representation.
- o
SetIsValidTC(int)
- Sets the validity of texture coordinates.
- o
SetLineType(unsigned int)
- Sets the line type used for drawing lines of the representation.
- o
SetLowlightMode(unsigned int)
- Sets the lowlight mode of the representation.
- o
SetManipulator(CATManipulator*)
- Attach a manipulator to the representation.
- o
SetMaterialInheritance(int)
- Sets the heritance mode for material.
- o
SetPickMode(unsigned int)
- Sets the pick mode of the representation.
- o
SetShowFreeMode(unsigned int)
- Sets the show free mode of the representation.
- o
SetShowMode(int,int)
- Sets the show mode of the representation.
- o
SetThickness(unsigned int)
- Sets the thickness used for drawing lines of the representation.
- o
SetTransparentMode(unsigned int)
- Sets the transparency mode graphic attribute.
Constructor and Destructor
o CATRep
-
Constructs a representation.
o ~CATRep
-
Methods
o AddChild
-
Adds a child graphic representation.
Role: This method is not implemented on the current class.
- Parameters:
-
- iRep
- Child representation to be added.
o AddParent
public virtual void AddParent( | CATRep& | iParentRep) |
-
Adds a specific representation to the list of parents.
- Parameters:
-
- iParentRep
- The parent rep to be added.
o BuildHightlightLook
-
Sets the representation path for highlighted state (calls BuildRepPath by default).
- Parameters:
-
- iPathElement
-
- oRepPath
o ComputeBoundingElement
public virtual void ComputeBoundingElement( | int | iShowSpace | = 1) |
-
Computes the bounding element of the representation. The bounding element should be the smallest possible sphere containing the representation.
- Parameters:
-
- iShowSpace
-
Legal Values:
- 0 :
- 1 :
o Destroy
public virtual void Destroy( | ) |
-
Deletes the representation. Do not use the delete operator for this purpose.
o GetChildren
public virtual list * GetChildren() | |
-
Returns the list of children representations, if it exists.
The class remains owner of the list. Do not delete the list.
o GetGraphicAttributeSet
-
Returns the associated set of graphic attributes.
o GetInheritanceMode
public inline unsigned int GetInheritanceMode( | ) |
-
Returns the inheritance mode of the representation.
o GetIsValidTC
public virtual int GetIsValidTC( | ) |
-
Return the validity of texture coordinates.
o GetManipulator
-
Returns the manipulator of the representation.
o GetMaterialInheritance
public virtual int GetMaterialInheritance( | ) |
-
Returns the inheritance mode for the material of the rep.
o GetNbParents
public virtual int GetNbParents( | )const |
-
Returns the number of parent representations.
o GetParentListCopy
public virtual list* GetParentListCopy()const | |
-
Returns a list of parent representations.
The class is not owner of the returned list. It is your responsability to delete the list.
o GetRepParents
public virtual CATRep* GetRepParents( | int | index) const |
-
Iteration method to retreive the parent representations.
- Parameters:
-
- index
- the index of the parent representation you want to retrieve from the list of parents.
- Returns:
- NULL if index is negative or equal or superior to the number of parents The returned CATRep remains owned by this object . Do not delete it.
o IsHidden
public virtual int IsHidden( | ) |
-
Indicates that the representation is hidden.
o IsOkToDraw
public virtual int IsOkToDraw( | CATRender& | ioRender, |
| int | ioInside) |
-
Tests whether the representation will draw its graphic primitives.
- Returns:
-
- 0 : the representation must not be drawn
- 1 : the representation must be drawn
- Parameters:
-
- ioRender
- The render used to draw the representation.
- ioInside
- This parameter indicates whether the representation is fully in the view frustrum.
Legal values
- 0 : the representation is fully or partially out of the view frustrum.
Not all graphic primitives will be drawn.
- 1 : the representation is fully in the view frustrum.
All graphic primitives will be drawn.
o RemoveChild
public virtual void RemoveChild( | CATRep& | iRep) |
-
Removes a child representation.
Role: This method is not implemented on the current class.
- Parameters:
-
- iRep
- Child representation to be removed.
o RemoveChildren
public virtual void RemoveChildren( | CATRep& | iRep) |
-
Removes a child representation but does not compute the new bounding element.
Role: This method is not implemented on the current class.
- Parameters:
-
- iRep
- Child representation to be removed.
o RemoveParent
public virtual void RemoveParent( | CATRep& | iParentRep) |
-
Removes a specific representation from the list of parents.
- Parameters:
-
- iParentRep
- The parent rep to be removed.
o SetColor
public virtual void SetColor( | unsigned int | iColor) |
-
Sets the color of the representation.
- Parameters:
-
- iColor
- The index of the color. You can use predefined color
see
CATPredefinedColorName
o SetColorRGBA
public virtual void SetColorRGBA( | unsigned int | iRed, |
| unsigned int | iGreen, |
| unsigned int | iBlue, |
| unsigned int | iAlpha | = 255) |
-
Sets the color of the representation, in RGBA notation.
- Parameters:
-
- iRed
- The red component of the color must be in the range [0,255].
- iGreen
- The green component of the color must be in the range [0,255].
- iBlue
- The blue component of the color must be in the range [0,255].
- iAlpha
- The opacity component of the color must be in the range [0,255].
o SetFixedThickness
public virtual void SetFixedThickness( | unsigned int | iThickness) |
-
Sets the thickness used for drawing lines of the representation.
- Parameters:
-
- iThickness
- Indicates the width of the line in pixels in the range [1,8].
o SetGraphicAttributeSet
-
Sets the associated set of graphic attributes.
- Parameters:
-
- iGraphicAttributeSet
- The set of graphic attributes for the representation.
o SetHighlightMode
public virtual void SetHighlightMode( | int | iHighlightMode, |
| int | iPropagationMode | = 0) |
-
Sets the highlight mode of the representation.
- Parameters:
-
- iHighlightMode
-
Legal Values:
- 0 :
- 1 :
- iPropagationMode
-
Legal Values:
- 0 :
- 1 :
o SetInheritanceMode
public void SetInheritanceMode( | unsigned int | iInheritance) |
-
Sets the inheritance mode of the representation.
- Parameters:
-
- iInheritance
- iInheritance is a Bitwise OR of masks that indicates the children reps will automatically have this rep's color or/and line width or/and line type attributes as specified by
SetGraphicAttributeSet method. Legal values are :
- RESET_INHERITANCE : Stop all inheritance
- COLOR_INHERITANCE : Activate color inheritance
- LINEWIDTH_INHERITANCE : Activate line width inheritance
- LINETYPE_INHERITANCE : Activate line type inheritance
RESET_INHERITANCE is used to stop the inheritance.
o SetIsValidTC
public virtual void SetIsValidTC( | int | iState) |
-
Sets the validity of texture coordinates.
- Parameters:
-
- iState
-
- 0 : TC invalid, they will be computed at next Draw
- 1 : TC valid
o SetLineType
public virtual void SetLineType( | unsigned int | iLineType) |
-
Sets the line type used for drawing lines of the representation.
- Parameters:
-
- iLineType
- Legal values are :
- 1 : solid
- 2 : dotted
- 3 : dashed
- 4 : dot-dashed
- 5 : phantom
o SetLowlightMode
public virtual void SetLowlightMode( | unsigned int | iLowlightMode) |
-
Sets the lowlight mode of the representation.
- Parameters:
-
- iLowlightMode
-
- 0 : representation is drawn normally
- 1 : representation is drawn in lowlight
o SetManipulator
-
Attach a manipulator to the representation.
- Parameters:
-
- iManipulator
- Manipulator of the representation.
o SetMaterialInheritance
public virtual void SetMaterialInheritance( | int | iInheritance) |
-
Sets the heritance mode for material.
- Parameters:
-
- iInheritance
-
- MATERIAL_NOT_INHERIT : children reps will not have this rep's material
- MATERIAL_INHERIT : children reps will have automaticly this rep's material
- MATERIAL_FORCE_INHERIT : same as INHERIT, but even when a father has the INHERIT flag
o SetPickMode
public virtual void SetPickMode( | unsigned int | iPickMode) |
-
Sets the pick mode of the representation.
- Parameters:
-
- iPickMode
-
- 0 : representation is pickable
- 1 : representation is not pickable
o SetShowFreeMode
public virtual void SetShowFreeMode( | unsigned int | iShowFreeMode) |
-
Sets the show free mode of the representation.
- Parameters:
-
- iShowFreeMode
-
- 0 : the show/noshow parameter of the representation is taken into account
- 1 : the show/noshow parameter of the representation is not taken into account
o SetShowMode
public virtual void SetShowMode( | int | iShowMode, |
| int | iPropagationMode | = 0) |
-
Sets the show mode of the representation.
- Parameters:
-
- iShowMode
-
Legal Values:
- 0 :
- 1 :
- iPropagationMode
-
Legal Values:
- 0 :
- 1 :
o SetThickness
public virtual void SetThickness( | unsigned int | iThickness) |
-
Sets the thickness used for drawing lines of the representation.
- Parameters:
-
- iThickness
- Indicates the index width of the line in the range [1,55].
This index is pointing on the true width in pixel, recorded in the standard
(if there is one in the document) or in the setting.
o SetTransparentMode
public virtual void SetTransparentMode( | unsigned int | iTransparentMode) |
-
Sets the transparency mode graphic attribute.
- Parameters:
-
- iTransparentMode
-
Legal Values:
- 0 : transparency is disabled
- 1 : transparency is eneabled
.
This object is included in the file: CATRep.h
If needed, your Imakefile.mk should include the module: CATViz