dVISE User Guide - MAZ and SPLINE file formats December 1993 This document is Copyright 1993 Division Ltd. All Rights Reserved. This document may not, in whole or in part, be copied, photocopied, reproduced, translated, or reduced to any electronic medium or machine readable form without prior written consent from Division Ltd. DIVISION Limited, 19 Apex Court, Woodlands, Almondsbury, BRISTOL, BS12 4JT, U.K. Tel: +44 (0)454 615554 Fax: +44 (0)454 615532 A - MAZ File Syntax The following definitions outline the syntax of the MAZ file format. The symbols may be interpreted as follows:- [ .. ] Optional command/parameter. | 'or' denoting a number of selections. # comment line. All comments commence with #. Comments exit to end-of-line. [Object Definitions] SCENE scene_name { [ OBJECT ] [ PORTAL ] [ EVENT ] [ FRAME_RATE ] } [more scene definitions] OBJECT object_name { [ POSITION (x, y, z) ] [ ORIENTATION (rx, ry, rz) ] [ SCALE (sx, sy, sz) ] [ ICON "filename" ] [ VISUAL ] [ COLLISION ] [ LIGHT ] [ EVENT ] [ CONSTRAINTS ] [ AUDIO ] } VISUAL { [ GEOMETRY "filename" ] [ F_TEXTURE "filename" ] [ B_TEXTURE "filename" ] [ F_COLOUR (red, green, blue) ] [ B_COLOUR (red, green, blue) ] [ F_SPECULAR ks, power ] [ B_SPECULAR ks, power ] [ VISIBLE on | off ] } EVENT { event_name : [ list of functions separated by ; ] BREAK ; [ more event_name : lists; BREAK ;] } CONSTRAINTS { [ LOCK_X [ [ min | * ] [ max | * ] ] ] [ LOCK_Y [ [ min | * ] [ max | * ] ] ] [ LOCK_Z [ [ min | * ] [ max | * ] ] ] [ LOCK_ROLL [ [ min | * ] [ max | * ] ] ] [ LOCK_YAW [ [ min | * ] [ max | * ] ] ] [ LOCK_PITCH [ [ min | * ] [ max | * ] ] ] } COLLISION { [ VOLUMES "filename" ] [ COLLIDE on | off ] } LIGHT { STATE on | off TYPE directional | ambient | point COLOUR (red, green, blue) } AUDIO { [ VOICE filename | sample name ] [ ENABLE on | off ] [ GAIN volume ] } EVENT_NAMES SCENE_ENABLE - called when scene entered SCENE_DISABLE - called when scene exited SCENE_ANIMATE - called every loop COLLIDE [object_name] - If another object touches object PICK [body_part] - If hand touches object and pick button pressed. DROP [body_part] - If hand is picking, action when pick is disabled. TOUCH [body_part] - If hand touches an object UNTOUCH [body_part] - If hand untouches an object where body_part is defined as LEFT_HAND or RIGHT_HAND Event Functions supplied followSpline (obj, file, speed, count) - Follow a spline definition lightState (object, state) - Enable/Disable light. resetBodyVisual (obj, body_type) - Restore the body visual part. setBackgroundColour (red, green, blue) - Background colour of display setBodyPosition (x, y, z) - Move body to specified position. setBodyVisual (obj, body_type, visual) - Assign new visual to body part. setNearClipPlane (distance) - Distance to near clipping plane. setFarClipPlane (distance) - Distance to far clipping plane. soundOn (object, repeat) - Enable audio output. soundOff (object) - Disable audio output. soundGain (object, gain) - Change the volume of audio. spin (name, axis, rate) - spin about axis. toggleLightState (object) - Change the light state to opposing. toggleVisible (object) - Change visible state to opposing. visible (object, state) - Change visibility of an object B - Spline File Syntax The spline files have the following syntax:- ..... Where each entry is separated by a new-line character. A is defined as:- Where each entry on the line is separated by a single space character. The field is the absolute world co-ordinate position of the spline point, this is a floating point value. The field is the orientation of the spline point specified in radians.