I mean it can be drawn but I would like to be able to do it also by importing a blender model to my program, lets say some day ill create a soldier, I would be a hell to draw him with Vertex functions.
No I havent been able to do so even though I would like to have the freedom to distribute the game, thats why I avoided pre maked loaders.
Im new on this section but I would like to Understand this or make a Loader Cause this is the function for the 2D textures:
using namespace std;
GLuint loadTexture( const string &fileName )
SDL_Surface *image = IMG_Load( fileName.c_str() );
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, image -> w, image -> h, 0, GL_RGBA, GL_UNSIGNED_BYTE, image -> pixels);
I know I have to Draw an object and the Wrap it with the texture, but for the 3D models stuff im kind off lost.