Sign in to follow this  
Guest Wintifax

DLL Modules and GPS

Recommended Posts

Hello there,I've been posting an idea that I want to implement for FS9; See thread "dll modules adding to gameplay" in the general forum.I've started implementing the module and I get along quite well, there's just this one thing that does not want to show it's mystery to me: How can I access the more elaborate GPS data, like a list of nearest airports, etc. The panel SDK includes the gpsinfo thingies, but those are old (fs2k/fs2002) and only give access to basic GPS info, especially waypoint info, etc.I've been disassembling the gps.dll that comes with FS9 and I can see that there's a lot of strings in there that have exactly those names (NearestAirport* and a whole lot of others). So I'm absolutely sure that it's possible to access this data (how'd the atc.dll do it?), and I think that it works via some named variables. Well, I've been fiddling with those, but had no success - I think the named variables would have some combined name, like "FS9GPS NearestAirportItemsMax", etc, but so far I wasn't able to get any useful data.Does anyone know what those variables are named like?Is this really the way to access them? Or does the gps.dll reflect a c++ class that needs to be mapped into an interface (like the traffic info in the panels sdk)? If so, is there a way to find out what that interface looks like, without getting the necessary info from MS?Is there any developer support by MS for FS?Thanks for reading me and greetings,Winti

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

I've solved the problem, I can now access nearest airport data and just about everything the GPS can display (that includes the built in apt database, but I didn't test that yet).I'll soon start putting together a c/c++ header file so everyone can use that in a simple way. Greetings,Winti

Share this post


Link to post
Share on other sites

Winti,Have you managed to acccess(find) the sections pertaining to the background color or draw color of the terrain (other than blue) of the GPS? A number of us have been looking for a way to remove it (make it transparent), so that the map data and symbology can be used for applications such as a HUD. We have pretty much mastered all variable GPS functions available to XML programmers, but certain colors as mentioend above are hard-coded into the DLL.Thanks--Jon

Share this post


Link to post
Share on other sites

No, gps.dll for sure doesn't contain that information and I'm not yet sure where the code for drawing the gps-terrain map is in; I suspect it's symmap.dll.Although, I'm not quite sure why you'd want to make it transparent... You mean, while flying with the GPS-Terrain turned on and still have a HUD display without terrain, but just the symbols?My approach would be different: With the gps variables I have available now (They should be no problem to access within an XML Gauge), I'd rather paint a new map by myself. Everything you need is in those variables - You could even customize the symbols, etc. I don't think it would need too much cpu time either, as long as the maximum distances are held small enough. I know for sure that whatever draws the gps map uses exactly those variables, too.Greetings,Winti

Share this post


Link to post
Share on other sites

Hi,Trying to do that, but things, as for example "The flightplan and symbols", don't show up on the handmade map.Jan"Beatus Ille Procul Negotiis"

Share this post


Link to post
Share on other sites

>Although, I'm not quite sure why you'd want to make it>transparent... You mean, while flying with the GPS-Terrain>turned on and still have a HUD display without terrain, but>just the symbols?I don't want to make the terrain color transparent, I'm more interested in just changing the color from blue to green, but the map color is not accessible from XML. What I need transparent is the black background. There are many reasons why it would be beneficial to remove the background "black" color. My displays have a slight green hue to them when illuminated at night, and a secularity during the day, which the GPS covers up with its black background.Of course I've ripped every inch of the GPS apart in XML and put it back together again trying to find the solution. There is no way to change those colors using the known XML parameters, so it must be hardwired in one of the DLLs.

Share this post


Link to post
Share on other sites

The Flightplan and Symbols? Not sure what you mean by that, but the flightplan can easily be drawn by a handmade gauge... the Waypoints are all available, with their positions, distances, etc. If you mean symbols like navigational spots, they should be available via the nearest airspace query, of course that just tells the type, not the symbol itself... but it shouldnt be a problem paint the according symbol then. I'll probably have to look deeper into this to really understand your problem...Winti

Share this post


Link to post
Share on other sites

Following the discussion with great interest,If I would like to show all airports with a custom ie handdrawn airport symbol could that be accomplished in xml ?BrgdsEugen

Share this post


Link to post
Share on other sites

I'm not sure about xml; it would probably include a lot of bitmap moving and rotating in xml... it surely can be done in a C gauge, there you can draw lines and circles and so on without great effort.Greetings,Winti

Share this post


Link to post
Share on other sites

>I'll soon start putting together a c/c++ header file so>everyone can use that in a simple way. Very interested in that one, really looking forward to it. Give us a hint when you are done. :)BestEtienne :-wave

Share this post


Link to post
Share on other sites

I'm just starting out on getting my head around the SDK to create my own gauges and something has been bothering me from day one.This may be a naive question but if Microsoft has made efforts to allow third-parties to create add-ons for FS2004 by releasing this SDK, how come there is still so much useful functionality hidden away in undocumented dll files? I've seen postings in other threads in here on the interesting topic of having a moving map in a .gau C/C++ implemented gauge (it seems relatively easy in an XML gauge like the default GPS). Or how about having the FS2004 flightplanner style map shown in a .gau ND types gauge? That way you could use the elevation type terrain colouring for a psuedo TAWS.How come this kind of functionaility is so very well hidden and not described in the SDK? Is it simply a case of time and effort on the FS2004 SDK authors part that they have't got around to telling us all how to talk to the various dll files that provide so much of the Flight Simulator engine information?It just seems all very inconsistent to me at the moment. Compared to other software titles that allow users to create content using SDK material (Unreal, Half Life etc), Flight Simulator's SDK appears ludicrously limited in scope. Will this ever change for FS2004 or do we all just have to hope things improve in the next Flight Sim release :)- DE

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this