diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2015-10-04 10:31:17 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2015-10-04 10:31:17 +0300 |
commit | 52f74923e6957b4dc6e7b37514d864588b922ae6 (patch) | |
tree | 2db78fbec9d41673797e9a9fca28c0692a7b488d /source/blender/editors/transform/transform.c | |
parent | 61218546cb79dbae09a6102a5695878ea96d0045 (diff) |
Fix (coverity-reported) broken 'transform helpers' drawing.
E.g. trackball-arrows (R-R) were no more visible.
Caused by wrong cast of an array from int to float, we need an int version of those helpers (`glTranslatenxv`) too.
Diffstat (limited to 'source/blender/editors/transform/transform.c')
-rw-r--r-- | source/blender/editors/transform/transform.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/editors/transform/transform.c b/source/blender/editors/transform/transform.c index 6931efdbd6a..9aa22ed737f 100644 --- a/source/blender/editors/transform/transform.c +++ b/source/blender/editors/transform/transform.c @@ -1720,7 +1720,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata) glVertex2fv(cent); glEnd(); - glTranslate2fv((const float *)mval); + glTranslate2iv(mval); glRotatef(-RAD2DEGF(atan2f(cent[0] - t->mval[0], cent[1] - t->mval[1])), 0, 0, 1); setlinestyle(0); @@ -1732,7 +1732,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata) case HLP_HARROW: UI_ThemeColor(TH_VIEW_OVERLAY); - glTranslate2fv((const float *)mval); + glTranslate2iv(mval); glLineWidth(3.0); drawArrow(RIGHT, 5, 10, 5); @@ -1742,7 +1742,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata) case HLP_VARROW: UI_ThemeColor(TH_VIEW_OVERLAY); - glTranslate2fv((const float *)mval); + glTranslate2iv(mval); glLineWidth(3.0); drawArrow(UP, 5, 10, 5); @@ -1793,7 +1793,7 @@ static void drawHelpline(bContext *UNUSED(C), int x, int y, void *customdata) unsigned char col[3], col2[3]; UI_GetThemeColor3ubv(TH_GRID, col); - glTranslate2fv((const float *)mval); + glTranslate2iv(mval); glLineWidth(3.0); |