mirror of
https://github.com/yawut/SDL.git
synced 2026-09-08 09:06:29 -05:00
Fixed direction of rotation with OpenGL ES 2
This commit is contained in:
@@ -1341,7 +1341,7 @@ GLES2_RenderCopyEx(SDL_Renderer *renderer, SDL_Texture *texture, const SDL_Rect
|
||||
|
||||
rdata->glEnableVertexAttribArray(GLES2_ATTRIBUTE_CENTER);
|
||||
rdata->glEnableVertexAttribArray(GLES2_ATTRIBUTE_ANGLE);
|
||||
fAngle[0] = fAngle[1] = fAngle[2] = fAngle[3] = (GLfloat)angle;
|
||||
fAngle[0] = fAngle[1] = fAngle[2] = fAngle[3] = (GLfloat)(360.0f - angle);
|
||||
/* Calculate the center of rotation */
|
||||
translate[0] = translate[2] = translate[4] = translate[6] = (center->x + dstrect->x);
|
||||
translate[1] = translate[3] = translate[5] = translate[7] = (center->y + dstrect->y);
|
||||
|
||||
Reference in New Issue
Block a user