Skip to main content
gamedev.net
🔒 Locked

about D3DPOOL_DEFAULT texture

Started by tandory 3 replies 1k views
Original Post
tandory
tandory
Hi, I have a question. When Direct3D device is lost, all textures created with D3DPOOL_DEFAULT are lost too? I want to keep those textures while program is running. (I'm using Direct3D 9.)
arbitus
arbitus
Yes, anything in the DEFAULT pool will be lost. You can either use the MANAGED pool or you can reset/reload your assets after a lost device has been reset.
tandory
tandory
Thanks for your reply.

I have textures used as render target and updated every frame. So, I have to create copies of them in system RAM and update every frame in order not to lose them. Is this right?
jollyjeffers
jollyjeffers
Yes, you'll have to use ::GetRenderTargetData() if you need to persist your render target contents. Alternatively you need only remember the state necessary to re-render the exact same image after the D3DPOOL_DEFAULT resource is lost...

hth
Jack
<hr align="left" width="25%" />
Jack Hoxley <small>[</small><small> Forum FAQ | Revised FAQ |
tandory
tandory
I'm planning to develop painting program using Direct3D 9 and use Direct3D texture as layer, but the program may be slow if I have to update frequently...

Topic Locked

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

Sign in to reply to this topic.