Skip to content

Commit 575fcc0

Browse files
committed
- added SetVolume() README note
- fixed correct output volume device on Linux
1 parent f42218b commit 575fcc0

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

NetCoreAudio/Players/LinuxPlayer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public override Task SetVolume(byte percent)
2424
if (percent > 100)
2525
throw new ArgumentOutOfRangeException(nameof(percent), "Percent can't exceed 100");
2626

27-
var tempProcess = StartBashProcess($"amixer -M set Headphone {percent}%");
27+
var tempProcess = StartBashProcess($"amixer -M set 'Master' {percent}%");
2828
tempProcess.WaitForExit();
2929

3030
return Task.CompletedTask;

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@ Stops any current playback and clears the buffer. Sets Playing and Paused flags
4040

4141
Stopped playback cannot be resumed. If the same file needs to be played again, it can only be played from the beginning.
4242

43+
### SetVolume()
44+
45+
Sets the playing volume as percent
46+
4347
## Events
4448

4549
### EventHandler PlaybackFinished

0 commit comments

Comments
 (0)