Build a movie generator and a movie

This program is similar to the previous movie. For this assignment you are to develop a 3D movie with at least 3 "actors". The actors are to be moving relative to each other. In addition the camera view point is to also be changing.

It is highly recommended that you "story board" this before you program it. This will allow you sketch out the relative motion and camera work without cutting any code. You may want to try several stories before you pick one to code.

There is simple way to create complex movements. You need a input file, with each line containing the following information:

Assume agent 0 is the camera and the other agent numbers are items you specify. You will read in all of these lines (8 tuples). We will want to display more than the input specified time points. So we will display some number of images, say 100. The first time point will be the lowest time value in the input. The last time point will be the largest time value specified in the input. For each point in time that you want to display a scene, calculate what time it would be in the input time scale. Then determine for each object where it should be displayed and how it should be orientated. Do this based on interpreting the values in the input for that agent. If the current (display) time proceeds any input values specified for that agent, it is not to be displayed. If the time exactly matches an input time value, display according to the specified values. If the time lies between two input specified values interpolate all of the location and orientation values between the two time points. That is, determine the per-cent of the distance covered on the time line from the previous time point, for that agent, to the next time point, for that agent. Then use the parametric form for a line to prorate the x from the previous time point to the next time point. Do this for the y, z, rotate x, rotate y, and rotate z. If the current time is greater than any time specified, for that object, leave it at the location and ordination last specified.

If the first time only specifies the camera (agent 0), the display is empty. If an, item is specified only once in the input, it is first displayed at the specified time and then continues in the image.

If you want items to spin, you will need to do two things. Specify more than one time point on the curve. And use angles greater than 360 degrees. That is, you might want to specify successive turns of 0, 90, 180, 270, 360, 450 to get the effect of a turn.

You can directly use the build-in commands to position and rotate the agents. You need to write the program to handle the movements over time. And then you need to write the data set to cause the movie you want displayed.


NOT PART OF THIS ASSIGNMENT

If you were doing a lot of this, you might want to simplify the input and/or reduce the amount of calculation. You could do this by have the following either in the input, or calculated and storied in the program. Add two vectors to each time point: a movement vector and rotation vector. For example a data value of: 100 2 5 6 7 0 0 0 1 1 1 0 0 3 Would indicate that at time 100 agent 2 is to be at location (5,6,7) with rotations (0,0,0) from defined orientation. For each unit of time, move agent 2 by adding in movement vector (1,1,1) and rotations (0,0,3). That is, until something else is specified, move the object on the line of the vector (1,1,1) and rotate it around the z axis 3 degrees each unit of time.

SOME ADDITIONAL THOUGHTS - starting points for modeling real systems

If you take the previous idea, you have added an description of inertia or translation and rotational inertial vectors. What do you do if you want to have the object, at a specified point in time, to have a predictable location and/or translation inertial and/or rotational inertial? Well, you will probably have to look at this in real world systems. Or you will have to study the real world system you are trying to model or display. This similar to animators looking at films of elephant to determine how they want a image of a dinosaur to move. This could also be asking the shuttle craft pilots and engineers to determine how they achieve a shuttle insertion into orbit. You may want more complex objects. For instance, you may want an object, that when it moves to have a fixed speed or rotation with out further specification. You may want objects that starting at a predetermined point in time start moving, they move slowly for 10 seconds and then move fast for 10 seconds. How can you build things such as these? The simple answer is to pre-specify a the path as we did in the first version of the problem statement. However, if we would like the object to do that without more detailed specification of its path, we will need to build a more complex object in our system and add new parameters to describe how it is to behave. This is basically how the complex computer modeling systems work. Game or real flight simulators have numerous sets of parameters specified to control the behavior of the displayed items. For a particular type of simulated airplane they have the range of speeds it can fly at, how fast it has go to take off, how fast it can turn and other parameters to describe how the object is to move. How about if you want objects to appear and disappear, to change shape or other changes in the image. You would add new types of data and or commands to specify these needed behaviors and characteristics. The input data then starts taking on the characteristics of a programming language.