Log in

View Full Version : loading audio and video


Zodiacal
4th January 2003, 10:12
How come my 3.5 .avs file doesn’t recognize the setting of a the V varable for the Mpeg2source function? I can load the video with out the audio and I can load the audio with a blank video but not both together cuz I have to use V=Mpeg2source but it doesn’t seem to like the V=. i get an error saying this:
Avisynth open failure:
Avisynth open failure:
Script error: Invalid arguments to function "YV12toYUY2"
If i remove the lines:
YV12toYUY2()
LanczosResize(320,240)
then i get this error:
AVISource: couldn't locate a decompressor for fourcc YV12

Any ideas?
here is my .avs below:
LoadPlugin("c:\extract\MPEG2Dec3.dll")
LoadPlugin("c:\extract\mpasource.dll")
V=mpeg2source("c:\extract\THE.d2v")
#crop(4,4,712,472)
YV12toYUY2()
LanczosResize(320,240)
A=MPASource("c:\extract\the.m2a", normalize = false)
return AudioDub(V,A)

hakko504
4th January 2003, 10:43
Since you load the video into the variable V then the implicit 'last' is not set and then you try to use 'last'. Can't work. If you use 'V=' then the next line should begin with either 'V=V.' or 'V.' In your case:LoadPlugin("c:\extract\MPEG2Dec3.dll")
LoadPlugin("c:\extract\mpasource.dll")
V=mpeg2source("c:\extract\THE.d2v")
#V=V.crop(4,4,712,472)
#V=V.YV12toYUY2()
V=V.LanczosResize(320,240)
A=MPASource("c:\extract\the.m2a", normalize = false)
return AudioDub(V,A)or the easierLoadPlugin("c:\extract\MPEG2Dec3.dll")
LoadPlugin("c:\extract\mpasource.dll")
mpeg2source("c:\extract\THE.d2v")
#crop(4,4,712,472)
#YV12toYUY2()
V=last.LanczosResize(320,240)
A=MPASource("c:\extract\the.m2a", normalize = false)
return AudioDub(V,A)Also, as far as I can see there is no need to convert the colorspace from YV12 to YUY2. It just takes extra time. The error you get is probably because you do not have a YV12 handler installed like DivX5.02 or XviD (some versions, don't remember which)

Zodiacal
4th January 2003, 11:22
unrecognized exeption is the error i get when i run your scripts you just posted.. i installed divx package like you shuggested. where can i find mpeg2dec2.dll for download? maybe that will work.