Skip to content

Any plans to support WASM / Browser? #9

Description

@sandreas

Hello,

first of all: Thanks for this great library.

Today I tried to use it with Linux and it worked flawlessly. Unfortunately when using an AvaloniaUI Cross Platform GUI Application and trying to start the WASM / Browser build, there is an error:

Unsupported Operating System: Browser

Since this is a wrapper for miniaudio and miniaudio seems to support WASM builds, I would like to ask, if you plan to integrate support for WASM or if I missed something

miniaudio works on all the major desktop and mobile platforms, including Windows, macOS, Linux, BSD, iOS, Android and Web (via Emscripten).

Examples:

I basically ran all this using the AvaloniaUI xplat example and the SoundFlow example from the readme using a MemoryStream to rule out local file accessing errors:

using var audioEngine = new MiniAudioEngine(44100, Capability.Playback);

// 
var audioBytes = Convert.FromBase64(".....");
var audioStream = new MemoryStream(audioBytes);

// Create a SoundPlayer and load an audio file
var player = new SoundPlayer(new StreamDataProvider(audioStream));

// Add the player to the master mixer
Mixer.Master.AddComponent(player);

// Start playback
player.Play();

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is neededin-progressThis issue is actively being worked on; development is currently in progress.

    Projects

    • Status
      In progress

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions