Terrain tutorial - Part 2
Tutorials in this series:
- Terrain tutorial: Creating a heightmap, modifying brush patterns and shapes, using terrain limiters, using the level tool to create ramps and mesas
- Terrain tutorial - Part 2: Colorizing terrain, importing unique brush patterns
- Terrain tutorial - Part 3: Creating multiple heightmaps at once, dealing with overlaps
- Terrain tutorial - Part 4: Modifying terrain with textures, adding dynamic details
- Terrain tutorial - Part 5: Erasing and Cloning terrain details, exporting terrain for modeling reference, texture tweaking
- In the Terrain panel, click on the Paint Color icon .
- In the "Paint Color" subpanel, above the "default" button, is a swatch showing the currently selected color. The default is a 50% grey, which has no impact on the base texture.
- Choose a color from the Paint Color subpanel
- Tip: If you want very precise control, clicking "Bigger" will provide a larger color wheel.
- The color is chosen by clicking in the inner triangle
- Dragging the indicator around the outside circle, modifies the colors available inside the triangle
- Once you've chosen a different color, right-click in one of the Palette boxes, to set the current color into that box.
- Set four different colors into the Palette
- Clicking "Save palette" will save the current colors to the area server for your current area
- Clicking "Default" will return the current color selection to a neutral gray
- Right-click in one of the previously set swatches to change it to grey.
- Click "Reload palette" to restore the last-saved palette.
- Choose a bright color, such as red.
- Move the mouse over the heightmap.
- Hold down the CTRL key, and without moving the mouse, spin the mouse wheel. Observe how the to-be-affected white polygons change in intensity. This is directly correlated with the intensity of the color that will be painted. End with a low intensity, about 10-25% of max
- The reason it is important to not move the mouse, is because doing this while holding down the CTRL key is used for sampling colors (see next section)
- Release the CTRL key, and using just the mouse wheel, make the brush size about 20% the size of the heightmap
- On a clean flat area of the heightmap, click once.
- In another area of the heightmap, position the mouse, and then click a few times. Note how each click increases the intensity.
- Choose different colors from the palette, and practice painting with them as well.
As a general rule for area design, keep in mind that when it comes to colorizing terrain, a little goes a long way.
Sampling existing colors
It is possible to sample colors that have already been used to paint a heightmap.
- Hold down the CTRL key, and move the pointer over different parts of the heightmap. The pointer will change color depending on what it is pointing at, if it is over an area that has already been colorized.
- CTRL-Leftclick, and this will capture the current color on the heightmap, and make it the current color on the Terrain Panel. This can also be saved into an empty box in the palette, by right-clicking in that box.
Start with a heightmap that has already been painted with various colors
- Choose the Colorize tool
- Click "Default" in the Paint Color subpanel to get the neutral gray as the current color.
- Choose a large brush size (25% the size of the heightmap)
- Choose a low intensity (10% of maximum)
- Click over an area of bright color on the heightmap, and note how each click slightly fades or decreases the intensity of the existing colors.
- Click on the eraser tool.
- Using the mouse wheel, make a very large brush (close to the size of the heightmap)
- Click and drag, to quickly erase colors from the heightmap.
- Note that there is no intensity setting for erasing, it's all or nothing.
- To erase all heightmaps in the area, alt-click. Since this is a major change, this will generate a Confirmation popup, to doublecheck that you wish to do this. (It is your option in the tutorial if you'd like to do this or not).
- Note: The alt-click confirmation popups can be disabled, by de-selecting the Confirm ALT-Click checkbox at the bottom of the terrain panel.
- To do a "slight" erasure without removing things entirely, see Fading colors above.
Importing a Brush Pattern
The third kind of Brush Pattern, is Import, which lets you select any texture file you wish as the pattern to use for the brush. This might be useful as a "rubber stamp" to make repeating patterns of color or terrain, along with other uses. Textures could be anything from a geometric pattern, to an image of leaves, to a company logo or even a photograph of a place or person.
In this section of the tutorial, we will:
- Import the HeroEngine logo as a brush pattern
- Stamp the image in color on a heightmap
- Raise and lower terrain in the same pattern as the logo.
Using an imported brush pattern to colorize
- Create a clean heightmap, with no height or color adjustments. Maneuver your view so you can see the entire heightmap at once.
- Click in the Brush Pattern box to cycle to the "TV pattern".
- Click on the "Paint Color" terrain tool.
- In the color subpanel, choose a bright color, such as light blue
- Choose a square brush
- Set a high brush intensity (Ctrl-Wheel)
- Set a large brush size that's about 80% of the heightmap.
- In the Brush subpanel:
- Click on the "..." button and navigate to:
- Click "OK"
- Still in the subpanel, ensure the Invert Values checkbox is checked
- Uncheck the Use RGB Channels checkbox
- The Channel dropdown box should be at Alpha (for the HeroEngine texture)
- Set the Scale slider to 1
- Set the Rotation to (approximately) 0
- Set Offset U and Offset V to 0
- Hover the mouse over the heightmap, and the image of the logo should now be visible in the white area-of-effect polygons of the brush.
- Click once, and the logo should "stamp" onto the heightmap.
- Observe what happens if you click multiple times, or click and hold and wiggle the mouse back and forth a bit, to intensify the image.
- Click CTRL-Z to undo the image.
- Try modifying various options in the Brush subpanel:
- Move the Scale slider to the far right
- Hover the mouse over the heightmap, and the logo should now be a repeating pattern
- Adjust the Scale by holding down the SHIFT key and spinning the mouse wheel (this will probably be easiest to see between a range of .5 to 3.0)
- Move the Scale slider back to 1.00, and the logo should be back to normal
- Move the Rotation slider to approximately 45, and note how the logo has rotated clockwise.
Using a brush pattern to raise terrain
The brush pattern can also affect the raising and lowering of terrain. In the following example, the HeroEngine logo will be used to make a brush pattern which creates hills and valleys on the heightmap in the shape of the logo.
- Start with a clean heightmap
- Select a square brush shape.
- Choose a Flat Falloff.
- All Limiters should be off, especially:
- In the Brush subpanel, set:
- Scale to 1.00
- Rotation to 1
- Offset U to 0
- Offset V to 0
- Invert Values checkbox is checked
- Select the Edit Height tool.
- Hover the mouse over a clean heightmap, and using the mouse wheel, enlarge the brush size to about 80% of the heightmap
- Click and drag UP, to create a 3D logo
At this point, your heightmap may look like the following (it may be slightly different depending on other settings in the terrain panel):
For further practice, you may wish to try other DDS textures at random from the repository, and see what they look like when you use them to raise and lower terrain. Or, try dealing with terrain that already has hills and valleys, and see what an imported brush texture does to that terrain, versus starting with flat terrain.