Jump to content

Sign in to follow this  
Guest harry3

Dev C++ for gauges???

Recommended Posts

Guest harry3

Hi!After a long time not doing anything for flight simulator, I want to make some gauges in C.(I think I've now enough experience in that language to try again)I'm not too bad at XML, but I want to learn programming C gauges finally because of some advantages(e.g. sound)As my favorite compiler is Dev C++, I wanted to ask if it's possible to use this compiler for gauges too?Would be good if it's possible to use this compiler, otherwise I've to use MS Visual C++ 6.0, which I don't like too much.(but wouldn't be a too big problem;-))Regards,Harry

Share this post


Link to post
Share on other sites
Guest adameke777

Regarding Dev C++, after little bit of trial and error, I had luck getting the compiler to produce an operational gauge. However, after switching to Visual C++ 2005 Express, I will probably not be using other compilers for a while now.Adam

Share this post


Link to post
Share on other sites
Guest harry3

What did you do to get Dev C++ running?Another question: Is it a bug of the fssound.dll that the looped sound1 doesn't stop when I call the MFSoundStop() function?if(erg>=29.92) MFSSoundResPlay(sound1, 1);//plays sound1 loopedelse MFSSoundStop(sound1);//should stop itBut the sound keeps playing and playing and playing...!?(FS2002)Regards,Harry

Share this post


Link to post
Share on other sites
Guest adameke777

>What did you do to get Dev C++ running?In Dev C++ IDE: menu Project -> Project Options (Alt+P)General tab: Type: Win32 DLLThat's all I had to do.>Another question: Is it a bug of the fssound.dll that the>looped sound1 doesn't stop when I call the MFSoundStop()>function?>>if(erg>=29.92)> MFSSoundResPlay(sound1, 1);//plays sound1 looped>else > MFSSoundStop(sound1);//should stop it>>But the sound keeps playing and playing and>playing...!?(FS2002)I would start with the simplest thing and check whether the condition (erg >= 29.92) is being fullfilled all the time. That may be causing the problemGLadam

Share this post


Link to post
Share on other sites
Guest harry3

Thanks for the answer.I'll have a look at the Dev C++ compiler another time.The sound now also works:I've put the fssound function calls now into the GAUGE_CALLBACK under PANEL_SERVICE_PRE_UPDATE.And, I've made the sound dependent of a boolean variable and not of a float.Regards,Harry

Share this post


Link to post
Share on other sites
Guest harry3

Dev C++ is now running without any problems for gauge compiling.The only thing which is important is to delete the Version info from the *.rc file. The .rc file must only contain the #include "*.h" and the bitmap resources.What I didn't manage until now is to get the fssound running in Dev C++.But maybe I'll find a way.The only defference in the output file is that the one from Dev C++ is bigger than the one from MSVC.(~800kb compared to ~100kb!?!?!)Regards,Harry

Share this post


Link to post
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.
Note: Your post will require moderator approval before it will be visible.

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.

Sign in to follow this  

×
×
  • Create New...