68 bool use_custom_normals;
76 std::map<std::string, std::string> mesh_geom_map;
77 std::map<COLLADAFW::UniqueId, Mesh *> uid_mesh_map;
78 std::map<COLLADAFW::UniqueId, Object *> uid_object_map;
79 std::vector<Object *> imported_objects;
86 int *material_indices;
89 using MaterialIdPrimitiveArrayMap = std::map<COLLADAFW::MaterialId, std::vector<Primitive>>;
91 std::map<COLLADAFW::UniqueId, MaterialIdPrimitiveArrayMap> geom_uid_mat_mapping_map;
94 std::multimap<COLLADAFW::UniqueId, COLLADAFW::UniqueId> materials_mapped_to_geom;
96 bool set_poly_indices(
int *face_verts,
int loop_index,
const uint *
indices,
int loop_count);
101 COLLADAFW::IndexList &index_list,
107 COLLADAFW::IndexList &index_list,
111 void print_index_list(COLLADAFW::IndexList &index_list);
118 bool is_nice_mesh(COLLADAFW::Mesh *mesh);
120 void read_vertices(COLLADAFW::Mesh *mesh,
Mesh *blender_mesh);
128 bool primitive_has_useable_normals(COLLADAFW::MeshPrimitive *mp);
133 bool primitive_has_faces(COLLADAFW::MeshPrimitive *mp);
142 static void mesh_add_edges(
Mesh *mesh,
int len);
144 uint get_loose_edge_count(COLLADAFW::Mesh *mesh);
152 void allocate_poly_data(COLLADAFW::Mesh *collada_mesh,
Mesh *mesh);
162 void read_polys(COLLADAFW::Mesh *mesh,
171 void read_lines(COLLADAFW::Mesh *mesh,
Mesh *blender_mesh);
172 uint get_vertex_count(COLLADAFW::Polygons *mp,
int index);
174 void get_vector(
float v[3], COLLADAFW::MeshVertexData &arr,
int i,
int stride);
176 bool is_flat_face(
uint *nind, COLLADAFW::MeshVertexData &
nor,
int count);
183 std::vector<Object *> get_all_users_of(
Mesh *reference_mesh);
187 bool use_custom_normals,
225 std::map<COLLADAFW::UniqueId, Material *> &uid_material_map,
227 const COLLADAFW::UniqueId *geom_uid,
231 COLLADAFW::InstanceGeometry *geom,
233 std::map<COLLADAFW::UniqueId, Material *> &uid_material_map);
void assign_material_to_geom(COLLADAFW::MaterialBinding cmaterial, std::map< COLLADAFW::UniqueId, Material * > &uid_material_map, Object *ob, const COLLADAFW::UniqueId *geom_uid, short mat_index)
MeshImporter(UnitConverter *unitconv, bool use_custom_normals, ArmatureImporter *arm, Main *bmain, Scene *sce, ViewLayer *view_layer)