CFx SDK Documentation  2023 SP0
Public Types | Public Member Functions | List of all members
OdGiFaceStyle Class Referenceabstract

#include <GiVisualStyle.h>

Inheritance diagram for OdGiFaceStyle:
OdRxObject OdStaticRxObject< OdGiFaceStyle > OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer

Public Types

enum  LightingModel { kInvisible = 0 , kConstant = 1 , kPhong = 2 , kGooch = 3 }
 
enum  LightingQuality { kNoLighting = 0 , kPerFaceLighting = 1 , kPerVertexLighting = 2 , kPerPixelLighting = 3 }
 
enum  FaceColorMode {
  kNoColorMode = 0 , kObjectColor = 1 , kBackgroundColor = 2 , kMono = 3 ,
  kTint = 4 , kDesaturate = 5
}
 
enum  FaceModifier { kNoFaceModifiers = 0 , kOpacity = 1 , kSpecular = 2 }
 

Public Member Functions

 ODRX_DECLARE_MEMBERS (OdGiFaceStyle)
 
void set (const OdGiFaceStyle &style)
 
OdGiFaceStyleoperator= (const OdGiFaceStyle &style)
 
bool operator== (const OdGiFaceStyle &style) const
 
virtual void setLightingModel (LightingModel lightingModel)=0
 
virtual LightingModel lightingModel () const =0
 
virtual void setLightingQuality (LightingQuality lightingQuality)=0
 
virtual LightingQuality lightingQuality () const =0
 
virtual void setFaceColorMode (FaceColorMode mode)=0
 
virtual FaceColorMode faceColorMode () const =0
 
virtual void setFaceModifiers (unsigned long nModifiers)=0
 
virtual void setFaceModifierFlag (FaceModifier flag, bool bEnable)=0
 
virtual unsigned long faceModifiers () const =0
 
virtual bool isFaceModifierFlagSet (FaceModifier flag) const =0
 
virtual void setOpacityLevel (double nLevel, bool bEnableModifier)=0
 
virtual double opacityLevel () const =0
 
virtual void setSpecularAmount (double nAmount, bool bEnableModifier)=0
 
virtual double specularAmount () const =0
 
virtual void setMonoColor (const OdCmColorBase &color, bool bEnableMode)=0
 
virtual const OdCmColorBasemonoColor () const =0
 
virtual OdCmColorBasemonoColor ()=0
 
- Public Member Functions inherited from OdRxObject
 ODRX_HEAP_OPERATORS ()
 
 OdRxObject ()
 
virtual ~OdRxObject ()
 
virtual OdRxObjectqueryX (const OdRxClass *pClass) const
 
virtual OdRxObjectx (const OdRxClass *pClass) const
 
virtual OdRxClassisA () const
 
virtual void addRef ()=0
 
virtual void release ()=0
 
virtual long numRefs () const
 
bool isKindOf (const OdRxClass *pClass) const
 
virtual OdRxObjectPtr clone () const
 
virtual void copyFrom (const OdRxObject *pSource)
 
virtual OdRx::Ordering comparedTo (const OdRxObject *pOther) const
 
virtual bool isEqualTo (const OdRxObject *pOther) const
 

Additional Inherited Members

- Static Public Member Functions inherited from OdRxObject
static OdRxObjectPtr cast (const OdRxObject *pointer)
 
static OdRxClassdesc ()
 

Detailed Description

This class represents a set of visual style properties that can be applied to the faces of graphical entities.

Corresponding C++ library: TD_Gi <group OdGi_Classes>

Definition at line 40 of file GiVisualStyle.h.

Member Enumeration Documentation

◆ FaceColorMode

Defines modifications that affect the color of a face before any lighting and shading calculations have been performed.

Enumerator
kNoColorMode 
kObjectColor 
kBackgroundColor 
kMono 
kTint 
kDesaturate 

Definition at line 70 of file GiVisualStyle.h.

◆ FaceModifier

Defines the modifiers applied to the faces using this face style.

Enumerator
kNoFaceModifiers 
kOpacity 
kSpecular 

Definition at line 83 of file GiVisualStyle.h.

◆ LightingModel

Defines the lighting model of the face style to apply to the faces of graphical entities.

Enumerator
kInvisible 
kConstant 
kPhong 
kGooch 

Definition at line 48 of file GiVisualStyle.h.

◆ LightingQuality

Defines the calculation method used for application of lighting effects to faces.

Enumerator
kNoLighting 
kPerFaceLighting 
kPerVertexLighting 
kPerPixelLighting 

Definition at line 59 of file GiVisualStyle.h.

Member Function Documentation

◆ faceColorMode()

virtual FaceColorMode OdGiFaceStyle::faceColorMode ( ) const
pure virtual

Returns the currently used face color mode value.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ faceModifiers()

virtual unsigned long OdGiFaceStyle::faceModifiers ( ) const
pure virtual

Returns the collection of currently used face modifier flags.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ isFaceModifierFlagSet()

virtual bool OdGiFaceStyle::isFaceModifierFlagSet ( FaceModifier  flag) const
pure virtual

Returns whether the specified face modifier flag is enabled.

Parameters
flag[in] Flag to be checked whether it's enabled or disabled.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ lightingModel()

virtual LightingModel OdGiFaceStyle::lightingModel ( ) const
pure virtual

Returns the currently used lighting model of the face style.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ lightingQuality()

virtual LightingQuality OdGiFaceStyle::lightingQuality ( ) const
pure virtual

Returns the currently used lighting quality of the face style.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ monoColor() [1/2]

virtual const OdCmColorBase& OdGiFaceStyle::monoColor ( ) const
pure virtual

Returns a color that is applied to produce a monochromatic effect on the faces.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ monoColor() [2/2]

virtual OdCmColorBase& OdGiFaceStyle::monoColor ( )
pure virtual

Returns a color that is applied to produce a monochromatic effect on the faces.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ ODRX_DECLARE_MEMBERS()

OdGiFaceStyle::ODRX_DECLARE_MEMBERS ( OdGiFaceStyle  )

◆ opacityLevel()

virtual double OdGiFaceStyle::opacityLevel ( ) const
pure virtual

Returns whether the opacity level is applied to faces.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ operator=()

OdGiFaceStyle& OdGiFaceStyle::operator= ( const OdGiFaceStyle style)

◆ operator==()

bool OdGiFaceStyle::operator== ( const OdGiFaceStyle style) const

◆ set()

void OdGiFaceStyle::set ( const OdGiFaceStyle style)

Copies values from the given face style to this face style.

Parameters
style[in] Reference to the OdGiFaceStyle to copy into this face style.

◆ setFaceColorMode()

virtual void OdGiFaceStyle::setFaceColorMode ( FaceColorMode  mode)
pure virtual

Sets the face color mode of the face style. All valid values are described in the FaceColorMode enum.

Parameters
mode[in] Face color mode value to set.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setFaceModifierFlag()

virtual void OdGiFaceStyle::setFaceModifierFlag ( FaceModifier  flag,
bool  bEnable 
)
pure virtual

Enables or disables the specified face modifier flag.

Parameters
flag[in] Flag to enable or disable.
bEnable[in] Value that indicates whether to enable or disable the specified flag.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setFaceModifiers()

virtual void OdGiFaceStyle::setFaceModifiers ( unsigned long  nModifiers)
pure virtual

Sets a collection of bitflags representing the face modifiers in effect.

Parameters
nModifiers[in] Unsigned long value that represents a collection of bitwise flags defined in the FaceModifier enum.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setLightingModel()

virtual void OdGiFaceStyle::setLightingModel ( LightingModel  lightingModel)
pure virtual

Sets the lighting model to the given value. All valid values are described in the LightingModel enumeration.

Parameters
lightingModel[in] Lighting model value to set.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setLightingQuality()

virtual void OdGiFaceStyle::setLightingQuality ( LightingQuality  lightingQuality)
pure virtual

Sets the lighting quality of faces to the given value. All valid values are described in the LightingQuality enum.

Parameters
lightingQuality[in] Lighting quality value to set.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setMonoColor()

virtual void OdGiFaceStyle::setMonoColor ( const OdCmColorBase color,
bool  bEnableMode 
)
pure virtual

Sets the color that will be applied to produce a monochromatic effect on the faces.

Parameters
color[in] Reference to an OdCmColorBase value to set.
bEnableMode[in] Value that indicates whether to enable or disable the mono color mode.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setOpacityLevel()

virtual void OdGiFaceStyle::setOpacityLevel ( double  nLevel,
bool  bEnableModifier 
)
pure virtual

Sets the opacity level of the faces.

Parameters
nLevel[in] Opacity level to set. Must be in the range from 0.0 (faces are fully transparent) to 1.0 (no transparency).
bEnableModifier[in] Value that indicates whether to enable or disable the opacity.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ setSpecularAmount()

virtual void OdGiFaceStyle::setSpecularAmount ( double  nAmount,
bool  bEnableModifier 
)
pure virtual

Sets the amount of specular highlight (indicating reflection and shininess values) of a faces material.

Parameters
nAmount[in] Amount of specular highlight of a faces material to set.
bEnableModifier[in] Value that indicates whether to enable or disable the specular highlight.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.

◆ specularAmount()

virtual double OdGiFaceStyle::specularAmount ( ) const
pure virtual

Returns the amount of specular highlight applied to a faces material.

Implemented in OdGiVisualStyleDataContainer::OdGiFaceStyleDataContainer.


The documentation for this class was generated from the following file: