/////////////////////////////////////////////////////////////////////////////// // 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. /////////////////////////////////////////////////////////////////////////////// #ifndef _ODTV_MODELEXPLODE_H_INCLUDED_ #define _ODTV_MODELEXPLODE_H_INCLUDED_ #include "TvToolsExport.h" // Visualize SDK #include "TvEntity.h" #include "TvInsert.h" #include "TvModel.h" #define STL_USING_VECTOR #include "OdaSTL.h" struct TransformData; class OdTvModelExplode; /** \details A data type that represents a smart pointer to an object. */ typedef OdSharedPtr OdTvModelExplodePtr; /** \details This class implements methods for explode model. */ class ODTVTOOLS_EXPORT OdTvModelExplode { public: /** \details Constructs the OdTvModelExplode object. \param modelId [in] An id of model, which should be exploded. \param origin [in] The point about which the explode is performed. If origin is kOrigin, will be used center of model extents as origin. */ OdTvModelExplode(const OdTvModelId& modelId, const OdTvPoint& origin = OdTvPoint::kOrigin); /** \details Destroys the OdTvModelExplode object. */ ~OdTvModelExplode(); /** \details Sets percent value for vector length for explode. \param lengthCoef [in] An value, which represent percent for vector length for explode. By default the value is 0.05 (5%). */ void setLengthCoef(double lengthCoef); /** \details Returns value, which represent percent from vector length for explode. */ double getLengthCoef() const; /** \details Perform explode. \param nStep [in] A value, which used for calculating distance of explode. Zero is reset explode. \remarks Explode distance calculate as nStep * vector from origin to center entity extents length * lengthCoef. */ void doExplode(OdUInt32 nStep); //DOM-IGNORE-BEGIN protected: /** \details Initialization of the OdTvModelExplode object. */ void initialize(); protected: OdTvModelId m_modelId; OdTvPoint m_origin; std::vector m_transformData; double m_dLengthCoef; //DOM-IGNORE-END }; #endif //_ODTV_MODELEXPLODE_H_INCLUDED_