A Guide to the Graphics of the Sega Mega Drive / Genesis

Return to Table of Contents

Shadow and Highlight

The VDP supports shadow and highlight (S/H) mode, which either lowers or raises the intensity of a pixel’s color. The mode can be used in several ways. Let’s first look at how to apply shadow to sprites and background planes.

When S/H mode is activated, any overlapping tiles that are set to low priority on both planes will be shadowed. Additionally, a sprite that is also set to low priority will become shadowed if it passes over the shadowed plane tiles.

Here is an example of shadowing from the first stage of Battle Mania 2:

Shadowing seen in the window in Battle Mania 2.

The building window tiles of Plane A and the tiles of Plane B (where the moon is drawn) are low priority—the other tiles of the building are high priority. Only tiles that overlap with the window tiles will be shadowed, such as the moon when it is visible. The main sprites for the player character are high priority, so they are not shadowed even when they overlap with the shadowed plane tiles. However, the sprites of the player’s reflection are low priority, which is why the reflection appears shadowed, and which is why the reflection passes under the high-priority building tiles. In fact, the tiles making up the player sprites and the reflection sprites are identical aside from the shadowing.

Here is a nice use of shadow to create water in Mega Turrican:

This water effect in Mega Turrican is done using shadowing.

This is actually a raster effect. At the start of each frame, S/H mode is disabled, but it is enabled halfway through the frame at the point where the water begins. Both background planes and the player character sprite are low priority. A series of flashing wave sprites is used to cover the transition to the shadowed section and to add to the illusion of water.

Let’s consider another classic example from Ranger-X:

The far background in this scene from Ranger-X is shadowed throughout the stage.

Your first thought might be: this looks like highlighting. When the player opens a hole in the ceiling, the background plane clearly becomes lighter. However, this effect is only using shadowing. The background planes throughout the level are low priority and therefore shadowed from the beginning. When a hole is opened in the ceiling, the game shifts the transparent tiles under the hole to high priority, which cancels the shadow effect on the far background.

In the above Ranger-X example, notice that the player character’s color does not change when it passes under the newly lighted sections. This is because the sprites are set to high priority, so they will not be affected by background shadowing. However, if we switch these sprites to low priority via an emulator, we can see the effect:

The display priority of the sprites has been switched via an emulator for this example so that the player character sprites are now low priority.

It looks nice, but presumably the developers didn’t want to have the player character shadowed throughout the level just for the sake of one effect.

The examples we’ve just seen show how to apply shadow to both background planes and sprites when they are set to low priority. There is a second way to apply shadow, as well as highlight, using a different method, but this method cannot be used to shadow or highlight sprites (sprites can never be highlighted).

When S/H mode is enabled, any sprite pixels that are set to palette 3 color 15 will become transparent and the plane pixels under them will become shadowed. Similarly, if set to palette 3 color 14, the pixels under them will become highlighted. This only works if the sprite in question is at the ‘top’ of the display—meaning there are no planes set to higher priority than the sprite (e.g., if the sprite is low priority and Plane A is high priority, the shadow or highlight effect will not work).

Here is an example of sprite-based highlighting from Mega Turrican:

Highlighting in Mega Turrican.

The spotlight of the enemy is made of sprites that only contain pixels of palette 3 color 14. They become transparent, and the planes under them become highlighted. The spotlight passes over the player character, but since sprites can never be shadowed or highlighted using this method, the player character’s color does not change.

Next: Transparency

Return to Table of Contents

List of Effects:
  1. Introduction
  2. Full-Screen Scrolling
  3. Row / Column Scrolling
  4. Line Scrolling
  5. Animation
  6. Multi-Jointed Characters
  7. Tilting / Rotation
  8. Scaling
  9. Shadow and Highlight
  10. Transparency
  11. Silhouette
  12. Palette Swapping
  13. Vertical Scaling
  14. Sprite Raster Effects

Want to post a comment? You can do so here.