18 lines
418 B
C#

namespace AudioCore.Interfaces;
public interface IAudioReader : IDisposable
{
int SampleRate { get; }
int Channels { get; }
long TotalSamples { get; }
// Read PCM float samples into the provided buffer.
// Returns number of samples actually read.
int Read(float[] buffer, int offset, int count);
// Seek to absolute sample index.
void Seek(long sampleIndex);
void Reset();
}