소스 검색

fix leak: just ignore broken texture coordinates.

kimkulling 5 년 전
부모
커밋
f938a6b744
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      code/AssetLib/glTF2/glTF2Importer.cpp

+ 2 - 1
code/AssetLib/glTF2/glTF2Importer.cpp

@@ -417,7 +417,8 @@ void glTF2Importer::ImportMeshes(glTF2::Asset &r) {
 			}
 			for (size_t tc = 0; tc < attr.texcoord.size() && tc < AI_MAX_NUMBER_OF_TEXTURECOORDS; ++tc) {
                 if (!attr.texcoord[tc]) {
-                    throw DeadlyImportError("GLTF: Texture coordinate accessor not found or non-contiguous texture coordinate sets");
+                    DefaultLogger::get()->warn("Texture coordinate accessor not found or non-contiguous texture coordinate sets.");
+                    continue;
                 }
 
 				if (attr.texcoord[tc]->count != aim->mNumVertices) {