Luna::RHI::DepthStencilDesc

Describes depth stencil stage configurations of one graphics pipeline.

struct Luna::RHI::DepthStencilDesc

Member objects

  • bool depth_test_enable

    Whether depth testing is enabled. If this is false, all pixels from pixel shader will pass depth testing.

  • bool depth_write_enable

    Whether to write the pixel's depth value to depth buffer if one pixel passes depth testing.

  • CompareFunction depth_func

    The compare function used for depth comparison in depth testing.

  • bool stencil_enable

    Whether stencil testing is enabled. If this is false, all pixels from pixel shader will pass stencil testing.

  • u8 stencil_read_mask

    The mask used to specify bits that will be loaded from stencil buffer for stencil testing. All bits that are not specified in the mask (with mask bit value 0) will be set to 0 before stencil testing is performed.

  • u8 stencil_write_mask

    The mask used to specify bits that are allowed to be modified in stencil testing.

  • DepthStencilOpDesc front_face

    The depth stencil operation performed for the front face of one triangle.

  • DepthStencilOpDesc back_face

    The depth stencil operation performed for the back face of one triangle.