Merge branch 'main' into better-docs

This commit is contained in:
Sergey "Shnatsel" Davidoff committed 2026-03-06 14:39:37 +00:00
commit ba97bad411
2 files changed
+6 -8

No files matched your search

+2 -4
View File
@@ -40,7 +40,7 @@ use self::writer::*;
pub type Predictor = crate::tags::Predictor;
#[non_exhaustive]
#[derive(Clone, Copy, PartialEq, Default)]
#[derive(Debug, Clone, Copy, PartialEq, Default)]
pub enum Compression {
#[default]
Uncompressed,
@@ -840,9 +840,7 @@ impl<'a, W: 'a + Write + Seek, T: ColorType, K: TiffKind> ImageEncoder<'a, W, T,
self.encoder
.write_tag(Tag::ResolutionUnit, unit.to_u16())
.unwrap();
self.encoder
.write_tag(Tag::XResolution, value.clone())
.unwrap();
self.encoder.write_tag(Tag::XResolution, value).unwrap();
self.encoder.write_tag(Tag::YResolution, value).unwrap();
}
+4 -4
View File
@@ -665,22 +665,22 @@ impl_tiff_value_for_contiguous_sequence!(Rational; 8; Type::RATIONAL);
impl_tiff_value_for_contiguous_sequence!(SRational; 8; Type::SRATIONAL);
/// Type to represent tiff values of type `IFD`
#[derive(Clone)]
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
pub struct Ifd(pub u32);
/// Type to represent tiff values of type `IFD8`
#[derive(Clone)]
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
pub struct Ifd8(pub u64);
/// Type to represent tiff values of type `RATIONAL`
#[derive(Clone)]
#[derive(Debug, Copy, Clone)]
pub struct Rational {
pub n: u32,
pub d: u32,
}
/// Type to represent tiff values of type `SRATIONAL`
#[derive(Clone)]
#[derive(Debug, Copy, Clone)]
pub struct SRational {
pub n: i32,
pub d: i32,