Skip to content

Commit

Permalink
Adding defaults for StereoToMonoProvider16 volumes - resolves #267
Browse files Browse the repository at this point in the history
  • Loading branch information
markheath committed Dec 5, 2017
1 parent b5dc520 commit 6b6860b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions NAudio/Wave/WaveProviders/StereoToMonoProvider16.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ public class StereoToMonoProvider16 : IWaveProvider
/// <param name="sourceProvider">Stereo 16 bit PCM input</param>
public StereoToMonoProvider16(IWaveProvider sourceProvider)
{
LeftVolume = 0.5f;
RightVolume = 0.5f;
if (sourceProvider.WaveFormat.Encoding != WaveFormatEncoding.Pcm)
{
throw new ArgumentException("Source must be PCM");
Expand Down

0 comments on commit 6b6860b

Please sign in to comment.