Skip to content

Instantly share code, notes, and snippets.

@iondune
Created April 16, 2014 07:38
Show Gist options
  • Save iondune/10825413 to your computer and use it in GitHub Desktop.
Save iondune/10825413 to your computer and use it in GitHub Desktop.
#include <assimp/Importer.hpp>
#include <assimp/scene.h>
#include <assimp/postprocess.h>
Assimp::Importer Importer;
aiScene const * const Scene = Importer.ReadFile(FileName,
aiProcess_CalcTangentSpace |
aiProcess_Triangulate |
aiProcess_JoinIdenticalVertices |
aiProcess_SortByPType
);
if (! Scene)
{
std::cerr << "Failed to import mesh file '" << FileName << "': " << Importer.GetErrorString() << std::endl;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment