chickadee » 3viewer » add-object

add-object RENDER #!key name select animateprocedure

Creates a new object and returns its ID. name is an optional name for ther object. RENDER is a procedure taking an object ID and performs the necessary graphical operations to render the object into the OpenGL buffer. select is a procedure taking an object ID and is invoked when the user clicks on the rendered object in the viewer window. animate is a procedure taking an object ID and defines an animation to be executed on each "tick" (redraw or when the system is idle). If the animation procedure returns true, then the object will be re-rendered.