1<html> 2 3<head> 4<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 5<LINK rel="stylesheet" type="text/css" href="../../../CSS/revolution.css"> 6<title>THPAudioWriteFrame</title> 7</head> 8 9<body> 10 11<h1>THPAudioWriteFrame</h1> 12 13<h2>C Specification</h2> 14 15<dl> 16<dd><pre><code>#include <win32/thpaudio.h></code></pre></dd> 17<dd><pre><code>s32 THPAudioWriteFrame(THPAudioHandle* handle, FILE* output, s32 flag);</code></pre></dd> 18</dl> 19 20<h2>Arguments</h2> 21<table border="1" cellpadding="3" cellspacing="0.1"> 22 <tr> 23<td width="120" bgcolor="#ffffe8"><strong><em><CODE>handle</CODE></em></strong></td> 24<td width="520">Pointer to a <A href="THPAudioHandle.html"><code>THPAudioHandle</code></A> structure.</td> 25 </tr> 26 <tr> 27<td width="120" bgcolor="#ffffe8"><strong><em><CODE>output</CODE></em></strong></td> 28<td width="520">File pointer to the output file. </td> 29 </tr> 30 <tr> 31<td width="120" bgcolor="#ffffe8"><strong><em><CODE>flag</CODE></em></strong></td> 32<td width="520">Final frame flag. </td> 33 </tr> 34</table> 35 36<h2>Return Values</h2> 37<p> 38<CODE>TRUE</CODE> if successful, <font face="Courier New">FALSE</font> otherwise. 39</p> 40 41<h2>Description</h2> 42<p> 43This function gets the audio data of the current frame from the WAV file associated with <code>handle</code>. Subsequently, this function encodes the acquired audio data using <CODE>ADPCM</CODE> and outputs to <code>output</code>. 44</p> 45<p> 46This function determines the current frame when it was invoked with the <code>currentFrameNumber</code> member of the <A href="THPAudioHandle.html"><code>THPAudioHandle</code> structure</A>. <code>currentFrameNumber</code> is initialized by the <A href="THPAudioCreateHandle.html"><code>THPAudioCreateHandle</code> function</A> and is updated each time this (<code>THPAudioWriteFrame</code>) function is called. 47</p> 48<p> 49<code>flag</code> is normally set to zero. Set to one if outputting the final frame of the audio data. 50</p> 51 52<h2>See Also</h2> 53<p> 54<A href="THPAudioCreateHandle.html"><code>THPAudioCreateHandle</code></A>, <A href="THPAudioHandle.html"><code>THPAudioHandle</code></A> 55</p> 56 57<h2>Revision History</h2> 58<P>03/01/2006 Initial version.</P> 59</body> 60</html>