Skip to content
Image transformation in wasm using Go
Branch: master
Clone or download
Latest commit 87e6242 Oct 28, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cmd/shimmer
scripts
testdata cleanup: old comments Jun 17, 2018
.gitignore [Added]: go file to spin up a web server Sep 24, 2018
LICENSE
Makefile [Added]: Making separate dev and prod builds Oct 4, 2018
README.md
effects_cb.go
index.html
load_image_cb.go
screenshot.png Adding screenshot Jun 18, 2018
shimmer.go Minor name cleanup Oct 28, 2018
shimmer_test.go
wasm_loader.js

README.md

shimmer

“The shimmer is a prism but it refracts everything.”- Annihilation (2018)

Image transformation in wasm using Go.

screenshot

Just a demo project done on a weekend to play with images inside the browser using WASM. Performance lag is noticeable for images over 100KB.

Setup

  • Run make build-prod
  • Serve the files using any HTTP server. (Note that .wasm files need to be served with application/wasm mime type. So the server must be capable of doing that.)

Benchmarks

name         time/op
AdjustImage   249ms ± 4%

name         alloc/op
AdjustImage  2.44MB ± 0%

name         allocs/op
AdjustImage    62.0 ± 0%
You can’t perform that action at this time.