Jump to content


* - - - - 1 votes

Creating an Exclude Zone


  • Please log in to reply
6 replies to this topic

#1 IBtheSarge

IBtheSarge

    First Class Member

  • Moderator
  • PipPipPipPipPipPipPipPip
  • 10,718 posts
  • Location:Central Florida

Posted 30 March 2006 - 03:25 PM

Those who would like to create exclude zones without the use of 3rd party programs (and the associated learning curve) and without modifying the scenery.cfg file, may find this useful.  WordPad, AFCAD, and the bglcomp_SDK are required.

=====================================================

Step 1:  Create a work directory (or, you can simply use the same directory in which you installed the bglcomp_SDK).  If you decide to use a work directory, move or copy bglcomp.exe and bglcomp.xsd into this directory.

Step 2:  Open Wordpad and create the following lines of code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<FSData version="9.0" xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation="bglcomp.xsd" >
<ExclusionRectangle
      latitudeMinimum="N41 38.3300"
      latitudeMaximum="N41 40.7680"
      longitudeMinimum="W116 45.2300"
      longitudeMaximum="W116 43.9950"
      excludeAllObjects = "FALSE"
      excludeBeaconObjects = "FALSE"
      excludeEffectObjects = "FALSE"
      excludeGenericBuildingObjects = "FALSE"
      excludeLibraryObjects = "FALSE"
      excludeTaxiwaySignObjects = "FALSE"
      excludeTriggerObjects = "FALSE"
      excludeWindsockObjects = "FALSE"/>
</FSData>
Be certain you type the code EXACTLY as it appears above.  One space, one character that is not precise will cause blgcomp to abort the compilation to BGL.  To make this work, all you need are the northern-/western-most latitude/longitude and southern-/eastern-most latitude/longitude of the area containing the objects you wish to exclude.

Step 3:  Open your airport in AFCAD and determine the boundaries of the area you wish to be affected by the exclusion.  (Hint:  I normally just use the "apron route" tool to draw a box around the area.)  Find the lat/lon of the upper-left corner of the box, then find the lat/lon of the lower-right corner of the box, and write them down.

Step 4:  Enter your data into the code you just created.  Change
latitudeMinimum="N41 38.3300"
to the latitude you wrote down for the lower-right corner of the box.  Change
latitudeMaximum="N41 40.7680"
to the latitude you wrote down for the upper-left corner of the box.  Change
longitudeMinimum="W116 45.2300"
to the longitude you wrote down for the upper-left corner of the box.  Change
longitudeMaximum="W116 43.9950"
to the longitude you wrote down for the lower-right corner of the box.

An easy way to remember it is latitude first, longitude second, in the order BOTTOM TOP TOP BOTTOM.  Don't try it with SMALL BIG BIG SMALL as that relationship will change in the southern latitudes and eastern longitudes -- keep it BOTTOM TOP TOP BOTTOM.

Change the BOOLEAN statements
      excludeAllObjects = "FALSE"
      excludeBeaconObjects = "FALSE"
      excludeEffectObjects = "FALSE"
      excludeGenericBuildingObjects = "FALSE"
      excludeLibraryObjects = "FALSE"
      excludeTaxiwaySignObjects = "FALSE"
      excludeTriggerObjects = "FALSE"
      excludeWindsockObjects = "FALSE"/>
as required.  If you want all objects to be excluded, change "FALSE" to "TRUE" in the first statement.  If you only want to remove taxiway signs, leave everything else "FALSE" and change the sixth line to "TRUE".  You may have to play with these lines a bit to ensure what you want excluded actually gets excluded.  For instance, setting excludeAllObjects = "TRUE" does not always remove refueling points.  You must also set excludeTriggerObjects = "TRUE".

You can also have more than one exclude zone.  Simply copy-paste
<ExclusionRectangle
      latitudeMinimum="N41 38.3300"
      latitudeMaximum="N41 40.7680"
      longitudeMinimum="W116 45.2300"
      longitudeMaximum="W116 43.9950"
      excludeAllObjects = "FALSE"
      excludeBeaconObjects = "FALSE"
      excludeEffectObjects = "FALSE"
      excludeGenericBuildingObjects = "FALSE"
      excludeLibraryObjects = "FALSE"
      excludeTaxiwaySignObjects = "FALSE"
      excludeTriggerObjects = "FALSE"
      excludeWindsockObjects = "FALSE"/>
as many times as you need, until you have entered the last area.  Put in the actual lats/lons of each area (BOTTOM TOP TOP BOTTOM, remember?).  Just make sure that </FSData> is the last line.

Step 5:  On Wordpad's top toolbar, select "File" then "Save As" and give the file a unique name.  My method is to use the ICAO of the airport in the filename (i.e. KPSM_Excl).  Change the file extension to .XML and save the file into the same directory you have bglcomp.exe and bglcomp.xsd located.  Now, drag-and-drop the XML file onto the bglcomp.exe icon.  Wait a few seconds, and if you have typed the code in correctly, a BGL with the same name as the XML file will appear (i.e. KPSM_Excl.BGL).  Place this BGL in your airport's Scenery folder.  You're finished.

=====================================================

Word of Caution:  If you are going to provide your creation for others to use, be sure you turn your autogen slider all the way up to 100%.  That's the only way you are going to find exactly what kind of objects are in the area you wish to exclude.  You may find a windsock (which has its own BOOLEAN line) that you hadn't seen before because your slider was too low.  If you only set excludeAllObjects = "TRUE", then another person who installs your design may suddenly be faced with that windsock right in the middle of the expanded ramp you made.

Edited by sarge, 30 March 2006 - 07:23 PM.


#2 Panhead

Panhead

    Airline Transport Pilot

  • Members
  • PipPipPipPipPipPip
  • 2,554 posts
  • Location:Tampa, FL

Posted 31 March 2006 - 12:38 PM

great tut. sarge, i was recently thinking about making my own airport.

#3 IBtheSarge

IBtheSarge

    First Class Member

  • Moderator
  • PipPipPipPipPipPipPipPip
  • 10,718 posts
  • Location:Central Florida

Posted 31 March 2006 - 01:12 PM

cmfs2004, on Mar 31 2006, 01:38 PM, said:

great tut. sarge, i was recently thinking about making my own airport.
Thanks.  One more to go -- placing MDL objects using XML and bglcomp.  It will show how to place them from user-created library object files or ready-made libraries such as EZ-Scenery, Runway 12, SBuilder, etc., without having to learn those programs.  That one should be up sometime this evening (Friday) or tomorrow NLT 1200 local.

#4 mobisone

mobisone

    Commercial Pilot

  • Members
  • PipPipPipPipPip
  • 1,934 posts
  • Location:ALASKA

Posted 08 April 2006 - 10:18 PM

woohoo! there all gone now!

here they were before..

Posted Image


and after!


Posted Image

now i can instal some buildings that will do justice to Dillingham!
maybe photoreal ones lol , i did take pictures of the real buildings.
and i have GMAX!

#5 IBtheSarge

IBtheSarge

    First Class Member

  • Moderator
  • PipPipPipPipPipPipPipPip
  • 10,718 posts
  • Location:Central Florida

Posted 09 April 2006 - 03:49 AM

mobisone, on Apr 8 2006, 11:18 PM, said:

woohoo! there all gone now!
now i can instal some buildings that will do justice to Dillingham!
maybe photoreal ones lol , i did take pictures of the real buildings.
and i have GMAX!
:D   You're welcome   :D

#6 mobisone

mobisone

    Commercial Pilot

  • Members
  • PipPipPipPipPip
  • 1,934 posts
  • Location:ALASKA

Posted 09 April 2006 - 12:19 PM

sarge, on Apr 9 2006, 03:49 AM, said:

mobisone, on Apr 8 2006, 11:18 PM, said:

woohoo! there all gone now!
now i can instal some buildings that will do justice to Dillingham!
maybe photoreal ones lol , i did take pictures of the real buildings.
and i have GMAX!
:D   You're welcome   :D

mobisone, on Apr 8 2006, 11:18 PM, said:

woohoo! there all gone now!
now i can instal some buildings that will do justice to Dillingham!
maybe photoreal ones lol , i did take pictures of the real buildings.

Somtimes i let my pictures speak for me
For those that didn't hear it,
Thank You. :lol:
:)   You're welcome   :lol:

Edited by mobisone, 09 April 2006 - 12:21 PM.


#7 Jon

Jon

    Administrator

  • Admin
  • PipPipPipPipPipPip
  • 3,140 posts
  • Location:South Carolina, USA

Posted 14 April 2006 - 02:44 PM

Moved to Knowledge Base... :D