[FFmpeg-devel] [PATCH] JPEG-LS Decoder: Update

Spyros Theoharis s.theoharis at alma-tech.com
Thu Apr 15 18:26:05 EEST 2021

> - 8 up to 16 bits
> - 444/422/420/411
> - fixed restart mechanism support
> - RGB/YUV 444 images (via -rgb444 input option)
This typically indicates that you should send four patches
instead of one.
    [A] Is this necessary? It is difficult to split the patch to four
individual patches since
    there are dependencies between modified/added features.
How can we create samples / please provide samples.
    [A] We can provide JPEG-LS samples for the decoder in the following
    <image name>.<W>x<H>.<chroma format>.<bps>bps.<restart>rst.<point
    o <chroma format>   : P100, P444, P422 or P420
    o <bps>             : 8, 10, 12, 14 or 16
    o <restart>         : 0 or any other value
    o <point transform> : 0 or any other value
    An example for a sample is: test.320x240.P100.8bps.0rst.0pt.jls
(Grayscale, 8 bits, 0 restart, 0 pt)
    How many samples do you think that we have to create and send to you
(via dropbox for example)?
    For these samples only the .jls compressed JPEG-LS image is enough or
you need some more info ?  
> + * Skip bitstream for the next restart marker
> + */
Was this completely missing so far or what is the
reason for this change?
    [A] The JPEG-LS T.87 standard defines that a Decoder has to initialize
its context model (variables A,B,C,N) 
    at each individual restart interval. 
    The JPEG-LS decoder that decompress one scan at every call, don't know
how many bits are missing during 
    the destuffing process in the mjpegdec.c/ff_mjpeg_decode_sof function
and has to remove the final "dummy"
    restart interval's '0' bits till an 0xFF is reaching that indicates the
end of a restart interval and 
    then shall skip the 0xDi RSTn marker.
All other warnings for the patch are fixed.
Spyros Theoharis

More information about the ffmpeg-devel mailing list