D3D9Client documentation

Requirements

D3D9Client uses external libraries that need support for the SSE2 Instruction set (GPSVC.DLL e.g.) and requires XNA Math support, so that the processor must support those Streaming SIMD Extensions.


Installation

You need a DirectX February 2010 or newer to run D3D9Client. To install the client itself you need to extract the zip package in the root folder of the Orbiter. In order to use a graphics client you need to run "Orbiter_ng.exe" instead of "Orbiter.exe". Also the client must be activated from the Modules tab.


DirectX Runtimes

If the redistributable package isn't installed in your computer you will receive an error message "The program can't start because d3dx9_42.dll is missing from your computer". Or you may see a pop-up window in Orbiter LaunchPad telling about a missing runtimes. If that happens then download and extract the content of the package in any empty directory you want and then find a Setup.exe and run it. You can delete the contents of the directory after the setup is completed. The directory is just a temporary storage for the installation files.

Here is a link: https://www.microsoft.com/en-us/download/details.aspx?id=8109


Orbiter Sound 3.5, Spacecraft3.dll

In order to use Spacecraft3.dll and Orbiter Sound (Version 3.5) with an external graphics client –like D3D9Client is one–, symbolic links in /Modules/Server/ folder must be created.

Note, that for the current version of Orbiter Sound (Version 4.0) the "Sound" link is not necessary anymore. It will not be created via the according Button in D3D9Clients "Advanced Setup" dialog, if D3DClient detects that the loaded Orbiter Sound Module if of Version 4.0. Anyhow, it does not harm if the "Sound" link is present for a Orbiter Sound 4.0 setup.

The two symbolic links in /Modules/Server/ folder for Config and Sound folders point (or link) to their "originals" located in the root folder of the Orbiter installation.
If you are using Windows XP or newer and your installation is on a NTFS filesystem, these links can easily be created from Video Tab -> Advanced Setup. If you have problems with creating the links you can also use a software called Link Shell Extension (see link below) or you can simply copy the Config and Sound folders into /Modules/Server/. But then you have to keep them updated manually.

Here is the link: http://schinagl.priv.at/nt/hardlinkshellext/hardlinkshellext.html


Fullscreen Mode and Alt-Tabing

D3D9Client doesn't support alt-tabing in a so-called "True Fullscreen Mode". Therefore, it's recommended that you use a windowed fullscreen mode that will run the orbiter in a fullscreen sized borderless window. There is also a conflict between a GDI based dialog (i.e. pop-up) windows and anti-aliasing in a true fullscreen mode which will disable the anti-aliasing.


D3D9Client Advanced Setup

Under the regular Video Tab of the Orbiter (Orbiter_NG) Launchpad you find the "Advanced" Button that will show the "D3D9Client Advanced Setup" Dialog. Here you can change several settings to tweak your experience with the D3D9Client.

D3D9Client Advanced Setup

On the lower left side of the Dialog you'll find the "Create symbolic links" button that will create the symbolic links that are needed for some add-ons. The symbolic links can only be created on an NTFS filesystem, so if you have installed your Orbiter installation for example on an FAT32 of extFS filesystem this feature will not work. In this case you have to copy the according folders as explained in the "Orbiter Sound, Spacecraft3.dll" chapter.

Surface texture load options

Here you can change the behavior how the D3D9Client will load surface textures. The two options available are either "Load on demand (recommended)" or "Pre-load at session start":

Graphics options

Here you can change settings according to your graphic hardware:

Following checkboxes can be checked (enabled) or unchecked (disabled) to further fine-tune your D3D9Client experience:

Self Shadows

Here you can change settings that will affect the rendering of shadows that vessels will cast onto themselves or onto other vessel structures.

Terrain Resolution

Here you can change settings that will affect the rendering of planetary terrains.

SketchPad settings

The SketchPad is used in Orbiter to draw 2D graphics onto surfaces. These are for example MFD Displays or announcements in the Simulation.

Generic configuration

The generic configuration contains options that will change the general behavior of D3D9Client. For most of the time the default setup should be fine ("Default" Shader set and Debug Level "1"). But you can for example change the verbosity of the internal logging system to be able to report more detailed issue information when you experience an error or failure.

StereoScopic 3D

The stereoScopic 3D settings allow you to tweak the 3D experience if you are using a NVIDIA graphic card that provides this feature.

Reflections and Custom camera settings

The reflections and custom camera settings allow you to tweak the parameters that define the behavior of the environment mapping feature. Environment mapping is a feature used to draw reflections of the surrounding environment on reflective surfaces. Custom camera settings will allow add-ons to render images on isolated surfaces (camera screens).


D3D9 Debug Controls Dialog

The D3D9 Debug Controls Dialog allows you look at different things while the simulation is running.
Such things are for example the highlighting of Meshes or Groups, so their location and look can be easily checked. Looking at a complete scene in wireframe mode might for example help in finding any mesh parts that are not placed correct.
The D3D9 Debug Controls Dialog also allows you to change the settings of materials at runtime, so that changes can be 'seen' while changing them.

D3D9 Debug Controls

Mesh debugger

The mesh debugger group contains elements to inspect a mesh. It gives a mesh developer some tools at hand to better inspect a mesh in its 'natural environment', the Orbiter Simulation environment.
With the options available in this group one can for example separate individual parts of the shown scene and leave out all the rest, so it might be easier to see what really happens at rendering.
Other settings change the environment so that the current lighting conditions do not apply, so when the mesh is currently in the shadowed part of the orbit it can still be seen with some artificial ambient light.
For all possibilities, please read the descriptions of the individual GUI- Elements, below.

Bounding geometry

The options in this group offers additional rendering of bounding boxes or spheres of individual mesh parts.

Misc.

This group contains some debugging options to assist on more severe problems or let you see the current environment, that is used for the environment mapping feature of the D3D9Client.

Material 'X'

This group contains all the elements that enable you to tweak the different parameter of materials.

Save materials (Button)

The save materials button in the "D3D9 Debug Controls" Dialog does just that: it saves the materials ;)
Once you are happy with the result you have adjusted in the Material 'X' group, click on "save materials" and the changed material specifications will be saved in the Config\GC\ folder of your Orbiter installation.
Then of course you can tweak these file(s) in Config\GC\ folder with notepad etc.
So next time you fly with a ship of the same class it will have the properties, you have defined or changed, applied.
If you want to have the "default" look back, just delete the according file from that folder (e.g. Config\GC\DeltaGlider.cfg) and the standard Orbiter appearance will be restored.
The install ZIP of D3D9Client contains some of those files already, that contain some nice "advanced looks" for some of the standard vessels. You can always take those and place it back into that folder to get the "D3D9-Default" look.


Base Configuration settings

The D3D9Client allows you to to configure some more details when settings up runway lights.
Additionally to the parameters that Orbiter itself defines (see Doc\OrbiterConfig.pdf for further details) there are some extra parameters you can define.
For a better understanding how some of those parameters will affect the rendering of the runway lights this image might help:

Runway lights

<RUNWAYLIGHTS>

Example of runway lights for KSC:

RUNWAYLIGHTS
  END1 -8220 -3 -600
  END2 -12670 -12 -3155
  WIDTH 100
  PAPI 5.0 3.0 257 3      ; both sides of the green line, in both ends
  PAPI 20.0 3.0 -2000 0 0 ; on a center line 2km before rwy in END 1
  PAPI 20.0 3.0 -2000 3 1 ; both sides of center line, 2km before rwy, in END 2
  VASI 1.5 152 671
  TD_DISP 257
  TD_LENGTH 600
  DECISION_DIST 257
  APPROACH_START 900
END

Advanced Texture Maps

Additional texture maps can be automatically assigned for a mesh simply by placing additional textures into a texture folder. Additional textures are identified by using an identifier in the end of the textures name like "dgmk4_1_bump.dds" where "dgmk4_1.dds" is the name of the base texture.

A fully specified texture set could for example consist of these files:

    cube.dds       <= 'base' texture
    cube_bump.dds  <= 'advanced texture Bump-map'
    cube_spec.dds  <= 'advanced texture Specular-map'
    cube_emis.dds  <= 'advanced texture Emission-map'
    cube_refl.dds  <= 'advanced texture Reflection-map'
  

Available identifiers are:


Note, that not all objects support all advanced texture maps:

Type Identifier  Vessel Base Planetary Surface
Bump-map_bumpsupportedsupportednot supported
Specular-map_specsupportedsupportednot supported
Emission-map_emissupportedsupportednot supported
Reflection-map_reflsupportednot supportednot supported
Translucence-map_translsupportednot supportednot supported
Transmittance-map_transmsupportednot supportednot supported