wip(av1): superres stage-3 gate flags + chroma crop rounding fix
Browse files at this commite9f1fa85c2fda7f0e94ad5bfa42288e5c350f28dParent: c28ee952 changed files +21 -4
crates/ec-av1/src/decode.rsmodified+4 -4
| @@ -4990,8 +4990,8 @@ pub(crate) fn decode_key_frame_tile_with_cdfs( | |||
| 4990 | width: fw, | 4990 | width: fw, |
| 4991 | height: fh, | 4991 | height: fh, |
| 4992 | y: crop(&y, fw, fh), | 4992 | y: crop(&y, fw, fh), |
| 4993 | - u: crop(&u, fw / 2, fh / 2), | 4993 | + u: crop(&u, fw.div_ceil(2), fh.div_ceil(2)), |
| 4994 | - v: crop(&v, fw / 2, fh / 2), | 4994 | + v: crop(&v, fw.div_ceil(2), fh.div_ceil(2)), |
| 4995 | }, | 4995 | }, |
| 4996 | cdfs, | 4996 | cdfs, |
| 4997 | )) | 4997 | )) |
| @@ -10501,8 +10501,8 @@ pub(crate) fn decode_inter_frame_tile_with_cdfs( | |||
| 10501 | width: fw, | 10501 | width: fw, |
| 10502 | height: fh, | 10502 | height: fh, |
| 10503 | y: crop(&y, fw, fh), | 10503 | y: crop(&y, fw, fh), |
| 10504 | - u: crop(&u, fw / 2, fh / 2), | 10504 | + u: crop(&u, fw.div_ceil(2), fh.div_ceil(2)), |
| 10505 | - v: crop(&v, fw / 2, fh / 2), | 10505 | + v: crop(&v, fw.div_ceil(2), fh.div_ceil(2)), |
| 10506 | }, | 10506 | }, |
| 10507 | cdfs, | 10507 | cdfs, |
| 10508 | motion_field, | 10508 | motion_field, |
crates/ec-av1/src/stream.rsmodified+17 -0
| @@ -3868,6 +3868,23 @@ mod tests { | |||
| 3868 | "--row-mt=0", | 3868 | "--row-mt=0", |
| 3869 | "--superres-mode=1", | 3869 | "--superres-mode=1", |
| 3870 | "--superres-denominator=12", | 3870 | "--superres-denominator=12", |
| 3871 | + "--superres-kf-denominator=12", | ||
| 3872 | + "--enable-rect-partitions=0", | ||
| 3873 | + "--enable-ab-partitions=0", | ||
| 3874 | + "--enable-1to4-partitions=0", | ||
| 3875 | + "--enable-filter-intra=0", | ||
| 3876 | + "--enable-smooth-intra=0", | ||
| 3877 | + "--enable-paeth-intra=0", | ||
| 3878 | + "--enable-directional-intra=0", | ||
| 3879 | + "--enable-angle-delta=0", | ||
| 3880 | + "--enable-tx-size-search=0", | ||
| 3881 | + "--enable-cdef=0", | ||
| 3882 | + "--enable-restoration=0", | ||
| 3883 | + "--max-partition-size=32", | ||
| 3884 | + "--min-partition-size=32", | ||
| 3885 | + "--enable-palette=0", | ||
| 3886 | + "--enable-intrabc=0", | ||
| 3887 | + "--enable-cfl-intra=0", | ||
| 3871 | "--obu", | 3888 | "--obu", |
| 3872 | "-o", | 3889 | "-o", |
| 3873 | "-", | 3890 | "-", |