summaryrefslogtreecommitdiffstats
path: root/matchblox/C_Environment.h
diff options
context:
space:
mode:
authorOliver Schinagl <oliver@schinagl.nl>2008-05-14 11:56:06 (GMT)
committerOliver Schinagl <oliver@schinagl.nl>2008-05-14 11:56:06 (GMT)
commitd4d35970d88edccdd963e53ea3e11f702e1e2bab (patch)
treeaa3f522ef826752bf08e2396f70a3156e1b81e5b /matchblox/C_Environment.h
parentab5d6fe55a31891ac8ad2949c31704e8245e116f (diff)
download2iv55-d4d35970d88edccdd963e53ea3e11f702e1e2bab.zip
2iv55-d4d35970d88edccdd963e53ea3e11f702e1e2bab.tar.gz
2iv55-d4d35970d88edccdd963e53ea3e11f702e1e2bab.tar.bz2
fix this
Diffstat (limited to 'matchblox/C_Environment.h')
-rw-r--r--matchblox/C_Environment.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/matchblox/C_Environment.h b/matchblox/C_Environment.h
new file mode 100644
index 0000000..cfdb816
--- /dev/null
+++ b/matchblox/C_Environment.h
@@ -0,0 +1,32 @@
+#ifndef C_ENVIRONMENT_H
+
+#define C_ENVIRONMENT_H
+
+#include <GL/glut.h>
+
+class C_Environment
+{
+public:
+ //environment map consist of 6 bitmaps with a common
+ //base name with the axis name (_positive_x.bmp,
+ //_negative_y.bmp, ...)
+ //appended, the distance is the distance from the center
+ //to the sides of the cube
+ C_Environment(const char *f_strEnvMapBaseName,
+ double f_dDistance);
+ ~C_Environment();
+
+ void Render();
+ void RenderFace(double f_verts[8][3],
+ int f_v00, int f_v10,
+ int f_v11, int f_v01);
+
+private:
+ double m_dDist;
+
+ //texture handles for the faces of the cube
+ GLuint m_uiFaceTex[6]; //order -x, -y, -z, +x, +y, +z
+};
+
+#endif //C_ENVIRONMENT_H
+