I’ve been working on implementing the Assimp library into my code, and I’ve run into a problem and am unsure if I’m going to have to find another library or if I’m just making a simple mistake.
When I load OBJ files (Assimp won’t load FBX, 3DSmax, or Maya files, citing invalid formats or outdated versions) into AIScene instances with Assimp, the textures are nowhere to be found.
scene.mNumTextures() = 0
Assimp.aiGetMaterialTextureCount(material, Assimp.aiTextureType_DIFFUSE) = 0
Assimp.aiGetMaterialTextureCount(material, Assimp.aiTextureType_NONE) = 0
I load my AIScene instance with:
ByteBuffer file = Utils.read(asset.toInputStream());
int flags = Assimp.aiProcess_Triangulate | Assimp.aiProcess_GenNormals | Assimp.aiProcess_ImproveCacheLocality
| Assimp.aiProcess_SortByPType | Assimp.aiProcess_OptimizeMeshes | Assimp.aiProcess_OptimizeGraph
| Assimp.aiProcess_CalcTangentSpace | Assimp.aiProcess_TransformUVCoords | Assimp.aiProcess_GenUVCoords
| Assimp.aiProcess_JoinIdenticalVertices | Assimp.aiProcess_FlipUVs;
AIScene scene = Assimp.aiImportFileFromMemory(file, flags, "");
Any thoughts or ideas would be appreciated.