import graphics3d.Graphics3DFramework; import Graphics3D; import Math; // For the value of PI // Variables to store the model IDs int axis, box; // Function called at the start of the program void onStart ( int rendererID ) { // Optional: Set window size and background color setWindowSize( 800, 600 ); setBackgroundColor( 0, 0, 0, 255 ); // Create and place an axis model axis = newAxisModel( 3.0, 3.0, 3.0 ); mountModel( axis, rendererID ); // Create and place a box-shaped model box = newBoxModel( 2.0, 2.0, 2.0 ); mountModel( box, rendererID ); } // Function called several dozen times per second during each frame update void onUpdate (int renderer) { // Gradually rotate the box around the Z-axis rotModelZ( box, 0.02 ); }