Creating dynamic? textures.

Started by
10 comments, last by greenpig83 10 years, 1 month ago

Actually, "best" would be to read the docs, look for examples, etc. There've been a lot of posts here on gamedev about similar problems.


Thanks man. But, I have actually been reading up on this for days and days now, with no huge progress.

I actually got it behaving correctly just then by changing my LockedRect call to this...

hr=mRenderer->textureVideoGet()->LockRect(0,&lockedRect,NULL,0);

...making the third parameter NULL (the area to lock). So, I guess I am now locking the whole image? Not sure why it doesn't work if I specify a rect though. Odd.

But, I am now seeing a 5 pixel white line (as intended).
Advertisement

Using D3DPOOL_MANAGED is nice because when you reset your graphic (fullscreen ->windows, change resolution...) you dont have to worry about the Texture. Otherwise you will have to relase and recreate all the texture you loaded!

This topic is closed to new replies.

Advertisement