VPOS is relative to desktop, not to application


The values passed in through VPOS are relative to desktop instead of the render target.
To show this is a bug, setup a shader in Shazzam with this input:
float2 Screen    : VPOS;
Then add this code:
if ( screen.x > 800 )
    result = float4(0,1,0,1);   // Green
    result = float4(0,0,1,1);  // Blue
return result;
If running inside Shazzam it's relative to desktop, if running in a WPF app it's relative to the Window.


WaltRitscher wrote Jan 9, 2012 at 3:35 AM

I need more details. Can you supply the entire shader text?

wrote Feb 14, 2013 at 1:30 AM