sdk:intro
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
sdk:intro [2017/01/16 11:30] – aerofly | sdk:intro [2022/07/07 09:39] – jh | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | Aerofly FS 2 Flight Simulator | + | ====== |
- | Software Development Kit (SDK) | + | |
- | Version | + | Version |
- | ===== Introduction | + | ==== **NOTE** - This SDK is not yet updated for Aerofly FS 4 ==== |
- | ==== Content overview | + | ==== **NOTE** - This SDK is not yet updated for Aerofly FS 4 ==== |
- | The Aerofly FS 2 Flight Simulator Software Development Kit (SDK) consists of several different programs and libraries that are required by external developers to create additional content for Aerofly FS 2. | + | ==== **NOTE** - This SDK is not yet updated |
- | This SDK includes: | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | *The ' | + | |
- | *The ' | + | |
- | ===== Requirements ===== | + | ** Important update for latest |
- | Operating System: | + | |
- | | + | |
- | One of the following modeling tools: | + | |
- | *Autodesk 3D Studio Max 2010, 2012, 2013, 2014 or 2016 | + | |
- | *Maxon Cinema 4D Version 17 | + | |
- | UNICODE capable text editor, e.g.: | + | |
- | *EditPad Pro | + | |
- | *UltraEdit | + | |
- | | + | |
- | | + | |
- | ====== Plugins For 3D Studio Max and Cinema 4D ====== | + | If you have installed a previous version of our Aerofly FS 2 Content Converter |
- | ===== Description ===== | + | |
- | The SDK provides export plugins for 3D Studio Max and Cinema 4D. Those plugins export | + | |
- | The structure | + | |
- | ===== Installation | + | ===== Getting the SDK ===== |
- | Installing the export plugins should simply be a case of following the usual plugin-installation-procedures for your modeling software, copying the plugins into the respective plugin-folder of the target modeling software. | + | |
- | *In 3D Studio Max select Customize > Configure System Paths > 3rd party plugins and add a file path reference to the 3D Studio Max export plugin file\\ ' | + | |
- | *For Maxon Cinema 4D copy the file ' | + | |
- | ====== Aerofly FS 2 Content Converter ====== | + | Please visit our [[https://www.aerofly.com/ |
- | ===== Description ===== | + | |
- | The Aerofly FS 2 Content Converter can do several operations to generate files compatible with the Aerofly FS 2 Flight Simulator: | + | |
- | - Convert intermediate | + | |
- | - Convert .wav sound files to .tsb sound files for the Aerofly FS 2 engine. | + | |
- | ===== Installation ===== | + | * [[https:// |
- | For the installation of the Aerofly FS 2 Content Converter simply start the setup program ' | + | * [[https:// |
+ | * [[https:// | ||
+ | * [[https:// | ||
- | ====== Scenery Workshop ====== | + | **SDK Requirements** |
- | ===== Kingman Example Airport ===== | + | * 64 Bit version |
- | To get a better idea on how the whole process | + | * E-mail account to register in the IPACS forum and download |
+ | * UNICODE capable text editor, e.g.: | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * [[https:// | ||
+ | * Windows Wordpad | ||
+ | * If you want to create own 3D models: | ||
+ | * 3D Studio Max 2010 or higher, | ||
+ | * Maxon Cinema 4D Version 17, or | ||
+ | * AutoCAD (AC3D) 3D Version 8 | ||
- | ===== Scenery Definition File (.tsc) | + | ===== SDK Tools Overview |
- | The .tsc is a simple text file that defines the type of scenery object, its 3d model origin on the globe, elevation and use of auto height, its name as short and long version, description text and specific to airports: ICAO code identifier, parking positions, runway endpoints and threshold points, runway width and its approach light system, tower view position and more. We will address some of these features later on in this workshop. | + | |
- | Changing the .tsc file can be done in two different | + | The Aerofly FS 2 Flight Simulator Software Development Kit (SDK) consists of several |
- | *Manually editing the .tsc file with a UNICODE capable text editor. | + | This SDK includes: |
- | *Using the convenient export options of the exporter | + | * Export |
+ | * Installer for the Aerofly FS 2 Content Converter used to create 3D scenery objects | ||
+ | * Installer for the Aerofly FS 2 Aircraft Converter for creating your own airplane | ||
+ | * GeoConvert tool to bring your own aerial images into Aerofly FS 2 | ||
+ | * The ' | ||
- | ===== Scenery Object Classes Overview | + | ===== Export Plugins For 3D Studio Max, Cinema 4D and AC3D ===== |
- | The Aerofly FS 2 engine supports the following scenery classes. A more detailed description will be given further down. | + | |
- | *ground (runways, taxiways, aprons) | + | |
- | *decals (runway and taxiway lines) | + | |
- | *objects (buildings and static vehicles) | + | |
- | *alpha to coverage (billboard trees, vegetation) | + | |
- | ===== Exporting an Airport ===== | + | The SDK provides |
- | Go ahead and open the airport 3D model file in 3D Studio Max or Cinema 4D, whichever is preferred. Then the runway, decals, objects and alpha-to-coverage (atc) object have to be exported one after the other. When one of these is changed in the future, only the affected objects will need to be exported again. Running the Content Converter will update the results afterward. | + | The structure |
- | To export | + | |
- | - Select the object ' | + | |
- | - In 3D Studio Max select ' | + | |
- | - In the save-file-dialog browse to the folder ' | + | |
- | - Edit the filename to ' | + | |
- | - Finally, click save to start the export process.\\ | + | |
- | - In 3D Studio Max pick ' | + | |
- | + | ||
- | To export the runway markings and taxiway lines (decals 3D objects) repeat the same process but this time select the object ' | + | |
- | + | ||
- | Next, the remaining objects like houses, static vehicles and so on are exported by selecting the ' | + | |
- | + | ||
- | Follow the same pattern to export the alpha to coverage %%' | + | |
- | + | ||
- | Finally the airport description file (.tsc) has to be created. Select all helper objects in 3D Studio Max or null-objects in Cinema 4D and export them into the same project folder as before by using the file extension | + | |
- | + | ||
- | You now have all required intermediate files to start the conversion to Aerofly FS 2 using the Aerofly FS 2 Content Converter. | + | |
- | + | ||
- | ===== Notes using the Content Converter ===== | + | |
- | Before the Aerofly FS 2 Content Converter can be started, several conditions have to be met. Otherwise the Content Converter throws an error and does not proceed. | + | |
- | *The input and output folders have to be set to valid file paths that fit the specific folder structure of your machine. To configure these paths edit the ' | + | |
- | *All files referenced by the 3D model file have to be in the input folder. | + | |
- | *They have to be ' | + | |
- | *Files that don't belong to the project, especially unused images can cause the Content Converter to fail. If an areal image was used as a positioning guidance it must not be contained in the same folder as the 3D model. Such files can be put into a sub-directory or somewhere else. | + | |
- | *All 3D models referenced in the airport .tsc file must have been exported as .tgi files beforehand. For the Kingman airport those are ' | + | |
- | *The .tsc file has to be contained within the project folder. | + | |
- | *The Content Converter only updates the output files if the intermediate files are newer than the already converted output files. | + | |
- | + | ||
- | ===== Starting the converter ===== | + | |
- | When the above conditions are met the Aerofly FS 2 Content Converter can be executed. | + | |
- | + | ||
- | Within a project folder right click on the file ' | + | |
- | + | ||
- | ===== Coordinate System ===== | + | |
- | The entire airport is modeled in a local coordinate system whose origin is moved to the longitude and latitude or web-mercator coordinates defined in the .tsc file when the airport is loaded in the simulator. | + | |
- | + | ||
- | The x-axis of the modeling coordinate system points towards east; the y-axis is geographic north and the z-direction is defined up from the earth' | + | |
- | + | ||
- | ===== Elevation and Auto-Height ===== | + | |
- | There are two different approaches to defining the aiport' | + | |
- | 'auto height' | + | |
- | + | ||
- | *Auto height ' | + | |
- | *When using the manual mode the entire ground mesh, runway and objects | + | |
- | + | ||
- | ===== Model Scaling ===== | + | |
- | Scenery objects have to be scaled to fit web-mercator units. Close to the location defined in the .tsc file one web-mercator unit still equals one modeling unit but further away from the equator objects theoretically need to be bigger. For most airports sizes the effect is minimal and they can be modelled at a 1:1 scale with very little length error at the furthest point away from the .tsc reference point. | + | |
- | + | ||
- | ===== Scenery Object Classes in Detail ===== | + | |
- | We already briefly introduced the different object classes available in the Aerofly FS 2 engine. Now we will look closer into the individual properties of the ground mesh, decals, static objects and alpha-to-coverage objects. | + | |
- | + | ||
- | ==== Ground ==== | + | |
- | === Runways, taxiways, apron === | + | |
- | Usually, the ground mesh is one large joined mesh object that includes the runways, taxiways, aprons and surrounding area and is identified in Cinema 4D with the suffix %%' | + | |
- | + | ||
- | A ground mesh can have different materials assigned that divide the mesh into several material selections. All material selections for the ground mesh must end with %%' | + | |
- | + | ||
- | Seen from above the ground mesh object can have any shape. Experience shows that a rounded island shape creates the best looking results. Using the vertex-color alpha channel in 3D Studio Max or the vertex-weight in Cinema 4D ground textures can be blended into the areal images linearly. Assigning vertex-weight (vertex-color alpha component) of 100% will use only the assigned material, smooth out the terrain elevation data and remove all auto-places trees. 0% will result in a usage of only areal images. This means a vertex-color or vertex weight has to be assigned in order to see any custom textures. | + | |
- | + | ||
- | As the auto height feature changes the height per vertex, a smoother surface can be achieved by creating a denser mesh. | + | |
- | + | ||
- | === Ground materials === | + | |
- | The materials for the ground mesh must have at least one UV-color texture assigned. Multiple UV-color maps are possible to reduce visual patterns created by the texture tiling. The default Aerofly FS 2 airports use two different UV-color textures with a 40m tiling color texture and 1200m variation ' | + | |
- | + | ||
- | Summary: | + | |
- | *_color texture is a mandatory RGB, 8bit per color channel color map for the diffuse shader color. | + | |
- | *_bump texture is an optional gray 8bit RGB height map for optical surface height variations which will be converted to a .tsn normal map by the Content Converter. | + | |
- | *_specular is optionally used by the shader to create to create a soft gloss effect. It can have an alpha channel in addition to the three 8bit RGB color channels but doesn' | + | |
- | *_specular_alpha is an optional 8bit RGB texture that overwrites the specular map's alpha channel with its calculated RGB brightness and controls the width of the specular reflection spot. The Aerofly FS 2 Content Converter will merge the _specular_alpha texture | + | |
- | + | ||
- | ==== Decals ==== | + | |
- | === Runway markings, taxiway lines === | + | |
- | As decals we understand lines and markings on the ground that are usually painted onto the surface in the real world and require a higher level of detail than the ground itself. In the Aerofly FS 2 engine decals are rendered with a dynamic height offset over ground mesh to prevent z-fighting of the decals and the surface blow. The decal objects themselves must have a priority suffix at the end of their name, e.g. %%' | + | |
- | + | ||
- | A decal object consists of several flat polygons and can have multiple materials assigned to it. Like the ground mesh, the elevation of decals is adjusted per vertex by the engine if the auto-height feature is selected. For very high curvature in taxiways or runways due to large changes in elevation, the decals should be cut along the edges of the ground mesh polygons below to follow the curved terrain better. | + | |
- | + | ||
- | === Decal materials === | + | |
- | Materials for the decals and markings must have a UV color map. The texture must have the extension _color and use three 8bit RGB color channels. Optionally an 8bit alpha channel can be used. | + | |
- | + | ||
- | ==== Objects ==== | + | |
- | === Buildings, vehicles === | + | |
- | Houses, static vehicles and so on are created as individual polygon objects that also can have multiple materials assigned to them. When auto height is enabled, the Aerofly engine will offset the origin of each of these objects by the elevation information at that their origin. Because the terrain could be sloped it is recommended to have the base of the houses at an elevation slightly below zero in the modeling software to prevent floating above the ground. All objects are exported together as one %%' | + | |
- | + | ||
- | === Object materials === | + | |
- | One of two combinations are possible for materials used for objects:\\ | + | |
- | - _color (mandatory), | + | |
- | - _color (mandatory), | + | |
- | The mandatory diffuse color texture must end with _color and have the three 8bit RGB colors and an optional 8bit alpha channel for transparent windows as an example. | + | |
- | + | ||
- | Reflection textures are 8bit RGB-textures and must end with _reflection. Bright colors create higher reflectivity. | + | |
- | + | ||
- | Specular maps are used for non-reflective but shiny objects like metal surfaces. They are identified by the suffix _specular. The three 8bit RGB components describe the reflectivity of each of the colors and an optional 8bit alpha channel changes the specular spot size. Optionally an 8bit RGB _specular_alpha texture can be used to overwrite the alpha channel of the output _specular texture. | + | |
- | + | ||
- | Light maps with the suffix _light can be used for light emitting things like windows at night. The three 8bit RGB colors are available. | + | |
- | + | ||
- | ==== Alpha-to-coverage ==== | + | |
- | === Vegetation and others === | + | |
- | Billboard trees or flat grass planes that consist of only very few intersecting polygons fall into this category. The Aerofly FS 2 engine uses different techniques to render their transparency quicker which makes this category the best choice for large sets of partly transparent objects that are not very important. | + | |
- | + | ||
- | === Object materials === | + | |
- | The mandatory diffuse color texture must end with _color and usually is a single texture with three 8bit color and an 8bit alpha component. | + | |
- | + | ||
- | ===== Guidelines for creating or porting own scenery objects ===== | + | |
- | - Create a new project folder where all textures and the 3D model will be stored.\\ The Aerofly convention for naming airports is icao_airport_name e.g. ' | + | |
- | - Start 3D Studio Max or Cinema 4D and insert a background reference image that covers scenery region sufficiently. Save the project with the same name as the newly created project folder. | + | |
- | - Paste all textures into the project folder and rename them following the same naming rules as above. Refresh the texture assignments in the modeling software if necessary.\\ | + | |
- | - Scale the entire scene to 1:1 by using ground reference points on the background image that are easy to identify. Vast scenery projects should probably be split into multiple regions if they are not using web-mercator coordinates to avoid wrong scaling at great distances.\\ | + | |
- | - Copy the dummy- or null-objects from our example airport and adjust the names, ICAO identifier, etc. or copy the .tsc of the example airport to the project folder and set the fields manually.\\ | + | |
- | - Decide on an airport reference point on the background image and write its coordinates (lon. lat. or web-mercator) into the dummy- or null-object for the airport location or into the .tsc file manually.\\ | + | |
- | - Create one ground object that is one joined mesh. | + | |
- | + | ||
- | *3D Studio Max specific: The materials for ground objects should follow the following naming conventions: | + | |
- | *Cinema 4D specific: All material selections assigned to the ground objects must have the %%' | + | |
- | + | ||
- | - Continue with decals, add the suffix ' | + | |
- | - Use helper objects to set the coordinates of all runway endpoints and their threshold points. The threshold points will affect the positioning of the selected approach lighting system. | + | |
- | + | ||
- | ====== Aerofly FS 2 Aircraft Converter ====== | + | |
- | ===== Description ===== | + | |
- | The Aerofly FS 2 Aircraft Converter converts all files needed from an intermediate | + | |
- | + | ||
- | ===== Installation ===== | + | |
- | Install the Aerofly FS 2 Aircraft Converter by starting the setup program ' | + | |
- | + | ||
- | ====== Aerofly FS 2 Aircraft ====== | + | |
- | ===== Robin DR400 Example Aircraft ===== | + | |
- | This SDK comes with an example aircraft including all source files and intermediate files to demonstrate how to get a new aircraft into Aerofly FS 2 using the Aerofly FS 2 Aircraft Converter. | + | |
- | + | ||
- | Please note that even though these files are included with the aircraft converter for free, the files are copyrighted and may not be used for any other purpose than demonstrating how to create an aircraft for Aerofly FS 2. | + | |
- | + | ||
- | \\ The following steps describe how to do the conversion before we go to the details of creating a new aircraft: | + | |
- | - Install the Aerofly FS 2 Aircraft Converter as described above. | + | |
- | - Locate the ' | + | |
- | - Click the Convert button to start the conversion. The aircraft converter will copy the dynamics and configuration files to the user folder of Aerofly FS 2, convert the sounds, the 3d model and the textures, and will render the preview texture if necessary. Depending on your hardware, this may take a while. | + | |
- | - When the aircraft converter has converted the example aircraft, start Aerofly FS 2. The Robin DR400 should be available in the aircraft menu now. Enjoy your new aircraft. | + | |
- | + | ||
- | The template folder contains template files for your project. In addition to that, we have added a simple box geometry so that the template folder can be converted in the same way. This creates a minimal ' | + | |
- | + | ||
- | ===== Introduction ===== | + | |
- | This section gives a brief overview of how Aerofly FS 2 simulates an aircraft, the units and coordinates systems and the different file types that are used by Aerofly FS 2 and the Aircraft Converter. | + | |
- | + | ||
- | ==== Simulation ==== | + | |
- | Aerofly FS 2 uses an object-based approach to simulate an aircraft for maximum flexibility. This means that each aircraft is defined in terms of many objects (also called (function) blocks or elements in commercial general purpose simulation packages), instead of a fixed set of variables that every aircraft must use. In addition to very general objects that can be used for any type of simulation, there are many objects specialized for flight simulation like aerodynamics forces, engines and propellers, avionics objects and many more. The designer of the aircraft is free to add any number of objects and connections to an aircraft by adding it to the dynamics section of the aircraft' | + | |
- | + | ||
- | Please refer to the ' | + | |
- | + | ||
- | ==== Units and Coordinate Systems ==== | + | |
- | Aerofly FS 2 uses the international system of units (SI) exclusively. This means that all lengths and dimensions are meters, masses are in kilograms, forces are in Newtons, power values are in Watts, speeds are in meters per second. | + | |
- | Any rotation uses the positive mathematical direction (anti-clockwise), | + | |
- | Fractions are used instead of percentages (20% would be written as 0.2). | + | |
- | The coordinate system the entire aircraft is defined in is set in the 3D model of the aircraft. The origin is usually placed close to the center of gravity but does not have to be. The direction of flight defines the x-axis of the aircraft' | + | |
- | The y-axis points towards the left of the aircraft, the z-axis points straight up. One unit in the coordinate system represents a real world length of one meter. The 3D model may use a scale factor which is removed when the aircraft is exported. | + | |
- | + | ||
- | ==== File Types ==== | + | |
- | An aircraft in Aerofly FS 2 is defined by the files contained in one folder. The folder' | + | |
- | + | ||
- | | Intermediate folder | Aerofly FS 2 aircraft folder | Description | | + | |
- | | | | | | + | |
- | | xxxx.tgi | | Binary 3D model file created | + | |
- | | | xxxx.tmb | Binary 3D model that contains information like the vertex positions, texture coordinates, | + | |
- | | xxxx.tmc | xxxx.tmc | Description file of the aircraft that contains the text shown in the aircraft menu together with the preview image. Also contains parameters to change the initialization of the aircraft: the orientation how the aircraft | + | |
- | | xxxx.tmd | xxxx.tmd | Defines camera positions, the complete physics definition | + | |
- | | xxxx_takeoff.tmd xxxx_clean.tmd xxxx_landing.tmd | xxxx_takeoff.tmd xxxx_clean.tmd xxxx_landing.tmd | Used to set certain dynamics parameters that should be different from the standard values in the ' | + | |
- | | controls.tmd | | Defines positions and sizes where interaction with the mouse or VR controllers is possible. | | + | |
- | | .bmp .tif .png | | Source texture files. Must be square power-of-two bitmaps. BMPs 24 bit RGB only. TIF and PNG RGB or RGBA. Bump maps can use 16 / 48 bit to avoid terracing. | | + | |
- | | | .ttx | Converted and compressed texture files | | + | |
- | | preview_xxxx.png | | Preview file rendered by the converter | | + | |
- | | | preview.ttx | Compressed preview texture for aircraft menu | | + | |
- | | repaint.tmr | repaint.tmr | Repaint or livery description file defining the repaint' | + | |
- | | .wav | | Source sound file. Must be PCM 22050 Hz mono | | + | |
- | | | .tsb | Converted sound files that are created from .wav files by the converter tool. | | + | |
- | | model.tmc | | Configuration file for aircraft conversion. Used to set non-default values for texture sizes, bump map strength and texture parameters if necessary. | | + | |
- | + | ||
- | The ' | + | |
- | + | ||
- | ==== Limitations ==== | + | |
- | The Aircraft Converter that comes with this SDK is the same tool we use to convert aircraft. There are no limitations on objects or functions you can use to create your aircraft. | + | |
- | + | ||
- | However, the SDK doesn' | + | |
- | + | ||
- | ===== Creating an Aircraft for Aerofly FS 2 ===== | + | |
- | + | ||
- | ==== Overview ==== | + | |
- | + | ||
- | This overview shows the necessary steps to get an aircraft model from a 3D design | + | |
- | + | ||
- | Steps 1. to 6. have already been done for the example aircraft that comes with this SDK so that you can start with step 7. right away and use the example aircraft as a reference for your projects. | + | |
- | + | ||
- | - Create a new folder using lowercase letters a-z, digits 0-9 and the underscore only (like c172, b747, f4u, mustang, …). This folder will be referred to as the intermediate folder. The name of this folder will be the internal name of the aircraft (the name displayed in the aircraft menu can be set later) and determines the names of several files. In the following, we will choose the name to be xxxx. | + | |
- | - Copy and/ | + | |
- | - Prepare the 3D model as described below. | + | |
- | - Export the 3d model to the intermediate folder using the filename xxxx (this creates the ' | + | |
- | - Create the aircraft definition and configuration files. You can create these files from scratch using the section ' | + | |
- | - Add the ' | + | |
- | - Run the aircraft converter. Right click on the ' | + | |
- | - 8.Your new aircraft is available in Aerofly FS 2 now. Test and refine the dynamics, graphics and sounds as desired. | + | |
- | + | ||
- | ==== Preparing the 3D Model ==== | + | |
- | To achieve an error free export some preparation is needed to be done first. For the DR400 example aircraft all these steps have already been completed so that this plane can be used as a reference. | + | |
- | + | ||
- | === Single 3D Model === | + | |
- | Aerofly FS 2 works with just one 3D for an entire aircraft; there is no need to provide an external and internal model separately. The Aerofly FS 2 engine is optimized to draw only those objects that are in the view of the camera. | + | |
- | + | ||
- | === Generic Modeling Units === | + | |
- | The units of the aircraft model should be set to ' | + | |
- | + | ||
- | === Alignment and coordinate system === | + | |
- | The aircraft should be aligned to the x-axis as the forward flight direction, the positive y-axis towards the left and the positive z-axis pointing upwards. The origin of the model coordinate system should be placed close to the center of gravity. | + | |
- | + | ||
- | Animated objects should have their axis and rotation pivots set to a plausible location. Hinged objects should have their local origin in their hinge location. The pivots and axes set in 3D Studio Max will be exported to the log files which will be used later on to animate the objects in the graphics section of the .tmd file. | + | |
- | + | ||
- | Animated objects should be positioned in the following neutral positions before export: | + | |
- | *control surfaces neutral, flaps up | + | |
- | *gear down and compressed as if the aircraft would stay on the ground | + | |
- | *gear doors closed to assure perfect alignment when the gear is retracted in flight | + | |
- | *cabin doors and windows closed | + | |
- | *knobs and switches that are not planned to be animated should be in an in-flight position | + | |
- | *switches and knobs that will be animated are best exported in their off state | + | |
- | *instrument needles point to zero or neutral depending on the instrument | + | |
- | *magnetic compass points towards 090 degrees (East). This is needed because the x-axis of the global coordinate system of the Aerofly FS 2 points towards the East as well. | + | |
- | + | ||
- | === Individual objects === | + | |
- | All animated objects like the control surfaces (rudder, aileron, elevator) and trim rudders, switches and knobs, gear parts and so on have to be individual objects in the 3D model so that they can be animated independently from each other. The Aerofly FS 2 rendering engine is optimized to merge objects in the same GeometryList when the aircraft is loaded, so there is no real benefit combining objects. Experience has shown that development time can be reduced if all switches and knobs are available as individual objects right away and the model doesn' | + | |
- | + | ||
- | Display screens have to be separate objects so you can set the display brightness independently of the background lighting later. | + | |
- | + | ||
- | === Object naming conventions === | + | |
- | 3D objects will be referenced by their name for display and animations, so it is essential that each object has a unique name. Objects should be named logically, and the name must not contain spaces or special characters (it is recommended to use A-Z, a-z, 0-9 only). While the object names have no meaning to the simulation, it is easier for everyone working on the project to use standardized names. We use the ' | + | |
- | + | ||
- | Advisable names are e.g.:\\ Fuselage, LeftWing, LeftAileron, | + | |
- | + | ||
- | === Materials === | + | |
- | Materials are defined by the set of textures they use and by tags or hints that describe the intended usage. A simple material just needs a diffuse texture, but Aerofly FS 2 also supports ambient, specular, bump/ | + | |
- | *Diffuse: diffuse color. An optional grayscale ' | + | |
- | *Ambient: ambient color. This is a separate grayscale RGB map. | + | |
- | *Bump: bump map if texture name ends with ' | + | |
- | *Specular: specular highlight color and strength. Color and strength are given by RGB values of the texture, specular highlight width is controlled by the alpha channel | + | |
- | *Reflection: | + | |
- | *Self-Illumination: | + | |
- | *Filter Color: illumination. RGB channels encode the illumination strength/ | + | |
- | + | ||
- | We use the suffixes ' | + | |
- | + | ||
- | === Textures === | + | |
- | All textures must be square power-of-two images with a pixel depth of 24-bit RGB .bmp, 24/32-bit .png or .tif files. Bump maps can be 16-bit grayscale textures. There is no support for .psd files in the converter, the different layers for diffuse, ambient, .. have to be exported to the intermediate folder first. You can keep a .psd file assigned to a texture slot in the 3D software if it has the name as the bitmap file except | + | |
- | + | ||
- | It is recommended to create all textures at a resolution of 4096x4096 or even 8192x8192 pixels, and use the appropriate converter setting to reduce the actual size used in the simulator. The smallest size recommended is 32x32 pixels, the maximum supported texture resolution by the engine is currently 4096x4096px. The total compressed texture amount should be in the range of 150 MB to ensure compatibility with all platforms. The final texture resolution can be set in the ' | + | |
- | + | ||
- | === Refresh Texture assignments === | + | |
- | If necessary, refresh the texture assignments in the 3D modeling software to use the exported textures in the intermediate folder. Again, you can keep a .psd file assigned to a texture slot in the 3D software if it has the name as the bitmap file except for the suffix. The converter | + | |
- | + | ||
- | === Material Tags or Hints === | + | |
- | Each material can define tags or shader hints to support the selection of the best shader when the aircraft is loaded. Shader hints can be combined to describe the material properties as precise as possible. Currently, the following shader hints are supported: | + | |
- | + | ||
- | | exterior | everything that is not in the cockpit/ | + | |
- | | interior | everything that is in the cockpit and cabin, inside of windows and canopy | | + | |
- | | default | | | + | |
- | | standard | | | + | |
- | | glass | | | + | |
- | | canopy | | | + | |
- | | window | | | + | |
- | | instrument | | | + | |
- | | darken | | | + | |
- | + | ||
- | The hint can be added to a material in 3D Studio Max as follows: | + | |
- | + | ||
- | | + | |
- | - Open ' | + | |
- | - Select 'Add to Type' -> ' | + | |
- | - Select ' | + | |
- | - Enter ' | + | |
- | - Click the ' |