VBO memory question

Started by
0 comments, last by V-man 15 years, 5 months ago
Iv been reading OPENGL distilled and trying the basics of a 2d OPENGL engine that i want to build. Iv been able to do it in the past with immediate mode, but that slow and eventually going away so im working with VA's and VBO's. I understand the concept of being put into either system/vram but how do i handle the memory management aspect? If i setup a system to create VBO's for all the 2d images i want to load, eventually i run out of vram right? How does one handle this situation. Or does OPENGL swap VBO's from vram to system ram on its own? Thanks for any guidance. I have very little knowledge of memory issues in game programming, just looking to learn how its handled.
Advertisement
If you read the opengl spec, there is no mention of RAM, VRAM and anything else. These are hardware specific details.
If you have a PC with some video card like a nvidia geforce, then the driver provided by nvidia does the memory management and swapping.
Sig: http://glhlib.sourceforge.net
an open source GLU replacement library. Much more modern than GLU.
float matrix[16], inverse_matrix[16];
glhLoadIdentityf2(matrix);
glhTranslatef2(matrix, 0.0, 0.0, 5.0);
glhRotateAboutXf2(matrix, angleInRadians);
glhScalef2(matrix, 1.0, 1.0, -1.0);
glhQuickInvertMatrixf2(matrix, inverse_matrix);
glUniformMatrix4fv(uniformLocation1, 1, FALSE, matrix);
glUniformMatrix4fv(uniformLocation2, 1, FALSE, inverse_matrix);

This topic is closed to new replies.

Advertisement