Classic Computer Magazine Archive START VOL. 5 NO. 7 / APRIL/MAY 1991

CYBER CORNER

CAMERA CONTROL

Simple Program Adds Drama To Animations

BY RICK MAY

Creating an exciting and dramatic 3D animation is not always the easiest thing to do. In addition to the movement of objects, the animator needs to pay close attention to the movement of the viewer, or the "camera." I have focused on creating complicated camera effects for quite a while now, and my experience teaches me that camera movements can make or break an animation. Moving the camera the wrong direction at the wrong time lessens an object's sense of movement. But the right camera movement combined with the right object movement creates an exciting feeling.

AT A GLANCE
Program:
 
Type:
 
Requirements:
 
 
Arcfile:
 
Files:
 
 
Camera Control

Animation utility

1MB. medium or high rez,
CAD-3D 2.0. Cyber Control

CAMC_ARC PRG

CAMCNTRL.CTL
EXAMPLE.3D2
STARTUP.CTL


This is the example picture EXAMPLE.3D2. The small cubes define the spline
of movement through this universe occupied by a sphere and a wedge.

To create a dramatic camera movement via Cyber Studio's Cyber Control takes a lot of time, trial and error. So to help with this problem, I have written two short programs in the Cyber Control language. CAMCNTRL.CTL, along with CAD-3D 2.0, allows you to edit a spline based on five control points, which the camera follows during your animation. It also allows you to set these control points so that all objects arc totally within your viewing area and nothing is cut out. The second file, STARTUP.CTL is to be inserted in front of your animation script, setting up the spline and camera for your own animations.

Getting Started
You'll need to extract the file CAMC_ARC.PRG, which is on your START disk. Then boot up your disk containing Cyber Control and CAD-3D 2.0. Load EXAMPLE.3D2 into CAD. Take a look at these objects from each viewing window. You will notice five cubes named c1. c2, c3, c4 and c5. These points will define a spline that your camera will follow. There are also two objects labelled "object1" and "object2," the first being the sphere. Switch over to Cyber Control and load up CAMCNTRL.CTL. Click on the run option and follow along.

Action
After starting CAMCNTRL and clicking on OK in the alert box, the program will take a few seconds to initialize itself. The five control points from CAD-3D are turned into a spline. The spline starts at c1, curves through c2, c3 and c4, and ends at c5. You will be asked to give the number of points on the spline and the type of spline. Larger numbers give you a smoother curve but a slower animation, since the camera steps from one point to the next. See your Cyber Control manual for a description of the types of splines. For this first time we will use a 50-point linear spline, so enter 50. After the spline is created you will be given a four-item menu. Let's go over each option.

Lens Edit: This option lets you change the current camera settings, which are heading, zoom, and perspective. Let's use 0, 25 and 999 respectively.

View: We can view the objects from any point on the spline by typing any number from 0 to 49 (since we created a 50-point spline, 0 is the first point and 49 is the last). You also need to decide whether to view the objects as a wireframe or a solid. The program then asks whether you wish to look at the center of the universe, or at object1.

Print: All information needed to set up the view, including camera location, zoom, heading and perspective, are printed out. This is very important, because after you have found a zoom and perspective you like, you must enter these numbers each time you use CAD-3D. (If you have no printer, you'll have to write down all numbers for later input.)

Move: Here is an easy way to xlate or rotate object1. If there is any object movement in your animation, you want to make sure that the object will be visible, and this is a nice way to test it. If you have modelled an object or group of objects that will be animated, you may wish to modify CAMCNTRL so that the Move option will move your own models, and not just object1.

Startup
STARTUP.CTL is for you to use for the beginning of your animation script file. It sets up the spline from the five control points and then erases them to keep them out of the camera's way. Remember to input the same number of points in this program as you did in CAMCNTRL.CTL.

Some Pointers
EXAMPLE.3D2 was provided for just that purpose, an example. The idea is for you to place five control points and an object1 in your already modelled universe.

Remember you must always have a object named object1 in CAD-3D. CAMCNTRL.CTL looks for this object when it runs. Also, keep flipping between CAMCNTRL and CAD-3D until you get the control points in just the right place.

Simple But Effective
Yes, these programs are very simple, but they solve many problems and make camera animation much faster without as much trial and error. Play around with it, and make changes to suit your own animation. Maybe even add a second spline for object movement to coincide with camera movement!

Rick May operates Rick May Productions, a computer graphics and animation studio in Florissant, Mo. This is his first program for START