| 110 | } |
| 111 | |
| 112 | TEST(ModelGLTF, Load) |
| 113 | { |
| 114 | const char* path = "./src/test/assets/car01.glb"; |
| 115 | uint32_t file_size = 0; |
| 116 | void* mem = dmModelImporter::ReadFile(path, &file_size); |
| 117 | |
| 118 | const char* suffix = strrchr(path, '.') + 1; |
| 119 | |
| 120 | dmModelImporter::Options options; |
| 121 | dmModelImporter::Scene* scene = dmModelImporter::LoadFromBuffer(&options, suffix, mem, file_size); |
| 122 | ASSERT_FALSE(dmModelImporter::NeedsResolve(scene)); |
| 123 | bool result = dmModelImporter::LoadFinalize(scene); |
| 124 | ASSERT_TRUE(result); |
| 125 | result = dmModelImporter::Validate(scene); |
| 126 | ASSERT_TRUE(result); |
| 127 | |
| 128 | ASSERT_NE((void*)0, scene); |
| 129 | |
| 130 | //dmModelImporter::DebugScene(scene); |
| 131 | |
| 132 | dmModelImporter::DestroyScene(scene); |
| 133 | |
| 134 | free(mem); |
| 135 | } |
| 136 | |
| 137 | TEST(ModelGLTF, MorphWeightsAnimationChannel) |
| 138 | { |
nothing calls this directly
no test coverage detected