MCPcopy
hub / github.com/nodeca/pica / fn

Function fn

benchmark/browser.js:16–26  ·  view source on GitHub ↗
(defer)

Source from the content-addressed store, hash-verified

14 .add(`Resize of ${sample.width}x${sample.height}`, {
15 defer: true,
16 fn (defer) {
17 p.resizeBuffer({
18 src: sample.buffer,
19 width: sample.width,
20 height: sample.height,
21 toWidth: (sample.width * 0.15)|0,
22 toHeight: (sample.height * 0.15)|0,
23 filter: 'lanczos3'
24 })
25 .then(() => defer.resolve())
26 }
27 })
28
29 .add(`Unsharp of ${sample.width}x${sample.height}`, {

Callers 1

glur16_wasm_invokeFunction · 0.50

Calls 1

resizeBufferMethod · 0.80

Tested by 1

glur16_wasm_invokeFunction · 0.40