Alpha Mask to generate water

General discussion about Scenery Design. Questions about SBuilder for Flight Simulator FS2004.
Post Reply
Amengol
Posts: 8
Joined: Mon Nov 26, 2007 1:28 pm

Alpha Mask to generate water

Post by Amengol » Mon Nov 26, 2007 1:43 pm

Hi all. I like the quality of the terrain generated by Sbuilder, and I prefer to use this instead of other tools and the Terrain SDK method. The problem is that with the usual method I got water with the Alpha bitmap, but in sbuilder I got blending. Is that a workaround to get water instead and maintain the quality of those images?

Thanks a lot.

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Mon Nov 26, 2007 2:59 pm

Hello,

The photo scenery in SB205 is nothing more than VTP polygons. So you need to know the VTP layer number for the photo scenery and make a VTP polygon with a water texture and with an higher layer number. I am not 100% sure if this works.

Kind Regards,

Luis

Amengol
Posts: 8
Joined: Mon Nov 26, 2007 1:28 pm

Post by Amengol » Mon Nov 26, 2007 3:33 pm

Hi Luis, and thank you for the tool and for that reply, but I'm not sure about how do I got VTP polygon with a water texture. Could you be more specific?

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Mon Nov 26, 2007 7:52 pm

Hello,

You can use custom textures and they can be water. But I think that you want "100% water" that is, for example, the capabilty to get water effects, water reflections and so on. If you paint the photo texture with water you can not get that.

By reading the SDK:

<font color="red">
Layers define the order in which Flight Simulator applies the textured polygons to the ground and in which phase of the texture building process they are applied.
• Layers 0 to 3 are applied in the water texture layer. These are applied before the water texture is masked into the land texture. These polygons appear only in the water and are clipped by the land portion of a texture.
• Layers 4 to 7 are in the land texture layer. These textures are applied to the land texture before the water texture is masked in. Polygons used at these levels appear on the land texture but are clipped by the water portions. For this reason, airport skirtings and park polygons were placed in layer 4.
• Layers 8 and above (the number of layers is capped at 100) are applied to the texture after the land and water are masked together. Polygons applied at this level appear over both the land and water portions of the texture. Shoreline polygons were placed at level 8 to provide a blending effect between the land and the water.
</font id="red">

It seems that if your VTP scenery has a layer number of 4 to 7, then a LWM water mask polygon will cut the land. Can you try and report? I am sorry but for a long time that I do not use FS9 VTP photo scenery.

Kind Regards,

Luis

Amengol
Posts: 8
Joined: Mon Nov 26, 2007 1:28 pm

Post by Amengol » Mon Nov 26, 2007 8:50 pm

I'll try and report, but answer me if to do that, I must have the Alpha Channel (to the water mask) in the same file (like 32bit bmp) or an alpha bitmap (8bit) in a different one? Cause when I load a map and a alpha bitmap to it, I always get a blending effect and not the water coast line I want! Or are you trying to say that, if I change the layers, I could get a blending effect over water. Is that correct?

Thanks for you patience.

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Tue Nov 27, 2007 4:12 am

Hi,

No. The alpha map will always translate into blending. You can test what I mean (note that I am not 100% sure!) with a small project:

a) Make some VTP polygon withe a land texture and give it a layer number of X. This will be your photo polygon.

b) Make a LWM water polygon that intersects the above polygon. Call A the part that intersects the VTP polygon and B the remaining of the LWM polygon.

c) Consider the VTP polygon divided in 2 parts A and C. A will be the same region as above and C will be the remaing part of the VTP polygon.

Image

Now I think that:

1) X = 0 1 2 or 3

C will not show because the VTP polygon (C + A) is applied to the water layer and FS will take this region from the land layer. A will show as a land texture. B will show as water.

2) X = 4 5 6 or 7

C will show as the land texture. A will show as water because the VTP polygon was painted on the land layer and FS takes the pixels for this region from the water layer. B will be water.

3) X = 8 or greater

A and C will be land because the VTP polygon is painted over the Land/Water combination. B will be water.

In conclusion: FS takes pixels either from the land or the water layer. VTP polygons can be painted on top of the water layer ( X < 4) on top of the land layer ( 3 < X < 8 ) or after the 2 layers are combined.

Hope this is correct,

Regards,

Luis

Amengol
Posts: 8
Joined: Mon Nov 26, 2007 1:28 pm

Post by Amengol » Tue Nov 27, 2007 2:00 pm

Ok. I got it. The problem is that I have an Alpha Map to water, so, since when it is not possible to produce water from that, I think a workaround, according to your line, should be:

Example to an island in the middle of the ocean:

Just put the photo scenery in a layer grater than 8. Load the alpha channel to it. The blending effect should be over water. Is that correct?

In case of a cost line in a continent, things would be a little different. We should do a water polygon that enter some meter over the land. And than use the same method.

You think it should work that way?

I will try this later and post the results.

User avatar
Luis Sa
Posts: 1736
Joined: Sun May 18, 2003 11:17 am
Location: Portugal
Contact:

Post by Luis Sa » Tue Nov 27, 2007 8:14 pm

<blockquote id="quote"><font size="1" face="Verdana, Arial, Helvetica" id="quote">citação:<hr height="1" noshade id="quote">
Example to an island in the middle of the ocean:

Just put the photo scenery in a layer grater than 8. Load the alpha channel to it. The blending effect should be over water. Is that correct?
<hr height="1" noshade id="quote"></blockquote id="quote"></font id="quote">

Hi,

Please read the section on LWM masks on the Help file. In the middle of the ocean there is only the water layer, so to speak. So you can either use a layer of 3 or 8. But your island will have a land texture but it will have water properties. You should first insert several land class tiles that cover the extents of the island (note that for a single land square to appear you need 4 vertices of land). Then you would make the coast of the island by several LWM water polygons. No VTP up to here. Then you could add a VTP shoreline to add some sand looking and waves. The layer here should be 8 because it should cover the both the land and water boundary line.

Regards,

Luis

Post Reply