Jump to content
Sign in to follow this  
falconno

my approach to avoid re-meshing

Recommended Posts

It's the familiar story: you've spent hours digitizing accurate shorelines but the default LWM flatten polys remain, which makes the entire process pretty frustrating. So here's an approach that I'm using that doesn't require any tedious re-meshing. I'd appreciate any feedback as I'm planning on distributing the project files soon. The area is in southern British Columbia (badly mangled in the default FS9), with new LOD9 mesh, partial replacement of lake shorelines, full adjustment of lake elevations, and some new roads/railroads and landclass enhancements.Ultimately, we'd like to be able to get rid of the FS9 HP9*.bgl files, but without losing data or causing compatibility problems for users. The basic idea of this approach is to assemble a copy of the HP9*.bgl file, manipulate this copy as desired, and compile it for installation into a local scenery directory. The user then has the option (!) to disable/rename the default HP9*.bgl file and thus regain the full terrain mesh (minus the new permanent flatten areas for roads and utilities - grrr!). If two designers happen to work on the same LOD5 area then the File Library priority will determine precedence; not ideal, but at least no one has altered the default files.Since we can't read the FS9 LWM files yet, we need to utilize the correspoding FS2002 HYP* files (as far as I can tell, their contents are identical except for the new feature of sloped water, which happens to be responsible for most of the 'mess' in my project area).Specifically, I use LocBGL, TMFViewerCalc and TMFViewer to determine the names of the default FS2002 LWM files that cover my area (in FS9, these files appear all to be LOD5 squares, meaning they cover a smaller area than most of the FS2002 HYP* files) and a list of the LOD8 cells included in that LOD5 file.I use BGLAnalyze to decompile the selected FS2002 HYP*.bgl file(s), open the .asm file(s) in Notepad and cut and paste the desired cells into one "Master copy" that has the same 8x8 LOD8 cells as the FS9 LOD5 original. If this sounds like a lot of work: it took me less than two hours to complete this task for four LOD5 master copy files (our upcoming tutorial on lake elevation adjustments should help people unfamiliar with the HYP* file format).The master copy can be used in two ways: adjusting the elevation of individual lakes to better fit the add-on mesh; and removing those cells/areas that are receiving new shorelines with Ground2K or other utilities. All cells/areas that remain unedited will display exactly like the default LWM polys, so one doesn't have to rework an entire LOD5 square.Once your Ground2K work is complete, compile those files and the master copy and install all project files in a local scenery directory. Test it in FS9 and then you're ready to deactivate/rename the HP*.bgl file. If you or the end user doesn't want to touch the default files, all the elevation/shoreline/linework changes will work as intended except that the default flatten switches remain active. In other words, either choice works perfectly fine. I spent much more time doing the new shorelines etc. than editing the master copy, and thus believe it's an interesting alternative for these kinds of situations. Obviously, some areas require heavy 'terraforming' more than others and you probably don't want to use this approach for adjusting only a few areas or cells.Here's a screenshot comparison of the default FS9 mesh/LWM display, just outside of Castlegar, against the new mesh/LWM data and the two options regarding the default flattens. Note that the images were taken from exactly the same position! Also, for lack of modeling skills, I approximate the hydro dam with an LWM 'earth mound' and an autogen bridge on top ;-) http://forums.avsim.net/user_files/43146.jpghttp://forums.avsim.net/user_files/43147.jpghttp://forums.avsim.net/user_files/43148.jpgAny comments are appreciated. Cheers,Holger

Share this post


Link to post
Share on other sites

Hello.This looks very interesting. The re-mesh option does'nt give me any good result, but this looks really nice! But how on earth do you get the right hyp* file? There's a lot of them. Is there a tool to search trough all the files? I do have LocBgl, but doesn't have any luck with it.You mentioned a tutorial, is this ready yet?PerA

Share this post


Link to post
Share on other sites

Howdy:The tuturial will be out shortly (Steve just updated his flatten utility so I have to make changes to that part) but here's the bit for finding the correct "hyp*" file; it's written for an example of a single lake but applies generally to determining whether any bgl file includes the desired coordinate: "Part 3: Locating the lake in the FS default files1. Start LocBGL.exe, then select the correct FS2002 directory as follows: open Scenedb, then 'Westhem' (i.e., Western Hemisphere) or 'Easthem', then the scenery sub-folder of the appropriate regional directory; in our example it's Cane (i.e., Canada East), as in 'ScenedbWesthemCaneScenery'. Remember that you'll need to use the FS2002 data even if you want to correct the lake in FS2004. 2. Enter the latitude and longitude of your lake. Note that you can enter either Deg/Min/Sec separately or simply decimal degrees, e.g. LAT '54.429' and LONG '69.442'3. In the 'Highlight the File' window, scroll to the first file that begins with 'hyp'4. Move through the hyp*.bgl files one by one (arrow-down key) and watch the display at the bottom. If your coordinate is part of the file LocBGL will display 'YES'; in our example, it's the first file, 'HYP540~1.bgl'.http://forums.avsim.net/user_files/43429.jpg5. Locate the file in Explorer ('hyp540204.bgl') and copy (not move!) it into your working directory (e.g. 'my Quebec lake patches'). While LocBGL doesn't display the full file name they are shown in alphabetical order so you can find the correct file as long as your Explorer window is sorted alphabetically as well. "Hope this helps. Cheers,Holger

Share this post


Link to post
Share on other sites

Hello again.Yes, it helps very much! Now i've found the right HYP-file for my area. Next thing for me is to find out HOW to edit the asm file. I have the necessary info on the exact location (via TdfCalc).Thank's again for your response. Waiting for your tutorial.Best regardsPerA

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