Sign in to follow this  
supagu

[dx10] stencil buffer on render texture

Recommended Posts

im trying to use the stencil buffer on my render texture, problem is, its not working! read and write mask are 255 for both faces (front and back) i've set up: compare function: always fail, pass and depth fail all to increment i can clear the stencil to a set value and this works fine, so im not sure why using stencil while rendering to the render texture doesnt do anything. suggestions on what to try? i read back the stencil buffer back to main memory thats how i know if its working or not

Share this post


Link to post
Share on other sites
here is the info from PIX:

Depth Enable FALSE
Depth Function D3D10_COMPARISON_NEVER
Depth Write Mask D3D10_DEPTH_WRITE_MASK_ZERO
Stencil Enable TRUE
Stencil Read Mask 11111111
Stencil Write Mask 11111111

Back Face:
Depth Fail Op D3D10_STENCIL_OP_INCR
Fail Op D3D10_STENCIL_OP_INCR
Function D3D10_COMPARISON_ALWAYS
Pass Op D3D10_STENCIL_OP_INCR

Front Face:
Depth Fail Op D3D10_STENCIL_OP_INCR
Fail Op D3D10_STENCIL_OP_INCR
Function D3D10_COMPARISON_ALWAYS
Pass Op D3D10_STENCIL_OP_INCR


unfortunately i cant view stencil in PIX

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this