Am 29.10.2013 15:00, schrieb Benjamin Thaut:
Am 29.10.2013 14:45, schrieb evilrat:
On Tuesday, 29 October 2013 at 13:35:11 UTC, Benjamin Thaut wrote:
I already found the first problem with your library.
Your directx modules have module declarations in the form of:
module directx.xaudio2;
but they are directly within the src directory.
You should create a subfolder called "directx" and place all your
modules in there so it is actually consistent with the module
declarations.
yep, i know, thats just because it was a bit messy and i cleaned without
test compile :(
btw, i think the real problem with xaudio2 is that it is part of
windows, so on my machine (win 7 x64) i can't link directly(and in C++
it is actually loaded dynamically). for windows 8 there is a .lib file,
but i don't have access to it now.
Well I just managed to finally compile your example. And it does not
crash for me. But it doesn't play a sound either.
I also found that for all pp members which take pointers to COM
interfaces. For example the "CreateMasteringVoice"
"IXAudio2MasteringVoice** ppMasteringVoice" member. In D interfaces are
already reference types. So it should read "IXAudio2MasteringVoice*
ppMasteringVoice". Then you can also avoid the ugly casting you do in
your examples. When fixing this it still doesn't work however.
As I'm not familiar with xaudio2 I will not be able to help you unless
you present a example which actually crashes. I don't think this is a
COM issue. Does a C++ program which does the same work?
Kind Regards
Benjamin Thaut
--
Kind Regards
Benjamin Thaut