X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fstenciltest.h;h=09f1d2784e0e0686a71633985febfd0ec069bf6a;hb=11a5d4f2a35dfdcf61e16d4fcfba22e20ea6a3db;hp=cdc613886e4e3adc9002d99f787340e093e50e12;hpb=2b2676392aff2eb6b38c3e463cc67f4d67a4ef8b;p=libs%2Fgl.git diff --git a/source/core/stenciltest.h b/source/core/stenciltest.h index cdc61388..09f1d278 100644 --- a/source/core/stenciltest.h +++ b/source/core/stenciltest.h @@ -8,13 +8,13 @@ namespace Msp { namespace GL { -enum StencilOp +enum StencilOp: std::uint8_t { KEEP, SET_ZERO, REPLACE, - INCR, - DECR, + INCR_CLAMP, + DECR_CLAMP, INVERT, INCR_WRAP, DECR_WRAP @@ -37,22 +37,20 @@ struct StencilTest void actions(StencilOp, StencilOp, StencilOp); }; - bool enabled; - Predicate compare; - StencilOp stencil_fail_op; - StencilOp depth_fail_op; - StencilOp depth_pass_op; - unsigned reference; - - StencilTest(); + bool enabled = false; + Predicate compare = ALWAYS; + StencilOp stencil_fail_op = KEEP; + StencilOp depth_fail_op = KEEP; + StencilOp depth_pass_op = KEEP; + unsigned reference = 0; }; -GLenum get_gl_stencil_op(StencilOp); - void operator>>(const LexicalConverter &, StencilOp &); void operator<<(LexicalConverter &, StencilOp); } // namespace GL } // namespace Msp +#include "stenciltest_backend.h" + #endif