Log in

View Full Version : Command-line AVI muxer?


MOverride
21st September 2009, 22:36
I'm looking to mux raw VC-1 files (ripped from a Blu-ray via DumpHD into a .m2ts file, subsequently extracted by EAC3TO) into .AVI files so that they can be opened by AVISynth and used by MeGUI to encode to H264.

Currently, my toolchain has me muxing the raw VC-1 files into MKV with mkvtools/mkvmerge, and then extracting that into an AVI via mkvtools/mkvextract. This... sort of works, but seems to be running into 4 GB issues (the same frame is repeated for about the last 20% of a 5 GB VC-1 file).

I've also tried using FFmpegSource2 to directly access the .MKV via AviSynth (instead of converting to AVI), but I'm not convinced that this is working--MeGUI complains of colorspace issues even with ConvertToYV12(). It also takes twice as long as via AVI, though it encodes the entire file correctly in terms of frames (no idea how to tell what colorspace it's using in the final file...) which is a plus.

There's got to be a more efficient way of handling this, doesn't there?

(I'm looking for a way of doing this without DirectShow filters, so installing Haali to have EAC3TO go directly to MKV is out. Even if that worked, there's still the colorspace issue, I suspect.)

Yes, I've searched; no, I didn't find anything useful.

Just in case they're useful, the two AviSynth scripts:

FFImageSource("D:\ripping\chuckS1D1\chuck101.mkv")
ConvertToYV12()
lanczosresize(640,352)

DirectShowSource("D:\ripping\chuckS1D1\chuck101.avi")
lanczosresize(640,352)

Inspector.Gadget
21st September 2009, 22:45
There's VC12AVI, but it splits into 2GB chunks so you'll need to either append with Virtualdub first or append in Avisynth. What't the error message in MeGUI with the colorspace?

MOverride
21st September 2009, 23:32
There's VC12AVI, but it splits into 2GB chunks so you'll need to either append with Virtualdub first or append in Avisynth.
And isn't command-line.

What't the error message in MeGUI with the colorspace?
When I click Enqueue, even with the script with that already in it:

"Incorrect Colorspace
"Your AviSynth clip is is the wrong colorspace, I420.
"The colorspace should by YV12. Do you want me to add ConvertToYV12() to the end of your script?"

(Nice typos in there. :p)

When I click Yes:

"Problem in AviSynth
"Your AviSynth script has the following problem:
"AviSynth clip is in I420 not YV12, even though ConvertToYV12() has been appended.
"Continue anyway?"

Inspector.Gadget
21st September 2009, 23:38
Try installing ffdshow, setting it to decode VC1 with wmv9 (rather than LAVC), disabling all processing filters, and allowing the output colorspace to be only YV12. Do you still get the MeGUI error?

b66pak
22nd September 2009, 19:26
you should keep the vc1 in .mkv...the avisynth scripts are OK...add info() at the end of one of then and you will see (when play it) info about the colorspace (should be YV12 even without "ConvertToYV12()")...after you are convinced that colorspace is OK you should disregard the MeGUI warning...
_

MOverride
23rd September 2009, 01:01
you should keep the vc1 in .mkv...the avisynth scripts are OK...add info() at the end of one of then and you will see (when play it) info about the colorspace (should be YV12 even without "ConvertToYV12()")...after you are convinced that colorspace is OK you should disregard the MeGUI warning...
_
Why so it is okay. Thanks for that. :) :thanks:

And switching to non-threaded FFMPEGSource2 improved results. Still not as fast as AVI, but it's actually correct, which is a plus. I think I'll be satisfied with the current arrangement, unless somebody has a brilliant suggestion for trimming this chain down without violating the "Thou Shalt Not Run Installers For Any Crap Beyond AviSynth" precept. :)