Revision: 58761
          
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=58761
Author:   psy-fi
Date:     2013-07-31 10:05:47 +0000 (Wed, 31 Jul 2013)
Log Message:
-----------
* Fix accumulation working only when pressure alpha influence was active.

* Draw stroke line with outline, it helps in backgrounds that do not have
enough contrast.

Modified Paths:
--------------
    branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_image.c
    branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_stroke.c

Modified: 
branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_image.c
===================================================================
--- branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_image.c   
2013-07-31 09:42:07 UTC (rev 58760)
+++ branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_image.c   
2013-07-31 10:05:47 UTC (rev 58761)
@@ -645,6 +645,8 @@
 
        if (BKE_brush_use_alpha_pressure(scene, brush))
                BKE_brush_alpha_set(scene, brush, max_ff(0.0f, startalpha * 
pressure * alphafac));
+       else
+               BKE_brush_alpha_set(scene, brush, max_ff(0.0f, startalpha * 
alphafac));
 
        BKE_brush_size_set(scene, brush, max_ff(1.0f, size));
 

Modified: 
branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_stroke.c
===================================================================
--- branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_stroke.c  
2013-07-31 09:42:07 UTC (rev 58760)
+++ branches/soc-2013-paint/source/blender/editors/sculpt_paint/paint_stroke.c  
2013-07-31 10:05:47 UTC (rev 58761)
@@ -120,12 +120,19 @@
        PaintStroke *stroke = customdata;
 
        if (stroke && brush) {
-               glColor4ubv(paint->paint_cursor_col);
                glEnable(GL_LINE_SMOOTH);
                glEnable(GL_BLEND);
 
+               glColor4ub(0, 0, 0, paint->paint_cursor_col[3]);
+               glLineWidth(4.0);
                sdrawline(x, y, (int)stroke->last_mouse_position[0],
                          (int)stroke->last_mouse_position[1]);
+
+               glColor4ubv(paint->paint_cursor_col);
+               glLineWidth(2.0);
+               sdrawline(x, y, (int)stroke->last_mouse_position[0],
+                         (int)stroke->last_mouse_position[1]);
+
                glDisable(GL_BLEND);
                glDisable(GL_LINE_SMOOTH);
        }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to