/** * * @file FITKGeometryMeshVS.h * @brief 几何模型渲染对象 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 * */ #ifndef _FITK_GEOMETRY_MESH_VS_H___ #define _FITK_GEOMETRY_MESH_VS_H___ #include "FITKInterfaceGeometryAPI.h" #include "FITK_Kernel/FITKCore/FITKAbstractDataObject.h" #include namespace Interface { class FITKGeoMeshVSPt; class FITKGeoMeshVSEdgeEntity; class FITKGeoMeshVSFaceEntity; /** * @brief 几何模型渲染网格对象 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ class FITKInterfaceGeometryAPI FITKGeometryMeshVS : public Core::FITKAbstractDataObject { public: /** * @brief Construct a new FITKGeometryMeshVS object * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ explicit FITKGeometryMeshVS() = default; /** * @brief Destroy the FITKGeometryMeshVS object * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ virtual ~FITKGeometryMeshVS(); /** * @brief 插入点对象 * @param[i] id 虚拓扑id * @param[i] pt 点渲染对象 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ void insertPoint(int id, FITKGeoMeshVSPt* pt); /** * @brief 插入边对象 * @param[i] id 边的虚拓扑id * @param[i] pt 边的网格 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ void insertEdge(int id, FITKGeoMeshVSEdgeEntity* pt); /** * @brief 插入面对象 * @param[i] id 面的虚拓扑id * @param[i] pt 面的网格 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ void insertFace(int id, FITKGeoMeshVSFaceEntity* pt); /** * @brief 获取点的渲染数据 * @return const QHash& int 为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ const QHash & getPointItems() const; /** * @brief 获取边的渲染数据 * @return const QHash& int 为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ const QHash & getEdgeItems() const; /** * @brief 获取面的渲染数据 * @return const QHash& int 为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ const QHash & getFaceItems() const; /** * @brief 清空对象 * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ void clear(); /** * @brief 是否有效,所有对象均为空是无效状态 * @return true * @return false * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ bool isValid(); private: /** * @brief 点渲染对象 键为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ QHash _points{}; /** * @brief 线渲染对象 键为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ QHash _edges{}; /** * @brief 面渲染对象 键为虚拓扑id * @author LiBaojun (libaojunqd@foxmail.com) * @date 2024-08-31 */ QHash _faces{}; }; } #endif