What happens when the video card runs out of memory?

Started by
2 comments, last by Jackis 18 years, 7 months ago
I was recently testing a program that loads up a film res (2048x1556), floating-point image and applies a Cg shader to it for display when I got GL_OUT_OF_MEMORY error. Is this out of system memory (I was running pretty close to the physical limit at the time), or video memory. If it's video memory that's running out, is there anything I can do (aside from splitting the image up into smaller chunks) to get around this? Cheers, Anders
Advertisement
If it doesn't fit in video memory I it goes to system memory. Then the driver swaps textures in and out of video memory depending on which textures are bound. If you're out of system memory too I would guess it goes virtual memory (the swap file).

I think the driver has a fairly good memory manager which decides which textures stay in VRAM and which stay in system memory.

Btw your texture is not a power of 2 texture, make sure you use the texture nonpow2 ARB extension.
Yeah I'm using TEXTURE_RECTANGLE_NV.

So presumably if I'm getting OUT_OF_MEMORY then it's already swapped out to systen memory and decided it can't even get enought there to allocate the texture?

playmesumch00ns
What 3D hadrware do you use? I meen, what videocard do you have, and what is the amount of on-board video-memory? And what is the setting of "AGP Aperture Size" in your PC BIOS? (the last thing is not for textures, but for vertex buffer objects and so on)

This topic is closed to new replies.

Advertisement