OpenFlight reader

I have a list of feature requests for ModelConverterX, some items on this list have a higher priority than others. But as it goes with priorities they sometimes suddenly change a bit. For example I was planning to finish the Ground Polygon Wizard first, by adding support for seasonal textures. But some activities at work meant that the OpenFlight reader, which was almost at the bottom of the list, suddenly got more priority.

So this weekend I started to implement this new reader for ModelConverterX. At the moment I have the basics working, as you can see in the picture below. But this new reader is not yet available in the development release, that’s because I want to test it with more OpenFlight files first. At the moment it works best with OpenFlight files that ModelConverterX created itself. Obviously that is a nice start, but not enough for a functional reader.

So what could you do with this new reader once it is done? You could import OpenFlight files and convert them to FS MDL files. If you are transferring 3D models from another simulation system that uses OpenFlight that might be useful. This is probably mainly interesting for people who are using ESP or Prepar3D for professional purposes.

Hopefully tomorrow I can test this reader with some more objects and once it is robust enough I will make it available in the development release. I’ll keep you informed about the progress.

Creating ground polygons for FSX with SketchUp

Over the last days I have been working on the Amsterdam Heliport for the NL2000 scenery. One of the tasks I did was to update the ground polygons of this scenery. Instead of using GMax for this, I decided to give SketchUp a try. In this blog post I will give an overview of my experiences.

Pros

  • If you use the SketchUp feature to load a background image from Google Earth it is easier to position your ground polygons at the right location in the world.
  • When you draw another polygon in SketchUp that is on top of an existing polygon, the new polygon is automatically cut out of the other one. So this means you need to use less layers in the end, since there are less polygons on top of each other. On the other hand, if you are using transparent textures and what two polygons in the end this can also be a negative feature.
  • I still find it more fun to model in SketchUp than in GMax, it just seems easier.

Cons

  • Mapping the textures is less convenient in SketchUp, especially since you can not alter the mapping of multiple polygons at the same time. So making sure the textures were mapped as I wanted took me more time than I wanted.

Conclusions

So if we balance the pros and cons, where do we end up? I am not sure yet if I prefer GMax or SketchUp for my ground polygons. At the moment I would say it is still 50 – 50. I guess I will have to do another test project to really find out. Maybe one with more markings and other features, to see how that works out.

Ground Polygon Wizard: shadow bug – a partial fix

In the next development release of ModelConverterX the ground polygon wizard as a new option: Prevent autogen suppresion. When you check this option the file will have the tweak to keep your autogen around the airport. However there is a bug in this tweak that it will result in flickering shadows. So if your shadows are important you better not select this option.

This is just a partial fix of the problem of course, I will continue searching for a few to have both the shadows and the autogen. But at least you have a choice now which feature is more important for your project.

Ground Polygon Wizard and non ground polygons

A user reported that the ground polygon wizard of ModelConverterX lost some of his polygons while converting them. When I was debugging this issue, I found out that this was because the polygons were not actually on the ground. They were a few centimeters above the ground. The code that makes sure the polygons are sliced correctly for FSX can’t handle such polygons correctly. That’s why some of them got lost.

So to fix such trouble I have made two small changes to the ground polygon wizard. The first is that you get a warning when your model contains such polygons. The second is that there is an additional button now, which when pressed will ensure that all ground polygons are lowered back to ground level.

Hopefully with these changes the ground polygon wizard works correctly in more cases. But let me know if you encounter more issues.

 

 

Autogen suppression

In the previous post about the ground polygon wizard of ModelConverterX I already mentioned that the tool also helps to prevent the exclusion of autogen by your  ground polygons. I forgot to post some screenshots to illustrate this with that post, so here they are.

They show Gilze Rijen airport in the Netherlands as developed by the NL2000 team. And you can clearly see what the benefit is of having autogen on the airport as well.

Ground Polygon Wizard available

I have just released a new version of ModelConverterX. The big change in this new release is that the ground polygon wizard is now included. Before I will go into the details of how to use this wizard, let’s first take a look at the problems it is trying to solve.

When creating ground polygons scenery designers usually encounter these problems:

 

  • You need the FS2002 gamepack, since that is still the preferred way to create ground polygons. Some of the files of the gamepack are only on the FS2002 Pro disks, which means you have to find all kind of work arounds if you don’t have FS2002. And of course not every designer is making scenery since the days of FS2002 already.
  • When you have the FS2002 gamepack and you have exported your ground polygons, you still need to edit the ASM source files. Else the ground polygons will flicker and will not show shadows correctly.
  • After you have finally got your ground polygons into FS you will see that big parts of the autogen around your scenery are gone.

 

The ground polygon wizard of ModelConverterX tries to help with these problems. I am not trying to say it is the magic solution that solves all your ground polygon problems, but hopefully it helps you.

With the wizard you can load your ground polygons from any file format that ModelConverterX can read, for example FSX MDL or COLLADA files. After you specify the options you want, the wizard will create a BGL file with ground polygons that behave like proper ground polygons.

Before using this functionality, make sure that you the path to SCASM specified in your options. The wizard is using SCASM to create the BGL file. Don’t worry if you think SCASM is old, the code generated for the BGL is the same as the FS2002 gamepack would.

So now let me explain which options the wizard has and how to use it. At the top of ModelConverterX you see a button called wizards. Use this to open the ground polygon wizard, it will appear as a separate window. It looks like the one shown on the side here (but empty when first loaded). We’ll now walk through all the options.

Select file to convert: here you select the file that contains your ground polygons and that ModelConverterX should load. This can be any format supported by ModelConverterX. Once you have selected a file here it will be loaded in the background and once that is done the object is shown in the preview and the rest of the form is populated.

Select output BGL file: here you select where ModelConverterX should generate the new BGL file with your ground polygons.

Filter out non-ground polygons: This option will remove any polygons from your loaded object that are not on the ground (z coordinate is zero). It will also filter out polygons that are on the ground, but pointing downwards. This ensures only ground polygons are left.

Layering and visibility: the grid shown here shows all materials used in your object. You should be able to recognize the names of the textures you are using. For each texture you specify at which layer you want it to be and what the visibility of that layer is. The visibility is not specified per texture, but per layer. So if you change the visibility of one texture on a layer, all others on the same layer get the same visibility.

Position: here you specify the position of the reference point of the object. If you import a BGL file, the position will already be read from it. When you are exporting to FSX it is also important to specify the altitude of the point you are exporting to, else the polygons might not connect correctly.

Slice polygons into 100 meter sections: this option slices big polygons into smaller section. This is required when you are exporting to FSX, else the ground polygons will not follow the curved earth correctly.

Divide polygons in 500 meter areas: this option divides the polygons into areas of 500 meter and exports them per area. When exporting from GMax all your ground polygons have the same reference point. This means they are all loaded at once and the scenery engine also has to evaluate all of them to see if they need to be drawn. What this option does is group them in areas of 500 x 500 meter. Each of these areas gets their own reference point. FS can not evaluate per area if it needs to be drawn or not. And the visibility is specified from the center of that area. In general this will give you a performance increase, especially when you only have part of the airport in view.

FSX or FS2004: select for which version you are exporting the BGL file. Due to the different earth model it is not possible to use the same BGL in both FSX and FS2004.

Now press the Convert button and wait until the wizard form closes. Your new BGL file should now be ready at the location you specified.

Besides the options you see two small buttons. These can be used to save and load the ground polygons wizard settings. If you are converting the same airport multiple times, this prevents you from entering all the information every time. Just save it once and reload it the next time you convert the object.

I hope this wizard is useful to you and improves the workflow of generating ground polygons. This is the first release of this feature, so please let me know if you have any suggestions or comments. There are some additional features that I have planned already, mainly the option to add night and seasonal textures with the wizard as well.

Leaking memory

Tonight I have been doing some memory leak hunting in ModelConverterX. I have found (and fixed) a few leaks in the 3D preview of the objects. So from the next development release you should see less memory being used, especially when you make changes in the material editor. Also when browsing through object libraries or making an object report you should see less memory usage. I can’t guarantee that all memory leaks are gone, but at least these are fixed.

Ground polygons and autogen

Just before my vacation I already posted about the ground polygons wizard for ModelConverterX. Since then I have been working more on this feature and it is almost ready for inclusion in the development release. This wizard allows you to export your ground polygons without the FS2002 GMax gamepack, ModelConverterX will take care of converting them to the right format to behave as proper ground polygons. At the moment I am doing the last testing and removing some minor bugs.

Parallel to this I am also enhancing the output of the ground polygons wizard to prevent suppression of autogen by these ground polygons. For this I am using one of the airfields of the NL2000 scenery project as a test case, Gilze-Rijen (EHGR). The basic technique to keep the autogen seems to be working, but there are a few bugs left that I need to fix before this can be released as well. So hopefully I will have more news in a couple of days.

FSDeveloper server performance

Over the last weeks there have been some issues with the performance of the FSDeveloper server. Now and then (but quite regularly), the performance of the server is bad. This means that pages load very slow or not at all. We are sorry for this inconvenience and we are looking into this issue. The problem is that every time our hosting company looks at the issue, everything is running fine. So that makes it hard to pin it down. We hope to solve the problem soon though.