goat3d

annotate doc/goatfmt @ 94:21319e71117f

[libs] fixed a few warnings in openctm [goatview] starting animation loading
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 18 May 2014 19:58:47 +0300
parents f1b4c27382ce
children
rev   line source
nuclear@35 1 Goat3D scene file format
nuclear@35 2 ------------------------
nuclear@35 3
nuclear@14 4 Chunk structure
nuclear@14 5 ---------------
nuclear@14 6
nuclear@14 7 Leaf nodes which carry actual data are marked with <SINGLE_CHILD>, or
nuclear@14 8 [MULTIPLE_CHILDREN]. Where choice is involved, options are seperated with the |
nuclear@14 9 symbol.
nuclear@14 10
nuclear@14 11 SCENE
nuclear@14 12 +--ENV
nuclear@14 13 | +--AMBIENT
nuclear@14 14 | | +--<FLOAT3>
nuclear@14 15 | +--FOG
nuclear@14 16 | +--FOG_COLOR
nuclear@14 17 | | +--<FLOAT3>
nuclear@14 18 | +--FOG_EXP
nuclear@14 19 | +--<FLOAT>
nuclear@14 20 +--MTL
nuclear@14 21 | +--MTL_NAME
nuclear@14 22 | | +--<STRING>
nuclear@14 23 | +--MTL_ATTR
nuclear@14 24 | +--MTL_ATTR_NAME
nuclear@14 25 | | +--<STRING>
nuclear@14 26 | +--MTL_ATTR_VAL
nuclear@14 27 | | +--<FLOAT|FLOAT3|FLOAT4>
nuclear@14 28 | +--MTL_ATTR_MAP
nuclear@14 29 | +--<STRING> (filename)
nuclear@14 30 +--MESH
nuclear@14 31 | +--MESH_NAME
nuclear@14 32 | | +--<STRING>
nuclear@14 33 | +--MESH_MATERIAL
nuclear@15 34 | | +--<STRING|INT> (material name or index)
nuclear@14 35 | +--MESH_VERTEX_LIST
nuclear@14 36 | | +--[FLOAT3]
nuclear@14 37 | +--MESH_NORMAL_LIST
nuclear@14 38 | | +--[FLOAT3]
nuclear@14 39 | +--MESH_TANGENT_LIST
nuclear@14 40 | | +--[FLOAT3]
nuclear@14 41 | +--MESH_TEXCOORD_LIST
nuclear@14 42 | | +--[FLOAT3]
nuclear@14 43 | +--MESH_SKINWEIGHT_LIST
nuclear@14 44 | | +--[FLOAT4] (vector elements are the 4 skin weights/vertex)
nuclear@14 45 | +--MESH_SKINMATRIX_LIST
nuclear@14 46 | | +--[INT4] (vector elements are the 4 matrix indices/vertex)
nuclear@14 47 | +--MESH_COLOR_LIST
nuclear@14 48 | | +--[FLOAT4]
nuclear@14 49 | +--MESH_BONES_LIST
nuclear@14 50 | | +--[INT|STRING] (list of bone nodes by name or index)
nuclear@14 51 | +--MESH_FACE_LIST
nuclear@14 52 | | +--MESH_FACE
nuclear@14 53 | | +--[INT] (three INT chunks for the vertex indices)
nuclear@14 54 | +--MESH_FILE
nuclear@14 55 | +--<STRING> (filename of mesh file to get all the data from)
nuclear@14 56 +--LIGHT
nuclear@14 57 | +--LIGHT_NAME
nuclear@14 58 | | +--<STRING>
nuclear@14 59 | +--LIGHT_POS
nuclear@14 60 | | +--<FLOAT3>
nuclear@14 61 | +--LIGHT_COLOR
nuclear@14 62 | | +--<FLOAT3>
nuclear@14 63 | +--LIGHT_ATTEN
nuclear@14 64 | | +--<FLOAT3> (constant, linear, and quadratic attenuation)
nuclear@14 65 | +--LIGHT_DISTANCE
nuclear@14 66 | | +--<FLOAT>
nuclear@14 67 | +--LIGHT_DIR
nuclear@14 68 | | +--<FLOAT3>
nuclear@14 69 | +--LIGHT_CONE_INNER
nuclear@14 70 | | +--<FLOAT>
nuclear@14 71 | +--LIGHT_CONE_OUTER
nuclear@14 72 | +--<FLOAT>
nuclear@14 73 +--CAMERA
nuclear@14 74 | +--CAMERA_NAME
nuclear@14 75 | | +--<STRING>
nuclear@14 76 | +--CAMERA_POS
nuclear@14 77 | | +--<FLOAT3>
nuclear@14 78 | +--CAMERA_TARGET
nuclear@14 79 | | +--<FLOAT3>
nuclear@14 80 | +--CAMERA_FOV
nuclear@14 81 | | +--<FLOAT>
nuclear@14 82 | +--CAMERA_NEARCLIP
nuclear@14 83 | | +--<FLOAT>
nuclear@14 84 | +--CAMERA_FARCLIP
nuclear@14 85 | +--<FLOAT>
nuclear@14 86 +--NODE
nuclear@14 87 +--NODE_NAME
nuclear@14 88 | +--<STRING>
nuclear@14 89 +--NODE_PARENT
nuclear@14 90 | +--<INT|STRING>
nuclear@14 91 +--NODE_MESH|NODE_LIGHT|NODE_CAMERA
nuclear@14 92 | +--<INT|STRING>
nuclear@14 93 +--NODE_POS
nuclear@14 94 | +--<FLOAT3>
nuclear@14 95 +--NODE_ROT
nuclear@14 96 | +--<FLOAT4> ([x, y, z], w <- real part)
nuclear@14 97 +--NODE_SCALE
nuclear@14 98 | +--<FLOAT3>
nuclear@14 99 +--NODE_PIVOT
nuclear@14 100 | +--<FLOAT3>
nuclear@14 101 +--NODE_MATRIX0
nuclear@14 102 | +--<FLOAT4> (first row)
nuclear@14 103 +--NODE_MATRIX1
nuclear@14 104 | +--<FLOAT4> (second row)
nuclear@14 105 +--NODE_MATRIX2
nuclear@14 106 +--<FLOAT4> (third row)
nuclear@14 107
nuclear@14 108 NOTES:
nuclear@14 109 * Name chunks are mandatory. If something doesn't have a name, one must be made
nuclear@14 110 up, even if it's just "object%d".
nuclear@14 111 * In node chunks, both POS/ROT/SCALE, and MATRIX0/MATRIX1/MATRIX2 are mandatory
nuclear@14 112 and they must agree. Makes it easy for the reader to pick the transformation
nuclear@14 113 data in whichever way is more convenient.