www.pudn.com > audiocapture.zip > Sound.cpp, change:2001-04-17,size:1069b


//--------------------------------------------------------------------------- 
#include <vcl.h> 
#pragma hdrstop 
 
#include "Sound.h" 
//--------------------------------------------------------------------------- 
#pragma package(smart_init) 
#pragma resource "*.dfm" 
TForm1 *Form1; 
//--------------------------------------------------------------------------- 
__fastcall TForm1::TForm1(TComponent* Owner) 
  : TForm(Owner) 
{ 
  Audio=new TAudioCap("c:\\AAAAAAAAAAAA.wav",8000,8); 
} 
//--------------------------------------------------------------------------- 
 
 
void __fastcall TForm1::StartClick(TObject *Sender) 
{ 
  Audio->Start();   
} 
//--------------------------------------------------------------------------- 
 
void __fastcall TForm1::StopClick(TObject *Sender) 
{ 
  Audio->Stop(); 
} 
//--------------------------------------------------------------------------- 
 
void __fastcall TForm1::FormClose(TObject *Sender, TCloseAction &Action) 
{ 
  delete Audio;   
} 
//---------------------------------------------------------------------------