Skip to content

Demo Web App with image operations with WebAssembly compiled from Rust, with benchmarks

Notifications You must be signed in to change notification settings

maudnals/wasm-image-operations

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wasm-image-operations

start-node.sh

JS vs Wasm benchmark, when perform the same basic operations on an image's pixels.

Demo

  • The average pixel value (R+G+B) of the image is computed with WebAssembly.
  • A benchmark of JS vs Wasm duration to perform the operations is performed (over multiple iterations) - see below the image.

Run

  1. Install the dependencies:

    $ npm install

  2. Start the demo:

    $(npm bin)/parcel index.html parcel serve index.html --public-url /

  3. Visit http://localhost:1234 with your browser.

Built with Parcel+Rust

Boilerplate used: https://github.com/koute/stdweb/tree/master/examples/hasher-parcel

How does this work?

A parcel plugin is used to integrate cargo-web with Parcel.

Source: https://github.com/koute/stdweb/tree/master/examples/hasher-parcel

About

Demo Web App with image operations with WebAssembly compiled from Rust, with benchmarks

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published