DELPHI AREA
MESSAGE BOARD
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   Favorites   Watched Topics     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

AudioRecorder and MP3. Is it possible?

 
   Reply to topic       DELPHI AREA Forum Index -> DELPHI AREA's Products
View previous topic :: View next topic  
Author Message
Ray Adams
Member


Joined: 04 Nov 2004
Posts: 1

PostPosted: 04/11/04 11:36    Post subject: AudioRecorder and MP3. Is it possible? Reply with quote

Hi.
At first, thanks for the great audio package! Its very usefull!
And now some questions.
1st.
I try to record directly to MP3 format. I've installed mp3 encoder , and trying to use OnFormat event. Also I found record for MP3 format
Code:

  mpeglayer3waveformat_tag=packed record
  wfx:TWAVEFORMATEX;
  wID:word;
  fdwFlags:dword;
  nBlockSize:word;
  nFramesPerBlock:word;
  nCodecDelay:word;
  end;

and here is a code
Code:

procedure TMainForm.StockAudioRecorderFormat(Sender: TObject;
  out pWaveFormat: PWaveFormatEx; var FreeIt: Boolean);
begin
     FreeIt:=false;
     pWaveFormat:=@mp3;
     mp3.wfx.nChannels:=2;
     mp3.wfx.nSamplesPerSec:=44100;
     mp3.wfx.nAvgBytesPerSec:=44100;
     mp3.wfx.wBitsPerSample:=8;
     mp3.wfx.cbSize:=sizeof(mp3.wfx);
     mp3.wfx.nBlockAlign:=2;

     //#WAVE_FORMAT_MPEGLAYER3                 0x0055 /* ISO/MPEG Layer3 Format Tag */
     mp3.wfx.wFormatTag:=$55;

     mp3.nFramesPerBlock:=8;// ???
     mp3.nCodecDelay:=0;// ???
     //MPEGLAYER3_FLAG_PADDING_ISO      0x00000000
     mp3.fdwFlags:=0;
     // MPEGLAYER3_ID_MPEG               1
     mp3.wID:=1;
end;

I don't know is it a right way to force use MP3 encoder or not. It doesnt work
Any one know how to do it?
Back to top
View user's profile
Display posts from previous:   
   Reply to topic       DELPHI AREA Forum Index -> DELPHI AREA's Products All times are GMT
Page 1 of 1

Add to favorites

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group