Workbench Library  0.1b
workbench_audio.h
Go to the documentation of this file.
1 
9 #pragma once
10 
15 #ifndef SAMPLE_FORMAT
16 #define SAMPLE_FORMAT Float32
17 #endif
18 
19 #define _SAMPLE_TYPE_NAME(T) _SAMPLE_##T
20 #define _SAMPLE_TYPE(T) _SAMPLE_TYPE_NAME(T)
21 
22 #define _SAMPLE_Float32 float
23 #define _SAMPLE_Int32 uint32_t
24 #define _SAMPLE_Int24 uint32_t
25 #define _SAMPLE_Int16 uint16_t
26 #define _SAMPLE_Int8 uint8_t
27 
35 #define SAMPLE _SAMPLE_TYPE(SAMPLE_FORMAT)
36 
37 #define _PA_SAMPLE_FORMAT_HELPER(x) pa##x
38 #define _PA_SAMPLE_FORMAT(x) _PA_SAMPLE_FORMAT_HELPER(x)
39 
41 #define PA_SAMPLE_FORMAT _PA_SAMPLE_FORMAT(SAMPLE_FORMAT)