Skip to content

Platform/wasm browser#109

Draft
KieranFoot wants to merge 13 commits intoLSXPrime:platform/wasm-browserfrom
KieranFoot:platform/wasm-browser
Draft

Platform/wasm browser#109
KieranFoot wants to merge 13 commits intoLSXPrime:platform/wasm-browserfrom
KieranFoot:platform/wasm-browser

Conversation

@KieranFoot
Copy link
Copy Markdown

@KieranFoot KieranFoot commented Apr 19, 2026

Working on fixing Blazor WASM support.

Todo list:

  • MiniAudioEngine.DataCallback cannot be used as-is in WASM.
  • Synchronous Stream IO not supported in the browser.
  • Monitor.Wait() not supported on browser. (Used manually and in Task.Wait())
  • System.Security.Cryptography.ECDsa not supported in the browser.
  • System.Security.Cryptography.AES not supported in the browser.
  • Browser file stream cannot use Seek() and must be wrapped in a MemoryStream or another fix found.

Copy link
Copy Markdown

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Welcome to SoundFlow repository! We appreciate you taking the time to contribute.

We're excited to review your pull request and look forward to collaborating with you. Please let us know if you have any questions or need any assistance.

Thank you for your contribution!

…to replace AES and ECDsa usages that are not usable in the browser.
@KieranFoot
Copy link
Copy Markdown
Author

I have successfully found all code that is not compatible with the browser and annotated it as such.

Unfortunately, to finish WASM compatibility, a considerable amount of code will have to be re-written to use asynchronous stream IO exclusively and to take out all uses of Task.Wait() and Monitor.Wait().

Also, the frameworks implementations of Aes and ECDsa are not supported in the browser and will need to made to use implementations from the BouncyCastle.Cryptography library instead.

…fic implementations for unsupported APIs. Updated Emscripten paths and dependencies for WASM builds.
@KieranFoot
Copy link
Copy Markdown
Author

Since many implementations of ISoundDataProvider read data from a stream in their constructors, I propose moving the constructor code to an Initialize() and / or InitializeAsync() method allowing for the inner stream IO to be fully asynchronous when required.

Also, I propose the addition of ReadBytesAsync() for use in the browser.

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

Successfully merging this pull request may close these issues.

1 participant