Skip to content

Commit d6879d9

Browse files
authored
Make avif/yuv.rs 1.70-compatible (#2382)
1 parent 317bc16 commit d6879d9

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

src/codecs/avif/yuv.rs

+11-10
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,16 @@ use crate::error::DecodingError;
22
use crate::{ImageError, ImageFormat};
33
use num_traits::AsPrimitive;
44
use std::fmt::{Display, Formatter};
5+
use std::mem::size_of;
56

67
#[derive(Debug, Copy, Clone)]
78
/// Representation of inversion matrix
89
struct CbCrInverseTransform<T> {
9-
pub y_coef: T,
10-
pub cr_coef: T,
11-
pub cb_coef: T,
12-
pub g_coeff_1: T,
13-
pub g_coeff_2: T,
10+
y_coef: T,
11+
cr_coef: T,
12+
cb_coef: T,
13+
g_coeff_1: T,
14+
g_coeff_2: T,
1415
}
1516

1617
impl CbCrInverseTransform<f32> {
@@ -162,11 +163,11 @@ pub(crate) enum YuvIntensityRange {
162163

163164
#[derive(Debug, Copy, Clone, PartialOrd, PartialEq)]
164165
struct YuvChromaRange {
165-
pub bias_y: u32,
166-
pub bias_uv: u32,
167-
pub range_y: u32,
168-
pub range_uv: u32,
169-
pub range: YuvIntensityRange,
166+
bias_y: u32,
167+
bias_uv: u32,
168+
range_y: u32,
169+
range_uv: u32,
170+
range: YuvIntensityRange,
170171
}
171172

172173
impl YuvIntensityRange {

0 commit comments

Comments
 (0)