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

Deferred load AudioElement code unless needed #267

Open
kevmoo opened this issue Feb 18, 2017 · 5 comments
Open

Deferred load AudioElement code unless needed #267

kevmoo opened this issue Feb 18, 2017 · 5 comments

Comments

@kevmoo
Copy link
Contributor

kevmoo commented Feb 18, 2017

https://www.dartlang.org/guides/language/language-tour#deferred-loading

One thing on code size: you have a lot of if X, do Y, else do Z code in StageXL.

Great for flexible runtime behavior, but you end up paying for Y and Z even if only one is used.

You may get traction by deferred loading the fallback logic in some cases – like AudioElement.

@bp74
Copy link
Owner

bp74 commented Feb 18, 2017

Thanks for the suggestion, this is surely something i should look into.

Since you mentioned AudioElement ... Dartium is super old, i'm waiting for a bugfix for AudioElement and WebAudio API that was fixed in Chrome 50.

@kevmoo
Copy link
Contributor Author

kevmoo commented Feb 18, 2017

We're working on that, too. 😄

@kevmoo
Copy link
Contributor Author

kevmoo commented Feb 20, 2017

On second thought, maybe not.

The overhead of compiling in the deferred loading infrastructure is greater than the savings of defer loading Audio and Mock sound things. 🤷‍♂️

@kevmoo
Copy link
Contributor Author

kevmoo commented Feb 20, 2017

@kevmoo
Copy link
Contributor Author

kevmoo commented Feb 20, 2017

If one had an app that was already using deferred loading, I think you would get some help here.

I could imagine that being the case w/ a game with defer-loaded levels, etc.

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