Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I help? #1

Open
kliu128 opened this issue Apr 4, 2019 · 4 comments
Open

How can I help? #1

kliu128 opened this issue Apr 4, 2019 · 4 comments

Comments

@kliu128
Copy link

kliu128 commented Apr 4, 2019

Hi,

I love what you are doing here! Seems like an important project, especially considering the failures of other efforts.

I hence would like to help out - is there a good place where I could get started? I have worked for a while in TypeScript, and am just getting started with Rust. I see that there are a lot of projects, and I am not sure which is the most urgent currently.

@demurgos
Copy link
Contributor

demurgos commented Apr 4, 2019

Hi,
Thanks for reaching out.

I recently managed to finalize a minimal player at domu-player: it handles shapes, nested sprites, linear AVM1 bytecode, frame navigation and bitmaps. Because of this, I am now doing some maintenance work to improve the state of the repos and enable external contributors to, well, contribute 🙂

As part of this effort, I am updating the repos metadata, addings tests, enabling CI, etc. but most of my focus currently is about bringing the Rust implementation to feature-parity with the Typescript one. But don't worry, there's still plenty of work on the Typescript implementation.

Here are my propositions of work to do. Of course, I am available to provide help.

  • Complete the parser. It already handles almost all of the tags, but there are still few remaining ones (mostly video related). You have to compare the SWF spec in this repo with the implementation, the translation is mostly transparent.

  • Advance on the renderer. The Typescript backend uses the CanvasRenderingContext2D API (you may be familiar with it). For the moment it is written just to support a few test samples. It handles shapes and morph shapes but there are many placeholders. For example the line style always uses the black color, gradients may not be fully supported. My main concern is that I am not confident in the shape decoder: it's a function converting from SWF's space-optimized format to a path-based representation. I don't know how it handles self-intersections, holes, disjoint segments, etc.

  • Implement bitmap decoders (currently part of the renderer). SWF supports a few different bitmap formats. JPEG and PNG, but also some custom ones. Currently there's only one decoder for SWF bitmaps with a format id equal to 3.

  • Add support for control flow in the AVM1 interpreter. The AVM1 support is pretty basic at the moment: it only supports linear flow, no branches, functions, etc.


These are some of the most pressing issues that are ready to be handled. Longer-term, here are the main missing components:

  • Sound support: I don't know anything about it, I'll have to learn to use it and how to test it.
  • Automate the generation of test samples for the renderer, probably by running flashplayerdebugger in a virtual frame buffer and taking screenshots.
  • Adding end-to-end tests for the player: check the result frame-by-frame.
  • Add support for AVM2.
  • Abstract the renderer so it is possible to swap the Canvas implementation with a wasm/webGL one.
  • Set up a better communication channel than Github issues, better track the progress.
  • Clean up the SWF emitter and hook it with the AST test samples.
  • Provide a CLI to easily dump the content of SWF files.
  • Advance on the AVM decompiler, investigate conversion to JS or Haxe.
  • Document the architecture/interaction between the various components.
  • Set up a tool to download test-samples from the internet (for files that we do not own/should not keep in the repos)

@kliu128
Copy link
Author

kliu128 commented Apr 4, 2019

Awesome! Thanks so much for the pointers. I'll try to get cracking on one of the issues you've mentioned soon.

Re: communications channels, have you considered Riot for chat? I've found that having a chat room of some sort for a project helps a lot if people have smaller questions.

@demurgos
Copy link
Contributor

demurgos commented Apr 4, 2019

Thanks for the recommendation. I heard about Riot but never used it. I would still prefer to progress a bit before expanding on communication tools, but I'll keep it in mind when it will be time.

@demurgos
Copy link
Contributor

I updated the README with a link to "good first issues". I am opening issues on the repos and marking them with the "good first issue" tag when appropriate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants