Category : assimp

I have the following code void Mesh::draw(Shader shader) { //bind appropriate textures GLuint diffuse_nr = 1; GLuint specular_nr = 1; for(GLuint i = 0; i < textures.size(); i++) { //active proper texture unit before binding glActiveTexture(GL_TEXTURE0 + i); //retrieve texture number (the N in the diffuse_textureN) stringstream ss; string number; string name = textures[i].type; if(name ..

Read more

I have the following code from learnopengl.com void Model::load_model(string path) { //read file via ASSIMP Assimp::Importer Importer; const aiScene* scene = Importer.ReadFile(path, aiProcess_Triangulate | aiProcess_FlipUVs); //check for errors if(!scene || scene->mFlags & AI_SCENE_FLAGS_INCOMPLETE || !scene->mRootNode)// if not zero { cout << "error, assimp ," << Importer.GetErrorString() << endl; return; } //retrieve the directory path of ..

Read more

ive followed opengl tutorial at leranOpengl.com and i have problem with drawing nanosuit model my appliction use opengl and lefthanded the result image : wrong nanosuit model and while it should be like this correct one my assimp importer flags is const aiScene* scene = importer.ReadFile(path, aiProcess_Triangulate | aiProcess_JoinIdenticalVertices | aiProcess_CalcTangentSpace | aiProcess_GenNormals | aiProcess_MakeLeftHanded ..

Read more