X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fcore%2Fstenciltest.cpp;h=2a1f0a846b7eb67cf75ea3a966a09345c2af453b;hp=7076f4d72dd205aec28341bee9ea01b92012dd36;hb=959efbf61663efd7879070ce0447e02c8a447ce0;hpb=2b2676392aff2eb6b38c3e463cc67f4d67a4ef8b diff --git a/source/core/stenciltest.cpp b/source/core/stenciltest.cpp index 7076f4d7..2a1f0a84 100644 --- a/source/core/stenciltest.cpp +++ b/source/core/stenciltest.cpp @@ -1,5 +1,6 @@ #include #include +#include "gl.h" #include "stenciltest.h" using namespace std; @@ -7,16 +8,6 @@ using namespace std; namespace Msp { namespace GL { -StencilTest::StencilTest(): - enabled(false), - compare(ALWAYS), - stencil_fail_op(KEEP), - depth_fail_op(KEEP), - depth_pass_op(KEEP), - reference(0) -{ } - - StencilTest::Loader::Loader(StencilTest &st): ObjectLoader(st) { @@ -39,22 +30,6 @@ void StencilTest::Loader::actions(StencilOp sf, StencilOp df, StencilOp dp) } -GLenum get_gl_stencil_op(StencilOp op) -{ - switch(op) - { - case KEEP: return GL_KEEP; - case SET_ZERO: return GL_ZERO; - case REPLACE: return GL_REPLACE; - case INCR: return GL_INCR; - case DECR: return GL_DECR; - case INVERT: return GL_INVERT; - case INCR_WRAP: return GL_INCR_WRAP; - case DECR_WRAP: return GL_DECR_WRAP; - default: throw invalid_argument("get_gl_stencil_op"); - } -} - void operator>>(const LexicalConverter &conv, StencilOp &op) { const string &str = conv.get();