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

NAudio Cross Platform Support with Linux & Mac #1077

Open
Kuumba123 opened this issue Oct 1, 2023 · 15 comments
Open

NAudio Cross Platform Support with Linux & Mac #1077

Kuumba123 opened this issue Oct 1, 2023 · 15 comments

Comments

@Kuumba123
Copy link

Is NAudio cross platform with Linux & Mac . I remember seeing some github issue for this repro a little while ago saying that anything in NAudio.Core (via the nugget package) is cross platform. However I time I try to use anything in that namespace my linux app just crashes and I haven't found any examlpes online when it comes to NAudio working on any other platforms aside windows , is it really cross platform ? Im not trying to do anything advanced quite just yet , I mainly just wanna play raw sample data and some basic volume controls. Any help would be appricated :)

@smay4finger
Copy link

However I time I try to use anything in that namespace my linux app just crashes

Is there more information available then "just crashes"?

I would also be interested in a solution for Linux.

@Kuumba123
Copy link
Author

@smay4finger sorry guess I should have posted that first . All my code does is get the list of devices from the NAudio.Wave.DirectSound.Devices (using the NAudio.Core nugget package) :

        var devices = NAudio.Wave.DirectSoundOut.Devices;

This is the error message Im getting: Unhandled exception. System.DllNotFoundException: Unable to load shared library 'dsound.dll' or one of its dependencies. In order to help diagnose loading problems, consider using a tool like strace. If you're using glibc, consider setting the LD_DEBUG environment variable

@moorehousew
Copy link

Late reply but @Kuumba123 DirectSound is a Windows-only API. You might have some luck running your .NET application (compiled for Windows) under Wine, otherwise it's not available on *nix.

@markheath
Copy link
Contributor

Yes, it was a mistake to leave DirectSound in the NAudio.Core assembly. It should be moved out. I am in discussions with someone who has offered to contribute a Linux IWavePlayer implementation which would be a great addition to NAudio.

@lujiaxing
Copy link

Yes, it was a mistake to leave DirectSound in the NAudio.Core assembly. It should be moved out. I am in discussions with someone who has offered to contribute a Linux IWavePlayer implementation which would be a great addition to NAudio.

How is it going?

@markheath
Copy link
Contributor

I believe the code has been created, but am still waiting for the pull request

@DashNY
Copy link

DashNY commented Feb 13, 2024

+1. Would love to run it on my SBC (e.g. Raspberry Pi, Odroid N2+) and play sounds / capture microphone or line input.
Is there any update on the issue? Thanks.

@markheath
Copy link
Contributor

no update I'm afraid

@E-Hain
Copy link

E-Hain commented Jun 19, 2024

There seem to be quite a few people interested in a Linux compatible Naudio, myself included... any progress?

@Kuumba123
Copy link
Author

Havent had a chance to do any testing latly but last time it didnt work . From what I can tell atleast we havent really got the cross platform support features that I oringally opened this issue for.

@vchelaru
Copy link

vchelaru commented Jul 8, 2024

I am also interested in this feature. For context, I develop games using MonoGame and these natively run on Windows, Mac, and Linux. I've been using NAudio to supplement the missing Song functionality in MonoGame.

I'm interested in the general philosophy regarding cross platform versions of NAudio beyond desktop platforms. Is there any possibility of supporting it on mobile (iOS and Android) or blazor for web apps?

@PlatinumLucario
Copy link

PlatinumLucario commented Jul 9, 2024

I've also opened a discussion about adding an AlsaOut(), when a NAudio.Alsa namespace is made.
#1134

@912BIT
Copy link

912BIT commented Oct 12, 2024

Any updates on the topic?

@Consumedgrub2
Copy link

Consumedgrub2 commented Jan 12, 2025

Bump, there are no libraries that are open source, free and currently functional that work on Linux for dotnet. (Edit: That are audio libs)

@michaelhofer-slg
Copy link

Same here, would be greatly interested and willing to help.

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