Andrew Fenn schrieb:
I'm alittle confused, are you suggesting that if SetScissorRect receives a null value that if should default to the window size? or do you mean that perhaps GetScissorRect should call SetScissorRect and return a correct value instead of null?
No. {0,0,0,0} is a valid scissorrect. You could set it and get it. It is valid. Wines default scissorect is wrong, it has to be the size of the first swapchains backbuffer. I have a patch for this one. I'll send it later today.
If I understand you correctly it sounds like another problem and I think that checking should still be done on SetScissorRect as currently there is no checking being done where as the documentation states that D3DERR_INVALIDCALL is returned if SetScissorRect gets an invalid or null rectangle.
Probably, checking should be done for invalid scissorrect values.
I'm currently rewriting the tests and patch so I'll let you know when I am done.
PS: I just looked at wine's implementation of GetScissorRect and it looks wrong as well. It should be returning D3DERR_INVALIDCALL if there is no value and perhaps maybe if scissor test hasn't been enabled.
There is always a scissorrect value! I don't know if there is a chance to get a D3DERR_INVALIDCALL from the GetScissorRect-function.
Cheers Rico