Parameters:
size,: Size of the texture, in pixels. Width and height should be a power of two (for example 64, 128, 256, 512, ...) and it should not be bigger than the backbuffer, because it shares the zbuffer with the screen buffer.
I guess the question is very stupid, but i want to know for sure, about "and it should not be bigger than the backbuffer":
If i have 800x600 mode what maximum size may i use ? (512x512 ?)
If i have 1024x768 mode --------------------------------- ? (1024x1024 or 1024x512 ?)
P.S.: How to determinate backbuffer size and check is this size acceptable?
The limitation to the backbuffer is because its zbuffer is reused, so you wouldn't get sane results otherwise. The Power-of-two is because no DirectX programmer in the team yet fixed it. It was reported that this limitation does not exists for D3D9, but I simply don't know and try to avoid messing with D3D stuff, and the others did not fix it. What about D3D8, is it also capable of NPOT RTT?
I'm using rendertargets with the size of the backbuffer (non power of 2, like 640x480 etc) on the OpenGL driver and it works fine.
*edit* hybrid answered faster and better
________ VAPORIZER AFFILIATE
Last edited by LLDD on Sun Feb 20, 2011 2:13 am, edited 2 times in total.