SPACEFX Version 1.0 Demo Tutorial. 1st June 1997 (c) A.M.Hugo
Description of DEMO.CFG animation project file.
It may make things easier to print this out and follow through step by
step.
DEMO.CFG is the project file responsible for the demo FLI animation
that is available on my geocities web page at http://www.geocities.com./SiliconValley/Sector/3169/spacefx.html.
The demo animation is called spfxdemo.fli and can be downloaded as spfxdemo.zip,
about 182k in size. Spfxdemo.fli does not appear in the spacefx1.zip shareware
archive as I wanted the file to fit on a 1.44M floppy. Additionally, it
is a useful exercise for a user to generate the FLI file!
There are two ways to generate the animation, assuming you also have DTA
installed.
1. Load the DEMO project from the file menu and press DOALL. (Sheesh,
how simple can it get?)
2. Ignore the DEMO project and roll your own.
That is what we will do! After SPACEFX is through, run DTA to compile the
animation FLI file.
1. STARTING OFF.
We are going to make a short animation showing the planet Earth
in the background, a spinning satellite, a passing asteroid, a small comet
and two spacecraft flying through the scene. This is quite complex for
a first animation, so pay attention! (joke...)
The files will use 11-12 Mb of your precious hard disk real estate, but
can be deleted when the animation is done.
Start up SPACE FX and go to the File menu.
Set up a 60 frame project (START FRAME=1, END FRAME=60) or 0-59 for all
you computer geeks...
Go down to BACKDROP and delete the default file so none will show.
As an exercise, go to the List menu and click on the CLEAR button. This
makes sure you start with a clean slate. All objects empty.
Back in the File menu, set WIDTH to 320 and Height to 200. Since we will
be targeting a standard 320x200 screen which has non-square pixels, set
the ASPECT RATIO to 1.20 so that the planets will appear circular in our
final animation. Nothing worse than eggs for planets!
Note that SPACEFX runs in 320x240 (mode-X) and has 'square' pixels. This
means that preview screens may not always match the geometry of your target
resolution.
Next set PIXELS/DEGREE to 4.0 so that our 320 wide screen covers 80deg.
Now time to put something on screen.
2. SKY BACKGROUND.
Go to the SKY menu (ALT-S or click on the heading button mouse-wise).
You can probably accept the defaults.
Make sure that FADE TYPE is off. You can play with it later, I promise!
Make sure that STAR ENABLE is on the NORTH setting. If it is on 'None'
you will not see stars.
We will now make the starry sky as the first object in our animation.
How on Earth do we do that??
Press INSERT. Done! (press INSERT key or click on the button)
Try pressing function key F2. This will switch to the preview screen
so that you can checkout the results of all your hard work. You should
be rewarded with a night sky and stars. If astronomy is your passion you
will recognise ORION on the left and TAURUS in the middle (top).
Press ESCAPE to return to the Menu.
Fiddle with the LONG & LAT settings and press F2 until you're happy.
Note to Astronomers!
I have used the terms Longitude and Latitude in the program instead of
the correct terms, namely, Right Ascention and Declination. It may be that
non-astronomers will understand latitude a little more readily than the
astronomical names. If you strongly disagree, the let me know and I'll
consider changing it.
Then press SAVE button to update if things have changed.
IMPORTANT! Don't press INSERT a second time unless you want TWO starry
skies!
Each press of INSERT will do just that. Add another instance of the current
object to the list.
There is no confirmation dialog for inserting objects, the program assumes
you know what you're doing!
3. ADDING PLANETS.
Activate the Planet menu.
Edit the planet NUMBER for planet 3. This is Earth. The list of available
planets on the right shows the possible selections.
Put X CENTRE at 200 and Y CENTRE about midscreen and DIAMETER 80, press
F2 for a preview.
Hey! How come it's in Black and White?
Hummph.. It's greyscale, actually! With only a few objects, SPACE FX generates
thousands of colours, and will faithfully store them in the 24-bit truecolour
TGA files. Greyscale is the best way to view this on a lousy VGA card!
Hint: Version 3.0 will run in truecolour modes...
Fiddle with the settings a bit. I put POLAR ANGLE at 70.0, LONGITUDE at
300.0 and LATITUDE at -15.0 to show the south pacific.
Next set PHASE at 120 degrees. The spacecraft images assume that the Sun
is on the right hand side so 120 degrees is about right.
Press F1 for instant help on any item you are not sure of.
Fixed objects (like planets) belong in the background. Give yourself a
little elbow room and put it at a REF DISTANCE of 1000. This is the distance
at the START frame, which we use as a reference.
Next press INSERT. Done!
4. SPINNING SATELLITE.
Change the planet to Commsat1. We will put a satellite on screen and make it rotate.
Edit X and Y so that it is left of centre (X = 80), and change Diameter to about 50 pixels.
To make it rotate, we need one revolution for our 60 frames. That is
360 degrees in 60 frames or 6 degrees per frame.
Find LONGITUDE INC and set it to 6.0.
Keep the other settings as for Earth so that it looks compatible.
Then place the REF DISTANCE at 990 so that it will always be drawn in front
of the Earth.
Press INSERT. Done!
This time when you press F2, only the current object (satelite) is previewed.
What happened to Earth?
If you remembered to press INSERT before, it is still in the list.
Go to the List menu. You will see that we have defined 3 objects. They
are the Starfield, Earth and Commsat1.
To get an idea how the whole job is going, go to the File menu and press
the PREVIEW button.
This will plot the current frame on screen and all defined objects will
appear. You should see your starry sky, the planet Earth and a satellite
on the left.
You should also save your work regularly, so pick SAVE PROJECT and answer
'Y' (Yes) to the confirmation dialog box.
5. ADDING SPACECRAFT.
Go to the Bitmap menu.
Set the File name to CARGO.TGA, a simple raytraced cargo ship.
We want the object to come from the left edge and exit stage right.
Try X = -40. This will put it off screen at the Start of our animation.
(If you press F2 it will NOT appear! The computer will faithfully draw
it off screen.)
We want this craft to travel in front of the other objects so put it at
a DISTANCE of 150.
How do we get it to move from left to right?
Set TRAVEL DISTANCE to about 20.0 and ANGLE to (say) 300. For a brief explanation
of each function, press F1 at any time for on-line help.
Press INSERT. Done!
HINT #1: To check if the TRAVEL options work as expected, go to the File menu and change the value of THIS FRAME to say 10 or 20. Press PREVIEW to display where it goes. Then change THIS FRAME to 60 to make sure it has moved off the right hand side. If not, adjust the TRAVEL options. Don't forget to press SAVE to update your object parameters.
HINT #2: When you are busy previewing and adjusting, the 'current object' may no longer be the one that you wish to change. Go to the List menu and highlight your object with the NEXT and PREVIOUS buttons and click on the EDIT OBJECT button. This will automatically jump to the correct menu with all items as saved.
6. CONTROLLING DISTANCE.
SPACE FX draws objects by finding their current distance and plotting the most distant first and the closest thing last. (painters algorithm) The distance settings described above, do not correspond to any particular unit (feet or kilometers). They are the means by which we keep things separate and control movement. As long as you are consistent with distances and travel options, units don't really matter.
7. DELAYED ARRIVAL.
Up to now, all objects 'exist' for the entire 60 frames. We will now
add a second spacecraft and arrange for it to appear suddenly part way
through the animation, say at frame 10.
Fire up the Bitmap menu and change the bitmap to SHIP.TGA, a simple raytraced
spacecraft viewed from its rear end.
To use this effectively, it will need to travel forward into the distance.
Set the DISTANCE at 30.0, and plonk it amidships but below centre, say
at X=160 and Y=180. Make it TRAVEL at 10.0 units distance at a TRAVEL ANGLE
near zero (say 10.0) so that it disappears into the screen.
Check that the X and Y SCALE are both 1.00.
SPACE FX will do the positioning and scaling for us automatically.
Press INSERT. Done!
But not quite done...
Go to the File Menu and edit the START FRAME to 10, our new start frame
for our current ship.
Back in the Bitmap menu (which has not changed) press or click SAVE to
update our ship.
NOW we are done!
You will notice that our current object box reads "FR 10-60" in part. This means that our ship.tga object will only appear between frames ten and sixty. The computer will not bother plotting it for 1 to 9. The downside is that we have to set the START FRAME back to 1 for the other objects we will add (a comet). I didn't have room to add a START and END buttons on each menu. Perhaps later...
Now try File/PREVIEW and check that the ship does not appear before frame 10 and quickly disappears into the distance.
8. COMETS AND FUZZBALLS.
Our next to last task is a comet.
Comets consist of two parts, a tail and a coma.
The tail can be LHS or RHS and the coma is the brightest part of the comet,
the nucleus.
We will make it go from right to left this time.
In the Comet menu, set DIAMETER to 30 pixels.
Set COMET TYPE to TAIL LHS by clicking on the button a few times.
This will make a tail appear to stream out from the nucleus towards the
left hand side of the screen.
Set ASPECT RATIO to 5.0 to make a nice long tail. It will start life at
150 pixels long.
Where to put it?
Since we want it off screen to the right, the centre will be about 75 pixels
past the edge, about 395. In practice you can go lower since the end of
the tail will be rather faint and go unnoticed.
Make it 360.
Put the DISTANCE at about 400.
Colours? How about a fetching shade of pink
(MID COLOUR = 118) and an EDGE COLOUR of Blue
(8)!
Note that since the edge actually fades away to nothing, there will be
very little blue in the final product.
Movement? Try TRAVEL values around 12.0 units and an ANGLE of 90 degrees.
Press INSERT. Done with the tail.
Now the COMA or nucleus.
Change COMET TYPE to Coma.
We are going to have to place the coma over the brightest part of the tail
so that it all hangs together. This point is close to the right edge of
the tail, less 15 pixels. At the START frame the tails centre is at X=360
(off screen). The coma therefore will be at 360+60 = 420. Keep the same
TRAVEL parameters for the coma and tail.
Press INSERT. Done!
9. NEAR EARTH ASTEROID.
The last object is an earth crossing asteroid, also going right to left.
Select the Planet menu and pick CERES for the asteroid.
Give it similar parameters to earth but move it off screen to the right
with X CENTRE = 325, Y is 120 so that it will pass by the lower part of
the screen. DIAMETER is 12.0, but it will go larger as it approaches.
Start it off at a REF DISTANCE of 400.
Put TRAVEL options about 8-10 in DISTANCE and an ANGLE of 120.0 so that
it swings toward us.
Rotate it with ROTATION INCrement of 6.0 degrees.
Press INSERT. Done!
Hmm, perhaps not.
The planet looks a bit dull. Can I spruce it up?
Yes.
Why not try to improve brightness by putting LIGHTING at 1.4? This will
brighten it just a little. (Not too much though!) At the same time, change
BACKLIGHT to 0.15 to improve visibility of the dark side to simulate earthlight.
Press SAVE.
Important! Save the project file and we are done.
10. DOALL
After satisfying yourself that it all works as planned. there is only one more thing to do. Press DOALL and answer yes to the dialog box.
On my 486, the 60 TGA frames took just over SIX MINUTES to create!
Run DTA after exiting SPACEFX.
On my 486, DTA took only ONE MINUTE to compile the FLI animation!
Did you say you had a pentium?...
11. AN EXERCISE FOR THE READER.
This quick tutorial only begins to scrape the surface of SPACE FX.
I have not covered BACKDROP files or FILE SEARCH options.
Also background FADES and colour merges.
Neither have I touched on planets with no maps.
(Try planet 30!)
I have not described halos or the Torus.
Nix about fading in and fading out. (Beam me up, Scotty!)
Zilch about Transparency. (Warbird de-cloaking on the starboard beam, Sir!)
What about Acceleration or putting on the brakes?
How to switch on a Debug dialog box?
Can I view previews in colour?
Can I keep my projects in other directories?
I want to change my spacecraft in frame 42!
Hey, do you really need me to hold your hand??
Go explore!
Why not try to duplicate SUNRISE.GIF? (included in archive)
No, I'm not telling! It is "an exercise for the reader!"
If you find this program interesting, please send me a postcard or an email with your questions, comments and wish-list. Happy animating!
Tony Hugo
hugo@winshop.com.au