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>2007-10-09 04:22:59 +0400
committerCampbell Barton <ideasman42@gmail.com>2007-10-09 04:22:59 +0400
commit80af4ce69d0e050aef3654977638a6613654a60b (patch)
treef3f45b99c9238326cd4615bc115abc9404964234 /source/blender/src/drawseq.c
parent7d82b7720993fcf0eda749bf52c83dd2ddcd3c20 (diff)
Sequencer
changed teh way single images operate, * they dont act like a sequence of 1 image - so you can drag and resize without the trouble of having teh center image. * they draw without the single frame in them. and no 'gutter?' strip drawing. * the start frame is always set to be where the handles start. This is done in the transform and draw areas of the sequencer. added 2 functions, fix_single_image_seq - moves the seq start without any visible change - so it will load in older blend's check_single_image_seq - quick way to check for single image.
Diffstat (limited to 'source/blender/src/drawseq.c')
-rw-r--r--source/blender/src/drawseq.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/source/blender/src/drawseq.c b/source/blender/src/drawseq.c
index a6d5cc90842..fbbaf54fa29 100644
--- a/source/blender/src/drawseq.c
+++ b/source/blender/src/drawseq.c
@@ -686,9 +686,12 @@ so wave file sample drawing precission is zoom adjusted
static void draw_seq_strip(Sequence *seq, ScrArea *sa, SpaceSeq *sseq)
{
float x1, x2, y1, y2;
- char col[3];
+ char col[3], is_single_image;
Sequence *last_seq = get_last_seq();
+ /* we need to know if this is a single image or not for drawing */
+ is_single_image = (char)check_single_image_seq(seq);
+
/* body */
if(seq->startstill) x1= seq->start;
else x1= seq->startdisp;
@@ -702,11 +705,18 @@ static void draw_seq_strip(Sequence *seq, ScrArea *sa, SpaceSeq *sseq)
get_seq_color3ubv(seq, col);
/* draw the main strip body */
- draw_shadedstrip(seq, col, x1, y1, x2, y2);
+ if (is_single_image) /* single image */
+ draw_shadedstrip(seq, col, SEQ_GET_FINAL_LEFT(seq), y1, SEQ_GET_FINAL_RIGHT(seq), y2);
+ else /* normal operation */
+ draw_shadedstrip(seq, col, x1, y1, x2, y2);
/* draw additional info and controls */
- if (seq->type == SEQ_RAM_SOUND) drawseqwave(seq, x1, y1, x2, y2, sa->winx);
- draw_seq_extensions(seq, sseq);
+ if (seq->type == SEQ_RAM_SOUND)
+ drawseqwave(seq, x1, y1, x2, y2, sa->winx);
+
+ if (!is_single_image)
+ draw_seq_extensions(seq, sseq);
+
draw_seq_handle(seq, sseq, SEQ_LEFTHANDLE);
draw_seq_handle(seq, sseq, SEQ_RIGHTHANDLE);