ReactOS 0.4.15-dev-7942-gd23573b
audio_waveout Class Reference

#include <audio_waveout.hpp>

Collaboration diagram for audio_waveout:

Public Member Functions

 audio_waveout (const audio_format &aud_fmt, audio_producer &a_buf)
 
 ~audio_waveout (void)
 
void open (void)
 
void play (void)
 
void pause (void)
 
void stop (void)
 
void close (void)
 
audio_waveout_status current_status (void)
 
BYTEbuf (void)
 
unsigned int bufsz (void)
 
unsigned int samplevalue_max (void)
 
unsigned tot_samples_buf (void)
 
unsigned int nsample (unsigned int nsamp)
 

Protected Member Functions

void init_ (void)
 
void alloc_buffers_mem_ (unsigned int, float)
 
void free_buffers_mem_ (void)
 
void init_headers_ (void)
 
void prep_headers_ (void)
 
void unprep_headers_ (void)
 

Protected Attributes

WAVEFORMATEX wave_format
 
WAVEHDRwave_headers
 
HWAVEOUT waveout_handle
 
const audio_formataud_info
 
audio_produceraudio_buf
 
DWORD playthread_id
 
audio_waveout_status status
 
float buf_secs
 
BYTEmain_buffer
 
unsigned int mb_size
 
unsigned int buffers
 

Static Private Member Functions

static DWORD WINAPI playing_procedure (LPVOID)
 

Private Attributes

HANDLE wakeup_playthread
 

Friends

class audio_buffer
 

Detailed Description

Definition at line 27 of file audio_waveout.hpp.

Constructor & Destructor Documentation

◆ audio_waveout()

audio_waveout::audio_waveout ( const audio_format aud_fmt,
audio_producer a_buf 
)
inline

Definition at line 73 of file audio_waveout.hpp.

74 : wave_headers(0),
75 aud_info(aud_fmt),
76 audio_buf(a_buf),
78 main_buffer(0),
79 mb_size(0),
81 {
82 /* Initializing internal wavein data */
83 init_();
84 }
#define _AUDIO_DEFAULT_WAVEOUTBUFFERS
Definition: audio_def.hpp:18
@ WAVEOUT_NOTREADY
unsigned int mb_size
WAVEHDR * wave_headers
audio_producer & audio_buf
void init_(void)
const audio_format & aud_info
unsigned int buffers
audio_waveout_status status

◆ ~audio_waveout()

audio_waveout::~audio_waveout ( void  )
inline

Definition at line 87 of file audio_waveout.hpp.

88 {
89 }

Member Function Documentation

◆ alloc_buffers_mem_()

void audio_waveout::alloc_buffers_mem_ ( unsigned int  buffs,
float  secs 
)
protected

Definition at line 26 of file audio_waveout.cpp.

27{
28 unsigned int onebuf_size = 0, tot_size = 0;
29
30 /* Release old memory */
31 if (main_buffer)
32 delete[] main_buffer;
33
34 if (wave_headers)
35 delete[] wave_headers;
36
37 /* Calcs size of the buffers */
38 onebuf_size = (unsigned int)((float)aud_info.byte_rate() * secs);
39 tot_size = onebuf_size * buffs;
40 /* Allocs memory for the audio buffers */
41 main_buffer = new BYTE[tot_size];
42 /* Allocs memory for the `WAVEHDR' structures */
43 wave_headers = (WAVEHDR *) new BYTE[sizeof(WAVEHDR) * buffs];
44 /* Zeros memory */
45 ZeroMemory(main_buffer, tot_size);
46 ZeroMemory(wave_headers, sizeof(WAVEHDR) * buffs);
47 /* Updates total size of the buffers */
48 mb_size = tot_size;
49}
unsigned int byte_rate(void) const
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
Definition: typeof.h:31
#define ZeroMemory
Definition: winbase.h:1712
unsigned char BYTE
Definition: xxhash.c:193

Referenced by open().

◆ buf()

BYTE * audio_waveout::buf ( void  )
inline

Definition at line 104 of file audio_waveout.hpp.

105 {
106 return main_buffer;
107 }

◆ bufsz()

unsigned int audio_waveout::bufsz ( void  )
inline

Definition at line 109 of file audio_waveout.hpp.

110 {
111 return mb_size;
112 }

◆ close()

void audio_waveout::close ( void  )

Definition at line 325 of file audio_waveout.cpp.

326{
328
329 /* If the `wave_out' object is playing audio, or it is in paused state,
330 we have to call the `stop' member function, to flush pending buffers */
332 {
333 stop();
334 }
335
336 /* When we have flushed all pending buffers, the wave out handle can be successfully closed */
338 if (err != MMSYSERR_NOERROR)
339 {
340 MessageBox(0, _T("waveOutClose Error"), 0, 0);
341 /* TODO: throw error */
342 }
343
345}
@ WAVEOUT_PAUSED
@ WAVEOUT_PLAYING
void stop(void)
void free_buffers_mem_(void)
HWAVEOUT waveout_handle
UINT MMRESULT
Definition: mmsystem.h:962
#define MMSYSERR_NOERROR
Definition: mmsystem.h:96
#define err(...)
Definition: ps.c:97
#define _T(x)
Definition: vfdio.h:22
UINT WINAPI waveOutClose(HWAVEOUT hWaveOut)
Definition: winmm.c:2257
#define MessageBox
Definition: winuser.h:5822

◆ current_status()

audio_waveout_status audio_waveout::current_status ( void  )
inline

Definition at line 99 of file audio_waveout.hpp.

100 {
101 return status;
102 }

◆ free_buffers_mem_()

void audio_waveout::free_buffers_mem_ ( void  )
protected

Definition at line 134 of file audio_waveout.cpp.

135{
136 /* Frees memory */
137 if (main_buffer)
138 delete[] main_buffer;
139
140 if (wave_headers)
141 delete[] wave_headers;
142
143 main_buffer = 0;
144 wave_headers = 0;
145}

Referenced by close().

◆ init_()

_AUDIO_NAMESPACE_START_ void audio_waveout::init_ ( void  )
protected

Definition at line 14 of file audio_waveout.cpp.

Referenced by audio_waveout().

◆ init_headers_()

void audio_waveout::init_headers_ ( void  )
protected

Definition at line 52 of file audio_waveout.cpp.

53{
54 /* If there is no memory for memory or headers, simply return */
55 if ((!wave_headers) || (!main_buffer))
56 return;
57
58 /* This is the size for one buffer */
59 DWORD buf_sz = mb_size / buffers;
60 /* This is the base address for one buffer */
61 BYTE *buf_addr = main_buffer;
62
64
65 /* Initializes headers */
66 for (unsigned int i = 0; i < buffers; ++i)
67 {
68 /* Sets the correct base address and length for the little buffer */
70 wave_headers[i].lpData = (LPSTR) buf_addr;
71
72 /* Unsets the WHDR_DONE flag */
73 wave_headers[i].dwFlags &= ~WHDR_DONE;
74
75 /* Sets the WAVEHDR user data with an unique little buffer ID# */
76 wave_headers[i].dwUser = (unsigned int)i;
77
78 /* Increments little buffer base address */
79 buf_addr += buf_sz;
80 }
81}
unsigned long DWORD
Definition: ntddk_ex.h:95
const GLuint * buffers
Definition: glext.h:5916
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
DWORD dwBufferLength
Definition: mmsystem.h:1015
DWORD dwFlags
Definition: mmsystem.h:1018
DWORD_PTR dwUser
Definition: mmsystem.h:1017
LPSTR lpData
Definition: mmsystem.h:1014
char * LPSTR
Definition: xmlstorage.h:182

Referenced by open(), and stop().

◆ nsample()

unsigned int audio_waveout::nsample ( unsigned int  nsamp)
inline

Definition at line 129 of file audio_waveout.hpp.

130 {
131 unsigned int svalue;
132
133 if (aud_info.bits() == 16)
134 svalue = (unsigned int)abs(*((short *)(main_buffer + aud_info.bytes_in_samples(nsamp))));
135 else if (aud_info.bits() == 8)
136 svalue = (unsigned int)((ptrdiff_t) *(main_buffer + aud_info.bytes_in_samples(nsamp)));
137 else
138 svalue = 0;
139
140 return svalue;
141 }
unsigned short int bits(void) const
unsigned int bytes_in_samples(unsigned int samples) const
__kernel_ptrdiff_t ptrdiff_t
Definition: linux.h:247
#define abs(i)
Definition: fconv.c:206

◆ open()

void audio_waveout::open ( void  )

Definition at line 148 of file audio_waveout.cpp.

149{
151 HANDLE playthread_handle = 0;
152
153 /* Checkin the status of the object */
155 {
156 /* TODO: throw error */
157 }
158
159 /* Creating the EVENT object that will be signaled when
160 the playing thread has to wake up */
163 {
165 /* TODO: throw error */
166 }
167
168 /* Inialize buffers for recording audio data from the wavein audio line */
171
172 /* Sound format that will be captured by wavein */
179
180 /* Creating the recording thread */
181 playthread_handle = CreateThread(NULL,
182 0,
184 (PVOID)this,
185 0,
187 /* Checking thread handle */
188 if (!playthread_handle)
189 {
190 /* Updating status */
192 /* TODO: throw error */
193 }
194
195 /* We don't need the thread handle anymore, so we can close it from now.
196 (We'll just need the thread ID for the `waveInOpen' API) */
197 CloseHandle(playthread_handle);
198
199 /* Reset the `audio_source' to the start position */
201 /* Opens the WAVE_OUT device */
206 0,
208 if (err != MMSYSERR_NOERROR)
209 {
210 MessageBox(0, _T("waveOutOpen Error"), 0, 0);
211 /* TODO: throw error */
212 }
213
215}
@ WAVEOUT_ERR
@ WAVEOUT_READY
#define WAVE_FORMAT_PCM
Definition: constants.h:425
unsigned int sample_rate(void) const
unsigned short int channels(void) const
unsigned int block_align(void) const
void set_position_start(void)
static DWORD WINAPI playing_procedure(LPVOID)
void init_headers_(void)
void alloc_buffers_mem_(unsigned int, float)
#define NULL
Definition: types.h:112
#define FALSE
Definition: types.h:117
#define CloseHandle
Definition: compat.h:739
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
Definition: thread.c:137
#define CALLBACK_THREAD
Definition: mmsystem.h:151
#define WAVE_ALLOWSYNC
Definition: mmsystem.h:189
#define WAVE_MAPPER
Definition: mmsystem.h:187
DWORD nAvgBytesPerSec
Definition: audioclient.idl:43
WORD wBitsPerSample
Definition: audioclient.idl:45
DWORD nSamplesPerSec
Definition: audioclient.idl:42
#define CreateEvent
Definition: winbase.h:3748
MMRESULT WINAPI waveOutOpen(LPHWAVEOUT lphWaveOut, UINT uDeviceID, LPCWAVEFORMATEX lpFormat, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD dwFlags)
Definition: winmm.c:2246

◆ pause()

void audio_waveout::pause ( void  )

Definition at line 272 of file audio_waveout.cpp.

273{
275
276 /* If the waveout object is not playing audio, do nothing */
277 if (status == WAVEOUT_PLAYING)
278 {
279 /* Updating status */
281 /* Tells to audio driver to pause audio */
283 if (err != MMSYSERR_NOERROR)
284 {
285 MessageBox(0, _T("waveOutPause Error"), 0, 0);
286 /* TODO: throw error */
287 }
288 }
289}
UINT WINAPI waveOutPause(HWAVEOUT hWaveOut)
Definition: winmm.c:2371

◆ play()

void audio_waveout::play ( void  )

Definition at line 218 of file audio_waveout.cpp.

219{
221 unsigned int i;
222
223 if (!main_buffer)
224 {
225 /* TODO; throw error, or assert */
226 return;
227 }
228
229 /* If the status is PAUSED, we have to resume the audio playing */
230 if (status == WAVEOUT_PAUSED)
231 {
232 /* Updates status */
234 /* Tells to the driver to resume audio playing */
236 /* Wakeup playing thread */
238 return;
239 } /* if status == WAVEOUT_PAUSED */
240
241 if (status != WAVEOUT_READY)
242 return;
243
244 /* Prepares WAVEHDR structures */
246 /* Sets correct status */
248 /* Reads the audio from the start */
249 //audio_buf.set_position_start();
250
251 /* Reads the first N bytes from the audio buffer, where N = the total
252 size of all little buffers */
254
255 /* Wakeup the playing thread */
257
258 /* Sends all the little buffers to the audio driver, so it can play
259 the sound data */
260 for (i = 0; i < buffers; ++i)
261 {
263 if (err != MMSYSERR_NOERROR)
264 {
265 MessageBox(0, _T("waveOutWrite Error"), 0, 0);
266 /* TODO: throw error */
267 }
268 }
269}
virtual unsigned int read(BYTE *, unsigned int)=0
void prep_headers_(void)
BOOL WINAPI DECLSPEC_HOTPATCH SetEvent(IN HANDLE hEvent)
Definition: synch.c:733
UINT WINAPI waveOutWrite(HWAVEOUT hWaveOut, LPWAVEHDR lpWaveOutHdr, UINT uSize)
Definition: winmm.c:2341
UINT WINAPI waveOutRestart(HWAVEOUT hWaveOut)
Definition: winmm.c:2399

◆ playing_procedure()

DWORD WINAPI audio_waveout::playing_procedure ( LPVOID  arg)
staticprivate

Definition at line 348 of file audio_waveout.cpp.

349{
350 MSG msg;
351 WAVEHDR *phdr;
353 audio_waveout *_this = (audio_waveout *)arg;
354 unsigned int read_size;
355
356 /* Check the arg pointer */
357 if (_this == 0)
358 return 0;
359
360 /* The thread can go to sleep for now. It will be wake up only when
361 there is audio data to be recorded */
362 if (_this->wakeup_playthread)
364
365 /* Entering main polling loop */
366 while (GetMessage(&msg, 0, 0, 0))
367 {
368 switch (msg.message)
369 {
370 case MM_WOM_DONE:
371 phdr = (WAVEHDR *)msg.lParam;
372
373 /* If the status of the `wave_out' object is different
374 than playing, then the thread can go to sleep */
375 if ((_this->status != WAVEOUT_PLAYING) &&
376 (_this->status != WAVEOUT_FLUSHING) &&
377 (_this->wakeup_playthread))
378 {
380 }
381
382 /* The playing thread doesn't have to sleep, so let's checking
383 first if the little buffer has been sent to the audio driver
384 (it has the WHDR_DONE flag). If it is, we can read new audio
385 datas from the `audio_producer' object, refill the little buffer,
386 and resend it to the driver with waveOutWrite( ) API */
387 if (phdr->dwFlags & WHDR_DONE)
388 {
389 if (_this->status == WAVEOUT_PLAYING)
390 {
391 /* Here the thread is still playing a sound, so it can
392 read new audio data from the `audio_producer' object */
393 read_size = _this->audio_buf.read((BYTE *)phdr->lpData,
394 phdr->dwBufferLength);
395 } else
396 read_size = 0;
397
398 /* If the `audio_producer' object, has produced some
399 audio data, so `read_size' will be > 0 */
400 if (read_size)
401 {
402 /* Adjusts the correct effectively read size */
403 phdr->dwBufferLength = read_size;
404
405 /* Before sending the little buffer to the driver,
406 we have to remove the `WHDR_DONE' flag, because
407 the little buffer now contain new audio data that have to be played */
408 phdr->dwFlags &= ~WHDR_DONE;
409
410 /* Plays the sound of the little buffer */
412 phdr,
413 sizeof(WAVEHDR));
414
415 /* Checking if any error has occured */
416 if (err != MMSYSERR_NOERROR)
417 {
418 MessageBox(0, _T("waveOutWrite Error"), 0, 0);
419 /* TODO: throw error */
420 }
421 }
422 else
423 {
424 /* Here `read_size' is 0, so the `audio_producer' object,
425 doesn't have any sound data to produce anymore. So,
426 now we have to see the little buffer #ID to establishing what to do */
427 if (phdr->dwUser == 0)
428 {
429 /* Here `read_size' is 0, and the buffer user data
430 contain 0, so this is the first of N little
431 buffers that came back with `WHDR_DONE' flag;
432 this means that this is the last little buffer
433 in which we have to read data to; so we can
434 _STOP_ reading data from the `audio_producer'
435 object: doing this is accomplished just setting
436 the current status as "WAVEOUT_FLUSHING" */
437 _this->status = WAVEOUT_FLUSHING;
438 }
439 else if (phdr->dwUser == (_this->buffers - 1))
440 {
441 /* Here `read_size' and the buffer user data, that
442 contain a buffer ID#, is equal to the number of
443 the total buffers - 1. This means that this is
444 the _LAST_ little buffer that has been played by
445 the audio driver. We can STOP the `wave_out'
446 object now, or restart the sound playing, if we have a infinite loop */
447 _this->stop();
448
449 /* Let the thread go to sleep */
450 if (_this->audio_buf.play_finished)
451 _this->audio_buf.play_finished();
452
453 if (_this->wakeup_playthread)
455 INFINITE);
456
457 } /* if (phdr->dwUser == (_this->buffers - 1)) */
458 } /* if read_size != 0 */
459 } /* (phdr->dwFlags & WHDR_DONE) */
460 break; /* end case */
461 case MM_WOM_CLOSE:
462 /* The thread can exit now */
463 return 0;
464 break;
465 case MM_WOM_OPEN:
466 /* Do nothing */
467 break;
468 } /* end switch(msg.message) */
469 } /* end while(GetMessage(...)) */
470
471 return 0;
472}
@ WAVEOUT_FLUSHING
#define msg(x)
Definition: auth_time.c:54
void(* play_finished)(void)
#define INFINITE
Definition: serial.h:102
if(dx< 0)
Definition: linetemp.h:194
#define MM_WOM_CLOSE
Definition: mmsystem.h:57
#define MM_WOM_OPEN
Definition: mmsystem.h:56
#define MM_WOM_DONE
Definition: mmsystem.h:58
#define WHDR_DONE
Definition: mmsystem.h:193
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
Definition: synch.c:82
TW_UINT32 TW_UINT16 TW_UINT16 MSG
Definition: twain.h:1829
#define GetMessage
Definition: winuser.h:5790

Referenced by open().

◆ prep_headers_()

void audio_waveout::prep_headers_ ( void  )
protected

Definition at line 84 of file audio_waveout.cpp.

85{
87 bool error = false;
88
89 /* If there is no memory for memory or headers, throw error */
90 if ((!wave_headers) || (!main_buffer) || (!waveout_handle))
91 {
92 /* TODO: throw error! */
93 }
94
95 for (unsigned int i = 0; i < buffers; ++i)
96 {
98 if (err != MMSYSERR_NOERROR)
99 error = true;
100 }
101
102 if (error)
103 {
104 /* TODO: throw error indicating which header i-th is errorneous */
105 }
106}
#define error(str)
Definition: mkdosfs.c:1605
UINT WINAPI waveOutPrepareHeader(HWAVEOUT hWaveOut, WAVEHDR *lpWaveOutHdr, UINT uSize)
Definition: winmm.c:2277

Referenced by play().

◆ samplevalue_max()

unsigned int audio_waveout::samplevalue_max ( void  )
inline

Definition at line 114 of file audio_waveout.hpp.

115 {
116 if (aud_info.bits() == 16)
117 return (unsigned int)65535;
118 else if (aud_info.bits() == 8)
119 return (unsigned int)255;
120 else
121 return 0;
122 }

◆ stop()

void audio_waveout::stop ( void  )

Definition at line 292 of file audio_waveout.cpp.

293{
295
296 /* Checks the current status */
297 if ((status != WAVEOUT_PLAYING) &&
300 {
301 /* Do nothing */
302 return;
303 }
304
305 /* Sets a new status */
307 /* Flushes pending audio datas */
309 if (err != MMSYSERR_NOERROR)
310 {
311 MessageBox(0, _T("err WaveOutReset.\n"),_T("ERROR"), 0);
312 /* TODO: throw error */
313 }
314
315 /* Sets the start position of the audio buffer */
317 /* Cleans little buffers */
320 /* Refreshes the status */
322}
@ WAVEOUT_STOP
void unprep_headers_(void)
UINT WINAPI waveOutReset(HWAVEOUT hWaveOut)
Definition: winmm.c:2385

Referenced by close(), and playing_procedure().

◆ tot_samples_buf()

unsigned audio_waveout::tot_samples_buf ( void  )
inline

Definition at line 124 of file audio_waveout.hpp.

125 {
127 }
unsigned int samples_in_bytes(unsigned int bytes) const

◆ unprep_headers_()

void audio_waveout::unprep_headers_ ( void  )
protected

Definition at line 109 of file audio_waveout.cpp.

110{
112 bool error = false;
113
114 /* If there is no memory for memory or headers, throw error */
115 if ((!wave_headers) || (!main_buffer) || (!waveout_handle))
116 {
117 /* TODO: throw error! */
118 }
119
120 for (unsigned int i = 0; i < buffers; ++i)
121 {
123 if (err != MMSYSERR_NOERROR)
124 error = true;
125 }
126
127 if (error)
128 {
129 /* TODO: throw error indicating which header i-th is errorneous */
130 }
131}
UINT WINAPI waveOutUnprepareHeader(HWAVEOUT hWaveOut, LPWAVEHDR lpWaveOutHdr, UINT uSize)
Definition: winmm.c:2307

Referenced by stop().

Friends And Related Function Documentation

◆ audio_buffer

friend class audio_buffer
friend

Definition at line 29 of file audio_waveout.hpp.

Member Data Documentation

◆ aud_info

const audio_format& audio_waveout::aud_info
protected

Definition at line 40 of file audio_waveout.hpp.

Referenced by alloc_buffers_mem_(), nsample(), open(), samplevalue_max(), and tot_samples_buf().

◆ audio_buf

audio_producer& audio_waveout::audio_buf
protected

Definition at line 41 of file audio_waveout.hpp.

Referenced by open(), play(), playing_procedure(), and stop().

◆ buf_secs

float audio_waveout::buf_secs
protected

Definition at line 47 of file audio_waveout.hpp.

Referenced by init_(), and open().

◆ buffers

unsigned int audio_waveout::buffers
protected

◆ main_buffer

BYTE* audio_waveout::main_buffer
protected

◆ mb_size

unsigned int audio_waveout::mb_size
protected

Definition at line 56 of file audio_waveout.hpp.

Referenced by alloc_buffers_mem_(), bufsz(), init_headers_(), play(), and tot_samples_buf().

◆ playthread_id

DWORD audio_waveout::playthread_id
protected

Definition at line 44 of file audio_waveout.hpp.

Referenced by init_(), and open().

◆ status

audio_waveout_status audio_waveout::status
protected

Definition at line 46 of file audio_waveout.hpp.

Referenced by current_status(), and playing_procedure().

◆ wakeup_playthread

HANDLE audio_waveout::wakeup_playthread
private

Definition at line 33 of file audio_waveout.hpp.

Referenced by init_(), open(), play(), and playing_procedure().

◆ wave_format

WAVEFORMATEX audio_waveout::wave_format
protected

Definition at line 36 of file audio_waveout.hpp.

Referenced by init_(), and open().

◆ wave_headers

WAVEHDR* audio_waveout::wave_headers
protected

◆ waveout_handle

HWAVEOUT audio_waveout::waveout_handle
protected

The documentation for this class was generated from the following files: