[Bf-blender-cvs] [15fd37f] master: Rake: store last position from mouse, don't store halfpoint between last and current position.
Antony Riakiotakis
noreply at git.blender.org
Thu May 7 15:04:29 CEST 2015
Commit: 15fd37fab23ad906942726162a677d9254a94be4
Author: Antony Riakiotakis
Date: Thu May 7 15:03:55 2015 +0200
Branches: master
https://developer.blender.org/rB15fd37fab23ad906942726162a677d9254a94be4
Rake: store last position from mouse, don't store halfpoint between last
and current position.
patch by Bastien
===================================================================
M source/blender/blenkernel/intern/paint.c
===================================================================
diff --git a/source/blender/blenkernel/intern/paint.c b/source/blender/blenkernel/intern/paint.c
index 3900ba8..1284ffd 100644
--- a/source/blender/blenkernel/intern/paint.c
+++ b/source/blender/blenkernel/intern/paint.c
@@ -536,7 +536,6 @@ static void update_brush_rake_rotation(UnifiedPaintSettings *ups, Brush *brush,
void paint_calculate_rake_rotation(UnifiedPaintSettings *ups, Brush *brush, const float mouse_pos[2])
{
if ((brush->mtex.brush_angle_mode & MTEX_ANGLE_RAKE) || (brush->mask_mtex.brush_angle_mode & MTEX_ANGLE_RAKE)) {
- const float u = 0.5f;
const float r = RAKE_THRESHHOLD;
float rotation;
@@ -546,8 +545,7 @@ void paint_calculate_rake_rotation(UnifiedPaintSettings *ups, Brush *brush, cons
if (len_squared_v2(dpos) >= r * r) {
rotation = atan2f(dpos[0], dpos[1]);
- interp_v2_v2v2(ups->last_rake, ups->last_rake,
- mouse_pos, u);
+ copy_v2_v2(ups->last_rake, mouse_pos);
ups->last_rake_angle = rotation;
More information about the Bf-blender-cvs
mailing list