[mythtv] Anyone working on direct MPEG2 encoding?

Geoffrey Hausheer ou401cru02 at sneakemail.com
Thu Jan 1 17:40:24 EST 2004


On Thu, 1 Jan 2004 22:24:53 +0100, "Kenneth Aafløy" said:
> Chris Petersen wrote:
> > Chris Osgood wrote:
> > > I'd like to encode directly to MPEG2 off my bttv card so 
> > > that I can use the PVR350's hardware decoder for output.
> > > Now that ffmpeg supports mpeg2 encoding are there any plans
> > > to add that as a direct encoding target?
> 
> I'm pretty sure nobody is working on this, and I would really like to
> see this as a feature, as long as the fact that (for the most part) what
> you reffer to as mpeg2 encoding, would become libavcodec supported
> encoding. This would also have the side effect (if i'm not mistaken) of
> adding (with a little effort) support for this to mythtranscode.
> 
First off, implementation won't be trivial but not too difficult.  Making
an mpeg2 compliant stream isn't hard using libavformat.  libavcodec can
do the encoding.  However, I can't imagine this working in real time.  I
think using mpeg2enc would be a bad idea.  libav* is already well
integrated in mythtv, and the ffmpeg guys have been doing a lot of work
on mpeg2 lately.

Once it is there, it would allow rtjpeg/mpeg4->mpeg2 transcoding, but it
wouldn't be helpful for the mpeg2->mpeg2 commercial-cut stuff (which is
mostly working now anyway).  It may help with getting frame-exact cuts
though (though I plan to do this in a different way using gop-exact cuts)

Anyhow, I'm not aware of anyone working on it, though last time I
proposed to attempt it (knowing a lot less about MPEG2 than I do today),
there wasn't all that much interest.

Note that the quality won't be great, since real-time encoding is 1-pass
(I believe the 1st pass is used to determine how to allocate the
bandwidth, whereas the second does the encoding...and that doesn't work
well in real-time).  In general incorporating a two-pass encoder won't be
easy.  Better to just use one of the currently availiable tools for the
job (nuvexport comes to mind)

.Geoff


More information about the mythtv-dev mailing list