Jump to content
Sign in to follow this  
Holger

Excluding FS2002 default lakes

Recommended Posts

Hi everyone:In my recently uploaded terrain meshes of British Columbia some of the default scenery, particularly lakes, doesn't work well with the mesh. I'm working on patches to improve the visual quality. For lakes on 'mesas', I use Steve Greenwood's great flatten utility to make complex flatten polygons. It's a tedious process, but works well.My question is regarding lakes sunken in and/or being in wrong places : I think the best thing for now is to simply exclude them out of the default scenery, but how do I do that? In my search of this forum, I came across references to Christian Fumey's DefArea utility. Is that the right one to use or are there other, (simpler?) methods?Thanks for any suggestions!Cheers, Holger

Share this post


Link to post
Share on other sites

Hi Holger.I don't know exactly what Steve Greenwood's utility does, but if it uses the older Area16n flattens, it will really kill your framerates.The lakes of FS2002 are flattened LWM polygons. They can be altered with a variety of programs now available. and [link:library.avsim.com/esearch.php?DLID=&Name=&FileName=lwmdraw4.zip&Author=&CatID=Root]LWMDraw 4..are a couple of good ones from right here at AVSIM's flie library.The FS2002 Terrain SDK has info on these types of BGLs, as well, and these forums have some good info.Dick

Share this post


Link to post
Share on other sites

Hi Dick:thanks for the prompt and helpful reply! I'll look into using the utilities and resources you suggested.The URL for Steve's utility is http://www.fs-traveler.com/flatten.htmlI don't know whether he uses the older Area16n flattens but will ask him in an email and get back to this forum. I have placed up to 5 smaller flatten switches in one area but haven't noticed any impact on frame rates (and I only have an elderly PIII 750).Cheers, Holger

Share this post


Link to post
Share on other sites

It's Area16 flattens indeed (just had a small look at the file). I think for Fs2002 scenery it is better to use the mesh flattens (LWM).Arno


Member Netherlands 2000 Scenery Team[a href=http://home.wanadoo.nl/arno.gerretsen]http://home.wanadoo.nl/arno.gerretsen/banner.jpg[/a]

Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites
Guest sgreenwood

Hi Dick,>if it uses the older Area16n flattens, >it will really kill your framerates.Well ...As Arno has noted, I am using Area16N flattens. Since you both feel this is less than optimal, I decided to bite the bullet and learn enough about LWM development to check it out. (Thanks for the invaluable tutorials.)I created a 16x16 LOD13 flatten area using each approach and see no difference in FPS when switching between them. (especially given the limitations of FPS measurement.) I also noticed that the LWM approach creates much steeper slopes and sharper angles around the borders. Not very desireable when flatten files are used to improve the appearance of transitions between areas. LWM created using LWMDataAreaFill16x16 0, 2, 0, 1, 0, 0, 1 While LWM polygons are quite interesting, and may suggest theoretical advantages, it seems they offer no concrete benefit in this specific situation. Of course this is my first effort with LWM and I may have overlooked something. You can download the complete experiment - bgls and source code - and check it out for yourself. Any additional insights are welcome. Meanwhile, I think I will continue with my current approach. :) My test files are available at:www.fs-traveler.com/cgi-bin/flattest.zipRegards,Steve

Share this post


Link to post
Share on other sites

Howdy:great experimental design, Steve! I'll go have a look in the desert soon.As a heads-up: I posted a screen shot in the Bush Flying forum that shows an area with complex flatten switches a la Steve (i.e., Area16N) applied to four lakes. The number of points per lake range from 8 to 26 (not sure if that would make a difference WRT computing) and I didn't experience any impacts on framerates whatsoever. The post is at: http://ftp.avsim.com/cgi-bin/dcforum/dcboa...rum=DCForumID43Cheers, Holger

Share this post


Link to post
Share on other sites

Hi Steve.The problem with Area16n is not distances or area covered. It's number of polygons.1000 Area16n polys in a viewport can be devasatingly slow... 1000 LWM polys makes no difference in the sim.FS2000 was loaded with m*.bgl files ( coastline flattens ) that killed the framerates... and made FS2000 almost unusable at times. I adapted some of these for CFS2, to allow mesh designers to not worry about the mesh appearance at the coastlines in Europe and the Pacific theater... but they very much slow the sim down ( not good for a combat sim ). CFS2 has LWMs but with no flattening ability.The LWM flattens of FS2002 have no framerate effect. That's why MS made them. That's why I recommend LWM flattens. And Holger will need to use LWMs and VTPs to erase the lakes and shorelines... and recreate them if he choses to move or reshape them. I would be very interested to see the effects of using Area16n for remeshing, and LWMs added later in the datastream, for recreating a lake over that area. Area16n elevations may do the job for Holger... and if the total number of polygons is small, and no other scenery design objects are in the immediate vicinity, then framerate decrease should not be a factor for him... And you're right, if you feel I should not have told him to avoid Area16n catagorically. If he is satisfied to rebuild the mountain with 20-30 points, perhaps it will work out well... and maybe it will look better than LWM "remeshing". Truthfully, I've found no macro combination that pleases me regarding LWM remeshing.Here's the link for Steve's Flatten Utility, for anyone that would like to experiment with it.Dick

Share this post


Link to post
Share on other sites

Hi Holger and Steve.I did some testing with my CFS2 European coastal flattens.This is a huge set of Area16Ns, that is basically the FS2000 coast flattens, but invisible ( no water texture ). I slewed to the northern Norwegian coast for a look.Predictably, I got about a 15% reduction in framerates with the set activated, while looking down the fiords on the coast.I then deactivated FS2002's EuroNW default scenery.... and the FPS rose to about the default level with the Area16N coastal flattens still activated.I then deactivated the coastal flattens, and the FPS shot up some 40%. At that point I felt pretty smug about condemning the older Area16N flattens.But...To be fair, I removed all the FLT and HYP files from default EuroNW, and activated the default scenery. The FPS stayed at deactivated level. That means the LWM flattens ARE causing an FPS decrease.I activated the Area16N coastal flattens, and the FPS dropped... but only to the level of the default EuroNW when it also had the LWM flattens.Hmmmm..........I repeated it a few times, at different coastal locations. Same results.Hmmmm.........The Area16n flattens appear to be no worse than the default LWMs in FS2002... at least on my system. And if they provide equal control or a equal visual quality, then there shouldn't be any need to "remesh" with LWMs ( which is difficult ).This is really a surprise to me. I had thought LWM flattens to be relatively immune from FPS issues... but they are not.I had stated:"The LWM flattens of FS2002 have no framerate effect. That's why MS made them. "That is wrong. LWM flattens do have a framerate effect that appears equal to Area16N flattens.Your utility is looking better all the time, Steve!Dick

Share this post


Link to post
Share on other sites
Guest sgreenwood

Thanks Dick.I went back and did a bit more testing myself, using other bgls I had made earlier. I had created a ditch one LOD13 area wide and 32 long, extending the entire height of an LOD8 cell, using each method. I also have a much larger a 2x2 degree Area16N bgl. I tested these at 4000' so I could compare them with the default mesh. The ditch fills about 1/3 of the frame so the surrounding terrain plays a larger role here. [span style=font-size:1.5em] [pre]area method FPS1x32 area LWM 71-771x32 area Area16N 77-83default ??? 83-912x2 degree Area16N 91-100[/pre][/span]It looks like the Area16N method may even have the edge, although I'm not going to count on it. (Of course large flat areas help.) The resolution is limited to the resolution of the mesh. I've tested LOD12 data using a rectangle only 0.0005 minutes square, and the bgl created a flattened area about 9.6m square. Very convenient to use, and there is no need to calculate x,y offsets in the LOD13 area as well.I'll make these test files available as well if there is any interest.I agree with Holger, it is inconvenient to enter a lot of coordinates. It would be nice if there were a tool that worked with FSUIPC so we could slew around and create a text file of coordinate pairs with a hot key. This could be cut-and pasted into my text source file or perhaps be read directly by AWK. I looked around for something like this a while back but didn't find anything too promising. I have a companion exclude program that performs well, with one exception; NDBs are not excluded. Manfred has a "?" next to the hex value for this entity, suggesting he also experienced problems. Do you know if this is a problem with the SCASM implementation, exclude bgls, or with excluding NDBs in general. I haven't tested the switch.There is another bgl issue I haven't seen discussed, and so will mention it here. Although I didn't think of this as a "feature" at the time, the new version of Resample is able to leave a "transparent" hole in a mesh bgl file. A small square of 4 missing data values is enough to cause it to omit the data for the enclosing LOD quadrant. Not very fine resolution, but I wonder if this may prove useful for better integration of scenery with large areas of mesh at some point. Here is an example.http://ftp.avsim.com/dcforum/User_files/3e4540ec2180de4d.gifSteve

Share this post


Link to post
Share on other sites

Hi Steve.That mesh 'feature' might be exploitable for designing meshs. I wondered if the new resample had a difference with mesh.I also wonder if all the variations of Area16N commands work in FS2002?E63() and E67() have a texture assigned... I wonder if they display well. I have played with E63() in CFS2, and it works very well to cut rivers, or sloped Railroad beds. It might even be useful for creating road segments, as each end of the segment would be at a defined altitude... the drawback is that different meshes could leave huge valleys and elevated roadbeds!I never found a texture number that would be transparent... but there might be a trick to do that. :) I don't know if 63's or 67's need the old 8-bit mipped or if they accept DXT1 as a texture.Arno, or Christian Stock, might have some clue as to excludes and NDB.Dick

Share this post


Link to post
Share on other sites
Guest sgreenwood

Hi Dick,I'm afraid I can't help you with the other Area16N commands. My primary concern has been getting mesh and scenery to work better together. Since it doesn't look like performance provides a clear criteria for selecting Area16N or LWM flattens, I did yet more testing to see if the tradeoff might be ease-of-use vs. whether "they provide equal control".I first created very small flattened areas in the same region of Africa: 0,0 0,1 1,0 1,1 square using LWM. 0.00005 minutes square using Area16N The results seem to be about the same. The minimum possible flattened area, over LOD7 GTOPO30 mesh, is about 0.22 minutes wide and 0.18 minutes high. This corresponds to an area defined by about 4x3 points in an LOD7 area and 16x17 points in an LOD13 area! When I switch to the default mesh, the minimum possible flattened area is much larger. This is consistent with some earlier tests which showed Area16N flatten resolution was related to the LOD of the underlying mesh, but I am surprised to learn that the same seems to be true for the LWM flattens as well. The surface was not truly flat in either case.The precision increases significantly with higher LOD, but few have control over this value. LOD12 mesh produces a nice sharp rectangular area with a flat surface (using Area16N; LWM not tested but I would hope for the same result.)I then created flattened areas larger than the minimum possible area: 0,0 0,20 20,0 20,20 square using LWM. comparable area (from slew coordinates) using Area16N The flattened areas expanded as expected. So the underlying mesh LOD seems to determine only the minimum possible resolution, but this has significant implications when trying to control small areas extending from a larger core region. The underlying mesh, not the flatten technique, determines precision.I don't know what kind of precision you see in other uses of LWM polygons, but at this point LWM polygons seem to offer no advantage over Area16N flattens in this aspect of design either. :(Steve

Share this post


Link to post
Share on other sites

Hi Steve.The precision of LWM visually is about 4.8 meters... the same size as 1/256th of an LOD13 Area ( LOD21? ). We could refer to this as a pixel, as it is the TMF-TDF limit size. That's true for VTP and LWM.There is a blending routine at the borders that smudges the edge for about 1 "pixel" width. The flattens don't correspond to this. Flattening was tacked onto LWMs after CFS2, which used no default flattens. I'm not sure that was a good idea, as the only problems we have with LWMs concern this flattening.As you noted, the closer the mesh verticies, the sharper the elevation distinction for a flatten.There is no way to "undo" either type except by removing the BGL that is flattening the shape. With new water, the LWM flattening makes sense, as it lets there be 1 BGL, and compact code, to handle both the flattening and the watermasking. To 'remesh' elevations flattened by the default LWMs? Like you, I'm leaning towards Area16n flattens. The only possible problem is that they might not be supported in future versions of FS. But we don't know if any of our design methods will work with FS2004... just look at what happened to CFS3. Dick

Share this post


Link to post
Share on other sites

Hi Dick:you wrote:"I did some testing with my CFS2 European coastal flattens.This is a huge set of Area16Ns, that is basically the FS2000 coast flattens, but invisible ( no water texture ).I slewed to the northern Norwegian coast for a look.Predictably, I got about a 15% reduction in framerates with the set activated, while looking down the fiords on the coast."When I read these lines I had to immediately think of one of my favourite pieces of fiction - anyone knows where the following quote is from? ;-)"'You know we built planets do you?' he asked solemnly.'Well yes,' said Arthur, I'd sort of gathered...''Fascinating trade,' said the old man, and a wistful look came into his eyes, 'doing the coastlines was always my favourite. Used to have endless fun doing the little bits in fjords ...'... 'Did you ever go to a place... I think it was called Norway?''No,' said Arthur, 'no, I didn't.''Pity,' said Slartibartfast, 'that was one of mine. Won an award you know. Lovely crinkly edges. I was most upset to hear of its destruction.'"As for the rest of this discussion thread - very fascinating but I'll have to do some background reading first to fully grasp what you guys are talking about ;-)Cheers, Holger

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