Jump to content
  • Advertisement
Sign in to follow this  
danromeo

CreateTextureFromResource

This topic is 4998 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

If I D3DXCreateTextureFromResource, does this mean that if I, say, create the same texture from resource three times in a row that it is actually only loaded into memory once with an incremented reference count? Seems the MS docs have nothing to say about this at all. Thanks.

Share this post


Link to post
Share on other sites
Advertisement
Nope, three seperate textures are created. The easiest way to check is to do SetPrivateData() on one texture, then GetPrivateData() on another. If the return value is the same, then you'll be pointing to the same object. Also, the pointer values should be the same if they point to the same object.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!