Skip to content
View in the app

A better way to browse. Learn more.

The AVSIM Community

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Custom landclass, benefit of using 512x512bmp vs. 256?

Featured Replies

Can I use a 512x512 Bmp for better resolution in defining landclass info, or does the SDK tool just re-sample anyway back down to 256x256?ThanksPaul

About the only thing I could suggest is test it, and give it a try. Change the land classification in the corner of one of the quadrants, and compare the results using the less precise 256x256 .raw bmp...I'm still interested in trying the method mentioned in one of the other threads, of applying a byte value of 254 to the .bmp to use as a mask, so I can do "spot" touchups of the default landclasses (such as adding Carson City to Nevada, and increasing the urban area sizes in Latin America)....John, KPHX

Hi Paul.According to Christian Stock, a single LOD5 area will get resampled to 257 X 257, no matter the cell size of the data source. So there would be less control with a 512 X 512 data source, as resample re-interprets the data to a smaller grid.

In terms of miles (at average lats & lons), any idea how big an LOD5 grid is? I'm curious as to what the "minimum" size city might end up being with this restriction....I'm also curious as to the effects of leaving off the LOD 5 parameter in the .inf file, while still specifying a grid covering the same area.....John, KPHX

Hi John.There's a 'stack' of 32 LOD5 grids from the equator to the pole. ( 90 degrees / 2.8125 degrees ). The width at the equator is 313089 meters, according to the SDK. The width must be 0 meters at the pole.So an approximate formula for LOD5 width should be:(( LOD5 'stack'# ) / 32 Grids ) * 313089 Meters. Stack# 32 is the equator's LOD5.Maybe someone has a better formula.Each cell of the 257 X 257 grid should be about the size of an LOD13 span... 1223 Meters, at the equator.(( LOD13 "stack"# ) / 8192 Grids ) * 1223 Meters. Stack# 8192 is the equator's LOD13 ( ground tile ).

>About the only thing I could suggest is test it, and give it >a try. Change the land classification in the corner of one >of the quadrants, and compare the results using the less >precise 256x256 .raw bmp... >>I'm still interested in trying the method mentioned in one >of the other threads, of applying a byte value of 254 to the >.bmp to use as a mask, so I can do "spot" touchups of the >default landclasses (such as adding Carson City to Nevada, >and increasing the urban area sizes in Latin America).... Thanks,How do you go about "applying a byte value of 254 to the BMP"?I am still lost on this one!Thanks again John.Paul

The bitmap is simply a raw data file, with as many bytes as pixels. It's sometimes referenced as a grayscale bitmap, but they are also sometimes used along with index files to reproduce color images. Each byte cooresponds to an index value... I'll use a simple 5x5 matrix as an example:60 8D FE FE FE60 FE FE FE FEFE FE FE FE FEFE FE FE FE FEFE FE FE FE FEThe bytes are read sequentially, with each one cooresponding to a cell in the LOD 5 grid (although in practice we're dealing with a 256x256 matrix). There are graphics utilities out there which simply allow you to assign a grayscale color value to a pixel (byte) in the image, then they can save them in raw format. Opening them up in a hex editor would reveal something akin to what I've shown above. A 256x256 raw bmp will only have 65536 bytes in it. The "FE" value is the hex equivalent of 254. To apply "spot landclasses" to an area, I'd probably try to isolate the area to the upper left corner of the raw bitmap, after having first created a file filled with the hex value of "FE". I'm trying to write a simple utility in VB which would allow one to easily create these 256x256 raw bitmaps, rather than resorting to a hex editor. It's a fairly easy process, but I was waiting for something like this to come along (the suggestion of using 254 as a "mask" value) to put it to the test...John

The resampler will resample everything to 257x257.Cheers, Christian

Hi Christian.Is the 257 X 257 an array of points?The reason I ask is because a 257 X 257 grid of verticies will define a 256 X 256 array of planular cells...( each cell needing to be enclosed by points ). Perhaps that is what's happening here, with the 257 X 257 being the pegs upon which the 256 X 256 tiles are stretched?

Doesn't look like it. I can modify the data directly, opening the bgl files (uncompressed ones) with a hex editor and the data grid is 257x257. This grid corresponds to tiles rather than vertices. This may be different for the elvations though. Maybe thats why its 257 rather than 256. In the elevations it's 257 vertices, and Microsoft kept 257 for land class tiles. Initially, I thought that "SampleIsCentred" would decide between 257 and 256, but this switch would always produce a border for my landclass (so indeed it's 256 tiles then but the 257th tile is still there with a FF value, odd).Maybe it's a bug in the FS2000 SDK, because the land class stuff isn't really supported by Microsoft anyway. So chances are that we'll have to rethink for the FS2002 SDK.Cheers, Christian

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.