gpac / ComplianceWarden

A pluggable compliance checker (ISOBMFF, HEIF/MIAF/AVIF, AV1 HDR10+)
https://gpac.github.io/ComplianceWarden-wasm/
Other
16 stars 7 forks source link

False positive: "The mono_chrome field in the Sequence Header OBU shall be set to 1" #16

Closed joedrago closed 3 years ago

joedrago commented 3 years ago

Test file: gradient.zip

Generated with avifenc v0.9.0 and libaom 2.0.2, I have independently verified that the color item (ID 1) is YUV444 Full Range (signaled correctly) and the auxiliary plane alpha item (ID 2) is YUV400 Full Range (also signaled correctly). However, when submitting this file here:

https://gpac.github.io/ComplianceWarden-wasm/avif.html

I receive this error:

[avif][Rule #11] Error: The mono_chrome field in the Sequence Header OBU shall be set to 1 (item_ID=1)

... followed later by these details:

[avif][Rule #11] Section 4. Auxiliary Image Items
The mono_chrome field in the Sequence Header OBU shall be set to 1.
The color_range field in the Sequence Header OBU shall be set to 1.

I believe this is checking the wrong ID's mono_chrome flag (ID 1 instead of ID 2). Help!

rbouqueau commented 3 years ago

Thanks for reporting!

You are right. When getting the references (iref box) I considered the target item id instead of the source one.

I checked for other similar checks. Everything seems fine.

I've added an additional test to cover this case. The other alpha test was on MIAF only.

I've updated the wasm page without making a new release for now. Let me know if you think that's necessary. Close this issue if ok.

joedrago commented 3 years ago

Looks good, thanks! I see there is still an erroneous complaint about Rule 18, but I believe you and Cyril are discussing that elsewhere so I'll leave it alone.

rbouqueau commented 3 years ago

There is a patch but we're still discussing about the wording of the error message.