Jump to content
everton

sound record in c++?

Recommended Posts

trebuie sa fac ceva mini proiect in visula studio 2005,(win32 form aplication) si ma gandeam sa fac un mic sound recorder care sa salveze in wave sau ceva de genul ala , intrebarea mea este se poate asa ceva ca am cautat putin pe google si nu prea am gasit mare branza :-S. Daca are cineva ceva idei va rog frumos sa m a ajutati si pe mine . Va multmesc in avans

Link to comment
Share on other sites

cu record nu am lucrat dar poate fi similar cu play.

Cauta in help mai multe despre (extrag de printr-un program de-al meu facut cu CBuilder)

sndPlaySound((LPSTR)wave, SND_MEMORY | SND_SYNC | SND_NODEFAULT);

Trebuie sa stii headerul de la wave, foloseste header de 44 bytes. Gasesti mai multe aici: https://ccrma.stanford.edu/courses/422/projects/WaveFormat/ si pe google

Pui in cod de exemplu

unsigned long waveheader[11]=

{0x46464952,0xffffffff,0x45564157,0x20746d66,

0x00000010,0x00020001,0x0000ac44,0x0002b110,

0x00100004,0x61746164,0xffffffff};

si il tii ca header, il lipesti inaintea datelor inregistrate. Inlocuiesti FFFFFFF cu dimensiunile necesare si modifici si celelalte valori pentru rate etc.

Daca nu vrei sa te complici cauta in help despre TMediaPlayer, s-ar putea sa fie mult mai usor si sa aiba functiile care le vrei.

mediaplayer.gif

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...