lock rendertarget texture

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
turboferret
Posts: 49
Joined: Thu Aug 12, 2004 12:42 pm
Location: Sweden
Contact:

lock rendertarget texture

Post by turboferret »

Hi all!
Is it possible to lock an ITexture created with IVideoDriver::createRenderTargetTexture? Everytime I try to lock such a texture it returns NULL. Normal textures work fine.

Thanks
This monkey is useless, it only has ONE ass!!!
turboferret
Posts: 49
Joined: Thu Aug 12, 2004 12:42 pm
Location: Sweden
Contact:

Post by turboferret »

Update:
I've been able to lock the texture when using OpenGL, but not with directx 8 or 9. The weird thing with OpenGL is that when I use draw2DImage to draw the texture afterwards, it is flipped vertically. Also the colors returned by getPixel is wrong or different than expected.
This monkey is useless, it only has ONE ass!!!
niko
Site Admin
Posts: 1759
Joined: Fri Aug 22, 2003 4:44 am
Location: Vienna, Austria
Contact:

Post by niko »

I never tried out to lock rendertargets, I'm going to do it and try to fix bugs if there are some for the next version.
turboferret
Posts: 49
Joined: Thu Aug 12, 2004 12:42 pm
Location: Sweden
Contact:

Post by turboferret »

Thanks for that Nico. Looking forward to what you'll find out!
This monkey is useless, it only has ONE ass!!!
Post Reply