Refactor imir implementation to match HEIF Draft Amendment 2, which replaces 'axis' with 'mode' and inverts the behavior
diff --git a/src/read.c b/src/read.c
index a37fb80..d363f84 100644
--- a/src/read.c
+++ b/src/read.c
@@ -1553,10 +1553,10 @@
BEGIN_STREAM(s, raw, rawLen, diag, "Box[imir]");
avifImageMirror * imir = &prop->u.imir;
- CHECK(avifROStreamRead(&s, &imir->axis, 1)); // unsigned int (7) reserved = 0; unsigned int (1) axis;
- if ((imir->axis & 0xfe) != 0) {
+ CHECK(avifROStreamRead(&s, &imir->mode, 1)); // unsigned int (7) reserved = 0; unsigned int (1) mode;
+ if ((imir->mode & 0xfe) != 0) {
// reserved bits must be 0
- avifDiagnosticsPrintf(diag, "Box[imir] contains nonzero reserved bits [%u]", imir->axis);
+ avifDiagnosticsPrintf(diag, "Box[imir] contains nonzero reserved bits [%u]", imir->mode);
return AVIF_FALSE;
}
return AVIF_TRUE;