GRAF:Star Trek Armada SOD

From XentaxWiki
Jump to: navigation, search

Back to index | Edit this page

SOD

Format Specifications

Section 1 : File Header
=======================
 
HEADER Storm3D_SW File identification header (8 bit ascii values) - no strlen or terminating '\0'.
FLOAT version Current version is 1.8, older formats are not described at this time.
 

Section 2 : Lighting Materials
==============================
Defines the characteristics of the vertex lighting materials defined in this .SOD file.
 
UINT16 count - The number of lighting materials defined in this file.
 
LIGHTING_MATERIAL ARRAY(count) Array of lighting materials.
 
LIGHTING_MATERIAL
{
IDENTIFIER identifier Name of the lighting material.
COLOUR ambient Real time lighting ambient component
COLOUR diffuse Real time lighting diffue component
COLOUR specular Real time lighting specular component (only used by the phong illumination model)
FLOAT specular power Specular exponent, used to determine the 'shininess' of material using the phong illumination model.
UINT8 lighting model (constant=0, lambert=1, phong=2)
}
 

Section 3 : Nodes
=================
 
The nodes consist of 5 types NULL, LOD_CONTROL, SPRITE, MESH and EMITTER which together form
a scene graph which describes the object's hierarchy.
 
UINT16 count - The number of nodes in the hierarchy.
 
<Update: Note node_type & identifier order has been switched to correct error in initial specification.>
 
NODE
{
UINT16 node_type (0 - null, 1- mesh, 3 - sprite, 11 - LOD control node, 12 - emitter) DO NOT USE OTHER VALUES.
IDENTIFIER identifier
IDENTIFIER parent (which will be null for root node)
MATRIX34 local transform 
TYPE_SPECIFIC_DATA<node_type> Type specific data field as defined below.
}
 

Null Nodes
==========
 
TYPE_SPECIFIC_DATA<NULL>
{
No addtional data required.
}
 
Null nodes are used for two purposes :
1. As 'glue' to stick the rest of the hierarchy together
2. To mark specific locations in the hierachy, for example, hardpoints.
 

LOD Control Nodes
=================
 
TYPE_SPECIFIC_DATA<LOD_CONTROL>
{
No addtional data required.
}
 
Storm3D uses discrete (rather than dynamic) LODs for level of detail control. Each
child of an LOD control node indicates a discrete LOD that the graphics engine may
use when rendering this object. LOD selection is based on visible on-screen area.
 

Sprite Nodes
============
 
TYPE_SPECIFIC_DATA<SPRITE_NODE>
{
None: The appropriate sprite node definition to use is determined from the
identifier. The sprite node definition is defined in the .spr files.
}
 
Examples of sprite node usage include running lights in ST:Armada.
 
TYPE_SPECIFIC_DATA<PARTICLE_EMITTER>
{
IDENTIFIER Emitter used by this node as defined by an @emitter description in the .spr files.
}
 
Polygon Mesh Nodes
==================
 
TYPE_SPECIFIC_DATA<MESH>
{
IDENTIFIER texture material (0 for default) - Defines the TEXTURE_MATERIAL to be used by this mesh.
IDENTIFIER texture (0 if untextured)
UINT16 nvertices : Number of vertices
UINT16 number of texture coordinates (ntexcoords)
UINT16 number of vertex lighting groups (ngroups)
 
VECTOR3 ARRAY vertex positions (nvertices entries)
VECTOR2 ARRAY texture coordinates (ntexcoords entries)
 
VERTEX_LIGHTING_GROUP ARRAY (ngroups entries) 
 
UINT8 cull type (0 - no cull, 1- (backface cull)
 
UINT16 0 - unused must be 0.
}
 
VERTEX_LIGHTING_GROUP
{
UINT16 num_faces (all faces are triangles)
IDENTIFIER lighting_material (0=default)
FACE ARRAY (num_faces entries)
}
 
FACE_VERTEX
{
UINT16 index into mesh vertex positions array
UINT16 index into mesh texture coordinate array
}
 
FACE
{
FACE_VERTEX ARRAY(3) 3 entries describing a triangular face.
}
 
Section 4 : Animation Channels (Defines transform animation)
============================================================
 
UINT16 count // Number of animation channels
 
ANIMATION_CHANNEL ARRAY(count) Array of animation channels.
 
ANIMATION_CHANNEL
{
IDENTIFIER node : The node to which this animation channel refers.
UINT16 nkeyframes : The number of keyframes used by this channel.
FLOAT channel_period : The length of time one loop of this channel lasts.
UINT16 0 : Not currently used. Must be 0.
MATRIX34 ARRAY(nkeyframes) keyframe_data : The actual animation transforms, evenly spaced over time 'channel_period'.
}
 
Section 5 : Animation References (Defines texture animation)
============================================================
 
Animation references are a way of linking texture (flipbook) animations defined in the 
.spr files to the geometry of a .SOD mesh node. An example of their usage is the
flipbook animation applied to the geometry for the various shield effects in Armada.
 

UINT16 num_animation_references
 
ANIMATION_REFERENCE ARRAY(num_animation_references)
 

ANIMATION_REFERENCE
{
UINT8 type : Must be 4
IDENTIFIER node : The node to which this animation applies.
IDENTIFIER anim : The animation (as defined in .spr files) that is to be applied to this node.
FLOAT playback_offset : Time offset in seconds to be applied to this animation reference.
}

Notes and Comments

Vertex Lighting Material Sharing
================================
 
Vertex lighting materials are shared between objects, when parsing a .SOD file,
Storm3D searches for a match in all previously loaded files. If a match is found, that
material is used. This prevents artists from having to ensure the material characteristics
of commonly used materials are correct in each file, and also saves memory.
 
A 'palette' of commonly used materials can be found in materials.sod 
In Armada, this file is loaded prior to most other SOD files & so defines the
characteristics of many common materials.

This information was copied verbatim from a text document located at http://gamefileformats.netfirms.com/files/docs/sod-file-format.txt .

MultiEx BMS Script

None written yet.

Supported by Programs

Unknown

Links

None

Games

Navigation

Jump to a listing by...
All Formats - Common Formats - Standard Formats - Malformed Pages
Platforms
Microsoft:
Xbox
Xbox 360
Nintendo:
GameCube
DS
Desktop:
PC
Sega:
Dreamcast
Sony:
PlayStation
PlayStation 2
PlayStation 3
PlayStation Portable
Type
Animation - Archive - Audio - Image - Mesh - Miscellaneous - Model - Video
Endianness
Little-endian - Big-endian
BMS Scripts
Pages Without a BMS Script

All Pages with Scripts:
Recently Added Scripts

Program Support
No Known Support

MultiEx Commander - Game Extractor

Format Specification Completion
Work in Progress - Almost Done - Completed
Compression and Encryption
No Compression or Encryption Used - Unknown Compression or Encryption Used

One or Both Used:
Compression Used - Both Compression and Encryption Used