[FFmpeg-devel] Issues with ljpeg
Michael Niedermayer
michaelni
Sat Aug 16 13:21:04 CEST 2008
On Sat, Aug 16, 2008 at 11:42:02AM +0200, Mathieu Malaterre wrote:
> On Sat, Aug 16, 2008 at 11:05 AM, Mathieu Malaterre
> <mathieu.malaterre at gmail.com> wrote:
> >> look at the int8_t casts and &0x1FF
>
> Changing int8_t to int16_t solve my issue ! Thanks.
>
> >> i think these are wrong, patch welcome and dont forget
> >> 1. the regression tests, they might need to be updated
>
> So I did 'make test' and in the end I get:
>
> diff -u -w "/home/mathieu/Projects/ffmpeg"/tests/ffmpeg.regression.ref
> tests/data/vsynth.regression
> --- /home/mathieu/Projects/ffmpeg/tests/ffmpeg.regression.ref 2008-08-15
> 18:55:35.000000000 +0200
> +++ tests/data/vsynth.regression 2008-08-16 11:33:26.000000000 +0200
> @@ -106,8 +106,8 @@
> 1567580 ./tests/data/a-mjpeg.avi
> 18c3a76f984e717dd886d21fa04355f6 *./tests/data/mjpeg.vsynth.out.yuv
> stddev: 7.93 PSNR: 30.13 bytes: 7603200/ 7603200
> -5a662e3833d900b56cca79ba5ed5ec06 *./tests/data/a-ljpeg.avi
> -6264498 ./tests/data/a-ljpeg.avi
> +7c79e97bbe4b2eac12a4bef0568eeb93 *./tests/data/a-ljpeg.avi
> +6312866 ./tests/data/a-ljpeg.avi
> 799d3db687f6cdd7a837ec156efc171f *./tests/data/ljpeg.vsynth.out.yuv
> stddev: 0.00 PSNR:999.99 bytes: 7603200/ 7603200
> dca9d700da7857217408c310c501b9bc *./tests/data/a-jpegls.avi
> make: *** [codectest] Error 1
>
> I can view the movie using mplayer: MPlayer dev-SVN-r26940 (debian testing).
>
> What am I supposed to do from there ?
we need a patch that when applied fixes the bug and the regression tests.
have you tested the RGB32 code? if not please do, i think it is buggy as well
and iam not going to apply a patch that fixes one function while one above
is left with the identical bug.
hint: the &0x1FF
>
> >> 2. check samples.mplayerhq.hu that the change does not break any ljpegs from
> >> there
>
> I do not understand your last statement. There is no ljpeg decoder in
> ffmpeg,
ljpeg_decode_yuv_scan() amongth other functions
> how could there be ljpeg files on the samples ftp ?
someone could have uploaded them, anyway forget the decoder, as long as you
make no change to it it does not need to be tested
[...]
> Index: libavcodec/ljpegenc.c
> ===================================================================
> --- libavcodec/ljpegenc.c (revision 14530)
> +++ libavcodec/ljpegenc.c (working copy)
> @@ -141,9 +141,9 @@
> }
>
> if(i==0)
> - ff_mjpeg_encode_dc(s, (int8_t)(*ptr - pred), m->huff_size_dc_luminance, m->huff_code_dc_luminance); //FIXME ugly
> + ff_mjpeg_encode_dc(s, (int16_t)(*ptr - pred), m->huff_size_dc_luminance, m->huff_code_dc_luminance); //FIXME ugly
the int8_t should be removed not replaced!
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Democracy is the form of government in which you can choose your dictator
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080816/34537e59/attachment.pgp>
More information about the ffmpeg-devel
mailing list