PLAY

3D models for cockpits

In this article: General Scene Requirements • Model • Naming Convention & Animation • Materials & Textures • Other Notes

General Scene Requirements

Cockpit placement and orientation
  • The scene must be fully compatible with Autodesk 3ds Max 2011
  • Scene names must contain the full name of the aircraft with the postfix «_cockpit». For example: bf_109e_3_cockpit.max. Scene and texture names cannot contain capital letters or hyphens «-». Instead, use underscores «_»
  • Stacks must be collapsed on all objects (objects must be Editable Poly)
  • Models are made to scale using metric system units (System units = Meters)
  • Display units may be whichever you want
  • All objects must have their scale reset to 100, 100, 100 (use Hierarchy/Reset Scale)
  • The cockpit should be positioned within the external model and oriented the same way (The X-axis points forward; the Y-axis is pointed to the left of the direction of flight; the Z-axis should point upward)

All objects in the scene must be composed into the following layers:

  • Cockpit – the cockpit itself. All cockpit related objects go here
  • LOD0 - undamaged state of the external model (is taken from the external model). Holes in the glass canopy and instrument panel go into this layer also
  • GUN – flames from gun barrels and also bomb and rocket mount points (from the external model)
  • nodes – animated pilot nodes linked to controls (are provided in the sample model)

Pivots for all non-moving objects must be at the center of world coordinates (World 0,0,0), the local axis must match the world axis. Pivots for gauge needles and aircraft controls must be at the point of rotation with one axis pointed along the rotational axis. In order to easily animate them. Since these objects will be animated particular axis of rotation (local x,y or z) is not important.

Model

Cockpit Geometry. Polygon Count

The model must contain 70-150K triangles for a single seat cockpit and 100-200K for a two seated cockpits. When making geometry, you should take into account the 360° camera view, as well as the fact that the game camera can move about 20-30cm in any direction from its neutral position.

So you have to be careful to which invisible polygons are to be deleted when optimizing cockpit geometry. You may want to make a layer called «invisible» and store excessive polygons there (not to be exported). Faces without smoothing groups are not allowed. Even if it is a flat surface.

Smoothing groups must be present on all faces.

UV mapping. Texture Layout

UV coordinates must not exceed +-7.0 in any direction.

All faces must be mapped and have UV coordinates. Otherwise there will be conversion errors. It is a good practice, for ordinary geometry to have all mapping inside 0-1 UV space.

Naming Convention & Animation

Animation should be made in a 0 to 100 frame range for any animated object. A Note track is to be created in the Track View Dope Sheet with keys «start» at frame 0 and «finish» at frame 100 for one of the objects. For cockpits it is the throttle object. The game code reads the «start» and «finish» keys to determine the animation range.

Track View - Dope Sheet «start» and «finish» keys

Use only Linear PositionLinear Rotation and Linear Scale animation controllers.

Animation controllers

Animation constraints are not allowed.

The names for moving (animated) objects in the cockpit are in the table below. The table also lists the initial and final positions of controls and instrument needles. Number and availability of objects depends on the cockpit you are making.

Animated objects

Controls

Aerodynamic Surfaces:

Aircraft Control Stickstick_elevator *fully away from the pilotfully towards the pilot
stick_ailerons *full to the leftfull to the right
Pedalspedalsleft pedal forwardright pedal forward
additional parts availablepedals(1-8) **----
Flapsflapsretractedextended
Trimmertrimmernose downnose up

Engine:

Throttlethrottleidle rpmmaximum rpm
add.throttle(1-2)----
Mixturemixturerichlean
add.mixture(1-3)----
Propeller Pitchprop_pitchhigh pitchlow pitch
Superchargersuperchargeroffon
add.supercharger(1-2)----
Radiator Flapsradiatorclosedopen

Weapons:

Weapon 1weapon1 ***neutralpressed
Weapon 2weapon2 ***neutralpressed
Weapon 3weapon3 ***neutralpressed
Weapon 4weapon4 ***neutralpressed

Others:

Landing Geargearsretractedextended
add.gears(1-2)----

Instruments & Equipment

Aircraft operation and Navigation:

Altitude (km or thousands of feet)altitude_hour0 degrees360 degrees clockwise
Altitude (hundreds of meters or feet)altitude_min0 degrees360 degrees clockwise
Altitude (10k meters or feet)altitude_10k0 degrees360 degrees clockwise
Speedspeed0 km/h (knots) ****maximum speed ****
Mach Numbermachminimum Mmaximum M
add.mach1----
Rate of Climbvariomaximum descentmaximum climb
Artificial Horizon Pitchaviahorizon_pitchmaximum ascentmaximum descent
Artificial Horizon Rollaviahorizon_rollmaximum roll to the rightmaximum roll to the left
Bank Indicatorbankball in the leftmost positionball in the rightmost position
add.bank(1-2)----
Turn Indicatorturnto the leftto the right
add.turn(1-2)----
Compasscompass0 degrees360 degrees counterclockwise
add.compass(1-4)----
Clockclock_hour0 degrees. 24 hours360 degrees clockwise
clock_min0 degrees. 60 min360 degrees clockwise
clock_sec0 degrees. 60 sec360 degrees clockwise
G-Meterg_metermax negative-gmax positive-g
g_meter_minmax negative-gmax positive-g
g_meter_maxmax negative-gmax positive-g
Ammo Counterammo_counter(1-8)fullempty
Ammo Empty Lampammo_counter(1-8)_lampnot animatednot animated

Engine:

Maniforld Зressuremanifold_pressure0maximum pressure
add.manifold_pressure----
Revolutions (single needle instrument)rpm0 rpmmaximum rpm
add.rpm1----
Revolutions (dual needle instrument)rpm_hour0 degrees360 degrees clockwise
add.rpm1_hour----
Revolutions (dual needle instrument)rpm_min0 degrees360 degrees clockwise
add.rpm1_min----
Oil Pressureoil_pressureminimum pressuremaximum pressure
add.oil_pressure1----
Oil Temperatureoil_temperatureminimum temperaturemaximum temperature
add.oil_temperature1----
Water Temperaturewater_temperatureminimum temperaturemaximum temperature
add.water_temperature1----
Cylinder Head Temperaturehead_temperatureminimum temperaturemaximum temperature
add.head_temperature1----
Carburetor temperaturecarb_temperatureminimum temperaturemaximum temperature
add.carb_temperature1----
Fuel Gaugefuelempty tankfull tank
add.fuel1----
Fuel Pressurefuel_pressure0maximum pressure
add.fuel_pressure(1-3)----

Others:

Gear Down. Green Lampgear_lamp_down *****not animatednot animated
Gear Up. Red Lampgear_lamp_up *****not animatednot animated
Gear in Transition Lampgear_lamp_off *****not animatednot animated
  • * - stick_ailerons should be parented to the stick_elevator. If the control stick is made of one object (and usually it is), it is necessary to create a stick_elevator fake object (an ordinary small box will do) and put it in the hinge point of the control stick joint.
  • ** - pedals can be a complex parallelogram mechanism. In this case, all objects related to pedals need to be labeled pedals1, pedals2, pedals3 etc.
  • *** - triggers on the control stick must be parented to stick_ailerons and named weapon1 (machine guns), weapon2 (cannons), weapon3 (bombs, rockets).
  • **** - usually the speedometer has a nonlinear scale. It is necessary to animate the needle in order to display speed in a linear manner. For example, if the maximum speed according to the instrument is 500 km/h, then for every 2 frames the speed must increase by 10 km/h on the instrument.
  • ***** - these names are assigned to billboards, which have an illuminated lamp texture.
Control stick hierarchy

Materials & Textures

Several diffuse textures, normal and specular map textures are used for a model.

  • body – primary texture set for our cockpit. Diffuse+normal+specular
  • glass – glass texture. Diffuse only
  • glass_dmg – oil stained glass (for battle damage). Diffuse only
  • gauges - gauge dials and casings texture set. Diffuse+normal+specular
  • gunsight – gunsight texture set. Diffuse+normal+specular
  • labels – an optional texture set for cockpit text labels on billboards
  • boxes – an optional texture set for equipment (radio control boxes etc.) that did not fit into the primary body texture. Diffuse+normal+specular

Diffuse map (with or without an alpha channel) is a separate texture.Normal and specular maps share one texture with specular map placed in the alpha channel. Use optional textures carefully. For example if you have boxes texture with many text labels written on equipment - the remaining labels can be accommodated in the gauges texture. So we can skip creating separate labels texture.The rule is the fewer textures the better.

Diffuse Textures

The default usual texture dimensions are the following:

  • body (hull) – 4096x4096x24bit (no alpha). If the cockpit is small then a smaller size can be used
  • glass – 1024x1024x32bit
  • glass_dmg – 1024x1024x32bit
  • gauges – 2048x2048x32bit or 24bit. Up to 4096 pixels for a multiseated cockpits with many gauges
  • gunsight – 1024x1024x24bit (no alpha). No gunsight glass texture is required. Only gunsight body
  • labels – 1024x1024x32bit. As required up to 2048
  • boxes – 2048x2048x24bit (no alpha). As required up to 2048

glass_dmg texture is needed only when aircraft engine is located in front of the cockpit.

Always use the power of 2 for texture sizes. Aspect can be nonsquare. But it is better to plan your texture layouts keeping square sizes in mind.

An example of a, complete fighter cockpit texture set:

  • f3f_1_cockpit_body_c.tga
  • f3f_1_cockpit_body_n.tga
  • f3f_1_cockpit_glass_a.tga
  • f3f_1_cockpit_glass_oil_a.tga
  • f3f_1_cockpit_gauges_a.tga
  • f3f_1_cockpit_gauges_n.tga
  • f3f_1_cockpit_gunsight_c.tga
  • f3f_1_cockpit_gunsight_n.tga
  • f3f_1_cockpit_labels_a.tga (optional)
  • f3f_1_cockpit_labels_n.tga (optional)
  • f3f_1_cockpit_boxes_c.tga (optional)
  • f3f_1_cockpit_boxes_n.tga (optional)

The endings are added to the files of textures:

  • «_c» postfix is for textures without alpha channel
  • «_a» postfix is for textures with alpha channel
  • «_n» postfix is for normal map textures with specular map inside alpha channel

Important! Please do not forget to add required post-fixes to files. As the engine uses them to choose compression method for a texture.

You can find additional textures, used by cockpit in the sample model archive.Tip for graphics software suites with layer functionality. It is better to store diffuse, damage, normal map and specular maps all in one file. The resulting combined names will be (in case of Photoshop):

  • f3f_1_cockpit_body.psd
  • f3f_1_cockpit_gauges.psd etc.

Normal and Specular Textures

The normal map and specular maps are the same size as the primary diffuse texture. Normal map uses RGB channels and Specular map uses an alpha channel. It is good to keep normal maps as bump (height maps) in your layered source document before the NormalMapFilter conversion. Converted (blue) normal maps in layers are better used only for minor corrections. Use filter default settings for height to normal map conversion: Min Z = 0, Scale = 8.

The normal map Y (green) channel must NOT be inverted.

Normals and Y (green) channel

You should get the following look after the NormalMapFilter conversion. Convex parts look as if they are lit from below.The normal map must include minor details and relief which is "expensive" to do with geometry: rivets, washers, etching, etc. The specular map should emphasize defects from everyday use of machinery: chips and scratches on the paint, traces of abrasion on bolts, rivets and ribs of metal parts.

The following brightness values are recommended for the specular map:

  • Primary surfaces (paintwork): K~80-90% (40-70 RGB)
  • Bare metal (chips, wear) K~20-40% (170-210 RGB)

Materials (the order of material IDs)

Cockpit objects must have have a single Multi/Sub-object material, named «cockpit» assigned to it.Sub-Object materials:

  • (1) – glass
  • (2) – body
  • (3) – gauges
  • (4) – gauges_dmg (damaged instrument glass)
  • (5) – collimator or sight
  • (6) – collimator_glass or sight_glass (for gunsight glass)
  • (7) – bullet_glass* (canopy glass holes)
  • (8) – bullet_metal* (holes in the hull)
  • (9) – labels (optional)
  • (10) – boxes (optional)
  • (11) – flare_red** (red lamp flare)
  • (12) – flare_green** (green lamp flare)

* - you can make separate Multi/Sub-Object, material for bullet holes.

** - you can make separate Multi/Sub-Object, material for lamp flares. Color and quantity may vary as necessary.

No special material is required for glass_a_dmg texture. Because it is swapped in game with ordinary glass texture when oil radiator is damaged.

Text labels with alpha cut letters are not allowed. Because alpha is eaten out quickly by texture mips. So the text becomes unreadable. «No degradation» flag is not available for cockpit textures. It has limited uses.

Tips for users with advanced graphics software suites

It is a good practice to keep the size of source files low. For *.psd files for example it is better to stay under 1GB for a 4k texture. Low file sizes, are more convenient to work with. Primary size eaters are ordinary layers with masks. Using them on every occasion can increase the size of the file dramatically in no time. Use masks with care and only where really necessary. Please do not use 4k masks just to change the transparency of several pixels in a layer. Solid color fills with masks may be used. They are not size eaters. Keep reasonable layer count so any element, of the texture is easily editable. Not too many but not too few.

Cockpit layer names and format example:

  • uv – rendered uv template can go here. The topmost layer. Hidden by default.
  • gauge_dial_rpm
  • color_handle_throttle_fs_37038
  • overlay_pedal_left
  • label_warning_landing_gear
  • color_body_fs_34128 etc.

Layers may have sensible names which are easy to understand. For your convenience. In the example above Federal standard 595C colors are used for precise color description. Using the default layer names Layer 1, Layer 2 etc. may become uncomfortable in the long run.

Recommended names for layer groups:

  • s – specular
  • n – normal
  • ao – rendered ambient occlusion
  • lines – rivets and paneling
  • text – text and service labels
  • dirt – dirt and scratches layers
  • volume – hand painted light/dark volumes
  • color or c – primary colors for a cockpit

Additional layer groups suggestions:

  • electric_radio_equipment
  • electric_circuit_breakers
  • control_throttle_quadrant etc.

It is better not to rasterize text layers. So that they can be easily edited anytime.

Ambient Occlusion

An ambient occlusion layer must be rendered at least for the primary cockpit texture. To have nice ambient shadows. You can use mental ray Renderer for these purposes. Select Ambient Occlusion (MR) when adding a component in the Output section of Render To Texture dialog. Use Edge Padding of 2 pixels. Play with mental ray Samples and Falloff parameters to get the desired look. Do not forget to switch to mental ray renderer in the Render Setup dialog window (F10).

Ambient occlusion must be rendered against a white background. In Photoshop (or similar software) use «Multiply» layer blend and place AO layer group on top of the layer stack. Play with opacity, as you see fit to get a good looking result. It is advised not to overshadow the cockpit. Please note that there will be static shadows rendered in places where we do not want them to be. On moving control surfaces or under pedals for example. Keep this in mind. Such places will have to be adjusted manually.

Other Notes

Damage billboards

Glass bullet holes for damaged state are made with billboards placed near damaged surfaces (you can use texture provided with the sample model). Metal holes in the fuselage and instrument panel are made the same way. Player must get a visual notice when the aircraft is damaged. You can paint dirt on cockpit glass along the framework. With up to 40% opacity. Bare metal for chips and wear on the diffuse texture have to fall within 90-120 RGB range. Cockpit textures must not be clean. You can add traces of everyday use (wear & tear) with diffuse and specular textures for better realism.

Properties for all objects in the scene, are set with Object Properties Editor. Objects are treated as ordinary geometry. DagorMat2 materials with appropriate shaders have to be assigned for all objects to export. Please visit Dagor Tools chapter of the aircraft design document for information. Cockpits are exported the same way as aircraft. However, they have only 2 files for the cockpit model:

  • %aircraft_name%_cockpit.lod00.dag - aircraft cockpit and LOD0 file.
  • %aircraft_name%_cockpit_anim.a2d - animation file.

Good luck and we can't wait to see what you make.

Related Links

Comments
No comments yet
Be the first to write one!
Recommendation feed
We have nothing to recommend you at the moment :(
Go to Main
No more content