[Ffmpeg-devel] [PATCH] introduce swscale interface in libavcodec

Luca Abeni lucabe72
Mon Apr 3 08:19:30 CEST 2006

Hi all,

I think I found a solution for eliminating the sws_convert() function
introduced in my last "import swscale" patch (as noted by Michael,
introducing such function was not a good idea at all).

The new idea is to completely move ffmpeg.c to the swscale interface
(this also addresses the "XXX: resampling could be done before raw
format conversion in some cases to go faster" and "XXX: only works for
YUV420P" comments in ffmpeg.c :). This means that if swscale is not
compiled in, libavcodec has to "emulate" its interface.

So, the first attached patch introduces the swscale interface in
libavcodec, and the second one modifies ffmpeg.c to use it (a similar
patch is also needed for output_example.c and ffplay.c... I'll provide
it if the first patch is accepted).
The two patches apply over the "copping/padding" patchset I posted some
time ago.

After applying these two patches, importing swscale becomes really easy
(and the ffmpeg patch for importing it is much smaller...). In fact, I
already have a working patch: I'll post it later, after checking if all
the previous comments have been properly addressed (BTW, Michael, is the
"USE_AVUTIL" thing I put in my last patch ok? If not, let me know and
I'll remove it).

Copy this in your signature, if you think it is important:
                               N O    W A R ! ! !

-------------- next part --------------
A non-text attachment was scrubbed...
Name: sws-emulation.diff
Type: text/x-patch
Size: 6863 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060403/1fa0073a/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: move-ffmpeg-to-sws.diff
Type: text/x-patch
Size: 7506 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060403/1fa0073a/attachment-0001.bin>

More information about the ffmpeg-devel mailing list