Skip to content

jamesbmadden/emul8

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

emul8: a simple chip-8 emulator

Powered by Rust and WGPU, emul8 is my first attempt at an emulator. It can compile for desktop platforms or the web!

emul8 running pong

Compiling for the web

To compile for the web, build for the target wasm32_unknown_unknown: Set the RUSTFLAGS environment variable. In PowerShell, for example:

$env:RUSTFLAGS = "--cfg=web_sys_unstable_apis"

Then you can build:

cargo build --no-default-features --target wasm32-unknown-unknown

Finally, generate wasm bindings:

wasm-bindgen --out-dir web --web target/wasm32-unknown-unknown/debug/emul8.wasm

Now, serve the web folder, and it should run!

About

A simple chip-8 emulator for native and web built in Rust with WGPU

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published