mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
WIP: Dedupe dependencies
This commit is contained in:
parent
8eb2a53e20
commit
6354cd9a5e
11 changed files with 49 additions and 144 deletions
|
@ -836,7 +836,7 @@ impl Handler {
|
|||
let rgb = RgbImage::from_raw(img.width, img.height, img.bytes.to_vec()).unwrap();
|
||||
|
||||
let mut png_data = Vec::new();
|
||||
DynamicImage::ImageRgb8(rgb).save(&mut png_data, ImageFormat::PNG).unwrap();
|
||||
DynamicImage::ImageRgb8(rgb).write_to(&mut png_data, ImageFormat::PNG).unwrap();
|
||||
|
||||
let encoded = base64::encode(&png_data);
|
||||
Ok(WebDriverResponse::Generic(ValueResponse::new(encoded.to_json())))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue