Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2014-04-21 08:30:13 +0400
committerCampbell Barton <ideasman42@gmail.com>2014-04-21 08:30:13 +0400
commitb1e1f86eb7cfe040bd301beb91fb35a1c748667e (patch)
tree14f7cd2701cd6e196a3dc8ebab816882d3643991 /source/blender/editors/gpencil
parent3a950dc643c39073e573b2e3547701a705ee0808 (diff)
Fix for UI_view2d_to_region_float (was ignoring x,y args)
use this for grease pencil stroke conversion to avoid float->int->float conversion.
Diffstat (limited to 'source/blender/editors/gpencil')
-rw-r--r--source/blender/editors/gpencil/gpencil_edit.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c
index 4c4926f5ae7..4a688f11767 100644
--- a/source/blender/editors/gpencil/gpencil_edit.c
+++ b/source/blender/editors/gpencil/gpencil_edit.c
@@ -456,10 +456,8 @@ static void gp_strokepoint_convertcoords(bContext *C, bGPDstroke *gps, bGPDspoin
/* get screen coordinate */
if (gps->flag & GP_STROKE_2DSPACE) {
- int mvali[2];
View2D *v2d = &ar->v2d;
- UI_view2d_view_to_region(v2d, pt->x, pt->y, mvali, mvali + 1);
- VECCOPY2D(mvalf, mvali);
+ UI_view2d_to_region_float(v2d, pt->x, pt->y, &mvalf[0], &mvalf[1]);
}
else {
if (subrect) {