Jump to content
  • Advertisement

Archived

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

Daivuk

what is a vertex array?

This topic is 5523 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

Ok guys, I have made engine, with octree, blablabla, model. I stored my models in display list. Put Lightning, and bla bla bla But.... what the hell is a vertex array????? I see several post on that in that forum, but never get stop on it. But now i''m asking myself, what you guys mean by "vertex array" ? Just a quick answer, dont what to read a entire tutorial about it. What is it, and what is his use. Thanks

Share this post


Link to post
Share on other sites
Advertisement
Its something you should use if you want performance.
In immediate mode you send vertices vertex per vertex to the gfx hardware which can be quite slow. Well with a vertex array you basically store an array of vertices in memory(ram) and instead of sending them one by one you send the whole buffer at once to the card. This greatly improves performance.

You should also look into Vertex Buffer Objects (VBO). They are new but from what I can tell them work the same way as a vertex array, but instead of storing the array on ram you store the array on the graphic card memory.

Share this post


Link to post
Share on other sites
But its the same thing that Display list?
With display list you dont have to draw vertex by vertex, you already done that and ogl compiled it in a display list.
So is it the same thing? But only with vertex?

Share this post


Link to post
Share on other sites
no its not the same thing. With a display list you can do a sequence of ogl calls and store them in a list but a vertex array is just a buffer of vertices.

As far as I know you cant use vertex arrays in a display list, so using vertex arrays is still faster.

Share this post


Link to post
Share on other sites
Vertex arrays are not necessarily faster than using display lists. If you really want to know about them i suggest checking out the red book, its free online although i don''t have the URL, i''m sure someone will post it for ya.

Share this post


Link to post
Share on other sites
Yes, but you can have only one display list active at a time IIRC, (Am I right? My engine can't really use this nifty OGL feature) so vertex arrays are best used to store the level data (assuming you're using the standard OpenGL primitives as your user level representation) and display lists I found useful in my engine when placing objects like pickups (ammo packs, weapons, keys, etc) as repeated calls can be (RAPIDLY) made to show a display list's contents.

[edited by - Al Gorithm on May 8, 2003 10:46:11 PM]

Share this post


Link to post
Share on other sites
struct Vertex { ... };

Vertex vertexArray[SizeOfVertexArray];

that is a vertex array.. you can give that to opengl to let gl draw..

"take a look around" - limp bizkit
www.google.com

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Can you include things like color, texture & texture coordinates, normals, etc in a vertex array? Or are they just for position data?

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!