Overview

All C3D files contain a parameter section that stores information about the 3D and/or analog data stored within the C3D file.  These parameters should provide all the information that a software application needs to access and process the data contained within the C3D file.  In order to understand the parameter section within a C3D file it may be useful to see the C3D file format from the historical context as a particular implementation of a more general ADTech format specification.  The general ADTech specification covers a family of file formats and specifies that the first word of the file will contains a pointer to the parameter section.  The parameter section can contain pointers to any number of data sections in the file, together with their starting record locations.

A single 512 byte header section

A parameter section consisting of one or more 512-byte blocks.

3D point/analog data section consisting of one or more 512-byte blocks.

Figure 7 – The parameter section within the C3D file structure.

Although the C3D file header provides access to some basic information about the contents of a C3D file (number of 3D points, analog channels and sample rates etc), it is the parameters within the parameter section of the file that store the details that make the contents of the file intelligible.  For instance, the C3D header may tell you that the file contains 50 frames of data, each containing 20 3D points – however, it is the parameters that tell you that the 10th point in each frame is labeled “LTHI” and is the “Left Thigh Wand Marker”.

Without the parameter section, a C3D file is just a collection of data samples, stored in the file in yet another data format.  It is the structure of the parameter section, and its flexibility, that makes the C3D file format so adaptable and functional, regardless of the source of the data.

Within the parameter section, a name and a data type identify each stored parameter.  A parameter may have dimensions, which describe how many pieces or elements of data it can hold.  Each parameter can also have a description associated with it.  While the C3D file requires some specific information to be present as parameters, any user may create additional parameters to store any relevant information.  Any other C3D compatible application can automatically read this information making it easy to preserve almost any data-related information.

Related parameters (for instance, a collection of parameters containing information about the analog data in a C3D file) are organized into “groups” - each parameter within a C3D file belongs to a particular parameter group.  Each parameter group has a unique group name and may have a group description associated with it.

In listings and commands, the group name and parameter name are separated by a colon (:) so that the parameter “SCALE” that belongs to the “ANALOG” group will be written as ANALOG:SCALE – the group name always precedes the parameter name.  The ability to group parameters in this way enables similar parameters pertaining to different functions to be included in the same file without risk of confusion.  Thus, the SCALE parameter ANALOG:SCALE is different from the parameter POINT:SCALE.

A parameter or group name may consist of any number of characters made up from the letters A through Z, the numerals 0 through 9, and the underscore character “_”, other punctuation or printable characters may not be used.  Parameter and group names should not start with a numeral or the underscore character.  While lower case letters are usually tolerated in parameters and group names, it is standard practice to use upper case letters throughout the name.

For compatibility between software applications, the C3D specification states that when a parameter or group name is interpreted then only the first six characters of the group name and the first six characters of the parameter name are used.  Therefore, it is important that all group names, and all parameter names within the group, should show at least one difference in the first six characters.  The same names may be used for two parameters if they occur in different groups.

A parameter’s type determines the type of data that may be stored in it.  Four parameter types are used; integer, floating-point, character, and byte.  These data types correspond to the conventional meaning of the terms in computer programming.  An integer is a 16-bit signed number between -32768 and +32767, a floating-point number is one containing a decimal point or written in scientific exponential representation.  A character is a literal symbol such as a letter entered from the keyboard, and a byte data location can contain an 8-bit signed integer in the range -128 to +127.

An unsigned, 16-bit, integer can store positive numbers in the range of 0 to +65535 while unsigned bytes have a range of 0 to +255.  Unsigned integers lack any way of recording the sign of a number and so, by convention, are assumed to be positive values.  This ability to represent larger numbers makes the use of unsigned numbers attractive within some C3D file parameters where we are confident that the values represented will never be negative.  As a result, some software applications may treat certain parameters as unsigned – thus allowing them to store larger frames or longer parameters.  C3D files that contain unsigned integers are referred to as Unsigned C3D files.

It must be stressed that, other than the convention of treating a particular order of 16-bits as a positive or negative value, there is no discernable difference in the way that the C3D file is written.  The only way of determining that a C3D file is unsigned is by examining the values of various parameters for negative values in places that would make no sense in a signed C3D file – for instance, reading an array index with a negative value is a sure giveaway as is reading a negative frame range!

The dimensions of a parameter define how many elements of the appropriate type may be stored in that parameter – as a result, dimensions are always positive values.

The original signed C3D specification allowed for a maximum of seven dimensions.  Some older applications may fail to read more than seven dimensions, if present in a C3D file. 

The use of the term dimensions follows normal programming conventions - if a parameter has no dimensions, then it may only hold one value of its data type.  If it has one dimension it is presented in the form such as PARM(4) where the 4 indicates that the parameter called PARM is capable of holding four values.  Examples of two- and three-dimensional parameter arrays are PARMA(4,5) and PARMB(3,5,7).  The first example has 4 x 5 = 20 elements, and the second parameter holds 3 x 5 x 7 = 105 entries.