/////////////////////////////////////////////////////////////////////////////// // Copyright (C) 2002-2025, Open Design Alliance (the "Alliance"). // All rights reserved. // // This software and its documentation and related materials are owned by // the Alliance. The software may only be incorporated into application // programs owned by members of the Alliance, subject to a signed // Membership Agreement and Supplemental Software License Agreement with the // Alliance. The structure and organization of this software are the valuable // trade secrets of the Alliance and its suppliers. The software is also // protected by copyright law and international treaty provisions. Application // programs incorporating this software must include the following statement // with their copyright notices: // // This application incorporates Open Design Alliance software pursuant to a license // agreement with Open Design Alliance. // Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance. // All rights reserved. // // By use of this software, its documentation or related materials, you // acknowledge and accept the above terms. /////////////////////////////////////////////////////////////////////////////// // Basic draw order support for devices based on own display lists #ifndef ODEXDRAWORDERBASE #define ODEXDRAWORDERBASE #include "TD_PackPush.h" #include "Gs/GsBaseInclude.h" #include "Gs/GsBaseMaterialView.h" #include "Gs/GsBaseModelReactor.h" #include "OdVector.h" #define STL_USING_MAP #define STL_USING_SET #include "OdaSTL.h" class OdDrawOrderBaseDevice; /** \details */ struct OdDrawOrderBaseDeviceMCCallback { typedef void (*onDeleteRequestProc)(OdDrawOrderBaseDevice *pDevice, void *pData); virtual void onDeleteRequest(onDeleteRequestProc pReqProc, void *pData, void *pArg = nullptr) = 0; }; #ifdef _MSC_VER #pragma warning (push) #pragma warning (disable : 4100) #endif /** \details */ class OdDrawOrderBaseDevice : public OdGsBaseVectorizeDevice , protected OdDrawOrderBaseDeviceMCCallback { public: struct MetafileContext : public OdRxObject { OdDrawOrderBaseDeviceMCCallback *m_pDevice; OdRxObjectPtr m_pMetafilePool; }; typedef OdSmartPtr MetafileContextPtr; protected: MetafileContextPtr m_pMetafileContext; public: ODRX_USING_HEAP_OPERATORS(OdGsBaseVectorizeDevice); /** \details Default constructor for the OdDrawOrderBaseDevice class. */ OdDrawOrderBaseDevice(); /** \details Destructor for the OdDrawOrderBaseDevice class. */ ~OdDrawOrderBaseDevice() override; /** \details Returns the metafile context object associated with the device. \returns Pointer to the MetafileContext instance. */ MetafileContext *metafileContext() { return m_pMetafileContext.get(); } /** \details Releases currently associated metafile context. */ void releaseMetafileContext(); /** \details Updates the GUI window (or its region) associated with the device object. \param pUpdatedRect [in] A pointer to the rectangle object that represents the window region to be updated. \remarks The method affects all OdGsView objects owned by the device object, and so it displays the correct image on the GUI window (or its region). If the pointer to a window region (the pUpdatedRect parameter value) is NULL, the whole window is updated. \sa Redrawing Content of a Device */ void update(OdGsDCRect* pUpdatedRect = 0) override; /** \details Checks whether draw order mode is enabled for partial update of the device. \returns By default returns false. */ virtual bool drawOrderForPartialUpdate() const { return false; } // Callbacks /** \details Notification method called when new graphics metafile is added to the graphics scene. \param pMetafile [in] Pointer to a metafile. \param bVisible [in] Visibility flag for metafile graphics. \param bHighlighted [in] Highlight flag for metafile graphics. \remarks By default does nothing. */ virtual void onMetafileAdded(OdRxObject *pMetafile, bool bVisible, bool bHighlighted) { } /** \details Notification method called when a metafile is deleted. \param pMetafile [in] Pointer to a metafile. \remarks By default does nothing. */ virtual void onMetafileDeleted(OdRxObject *pMetafile) { } /** \details Notification method called when a metafile highlight status is changed. \param pMetafile [in] Pointer to a metafile. \param bSet [in] Highlight status. \remarks By default does nothing. */ virtual void onMetafileHighlightingChanged(OdRxObject *pMetafile, bool bSet) { } /** \details Notification method called when a metafile visibility status is changed. \param pMetafile [in] Pointer to a metafile. \param bSet [in] Visibility status. \remarks By default does nothing. */ virtual void onMetafileVisibilityChanged(OdRxObject *pMetafile, bool bSet) { } /** \details Notification method called when a metafile fading status is changed. \param pMetafile [in] Pointer to a metafile. \param bSet [in] Fading status. \remarks By default does nothing. */ virtual void onMetafileFadingChanged(OdRxObject *pMetafile, bool bSet) { } /** \details Notification method called when a metafile selection style is changed. \param pMetafile [in] Pointer to a metafile. \param nStyle [in] Selection style index. \remarks By default does nothing. */ virtual void onMetafileSelectionStyleChanged(OdRxObject *pMetafile, OdUInt32 nStyle) { } // Default callback impl /** \details Notification method called on the delete request. \param pReqProc [in] Processes the delete request. \param pData [in] Data. \param pArg [in] Additional arguments. \remarks By default does nothing. */ void onDeleteRequest(onDeleteRequestProc pReqProc, void *pData, void *pArg = nullptr) override { pReqProc(this, (pArg) ? pArg : pData); } protected: // Process synchronization with all dependent devices/views virtual void sync(); // Preprocess synchronization for all dependent views virtual void preprocess(); virtual void syncView(int id); virtual void preprocessView(int id); //SEA Draw order inheritance enum { kFirstFlag = OdGsBaseVectorizeDevice::kLastFlag, kCheckDrawOrderInheritanceFlag = kFirstFlag << 1 }; public: void setCheckDrawOrderInheritance( bool bSet ) { SETBIT( m_flags, kCheckDrawOrderInheritanceFlag, bSet ); } bool isCheckDrawOrderInheritance() const { return GETBIT( m_flags, kCheckDrawOrderInheritanceFlag ); } }; /** \details */ class OdDrawOrderBaseView : public OdGsBaseVectorizeView , protected OdGsBaseModelReactor { protected: enum DrawablesFlags { kStateModified = (1 << 0), // display list doesn't changed, required only state (highlight, visibility) check kPartialRegeneration = (1 << 1), // require partial comparison of display list kFullRegeneration = (1 << 2), // require full display list rebuild kStateModifiedTransformOnly = (1 << 3) //display list doesn't changed, only transform state check }; struct DrawableInfo { enum DrawableType { kTransient = 0, // No cache kContainer, // GsContainerNode kPersistent // GsEntityNode } m_type; // Need to check correctness OdDbStub* m_drawableId; const OdGiDrawable *m_pDrawable; const OdGsBaseModel *m_pGsModel; // Flags OdUInt32 m_flags; // Positions in display list OdUInt32 m_nFrom, m_nLen; // Link index with view drawables holder OdUInt32 m_nLink; }; struct ViewInfo { OdGsView::RenderMode m_mode; OdGiRegenType m_regenType; OdDbStub* m_annoScale; ViewInfo(); }; ViewInfo m_viewInfo; struct DrawOrderOverlayData : public GsViewOverlayData { OdArray > m_drawableInfo; OdUInt64Vector m_metafileOrder; OdUInt64Vector m_metafileOrderAccum; bool m_bMetafileOrderValid; OdUInt32 m_nInvalidFrom, m_nInvalidLen; OdUInt32 m_nValidFrom, m_nValidLen; const OdDrawOrderBaseView* m_pConnectedView; bool m_bBreakInheritance; DrawOrderOverlayData() : m_bMetafileOrderValid( false ), m_nInvalidFrom(0), m_nInvalidLen( 0 ), m_nValidFrom( 0 ), m_nValidLen( 0 ), m_pConnectedView( NULL ), m_bBreakInheritance( false ) {} }; struct DrawOrderOverlayDataAllocator : public GsViewOverlayDataContainer::Allocator #ifdef __hpux , public GsViewOverlayData #endif { GsViewOverlayData *createData() override { return new DrawOrderOverlayData(); } void deleteData(GsViewOverlayData *pData) override { delete static_cast(pData); } } m_overlayAlloc; DrawOrderOverlayData *getOverlayData(OdGsOverlayId nOverlay) { return static_cast(m_overlayData.getOverlayData(nOverlay)); } struct ModelRef { enum { kHighlighted = 1, kHidden = 2, kTransformed = 4 }; OdUInt32 nRefs, nFlags; ModelRef() : nRefs(0), nFlags(0) { } }; std::map m_refModels; public: ODRX_USING_HEAP_OPERATORS(OdGsBaseVectorizeView); /** \details Default constructor for the OdDrawOrderBaseView class. */ OdDrawOrderBaseView(); /** \details Destructor for the OdDrawOrderBaseView class. */ ~OdDrawOrderBaseView() override; /** \details Returns a device associated with this view. \returns Pointer to OdDrawOrderBaseDevice instance that owns this view. */ OdDrawOrderBaseDevice* device(); /** \details Returns a sequence of integer values representing the draw order defined for the specified graphics overlay. \param nOverlay [in] Identifier of a graphics system overlay. \returns Pointer to a vector of integers that represent a draw order from a metafile. */ OdUInt64Vector *drawOrder(OdGsOverlayId nOverlay) { DrawOrderOverlayData *pData = getOverlayData(nOverlay); return (pData) ? &pData->m_metafileOrder : NULL; } OdUInt64Vector *drawOrderAccum(OdGsOverlayId nOverlay) { DrawOrderOverlayData *pData = getOverlayData(nOverlay); return (pData) ? &pData->m_metafileOrderAccum : NULL; } /** \details Invalides all overlay data associated with this view. This requires full display list rebuild. */ virtual void drawOrderInvalidate(); void clearDrawOrderAccums(); /** \details Synchronizes with an associated metafile in case it is modified (added/edited/erased/off/highlighted) */ virtual void sync(); virtual void preprocess(); /** \details Extracts lights in this view. \remarks The method creates a new vectorizer associated with this view and calls the displayLights() method with this vectorizer. */ virtual void extractLights(); /** \details Displays lights. \param vec [in] Vectorizer. */ virtual void displayLights(OdGsBaseVectorizer &vec); /** \details Adds the specified scene graph to this view. \param pSceneGraph [in] Pointer to the root of the scene graph. \param pModel [in] Pointer to the Model object to which all scene graph notifications are to be directed. \returns true if successful, false otherwise. \remarks This function is intended to be used as follows: 1. Construct a scene graph of OdGiDrawable objects. Each object draws its children with OdGiGeometry::draw(). 2. With this function, add the root of the scene graph and the OdGsModel that handles notifications to this Viewport object. */ bool add(OdGiDrawable* pSceneGraph, OdGsModel* pModel) override; /** \details Removes the specified scene graph from this view. \param sceneGraph [in] Pointer to the root of the scene graph. \returns true if successful, false otherwise. */ bool erase(OdGiDrawable* sceneGraph) override; /** \details Removes all scene graphs from this Viewport object. */ void eraseAll() override; /** \details Notification method that is called whenever GsModel is highlighted or un-highlighted. \param pModel [in] Pointer to the model. \param path [in] Path node to highlight. \param bDoIt [in] Enables or disables highlighting. \param nStyle [in] Selection style index. \param pView [in] Pointer to the view in which model is highlighted. \returns By default returns true. */ bool onHighlight(OdGsModel *pModel, const OdGiPathNode& path, bool bDoIt, OdUInt32 &nStyle, const OdGsView* pView) override; /** \details Notification method that is called whenever GsModel is highlighted or un-highlighted. \param pModel [in] Pointer to the model. \param path [in] Path node to highlight. \param pMarkers [in] Pointer to an array of markers. \param nMarkers [in] Number of markers. \param bDoIt [in] Enables or disables highlighting. \param nStyle [in] Selection style index. \param pView [in] Pointer to the view in which model is highlighted. \returns By default returns true. */ bool onHighlight(OdGsModel *pModel, const OdGiPathNode& path, const OdGsMarker* pMarkers, OdUInt32 nMarkers, bool bDoIt, OdUInt32 &nStyle, const OdGsView* pView) override; /** \details Notification method that is called whenever GsModel is hidden or un-hidden. \param pModel [in] Pointer to the model. \param pNode [in] Pointer to Gs node. \param bHidden [in] Flag that specifies whether model is hidden. \param bSelectable [in] Flag that shows whether model is selectable. \param pView [in] Pointer to the view in which model is hidden. \returns By default returns true. */ bool onHide(OdGsModel *pModel, OdGsNode *pNode, bool &bHidden, bool &bSelectable, const OdGsView* pView) override; /** \details Notification method that is called whenever GsModel is hidden or un-hidden. \param pModel [in] Pointer to the model. \param pNode [in] Pointer to Gs node. \param pMarkers [in] Pointer to an array of markers. \param nMarkers [in] Number of markers. \param bHidden [in] Flag that specifies whether model is hidden. \param bSelectable [in] Flag that shows whether model is selectable. \param pView [in] Pointer to the view in which model is hidden. \returns By default returns true. */ bool onHide(OdGsModel *pModel, const OdGiPathNode& path, const OdGsMarker* pMarkers, OdUInt32 nMarkers, bool& bHidden, bool &bSelectable, const OdGsView* pView) override; bool onExternalTransform(OdGsModel *pModel, const OdGiPathNode &path, bool bDoIt, const OdGsMatrixParamPtr &xForm, const OdGsView *pView) override; bool onExternalTransform(OdGsModel *pModel, const OdGiPathNode &path, const OdGsMarker *pMarkers, OdUInt32 nMarkers, bool bDoIt, const OdGsMatrixParamPtr &xForm, const OdGsView *pView) override; /** \details Notification method that is called whenever a drawable object is erased from the Model object. \param pModel [in] Pointer to the model. \param pErased [in] Pointer to the erased Drawable object. \param pParent [in] Pointer to the parent of the erased Drawable object. \returns By default returns true. */ bool onErased(OdGsModel *pModel, OdGiDrawable *pErased, OdGiDrawable *pParent) override; /** \details Notification method that is called whenever a drawable object is erased from the Model object. \param pModel [in] Pointer to the model. \param pErased [in] Pointer to the erased Drawable object. \param parentID [in] Object ID of the parent of the erased Drawable object. \returns By default returns true. */ bool onErased(OdGsModel *pModel, OdGiDrawable *pErased, OdDbStub *parentID) override; //virtual bool onInvalidate(OdGsModel *pModel, OdGsView* pView); // Callbacks /** \details Notification method that is called whenever a metafiles rendering list is changed. \param nOverlay [in] Identifier of overlay buffer contains viewport to modify metafiles list. \param pFullDrawOrder [in] Pointer to the draw order sequence. \param nFullDrawOrder [in] Length of the draw order sequence. \returns By default does nothing. */ virtual void onMetafileOrderChanged(OdGsOverlayId nOverlay, const OdUInt64 *pFullDrawOrder, OdUInt32 nFullDrawOrder) { } /** \details Notification method that is called whenever a metafiles rendering list is changed. \param nOverlay [in] Identifier of overlay buffer contains viewport to modify metafiles list. \param nInvalidFrom [in] Position of the invalid sequence. \param nInvalidLen [in] Length of the invalid sequence. \param pValidOrderPart [in] Pointer to the valid draw order sequence. \param nValidLen [in] Length of the valid draw order sequence. \returns By default does nothing. */ virtual void onMetafileOrderChanged(OdGsOverlayId nOverlay, OdUInt32 nInvalidFrom, OdUInt32 nInvalidLen, const OdUInt64 *pValidOrderPart, OdUInt32 nValidLen) { } /** \details Notification method that is called whenever a metafiles rendering list is shared between different viewports instead of creating rendering lists for each viewport of vectorizer. \param overlayId [in] Identifier of overlay buffer that contains viewport that can use foreign rendering list and viewport. \param viewportId2 [in] Pointer to a viewport whose rendering list can be used as foreign. \returns By default does nothing. */ virtual void onMetafileOrderInheritance( OdGsOverlayId overlayId, const OdGsView* viewportId2 ) {} protected: //DOM-IGNORE-BEGIN virtual void onGsModelLinkAdded(OdGsModel *pModel); virtual void onGsModelLinkErased(OdGsModel *pModel); bool viewChangesAndUpdate(); //SEA List cmp enum DiffAction { kNoChanges = 0, kAdd, kRemove }; class ActionSequence { public: struct ConvertorAction { DiffAction m_action; OdUInt32 m_nCount; ConvertorAction* m_pNext; ConvertorAction* m_pPrev; ConvertorAction() : m_pNext( NULL ), m_pPrev( NULL ) { m_nCount = 0; m_action = kNoChanges; } }; public: ActionSequence(); ~ActionSequence(); void addAction( DiffAction action, OdUInt32 count = 1 ); ConvertorAction* top() { return m_pFirst; } void clear(); protected: ConvertorAction* m_pFirst; ConvertorAction* m_pLast; }; class MapBasedComparer { public: MapBasedComparer(); ~MapBasedComparer(); void setOriginal( const OdUInt64* pList, OdUInt32 size, OdUInt32 offset = 0 ); void diff( const OdUInt64* pList, OdUInt32 size, ActionSequence& as ); protected: struct Options { OdUInt32 m_pos; bool m_bTouched; Options( OdUInt32 pos ) { m_pos = pos; m_bTouched = false; }; Options() { }; }; std::map< OdUInt64, Options > m_map; std::set< OdUInt32 > m_removeSet; }; MapBasedComparer m_mbCmp; ActionSequence m_diffActions; void listCmp( OdUInt64Vector& originalList, OdUInt64Vector& newList, OdUInt32 nDrawInfo, DrawableInfo* drawInfo, ActionSequence& result ); //DOM-IGNORE-END protected: //SEA virtual bool isContentCompatibleOverlay( const OdDrawOrderBaseView* pView, const DrawOrderOverlayData* pOverlayData, OdGsOverlayId overId ) const; virtual bool isMetafilesCompatibleOverlays( OdGsOverlayId overId1, const OdDrawOrderBaseView* pView2 ); public: virtual void breakOverlayCompatibility(); virtual void breakOverlayCompatibility( OdGsOverlayId nOverlay ); }; #ifdef _MSC_VER #pragma warning (pop) #endif /** \details */ class OdDrawOrderBaseVectorizer : public OdGsBaseMaterialViewPC { protected: OdUInt64Vector *m_pCurDrawOrderAccum; OdRxObjectPtr m_curRecordingMetafile; bool m_bDisableNesting, m_bDisableOffLayersVisibility; public: /** \details Default constructor for the OdDrawOrderBaseVectorizer class. */ OdDrawOrderBaseVectorizer(); /** \details Destructor for the OdDrawOrderBaseVectorizer class. */ ~OdDrawOrderBaseVectorizer() override; /** \details Returns device associated with this vectorizer. \returns Pointer to the OdDrawOrderBaseDevice instance associated with this vectorizer. */ OdDrawOrderBaseDevice* device(); /** \details Returns view associated with this vectorizer. \returns Reference to the OdDrawOrderBaseView instance associated with this vectorizer. */ OdDrawOrderBaseView& view() const; virtual void drawOrderQuery(bool bContainer, bool bDisableNested = false); OdUInt64Vector *drawOrderAccum(OdGsOverlayId nOverlay) { return view().drawOrderAccum(nOverlay); } OdUInt64Vector *activeDrawOrderAccum() { return m_pCurDrawOrderAccum; } /** \details Displays lights. */ virtual void displayLights(); // Vectorizer overrides void display(bool update) override; void switchOverlay(OdGsOverlayId overlayId) override; // Metafiles /** \details Returns a smart pointer to the newly created metafile object. \returns Smart pointer to a created GS metafile. \remarks GsMetafiles are used to record vectorizations, and rapidly 'redraw' them to a display device. */ OdRxObjectPtr newGsMetafile() override; /** \details Begins vectorization to the specified metafile (cache) object. \param pMetafile [in] Pointer to the GsMetafile. \remarks GsMetafiles are used to record vectorizations, and rapidly 'redraw' them to a display device. */ void beginMetafile(OdRxObject* pMetafile) override; /** \details Ends vectorization to the specified metafile (cache) object. \param pMetafile [in] Pointer to the GsMetafile. \remarks GsMetafiles are used to record vectorizations, and rapidly 'redraw' them to a display device. */ void endMetafile(OdRxObject* pMetafile) override; /** \details Plays (redraws) the specified metafile (cache) object. \param pMetafile [in] Pointer to the GsMetafile. \remarks GsMetafiles are used to record vectorizations, and rapidly 'redraw' them to a display device. */ void playMetafile(const OdRxObject* pMetafile) override; /** \details Notification method called when new graphics metafile is added to the graphics scene. \param pMetafile [in] Pointer to a metafile. \param bVisible [in] Visibility flag for metafile graphics. \param bHighlighted [in] Highlight flag for metafile graphics. */ virtual void onMetafileAdded(OdRxObject *pMetafile, bool bVisible, bool bHighlighted); }; /** \details Structure that represents base properties of metafiles. */ struct OdDrawOrderMetafileBase : public OdRxObject { enum MetafileFlagsBase { kIsArray = (1 << 0), kLastFlag = (kIsArray << 1) }; OdIntPtr m_pPtr; OdUInt16 m_flags; OdUInt16 m_refIndex; OdUInt32 m_refCounter; void setIsArray(bool bSet) { SETBIT(m_flags, kIsArray, bSet); } bool isArray() const { return GETBIT(m_flags, kIsArray); } void setRefIndex(OdUInt32 refIndex) { m_refIndex = (OdUInt16)refIndex; } OdUInt32 refIndex() const { return m_refIndex; } bool hasRefIndex() const { return m_refIndex != 0; } OdDrawOrderMetafileBase() : m_pPtr(0) , m_flags(0) , m_refIndex(0) , m_refCounter(0) { } void clear() { m_pPtr = 0; m_flags = m_refIndex = 0; m_refCounter = 0; } }; /** \details */ struct OdDrawOrderBaseMetafile : public OdDrawOrderMetafileBase { /** \details Represents metafile flags. */ enum MetafileFlags { kFilled = (OdDrawOrderMetafileBase::kLastFlag << 0), // Marks completed metafile (endMetafile called) kVisible = (OdDrawOrderMetafileBase::kLastFlag << 1), // Marks metafiles on enabled layer kHighlighted = (OdDrawOrderMetafileBase::kLastFlag << 2), // Marks completely highlighted metafiles kNested = (OdDrawOrderMetafileBase::kLastFlag << 3), // Marks nested metafiles kFaded = (OdDrawOrderMetafileBase::kLastFlag << 4), // Marks faded metafiles kEmpty = (OdDrawOrderMetafileBase::kLastFlag << 5), // Marks metafiles which doesn't contain any visible geometry kLastFlag = (kEmpty << 1) }; /** Smart pointer to metafile context. */ OdDrawOrderBaseDevice::MetafileContextPtr m_pContext; /** Visual display identifier. */ OdUInt64 m_visualId; /** Layer node. */ OdGsLayerNode *m_pLayer; /** \details Default constructor for the OdDrawOrderBaseMetafile class. */ OdDrawOrderBaseMetafile(); /** \details Destructor for the OdDrawOrderBaseMetafile class. */ ~OdDrawOrderBaseMetafile() override; void clear(); /** \details Checks whether the metafile is completed. \returns true if the metafile is filled, false otherwise. */ bool isFilled() const { return GETBIT(m_flags, kFilled); } /** \details Enables the kFilled flag for the metafile. */ void setFilled() { SETBIT_1(m_flags, kFilled); } /** \details Checks whether the metafile is visibile on the layer. \returns true if the metafile is visibile on the layer, false otherwise. */ bool isVisible() const { return GETBIT(m_flags, kVisible); } /** \details Sets the kVisible flag for the metafile. \param bSet [in] Status of the kVisible flag. */ void setVisible(bool bSet) { SETBIT(m_flags, kVisible, bSet); } /** \details Checks whether the metafile is highlighted. \returns true if the metafile is highlighted, false otherwise. */ bool isHighlighted() const { return GETBIT(m_flags, kHighlighted); } /** \details Sets the kHighlighted flag for the metafile. \param bSet [in] Status of the kHighlighted flag. */ void setHighlighted(bool bSet) { SETBIT(m_flags, kHighlighted, bSet); } /** \details Checks whether the metafile is nested. \returns true if the metafile is nested, false otherwise. */ bool isNested() const { return GETBIT(m_flags, kNested); } /** \details Marks this metafile as nested. */ void setNested() { SETBIT_1(m_flags, kNested); } /** \details Checks whether the metafile is faded. \returns true if the metafile is faded, false otherwise. */ bool isFaded() const { return GETBIT(m_flags, kFaded); } /** \details Sets the kFaded flag for the metafile. \param bSet [in] Status of the kFaded flag. */ void setFaded(bool bSet) { SETBIT(m_flags, kFaded, bSet); } /** \details Checks whether the metafile doesn't contain any visible geometry. \returns true if the metafile doesn't contain any visible geometry, false otherwise. */ bool isEmpty() const { return GETBIT(m_flags, kEmpty); } /** \details Sets the kEmpty flag for the metafile. */ void setEmpty() { SETBIT_1(m_flags, kEmpty); } static void onMetafileDeleteRequestProc(OdDrawOrderBaseDevice *pDevice, void *pData); /** \details Creates an instance of this class. \param pContext [in] Pointer to metafile context. \returns Smart ponter to this OdDrawOrderBaseMetafile. */ static OdRxObjectPtr createObject(OdDrawOrderBaseDevice::MetafileContext *pContext); }; #include "TD_PackPop.h" #endif // ODEXDRAWORDERBASE