Jump to content
Sign in to follow this  
Guest Derek D

Raster water masks?

Recommended Posts

Guest Derek D

Greetings, this post represents my first foray into the realm of FS scenery design. Unfortunately, the idea I have chosen to work on for my first project is rather ambitious, and the FSX scenery engine isn't nearly as friendly as I anticipated even with the help of the SDKs.At it's most basic level what I'm trying to accomplish is fairly straightforward--I want to take a 256x256 black and white image representing a water mask, and process it into a BGL as an LWM water poly. The difficulties stem from the (apparent) inability to use raster images as water masks. This has prompted me to attempt writing a program to convert raster images into vector data, but this has proven to be considerably difficult.I know it is possible to use raster images as water masks when processing photoreal scenery, but is it possible to do so over generic landclass? Is there any tool out there that can convert raster images to vector data that can be read by one of the compiler tools in the SDK (preferably with batch capabilities)? If anyone has any thoughts on a good way to approach my project I would be most appreciative. Thanks!Derek D.

Share this post


Link to post
Share on other sites

I don't think there is a current tool of course, but I think either/both of autoASM and slartibartfast have the ability to extract vector shoreline data from rasters. Once you have the shoreline, you still need to get to water mask polys. I'm not sure if those tools did that directly or not. At any rate, once you have the vectors they need to be in shapefile format for processing by shp2vec, which right now is all we have for generating fsx cvx files. Note that the shapefiles for airport "flattens" and "LWM" must be polygonZ type with elevations attached to coordinates. Note there also seems to be the new HGx watermask which seems like the same thing except it is using "polygon", that is, without elevation data, shapefiles.I guess maybe you could use your raster directly, with the blending option, to create a photo scenery water mask (which would not flatten the water).scott s..

Share this post


Link to post
Share on other sites
Guest Derek D

Thanks Scott. I may experiment a bit with blending. It certainly *seems* easier than mucking around with water polys and land polys, but the lack of flattening seems like a problem and I don't know if it is worse than vector polys performance-wise.Regarding those tools you mentioned, I did try autoASM before because I heard it had raster-to-vector capabilities. With all due respect to its creator, I'm sure it's a powerful tool once you get the hang of it but frankly the GUI just scared the bejeezus out of me. The interface will need a major overhaul before I consider trying it out again. If Slartibartfast can in fact do the required task with batch capabilities, I will definitely check out that tool.

Share this post


Link to post
Share on other sites

Note there also seems to>be the new HGx watermask which seems like the same thing>except it is using "polygon", that is, without elevation data,>shapefiles.The vector data from the HGX files are consumed by the GPS which does not care about elevation.-Doug

Share this post


Link to post
Share on other sites

We do this routinely derek. Drop me an email if you want details. Slartibartfast is the key, with manual editing in Sbuilder.


I7-7700k@4.7ghz | 32gb RAM | EVGA GTX1080 8gb | Mostly P3Dv5 (also IL2:BoX, DCS, XP11)

Share this post


Link to post
Share on other sites
Guest Derek D

Thanks Gridley, it's good to hear I'm not the only person on the planet who had a desire to do this :-lol. However I've decided to put this project on the backburner for a bit so I can devote more time to my landclass project, but I'll be sure to drop you a line when I'm ready to delve back into this in full.

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...