#Inventor V2.1 ascii # Check all aspects of SoLineSet rendering. # # 19990414 mortene Separator { # Global settings. Coordinate3 { point [ -1 1 0, -1 -1 0, 1 -1 0, 1 1 0, # face 0 -1 1 0, 1 1 0, 0 2 -1, # face 1 1 -1 0, 2 0 -1, 1 1 0, # face 2 -1 -1 0, 0 -2 -1, 1 -1 0, # face 3 -1 1 0, -2 0 -1, -1 -1 0, # face 4 ] } Material { diffuseColor [ 1 0 0, 0 1 0, 0 0 1, 1 1 0, 1 0 1, 0 1 1, 1 1 1, 0 0 0, 1 0 0, 0 1 0, 0 0 1, 1 1 0, 1 0 1, 0 1 1, 1 1 1, 0 0 0, ] } TextureCoordinate2 { point [ 0 0, 0 1, 1 0, 1 1, 0 0, 0 1, 1 0, 1 1, 0 0, 0 1, 1 0, 1 1, 0 0, 0 1, 1 0, 1 1, ] } Switch { whichChild -2 DEF ls LineSet { numVertices [ 4, 3, 3, 3, 3 ] } } # (ROW 0) MaterialBinding Separator { MaterialBinding { value OVERALL } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_PART } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_PART_INDEXED } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_FACE } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_FACE_INDEXED } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_VERTEX } USE ls Translation { translation +5 0 0 } MaterialBinding { value PER_VERTEX_INDEXED } USE ls } # (ROW 1) NormalBinding Translation { translation 0 +6 0 } Separator { NormalBinding { value OVERALL } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_PART } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_PART_INDEXED } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_FACE } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_FACE_INDEXED } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_VERTEX } USE ls Translation { translation +5 0 0 } NormalBinding { value PER_VERTEX_INDEXED } USE ls } # (ROW 2) Test how IndexedFaceSet is affected by Complexity. Translation { translation 0 +6 0 } Separator { Complexity { type BOUNDING_BOX } USE ls Translation { translation +5 0 0 } Complexity { type OBJECT_SPACE value 1.0 } USE ls Translation { translation +5 0 0 } Complexity { type OBJECT_SPACE value 0.2 } USE ls Translation { translation +5 0 0 } Complexity { type OBJECT_SPACE value 0.0 } USE ls } # (ROW 3) With different LightModel settings. Translation { translation 0 +6 0 } Separator { LightModel { model BASE_COLOR } USE ls Translation { translation +5 0 0 } LightModel { model PHONG } USE ls } # (ROW 4) With different DrawStyle settings. Translation { translation 0 +6 0 } Separator { DrawStyle { style INVISIBLE } USE ls Translation { translation +5 0 0 } DrawStyle { style LINES } USE ls Translation { translation +5 0 0 } DrawStyle { style LINES lineWidth 1 } USE ls Translation { translation +5 0 0 } DrawStyle { style LINES lineWidth 2 } USE ls Translation { translation +5 0 0 } DrawStyle { style LINES lineWidth 4 } USE ls Translation { translation +5 0 0 } DrawStyle { style LINES lineWidth 2 linePattern 0x0180 } USE ls Translation { translation +5 0 0 } DrawStyle { style POINTS } USE ls Translation { translation +5 0 0 } DrawStyle { style POINTS pointSize 3 } USE ls Translation { translation +5 0 0 } DrawStyle { style FILLED } USE ls } # (ROW 5) With different ShapeStyle settings. Translation { translation 0 +6 0 } Separator { Translation { translation +5 0 0 } ShapeHints { vertexOrdering CLOCKWISE } USE ls Translation { translation +5 0 0 } ShapeHints { vertexOrdering COUNTERCLOCKWISE } USE ls Translation { translation +5 0 0 } ShapeHints { shapeType UNKNOWN_SHAPE_TYPE } USE ls Translation { translation +5 0 0 } ShapeHints { shapeType SOLID } USE ls Translation { translation +5 0 0 } ShapeHints { faceType UNKNOWN_FACE_TYPE } USE ls Translation { translation +5 0 0 } ShapeHints { faceType CONVEX } USE ls Translation { translation +5 0 0 } ShapeHints { creaseAngle 0.5 } USE ls Translation { translation +5 0 0 } ShapeHints { creaseAngle 1.57 } USE ls } # (ROW 6) Test how IndexedFaceSet is affected by texturemapping. Translation { translation 0 +6 0 } Separator { Texture2 { image 8 6 3 0xff000000 0xff000000 0x00000000 0x00000000 0xff00ff00 0xff00ff00 0xff000000 0xff000000 0x00000000 0x00000000 0xff00ff00 0xff00ff00 0xff000000 0xff000000 0x00000000 0x00000000 0xff00ff00 0xff00ff00 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0xffff0000 0xffff0000 0x00000000 0x00000000 0xffffff00 0xffffff00 0xffff0000 0xffff0000 0x00000000 0x00000000 0xffffff00 0xffffff00 0xffff0000 0xffff0000 0x00000000 0x00000000 0xffffff00 0xffffff00 } USE ls Translation { translation +5 0 0 } TextureCoordinateBinding { value PER_VERTEX } USE ls Translation { translation +5 0 0 } TextureCoordinateBinding { value PER_VERTEX_INDEXED } USE ls } }