3 ms·
Dithering is fairly expensive operation. Please don't do it client-side each time a resource is fetched.
by marginalia_nu 5y ago
Dithering is fairly expensive operation. Please don't do it client-side each time a resource is fetched.
- WithinReason 5y agoIt's much cheaper than decompressing a JPEG
- marginalia_nu 5y agoCompressing, perhaps. But decompressing? Not really.
- WithinReason 5y agoFloyd-steinberg dithering is at least an order of magnitude cheaper than JPEG decompression
- marginalia_nu 5y agoMaybe if all else is equal, but let's not forget you'd be doing the dithering in javascript, and the JPEG decompression is implemented in a low level language, in practice probably hand written assembly (as performance-critical compression code often is).