Lazy LOD

As I already mentioned in my previous post I have been working hard on a scenery of Schiphol airport recently. As this is quite a big airport and we tried to make it detailed as well, we ended up with a lot of objects. Unfortunately this did not improve the performance a lot. In the past you could easily limit the visibility distance of an object with the v1 value of the reference point. But in the Fs2004 XML format this is not possible.

I know you are know thinking that we should just have added LODs to our MDL files and I guess you are right on that. But for most objects we did not do that. Partly because the performance was not too bad until now and probably also because it takes quite some time to make good LOD models for complex buildings. And a third reason is probably just that we are a bit lazy sometimes.

But to increase the performance a bit, we still had to limit the visibility of the objects, as the default range the scenery engine uses is a bit too big in general. So I extended MDL Tweaker a little bit, so that it can now also create conditions using the IFSIZEV and IFSIZEH commands. These are also used by the LODs generated by MakeMDL to determine which LOD to show. This command checks the amount of pixels that is used by a certain length at the position of the object. If this amount of pixels is below the threshold specified, the lower LOD will be shown (and in our case I used an empty LOD for that). The advantage of this command over a simple distance check, is that it also depends on the screen resolution you are using. So if you run at a higher resolution the objects will show earlier, as they should to get the same image quality. If you use a fixed distance the object seem to pop-up later if you run at a higher resolution.

So based on the radius of the bounding box of the model, I added such a condition to all MDL files used in the scenery project (with a new batch functionality I added to MDL Tweaker as well). After some tweaking to get the correct threshold value for the resolution, this resulted in a nice increase of the performance of the scenery.

I will probably release the updated version of MDL Tweaker soon as well. I just want to check some other bugs and features that are on my todo list at the moment. But I think support of the IFSIZEV and IFSIZEH functions are welcome to other designers as well.
 

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.