Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2005-03-19 23:48:39 +0300
committerDaniel Dunbar <daniel@zuster.org>2005-03-19 23:48:39 +0300
commitf74662dcc12cb82fddce7d1c3f7ac122fb1ab7eb (patch)
treedc95fd53c30959d759b2a60ae0d61aa0f9e00684
parent35ab8a32a125d245a4f9b12daacbba6b9b4599d0 (diff)
- add some windows specific defines to BIF_gl.h so that OpenGL can
be used without including windows.h - this is the main reason windows.h is included in so many places and this change allows most of those inclusions to die.
-rw-r--r--source/blender/include/BIF_gl.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/source/blender/include/BIF_gl.h b/source/blender/include/BIF_gl.h
index a4ccfa28768..9790becfd70 100644
--- a/source/blender/include/BIF_gl.h
+++ b/source/blender/include/BIF_gl.h
@@ -34,6 +34,24 @@
#ifndef BIF_GL_H
#define BIF_GL_H
+ /* Although not really a great idea to copy these defines
+ * from Windows' winnt.h, this lets us use GL without including
+ * windows.h everywhere (or BLI_winstuff.h) which is a good thing.
+ */
+#ifdef WIN32
+#ifndef APIENTRY
+#define APIENTRY __stdcall
+#endif
+
+#ifndef CALLBACK
+#define CALLBACK __stdcall
+#endif
+
+#ifndef WINGDIAPI
+#define WINGDIAPI __declspec(dllimport)
+#endif
+#endif
+
#ifdef __APPLE__
#include <OpenGL/gl.h>
#include <OpenGL/glu.h>