openpreserve / jpylyzer

JP2 (JPEG 2000 Part 1) validator and properties extractor. Jpylyzer was specifically created to check that a JP2 file really conforms to the format's specifications. Additionally jpylyzer is able to extract technical characteristics.
http://jpylyzer.openpreservation.org/
Other
69 stars 28 forks source link

Top-level decomposition level check partially duplicates QCD-level check #128

Closed bitsgalore closed 4 years ago

bitsgalore commented 4 years ago

The codestream top-level test quantizationConsistentWithLevels now does (almost) the same thing as lqcdConsistencyCheck (but the former takes the levels value from the COD marker, while the latter takes the local value from QCD).

A better approach might be:

  1. Remove the quantizationConsistentWithLevels test, and replace it with a simple comparison between the values of cod/levels and qcd/levels (the latter is currently not reported).
  2. Also do this test against the optional coc/levels and qcd/levels
  3. Also do these tests at the tilepart-level.

BUT beware that the tile-part markers generally override their main header counterparts, and tlikewise COC/QCC override the COD/QCD values! This needs some careful examination, as the comparison may not actually make any sense! In any case quantizationConsistentWithLevels should be removed.

Reporting levels for COC/QCD/QCC might be a good idea in any case.

bitsgalore commented 4 years ago

For now removed quantizationConsistentWithLevels: https://github.com/openpreserve/jpylyzer/commit/ed13f167788fa65d37a27d5e2d559495ce228cd0