Sign in to follow this  
rhumbaflappy

Landclass BGL creation

Recommended Posts

Hi,I think we allready discussed this matter few months ago but I can't find the post. Anyway, I have the following situation. I have three landclass.raw files to cover whole Slovenia and I would like to combinte them into one inf file so I will get oe BGL for lanclass. How this inf file should look? I also assume, since waterclass is similar to landclass, that I can also include waterclass data also in the same bgl (and same inf). Are there any special things that I should be aware of?Thank You for answers in advance.Best regards,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Hi Goran.Have you tried to use tmfmerge.exe to merge the tmfs before you use tmf2bgl.exe?I think that would work.Also, you could combine the RAW files to one source. Then, create the TMF from that in one INF.[source]Type = ClassU8SourceDir ="."SourceFile = "goge2_0ll.raw"Lon = -179.99999999Lat = 89.99999999NumOfCellsPerLine = 43200NumOfLines = 21600CellXdimensionDeg=0.0083335262390333109562721359290724CellYdimensionDeg=0.0083337191536645215056252604287236[Destination]DestDir = "."DestBaseFileName = "World"UseSourceDimensions = 0NorthLat = 89.99999999SouthLat = -89.99999999EastLong = 179.99999999WestLong = -179.99999999The above INF creates a new WorldLC.tmf from a source of 43200x21600 !It works. Note I made the destination a tiny bit less than the actual world dimensions. That allowed the wrapping of the tmf around the world. The exact dimensions left a line of water near the international dateline ( W180* ).If this causes a problem with a single RAW file, then the solution might be to enlarge the dimensions a bit, rather than shrink them ( you're not wrapping around the globe in this case ).Dick

Share this post


Link to post
Share on other sites

Hi Rhumba!Thanks for reply! I went so deep in VTP coding for my roads and lakes that I completely forgot how to use resample and TMFxxxx utilities :D. Anyway thank You for remembering me on TMFMERGE. So You mean that it would be best to create separate TMF, named let's say FSSloLC1.tmf, FSSloLC2.tmf and FSSloLC3.tmf, combine them together with TMFmerge and convert this LC with TMF2BGL to FSSloLC.bgl?Yesterday, when I was searching for suitable LC code for displaying rocks (texture 056b2xxx.bmp and btw I haven't found it ;( ) I also found the what I hope it will also work in one SDK. it goes something like this:

(source)UseMultipleSources=1NumberOfSources=3(source1)...(source2)...(source3)...(destination)...

Do You think I can use this approach? Thanks again,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites

Hi Goran.It might work. I seem to recall a problem with a multisource inf and landclass. The best way would be to try it. :)I suspect you may need to actually combine the RAW files. This RAW source would need to be rectangular, and equal to or larger than the bounds of the destination.You may need to add a "dummy" RAW block to square off the source... that would be filled with value #254:XOXXwhere "O" is the dummy. In fact you could make it:OOOOOXOOOXXOOOOOand that would guarantee the compilation! The source can be much larger than the destination extracted from it. The surrounding dummy value blocks may help the blending-in of the new landclass without the sharp "cutoff" we sometimes see with addon landclass.I think #130 is rock, but I don't know if it "blends" like normal landclass.Dick

Share this post


Link to post
Share on other sites

Hi Rhumba!Thanks for Your answer; You mean that original RAW file should be resized to 257x257 so that one coloumn added on the right and one row added on the bottom would be for joining? If it is so, no problem, thanks for advice.Regarding rocks; I think also #130 are rocks, but the main problem is, that I want texture 056B2xxx to appear (gray rocks) but instead of it I got 056F2xxx which has some unnatural reddish stones. All the pictures of our mountains have these gray rocks and I am quite surprised, that they are not available. I spent 4-5 hours searching valid landclass value and at the end came up to use red rocks :(. And I have full house of nice pictures of our mountains with beautiful (light) grey stones...Thanks again and best regards,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites

Hi Goran.What I actually meant was that each "X" would be a 256x256 or 257x257 source... and each "O" would be a dummy ( transparent ) source, also 256 or 257 in span. Then join the source RAW files by cut'n'paste in a paint program to have a larger, all-inclusive source for your project's landclass. Then the INF file would need to declare the right bounds for the source and desination... and it would give you a single landclass BGL that would encompass all your area, and blend-in to the default at it's edges, due to the transparency. We actually should have been doing this from the start with our small landclasses. By surrounding our data with LOD5 blocks of null data ( #254 ), and expanding our destination bounds to include those null blocks, we get a natural blending with the default landclass, instead of the sharply cutoff texture at the edge of the landclass.===========================The best way to source a single LOD5 area landclass, is to make a 769x769 null ( value #254 ) RAW file, then paste our 256x256 data to the center of that file. Why 769? ( 256 * 3 ) + 1 = 769That's one more vertex than the number of cells enclosed. For the best control, the source should always be the number of cells + 1.Place the source bounds at the NW corner. Make the destination bounds as equal to all the 9 LOD5 areas encompassed.The end result should be a file that encompasses 9 LOD5 areas, with all transparent except the central LOD5 ( that has your data ). And that landclass should blend into the default perfectly at the edges.=================This would also allow non-adjoining LOD5 data to be in a single BGL:00000000000X000X000000XXXXX00000X00X00000000000000That represents 50 LOD5 areas, with 9 areas of actual data. The rest of the data is populated by #254. The optimal size would be 2561x1281 ( with 256 cells per LOD5 area, +1 each way for the enclosing vertex ). The entire area should be sourced and destined. The resulting BGL should have all 50 areas landclassed. Only the 9 with valid data will appear. With tmfcompress, this BGL will be smaller than 9 separate BGLs, and the landclas edges will blend-in to the default as well.==========Try #133 ( lava ) or #138 ( black sand beach ) for rock values, and see if those are better.Dick

Share this post


Link to post
Share on other sites

Hi Rhumba!Thank You for this great answer. If there will be any problems, then I will try this enormous texture, but for now I will try with INF file with multiple sources.But what still bothers me is the texture. I tried around 30 different LandClass values to get those gray stones but I can't persuade FS to use them. Do You (or anybody else) have any idea, how to push FS to use grey stones textures instead of brown ones. It is simply unnatural here in Slovenia; it looks like we are in Grand Canyon not in the Alps world. :-( Is there any possibility to add some textures to LC lookup table or to tell FS use those textures? Afterall those textures are allready there... :-zhelp :-zhelpBest regards,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites

Maybe you can use the approach we use for our Dutch landclass? We just use the default numbering, but have made our own textures for the fields. So in the texture subfolder we have new textures with the default names and those are used.(Of course there are no mountains in the Netherlands, so we didn't have that stone problem :D).Arno


Member Netherlands 2000 Scenery Team[link:home.wanadoo.nl/arno.gerretsen]Arno's FlightSim World for scenery design hints, tips and other tricks...

Share this post


Link to post
Share on other sites

Hi Arno and Goran.I think if you use a local texture set, the local set must contain all the textures used in the small landclass BGL, or else there will be default textures not displayed. The work-around for that was to copy all textures from the '...scenedbworldtexture' folder to the main "Scenery" folder ( not a well recieved idea ).This isn't a large problem if your landclass contains a dozen texture assignments, but it still has some problems. If you wish to distribute the scenery, MS might frown on packaging their textures with your scenery.An alternative?2 landclass BGLS, one in a separate project folder without a texture subfolder, and the second in a normal project folder with a texture subfolder. First, the landclass for the general area using the default textures. It must be in a scenery folder without a twin texture folder, like normal landclass. The textures are then found normally in the default '...scenedbworldtexture' folder.Second, a landclass bgl that can be placed with the VTP or object scenery ( that does have a twin texture folder ). This landclass is all value #254, except for the rock texture that is placed. These textures must have the same name as a default texture, as Arno indicated, so the lookup table will be able to place them. Then placed the renamed textures into the local twin texture folder.You'll need to watch the datastream for the landclasses. The default landclass scenery folder will need to be displayed first ( lower ) in the Scenery Library order, so your customised rock landclass will next override them. This, in effect, layers the landclasses you create.I think this should work, though I have not tested it.Dick

Share this post


Link to post
Share on other sites

Yes, I guess you are right. Our landclass scenery only uses a few textures (6 different types of fields, to indicate the different look in the different parts of the country). All other things like towns, etc are placed with VTP polygons, so we use a very limited amount of textures with our landclass (and all textures are made by us).Arno


Member Netherlands 2000 Scenery Team[link:home.wanadoo.nl/arno.gerretsen]Arno's FlightSim World for scenery design hints, tips and other tricks...

Share this post


Link to post
Share on other sites

Hi Rhumba and Arno!Thanks for this nice idea! Maybe it would be worth trying making two LandClass files. The installer (which must be used due to hugness of scenery) will simply copy those needed default textures to my texture folder under correct name of course. I think if I copy those textures it won't be illegal to Microsoft?Best regards,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites

Hi Goran.As long as you're not distributing their textures, MS shouldn't have a problem with it... after all, the end user is supplying the actual textures from their own copy of FS2002. Good solution, I think.I still haven't tested this "layering" of landclass BGLs, so I would appreciuate if you keep us informed if you use that approach to using customized textures.Remember, the landclass BGL that uses the default textures needs to be in a separate project folder, with a "scenery" sub-folder, and no twin "texture" sub-folder. That's usual for landclass, and it forces the sim to use the default textures for that landclass BGL.Dick

Share this post


Link to post
Share on other sites

Hi Rhumba!Thank You for Your opinion. I will gladly post You discoveries based on this theme, no problem.Thank You and Arno again!Best regards,Goran BrumenFS Slovenija 2002 teamhttp://slovenia.avsim.net

Share this post


Link to post
Share on other sites

Hi guysThe simple solution to problems with ground textures and landclass scenery is to copy (or move - more efficient and perfectly safe - I have checked it out thoroughly) all ground textures files from fs2002scenedbworldtexture to fs2002texture, as mentioned earlier. One can then have landclass BGL's in their own ..scenery & ..texture folder pairs, with any replacement textures in the ..texture folder, with no problems at all. The other step that is necessary is to also copy ALL Autogen .agn files from fs2002scenedbworldtexture to the new ..texture folder (copies are required in every ..texture folder accompanying a ''scenery[/b] folder with a landclass BGL in it - unless you leave the ..texture folder out altogether).Everything then works like a charm. Why on earth the reference to "not well received", Dick, I just don't understand. This technique works and there are NO side effects etc. - so what's the problem?CheersGerrish

Share this post


Link to post
Share on other sites

Hi Gerrish.Perhaps that was just my mistaken impression. The method you describe is right, and can easily be accomplished by a batch file to either copy the textures and autogen. Scenery designers could include the copying batch file with their scenery. Unless harddrive space is at a premium, there would be no need to remove the original contents of the "scenedbworldtexture" folder... in fact they could be left as a storage of the original textures and autogen.It's one of my wishes for FS2004, that this could all be fixed... especially autogen location. ( And the vertical flipping needed for VTP texturing, and the secret of default VTP lines.... ). :-lol Dick

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