[Ffmpeg-devel] Comparison of gray codecs
Kostya
kostya.shishkov
Wed Sep 20 18:17:00 CEST 2006
On Tue, Sep 19, 2006 at 07:01:35PM +0200, Philippe De Muyter wrote:
> Hi all,
>
> I have tried to compress a 2.1G grayscale (y8) rawvideo 640x480 30fps video
> (about 4 minutes) with all codecs found in the ffmpeg distro (SVN-r6290),
> with the following command line :
>
> ./ffmpeg -y -i /tmp/rawvideo.avi -vcodec $codec /tmp/gray-$codec.avi
>
> Below are the results.
>
> All comparisons are made using an avi format output file :
>
> Announced Replay
> Output Quality
[... skipped most of results ...]
> huffyuv yuv422p 2.0G Good 0m46.260s
> jpegls gray - - decode crash
> ljpeg gray - - colorspace not supported
> mjpeg yuvj420p 63M Bad 0m33.014s
>
> Summary :
>
> None of the tested codec succeeds in compressing gray video preserving
> gray pixels.
>
[summary skipped]
Here is a small patch which fixes grayscale JPEG-LS decoding so now you have the
codec which supports grayscale encoding and is lossless or near-lossless.
For lossy compression try passing '-pred x' option where 1 <= x <= 3. It won't
result in blockiness too.
I hope Michael will approve this patch and it will be applied.
-------------- next part --------------
Index: mjpeg.c
===================================================================
--- mjpeg.c (revision 6151)
+++ mjpeg.c (working copy)
@@ -2039,6 +2039,7 @@
return -1;
break;
case EOI:
+ s->cur_scan = 0;
if ((s->buggy_avid && !s->interlaced) || s->restart_interval)
break;
eoi_parser:
More information about the ffmpeg-devel
mailing list