EMAIL: thorkell@san.rr.com NAME: Collins Mark TOPIC: Alien Invasion COPYRIGHT: I SUBMIT TO THE STANDARD RAYTRACING COMPETITION COPYRIGHT. TITLE: Payload COUNTRY: USA RENDERER USED: POV-Ray version 3.1g.watcom.win32 TOOLS USED: Media Studio 6.0 to spatially blur each frame (blurred images are more friendly for MPEG encoding) and convert the bitmap files to an AVI file of different size (no other post processing was performed, whatsoever). AVI2MPG1 to convert the AVI file to an MPEG file. Microsoft Paint, to create a height field that Povray used to create the background hills L-View Pro 16, to blur the height field (created by Paint) and save it as a Targa file. CREATION TIME: 48 hours 47 minutes of rendering time. A month or two of what would otherwise be free time. HARDWARE USED: 650 MHz Pentium III; 256 MB of PC-133 SD-RAM; 133 MHz front side bus; 7200 RPM Ultra DMA hard drive. VIEWING RECOMMENDATIONS: Real Player for Windows 98/NT works well. If you view at 200% size, sit a healthy distance from the monitor. The compression artifacts are pretty bad (it's tough to fit 74 seconds into 5 MB). See section "lessons learned" for details about my MPEG encoding trouble. ANIMATION DESCRIPTION: Payload explores two complementary aspects of the "Alien Invasion" theme. The animation shows Xavier the slug being abducted by the invading humans, who put him on an exciting ride. Complementing this, the humans are pretending (in their world of make-believe) that Xavier is a space alien himself, coming from another planet to invade earth in the model rocket ship. DESCRIPTION OF HOW THIS ANIMATION WAS CREATED: I have come to the conclusion that POV-Ray rules. This animation was created using both the standard and some non-standard [see below] animation support in POV-Ray (but everything was done in POV-Ray, none-the-less). Slug: The slug, made of blobs, cylinder's, a cone, and spheres, was by far the most complex object. Using the standard POV scene description language, I gave the slug various autonomous behaviors including automatic eyeball position movement, automatic blinking, automatic breathing, and automatic slug-tail wagging. The automatic features have a clear pro: I only had to declare an instance of the slug object, and it takes care of much of the detailed movement on its own. Automatic eyeball position movement: This movement was accomplished for each eyeball, by individually modeling the acceleration, velocity, and of course the position of each eye ball. Position is the integration over time of velocity, and velocity is the integration over time of acceleration. Since frame based animations are discrete in time, this simplifies to the current position is the last position plus the current velocity. The current velocity is the last velocity plus the current acceleration. There were four acceleration componets used for each eyeball. All components have scalable strength. These four acceleration components are described as follows. (1) Random, filtered acceleration vectors. This was accomplished using POV-Ray's standard random number generator, using a new seed each frame. The random vector streams were filtered by 63rd order finite impulse response (FIR) filters with a truncated sinc-function impulse response, coded using the standard POV scene description language. One limitation of the POV scene description language is that there is no standard way to reference information from previously generated frames (such as random vectors, velocity, position, etc). Only the clock variable is passed to the current frame, and this is unsuitable for filtering purposes. Therefore, in implementing the FIR filters (one for each eyeball), I had to use POV-Ray's standard file functions. The 63rd order filter (as opposed to a lower order) allowed me to reduce the filter noise bandwidth to 1 Hz assuming a 30 Hz frame rate. Without the filtering, the slug's eyes looked as though they were getting hit with sledgehammers. The random vectors generated from the previous 63 frames were stored in a file. While parsing each frame, the file was read, updated, and rewritten. The same file stored each eyeball's current velocity and position for use by the next frame, as well as the current seed value. Although all of this probably isn't a standard use for the POV-Ray language, POV-Ray handled it remarkably well. POV-Ray rules. (although there are some cons of this approach described below) (2) Returning acceleration. This acceleration component is proportional to the distance away from the desired eyeball position, that is specified by the main animation file, in the direction toward the specified desired position. In other words, this is the force that pushes the eyeball back to where it is intended to be. (3) Viscosity. This component of the acceleration is for damping, which keeps eye position from becoming unstable. The viscosity based acceleration's magnitude was proportional to the square of the eyeball's velocity. The direction of the viscous acceleration is in the opposite direction of the velocity. (4) Dry friction. Like viscosity, dry friction is for damping. This component adds a constant acceleration value in the opposite direction of velocity. Automatic blinking: This was also frame based, using POV Ray's standard file functions, and does not use POV-Ray's clock variable. In each frame, a file is opened which checks the status of the blinking. If a blink sequence is occurring the blink sequence continues. If the blink sequence is not occurring, a random number is compared against a predefined threshold. If the number is less than the threshold, a blink sequence begins. The file also stores the seed value (used by the random variable), such that a new seed value can be used for each frame. Automatic breathing and automatic slug-tail wagging: These were file based as well and do not use the clock variable. The file stores a continually incrementing number, and using sin() functions, the tail is moved, and the size of the abdomen sphere changes. These could easily have been done with the clock variable, but I used the frame based method for consistency. Cons of file-based (frame-based) movement: (1) Althogh the general position of each eye is specified by the main scene file, the precise position of each eye is unknown until the animation is complete. (2) Each continuous scene, or sequence, must be rendered all the way through, continuously. Rendering scenes, or parts of scenes out of order is a recepie for disaster since the object's movements follow the order rendered, and not necessarily the final animation order. I initially thought that was of no consequence to me since I had planned to create my scene file to render the entire animation from start to finish. But, over half way through the final rendering, my computer crashed. I continuted the rendering, backing up a couple frames from the last known good frame, but there is no way to back up the slug! Fortunately the discontinuities in slug movement are so minor they are undetectable. But, this scared me enough such that I am rethinking my approach for future projects. Besides those mentioned above, all other aspects of the animation were performed using POV-Ray's standard animation support that uses the clock variable. Grass: There were really two types of grass, fake grass and real grass. The fake grass as simply a texture defined by POV-Ray's color-map functionality, mapped on a plane. The real grass was for close ups. Each blade of the real grass was made by the union of two spheres, bounded by boxes. The grass blade was then re-produced a large number of times on a box made to look like dirt. Each blade had a random position and a random rotation on this box. However, another rotation element was used that allowed the blades to sway a certain amount dictated by the summing of sine waves. This effect allowed the grass to "blow" in the breeze. Careful use of the camera was implemented to hide the fact the block of real grass was only 5x5 units (ft) in size. Trees: There are two types of trees, real trees and dumb trees. Real trees were done by randomly placing leaves around a branch, and placing those branches at random rotation angles around a trunk. Like the grass, allowance was made to alter the rotation slightly by the sum of sine waves to give the effect of swaying in the wind (I love Fourier series stuff, if you couldn't tell). The smaller trees seen in the animation are actually just individual branches. Dumb trees were made out of simple cones, cylinders, and spheres. They can be seen in the far background. Rocket: The rocket body is pretty straightforward. The smoke is just a bunch of spheres, having a semi-transparent texture, and a pattern as dictated by the "bozo" keyword. Parachutes: A bi-cubic patch was used to create the parachute object. I actually edited the coefficients by hand until I found the desired shape. POV-Ray suggests using a third party program to make a bi-cubic patch, but I found it easy enough to work with by hand (plus I didn't have any such third party program at my disposal). Baseball diamond: The only complicated part of this is the fence, which was just made with a bunch of cylinders. Text: Text was done using POV-Ray's standard text functions using fonts from my Windows/fonts directory. LESSONS LEARNED: (1) I will reconsider using the frame based animation in the future. It worked very well this time, but it's risky for last minute editing. (2) Get a good MPEG encoder. I have Media Studio Pro 6.0, which has an MPEG1 encoder, but it is not very good at all. AVI2MPG1 works much better, but has it's own quality limitations. I couldn't get CMPEG to sync up to my uncompressed AVI file (using AVIRIP that comes with CMPEG), so I didn't use it. The quality of my final MPEG in this contest really suffered (using AVI2MPG1). (3) Create textures with lower contrast if they will be seen far in the distance. As you can see for yourself, the "fake grass" flickers in the distance, and this eats up MPEG encoding resources. Source code included in payload.zip: The final animation was rendered all at once. I have included the POV scene description language source code for your reference in the payload.zip file. If you care to re-render it, simply open up Payload.pov with POV-Ray 3.1g, select the payload_anim.ini file, and it should render the animation from start to finish. I do have a couple of notes though: Note #1. The payload_anim.ini file contains a line in it that places the windows/fonts directory in the path. But I added this line to the file after I copied the appropriate fonts to povray/include directory. If POV-Ray has problems finding these fonts, copy the appropriate fonts from your windows/fonts directory to some directory in POV-Ray's path. These fonts are used for the license, the opening credits, and the rocket decal. Of course, all this assumes that you are using Windows98. Note #2 The slug object has been replaced with a simple sphere in my submitted files. Forgive me, but I cannot bring myself to make the slug object public at this time. The rest is there though.