Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

arikMag

VBO's question

This topic is 5225 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi, I finally have a real question. I''m using the program of reading 3ds file from the site of gametutorials (if someone familier with this program). so the method of the program is : saving array of faces - each face include three indexes(and not verticies) to another array of verticies (which contain only diffrent verticies - no tow verticies are the same - this way is saving place because there are alot of vertices which identical in the object). I read alittle about the tutorial of using VBO''s (vertex buffer). I really sure that the only way to use it is to make array of cordinates/verticies which include real values of place and not index as it is now. so what can I do without changing the 3ds reader program. thanks.

Share this post


Link to post
Share on other sites
Advertisement
What you need is :
a) Load a model in memory
b) loop trough all of your vert. indexes and fill the buffer with them (vertices)
c) Delete the model''s memory

Share this post


Link to post
Share on other sites
Is it better not to use object class at all and just load what I read from the file strieght to the VBO''s?

Share this post


Link to post
Share on other sites
Sory about the delay I hawe totaly forgot that I posted to you
Yes you are right it''s usles to use class if you want to make a Vertex buffer if your model (data) is static.
If your model uses animation i think you shoud Implement a class.
Buth i think this is not the best way to rendedr your vertices .
I don''t know for shure buth i think you can remake your vertex buffer to become Index buffer. I read about this before buth i remember it preaty blury so I can''t tell for shure.
Go google : "OpenGL Index buffers" or somthing like this

Hope this helps some

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!