TWaveIn class v2.1
-------------------

TWaveIn is a wrapper class, encapsulating the WinAPI waveIn*
functions.

Latency: There will be some time differance between the moment
the A/D samples the incomming signal and the sample becomes
available via the Read* method. The latency (counted in samples)
is:
"samples per buffer"

Step by step instructions of how to use it:

// 1. Include the file TWaveIn.hpp in your project:
   #include "TWaveIn.hpp"

// 2. Create a TWaveIn object:
   TWaveIn *wiTest = new TWaveIn(20); // using 20 buffers

// 3. Open the wave out device:
   wiTest->OpenPCM(WAVE_MAPPER,200);  /* WAVE_MAPPER,
		                         200 samples per buffer,
                		         44100 samples/second,
		                         2 channels,
		                         16 bits/sample */

// 4. Read one second of raw sound data:
   i16 LeftChannel[44100], RightChannel[44100];

   for( int sample=0; sample<44100; sample++ ) {
       LeftChannel[sample]  = wiTest->Read_16();
       RightChannel[sample] = wiTest->Read_16();
   }

// 5. Close the wave in device:
   wiTest->Close();

Please report success or failure to
ted@lyncon.se

Kind regards,
Ted Lyngmo
17-June-2003