June 20, 201213 yr Commercial Member I have downloaded the Dai Griffiths C gauge tutorial rev 31 and tried to load the directsound example into MS VC++ 2010 Express. I've also downloaded the DirectX SDK and pretty sure I have linked the files there correctly with MS VC++. However, no matter how many times I try I just can't seem to get the directsound example to compile without some sort of error message. The closest I've managed is these errors: 1>...\subgauge\dfdsnd.c(298): error C2664: 'LoadWaveFile' : cannot convert parameter 2 from 'char [256]' to 'TCHAR *' 1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast 1>...\subgauge\dfdsnd.c(317): error C2664: 'LoadWaveFile' : cannot convert parameter 2 from 'char [256]' to 'TCHAR *' 1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast I've been at this for days now and despite downloading dozens of directsound example codes (that are not FSX related and yes I have tried the Directx SDK examples which again won't compile in VC++ 2010) I can't get anything that will even compile let alone actually make a sound. The best I've managed is an Xaudio2 example which I have managed to compile and get playing a sound, however, when trying to implement this into an FSX gauge it will cause FSX to crash when it comes time to play sound. I am assuming that Xaudio2 won't work within FSX. If anyone can confirm that you can only use directsound with FSX that would help as it would mean I could stop wasting time trying to get xaudio2 to work in an FSX gauge. I've also tried the premade gauge example dfdsnd.gau and that doesn't even work in FSX. PS I am not interested in using Doug Dawson's DSD gauge, I would like to make my own. Any help would be much appreciated. www.antsairplanes.com
June 21, 201213 yr Author Commercial Member After reading this post I think I'm getting closer. http://forum.avsim.net/topic/323634-help-for-adding-sound-c-gauges/ Changing from Unicode to multibyte gets rid of error messages but gives me some new ones. They seem to be the same ones as in post 8 of the above link. Dai explains that this suggest the link to sound.cpp is missing. What he doesn't explain is how to fix that. If anyone could post a pic or description of what files need to be included in the "Solution Explorer" and which need to be "Excluded from Build" that would be a big help as I can't make heads or tails of all these files and what calls what and what needs to be included and what doesn't. www.antsairplanes.com
Create an account or sign in to comment