Closter wrote:Hi all!
This is one of my subjects of interest, too. Some wrong assumptions here, as I see it.
-The data in L2 is from the 30 arcsec type, so along the N-S direction is about 900 meter each vertex. Along the E-W, it depends on the latitude, but always is less or equal.
-The data in L1 and L0 are derived from the L2 through SPTInstall, in a bilinear interpolation way. Kind of overkill, in my view. We don't need data that we can't see. But luckily, we can alter these two grids to improve the detail. That`s what BaZ did. So they are a 15 and 7.5 arcsec grid.
-The data from SRTM is 1 arcsec in some parts of the world (US mainly) and 3 arcsec in the rest. So 30m and 90m along the N-S. Pretty much for us (not bad at all).
-This data is available in 1 degree x 1 degree chunks from a FTP server, in a simple binary format.
-The only problem is to get this data into the Lx, Ox files.
-I would love to know these formats, Lx Ox. Please, some info here.
Are you a programmer? Can you create a utility to convert the data? I have the Lx/Ox formats somewhere...I just have to find them.... Will edit this post when I do.
------------------------------EDIT------------------------------------------------
Here are the notes I have accumulated on this subject along with the links I picked them up at. Not sure if the FF link will work now that they have a new forum:
http://www.freefalcon.com/forum/viewtop ... aggy#73082
File formats are as follows:
O2 file: 4Bytes per Record
DWORD(LONG) - L2 byte Location
(This file essentially, represents the SEGEMENTS of the theater, starting a 0,0 in the LOWER LEFT corner, to 63,63 in the UPPER RIGHT. Each of the DWORD(LONG) Records points to the location in the L2 file (in BYTES), that the 16x16 Tiles that make up each segment, begins. Like the O2 files, the order of the 16x16 segement records in the L2 is, starting at Lower Left, going to Upper Right)
L2 File: 9Bytes per Record
DWORD(LONG) - Texture Offset Number
WORD(INTEGER) - Elevation
BYTE - Palette
BYTE - X1
BYTE - X2
(Bytes 1-4 hold the Texture info, this what you want! 5-6 hold the elevation (in ft), 7, palette, 8 and 9 have something to do with the Normals, and you dont need to worry about them either!)
-So now you have an array of offset numbers (representing tiles)
-now you need to use the Texture.bin to figure out the Offset Numbers of the tiles and related them to the Filenames (im not TOO familiar with this format, but basically, the tiles are arranged into tilesets, with are 16 tiles long. So if there are 16 tiles in that tileset, you number them 1-16... If there less than 16, you still assign 16 numbers to that tileset... For example, if you have a tileset that only contains 8 tiles then a tileset of 16 tiles, the numbers would look like; 1-8 (for the first tileset) then 17-32 for the second tileset... I hope that helps)
-----------------------------
http://www.freefalcon.com/forum/viewtop ... rmat+zaggy
L2 Record
2-byte
===============================
WORD Texture;
WORD Elevation;
BYTE Palette;
BYTE X1;
BYTE X2;
4-byte
===============================
DWORD Offset;
WORD Elevation;
BYTE Palette;
BYTE X1;
BYTE X2;
WORD = 2 bytes
DWORD = 4 bytes
BYTE = 1 byte
O2 Record
2-byte & 4-byte
===============================
long (4 bytes) Pointer to each Section in L2.
Section = 16 x 16 x size of L2 record
And looking at that structure then, the only thing a 4byte structure does, is allow a larger number of textures to be used? Not that I want to mess with that area of it... Just the elevation stuff... And that shouldnt require messing with the O2, should it?
The L2 Offset points into fartiles.raw. With the more diversified tiled theaters, like the Balkans, the 16-bit offset was limited to 64,767 fartiles (Blkans has ~102,000 fartiles). Making the Offset a 32-bit integer extended the number of fartiles to 4+ gig tiles.
The O2 offsets (pointers) change due to the size (bytes) of a L2 section.