summaryrefslogtreecommitdiffstats
path: root/src/gui/opengl/qopengltexture.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/opengl/qopengltexture.h')
-rw-r--r--src/gui/opengl/qopengltexture.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/src/gui/opengl/qopengltexture.h b/src/gui/opengl/qopengltexture.h
index 1cf5fdc12aa..56fdd07f2f5 100644
--- a/src/gui/opengl/qopengltexture.h
+++ b/src/gui/opengl/qopengltexture.h
@@ -346,8 +346,9 @@ public:
NPOTTextures = 0x00000800,
NPOTTextureRepeat = 0x00001000,
Texture1D = 0x00002000,
+ TextureComparisonOperators = 0x00004000,
#ifndef Q_QDOC
- MaxFeatureFlag = 0x00004000
+ MaxFeatureFlag = 0x00008000
#endif
};
Q_DECLARE_FLAGS(Features, Feature)
@@ -488,6 +489,28 @@ public:
void setDepthStencilMode(DepthStencilMode mode);
DepthStencilMode depthStencilMode() const;
+ enum ComparisonFunction {
+ CompareLessEqual = 0x0203, // GL_LEQUAL
+ CompareGreaterEqual = 0x0206, // GL_GEQUAL
+ CompareLess = 0x0201, // GL_LESS
+ CompareGreater = 0x0204, // GL_GREATER
+ CompareEqual = 0x0202, // GL_EQUAL
+ CommpareNotEqual = 0x0205, // GL_NOTEQUAL
+ CompareAlways = 0x0207, // GL_ALWAYS
+ CompareNever = 0x0200 // GL_NEVER
+ };
+
+ void setComparisonFunction(ComparisonFunction function);
+ ComparisonFunction comparisonFunction() const;
+
+ enum ComparisonMode {
+ CompareRefToTexture = 0x884E, // GL_COMPARE_REF_TO_TEXTURE
+ CompareNone = 0x0000 // GL_NONE
+ };
+
+ void setComparisonMode(ComparisonMode mode);
+ ComparisonMode comparisonMode() const;
+
// Sampling Parameters
enum Filter {
Nearest = 0x2600, // GL_NEAREST