Fixed direction of rotation with OpenGL ES 2
authorSam Lantinga <slouken@libsdl.org>
Sun, 27 Jan 2013 15:52:56 -0800
changeset 6825a9c669052fa2
parent 6824 436b5b8a5b98
child 6826 7fd31621ce9c
Fixed direction of rotation with OpenGL ES 2
src/render/opengles2/SDL_render_gles2.c
     1.1 --- a/src/render/opengles2/SDL_render_gles2.c	Sat Jan 26 12:31:55 2013 -0300
     1.2 +++ b/src/render/opengles2/SDL_render_gles2.c	Sun Jan 27 15:52:56 2013 -0800
     1.3 @@ -1341,7 +1341,7 @@
     1.4      
     1.5      rdata->glEnableVertexAttribArray(GLES2_ATTRIBUTE_CENTER);
     1.6      rdata->glEnableVertexAttribArray(GLES2_ATTRIBUTE_ANGLE);
     1.7 -    fAngle[0] = fAngle[1] = fAngle[2] = fAngle[3] = (GLfloat)angle;
     1.8 +    fAngle[0] = fAngle[1] = fAngle[2] = fAngle[3] = (GLfloat)(360.0f - angle);
     1.9      /* Calculate the center of rotation */
    1.10      translate[0] = translate[2] = translate[4] = translate[6] = (center->x + dstrect->x);
    1.11      translate[1] = translate[3] = translate[5] = translate[7] = (center->y + dstrect->y);