Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

itrafficinfo examples needed

Featured Replies

Yup, AA is IMHO badly implemented and a major nuisance in the FS graphics engine. I will carry on experimenting and report my results.Thanks /Thomas

  • Replies 47
  • Views 5.2k
  • Created
  • Last Reply

Top Posters In This Topic

OK, a new switch AntiAlias="0"/"1" for the CustomDraw statement.

Works perfectly, thanks! One question: I want to control TCAS color with the macro I use for the other CRT elements (see screenshot). Like this:%('0x5fffaa' '0x7ac688' '0x7ab678' 3 (L:SColor,enum) case)...StandardColour="@TCASColors" ... It does not work though. Why?

The problem is twofold, first the ustomdraw doesn't seem to do any calculation in the attributes unlike other elements, and secondly all ...Colours in my Customdraw only accept integers (too lazy to treat them as string and then converting to integer).So what happens: a macro is nothing else then a textual replacement, it doesn't calculate anything, so with StandardColour="@TCASColors" you copy te Macro body to the CustomDraw attribute "StandardColour" which can't interpret it. Solution? Use "StandardColour" as element, like @TCASColorsCore(A:GPS GROUND TRUE HEADING, degrees)but then you can't use the original macro, because it uses syntax ("%(...)"), but you need syntax for elements of CostumDraw. So with redefined macros it should work:'0x5fffaa''0x7ac688' '0x7ab678' 3 (L:SColor,enum) case%(@TCASColorsCore)

Works perfectly, thanks!The radar I am trying to build with your help has two modes btw, VERT/HOR. HORizontal mode is like the present solution, i.e. the CRT y axis shows distance to the echoes. In VERTical mode they are instead shown with vertical separation, i.e. the y axis shows relative altitude (above/below the horizon). Shouldn't be too difficult to implement I think.(?)The aircraft in question is the SAAB J35J Draken, which is a freeware release. 100% XML except for two gauges by Doug Dawson that he graciously permitted me to include in the distribution. I would be very happy if you permit me to also include your dll in the package (with proper credits of course). Thanks and best regards /Thomas

My coding is a bit different to your purposes. I draw each aircraft "dot" (a ring with a short line) relatively to the aicraft due north and then rotate the screen by the heading (OK I rotate the coordinate system BEFORE I draw actually), and you need for a typical fighter radar something with with a forward looking radar, not all round. You can eather use a different coordinate axis, not in the center, or calculate the relative view angles and don't rotate the screen. For the vertical mode you'll need that anyway.

Yes, I see what you mean. I analyzed your code and found the relevant parts, I think I have the hang of it now. I will make the changes I need and recompile it, see what happens. Very educating for me if nothing else. Will post the results here. Cheers /Thomas

Hi,I had very severe program startup problems using the trafficradarxml.dllIn what folder do you have to put it, root or modules?Jan"Beatus ille qui procul negotiis..."

Jan

 

 

 

"Beatus ille qui procul negotiis..."

The Modules folder!

ThanksJan"Beatus ille qui procul negotiis..."

Jan

 

 

 

"Beatus ille qui procul negotiis..."

Hm, did I forget to say that I compiled with VC6.0 and linked "gdiplus.lib" and "user32.lib"? Just before questions come up.

Documentation, and the lack thereof, is the reason while all of this SDK-type stuff is such a black art and nightmare to wade through.Of course we have the helpful folk on here who shine beams of light into the darkness. However, the sacrifice of good documentation, which is almost as much work as the original technology artifact itself, creates as many problems as it avoids.Now, can I fault a volunteer, such as Arne, who is has done more than his share to help his fellow developers along? No way. Can I fault Microsoft for not making some of this clearer and easier to deal with? Probably not. However, the song remains the same such that add-on development in the FS series is arcane and obfuscated with kluges which are not accompanied by good explanation.What we need is a clone who can do your documenting while you progress with the hard stuff. Pair programming maybe?:-)

Jeff Bea

I am an avid globetrotter with my trusty Lufthansa B777F, Polar Air Cargo B744F, and Atlas Air B748F.

Just commenting the tricky parts of the code usually helps a lot. In this particular case, though, I found Arne's code quite easy to understand. I managed to make my changes and recompile the gauge in minutes, no problem. And I am a real amateur in this area, just blundering about most of the time!Cooperating on a project in the way you suggest is usually a good idea. But to write good documentation for source code you need to be very much "inside" the process, not so easy considering that most of us are hobbyists, dispersed around the globe. I know it can be done though, I spent 10 years doing exactly that as a technical documentation consultant. But I sometimes wondered why the software guys I interviewed for hours and hours didn't just use that time to write the documentation themselves. But then I would be unemployed of course. ;o) Just my ten cents, and slightly off-topic as usual./Thomas

Hello Arne,As I just come back from vacations, I'm trying to download the file you have so kindly shared, but they are not available any more. Can you please share them again?Thanks !!Eric

  • Moderator

>Hello Arne,>>As I just come back from vacations, I'm trying to download the>file you have so kindly shared, but they are not available any>more. Can you please share them again?I sent them to you via email, Eric. Enjoy!

Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.