Swap OptiPNG with OxiPNG

This makes building simpler and allows us to potentially use multithreading version in the future.

For now points to a custom fork of OxiPNG that enables WebAssembly support, as PR is still pending review.
This commit is contained in:
Ingvar Stepanyan
2019-08-01 17:01:25 +01:00
committed by Ingvar Stepanyan
parent 4621cbcae9
commit 629d64326d
34 changed files with 788 additions and 989 deletions

View File

@@ -0,0 +1,6 @@
import { optimise } from '../../../codecs/oxipng/pkg';
import { EncodeOptions } from './encoder-meta';
export async function compress(data: ArrayBuffer, options: EncodeOptions): Promise<ArrayBuffer> {
return optimise(new Uint8Array(data), options.level).buffer;
}