13#if __has_include(<choc/audio/choc_SampleBuffers.h>)
14 #include <choc/audio/choc_SampleBuffers.h>
16 #include "../../3rd_party/choc/audio/choc_SampleBuffers.h"
19#include "../utilities/tracktion_Time.h"
59 virtual bool readSamples (choc::buffer::ChannelArrayView<float>&) = 0;
Base class for audio based readers that can be chained together.
virtual SampleCount getPosition()=0
Must return the sample position that will be read from next.
virtual void setPosition(TimePosition)=0
Should set the time position to be read from next.
virtual double getSampleRate()=0
Should set the time position to be read from next.
virtual void reset()=0
Signifies a break in continuity and that the stream should reset itself.
virtual ~AudioReader()=default
Destructor.
virtual bool readSamples(choc::buffer::ChannelArrayView< float > &)=0
Must read a number of frames from the source, filling the buffer.
virtual choc::buffer::ChannelCount getNumChannels()=0
Must return the number of channels in the reader.
virtual void setPosition(SampleCount)=0
Should set the sample position to be read from next.
Represents a position in real-life time.