FreeRDP
channels/audin.h
1 
21 #ifndef FREERDP_CHANNEL_AUDIN_H
22 #define FREERDP_CHANNEL_AUDIN_H
23 
24 #include <freerdp/api.h>
25 #include <freerdp/codec/audio.h>
26 #include <freerdp/dvc.h>
27 #include <freerdp/types.h>
28 
33 #define AUDIN_CHANNEL_NAME "audin"
34 
39 #define AUDIN_DVC_CHANNEL_NAME "AUDIO_INPUT"
40 
41 typedef struct
42 {
43  BYTE MessageId;
44 } SNDIN_PDU;
45 
46 typedef enum
47 {
48  SNDIN_VERSION_Version_1 = 0x00000001,
49  SNDIN_VERSION_Version_2 = 0x00000002,
50 } SNDIN_VERSION_Version;
51 
52 typedef struct
53 {
54  SNDIN_PDU Header;
55  SNDIN_VERSION_Version Version;
57 
58 typedef struct
59 {
60  SNDIN_PDU Header;
61  UINT32 NumFormats;
62  UINT32 cbSizeFormatsPacket;
63  AUDIO_FORMAT* SoundFormats;
64  size_t ExtraDataSize;
66 
67 typedef enum
68 {
69  SPEAKER_FRONT_LEFT = 0x00000001,
70  SPEAKER_FRONT_RIGHT = 0x00000002,
71  SPEAKER_FRONT_CENTER = 0x00000004,
72  SPEAKER_LOW_FREQUENCY = 0x00000008,
73  SPEAKER_BACK_LEFT = 0x00000010,
74  SPEAKER_BACK_RIGHT = 0x00000020,
75  SPEAKER_FRONT_LEFT_OF_CENTER = 0x00000040,
76  SPEAKER_FRONT_RIGHT_OF_CENTER = 0x00000080,
77  SPEAKER_BACK_CENTER = 0x00000100,
78  SPEAKER_SIDE_LEFT = 0x00000200,
79  SPEAKER_SIDE_RIGHT = 0x00000400,
80  SPEAKER_TOP_CENTER = 0x00000800,
81  SPEAKER_TOP_FRONT_LEFT = 0x00001000,
82  SPEAKER_TOP_FRONT_CENTER = 0x00002000,
83  SPEAKER_TOP_FRONT_RIGHT = 0x00004000,
84  SPEAKER_TOP_BACK_LEFT = 0x00008000,
85  SPEAKER_TOP_BACK_CENTER = 0x00010000,
86  SPEAKER_TOP_BACK_RIGHT = 0x00020000,
87 } AUDIN_SPEAKER;
88 
89 typedef struct
90 {
91  union
92  {
93  UINT16 wValidBitsPerSample;
94  UINT16 wSamplesPerBlock;
95  UINT16 wReserved;
96  } Samples;
97  AUDIN_SPEAKER dwChannelMask;
98  GUID SubFormat;
100 
101 typedef struct
102 {
103  SNDIN_PDU Header;
104  UINT32 FramesPerPacket;
105  UINT32 initialFormat;
106  AUDIO_FORMAT captureFormat;
107  WAVEFORMAT_EXTENSIBLE* ExtraFormatData;
108 } SNDIN_OPEN;
109 
110 typedef struct
111 {
112  SNDIN_PDU Header;
113  UINT32 Result;
115 
116 typedef struct
117 {
118  SNDIN_PDU Header;
120 
121 typedef struct
122 {
123  SNDIN_PDU Header;
124  wStream* Data;
125 } SNDIN_DATA;
126 
127 typedef struct
128 {
129  SNDIN_PDU Header;
130  UINT32 NewFormat;
132 
133 #endif /* FREERDP_CHANNEL_AUDIN_H */