Hi Don:
I forgot to mention a few things in relation to using X,Y,Z coordinates extracted from an external program source like GoogleEarth ("GE") via a KML file opened in FSX-KML:
GE --> *.KML file --> FSX-KML --> "XML View" Tab --> Copy X,Y,Z coordinate sets into NotePad
...rather than clicking coordinates directly into SBuilder using a "background map image", one can create a *.
BLN format file for SBuilder to "Append".
To do this, paste your X,Y,Z (Lon/Lat/Elevation) coordinates for each vertex into NotePad, and
edit as needed, so your X,Y,Z coordinates for each vertex are on (1) line apiece
NOTE: Each line is a "record"... with vertex X,Y,Z coordinate data as "fields".
Next, "copy" the top-most line (Record) of X,Y,Z coordinates and paste them at the
bottom to become the
last line (Record) in that NotePad file
NOTE: This properly aligns vertices and allows one to "close" a vector shape made of vector coordinate "
points" or "nodes"; if not done, the data will remain an incomplete "triangle" poly and/or poly-line, so a completely "square" poly or poly-line can't be made.
FYI: The FS scenery utility used (ex: SBuilder for FS9) must set the attribute for FS SDK BGLCompiler that makes the data into a FS9 LWM water poly so that the vertices are "joined" into a true
polygon, rather than a FS9 VTP poly-line.
Then count the (current) total number of lines of vertex X,Y,Z coordinates (Records) you have in the Notepad file.
Now put that number for the total current number of lines of vertex X,Y,Z coordinates at the top in the Notepad file
above your existing top line of X,Y,Z coordinates.
That number for the total current number of lines of vertex X,Y,Z coordinates will then become the 'new'
first "Header" line in the file; it
must now be followed by a single comma character ("
,") like this (comments in
RED are for explanatory purposes only... do NOT include them in your NotePad file) :
EXAMPLE *.TXT POLYGON file in NotePad
These are X,Y,Z Coordinates for vertices of a square water poly (CLOCKWISE):
-123.082982475264000,47.526423035940100,190
<- NW [Top Line - is also COPIED to bottom]
-123.082966475264000,47.526423035940100,190
<- NE
-123.082966475264000,47.526407035940100,190
<- SE
-123.082982475264000,47.526407035940100,190
<- SW
-123.082982475264000,47.526423035940100,190
<- NW [vertex overlap "closes" polyline to make it a polygon]
[
EDITED]
NOTE: I believe tabs or spaces can be used as delimiters between X,Y,Z coordinates instead of commas, but the comma and "0" (zero) after the X,Y,Z total line count is required for a "simple format Surfer blanking file" *.BLN file.
Also note that in a "simple format Surfer blanking file" *.BLN file, in addition to the required "Header" with a comma and "0" (zero) after the X,Y,Z total line (Record) count,
commas are used as delimiters between X,Y,Z coordinates (Fields) on the "Vertex" (Record) lines.
There are (5) lines of X,Y,Z coordinates, so one edits the NotePad file to now read:
5,0
<- Numeral for total number of X,Y,Z coordinate lines followed by a comma and a "0" (this is a 'Header' line)
-123.082982475264000,47.526423035940100,190
<- ("Vertex" line #1)
-123.082966475264000,47.526423035940100,190
<- ("Vertex" line #2)
-123.082966475264000,47.526407035940100,190
<- ("Vertex" line #3)
-123.082982475264000,47.526407035940100,190
<- ("Vertex" line #4)
-123.082982475264000,47.526423035940100,190
<- ("Vertex" line #5)
Finally, in NotePad, click File > Save As, and set "Save as type" to "All Files", enter your desired file name (being sure to use a "
BLN" 3-character file extension) and save your file.
The *.BLN file can now be "Appended" to SBuilder for FS9 or SBuilderX for FSX for further processing.
CAVEAT: Be sure to use the latest versions of SBuilder.
In older versions of SBuilder for FS9, to append BLN files, "header" lines were required to be customized by use of a number
other than "0" after the comma to define the intended line width for polylines.
Newer versions of SBuilder for FS9, and SBuilderX now assume BLN "Header" lines will have after the X,Y,Z total line count, a comma and "0" (zero); that terminating "0" is
no longer customized in the BLN file itself, and definition of intended line width for appended polylines is done via a SBuilder pop-up dialog during the append process.
However, note that SBuilder allows definition of the delimiter between X,Y,Z fields in appended BLN files by editing the
SBuilder.ini file located in the main root folder where SBuilder is installed.
NOTE: A comma is the default BLN field delimiter (separator), but one can also substitute the word "tab" for the comma "
," character:
[BLN]
- BLNSeparator=, - This is the separator used between fields in BLN files.
[
END_EDIT]
FYI: If making a shoreline for the above water polygon, the coordinate line (Record)
sequence ('winding' direction) for the poly-line must be
reversed (
BTW: Some FS Scenery utilities (ex: FSX-KML) and GIS applications off a feature that can reverse the entire vertex X,Y,Z coordinate line (Record) sequence / order ...to save one having to manually edit them ! )
EXAMPLE *.TXT POLY-LINE file in NotePad
These are XYZ Coordinates for vertices of a square water poly-line "vector path" (COUNTER-CLOCKWISE):
-123.082982475264000,47.526423035940100,190
<- NW [Top Line - is also COPIED to bottom]
-123.082982475264000,47.526407035940100,190
<- SW
-123.082966475264000,47.526407035940100,190
<- SE
-123.082966475264000,47.526423035940100,190
<- NE
-123.082982475264000,47.526423035940100,190
<- NW [vertex overlap "closes" polyline to make it a polygon]
Remember to click File > Save As, and set "Save as type" to "All Files", enter your desired file name (being sure to use a "
BLN" 3-character file extension) and save your file.
FYI: The FS scenery utility used (ex: SBuilder for FS9) must set the attribute for FS SDK BGLCompiler that makes the data into a FS9 VTP poly-line so that the vertices form a full-length
line, rather than a FS9 LWM water poly.
Hope this helps orient you to the basics of that option in the process !
Oh, and I wanted to be sure you knew the legacy of wonderful AK/PNW SCASM API Macros you made/placed might be ported to FSX via
Arno's ModelConverterX:
http://www.fsdeveloper.com/forum/forumdisplay.php?f=87
Happy Tinkering !
GaryGB