OpenGL_convenience.h 934 B

123456789101112131415161718192021222324252627282930313233343536
  1. // This file is part of libigl, a simple c++ geometry processing library.
  2. //
  3. // Copyright (C) 2013 Alec Jacobson <alecjacobson@gmail.com>
  4. //
  5. // This Source Code Form is subject to the terms of the Mozilla Public License
  6. // v. 2.0. If a copy of the MPL was not distributed with this file, You can
  7. // obtain one at http://mozilla.org/MPL/2.0/.
  8. #ifndef OPENGL_CONVENIENCE_H
  9. #define OPENGL_CONVENIENCE_H
  10. #ifndef IGL_NO_OPENGL
  11. // Always use this:
  12. // #include "OpenGL_convenience.h"
  13. // Convenience includer for opengl.
  14. // For now this includes glu, glew and glext (perhaps these should be
  15. // separated)
  16. #if __APPLE__
  17. # include <OpenGL/gl.h>
  18. # include <OpenGL/glu.h>
  19. #elif defined(_WIN32)
  20. # define NOMINMAX
  21. # include <Windows.h>
  22. # undef NOMINMAX
  23. # include <GL/glew.h>
  24. # include <GL/gl.h>
  25. #else
  26. # define GL_GLEXT_PROTOTYPES
  27. # include <GL/gl.h>
  28. # include <GL/glext.h>
  29. # include <GL/glu.h>
  30. #endif
  31. #endif
  32. #endif