Files
UmaViewer/Assets/Scripts/Audio/NAudio/Wave/WaveOutputs/IWaveProviderFloat.cs
T
2022-09-10 16:59:44 +08:00

29 lines
940 B
C#

using System;
using System.Collections.Generic;
using System.Text;
namespace NAudio.Wave
{
/// <summary>
/// Like IWaveProvider, but makes it much simpler to put together a 32 bit floating
/// point mixing engine
/// </summary>
public interface ISampleProvider
{
/// <summary>
/// Gets the WaveFormat of this Sample Provider.
/// </summary>
/// <value>The wave format.</value>
WaveFormat WaveFormat { get; }
/// <summary>
/// Fill the specified buffer with 32 bit floating point samples
/// </summary>
/// <param name="buffer">The buffer to fill with samples.</param>
/// <param name="offset">Offset into buffer</param>
/// <param name="count">The number of samples to read</param>
/// <returns>the number of samples written to the buffer.</returns>
int Read(float[] buffer, int offset, int count);
}
}