Commit Graph

8539 Commits

Author SHA1 Message Date
Mike Welsh 738a7a8278 Add logo to README 2019-06-25 16:30:43 -07:00
Mike Welsh 5610001eae Remove listbox from demo page (for now) 2019-06-25 16:30:35 -07:00
Mike Welsh 3263255e60 Add color filter SVG as child of canvas element
Avoid adding to body, which can affect document layout.
2019-06-25 15:50:22 -07:00
Mike Welsh 64d6ea6f3f Move web demo into web/demo
Keep the root web folder as a pure NPM package. Move demo webpack
config separetly into web/demo.
2019-06-25 11:27:04 -07:00
Mike Welsh ef31433735 Bump version 2019-06-17 03:25:09 -07:00
Mike Welsh 5e4e6099a4 Add Tag::End
Tag::End added to the Tag enum, and read_tag and write_tag will
use this variant.  The End tag is still implicit when reading
tag lists (still unsure, this may change in the future).
2019-06-17 03:23:29 -07:00
Mike Welsh 2a365288e8 Update to latest swf-rs 2019-06-17 02:59:32 -07:00
Mike Welsh afbf8fdea5 Make Reader::new public 2019-06-17 02:53:18 -07:00
Mike Welsh 7c41bedbcb Bump Cargo.toml to 0.1.1 2019-06-17 02:11:53 -07:00
Mike Welsh 88d88ebab5 Update naming convention for AVM2 SWFs 2019-06-17 02:04:48 -07:00
Mike Welsh fd2c68e1ef Update naming convention for test SWFs 2019-06-17 01:58:24 -07:00
Mike Welsh d20a7c1123 Make read_ubits and read_sbits private 2019-06-17 01:52:13 -07:00
Mike Welsh d64ec2e133 read_swf decompresses SWF all at once 2019-06-17 01:51:21 -07:00
Mike Welsh bd46c273ee Update doc test filenames 2019-06-17 00:56:26 -07:00
Mike Welsh 8697457e05 Merge branch 'master' into ruffle 2019-06-17 00:52:31 -07:00
Mike Welsh eeca4275d4 clippy: cyclomatic_complexity -> computational_complexity 2019-06-17 00:50:09 -07:00
Mike Welsh 608f090501 Clean up test naming 2019-06-17 00:33:58 -07:00
Mike Welsh 6ab8c4a7d1 Export TagCode 2019-06-16 23:41:27 -07:00
Mike Welsh dc856dfd55 Update README examples 2019-06-16 23:03:48 -07:00
Mike Welsh f23b678ea8 clippy: cyclomatic_complexity -> cognitive_complexity 2019-06-16 22:55:29 -07:00
Mike Welsh 9d1f21eaa4 Add some documentation and clean up reader 2019-06-16 21:23:31 -07:00
Mike Welsh ba36435711 desktop: Pass pixel coordinates to lyon
Lyon seems sensitive to overflow on large coordinates, so passing
twips resulting in overflow panics on very large shapes.

Avoid panics on tessellation failure: instead, return an empty
mesh and log an error.
2019-05-17 18:51:53 -07:00
Mike Welsh 7512275847 web: Bump wasm-bindgen to 0.2.44 2019-05-17 17:35:29 -07:00
Mike Welsh 3cefeeba6a Use twips for internal calculations
Switch from pixels to twips for internal calculations. swf crate
was updated to add a Twips wrapper-type. Ruffle will use this type
internally for transforms and shapes. This fixes some precision
errors in rendering (see heroes_of_cybertron.swf) and will match
what the Flash Player does internally more closely. (e.g.
DisplayObject x and y will be quantized to 1/20 pixel units). It
is up to the renderer to convert units from twip space to pixels
when rendering.
2019-05-17 13:40:56 -07:00
Mike Welsh eadc1da798 Keep Twips as integers
Add Twips wrapper type around i32. Keep Twips coordinates as i32.
Add conversion methods to convert to/from pixels.
2019-05-17 13:07:42 -07:00
Mike Welsh 023406aa2b web: Move requestAnimationFrame loop into Rust 2019-05-16 19:14:37 -07:00
Mike Welsh aced67cb15
docs: Update README.md
Fix link to localhost
2019-05-16 11:16:53 -07:00
Mike Welsh 0405666849
docs: Update README.md
cargo build -> cargo run
2019-05-16 10:31:23 -07:00
Mike Welsh b5ef3cb4ea
docs: Update README with build instructions
Add simple build instructions to README for both desktop and web.
2019-05-16 10:10:32 -07:00
Mike Welsh 6673527b0a core: Add clip depth to DisplayObject 2019-05-12 13:48:00 -04:00
Mike Welsh 4e3eecb016 core: Improve SVG strokes
Use stroke properties to apply stroke styles from the SWF.
2019-05-12 13:35:03 -04:00
Mike Welsh 79b3a7007d core: Initial morph shape implementation 2019-05-12 12:55:48 -04:00
Mike Welsh cc7ef196e9 web: Clean up Player interface
Use generational_arena indices for the JS-side Player handle.
2019-05-10 09:06:47 -07:00
Mike Welsh af33b8538e desktop: Better event sounds 2019-05-09 17:43:53 -07:00
Mike Welsh 61189cfb84 core: Fix text transforms 2019-05-09 14:14:21 -07:00
Mike Welsh efe3270ce0 web: Decode streams completely on preload (for now) 2019-05-09 12:43:26 -07:00
Mike Welsh 74743f327c core: Remove unused file 2019-05-09 12:43:03 -07:00
Mike Welsh 12d6d3342b core: Switch to rust-gc 2019-05-08 18:10:43 -07:00
Mike Welsh 7063bc4080 ci: Add Circle CI config 2019-05-08 13:33:05 -07:00
Mike Welsh 07c6addb8b core: Remove patch from Cargo.toml 2019-05-08 11:59:46 -07:00
Mike Welsh d8a8f4da60 Make read_ubits public 2019-05-08 11:54:43 -07:00
Mike Welsh 58311e20a9 web: Re-organize npm/webpack files
Use wasm-pack-plugin npm package.
2019-05-08 11:32:44 -07:00
Mike Welsh 62ae3b0c46 Rename project 2019-05-08 09:46:19 -07:00
Mike Welsh 14b6c59a3c web: Update demo page 2019-05-07 16:07:23 -07:00
Mike Welsh 20844185d7 core: Set preload flag 2019-05-07 12:11:32 -07:00
Mike Welsh bfc735e3b7 web: Allow specifying SWF in query params 2019-05-07 10:03:45 -07:00
Mike Welsh cb6d96955d Remove debug spew 2019-05-07 09:52:22 -07:00
Mike Welsh 67b96119e3 Fix padding on 8-bit PNGs 2019-05-07 09:51:06 -07:00
Mike Welsh e6e8536672 Clean up DisplayObject traits 2019-05-07 03:34:17 -07:00
Mike Welsh 7983d9eb96 Clean up DisplayObject instantiation 2019-05-07 03:22:58 -07:00