Click here to Skip to main content
15,889,863 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRe: Encode audio from .wav to .aac Pin
jeron17-Oct-13 3:57
jeron17-Oct-13 3:57 
QuestionWhere is PCMFORMAT defined? Pin
Vaclav_3-Oct-13 5:21
Vaclav_3-Oct-13 5:21 
AnswerRe: Where is PCMFORMAT defined? Pin
Maximilien3-Oct-13 7:16
Maximilien3-Oct-13 7:16 
GeneralRe: Where is PCMFORMAT defined? Pin
Vaclav_3-Oct-13 8:13
Vaclav_3-Oct-13 8:13 
GeneralRe: Where is PCMFORMAT defined? Pin
Maximilien3-Oct-13 9:37
Maximilien3-Oct-13 9:37 
GeneralRe: Where is PCMFORMAT defined? SOLVED Pin
Vaclav_3-Oct-13 17:39
Vaclav_3-Oct-13 17:39 
AnswerRe: Where is PCMFORMAT defined? Pin
Albert Holguin8-Oct-13 7:28
professionalAlbert Holguin8-Oct-13 7:28 
QuestionwaveOutWrite while using header loops returns WOM_DONE Pin
Vaclav_2-Oct-13 9:39
Vaclav_2-Oct-13 9:39 
I am having problem detecting when the waveOutWrite is finished when I specify number of loops to output. I output 1kHz test tone and it should be about 5 seconds long. The waveOutWrite returns WOM_DONE to the callback function immediately when it is executed.

In debug the code works as expected, the tone is there for 5 seconds.
The WOM_DONE is still returned before the “loop” is done.

Here is the code snippet:

pcm[i].lFreq = Freq;
pcm[i].dDelay = 1;
pcm[i].whdr.dwFlags = WHDR_BEGINLOOP | WHDR_ENDLOOP ;
pcm[i].whdr.dwLoops = 5; // about 5 seconds

if(!pcm[i].C_CreateSinus())
TRACE("\nFailed pcm[i].C_CreateSinus() %i ", i );

mmres = waveOutPrepareHeader(hwout, & pcm[i].whdr, sizeof(WAVEHDR));
if (mmres != MMSYSERR_NOERROR) {ASSERT(0); bOK = FALSE;}

mmres = waveOutWrite(hwout, & pcm[i].whdr, sizeof(WAVEHDR));

Any help would be appreciated.
Cheers
Vaclav
QuestionRe: waveOutWrite while using header loops returns WOM_DONE Pin
David Crow2-Oct-13 9:49
David Crow2-Oct-13 9:49 
AnswerRe: waveOutWrite while using header loops returns WOM_DONE Pin
Vaclav_2-Oct-13 10:09
Vaclav_2-Oct-13 10:09 
SuggestionRe: waveOutWrite while using header loops returns WOM_DONE Pin
David Crow2-Oct-13 10:32
David Crow2-Oct-13 10:32 
GeneralRe: waveOutWrite while using header loops returns WOM_DONE Pin
Vaclav_3-Oct-13 4:25
Vaclav_3-Oct-13 4:25 
GeneralRe: waveOutWrite while using header loops returns WOM_DONE Pin
Vaclav_3-Oct-13 8:01
Vaclav_3-Oct-13 8:01 
SuggestionRe: waveOutWrite while using header loops returns WOM_DONE Pin
David Crow7-Oct-13 2:53
David Crow7-Oct-13 2:53 
GeneralRe: waveOutWrite while using header loops returns WOM_DONE Pin
Vaclav_7-Oct-13 5:09
Vaclav_7-Oct-13 5:09 
QuestionNumerical processing in C/C++ - text(books) resources? OT Pin
Vaclav_30-Sep-13 15:13
Vaclav_30-Sep-13 15:13 
AnswerRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Richard MacCutchan30-Sep-13 21:41
mveRichard MacCutchan30-Sep-13 21:41 
GeneralRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Member 103174295-Oct-13 7:56
Member 103174295-Oct-13 7:56 
GeneralRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Richard MacCutchan5-Oct-13 20:46
mveRichard MacCutchan5-Oct-13 20:46 
AnswerRe: Numerical processing in C/C++ - text(books) resources? OT Pin
CPallini2-Oct-13 0:50
mveCPallini2-Oct-13 0:50 
AnswerRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Albert Holguin8-Oct-13 5:47
professionalAlbert Holguin8-Oct-13 5:47 
GeneralRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Vaclav_8-Oct-13 6:18
Vaclav_8-Oct-13 6:18 
GeneralRe: Numerical processing in C/C++ - text(books) resources? OT Pin
Albert Holguin8-Oct-13 7:21
professionalAlbert Holguin8-Oct-13 7:21 
QuestionAccess specifier in multiple inheritance Pin
TheHelenLee30-Sep-13 10:24
TheHelenLee30-Sep-13 10:24 
AnswerRe: Access specifier in multiple inheritance Pin
.dan.g.30-Sep-13 18:51
professional.dan.g.30-Sep-13 18:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.