cocoa: remove support for systems without gl3.h header

This commit is contained in:
Stefano Pigozzi 2015-01-22 08:27:03 +01:00
parent edc100eee0
commit 29cf62d201
2 changed files with 3 additions and 37 deletions

View File

@ -38,11 +38,9 @@
#include "video/mp_image.h"
#if HAVE_GL_COCOA
#ifdef GL_VERSION_3_0
#include <OpenGL/gl3.h>
#else
#define GL_DO_NOT_WARN_IF_MULTI_GL_VERSION_HEADERS_INCLUDED 1
#include <OpenGL/gl.h>
#endif
#include <OpenGL/gl3.h>
#include <OpenGL/glext.h>
#else
#include <GL/gl.h>

View File

@ -57,42 +57,10 @@
#define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001
#endif
// Define just enough constants to make the OpenGL 3 code compile against
// older SDKs. Values are taken straight from OpenGL/gl3.h
#if defined __APPLE__ && !(defined GL_VERSION_3_0)
#define GL_RGBA16F 0x881A
#define GL_RGB16F 0x881B
#define GL_MAJOR_VERSION 0x821B
#define GL_MINOR_VERSION 0x821C
#define GL_NUM_EXTENSIONS 0x821D
#ifndef GL_ARB_framebuffer_sRGB
#define GL_FRAMEBUFFER_SRGB 0x8DB9
#endif
#endif
#ifndef GL_RGB_422_APPLE
#define GL_RGB_422_APPLE 0x8A1F
#endif
#ifndef UNSIGNED_SHORT_8_8_APPLE
#define UNSIGNED_SHORT_8_8_APPLE 0x85BA
#endif
#ifndef UNSIGNED_SHORT_8_8_APPLE
#define UNSIGNED_SHORT_8_8_APPLE 0x85BB
#endif
#ifndef GL_NV_vdpau_interop
#define GLvdpauSurfaceNV GLintptr
#endif
// OSX
#ifndef GL_RED_INTEGER
#define GL_RED_INTEGER 0x8D94
#define GL_RGB_INTEGER 0x8D98
#define GL_RGBA_INTEGER 0x8D99
#endif
#ifndef GL_DEBUG_SEVERITY_HIGH
#define GL_DEBUG_SEVERITY_HIGH 0x9146
#define GL_DEBUG_SEVERITY_MEDIUM 0x9147
@ -102,7 +70,7 @@
#undef MP_GET_GL_WORKAROUNDS
#endif
#endif // MP_GET_GL_WORKAROUNDS
#ifdef MP_GET_GLX_WORKAROUNDS