22 #include "repo_node.h"
24 #include "../../../repo_bouncer_global.h"
34 #define REPO_NODE_MESH_LABEL_VERTICES "vertices" //<! vertices array
35 #define REPO_NODE_MESH_LABEL_VERTICES_COUNT "vertices_count" //<! vertices size
36 #define REPO_NODE_MESH_LABEL_VERTICES_BYTE_COUNT "vertices_byte_count"
38 #define REPO_NODE_MESH_LABEL_FACES "faces" //<! faces array label
39 #define REPO_NODE_MESH_LABEL_FACES_COUNT "faces_count" //<! number of faces
40 #define REPO_NODE_MESH_LABEL_FACES_BYTE_COUNT "faces_byte_count"
42 #define REPO_NODE_MESH_LABEL_NORMALS "normals"
43 //------------------------------------------------------------------------------
44 #define REPO_NODE_MESH_LABEL_OUTLINE "outline"
45 #define REPO_NODE_MESH_LABEL_BOUNDING_BOX "bounding_box"
46 //------------------------------------------------------------------------------
47 #define REPO_NODE_MESH_LABEL_UV_CHANNELS "uv_channels"
48 #define REPO_NODE_MESH_LABEL_UV_CHANNELS_COUNT "uv_channels_count"
49 #define REPO_NODE_MESH_LABEL_UV_CHANNELS_BYTE_COUNT "uv_channels_byte_count"
50 #define REPO_NODE_MESH_LABEL_SHA256 "sha256"
51 #define REPO_NODE_MESH_LABEL_COLORS "colors"
53 #define REPO_NODE_MESH_LABEL_MAP_ID "map_id"
54 #define REPO_NODE_MESH_LABEL_VERTEX_FROM "v_from"
55 #define REPO_NODE_MESH_LABEL_VERTEX_TO "v_to"
56 #define REPO_NODE_MESH_LABEL_TRIANGLE_FROM "t_from"
57 #define REPO_NODE_MESH_LABEL_TRIANGLE_TO "t_to"
58 #define REPO_NODE_MESH_LABEL_MATERIAL_ID "mat_id"
59 #define REPO_NODE_MESH_LABEL_MERGE_MAP "m_map"
77 const std::unordered_map<std::string, std::pair<std::string, std::vector<uint8_t>>> &binMapping =
78 std::unordered_map<std::string, std::pair<std::string, std::vector<uint8_t>>>()
93 uint32_t getMFormat()
const;
101 return REPO_NODE_TYPE_MESH;
110 return NodeType::MESH;
131 virtual bool sEqual(
const RepoNode &other)
const;
146 virtual RepoNode cloneAndApplyTransformation(
147 const std::vector<float> &matrix)
const;
154 const std::vector<repo_mesh_mapping_t> &vec,
155 const bool &overwrite =
false);
165 std::vector<repo_vector_t> getBoundingBox()
const;
167 static std::vector<repo_vector_t> getBoundingBox(
RepoBSON &bbArr);
172 std::vector<repo_color4d_t> getColors()
const;
177 std::vector<repo_face_t> getFaces()
const;
179 std::vector<repo_mesh_mapping_t> getMeshMapping()
const;
184 std::vector<repo_vector_t> getNormals()
const;
189 std::vector<repo_vector2d_t> getUVChannels()
const;
194 std::vector<std::vector<repo_vector2d_t>> getUVChannelsSeparated()
const;
199 std::vector<repo_vector_t> getVertices()
const;
212 std::vector<uint32_t> getFacesSerialized()
const;
Definition: repo_connection_pool_mongo.h:32
Definition: repo_node_utils.h:81
Definition: repo_node_mesh.h:62
Definition: repo_node.h:33
Definition: repo_bson.h:53
virtual NodeType getTypeAsEnum() const
Definition: repo_node_mesh.h:108
virtual std::string getType() const
Definition: repo_node_mesh.h:99
virtual bool positionDependant()
Definition: repo_node_mesh.h:122