Skip to content

Commit

Permalink
Upgrade libgifski to 1.3.1 (#225)
Browse files Browse the repository at this point in the history
Fixes #224
  • Loading branch information
sindresorhus committed Jan 31, 2021
1 parent b5d113c commit 2bf854f
Show file tree
Hide file tree
Showing 10 changed files with 285 additions and 285 deletions.
160 changes: 52 additions & 108 deletions gifski-api/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 7 additions & 8 deletions gifski-api/Cargo.toml
Expand Up @@ -10,7 +10,7 @@ license = "AGPL-3.0+"
name = "gifski"
readme = "README.md"
repository = "https://github.com/ImageOptim/gifski"
version = "1.2.6"
version = "1.3.1"
autobins = false
edition = "2018"

Expand All @@ -22,10 +22,10 @@ name = "gifski"
gifsicle = { version = "1.92.4", optional = true }
clap = "2.33.3"
gif = "0.11.1"
gif-dispose = "3.1.0"
imagequant = "2.13.0"
gif-dispose = "3.1.1"
imagequant = "3.0.2"
imgref = "1.7.1"
lodepng = "3.2.2"
lodepng = "3.4.2"
pbr = "1.0.4"
resize = "0.5.5"
rgb = "0.8.25"
Expand All @@ -36,12 +36,11 @@ dunce = "1.0.1"
crossbeam-channel = "0.5.0"

[dependencies.ffmpeg]
# package = "ffmpeg-next"
# version = "4.3.6"
git = "https://github.com/kornelski/rust-ffmpeg"
package = "ffmpeg-next"
version = "4.3.8"
optional = true
default-features = false
features = ["ffmpeg4", "codec", "format", "filter", "software-resampling", "software-scaling"]
features = ["codec", "format", "filter", "software-resampling", "software-scaling"]

[features]
default = ["gifsicle"]
Expand Down
4 changes: 2 additions & 2 deletions gifski-api/src/bin/ffmpeg_source.rs
Expand Up @@ -17,7 +17,7 @@ impl Source for FfmpegDecoder {
fn total_frames(&self) -> u64 {
self.frames
}
fn collect(&mut self, dest: Collector) -> BinResult<()> {
fn collect(&mut self, dest: &mut Collector) -> BinResult<()> {
self.collect_frames(dest)
}
}
Expand All @@ -40,7 +40,7 @@ impl FfmpegDecoder {
})
}

pub fn collect_frames(&mut self, mut dest: Collector) -> BinResult<()> {
pub fn collect_frames(&mut self, dest: &mut Collector) -> BinResult<()> {
let (stream_index, mut decoder, mut filter) = {
let filter_fps = self.rate.fps / self.rate.speed;
let stream = self.input_context.streams().best(ffmpeg::media::Type::Video).ok_or("The file has no video tracks")?;
Expand Down

0 comments on commit 2bf854f

Please sign in to comment.