MINI INVENTOR FILE FORMAT - quick notes #Inventor V2.0 ascii # # The first line of the file must be the one above. # # Any number that appears in the description below is a "default", # except those in Coordinate3, IndexedFaceSet and FaceSet, where # they appear just as an example. # The entire model should hang from a separator node. # They can be used to group a set of children together. # Separator nodes cause any transformations or materials that hang # from them to be ignored by nodes that don't hang from them. Separator { ... } # Groups are like separators, only transformations and materials # within the group apply to all nodes to the right of, and down # from, the group. (Depth first traversal, from left to right) Group { ... } PerspectiveCamera { position 0 0 1 orientation 0 0 1 0 nearDistance 1 farDistance 10 heightAngle 0.785398 } PointLight { intensity 1 color 1 1 1 location 0 0 1 } Material { ambientColor 0.2 0.2 0.2 diffuseColor 0.8 0.8 0.8 specularColor 0 0 0 emissiveColor 0 0 0 shininess 0.2 } Transform { translation 0 0 0 rotation 0 0 1 0 scaleFactor 1 1 1 } # You could use a label for debugging, or just to keep track of the # parts of the model, if you want: Label { label "" } Cube { width 2 height 2 depth 2 } Cone { bottomRadius 1 height 2 } Sphere { radius 1 } Cylinder { radius 1 height 2 } Coordinate3 { point [ 0 0 0, 0 0 1, ... ] } # Coordinates of the verices come from the preceeding Coordinate3 IndexedFaceSet { coordIndex [ 0, 4, 5, 1, -1, 6, 2, 3, 7, -1, ... ] } # Coordinates of the verices come from the preceeding Coordinate3 FaceSet { numVertices [ 4, 4, 4, 4, 4, 4, 4, 4, ... ] } # DEF and USE allow you to turn the tree into a directed graph, reusing # some part of the model that has appeared before: # name a group or separtor (or any node for that matter): DEF name Group { ... } # use it later in the scene graph: USE name