diff options
author | Dave Airlie <[email protected]> | 2010-01-18 16:29:31 +1000 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2010-01-23 12:28:32 +1000 |
commit | cfe884e2030466df673881da8e830c300dda40db (patch) | |
tree | dbab66e31a8bfa8739ef0e7053b4686d32595e2e /src/mesa/main/varray.c | |
parent | 1ac5fd594a00d83f9b103ac6261bedabdb7e6b32 (diff) |
mesa: add core support for ARB_half_float_vertex.
Adds the extension to the list + support to the APIs.
also add t_draw.c support to convert for sw rast.
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/mesa/main/varray.c')
-rw-r--r-- | src/mesa/main/varray.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c index c2193074cdf..0b6295d5e16 100644 --- a/src/mesa/main/varray.c +++ b/src/mesa/main/varray.c @@ -121,6 +121,9 @@ _mesa_VertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *ptr) case GL_DOUBLE: elementSize = size * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = size * sizeof(GLhalfARB); + break; #if FEATURE_fixedpt case GL_FIXED: elementSize = size * sizeof(GLfixed); @@ -174,6 +177,9 @@ _mesa_NormalPointer(GLenum type, GLsizei stride, const GLvoid *ptr ) case GL_DOUBLE: elementSize = 3 * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = 3 * sizeof(GLhalfARB); + break; #if FEATURE_fixedpt case GL_FIXED: elementSize = 3 * sizeof(GLfixed); @@ -250,6 +256,9 @@ _mesa_ColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *ptr) case GL_DOUBLE: elementSize = size * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = size * sizeof(GLhalfARB); + break; #if FEATURE_fixedpt case GL_FIXED: elementSize = size * sizeof(GLfixed); @@ -285,6 +294,9 @@ _mesa_FogCoordPointerEXT(GLenum type, GLsizei stride, const GLvoid *ptr) case GL_DOUBLE: elementSize = sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = sizeof(GLhalfARB); + break; default: _mesa_error( ctx, GL_INVALID_ENUM, "glFogCoordPointer(type)" ); return; @@ -394,6 +406,9 @@ _mesa_SecondaryColorPointerEXT(GLint size, GLenum type, case GL_DOUBLE: elementSize = size * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = size * sizeof(GLhalfARB); + break; default: _mesa_error( ctx, GL_INVALID_ENUM, "glSecondaryColorPointer(type=%s)", _mesa_lookup_enum_by_nr(type)); @@ -441,6 +456,9 @@ _mesa_TexCoordPointer(GLint size, GLenum type, GLsizei stride, case GL_DOUBLE: elementSize = size * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = size * sizeof(GLhalfARB); + break; #if FEATURE_fixedpt case GL_FIXED: elementSize = size * sizeof(GLfixed); @@ -670,6 +688,9 @@ _mesa_VertexAttribPointerARB(GLuint index, GLint size, GLenum type, case GL_DOUBLE: elementSize = size * sizeof(GLdouble); break; + case GL_HALF_FLOAT: + elementSize = size * sizeof(GLhalfARB); + break; #if FEATURE_fixedpt case GL_FIXED: elementSize = size * sizeof(GLfixed); |