PDA

View Full Version : Would like a guide for parsing...



MolmasEpic
03-08-2011, 09:46 AM
Hey i think ima give up on trying to get other libraries to work since none of them work correctly(and nobody is able to help) :(

well anyways, im going to try and parse my .OBJ file myself, and maybe learn something new.

my only question is(since i found a guide) is what is the most efficient way to store the vertices,tex coords, and i guess normals?

if i knew this then i can get started
EDIT: also im wondering how i would load this up into opengl(the code/function to draw the vertices)

thanks and sorry if im bothering anyone.. :(

McLeary
03-08-2011, 12:05 PM
Start here: http://en.wikipedia.org/wiki/Wavefront_.obj_file

Take a look at this: http://people.cs.kuleuven.be/~ares.lagae/libobj/index.html

If you wanna the obj spec you can find it here: http://www.martinreddy.net/gfx/3d/OBJ.spec

Tools, libraries and example files: http://people.sc.fsu.edu/~jburkardt/data/obj/obj.html