OpenGL 3D Game Tutorial 10: Loading 3D Models

LWJGL tutorial series on how to create a 3D Java game with OpenGL!

This week we create an OBJ parser to load 3D models made in Blender into our game!

Download the stall model:

Download Blender for free:

Common Problems:

-If you’re using your own model then make sure to texture it in Blender first using UV mapping!

-The size of the normals array is “vertices.size() * 3” and NOT “normals.size() * 3”. Check 6:38 in the video and make sure you got this right.

– Make sure your texture file has dimensions that are powers of 2 (128×128, 256×256, 512×512 etc.) The file may have got resized when you downloaded it.

-Make sure you used “1 – currentTex.y” in the processVertex() method.

-If you’re using your own model and the texture looks distorted in the game but fine in Blender then you may be experiencing the texture seam problem that I talked about in the previous episode. You can fix this by using the improved OBJLoader provided at the end of episode 16.

Support the series on Patreon:

Facebook Page:
Check out my game on IndieDB:

End of video music- Kai Engel, “Waking Stars”:


What do you think?

Days Gone : des nouvelles images sur PC avec le mode "Photo", c'est ultra détaillé

The Witcher 3 : Une mise à jour next-gen qui utilise des mods de fans ?