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:
authorJoerg Mueller <nexyon@gmail.com>2011-07-26 17:56:31 +0400
committerJoerg Mueller <nexyon@gmail.com>2011-07-26 17:56:31 +0400
commit9077b8bffc6731062bbd6997379b4bf6badd13e2 (patch)
tree641b4fdb97c201727107c398517233ca313d1f38 /source/blender/blenkernel/intern/sequencer.c
parentc0373fb7ea2b6d36b57a7c43706626aa254c70b3 (diff)
3D Audio GSoC:
Main: Complete rewrite of the sequencer related audio code to support 3D Audio objects later and especially adressing the animation system problems (see mailing list if interested). Note: Animation is not working yet, so with this commit volume animation doesn't work anymore, that's the next step. Minor things: * Changed AUD_Reference behaviour a little to be more usage safe. * Fixed bug in AUD_I3DHandle: Missing virtual destructor * Fixed enmus in AUD_Space.h * Fixed a warning in rna_scene.c * Removed an unneeded call in rna_sound.c
Diffstat (limited to 'source/blender/blenkernel/intern/sequencer.c')
-rw-r--r--source/blender/blenkernel/intern/sequencer.c27
1 files changed, 25 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/sequencer.c b/source/blender/blenkernel/intern/sequencer.c
index 9673fee0b63..e4dc3a31cb1 100644
--- a/source/blender/blenkernel/intern/sequencer.c
+++ b/source/blender/blenkernel/intern/sequencer.c
@@ -533,7 +533,7 @@ void calc_sequence_disp(Scene *scene, Sequence *seq)
seq->handsize= (float)((seq->enddisp-seq->startdisp)/25);
}
- seq_update_sound(scene, seq);
+ seq_update_sound_bounds(scene, seq);
}
static void seq_update_sound_bounds_recursive(Scene *scene, Sequence *metaseq)
@@ -3145,7 +3145,7 @@ int shuffle_seq_time(ListBase * seqbasep, Scene *evil_scene)
return offset? 0:1;
}
-void seq_update_sound(Scene* scene, Sequence *seq)
+void seq_update_sound_bounds(Scene* scene, Sequence *seq)
{
if(seq->scene_sound)
{
@@ -3193,6 +3193,29 @@ void seq_update_muting(Scene *scene, Editing *ed)
}
}
+static void seq_update_sound_recursive(Scene *scene, ListBase *seqbasep, bSound *sound)
+{
+ Sequence *seq;
+
+ for(seq=seqbasep->first; seq; seq=seq->next) {
+ if(seq->type == SEQ_META) {
+ seq_update_sound_recursive(scene, &seq->seqbase, sound);
+ }
+ else if(seq->type == SEQ_SOUND) {
+ if(seq->scene_sound && sound == seq->sound) {
+ sound_update_scene_sound(seq->scene_sound, sound);
+ }
+ }
+ }
+}
+
+void seq_update_sound(struct Scene *scene, struct bSound *sound)
+{
+ if(scene->ed) {
+ seq_update_sound_recursive(scene, &scene->ed->seqbase, sound);
+ }
+}
+
/* in cases where we done know the sequence's listbase */
ListBase *seq_seqbase(ListBase *seqbase, Sequence *seq)
{