Ground Polygon Wizard update and seasonal models

The latest development release contains an updated version of the ground polygon wizard (GPW). The user interface has not changed a lot, but under water a lot has changed. So if you run into small issues with the new GPW, please let me know.

The following changes are included:

  • Before the GPW would set the layer number and other attributes at the level of the texture name. This meant that if you had different materials that used the same texture, the GPW would all give them the same settings. In the new version the GPW settings are set at material level, which means that multiple parts with the same texture can now have a different layer or other setting. This also means that you can see the same texture name mentioned multiple times in the list in the GUI.
  • Before the GPW only supported seasonal texture for FS2004 and FSX output. Now seasonal textures are also supported for P3D v4 and P3D v4.4 output. Below I will explain more how the seasonal textures are supported.

So how does MCX support the seasonal textures? This can be done in two ways and the way that is used is selected with the “Use season material script” option in the exporter settings.

  • When this option is set to true, MCX will create a LUA material script that will switch the textures based on the season. The LUA files are saved in the same directory as your BGL or MDL file, so you need to copy them over to your addon. It’s probably easiest to create a local script folder in your addon and load that via the add-on.xml file.
  • When the option is set to false, MCX will use visibility conditions to switch between different model parts that have the seasonal textures on them. The downside of this approach is that your MDL file gets bigger.

You can determine how the seasons need to look in the Season editor. You can select there which seasons are active for your area and in which day of the year each season starts and ends. If you have a heavy winter (with snow) season in your area, you can use winter and winter2 to have a non-snowy winter representation before and after the heavy winter.

In the ObjectModel settings the suffixes that are used for each season are defined. The default values use no suffix for summer, and the logical _SP, _FA, _WI and _HW for the other seasons. But you can change that to your needs.

And the good news is that this functionality to add seasonal textures is not only available in the GPW. You can also use it on a normal model that you export to P3D v4 and above. In the material editor you can set the HasSeasonalTexture option to true and then MCX will create the material script or visibility condition on export of your MDL file. The Season editor can be used to define the seasons again, as this editor can not only be started from the GPW, but also from the toolbar in MCX (it’s just left of the scale object button).

I hope you all enjoy these new functionalities and let me know if you have any issues with it.

scenProc autogen building bug

This week I have fixed a bug in scenProc that could result in autogen buildings showing incorrectly in Prepar3D. This especially affects buildings that are oriented exactly north-south or east-west. They would show with a roof of the correct size, but with the walls too small, like in the image below.

This bug has been in scenProc for many years already, so it will affect autogen files made with scenProc v1, v2 or the latest development release. It has been fixed in the development release of April 20th. So if your addon uses autogen buildings made with scenProc and you target the Prepar3D simulator you can best generate your autogen files again with the latest development release.

FXEditor update

I have just released an updated version of the FXEditor tool. In this new version the following new features are included:

  • In the text editor you can use code folding on emitters, particles and particle attributes. This means that for complex effects you can collapse some of them and thereby navigate easier through the file.
  • There is a Remove emitter button now, which will remove the emitter, particle and particle effect sections of the emitter that the cursor is currently in. This way you can quickly remove an entire emitter.
  • You can now add templates to the FX file. This way you can for example add another emitter more easily. The templates themselves are stored in the FXTemplates folder in FXEditor, so you can add your own if you want. And if there are suggestions to improve the default templates or add more templates, just let me know.
  • I have added an up to date manual to the FXEditor tool as well now.

Prepar3D v5 support

I have just released new development release versions of all my tools with added support for Prepar3D v5. The impact of the new version on most tools is limited. Below I list the details per tool.

Overall the impact on the tool is not that big. But let me know if you encounter any issues or if Prepar3D v5 support is still missing somewhere.

ModelConverterX

There is one new material attribute available for PBR materials in Prepar3D v5. ModelConverterX has been modified to read and write this attribute correctly now. Since the MDL version, as coded in the MDL file itself, still reads PV44, I have decided to not add a new version when you export. So for Prepar3D v5 you would still need to use the v4.4 MDL format. But make sure that you use the Prepar3D v5 SDK to be able to save that one additional attribute.

scenProc

In the scenProc options you can specify the Prepar3D v5 location now, so that it can be used for the auto completion of the autogen configuration details.

FXEditor

FXEditor has been modified so that you can specify that you want to read the textures and sounds from the Prepar3D v5 folder.

Autogen Configuration Merger

For Autogen Confguration Merger I have posted a beta build in the forums that should support Prepar3D v5. But since I don’t have the new version installed myself yet, I haven’t been able to test it. So this is a beta build, that needs some more testing before it is promoted to an official release.

Bug reporting broken

I was quite happy the last few weeks that hardly any crashes were reported in my bug tracker from my tools. But today I found out why, the bug reporting is actually broken at the moment. It seems the interface into the bugtracker does not like the newer PHP version that i had to enable for using the latest version of WordPress for SceneryDesign.org.

So now that I am aware of this issue, I’ll try to fix it. Probably the best way forward is to update the bugtracker software to a newer version that will hopefully give a working interface with my tools for newer PHP versions. So let me try to find some time for that upgrade soon.

Edit: the bug tracker software has been updated now and is running fine again. So you can report bugs from my tools again. Although I hope you don’t do it too often….

Image result for work in progress

Autogen object size distortion

That autogen objects have a distortion in their rotation is something we found out 6 years ago already. But until recently I was not aware that not only the rotation of the objects is distorted, also their sizes can be different then you would expect from looking at the objects in the Annotator tool. I guess most of use work in the zones around N40 and S40, where the distortion is minimal, so it took a developer who works outside of that area to inform me of a bug in scenProc that resulted in objects being rendered in the sim with wrong sizes.

So what I did is make a test photoreal scenery where I burned polygons with a known size in the photoreal. Next I placed autogen objects and tried different settings until I could get them to align correctly for each latitude where the objects are placed.

Below you see a screenshot of this test scenery at a latitude of 60 degrees, where you have quite some distortion already (around 41 degrees latitude the distortion is minimal, due to the way the autogen tile sizes are designed). As you can see for some polygons the rotation is off from what you see in the photoreal, but also the sizes of the objects need to be defined incorrect, to have them show correctly in the simulator. Some of the buildings need to be made longer and more narrow for example.

The good news is that you don’t have to apply this kind of rotation and size corrections by yourself. scenProc has been modified to do it automatically for you now. So with the latest development release you will find that the output generated should align more accurate with your photoreal scenery.

How does it work? In Annotator you are seeing your photoreal shown in a latitude and longitude projection. But the heading of the objects should actually be defined in the AGN file for flat earth projected version of the object. And for the size it is even weirder, the sizes are defined in degrees as if the object has a heading of zero. But even when the object does not have that heading, which means you need to provide an incorrect size in degrees to still get the correct size of your object in the simulator in the end.

And just as the proof of the pudding, below is a screenshot of the test scenery in the simulator, where you see things align well.

New steps to place points

The next development release of scenProc will include two new steps for placing points: LineToPoint and PolygonToPoint. In the future these steps will replace the existing steps to place points along lines or inside polygons. As i realise some of these steps are used in many of your scripts, I will not deprecate the old ones very soon. But for new scripts I encourage you to use the new steps.

Why did I make this change? There are a couple of reasons:

  • When I add the LineToPolygon and PointToPolygon step a while back, the idea was already to have similar steps for other conversions between feature types. So the new LineToPoint and PolygonToPoint steps are in the same philosophy.
  • Until now there were multiple steps to place points along a line or inside a polygon. Each with slightly different characteristics, but also with a lot of overlap. So it is easier to have all this logic in one step.

The manual has been updated to reflect these new steps as well. Both in the description of the steps and in the sample scripts.

Create terrain vector scenery with scenProc

The latest development release of scenProc makes a set of new steps to create terrain vector scenery generally available. This means that you can now use scenProc to make terrain vectors with the shp2vec tool.

The manual contains a sample script that shows you how you can make terrain vectors from OpenStreetMap data, but of course you can also tune this script to use the attributes of your vector data.

You can use this functionality for example to create freeway traffic BGL files for your scenery based on a road vector data.

scenProc 3.0 development release available

I have just made available the new development release version of scenProc. This takes the tool from version 2.0 to version 3.0. This new version has been in development for quite a while already, so it includes many new features. To main improvements are:

  • Polygonal features with holes are supported much better. This means that importing and processing features with holes goes much faster.
  • It is possible to create XML bridges now in scenProc.
  • The texture filter editor has been redesigned completely, so this means that the feature detection is much more powerful now.
  • The scenProc Batch Runner tool has been added, which replaces the old tool to create batch files. This makes it much easier to run a script in batch mode.

And there are many more improvements. I have also updated the entire manual, so please check the manual first if you want to learn about the new features. And else feel free to ask questions in the forum. I hope you enjoy the new version.

scenProc 2.0 stable released!

I have just released a new stable release of scenProc, this new stable release is version 2.0. It has the same functionalities as yesterdays development release. You can find the download links on the scenProc page.

The main reason to release this new stable release now, is that the version 3.0 development release is just around the corner. I hope to have it released in about a week from now. Since version 3.0 includes many changes I thought it would be a good moment to have a new stable release first.