Navigation Menu

Skip to content

Commit

Permalink
Cleaned up half-float stuff.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Dec 21, 2011
1 parent d9f2f81 commit 80dd029
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions mojoshader_opengl.c
Expand Up @@ -37,8 +37,12 @@
#include "GL/gl.h"
#include "GL/glext.h"

#ifndef GL_HALF_FLOAT
#define GL_HALF_FLOAT 0x140B
#ifndef GL_HALF_FLOAT_NV
#define GL_HALF_FLOAT_NV 0x140B
#endif

#ifndef GL_HALF_FLOAT_ARB
#define GL_HALF_FLOAT_ARB 0x140B
#endif

#ifndef GL_HALF_FLOAT_OES
Expand Down Expand Up @@ -2139,9 +2143,9 @@ static inline GLenum opengl_attr_type(const MOJOSHADER_attributeType type)
if (ctx->have_GL_NV_half_float)
return GL_HALF_FLOAT_NV;
else if (ctx->have_GL_ARB_half_float_vertex)
return GL_HALF_FLOAT;
return GL_HALF_FLOAT_ARB;
else if (ctx->have_GL_OES_vertex_half_float)
return GL_HALF_FLOAT;
return GL_HALF_FLOAT_OES;
break;
} // switch

Expand Down

0 comments on commit 80dd029

Please sign in to comment.