Make a model in Blender and load in opengl

Raghuram Vadapalli picture Raghuram Vadapalli · Jan 31, 2016 · Viewed 9.6k times · Source

I want to make a 3D model in Blender and load it in OpenGL. Can someone give a step-by-step approach on how to do so. I tried to google but did not get any proper results.

Programming language: C++,

Tools: GLFW + GLAD + GLM

Answer

Prabindh picture Prabindh · Jan 31, 2016

Its a 3 step process, using external libraries.

  1. Model in blender. Export from Blender to .obj format (also containing .mtl file with reference to textures used).

Refer to

https://blender.stackexchange.com/questions/121/how-do-i-export-a-model-to-obj-format

  1. Use a library like Assimp to produce vertices and attributes.

  2. Use the vertices and attributes in your OpenGL application, using a method like described in,

https://nickthecoder.wordpress.com/2013/01/20/mesh-loading-with-assimp/