Log in

View Full Version : Dissolve & Audio


ang2u27
11th December 2005, 21:39
Hi. I'm new in AviSynth. I want to know how to add the original sound of my two clips when using filter Dissolve. I was tryng this:

a=AVISource("test1.avi") - without sound
b=AVISource("test2.avi") - without sound
Dissolve(a,b,100)
WavSource(audio.wav)

not work.
Please help me!

krieger2005
11th December 2005, 23:14
I dont't know if Dissolve works on sound.. but it seems, that you have only one wav-file which you mixed before together? If not there are still two other possibilities:
The first on is, when you have the sound IN the AVI-Files. The your call should be something like this:
a=AVISource("test1.avi",true)

But since you wrote, that the avi-source seemed to have not audio this could be the result you are searching for:
aAVI=avisource(...)
aWAV=WavSource(...)
a=AudioDub(aAVI,aWAV)

BTW: If you look in the Documentation of Avisynth and look especially the documentation of AudioDub you exactly the same code-snipplet.

IanB
11th December 2005, 23:16
AudioDub(WavSource("audio.wav"))

Ebobtron
12th December 2005, 05:50
@ krieger2005
AviSynth dissolves audio just fine.

@ ang2u27
If you have managed to dissolve the audio together external to avisynth then IanB suggestion for adding the audio will work great.

If your audio is not already dissolved together, the last clips video and audio will be out of sync by 100 frames.

If your wish is to dissolve the video and the audio try this.


a=AVISource("test1.avi")
b=AVISource("test2.avi")

v = a+b

AudioDub(v, WavSource("audio.wav"))

trim1 = trim(0, framecount(a)-1)
trim2 = trim(framecount(a), framecount(v)-1)

Dissolve(trim1, trim2, 100)

Good luck,
Ebobtron
http://members.aol.com/avsfilmcutter

Mug Funky
12th December 2005, 09:44
hmm... doesn't avisynth do only linear fades on audio? i see the advantages of doing the audio crossfades in an audio-specific program, then fading the video in avs.

another good thing is you can check sync easily in a sound app that supports avs files (Cooledit pro 2, or audition do this).

Ebobtron
12th December 2005, 15:56
@ Mug Funky

I like the linear fade on dissolves between two active audio sources. The slightly reduced level at the 50 percent point to me is preferred. Fade-in and fade-out is most noticeable though and it would be nice if AviSynth’s fades and dissolves had one more option.

I make no claim as to which is more correct only how to use AviSynth with the information we have, else we slip off topic.

Ebobtron