Comments (11)
The easiest way to add WebP support is to follow @kean's advice and use WebPImageSerialization. I just set it up and everything's working fine like normal.
from nuke.
It would be nice if you guys share what you come up with, I'll add it somewhere in the Documentation.
from nuke.
Hey! There is a community plugin (Nuke-WebP-Plugin) which adds support for WebP! I've contacted the author, he's committed to update it to work with Nuke 7 when it is released. This means:
- adding progressive decoding support (new in Nuke 7)
- simplifying setup using
ImageDecoderRegistry
(new in Nuke 7)
I'm adding the link to this plugin in README as a recommended solution for WebP decoding 🍻
from nuke.
There are at least two ways to add WebP support:
- Add a new image decoder (see
ImageDecoding
protocol) and register it inImageManagerConfiguration
. That's how GIF support is implemented in Nuke AnimatedImage Plugin. - Use WebPImageSerialization which has a swizzle that extends
UIImage
with WebP support. This method doesn't require any additional code on Nuke's side. I haven't tested it in Swift yet, but it should work just fine.
from nuke.
Any update on this feature?
from nuke.
It seems that there is no work required on Nuke's side (see WebPImageSerialization). Haven't tested it thought.
from nuke.
I am pretty sure that Nuke should send image/webp at the http header of the request to identify that supports webp. Especially when image is loaded via image cdn
from nuke.
Yeah, that's true, most servers would require you to explicitly tell them that the client supports webp. It's possible to set those headers either using HTTPAdditionalHeaders
property of NSURLSessionConfiguration
, or via NSURLRequest
.
from nuke.
@mitchellporter do you mind sharing your implementation for WebP support? So other people including me can use it.
from nuke.
@kean Would be more than happy to share and help just need some time. We are using a legacy version of Nuke in an older project that works fine like I mentioned above, but last I checked it no longer works using the latest version of Nuke, animated image plugin, etc.
Will report back when I can share an update and maybe a quick test project too.
from nuke.
Bump. This has been long overdue. I'm going to try and spin up a test project within the next week or so. Last I remember WebPImageSerialization was no longer working... a lot has changed with Nuke
since the last time I had it working.
I'll update again soon with my findings.
from nuke.
Related Issues (20)
- Missing support for macCatalyst in Nuke 12.4 HOT 2
- LazyImage(url:) does not load image when using ImageRenderer HOT 4
- Add mandatory privacy manifest HOT 1
- SwiftUI Warning: Accessing StateObject's object without being installed on a View. This will create a new instance each time. HOT 2
- Xcode 15.3 concurrency warnings when using `Screen.scale`
- The operation couldn’t be completed: ImagePipeline.Error error 0 HOT 1
- Missing documentation for using LazyImage implementation inside Package HOT 2
- ImageRequest userInfo dictionary `Any` type for value allows unsupported types for imageIdKey HOT 2
- Any way to modify ImageRequest before it's executed? HOT 1
- Potential Memory Issue when using any processors such as Resize HOT 11
- Custom DataLoader without native URL cache HOT 1
- JPG not resizing, just black HOT 2
- Xcode warning: IO on main thread HOT 1
- Add dataTask that is similar to imageTask HOT 2
- Skip decompression for .png images and other uncompressed formats HOT 1
- Error resizing PNG-8 images HOT 3
- Authorization header HOT 2
- Image scaling bug HOT 11
- What would be the most elegant way to decrypt image data before it is sent to the pipeline? HOT 4
- Is there any way to apply transition to placeholder? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nuke.