BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Delphi 2006 with DirectSound SDK 9

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Multimedia
View previous topic :: View next topic  
Author Message
Mathieu
Guest





PostPosted: Fri Apr 13, 2007 8:11 am    Post subject: Delphi 2006 with DirectSound SDK 9 Reply with quote



Hi,
I want play WAV files with DirectSound 9 SDK. How can I make play fonction ?

This is my code about my Buffer, is it valid ?

public
buffer:tDSBUFFERDESC;

buffer.dwSize := 1024;
buffer.dwFlags := DSBCAPS_CTRLFREQUENCY;
buffer.dwBufferBytes := DSBCAPS_PRIMARYBUFFER;
buffer.dwReserved := 0;
buffer.guid3DAlgorithm := DS3DALG_DEFAULT;
buffer.lpwfxFormat.wFormatTag:=WAVE_FORMAT_PCM;
buffer.lpwfxFormat.nChannels:=2;
buffer.lpwfxFormat.nSamplesPerSec:=(44100 div 100);
buffer.lpwfxFormat.nAvgBytesPerSec:=buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.nBlockAlign:= buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.wBitsPerSample:=buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.cbSize:=0;


Thanks

Mat in Paris.
Back to top
Zamrony P Juhara
Guest





PostPosted: Wed Apr 18, 2007 3:45 pm    Post subject: Re: Delphi 2006 with DirectSound SDK 9 Reply with quote



You can try reading article that I wrote

http://juhara.com/article-9-playing-wav-and-midi-with-directx.html

as a start

Mathieu wrote:
Quote:
Hi,
I want play WAV files with DirectSound 9 SDK. How can I make play fonction ?

This is my code about my Buffer, is it valid ?

public
buffer:tDSBUFFERDESC;

buffer.dwSize := 1024;
buffer.dwFlags := DSBCAPS_CTRLFREQUENCY;
buffer.dwBufferBytes := DSBCAPS_PRIMARYBUFFER;
buffer.dwReserved := 0;
buffer.guid3DAlgorithm := DS3DALG_DEFAULT;
buffer.lpwfxFormat.wFormatTag:=WAVE_FORMAT_PCM;
buffer.lpwfxFormat.nChannels:=2;
buffer.lpwfxFormat.nSamplesPerSec:=(44100 div 100);
buffer.lpwfxFormat.nAvgBytesPerSec:=buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.nBlockAlign:= buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.wBitsPerSample:=buffer.lpwfxFormat.nSamplesPerSec;
buffer.lpwfxFormat.cbSize:=0;


Thanks

Mat in Paris.
Back to top
henkjan
Guest





PostPosted: Fri Apr 27, 2007 2:08 pm    Post subject: RE: Delphi 2006 with DirectSound SDK 9 Reply with quote



look at google for the Cloothie DirectX 9 Header files.. There can also be
found the directx 9 sample codes.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Multimedia All times are GMT
Page 1 of 1

 
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


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.