Microsoft DirectX 8.0 (Visual Basic)

テンプレートの例

次にテンプレートの例を示す。

template Mesh {
<3D82AB44-62DA-11cf-AB39-0020AF71E433>
DWORD nVertices;
array Vector vertices[nVertices];
DWORD nFaces;
array MeshFace faces[nFaces];
 [ ... ]                // 開かれたテンプレート
}
template Vector {
<3D82AB5E-62DA-11cf-AB39-0020AF71E433>
FLOAT x;
FLOAT y;
FLOAT z;
}                        // 閉じられたテンプレート
template FileSystem {
<UUID>
STRING name;
[ Directory <UUID>, File <UUID> ]    // 限定使用されるテンプレート
}