Fixed Mat and CMakeLists

This commit is contained in:
2024-09-16 16:18:49 -07:00
parent 25762b0c29
commit 681c0d09be
8 changed files with 620 additions and 424 deletions

View File

@@ -10,8 +10,8 @@ namespace ehs
{
enum class AudioDeviceType
{
OUTPUT = 0x0,
INPUT = 0x1,
OUTPUT = 0x0,
ALL = 0x2
};
@@ -28,13 +28,12 @@ namespace ehs
protected:
AudioDeviceType type;
DataType dataType;
UInt_16 bitDepth;
UInt_16 byteDepth;
UInt_32 sampleRate;
UInt_32 channels;
UInt_32 period;
UInt_32 latency;
UInt_64 maxFrames;
bool streaming;
public:
virtual ~BaseAudioDevice() = default;
@@ -45,19 +44,15 @@ namespace ehs
BaseAudioDevice& operator=(const BaseAudioDevice& device);
virtual void Release();
virtual void OpenStream();
virtual void CloseStream();
virtual UInt_64 SendStream(void *data, UInt_64 size);
virtual UInt_64 SendStream(const void *data, UInt_64 size);
virtual UInt_64 GetAvailFrames() const;
virtual UInt_64 ReceiveStream(void *data, UInt_64 size);
virtual Byte* Map(UInt_64* offset, UInt_64* frames);
virtual void UnMap(UInt_64 offset, UInt_64 frames);
void BridgeStreams(UInt_64 bufferSize);
AudioDeviceType GetType() const;
@@ -89,7 +84,7 @@ namespace ehs
UInt_64 GetMaxFrames() const;
bool IsStreaming() const;
virtual bool IsStreaming() const;
virtual bool IsValid() const;