How to detect lossless JPEG 2000 compression?
Asked Answered
N

2

8

I have a motion-JPEG 2000 file that I need to determine if the creator used lossless compression to create it based on the file itself. I do not have the raw video data to compare to, and I do not have the source code of the application used to produce the file.

Based on what I have found, it looks like the best I can do is check the wavelet filter (biorthogonal 3/5) and the quantization step size (1), and assume lossless if those conditions are true.

Any suggestions on how to check for lossless compression are greatly appreciated. My working environment is MATLAB or Java, but any hints for other platforms will be helpful.

Now answered 9/4, 2013 at 19:32 Comment(0)
R
2

You can use ffmpeg for this purpose. Download it from here: https://ffmpeg.org/. After you installed the software and added its source folder to WIN path, you can simply do the following:

ffprobe Test.mj2

The output then shows you many details about the video, including its possible losslessness.

See the following example output

[1]

Rokach answered 13/6, 2017 at 11:36 Comment(1)
This works for normal jpeg2000 files too (jpx/jp2 extension)Crap
V
0

It is possible to use 5/4 wavelet and quantization step of 1, and still truncate the code stream during encoding to get a lossy result. This is still a valid JPEG 2000 images. So, the only way of checking for lossless is to compare with original.

Villain answered 6/3, 2017 at 18:21 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.