The functionality in ModelConverterX to create lower level of detail versions of a model was running very slow for complex objects. I have not fixed that completely (yet), but I have made some changes to this functionality that should at least make it easier to work with. The calculation that simplifies the object is now running on a different thread, so that at least the rest of the tool should remain more responsive. I have also added a progress bar, so that you can see how far in the simplification process the tool is already. See the screenshot of the new dialog below.
As you might see there are some more changes. I have removed the 3D preview from the LOD Creator dialog. Instead the mean 3D preview is used now to display the result of the LOD Creator dialog. You can still select the LOD you want to see from the LOD Creator dialog though.
Optimizing the simplication code further, so that it will run faster is still on my todo list. But at the moment I am also busy with preparing for the new gPoly ground polygon tool. So I am not sure which one will get my attention first. Now that I am talking about the gPoly tool, I would still be happy to receive your input on what you would like to see in a tool for custom ground polygons.
I have just fixed some bugs in the 3DS exporter of ModelConverterX. The main issue solved is that complex objects often could not be imported into GMax. Without going into too much technical details, this was caused by some variables being stored as a short, allowing a maximum value of 65535. Some object parts had more triangles or vertices than this limit and that resulted in the error when importing. This has now be been fixed and those model parts will be split when exporting.
Another improvement I made to the 3DS exporter is that the night textures and bump textures are now also written to the material when exporting.
For future improvement of the 3DS exporter I still have the wish to add animations as well, but that is a little lower on the priority list at the moment. And another 3DS related wish is to have an importer for the 3DS format as well.
As I posted before, I am planning for a new ground polygon tool. To get more clear how potential end users, yes that is YOU, would prefer to make ground polygons I have setup a poll at the FSDeveloper forum. So please let me know what your ideal way to add ground polygons to a scenery would be. That will help me in creating a tool that is easy to use. I hope to see your vote!
You could say that recently unions have played a role in my life. First there has been my wedding one and a half week ago of course, forming a nice union between me and my wife. But that is not what I want to talk about in this blog post.
I have also been working on some code that allows me to do boolean operations between polygons. This functionality is something that will come in handy when I start working on my new ground polygon tool, It can for example be used to automatically slice the polygons into piece of no more than 100 meters, so that there are no problems with the curvation of the earth within FSX.
Below you see a screenshot of my test application, where I am testing out these boolean functions. The red polygon is polygon A and the green one is polygon B. The four small pictures below show in grey the union of A and B, the intersection of A and B, polygon A minus B and polygon B minus A respectively.
At first I looked around for some library that implements this functionality and although some exist, I still decided to code it myself in the end. The main reason for that was that I wanted to understand how the process works and that why learn a bit more from it (although it might not always be the easiest way). So in the end I used the algorithms described in Geometric tools for computer graphics and make my own implementation, building further onto for example the polygon class I had already made for ModelConverterX.
The boolean operations are not completely bug free yet, I have already found a few polygons that are not processed correctly. So there is still some more work to do and after that I will start with creating the tool for ground polygons that can make use of this logic. So I still have much more fun ahead…
For a while I am thinking about a new tool that will help in the creation of ground polygons, for the moment this tool will have the working name of gPoly. I have now setup a forum at FSDeveloper to discuss the requirements for such a tool. So I would like to invite other developers to provide their inputs and thereby help in shaping this new tool. I for example would love to hear what you see as the biggest issues currently while making ground polygons for your scenery and how you would like a tool to ease the process for you. So let me know what you think…
Yesterday Jon Masterson (scruffyduck for the FSDeveloper forum members) has released a new version of Airport Design Editor. The main new feature is that the tool now also support FS2004 airport XML files. I think it is good news that this program can now be used for FS2004 and FSX design. So I would advice everybody to try this new version.
I have added another new feature to ModelConverterX that was on my wishlist for a while already, this is the feature to generate a HTML report of the objects loaded. This can be good for reference or to know which files are used and should be included in your distribution. For more details see this forum post.
I am considering to generate such reports for all the default object libraries in FSX as well, that would be a good reference of the objects that are available. These could then be hosted on FSDeveloper.
I have made some changes to ModelConverterX that should make it easier to tweak or analyze models. The changes are that some of the forms are no longer modal and that you can highlight the selected material in the preview. For all details, please see this forum post.
Today I have been working a bit more on ModelConverterX. More specific on reading attachpoints for FS2004 scenery MDL files (for FSX files it was working already). While doing so I also took at a look at attached library objects, since their code is relatively similar I was able to add support for that type of attachpoint as well. So now the FS2004 and FSX MDL readers can both read attached effects and library objects. I have also updated the Wiki pages describing the MDL format with the new information I learned.
In the remainder of this week I plan to work on some other open issues for ModelConverterX, including the FSDS FSC format importer and exporter.
One of the features on the ModelConverterX wishlist is adding support for writing FSDS FSC files. I can now say that I started working on this. I got a SDK from Louis Sinclair, the author of FSDS, that explains how the file format works. To get more used to the format I decided to first make a reader that can import FSC files. The current development release has an initial version of this reader included already. It should read the geometry correctly, but I am still working on animations and other advanced features. I think I’ll also need some more test files to test the reader on those aspects. After the reader is done, I will start with the writer.
That I started on this FSDS support does not mean that the FS2004 MDL reader is completely done, I still have to look at the attachpoints and figure out a way to deal with the conditions and LODs. These issues are still high on my todo list as well and if there is feedback on how the FS2004 MDL reader works with your animations I would also like to now.