Advertisement

VAR memory allocation question

Started by August 11, 2002 01:13 PM
4 comments, last by nitzan 22 years, 6 months ago
Can I call wglAllocateMemoryNV more then once ? Or do I have to allocate one big chunk of memory and do my own memory management ? Nitzan ------------------------- www.geocities.com/nitzanw www.scorchedearth3d.net -------------------------
You should allocate one big chunk and do your own memory management.

Death of one is a tragedy, death of a million is just a statistic.
If at first you don't succeed, redefine success.
Advertisement
Hmm, I was thinking of something. You always have to choose between either allocating video memory or AGP memory, but not both. If you want to use both, you''d need 2 VAR chunks and you''d need to switch the vertex range in the middle of the frame (using glVertexArrayRangeNV()). And that''s very slow.

Does anyone know of a way to use both VidMem and AGP memory in a single frame without needing to flush the range ? Is it even possible on the NV20/25, or are there hardware limitations ?

/ Yann
As far as I know, the vertex_array_range2 extension eliminates this speed loss when switching from VAR''s to normal vertex arrays, so it may also reduce or eliminate the speed loss of switching different VARs. I''m not sure, but I suggest you look the second version of the extension up in the registry.

Death of one is a tragedy, death of a million is just a statistic.
If at first you don't succeed, redefine success.
python_regious, you say "should" rather then "cant". So whats the reasoning against allocating several chunks of memory ?

I am loading many models, and it would be alot easier if I can allocate one chunk for each one.

Nitzan

-------------------------
www.geocities.com/nitzanw
www.scorchedearth3d.net
-------------------------
The reasoning is that switching ranges (ie. switching between several different chunks of memory in a single frame) is *extremely* slow. Multiple ranges should be avoided at all costs. Ignoring that will lead to (quoting nVidia) ''terrible performance problems''.

python: I reread the specs of the vertex_array_range2 extension (I never used it before), but it only seems to apply to VAR/standard VA mixing. Would have been cool, if it was for two ranges, you could put static stuff in VidMem and dynamic stuff in AGP. Perhaps for the GF5

/ Yann

This topic is closed to new replies.

Advertisement