[Xvid-devel] xvid_encraw: AVI output >2 GB?
michael at xvid.org
Tue Jul 7 15:32:40 CEST 2015
the xvid_encraw example does not have its own AVI muxer but it uses the
AVIFile API on windows. And I think you are correct: AVIFile has a size
limitation of 2 GB.
We have no plans creating an own AVI muxer for xvid_encraw to circumvent
this size limitation. What you could do instead is to use the VfW encoder
via DirectShow or Media Foundation (like the Xvid MiniConvert example
does) - the DirectShow AVI muxer does not have the 2 GB size limitation.
Other options would be to encode to a raw .m4v and then mux to AVI with
some muxing tool. ffmpeg would be one option and setting the FourCC
to "xvid"/"XVID" afterwards should be rather easy. A bigger issue might
be the "packed b-frames" feature of xvid_encraw in case you need it - I'd
guess this won't come out properly when you first encode to .m4v and then
mux with ffmpeg. Another option over ffmpeg might be MP4Box from the
gpac project - iirc, it can import raw m4v streams and output video muxed
as AVI. Also it's supposed to handle packed b-frames correctly. Finally,
there's also still AVIMux-GUI, which I think can also be scripted...
Quoting Mario *LigH* Rohkrämer <contact at ligh.de>:
> Is it correct that xvid_encraw does not support OpenDML AVI output, hence
> limits created AVIs to 2 GB?
> And because it is an "example project", it is probably never planned to be
> Would it be necessary to either prefer ffmpeg/mencoder with linked libxvid
> to encode directly to a large AVI, or let xvid_encraw create a raw m4v
> file and use a supporting multiplexer (probably only ffmpeg) later?
> The latter will have the disadvantage that a following multiplexer needs
> to get told the FourCCs to be filled in the AVI header (except it would
> derive them from the m4v input format). I guess that the second FourCC (in
> the compression field of the BITMAPINFOHEADER structure) will be the only
> relevant for most players; but I can't be certain that no software ever
> will check the first FourCC too (the "used encoder" in the "vids" chunk).
> I found that ffmpeg as AVI multiplexer will use a forced FourCC via
> "-vtag" parameter, but apply both the same, whereas the VfW uses distinct
> FourCCs (lowercase "xvid" in "vids" chunk and uppercase "XVID" in
> compression field).
> Fun and success!
> Mario *LigH* Rohkrämer
> mailto:contact at ligh.de
> Xvid-devel mailing list
> Xvid-devel at xvid.org
More information about the Xvid-devel