summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mesa/main/api_loopback.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/main/api_loopback.c b/src/mesa/main/api_loopback.c
index a7fd82c531f..8b63d9c0e95 100644
--- a/src/mesa/main/api_loopback.c
+++ b/src/mesa/main/api_loopback.c
@@ -629,7 +629,10 @@ _mesa_Vertex2sv( const GLshort *v )
void GLAPIENTRY
_mesa_Vertex3dv( const GLdouble *v )
{
- VERTEX3( (GLfloat) v[0], (GLfloat) v[1], (GLfloat) v[2] );
+ if (v[2] == 0.0)
+ VERTEX2( (GLfloat) v[0], (GLfloat) v[1] );
+ else
+ VERTEX3( (GLfloat) v[0], (GLfloat) v[1], (GLfloat) v[2] );
}
void GLAPIENTRY