Terranim

Mode
Point Attributes
Buttons
Preview
Height Graph
Control Panel
Sun and Clouds

Getting Started
The first thing to do when Terranim has been loaded is to import a terrain. You can press the 'Import Terrain' button on the toolbar or select it from the 'File' menu. Once loaded, if you open the control panel by pressing the 'Control' button, you can change the way you view the map, ie Greyscale/Colour. At this stage you should also set the water level to whatever level you are going to be using in Terragen. The default height above terrain box enables you to set the how Terranim calculates the height of a control point when added/inserted. You can now begin generating your paths.
If you are unsure of what any of the colours or symbols on the map or the height graph mean, then just select 'Legend' from the 'View' menu for a description.


Mode
Current Path:
Use this to select the current path you wish to edit. The target path will not be used until the appropriate box has been selected on the control panel (described later). Also, the target path has no advanced properties, only the camera path has these.
Add Point Mode:
Clicking on the map will add a control point with default settings and Terranim will do it's best to draw a smooth curve. You will notice that the curve does not go through the control points but this is necessary to ensure that the curve is second-order continuous. If this were not the case then you would notice jerking of the camera as it travels throught the control points, and the banking would be unrealistic and erratic.

Insert Point Mode:
This mode allows you to insert a point anywhere between two existing control points. You must click very close to the curve at the position you wish to insert the control point.

Move Point Mode:
To move a point you can either click and hold with the mouse and then drag the point, or you can click once to select then click and hold anywhere on the map to drag. You'll know when you are in range to select a point since it will grow slightly in size when the mouse cursor is close enough. As with selecting files in windows you can select multiple control points. If you hold down Ctrl whilst clicking you can select any number of points, and if you hold down Shift you can select a range of control points. You can select all of the points from the 'Edit' menu or by right clicking on the map and choosing 'Select All' from the pop-up menu. The final way of selecting control points is to use the left and right arrow keys.

Set Attributes Mode:
Select a point or multiple points as described in Move Point Mode. You can then set values as described in Point Attributes.

Join Button:
By pressing this when you have more than two control points Terranim sets all values of the last control point to that of the first. The curve is then calculated taking this join into account giving you perfectly smooth looping animations. When you move or change the attributes of the first control point the corresponding attributes are set to the same for the last control point also. You can do this for either/both camera and target paths. By pressing the Join button again (now called the Unjoin button) the relationship between the first and last control point is broken and they can be separated and handled individually once again.

Delete Button:
This just allows quick access to the delete function. Alternatively you can choose delete from the Edit menu, choose delete from the pop-up menu (right click on the map), or you can press the delete key.


Point Attributes
When one or more points have been selected you can change any attribute by typing the value you wish to assign into the appropriate box and then pressing the 'Store' button. If you decide you do not want to change the value/s then press the 'Cancel' button to restore the original values (Although this will not work if you have already pressed the 'Store' button). An added feature that Terranim has is the ability to accept formulas, for example, if you had selected three control points that had velocity values 10, 20 and 30. If you type in 40 into the Velocity box it will set all control point velocities to 40, but if you type *2 then all values will be multiplied by 2 giving you 20, 40 and 60. You can also type /,+ or - allowing you to do any simple mathematical function on all selected control point values.
By pressing the advanced button in the Point Attributes box it pops up the window seen to the left. This box allows you to set any other values for each control point, and they will be interpolated through using exactly the same function that draws the smooth curves for the path. If you wish to use a particular command then select it on the list and click the 'Use This' check box. You will then be able to type values in if points have been selected (only on the Camera Path). Entering values is pretty much the same as on the main toolbar and you can still use *,/,+ and - to adjust/scale multiple values.
The advantage with this advanced box is that all commands listed are custom commands, therefore the user can add/remove commands of their choice. This means that if Terragen is changed at a later date to support more script commands then you can add them yourself without having to wait for a version of Terranim which supports them. At the moment commands can only be added by editing the 'terranim.ini' file, but I will later give Terranim the ability to edit it with a user-friendly interface.


Buttons
Fit Map / Align Window:
This causes the map window to be resized to fit the currently loaded terrain and also aligns the window with the right hand edge of the main toolbar window.

Preview Button:
Opens and closes the OpenGL preview window

Control Button:
Opens and closes the Control Panel window where you can set many properties to do with the animations, the preview and the user interface.
Import Terrain Button:
Shortcut for loading a Terragen terrain, other method is to use the 'File' menu.

Height Graph Button:
Opens and closes the Height Graph window

Sun/Cloud Button:
Opens and closes the Sun and Cloud Animation window

Create Script Button:
Once you have set up everything how you wish in Terranim press this button to produce the script file that Terragen can then read. Make sure that the output file has been set correctly on the control panel and that you have previewed the animation to make sure there aren't any problems.

Preview Control Buttons:
These become active when the preview window is open and they allow you to have a typical media style control over the animation preview. When you press play the button will remain down and will become a pause button which you can press again to pause the animation at any stage. Whenever the animation is paused you can see where you are up to on the map due to an indicator point along the curve (unfortunately this cannot be updated while the preview is playing since it slows it down too much). The stop button will stop the animation and return it to the beginning. Pressing the forward or rewind button while the animation is paused will cause the camera to move forward or backwards one frame. If you click the forward/rewind button with the right mouse button then it will move the camera to the next/previous control point.


Preview
The preview window displays an OpenGL preview of the animation so that you can see roughly what it will look like before you go rendering in Terragen. The preview can be quite slow and so you should adjust the 'Size of Polygons' on the control panel to suit your computer.
Note: Due to these speed problems the OpenGL preview goes as fast as it can, this means it is not playing at the frame rate specified on the control panel and will therefore not give a good indication of the how fast the animation will be when finished.
Also, the larger you have the polygon size, the smoother and faster the animation will play, but it will also be less accurate. This means that in a preview you might seem to fly through a piece of land when in fact you wouldn't, but I find that the default value of 4 usually gives you sufficient accuracy and the height graph is also fairly reliable at telling you when you are cutting through the land. Water is also displayed in the preview and is very handy for telling when you accidentally go beneath the surface (for example, if you were trying to get as close as possible). When you go beneath the water level you can see a darker shade of blue above you and the land that's usually hidden beneath you. The preview window is resizeable, but again this effects the speed at which the animation can play.


Height Graph
The height graph allows you to adjust the z-coordinate of the control points so that the path does not pass through land or water. You can select points in exactly the same way as on the map but they can only be moved up and down by dragging with the mouse or with the up/down arrow keys. The scale of the graph is shown on the left hand side and the path turns red whenever it goes beneath land or water. The graph automatically rescales itself if you drag a point outside the current range of heights, and the distance a control point moves in either direction is proportional to the current scale. The height graph can also be resized by click/dragging a corner or edge.


Control Panel
Animation Control:
The 'Frames/s' variable governs how the velocity is calculated upon and so should be set at the frame rate you plan to compress the animation at. If 'Look Ahead' is selected then Terranim will ignore the target path when creating the script or previewing the animation and will just look ahead down the camera path. 'Auto Banking' tells Terranim to automatically calculate the camera bank values based on the acceleration of the curve. 'Use Target Path' means just that, but it also means that auto banking is disabled.
Overall Settings:
Setting the 'Water Level' to the value which you intend to use in Terragen will cause that level to show up on the height graph so that you can make sure the path does not go beneath it. It also allows water to be visible in the OpenGL preview. 'Default Height Above Terrain' sets the height at which points will be added/inserted above the terrain or water. The update button sets the values typed in, if it's not pressed then 'Water Level' and 'Default Height Above Terrain' values will not be set.

Preview Control:
'Size of Polygons' effects the accuracy with which Terranim displays the OpenGL preview, but it also effects the speed at which it plays. The default value of 4 is sufficient for a Pentium II, but a lower spec. computer may require a polygon size of 6 to 8 to run the preview smoothly. The colour of the landscape and sky in the preview can be adjusted by clicking the colour boxes.

Map Control:
The 'Map Mode' lets you choose whether the map is displayed in colour or greyscale mode. I would recommend greyscale since it is then easier to see the various colours used for the control points and the paths.

Output Details:
The 'Filename' sets the initial path that will be passed to Terragen via the script which is used to produce the bitmap filenames. eg 'c:\temp\anim' is used by Terragen to produce the filename 'c:\temp\anim0001.bmp' and so on.


Sun and Clouds
By selecting the checkboxes you tell Terranim to initiate animation of the sun and/or the clouds. When you set a start and end value for the altitude and heading of the sun Terranim uses simple linear interpolation to calculate the values and place them in the script. For clouds Terranim just passes the heading and velocity values to Terragen which then handles the process of animating them.


Final word

This is the end of the Terranim tutorial, any future updates will be described here and in the version of this tutorial available for download. Enjoy :)


Terranim Copyright ⌐ 1999 Daniel Parnham
dan@terranim.cjb.net
Terranim Website