mirror of
https://github.com/wez/wezterm.git
synced 2025-01-08 23:17:36 +03:00
deps: image -> 0.24
This commit is contained in:
parent
c4009d8e1d
commit
435ff1e93b
132
Cargo.lock
generated
132
Cargo.lock
generated
@ -316,7 +316,7 @@ dependencies = [
|
||||
"cc",
|
||||
"cfg-if 1.0.0",
|
||||
"libc",
|
||||
"miniz_oxide 0.4.4",
|
||||
"miniz_oxide",
|
||||
"object",
|
||||
"rustc-demangle",
|
||||
]
|
||||
@ -358,6 +358,12 @@ checksum = "ea52a394d9a85bf9819ca50382187ece2497501dbd6397fd33388400e512a90e"
|
||||
name = "bintree"
|
||||
version = "0.1.0"
|
||||
|
||||
[[package]]
|
||||
name = "bit_field"
|
||||
version = "0.10.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "dcb6dd1c2376d2e096796e234a70e17e94cc2d5d54ff8ce42b28cef1d0d359a4"
|
||||
|
||||
[[package]]
|
||||
name = "bitflags"
|
||||
version = "1.3.2"
|
||||
@ -885,19 +891,18 @@ checksum = "b365fabc795046672053e29c954733ec3b05e4be654ab130fe8f1f94d7051f35"
|
||||
|
||||
[[package]]
|
||||
name = "deflate"
|
||||
version = "0.8.6"
|
||||
version = "0.9.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "73770f8e1fe7d64df17ca66ad28994a0a623ea497fa69486e14984e715c5d174"
|
||||
checksum = "5f95bf05dffba6e6cce8dfbb30def788154949ccd9aed761b472119c21e01c70"
|
||||
dependencies = [
|
||||
"adler32",
|
||||
"byteorder",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "deflate"
|
||||
version = "0.9.1"
|
||||
version = "1.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5f95bf05dffba6e6cce8dfbb30def788154949ccd9aed761b472119c21e01c70"
|
||||
checksum = "c86f7e25f518f4b81808a2cf1c50996a61f5c2eb394b2393bd87f2a4780a432f"
|
||||
dependencies = [
|
||||
"adler32",
|
||||
]
|
||||
@ -1199,6 +1204,22 @@ dependencies = [
|
||||
"smallvec 0.6.14",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "exr"
|
||||
version = "1.4.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d4badb9489a465cb2c555af1f00f0bfd8cecd6fc12ac11da9d5b40c5dd5f0200"
|
||||
dependencies = [
|
||||
"bit_field",
|
||||
"deflate 1.0.0",
|
||||
"flume",
|
||||
"half",
|
||||
"inflate",
|
||||
"lebe",
|
||||
"smallvec 1.8.0",
|
||||
"threadpool",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "fake-simd"
|
||||
version = "0.1.2"
|
||||
@ -1256,7 +1277,7 @@ dependencies = [
|
||||
"cfg-if 1.0.0",
|
||||
"crc32fast",
|
||||
"libc",
|
||||
"miniz_oxide 0.4.4",
|
||||
"miniz_oxide",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -1627,6 +1648,12 @@ dependencies = [
|
||||
"svg_fmt",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "half"
|
||||
version = "1.8.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "eabb4a44450da02c90444cf74558da904edde8fb4e9035a9a6a4e15445af0bd7"
|
||||
|
||||
[[package]]
|
||||
name = "harfbuzz"
|
||||
version = "0.1.0"
|
||||
@ -1749,19 +1776,20 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "image"
|
||||
version = "0.23.14"
|
||||
version = "0.24.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "24ffcb7e7244a9bf19d35bf2883b9c080c4ced3c07a9895572178cdb8f13f6a1"
|
||||
checksum = "e94ac3d41f882c624a82d7945952032388488681f45f9d4077999a6c85688d61"
|
||||
dependencies = [
|
||||
"bytemuck",
|
||||
"byteorder",
|
||||
"color_quant",
|
||||
"exr",
|
||||
"gif",
|
||||
"jpeg-decoder",
|
||||
"jpeg-decoder 0.2.1",
|
||||
"num-iter",
|
||||
"num-rational",
|
||||
"num-rational 0.4.0",
|
||||
"num-traits",
|
||||
"png 0.16.8",
|
||||
"png",
|
||||
"scoped_threadpool",
|
||||
"tiff",
|
||||
]
|
||||
@ -1775,6 +1803,15 @@ dependencies = [
|
||||
"unindent",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "inflate"
|
||||
version = "0.4.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "1cdb29978cc5797bd8dcc8e5bf7de604891df2a8dc576973d71a281e916db2ff"
|
||||
dependencies = [
|
||||
"adler32",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "inotify"
|
||||
version = "0.7.1"
|
||||
@ -1851,6 +1888,12 @@ name = "jpeg-decoder"
|
||||
version = "0.1.22"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "229d53d58899083193af11e15917b5640cd40b29ff475a1fe4ef725deb02d0f2"
|
||||
|
||||
[[package]]
|
||||
name = "jpeg-decoder"
|
||||
version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fbcf0244f6597be39ab8d9203f574cafb529ae8c698afa2182f7b3c3205a4a9c"
|
||||
dependencies = [
|
||||
"rayon",
|
||||
]
|
||||
@ -1924,6 +1967,12 @@ version = "0.2.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "884e2677b40cc8c339eaefcb701c32ef1fd2493d71118dc0ca4b6a736c93bd67"
|
||||
|
||||
[[package]]
|
||||
name = "lebe"
|
||||
version = "0.5.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7efd1d698db0759e6ef11a7cd44407407399a910c774dd804c64c032da7826ff"
|
||||
|
||||
[[package]]
|
||||
name = "libc"
|
||||
version = "0.2.117"
|
||||
@ -2194,15 +2243,6 @@ version = "0.2.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"
|
||||
|
||||
[[package]]
|
||||
name = "miniz_oxide"
|
||||
version = "0.3.7"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "791daaae1ed6889560f8c4359194f56648355540573244a5448a83ba1ecc7435"
|
||||
dependencies = [
|
||||
"adler32",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "miniz_oxide"
|
||||
version = "0.4.4"
|
||||
@ -2475,7 +2515,7 @@ dependencies = [
|
||||
"num-complex",
|
||||
"num-integer",
|
||||
"num-iter",
|
||||
"num-rational",
|
||||
"num-rational 0.3.2",
|
||||
"num-traits",
|
||||
]
|
||||
|
||||
@ -2543,6 +2583,17 @@ dependencies = [
|
||||
"num-traits",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "num-rational"
|
||||
version = "0.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d41702bd167c2df5520b384281bc111a4b5efcf7fbc4c9c222c815b07e0a6a6a"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
"num-integer",
|
||||
"num-traits",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "num-traits"
|
||||
version = "0.2.14"
|
||||
@ -2913,18 +2964,6 @@ version = "0.3.24"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "58893f751c9b0412871a09abd62ecd2a00298c6c83befa223ef98c52aef40cbe"
|
||||
|
||||
[[package]]
|
||||
name = "png"
|
||||
version = "0.16.8"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3c3287920cb847dee3de33d301c463fba14dda99db24214ddf93f83d3021f4c6"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"crc32fast",
|
||||
"deflate 0.8.6",
|
||||
"miniz_oxide 0.3.7",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "png"
|
||||
version = "0.17.2"
|
||||
@ -2935,7 +2974,7 @@ dependencies = [
|
||||
"crc32fast",
|
||||
"deflate 0.9.1",
|
||||
"encoding",
|
||||
"miniz_oxide 0.4.4",
|
||||
"miniz_oxide",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -4141,13 +4180,22 @@ dependencies = [
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tiff"
|
||||
version = "0.6.1"
|
||||
name = "threadpool"
|
||||
version = "1.8.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9a53f4706d65497df0c4349241deddf35f84cee19c87ed86ea8ca590f4464437"
|
||||
checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa"
|
||||
dependencies = [
|
||||
"jpeg-decoder",
|
||||
"miniz_oxide 0.4.4",
|
||||
"num_cpus",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tiff"
|
||||
version = "0.7.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "0247608e998cb6ce39dfc8f4a16c50361ce71e5b52e6d24ea1227ea8ea8ee0b2"
|
||||
dependencies = [
|
||||
"flate2",
|
||||
"jpeg-decoder 0.1.22",
|
||||
"weezl",
|
||||
]
|
||||
|
||||
@ -4171,7 +4219,7 @@ dependencies = [
|
||||
"arrayvec",
|
||||
"bytemuck",
|
||||
"cfg-if 1.0.0",
|
||||
"png 0.17.2",
|
||||
"png",
|
||||
"safe_arch",
|
||||
]
|
||||
|
||||
@ -4892,7 +4940,7 @@ dependencies = [
|
||||
"lazy_static",
|
||||
"log",
|
||||
"lru",
|
||||
"miniz_oxide 0.4.4",
|
||||
"miniz_oxide",
|
||||
"num-traits",
|
||||
"ordered-float",
|
||||
"pretty_assertions",
|
||||
|
@ -19,7 +19,7 @@ bitflags = "1.3"
|
||||
csscolorparser = "0.5"
|
||||
miniz_oxide = "0.4"
|
||||
hex = "0.4"
|
||||
image = "0.23"
|
||||
image = "0.24"
|
||||
lazy_static = "1.4"
|
||||
log = "0.4"
|
||||
lru = "0.7"
|
||||
|
@ -945,7 +945,7 @@ fn clip_view(
|
||||
let view = src.view(src_x, src_y, view_width, view_height);
|
||||
|
||||
let mut tmp = RgbaImage::new(view_width, view_height);
|
||||
tmp.copy_from(&view, 0, 0).context("copy source image")?;
|
||||
tmp.copy_from(&*view, 0, 0).context("copy source image")?;
|
||||
Ok(tmp)
|
||||
}
|
||||
|
||||
@ -962,10 +962,10 @@ where
|
||||
{
|
||||
match mode {
|
||||
KittyFrameCompositionMode::Overwrite => {
|
||||
::image::imageops::replace(dest, src, x, y);
|
||||
::image::imageops::replace(dest, src, x.into(), y.into());
|
||||
}
|
||||
KittyFrameCompositionMode::AlphaBlending => {
|
||||
::image::imageops::overlay(dest, src, x, y);
|
||||
::image::imageops::overlay(dest, src, x.into(), y.into());
|
||||
}
|
||||
}
|
||||
Ok(())
|
||||
|
@ -19,7 +19,7 @@ anyhow = "1.0"
|
||||
filedescriptor = { version="0.8", path = "../filedescriptor" }
|
||||
fnv = {version="1.0", optional=true}
|
||||
hex = "0.4"
|
||||
image = {version="0.23", optional=true}
|
||||
image = {version="0.24", optional=true}
|
||||
lazy_static = "1.4"
|
||||
libc = "0.2"
|
||||
log = "0.4"
|
||||
|
@ -288,7 +288,7 @@ impl ImageDataType {
|
||||
}
|
||||
};
|
||||
match format {
|
||||
ImageFormat::Gif => image::gif::GifDecoder::new(&*data)
|
||||
ImageFormat::Gif => image::codecs::gif::GifDecoder::new(&*data)
|
||||
.and_then(|decoder| decoder.into_frames().collect_frames())
|
||||
.and_then(|frames| Ok(Self::decode_frames(frames)))
|
||||
.unwrap_or_else(|err| {
|
||||
@ -299,7 +299,7 @@ impl ImageDataType {
|
||||
Self::decode_single(data)
|
||||
}),
|
||||
ImageFormat::Png => {
|
||||
let decoder = match image::png::PngDecoder::new(&*data) {
|
||||
let decoder = match image::codecs::png::PngDecoder::new(&*data) {
|
||||
Ok(d) => d,
|
||||
_ => return Self::EncodedFile(data),
|
||||
};
|
||||
|
@ -36,7 +36,7 @@ filedescriptor = { version="0.8", path = "../filedescriptor" }
|
||||
fuzzy-matcher = "0.3"
|
||||
hdrhistogram = "7.1"
|
||||
http_req = "0.8"
|
||||
image = "0.23"
|
||||
image = "0.24"
|
||||
lazy_static = "1.4"
|
||||
libc = "0.2"
|
||||
log = "0.4"
|
||||
|
@ -162,7 +162,6 @@ impl RenderState {
|
||||
}
|
||||
|
||||
Event::Start(Tag::Image(_linktype, img_url, _title)) => {
|
||||
use image::GenericImageView;
|
||||
use termwiz::image::TextureCoordinate;
|
||||
|
||||
let url: &str = img_url.as_ref();
|
||||
|
@ -1044,13 +1044,13 @@ impl TermWindow {
|
||||
}
|
||||
|
||||
fn apply_icon(window: &Window) -> anyhow::Result<()> {
|
||||
let icon_image = image::load_from_memory(ICON_DATA)?;
|
||||
let image = icon_image.to_bgra8();
|
||||
let image = image::load_from_memory(ICON_DATA)?.into_rgba8();
|
||||
let (width, height) = image.dimensions();
|
||||
window.set_icon(Image::from_raw(
|
||||
window.set_icon(Image::with_rgba32(
|
||||
width as usize,
|
||||
height as usize,
|
||||
image.into_raw(),
|
||||
width as usize * 4,
|
||||
image.as_raw(),
|
||||
));
|
||||
Ok(())
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user