[Bf-blender-cvs] [89d2099] master: Sequencer: handles drew outside of small strips

Campbell Barton noreply at git.blender.org
Fri Nov 14 16:53:39 CET 2014


Commit: 89d20990e591c0bc0e82e7d5d4f1c37e106cc87f
Author: Campbell Barton
Date:   Fri Nov 14 16:47:30 2014 +0100
Branches: master
https://developer.blender.org/rB89d20990e591c0bc0e82e7d5d4f1c37e106cc87f

Sequencer: handles drew outside of small strips

===================================================================

M	source/blender/editors/space_sequencer/sequencer_draw.c

===================================================================

diff --git a/source/blender/editors/space_sequencer/sequencer_draw.c b/source/blender/editors/space_sequencer/sequencer_draw.c
index 9fbca7b..90ba104 100644
--- a/source/blender/editors/space_sequencer/sequencer_draw.c
+++ b/source/blender/editors/space_sequencer/sequencer_draw.c
@@ -336,7 +336,10 @@ static float draw_seq_handle_size_get_clamped(Sequence *seq, const float pixelx)
 {
 	const float minhandle = pixelx * SEQ_HANDLE_SIZE_MIN;
 	const float maxhandle = pixelx * SEQ_HANDLE_SIZE_MAX;
-	return CLAMPIS(seq->handsize, minhandle, maxhandle);
+	float size = CLAMPIS(seq->handsize, minhandle, maxhandle);
+
+	/* ensure we're not greater then half width */
+	return min_ff(size, ((float)(seq->enddisp - seq->startdisp) / 2.0f) / pixelx);
 }
 
 /* draw a handle, for each end of a sequence strip */




More information about the Bf-blender-cvs mailing list