Jump to content
Sign in to follow this  
Guest pscarratt

Moving Map Display

Recommended Posts

Necroed this post to recover all the XML script for everyone's future benefit... Bill+

Steve,This is the code I use. I've added my own L Vars to control what is displayed.
<!-- Draw GPS Map -->		<Macro Name="c">C:fs9gps</Macro>	<Macro Name="g">C:fs9gps</Macro>		<Element Name="MapView Pages">		<Visible>(L:EFIS MODE, number) 2 == (L:EFIS MODE, number) 3 == || </Visible>		<Position X="0" Y="0"/>		<MaskImage Name="PS737EFISMASK.bmp" ImageSizes="400,420"/>		<CustomDraw Name="fs9gps:map" X="400" Y="726" LayerTerrain="Yes" LayerBorders="Yes" LayerFlightPlan="Yes" FlightPlanLineWidth="4" ActiveColorLayerFlightPlan="0x7010B0" PastColorLayerFlightPlan="0xF0F0F0" ColorLayerFlightPlan="0xF0F0F0" Bright="Yes" CenterX="200" CentreY="363">						<Zoom>(L:EFIS MAP RANGE, number) 1852 *</Zoom> <!-- 1852m is 1 nautical mile -->			<Latitude>(A:GPS POSITION LAT, Radians)</Latitude>			<Longitude>(A:GPS POSITION LON, Radians)</Longitude>			<Heading>(A:GPS GROUND TRUE TRACK, Radians)</Heading>						<DetailLayerTerrain>1</DetailLayerTerrain>			<LayerAirports>(L:EFIS MAP SHOW APT, bool)</LayerAirports>			<LayerVORs>(L:EFIS MAP SHOW VOR, bool)</LayerVORs>			<LayerILSs>(L:EFIS MAP SHOW ILS, bool)</LayerILSs>			<LayerNDBs>(L:EFIS MAP SHOW NBD, bool)</LayerNDBs>			<ObjectDetailLayerAirports>0 0 0 0 0 0 0x5 0x5 0x7 0x7 0x1F 0x1F 0x1F 0x1F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 24 (@g:map_ZoomStep) case</ObjectDetailLayerAirports>			<TextDetailLayerAirports>(L:EFIS MAP SHOW APT, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerAirports>			<TextDetailLayerVORs>(L:EFIS MAP SHOW VOR, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerVORs>			<TextDetailLayerILSs>(L:EFIS MAP SHOW ILS, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerILSs>			<TextDetailLayerNDBs>(L:EFIS MAP SHOW NBD, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerNDBs>			<ObjectDetailLayerFlightPlan>0xE 0xF (@c:FlightPlanIsActiveApproach) ?</ObjectDetailLayerFlightPlan>			<TrackUp>1</TrackUp>				</CustomDraw>					</Element>


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Fr. Bill,It is for everyone, only the script is too large and imperfect to show here.I started this some days ago, after a request of Ed(etroit)Send already copy's to him and Roman(spokes2112) to have a look at it.If one is interested, i send an update (busy with improvements, altough little time)When anyone makes a definite gauge, he can upload it for the community.Technically:It uses msgps codes, but not the customdraw gps:map.Jan

Share this post


Link to post
Share on other sites

I had a little fiddle this morning Jan (this was with the first xml code you sent me) ....as you say there is a fair bit of work to be done to optimise/perfect it. But I certainly doff my cap to you sir. :( While I am here... I sure I remember there is a way to smooth a vector drawn circle?.ndbit.jpg

Share this post


Link to post
Share on other sites

Ed,Just use:<Element><Position X="-5" Y="-5"/><Circle Radius="5" LineWidth="1" Color="#ff0000" Bright="Yes"/><Clip Left="312" Right="712" Top="205" Bottom="584"/></Element>instead of the polyline.Btw. very, very nice 737 panel!!!Finally you can see the light reflections.Jan

Share this post


Link to post
Share on other sites

Thankyou Jan.I would like to add to that (something you might like to try with your HUD). If you add <Rotate> to your vector circle it will smooth it. :( eg<Position X="9" Y="9"/><Circle Radius="9" Linewidth="2" Color="#00FF00" Bright="Yes"/><Rotate><Value>(L:rot,degress)</Value></Rotate>nd.jpg

Share this post


Link to post
Share on other sites

Good idea Ed.Btw the vortac symbol needs to be flipped vertically.With NearestVorCurrentType you can select the correct type of the vor symbol.Yeah, more code, but fun.Jan

Share this post


Link to post
Share on other sites
Thankyou Jan.I would like to add to that (something you might like to try with your HUD). If you add <Rotate> to your vector circle it will smooth it. :( eg<Position X="9" Y="9"/><Circle Radius="9" Linewidth="2" Color="#00FF00" Bright="Yes"/><Rotate><Value>(L:rot,degress)</Value></Rotate>
Wow, really nice work there. I'm using (probably) a similar technique as yours for the Aerosoft Airbus. None of the CustomDraw navaid icons look anything like the real A32X's, so it all had to be done by scratch. I'm not ashamed to say that it took me awhile to find the overall best method (best, for the particular goals, that is). If your method is very tedious, with tons of repeating code, then we're probably doing just about the same thing. ;-)Again, that ND you show looks very, very nice. I hope that custom navaid icons, vs. always the same old CustomDraw ones, will start to become more of the norm, because custom looks so much more authentic. And of course *variety* is just inherently nice....Scott

Share this post


Link to post
Share on other sites
Good idea Ed.Btw the vortac symbol needs to be flipped vertically.With NearestVorCurrentType you can select the correct type of the vor symbol.Yeah, more code, but fun.Jan
Danke ... also the Vortac symbol needs to change colour pending on whether it's frequency has been selected in Nav1/Nav2 radios no? ..... this is fun! :(

Share this post


Link to post
Share on other sites

Hi,I have all the types now(1-5).Trying to find parameters for color change of tuned vor , blue-->green, but all change color......Jan

Share this post


Link to post
Share on other sites
Hi,I have all the types now(1-5).Trying to find parameters for color change of tuned vor , blue-->green, but all change color......Jan
Well remember if when using nav autotune the radios are tuned into the nearest VORs you only have to have the colour change for for the two nearest VOR'sSo if nav1 tunes to the nearest and nav 2 tunes to the next nearest vor problem solved using NAV1 HAS NAV, bool and NAV2 HAS NAV, bool.Works a treat! :(

Share this post


Link to post
Share on other sites

Ed,I used NAV1 HAS NAV, bool etc, but that gives me a crash to desktop!Gives negative numbers and has to do which what vor you are using for vor navigation??What codes are you using?Jan

Share this post


Link to post
Share on other sites
Ed,I used NAV1 HAS NAV, bool etc, but that gives me a crash to desktop!Gives negative numbers and has to do which what vor you are using for vor navigation??What codes are you using?Jan
Hello Jan,The only line I changed in your code is for the nearest VOR. Color="%('#07E611' '#00ABEF' (A:NAV1 HAS NAV, bool) ?)"and obviously Color="%('#07E611' '#00ABEF' (A:NAV2 HAS NAV, bool) ?)" for the next nearest.You have mail btw.

Share this post


Link to post
Share on other sites

May I say, awesome work folks. Finding a way to incorporate custom symbols and background transparency in a cgps based gauge is genius. The transparent background alone has eluded me for some time. I am anxiously awaiting the public release!...Don

Share this post


Link to post
Share on other sites

Necroed this post to recover the lost script...

Steve,This is the code I use. I've added my own L Vars to control what is displayed.
<!-- Draw GPS Map -->		<Macro Name="c">C:fs9gps</Macro>	<Macro Name="g">C:fs9gps</Macro>		<Element Name="MapView Pages">		<Visible>(L:EFIS MODE, number) 2 == (L:EFIS MODE, number) 3 == || </Visible>		<Position X="0" Y="0"/>		<MaskImage Name="PS737EFISMASK.bmp" ImageSizes="400,420"/>		<CustomDraw Name="fs9gps:map" X="400" Y="726" LayerTerrain="Yes" LayerBorders="Yes" LayerFlightPlan="Yes" FlightPlanLineWidth="4" ActiveColorLayerFlightPlan="0x7010B0" PastColorLayerFlightPlan="0xF0F0F0" ColorLayerFlightPlan="0xF0F0F0" Bright="Yes" CenterX="200" CentreY="363">						<Zoom>(L:EFIS MAP RANGE, number) 1852 *</Zoom> <!-- 1852m is 1 nautical mile -->			<Latitude>(A:GPS POSITION LAT, Radians)</Latitude>			<Longitude>(A:GPS POSITION LON, Radians)</Longitude>			<Heading>(A:GPS GROUND TRUE TRACK, Radians)</Heading>						<DetailLayerTerrain>1</DetailLayerTerrain>			<LayerAirports>(L:EFIS MAP SHOW APT, bool)</LayerAirports>			<LayerVORs>(L:EFIS MAP SHOW VOR, bool)</LayerVORs>			<LayerILSs>(L:EFIS MAP SHOW ILS, bool)</LayerILSs>			<LayerNDBs>(L:EFIS MAP SHOW NBD, bool)</LayerNDBs>			<ObjectDetailLayerAirports>0 0 0 0 0 0 0x5 0x5 0x7 0x7 0x1F 0x1F 0x1F 0x1F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 0x4F 24 (@g:map_ZoomStep) case</ObjectDetailLayerAirports>			<TextDetailLayerAirports>(L:EFIS MAP SHOW APT, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerAirports>			<TextDetailLayerVORs>(L:EFIS MAP SHOW VOR, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerVORs>			<TextDetailLayerILSs>(L:EFIS MAP SHOW ILS, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerILSs>			<TextDetailLayerNDBs>(L:EFIS MAP SHOW NBD, bool) (L:EFIS MAP RANGE, number) 40 < ==</TextDetailLayerNDBs>			<ObjectDetailLayerFlightPlan>0xE 0xF (@c:FlightPlanIsActiveApproach) ?</ObjectDetailLayerFlightPlan>			<TrackUp>1</TrackUp>				</CustomDraw>					</Element>

I've also attached the code as text because of the formatting issues on the forum!Cheers,http://forums.avsim.net/user_files/82367.txt


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

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  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...