Avisynth: Multiple Clips to one mpeg file?
Just a question I didnt find a answer to on the avisynth pages:
Is it possible to add more than one movie clip in the same script?The point is to get one mpeg file out of the clips. And if yes,will it be something like this: a=AviSource("C:\Movie 1.avi") b=AviSource("C:\Movie 2.avi") and so on?? What about Trim()? Let say I want the video in the first clip to go from frame 24 to 3452 and from 5678 to 12345 Is it possible? and will the line be something like this: a=trim(24,3452),(5678,12345) b=trim(3333,8888),(9999,9999) ?? -------------------- viking |
You can do
a=avisource(...) b=avisource(...) or avisource(...)+avisource(...) and you can do c=trim(a,100,200)+trim(a,500,700)+trim(b,500,1000) I have a feeling that you can do c=a.trim(100,200)+a.trim(500,700)+b.trim(500,1000) but I'm not sure. But you can definately do a = AVISource("d:\capture.00.avi") b = AVISource("d:\capture.01.avi") c = AVISource("d:\capture.02.avi") sound_track = WAVSource("d:\audio.wav") AudioDub(a+b+c, sound_track) |
Nope! Trim() will do refer to the "last" video stream where ist applied and in your case it would be the ready merged streams so your cut point would be screwed up!
This is the way to go ...: a=AviSource("C:\Movie 1.avi").trim(24,3452)++trim(5678,12345) b=AviSource("C:\Movie 2.avi").trim(3333,8888)++trim(8889,9999) return a+b EDIT: aaaah Latexx was first :) |
Re: Multiple Clips to one mpeg file
Quote:
You just have to generete a merged clip after all the "avisource" by using the "++" operator. Code:
a=AviSource("C:\Movie 1.avi") Quote:
Quote:
b=AviSource("C:\Movie 2.avi") trim(a,24,3524)++trim(a,5678,12345)++trim(b,3333,8 888))... Read the manual, you will see that all commands have a first optional parameter called "clip" where you can give the name of the clip that will be affected by the command. By default it's the last one produced. EDIT: inc, no need to use "return" if not in a function. and it's better to use ++ than + if the clip has sound (see AlignedSplice and UnalignSplice in the doc) |
Damned! Thats what we call fast replies! :lol:
Thanks a lot for the info.Im already making a script. And its possible to have clips from a to z I guess? Yes,all my clips have the same resolution. --------------- viking |
Quote:
Note : if they you have a lot of them, perhaps it's faster to name them correctly and to use SegmentedAVISource |
Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.