--- a/src/vertexmap.h Wed Jul 28 08:23:09 2021 +0300 +++ b/src/vertexmap.h Wed Jul 28 13:22:51 2021 +0300 @@ -11,7 +11,14 @@ { Q_OBJECT public: - using ApplyFunction = std::function<void(const glm::vec3&, const std::set<ldraw::id_t>&)>; + struct VertexInfo + { + glm::vec3 point; + std::set<ldraw::id_t> objects; + bool transformSet = false; + glm::mat4 transform; + }; + using ApplyFunction = std::function<void(const glm::vec3&, const VertexInfo&)>; VertexMap(const Model *model); Q_SLOT void build(); void apply(ApplyFunction fn) const; @@ -21,7 +28,7 @@ const Model* const model; QSet<unsigned int> vertexHashes; std::vector<glm::vec3> vertices; - std::map<unsigned int, std::set<ldraw::id_t>> map; + std::map<unsigned int, VertexInfo> map; }; #endif // VERTEXMAP_H