Skip to main content
gamedev.net
🔒 Locked

Memory

Started by Aqua Costa Apr 6, 2011 at 5:44 PM 2 replies 500+ views
Original Post
Aqua Costa
Aqua Costa
What occupies RAM? Is it buffers (vertex and index, etc)? Texture2D? ShaderResourceViews and RenderTargetViews? What else?

What occupies GPU memory?

Are there more kinds of memory I should worry about (except hard disk space)?

What happens in my game exceed either RAM or GPU memory limit?
GregMichael
GregMichael
Hard disk space is not memory...it's storage.

What is your question ?

Just about anything can occupy either CPU RAM or GPU VRAM....it depends on where you put it and what you want to do with it.
Aqua Costa
Aqua Costa
So for example:

Case 1:
I have a mesh with, let's say, 3000 vertices and uses 10 textures. And I want to render it. How can either the CPU RAM or GPU VRAM limit my program?

Case 2:
I want to apply a post processing effect. So I have 4 vertices and many textures with the size of my window and different formats. Again, How can either the CPU RAM or GPU VRAM limit my program?

I belive I know most of the answers to this questions... But I want to make sure I learned everything correctly before moving on to more advanced things...
Hunter-Killer
Hunter-Killer
With the vertices, you would have a system copy up until the point you copy them over to a vertex buffer on the gpu. At that point the gpu copy would be persistent and you could free up your local copy if you didn't need them. Textures would start off in system memory before being copied over the vram (you really only deal with an id in code).

As far as shader parameters go, I would assume that they exist in system memory and get copied over to the gpu each time you make a rendering call but the shaders themselves are pushed to the card when loaded.

Render targets, like textures, would use up gpu memory.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.