The website and forum will be intermittently unavailable while we're making some security updates.
File uploads to the download hangar are also disabled until further notice.

Creating/Modifying the airport background with SBuilder

This is a collection of tutorials and discussions on the use of SBuilder and all of its various functions.
Locked
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Creating/Modifying the airport background with SBuilder

Post by MIKE JG »

This short tutorial will cover how to create or modify the airport grass background for a given location.

If you don't have SBuilder installed, please visit this thread to learn where to obtain SBuilder for free and how to get it setup as there are additional programs you will need to install to get it working properly:

http://www.militaryaiworks.com/newforum ... =33&t=7672

Most airfields in real life have all the trees and obstacles that sit near the runways cleared and the terrain flattened for safety purposes. This leaves a large cutout grassy area (unless in a desert environment) that gives a very distinctive look to the airfield complex. Often the stock FS2004 airports or airbases have a very quickly drawn background that is not at all accurate to the real life airfield. Additionally when we choose to modify the afcad for a given airfield to make it match the real world, often the new afcad parts will not fit completely inside the boundaries of the stock airport background.

This is a problem for several reasons. For one, visually it looks odd and out of place for a given ramp area that now, does not sit inside this grassy boundary. Secondly one important function of the airport background is to exclude all autogen inside its boundaries. When we end up drawing a ramp or taxiway outside the boundaries of the default background, we lose that automatic exclusion of the autogen and often times find trees, shrubs and other autogen objects popping up through the bottom of our ramps and taxiways. While that can be dealt with using a separate exclude file, sometimes the autogen is stubborn and will not go away. So using a regular airport background polygon is a much easier and more reliable way to get rid of the unwanted autogen objects. This also saves you from having to make an extra exclude file to take care of it.

In this little tutorial, we will look at Randolf AFB in Texas and get rid of its original airport background and replace it with a new one that we create using a different grass texture than that of the original. We will also add a second polygon to place the golf course that sits between the two runways sounth of the ramp complex.

So let's get started:
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

First let's take a look at the default KRND and its airfield background. In this example, I am using the KRND AFCAD file from the MAIW T-37 Tweets package from several years ago. If you do not have this AFCAD installed, the default one will do just fine.

This is an overhead picture of KRND as it is in its default state (with the exception of the MAIW AFCAD). In this example, this particular airfield background completely contains the AFCAD file and doesn't have to be altered to function correctly and appear normal from a visual standpoint. So we don't have to alter this background but for a better visual appearance, we will do so.

Image

To get started, leave FS2004 running and open, start SBuilder and click on the "NEW" button at the top left. You should get a screen that looks like this:

Image

Before you start any SB project, you need to define a couple items to orient SB to the nature of your project and location. If you click on the "Folders" tab in this pop up menu, this is where you can define the location that you want your SB output BGL (scenery) files to be placed when they are compiled. In this example, I have changed the SB default location for my main BGL files to FS9/Addon Scenery/Scenery. This will automatically place my new scenery files into a location that will allow me to start FS9 right away and check my work without having to find the file and move it to an appropriate folder.

There are times when you will want to have the file output to maybe a custom scenery folder, the desktop or some other locations for a variety of reasons. The second selection is the output location for you class and photo scenery which often needs to be in a separate folder. For this exercise, we do not need to alter that and so we will move on to the next tab.

Image

The "Class Scenery" tab defines the center of your project in lat/lon coordinates. This is why we have FS2004 up and running so we can copy the coordinates from FS2004 to SB. If you don't have the coordinates showing already, in FS2004, use Shift+Z to display them in the upper left corner. Then simply copy them to the lat and lon boxes in the SB Project Properties window. Remember East longitude needs a minus (-) sign in front of it and South latitude also needs a minus (-) sign in front of it.

Image

The rest of the tabs can be skipped for this exercise. Select "OK" and you should now have an all white screen that looks like this:

Image

Notice I still have FS2004 running in the background.

Next I want to add a grid system to the SB screen to simply give me some depth/altitude reference for working on my project. To do this, you can select "View" from the main menu, select "Display Grid" and then "GridLOD 13 F3" from the drop down menu. You can also just hit the F3 key. This will now place a grid system on your screen to give you a better reference to work from.

Image

This should give you a nice red grid system. However this is still meaningless until we do one more thing: From the main menu again, select "View" and "Show Aircraft". This is what you should see:

Image

The little red cross represents where your aircraft is inside FS2004. When using SBuilder and FS2004 at the same time, I recommend using either a very simple aircraft or even Traffic View Board as your user aircraft. This will make your life much easier.

Now we are going to make a single polygon to get rid of the default airport background polygon. To do this, we need to move our aircraft to a starting location from which to draw our polygon. In this exercise, I have moved my "aircraft" (Traffic View Board) by using the slew (Y key) command to the southwest corner of the airfield. Once I get my reference point (aircraft) into a starting location, I can now go about drawing my exclusion polygon. Polygons drawn with SBuilder can be of several different types. For this exercise, we are going to use two types, the exclusion and VTP polygon.

Use your mouse to move the cursor back into SBuilder and click on the "Poly" button at the top. Since we have "View Aircraft" selected, the center point in the SB screen will always be the current location of our FS2004 aircraft in game. Knowing that, we can use the red cross hair as our reference point from which to start drawing our polygon. With the "Poly" mode selected, left click to begin drawing the polygon. BEFORE you make another mouse click, move your cursor back over your FS2004 screen and make that active again. Now move your aircraft inside FS2004 to the next location that you want to define for your polygon. In this example, I have moved my aircraft to the north end of runway 32L to the corner where I want the airfield background to be. Make sure not to let your aircraft drift in slew mode while you are trying to work inside of SB. With your aircraft stopped at your next point in the polygon, move your mouse cursor back over SB, you will see that you now have a straight line connected to your original point that you left click on. Again using the cross hairs as your reference, move the polygon point over top of the cross hairs and left click again. It should look similar to this (note it does not show well on the screen capture).

Image
Image

The next steps are to continue to slew around your airport, stopping at the locations that you want to define a point of your polygon at, left clicking to set each point, slewing to the next location and repeating. Remember you can move freely back and forth between SB and FS2004 to make this happen. SB will always close the polygon back to your original point after you've added at least 2 new points. Don't worry about this for now. When you have finished drawing your polygon, simply right click to close it out and SB will make the final connection back to the original point. When you are finished, you should have a solid yellow polygon that looks something like this:

Image

At this point we have a basic polygon. Now we have to define what type of polygon we want it to be. In this case, since we want to use it to exclude the default background, we need to make it into and exclusion polygon. To do that, move your mouse in SB to one of the edges of your yellow polygon. With the mouse cursor hovering over the edge, right click and it will bring up a pop up menu that should look like this:

Image

In this little box, you can see what number polygon this is, you can choose to delete it, but for our exercise, choose "properties".

When you do this, the following pop up menu will appear:

Image
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

The next step is to use this pop up menu to define you polygon type. Note all the different info in this little box. In here you can name the polygon if you wish, you can define its type and you can change the drawing order of the polyon in case you have it stacked on top of or below a different polygon. Note in the Polygon Type menu, that the "None" button is currently selected. That is why you have a yellow polygon for now. All undefined polygons will be yellow. When we assign a type to it, its color will then change to let you know that you've defined this particular polygon. This comes in handy when you have multiple polygons as part of a larger SB project.

Let's go ahead and define the type and see what happens next. There are actually two ways to define the poly, you can simply select the little button for the type "Excl." in this case or actually select the "Exclude" tab at the top.

Image

When you do either one of those actions, a new screen will appear:

Image

Notice the Exclude tab at the top is now highlighted. This new screen is where we will tell SB which parts of the scenery that we want to exclude. To do this, select the "Add Layer" button and another pop up menu will appear:

Image

The text in this menu instructs you how to exclude certain layers of the scenery.

Side Note*** All scenery in FS2004 exists in a layered system to assure that different scenery parts are rendered correctly. The very first layer will be the terrain mesh itself, then the ground textures are drawn on top of that. If you read the text carefully, you can see which scenery parts are in which layers, starting with rivers, streams and utility lines at layer 4 and so on. Knowing which layers the scenery bits and pieces sit in, we can then choose which of these layers and therefore scenery parts that we want this exclusion polygon to get rid of.

In our case, we want to exclude the airport background which you can see from the text, sits in layer 007. So to exclude the background simply place your cursor inside the box and place a number 7 in that spot.

Image

When you enter a #7, the extra menu will go away and you will see "Layer 007" now inside your Exclude properties box. Select OK and you will now see that your polygon has switched from yellow to black.

Image

Black is the default color for any polygon that has been defined as an exclusion polygon.

Now we need to compile this polygon into a usable scenery file. To do that, make sure to select "Point" from the button menu at the top of the SB screen, then from the small menu, click on "Select" and "Select All" from the drop down menu. This will automatically select all SB parts for compilation using BGLComp. For this exercise, you could just choose "All Polygons" if you wish since we are only dealing with polygons for now. If you use "Select All" you will never miss a part of your project.

Image

Now go to the far right of the top button menu and select "BGL". That will bring up the compilation menu:

Image

Make sure that "VTP Excludes" is checked, it should already be but if not, check it. Now you have two options. You can have SB compile the file into a FS2004 scenery file and do nothing, or you can have SB compile the file and start FS2004 as soon as it finishes allowing you to check your work right away.

I want to check my work right away so I will check both boxes on the right part of the menu, checking both "start FS9" and "Compile files to BGL folders".

Doing this will send the SB file to BGLComp (which is why you had to define the path to BGLComp the first time you started SB) to be compiled into a scenery file and once that finishes, start FS9. As BGLComp is working, you will see some extra screens in the upper left hand corner of your screen which is normal.

So let's check our work. I select KRND and this is what I see from the overhead view:

Image

Notice the old background is now gone. You will also notice if you go back to the ground view that you now have autogen all over the base. We will fix that next.
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

The next step is to leave FS2004 up and go back into SB to draw a new polygon. This one will be the new background.

To do this, simply repeat the steps of drawing a polyon that we just completed. Remember to slew you aircraft to a start point and carefully move around the base, stopping and adding points at each spot you want to define a point for your new background polygon.

When you are all finished, if you are using KRND, you might have a new polygon that looks something like this:

Image

Notice how in the upper right of my new undefined polygon that it looks like I missed a point. This is easily corrected. Make sure that you are still in "Poly" mode from the button menu, then move your mouse cursor over one edge of your new polyon, hovering it directly above the edge. Make sure to left click on the edge to highlight all the points of this polygon. If you don't make sure you are selecting this polygon, you may accidentally add a new point to the other polygon. With the polygon points highlighted (all points are green instead of red), hold down the "I" key as you hover the mouse pointer over the edge and then left click. This will add a new polygon point in the location of your mouse cursor. Now you can simply left click on this point and drag it with the mouse to any location you need.

Image

Notice my highlighted point has been dragged to a location that corrects the shape of this new polygon.

Now just like before, I need to define this new polygon. This time we are going to make this one the new background. Again, to bring up the polygon's properties box, make sure this polygon is the selected one (the points will all be showing in red or green), hover the mouse cursor over one of the edges of this polygon and right click. This brings up the small box and again select "properties". This time when the properties menu comes up, select the "VTP2" button or tab. VTP2 is the type you will need for all backgrounds. Doing so brings up the VTP2 menu which looks like this:

Image

To add a specific texture to our new polygon we can select from one of three texture sets. For this exercise, we are only going to use "Classes" and not worry about the other two types which we will cover in a later tutorial. Before you do that, put your cursor inside the VTP Layer box and enter "20". This tells SB which scenery layer you want this polygon to exist in. You could put the new textured polygon into a lower layer, but doing so risks placing the new polygon below another scenery element. We want to make sure it's above everything else around it except for the AFCAD file. So if we use layer 20, we know it will be well above any other default scenery element.

Next click the "Classes" button and a second menu will appear:

Image

This is the Land Classes selection menu where we pick out which ground texture we want to use for the background. Any ground texture is technically a type of land class but the backgrounds are not typically what we would consider a type of land class. However they draw their textures from the same texture set used by land class so that is why they are part of this menu. The advantage of using a land class texture for the background is twofold. For one, the textures will be seasonal in those areas where there are seasons. So you don't have to worry about using the correct seasonal textures for your background, that will automatically be taken care of by SB. The second advantage is that the land class textures are also regional to the part of the world that they are in. So if you pick one texture for North America, it may appear differently in Europe than in N. America even though in the selection menu, it is all the same name.

So with this menu up, we can now scroll down through all the different choices of textures. Note the bitmap images are from the DEFAULT FS2004 texture set. If you use different textures from DEFAULT, yours may not look the same in game. Just be aware of that. If you are really energetic, you could actually go into your SBuilder folder and change out the images with ones from your texture set, but that would be a lot of work.

Generally speaking, if the airfield is in a part of the world that is not a desert type climate, you can use one of three textures. They are "095 Y Grasslands", "096 Y Grasslands", and "097 Y Grasslands". You are of course welcome to experiment with the other textures to see what they look like but anything other than these three may give less than desirable results. Something to note here it that some of the textures have a "Y" in their name and others have a "N". This denotes whether or not the texture excludes autogen automatically or not. When I said earlier that the backgrounds automatically exclude autogen, that's not entirely true. It's really only true if you select a textures for your polygon that has a "Y" in it meaning it will exclude the autogen. Again this is something you can experiment with, but generally speaking, since we almost always use one of these three grass textures, the background will exclude the autogen. Don't ask me what happens if you layer a "Y" texture over top of an "N" texture. I don't know that I've ever tried that, one of you will have to let me know.

Note that when we select one of these three grass textures, there is no image associated with it. The grass textures vary a bit from one part of the world to the next so I'm not sure you could preview just one of the grass textures. It wouldn't know which one to show because it wouldn't know the part of the world it was being used in.

So scroll down and select one of these three grass textures, I've chosen "097 Y Grasslands" and then select OK.

That will give you this:

Image

Note the texture name is now in the selection box with a color assigned to it. If you want to go back and change that to a different texture, simply click inside that text box and it will bring the land class menu up again.

Select OK again and note that your yellow undefined polygon, has now been defined and assigned a texture, therefore it gets a new color that should match the one that it had inside the selection box.

Image

OK, we're now ready to compile our files again into FS2004 scenery (BGL) files. So once again, assure that you are first in "Point" mode by selecting it in the button menu. Then go to the far right of this menu and select "BGL". This brings up the compile menu. Notice this time, you have a second box checked, the VTP Polygons in addition to the VTP Excludes box. Again if they are not both checked, do that on your own. Then select one or both of the boxes on the right to compile and start FS9.

Image

SBuilder will do its thing, and then we can check our work inside FS2004. If you are following along, you should be able to select KRND and have something similar to this:

Image

Notice the nice clean lines of the new background as well as the fact that it is using a different grass texture than the original.
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

Now I want to add another textured polygon that will add in the golf course on the south side of the base.

I repeat all the steps from earlier and get a new polygon that looks like this:

Image

Once again I right click on the edge of this new poly, select "properties" and select VTP2 as the type. When the new menu opens up, I type a #21 into the layer box. i want to make sure that this poly sits above the main background. Even though in this exercise they don't actually overlap, this is an example to show you that you can overlap your polys but you MUST give them different layers in order for them to display properly in game. So for the purposes of the tutorial, let's assume that this new poly is sitting over top of the one we just made. We use layer 21 because the other poly uses layer 20. This will assure that our golf course poly will sit above our background poly.

Image

I scroll down and find the golf course texture "135 Y Golf Course", select OK, then OK from the other menu and get this:

Image

Once again, go through the process of selecting the "Point" mode from the button menu. You have to be in "Point" mode in order to select your SB parts. If you are not in that mode, you can click on the "Select" menu all you want but none of the parts will be clickable. Remember this little tip, it will save you a lot of grief.

Once you are in "Point" mode, click on "Select" from the small menu, then "Select All" to make sure you get all the elements of your project, then select "BGL" from the button menu, making sure both "VTP Polygons" and "VTP Exlcudes" are checked, compile the files, and go in game to check the work.

If you did it correctly, you should get something that looks like this:

Image
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

Final tips:

To locate the actual scenery files that SBuilder has produced, look inside the folder that you defined in the project's properties menu at the start of this thread. Again the default location for you scenery files will be inside the actual SBuilder main folder in one of its sub folders. This means that in order to get your newly created scenery files to work, you will need to retrieve them from this folder and then move them into an appropriate add on scenery folder inside your main FS9 folder. Generally speaking, you can always place new scenery files inside the FS9/Addon Scenery/Scenery folder to check them in game. This folder should always be active on your setup as it also contains custom made AFCAD files and other types of scenery files that are not from the default program.

For this tutorial I went ahead and changed the output location of my files to the folder mentioned above which saves me from having to retrieve them from their default location, place them into a new folder, then start FS2004 to check my work. Remember when you select the "BGL" button, the compile option menu will appear and from that menu you can have SBuilder automatically start FS2004 when it finishes creating the new scenery files. However if you do not assign an FS9 addon scenery folder to your output files, there is no point to have SBuilder start FS2004 automatically because you will not see the changes. With all .bgl files, you must reboot FS2004 to see the changes. This can be a time consuming process if your version of FS2004 takes a while to load, just keep that in mind as you are creating your projects.

A note on the file names themselves: Sbuilder will automatically name your new files based on the project name that you input as part of the original project properties. You can change that name in the project properties box at any time.

You can also change the actual file name of your newly outputted scenery files to just about anything you want AS LONG AS you KEEP the .bgl extension on the end. Without that file extension, FS2004 will not recognize it as a scenery type file and will not use it to create new scenery.

For organizational purposes, I personally like to keep the file suffix that SBuilder assigns to each outputted file as well. For this tutorial we created two new scenery files. One that excluded the old default airport background, and one that added two new ground polygons, one was the new airport background and the other was the golf course texture.

The exclusion polygon, which don't forget can exclude other scenery elements as well, will always be given the file suffix of "VTPX.bgl" So the outputted name should always look something like this: "myfilename_VTPX.bgl".

The ground texture polygons(airport backgrounds included) will always be combined into one file with a suffix of "VTTP.bgl", giving you an outputted name of something like "myfilename_VTTP.bgl".

So no matter how many different exclusion polygons you create in a SINGLE project, they will always be compiled into just one file, same goes for regular VTP2 polygons (backgrounds, regular textures, custom textures, etc.).

You can as I did with the Nellis scenery, use multiple SBuilder projects to create more than one outputted VTTP, VTPL, VTPX files. (VTPL are lines which will be covered in a future tutorial). You may need to do this with large projects to keep things organized.

Also a note on saving your SBuilder project. You have to be careful to save your projects. SB will not always ask you if you want to save your work before closing out. Especially the first time you save a given project, MAKE SURE you go into the file menu and select "Save As" before exiting SB and losing all of your work.

SB will then save your projects with an "SBP" extension on them and they are located inside the main SBuilder folder on your computer in a sub folder called "Work". Each project you create, produces two project files, one is the actual "SBP" project file that SB will use to load your work up when you return to it later and the other is a "SCM" scasm file extension that SB will use for other types of scenery elements that we haven't covered just yet.
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
User avatar
MIKE JG
MAIW Developer
MAIW Developer
Posts: 10976
Joined: 12 Aug 2006, 02:25
Version: MSFS

Re: Creating/Modifying the airport background

Post by MIKE JG »

This concludes this tutorial. Please use this thread for questions and comments related to this tutorial.

http://www.militaryaiworks.com/newforum ... =33&t=7677
-Mike G.

Recovering flight sim addict, constant lurker.

Check out my real life RV-8 build here: RV-8 Builder Log
Locked