digitalFAQ.com Forums [Archives]

digitalFAQ.com Forums [Archives] (http://www.digitalfaq.com/archives/)
-   Avisynth Scripting (http://www.digitalfaq.com/archives/avisynth/)
-   -   Avisynth: Multiple Avi Sources? (http://www.digitalfaq.com/archives/avisynth/2179-avisynth-multiple-avi.html)

urban tec 01-16-2003 07:23 PM

Avisynth: Multiple Avi Sources?
 
Recently I saw an avs script posted where multiple avi sources had been specified. Now I cant find the post for the life of me, could somebody give an example of a script where you load multiple avi sources.
The reason being I have several avis that make up a movie but have been encoded at different resolutions so cant be joined, eg 352 x 240, 360 x 240 etc only a couple of pixels diffrence in each.

SansGrip 01-16-2003 07:29 PM

Re: Multiple Avi Sources
 
Quote:

Originally Posted by urban tec
I have several avis that make up a movie but have been encoded at different resolutions so cant be joined, eg 352 x 240, 360 x 240 etc only a couple of pixels diffrence in each.

Code:

clip1 = AviSource("1st.avi") # it's 352x240
clip2 = AviSource("2nd.avi") # it's 360x240

clip2 = clip2.Crop(4, 0, 352, 240) # clip2 now 352x240

clip1 + clip2 # concatenate

You need to crop/resize each clip so that you end up with the same dimensions for each, otherwise Avisynth will complain when you try to join them together.

urban tec 01-16-2003 07:30 PM

Thanks Sansgrip I figured I would need to resize each, I will give it a try.

black prince 01-16-2003 09:48 PM

@Urban tec,

Urban tec wrote:
Quote:

Recently I saw an avs script posted where multiple avi sources had been specified.

LoadPlugin("E:\DVD Backup\2 - DVD2SVCD\MPEG2Dec\MPEG2DEC2.dll")
#
# ------ avi File Number 1 ------
video=avisource("D:\Temp\movie01.avi")
audio=WAVSource("D:\Temp\audio01.wav")
#
# ------ Remove A/V Frames in File 1 ------
part1=trim(AudioDub(video,audio),0,12620)
part2=trim(AudioDub(video,audio),15575,21844)
part3=trim(AudioDub(video,audio),30009,62366)
part4=trim(AudioDub(video,audio),63509,0)
clip1=part1+part2+part3+part4
#
# ------ avi File Number 2 ------
video2=avisource("D:\Temp\movie02.avi")
audio2=WAVSource("D:\Temp\audio02.wav")
clip2=AudioDub(video2,audio2)
#
# ------ avi File Number 3 ------
video3=avisource("D:\Temp\movie03.avi")
audio3=WAVSource("D:\Temp\audio03.wav")
clip3=AudioDub(video3,audio3)
#
# ------ avi File Number 4 ------
video4=avisource("D:\Temp\movie04.avi")
audio4=WAVSource("D:\Temp\audio04.wav")
clip4=AudioDub(video4,audio4)
#
# ------ Join All avi Files ------
unalignedsplice(clip1,clip2,clip3,clip4)
#
# ------ Resize ------
LegalClip()
Grip(704,480,overscan=1)
GripSize()
TemporalSmoother(2,2)
GripBorders()
LegalClip()


The wav file are used to keep it in sync with video when using Trim
to remove frames. I use this with Tmpgenc to encode audio and video.
I hope this will help. :)

-black prince

urban tec 01-16-2003 10:41 PM

Thanks Black Prince

I think that was the script I saw, I thought I had copied it but hadn't.

That is a good script to keep in the archive no doubt I will want to do similar one day.

Here is the script I ended up using

Code:

LoadPlugin("C:\Program Files\fitcd\MPEG2DEC.dll")


clip1 = AviSource("D:\temp\Downloads\1\movie1.avi",false)
clip2 = AviSource("D:\temp\Downloads\1\movie2.avi",false)
clip3 = AviSource("D:\temp\Downloads\1\movie3.avi",false)

clip1 = clip1.Crop(2, 0, 352, 240)
clip3 = clip3.BilinearResize(352,240,348,240)
clip1 + clip2 + clip3
ConvertToYUY2()

LegalClip()
Pixiedust()
Convolution3D(preset="movieLQ")
GripFit(352, 240, overscan=1)
#FluxSmooth()
GripBorders()


#sampler(length=24)

LegalClip()

its a 2 hr home vid and will take approx 6hrs to do on my P4 2Gig (damn that dust and C3D are slow but fantastic results) it will be interesting to see how it comes out.


All times are GMT -5. The time now is 09:20 AM  —  vBulletin © Jelsoft Enterprises Ltd

Site design, images and content © 2002-2024 The Digital FAQ, www.digitalFAQ.com
Forum Software by vBulletin · Copyright © 2024 Jelsoft Enterprises Ltd.