From 36fefced01f558032025237b2ed362b1e842118e Mon Sep 17 00:00:00 2001 From: Jonathan Behrens Date: Thu, 27 Feb 2025 19:34:22 -0800 Subject: [PATCH] Remove deprecated method --- CHANGES.md | 4 ++-- src/encoder.rs | 12 ------------ 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 215ce6e2..8d1b782a 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2,8 +2,8 @@ ### API Breaking Changes -* Removed deprecated `Info::encode` method. -* Improved the compression settings API. +* Removed deprecated `Info::encode` and `Encoder::set_srgb` methods. +* Improved the compression settings API for encoding. * `Decoder` now requires a reader that implements `Seek` and `BufRead` traits. * Bump bitflags dependency to 2.0. diff --git a/src/encoder.rs b/src/encoder.rs index 91fdd2ee..15f751b1 100644 --- a/src/encoder.rs +++ b/src/encoder.rs @@ -266,18 +266,6 @@ impl<'a, W: Write> Encoder<'a, W> { self.info.source_chromaticities = Some(source_chromaticities); } - /// Mark the image data as conforming to the SRGB color space with the specified rendering intent. - /// - /// Matching source gamma and chromaticities chunks are added automatically. - /// Any manually specified source gamma, chromaticities, or ICC profiles will be ignored. - #[doc(hidden)] - #[deprecated(note = "use set_source_srgb")] - pub fn set_srgb(&mut self, rendering_intent: super::SrgbRenderingIntent) { - self.info.set_source_srgb(rendering_intent); - self.info.source_gamma = Some(crate::srgb::substitute_gamma()); - self.info.source_chromaticities = Some(crate::srgb::substitute_chromaticities()); - } - /// Mark the image data as conforming to the SRGB color space with the specified rendering intent. /// /// Any ICC profiles will be ignored.