[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [50072] trunk/blender/source/blender: mask : skip self intersection on drawing when fill is disabled, since it was only drawing on one side of an unfilled spline.
Campbell Barton
ideasman42 at gmail.com
Tue Aug 21 11:20:35 CEST 2012
Revision: 50072
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=50072
Author: campbellbarton
Date: 2012-08-21 09:20:35 +0000 (Tue, 21 Aug 2012)
Log Message:
-----------
mask: skip self intersection on drawing when fill is disabled, since it was only drawing on one side of an unfilled spline.
Modified Paths:
--------------
trunk/blender/source/blender/blenfont/intern/blf_font.c
trunk/blender/source/blender/blenkernel/BKE_mask.h
trunk/blender/source/blender/blenkernel/intern/mask.c
trunk/blender/source/blender/editors/mask/mask_draw.c
Modified: trunk/blender/source/blender/blenfont/intern/blf_font.c
===================================================================
--- trunk/blender/source/blender/blenfont/intern/blf_font.c 2012-08-21 09:01:50 UTC (rev 50071)
+++ trunk/blender/source/blender/blenfont/intern/blf_font.c 2012-08-21 09:20:35 UTC (rev 50072)
@@ -229,9 +229,9 @@
FontBufInfoBLF *buf_info = &font->buf_info;
float b_col_float[4];
const unsigned char b_col_char[4] = {buf_info->col[0] * 255,
- buf_info->col[1] * 255,
- buf_info->col[2] * 255,
- buf_info->col[3] * 255};
+ buf_info->col[1] * 255,
+ buf_info->col[2] * 255,
+ buf_info->col[3] * 255};
unsigned char *cbuf;
int chx, chy;
@@ -242,7 +242,7 @@
blf_font_ensure_ascii_table(font);
- /* another buffer spesific call for color conversion */
+ /* another buffer specific call for color conversion */
if (buf_info->do_color_management) {
srgb_to_linearrgb_v4(b_col_float, buf_info->col);
}
Modified: trunk/blender/source/blender/blenkernel/BKE_mask.h
===================================================================
--- trunk/blender/source/blender/blenkernel/BKE_mask.h 2012-08-21 09:01:50 UTC (rev 50071)
+++ trunk/blender/source/blender/blenkernel/BKE_mask.h 2012-08-21 09:20:35 UTC (rev 50072)
@@ -78,7 +78,8 @@
float (*BKE_mask_spline_differentiate_with_resolution(struct MaskSpline *spline, int width, int height, int *tot_diff_point))[2];
float (*BKE_mask_spline_feather_differentiated_points_with_resolution_ex(struct MaskSpline *spline, int *tot_feather_point,
const unsigned int resol, const int do_feather_isect))[2];
-float (*BKE_mask_spline_feather_differentiated_points_with_resolution(struct MaskSpline *spline, int width, int height, int *tot_feather_point))[2];
+float (*BKE_mask_spline_feather_differentiated_points_with_resolution(struct MaskSpline *spline, int width, int height,
+ int *tot_feather_point, const int do_feather_isect))[2];
float (*BKE_mask_spline_feather_points(struct MaskSpline *spline, int *tot_feather_point))[2];
Modified: trunk/blender/source/blender/blenkernel/intern/mask.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/mask.c 2012-08-21 09:01:50 UTC (rev 50071)
+++ trunk/blender/source/blender/blenkernel/intern/mask.c 2012-08-21 09:20:35 UTC (rev 50072)
@@ -792,16 +792,16 @@
}
float (*BKE_mask_spline_feather_differentiated_points_with_resolution(MaskSpline *spline, int width, int height,
- int *tot_feather_point))[2]
+ int *tot_feather_point, const int do_feather_isect))[2]
{
unsigned int resol = BKE_mask_spline_feather_resolution(spline, width, height);
- return BKE_mask_spline_feather_differentiated_points_with_resolution_ex(spline, tot_feather_point, resol, TRUE);
+ return BKE_mask_spline_feather_differentiated_points_with_resolution_ex(spline, tot_feather_point, resol, do_feather_isect);
}
float (*BKE_mask_spline_feather_differentiated_points(MaskSpline *spline, int *tot_feather_point))[2]
{
- return BKE_mask_spline_feather_differentiated_points_with_resolution(spline, 0, 0, tot_feather_point);
+ return BKE_mask_spline_feather_differentiated_points_with_resolution(spline, 0, 0, tot_feather_point, TRUE);
}
float (*BKE_mask_spline_feather_points(MaskSpline *spline, int *tot_feather_point))[2]
Modified: trunk/blender/source/blender/editors/mask/mask_draw.c
===================================================================
--- trunk/blender/source/blender/editors/mask/mask_draw.c 2012-08-21 09:01:50 UTC (rev 50071)
+++ trunk/blender/source/blender/editors/mask/mask_draw.c 2012-08-21 09:20:35 UTC (rev 50072)
@@ -388,7 +388,7 @@
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
}
- feather_points = BKE_mask_spline_feather_differentiated_points_with_resolution(spline, width, height, &tot_feather_point);
+ feather_points = BKE_mask_spline_feather_differentiated_points_with_resolution(spline, width, height, &tot_feather_point, (is_fill != FALSE));
/* draw feather */
mask_spline_feather_color_get(masklay, spline, is_spline_sel, rgb_tmp);
More information about the Bf-blender-cvs
mailing list