import graphics3d.Graphics3DFramework; import Graphics3D; import Math; // For the PI constant // Function called at the start of the program void onStart ( int rendererID ) { // Optional screen size and background color settings setWindowSize( 800, 600 ); setBackgroundColor( 0, 0, 0, 255 ); // Create a local coordinate system int coord = newCoordinate( ); // Mount it on the world coordinate system mountCoordinate( coord, rendererID ); // Move the local system slightly in the X direction moveCoordinate( coord, 1.0, 0.0, 0.0 ); // Spin the local system 45 degrees around its own Z axis spinCoordinateZ( coord, PI/4.0 ); // Mount a small axis model on the local system int axis1 = newAxisModel( 1.5, 1.5, 1.5 ); mountModel( axis1, rendererID, coord ); // Mount a large axis model on the world system int axis2 = newAxisModel( 3.0, 3.0, 3.0 ); mountModel( axis2, rendererID ); }