// This file is generated by WOK (CPPExt). // Please do not edit this file; modify original file instead. // The copyright and license terms as defined for the original file apply to // this header file considered to be the "object code" form of the original source. #ifndef _Graphic3d_AspectFillArea3d_HeaderFile #define _Graphic3d_AspectFillArea3d_HeaderFile #ifndef _Standard_HeaderFile #include #endif #ifndef _Standard_DefineHandle_HeaderFile #include #endif #ifndef _Handle_Graphic3d_AspectFillArea3d_HeaderFile #include #endif #ifndef _Standard_Boolean_HeaderFile #include #endif #ifndef _Handle_Graphic3d_TextureMap_HeaderFile #include #endif #ifndef _Graphic3d_MaterialAspect_HeaderFile #include #endif #ifndef _Aspect_TypeOfDegenerateModel_HeaderFile #include #endif #ifndef _Quantity_Ratio_HeaderFile #include #endif #ifndef _Standard_Integer_HeaderFile #include #endif #ifndef _Standard_Real_HeaderFile #include #endif #ifndef _Aspect_AspectFillArea_HeaderFile #include #endif #ifndef _Aspect_InteriorStyle_HeaderFile #include #endif #ifndef _Aspect_TypeOfLine_HeaderFile #include #endif class Graphic3d_TextureMap; class Quantity_Color; class Graphic3d_MaterialAspect; //! This class permits the creation and updating of
//! a graphic attribute context for opaque 3d
//! primitives (polygons, triangles, quadrilaterals)
//! Keywords: Face, FillArea, Triangle, Quadrangle, Polygon,
//! TriangleMesh, QuadrangleMesh, Edge, Border, Interior,
//! Color, Type, Width, Style, Hatch, Material,
//! BackFaceRemoval, DistinguishMode
class Graphic3d_AspectFillArea3d : public Aspect_AspectFillArea { public: //! Creates a context table for fill area primitives
//! defined with the following default values:
Standard_EXPORT Graphic3d_AspectFillArea3d(); //! Creates a context table for fill area primitives
//! defined with the specified values.
Standard_EXPORT Graphic3d_AspectFillArea3d(const Aspect_InteriorStyle Interior,const Quantity_Color& InteriorColor,const Quantity_Color& EdgeColor,const Aspect_TypeOfLine EdgeLineType,const Standard_Real EdgeWidth,const Graphic3d_MaterialAspect& FrontMaterial,const Graphic3d_MaterialAspect& BackMaterial); //! Allows the display of back-facing filled
//! polygons.
Standard_EXPORT void AllowBackFace() ; //! Modifies the surface material of internal faces
Standard_EXPORT void SetBackMaterial(const Graphic3d_MaterialAspect& AMaterial) ; //! Allows distinction between external and internal
//! faces of FillAreas.
Standard_EXPORT void SetDistinguishOn() ; //! Forbids distinction between external and internal
//! faces of FillAreas.
Standard_EXPORT void SetDistinguishOff() ; //! The edges of FillAreas are drawn.
Standard_EXPORT void SetEdgeOn() ; //! The edges of FillAreas are not drawn.
Standard_EXPORT void SetEdgeOff() ; //! Modifies the surface material of external faces
Standard_EXPORT void SetFrontMaterial(const Graphic3d_MaterialAspect& AMaterial) ; //! Suppress the display of back-facing filled
//! polygons.
//! A back-facing polygon is defined as a polygon whose
//! vertices are in a clockwise order with respect
//! to screen coordinates.
Standard_EXPORT void SuppressBackFace() ; Standard_EXPORT void SetTextureMap(const Handle(Graphic3d_TextureMap)& ATexture) ; Standard_EXPORT void SetTextureMapOn() ; Standard_EXPORT void SetTextureMapOff() ; //! Sets the default model of degeneration for the polygons
//! which is taking in account at creation time of any
//! graphic structure until the model is change using
//! SetDegenerateModel() method.
Standard_EXPORT static void SetDefaultDegenerateModel(const Aspect_TypeOfDegenerateModel aModel = Aspect_TDM_WIREFRAME,const Quantity_Ratio aRatio = 0.0) ; //! Sets the model of degeneration for the polygons
//! according to the degenerate ratio >= 0. & <= 1. where :
//! = 0. indicate that all polygons of the graphic structure
//! are displayed.
//! = 1. indicate that nothing is displayed in the graphic
//! structure.
//! When is > 0 & < 1. the corresponding amount
//! of polygons are displayed in the graphic structure with a
//! random method.
//! Warning: the degenerate structure is shown only when
//! the animation and degenerate flags are set to TRUE
//! in V3d_View::SetAnimationMode(..)
Standard_EXPORT void SetDegenerateModel(const Aspect_TypeOfDegenerateModel aModel = Aspect_TDM_WIREFRAME,const Quantity_Ratio aRatio = 0.0) ; //! Sets up OpenGL polygon offsets mechanism.
//! parameter can contain various combinations of
//! Aspect_PolygonOffsetMode enumeration elements (Aspect_POM_None means
//! that polygon offsets are not changed).
//! If is different from Aspect_POM_Off and Aspect_POM_None, then and
//! arguments are used by graphic renderer to calculate a depth offset value:
//!
//! offset = * m + * r, where
//! m - maximum depth slope for the polygon currently being displayed,
//! r - minimum window coordinates depth resolution (implementation-specific)
Standard_EXPORT void SetPolygonOffsets(const Standard_Integer aMode,const Standard_Real aFactor = 1.0,const Standard_Real aUnits = 0.0) ; //! Returns the Back Face Removal status.
//! Standard_True if SuppressBackFace is activated.
Standard_EXPORT Standard_Boolean BackFace() const; //! Returns the Distinguish Mode status.
Standard_EXPORT Standard_Boolean Distinguish() const; //! Returns Standard_True if the edges are drawn and
//! Standard_False if the edges are not drawn.
Standard_EXPORT Standard_Boolean Edge() const; //! Returns the surface material of internal faces
Standard_EXPORT Graphic3d_MaterialAspect BackMaterial() const; //! Returns the surface material of external faces
Standard_EXPORT Graphic3d_MaterialAspect FrontMaterial() const; Standard_EXPORT Handle_Graphic3d_TextureMap TextureMap() const; Standard_EXPORT Standard_Boolean TextureMapState() const; //! returns the current degeneration model and ratio
//! for the polygons
Standard_EXPORT Aspect_TypeOfDegenerateModel DegenerateModel(Quantity_Ratio& aRatio) const; //! returns the default degeneration model and ratio
//! for the polygons
Standard_EXPORT static Aspect_TypeOfDegenerateModel DefaultDegenerateModel(Quantity_Ratio& aRatio) ; //! Returns current polygon offsets settings.
Standard_EXPORT void PolygonOffsets(Standard_Integer& aMode,Standard_Real& aFactor,Standard_Real& aUnits) const; DEFINE_STANDARD_RTTI(Graphic3d_AspectFillArea3d) protected: private: Standard_Boolean DistinguishModeActive; Standard_Boolean EdgeModeActive; Standard_Boolean BackFaceRemovalActive; Handle_Graphic3d_TextureMap MyTextureMap; Standard_Boolean MyTextureMapState; Graphic3d_MaterialAspect MyFrontMaterial; Graphic3d_MaterialAspect MyBackMaterial; Aspect_TypeOfDegenerateModel MyDegenerateModel; Quantity_Ratio MyDegenerateRatio; Standard_Integer MyPolygonOffsetMode; Standard_Real MyPolygonOffsetFactor; Standard_Real MyPolygonOffsetUnits; }; // other Inline functions and methods (like "C++: function call" methods) #endif