UNRAVELING
RIVEN
by Tim Forcade
CGW contributing editor
Computer
Graphics World February 1998:
Game production techniques in Cyan's sequel to Myst
Millions
of people, computer literate and otherwise, have heard of the CD-ROM
game Myst, originally published in 1993 and developed by Robyn and Rand
Miller, the brothers behind Cyan (Spokane, WA). Indeed, Myst has sold
more than a million copies, and to date it is the best selling CD-ROM
game of all time. Myst set new criteria for what a computer game could
be, with its contemplative pace, total lack of fast-twitch violence,
mysterious non-goal-directed game play, and - as most who played the
game would agree - graphics so striking, they exceeded any previously
produced in a game.

image courtesy
of CYAN
With
such a legacy to surpass, it's no wonder that Cyan took four years to
produce Riven, the sequel to Myst. But as the saying goes, it was worth
the wait. Riven is truly stunning and is even more refined and well-developed
then Myst.
For
those not familiar with Myst and Riven, both titles are an experience
in the Tolkienesque D'ni civilization - an ancient and fantastic culture
in which physical worlds called Ages can be created by writing their
detailed descriptions in specially prepared books. In Myst, players
found themselves on an island attempting to unravel a mystery spanning
several Ages and involving Atrus and his two sons. Riven's story is
built upon Myst, with Atrus reappearing to charge the player with the
objective of capturing his father, Gehn, and freeing his wife, Catherine,
from her prison island somewhere in the Age of Riven.
The
graphics in Myst were, at the time, groundbreaking. The photorealistic
3D rendered world displayed a level of detail and beauty not known to
games. There was also no interface per se; the images filled the screen,
and players wandered through by clicking to go up, down, left, and right.
But
as beautiful as the graphics were in Myst, Riven goes further. The imagery
and its accompanying soundtrack are cinematic. As you explore Riven,
each frame makes you feel as if you are in a unique space that could
actually exist. Scenes have amazing texture, depth, and presence. Lighting,
both outdoor and indoor, is not only convincing but often provides a
theatrical feel that establishes and holds each set's mood. Riven's
oceans ripple and reflect their environs naturally. Its craggy terrain
and caves display marvelous rocky detail. The live action sequences
and animation integrate seamlessly.
"Rand
and Robyn knew Riven would be bigger than Myst", says Jason Baskett,
CG artist/animator. "They wanted the next level of graphic reality."
And they got it. The Cyan artists' attention to detail throughout the
title is astonishing. For instance, common shortcuts such as bump maps
were rarely used in lieu of geometry. This means essentially every object
and sub-object are fully modeled right down to the individual details,
such as the screws. Whereas many CG images are created using single-sided
models that accommodate just one camera view, Riven's models are equally
detailed from 360 degrees. "There are things on the backsides of models
that the player will never see," says Tim Greenberg, CG artist/animator.
To
achieve this level of graphics, Cyan's first major decision was to switch
from the Mac-based Vision3D from Strata, which was used to develop Myst,
to the SGI version of Softimage 3D and Mental Ray (both from Softimage)
for rendering. The reasoning was due to Softimage's ability to handle
more complex geometry and its superior texture capabilities. Mental
Ray, a shader-based renderer, would be need for lighting, shadows, and
optical effects - not to mention its distributed rendering and allowance
for creating custom shaders.
All
of the game's objects were modeled in Softimage using B-splines or NURBS
with only the islands themselves created using polygonal geometry. "B-Spline
geometry provided more control for most objects while the polygonal
geometry enabled us to break the large island objects apart to facilitate
world assembly and more efficient rendering" says Baskett.
Each
island was produced from intricate hand drawings which were scanned,
detailed in Photoshop, and saved as gray scale maps. These were then
used in Softimage as displacement maps to create the island topology.
Everything else was individually modeled and textured. As the Cyan artists
worked on each object, they would consider how it might function if
real, how its function would affect its look, and then devise its geometry
and texture maps accordingly. For example, in real life a lever would
look worn around its joints and handle, so the artists would build in
that level of detail.
Creating
and applying Riven's image maps was actually more complicated than the
modeling process. Initially, Cyan traveled to New Mexico to take photos
- hundreds, which all had to be catalogued - to serve as the texture
bases. Next, artists spent hours in Photoshop painting, editing, and
perfecting each texture. In addition to texture maps, bump and transparency
maps were used. In fact, working with image maps was so essential to
the process that alongside each artist's Indigo II Extreme was a PowerMac
with 73 MB of RAM used mostly for working on texture maps in Photoshop.
Artists would tweak textures in Photoshop and apply them to the 3D models
in Softimage. Next they'd render the textured model, evaluate how it
looked, and return to Photoshop to make corrections and start the cycle
all over again. Incidentally, Riven's maps range in size to as large
as 80MB, though a typical map averages around 2MB.

image courtesy
of CYAN
Lighting
Riven's numerous scenes was complex as well. Some scenes required as
few as four lights, but occasionally, a scene would need more than 100
lights to achieve the effect Cyan artists were seeking. Exterior
lighting consisted of four Infinite lights (a light source with direction
but no apparent position): a shadow casting sunlight, a fill light opposite
the sun, a ground bounce light, and a blue-sky bounce light. The interior
shots presented much more complex lighting problems, often requiring
numerous shadow casting area lights found in Mental Ray. Area Lights
produce soft, natural-looking shadows by projecting light from a 2D
or 3D object rather than from the single-point sources common to most
CG programs.
Cyan's
numerous custom shaders provided much of the unique and natural look
of the game. Shaders are small programs that plug-in to a renderer,
such as Mental Ray, and expand its capabilities. Karl Stiefvater, CG
technical director, created several suites of shaders that Cyan artists
used to produce realistic lighting, water, camera lens, and landscape
effects.
For
instance, Stiefvater developed a glare shader to provide a realistic
flare around brightly highlighted areas. It was used throughout the
game, he notes, from the bright sky that filters through trees on one
island to the blazing speculars reflecting off a golden elevator on
another island.
Stiefvater
also developed various landscape shaders. One shot in particular illustrates
how Greenberg applied these for natural-looking results. The shot consists
of a spherical hive structure (the rebel stronghold) supported by gnarly
tree roots; it's located in a dark lake at the bottom of a crater surrounded
by shear cliffs. The game required a fly-through of the entire scene,
which normally would mean using the largest and most detailed texture
maps possible on the cliffs. Otherwise, players might notice the lines
that delineate tiled textures or enlarged pixels where textures have
been excessively enlarged. But such maps also can be prohibitively large.
So instead, Greenberg applied a landscape shader that used a noise function
to blend smoothly between three relatively small tiled textures, which
were revealed based on their elevation relative to the crater model.
"This revealed or hid the striated texture according to the dips, curves,
and bumps of the crater's geometry," says Greenberg.
More
of Stiefvater's shaders were used to achieve the natural looking water
that appears in numerous scenes throughout the game. Water was created
by applying three shaders to single polygons: the WaterSurface shader,
which duplicates watery reflectance and transparency; the Submerge shader,
which produces vertical light falloff with depth; and the Ocean shader,
which produces waves.
The
shaders had such a positive impact on Riven's overall look that many
shots developed before the shaders were finished were rerendered with
the shaders. This also kept the game's look consistent. In fact, these
shaders have proven themselves so well that a spin-off company Lume,
Inc. (San Francisco), will be selling them not only for Softimage but
for 3DS MAX, Alias/Wavefront, and LightWave as well.

image courtesy
of CYAN
To
give you an idea of how complex some of these scenes were, consider
these stats for just one island, the Temple island. It has more than
2 million faces, 20,872 models, 96 lights, and 17,985 textures and thousands
of texture and material shaders. Just to load the scene in Softimage
required two hours.
As
for animation, the characters in Riven are primarily composited video.
For the scenes that do include animation, Cyan artists used two types,
Cinepak and an in house developed runtime animation; occasionally, both
were used to animate the same element under different circumstances
for varying effects. Cinepak was used for animation such as the tram
that transports the player between islands; this animation consists
of multiple Cinepak compressed frames produced at 15 frames per second.
The runtime animation was developed by Mark DeForest, effects programming
engineer. It was used to produce such elements as fireflies and smoothly
rippling waves in some 750 masked water shots. "The process applies
a series of sine waves to a single masked image," says DeForest. "This
generates a data file that tells each line of pixels where to move".
Although
human characters weren't modeled and animated, they still demanded a
lot of attention. There are numerous live-action shots, and these required
that cameras and lighting match as closely as possible. Artists also
had to composite the live shots with the prerendered backgrounds, which
they accomplished using Ultimatte software and a blue screen set. "We
used a scene diagram that detailed the positions of each object, light,
and camera to set up each live shot," notes Greenberg.
The
scene diagrams were set up in Softimage using real world units, which
enabled artists to position stairs, doorways, and other essential scene
elements. "We also placed the equivalent of an 18% gray card in test
renders to provide a starting point for color temperature and exposure,"
says Greenberg.
Richard
Vander Wende, who co-directed Riven, used multiple studio lights, scrims,
and diffusion sheets to soften shadows and match lighting between the
CG and live shots. Color balancing the live shots was a painstaking
process of carefully observing, experimenting, and closely duplicating
the CG lighting in the studio. The Ultimatte software provided real-time
previews of the actors composited over the 3D prerendered scenes. Artists
also used it to mask key foreground elements, such as the bars of a
cage that confine the player in the game's opening scene. Interestingly,
the cage begins as real bars: a live actor interacts with the real cage,
which then imperceptibly fades into a CG version of the cage, which
animates open to release the player into Riven at the end of the opening
shot.

image courtesy
of CYAN
Each
shot also has corresponding alpha-channel masks that were used to composite
the live action over the CG backgrounds. Michael Sheets, CG compositing,
used Adobe After Effects to refine and tweak each set of masks and to
produce the finished composite. Select live shots also were morph edited,
which enabled several takes to be seamlessly cut together. This made
it easier to produce multiple game play variations without the need
to reshoot each entire sequence.
Rendering
Riven was an enormous endeavor. There are about 4000 frames in the final
title. Even with as many as 12 Indigo II Extremes, two Solid Impacts,
and four Challenge L Servers, Riven's huge model created serious production
bottlenecks.
After
each series of frames was rendered, game play and navigation was previewed
using a custom HyperCard stack called World Starter, which was written
by Richard Watson, lead programmer. This enabled Cyan artists to click
through any part of Riven sequentially - looking right, left, up, or
down - while automatically loading the corresponding image for viewing.
As such, they could play each game segment and verify that its navigation
was smooth and camera placement consistent. Each sequence was carefully
reviewed and evaluated by Robyn Miller, Richard Vander Wende, and Rand
Miller. Every bug and suggested improvement was noted in World Starter's
comment field, which was used to track and perfect the game's final
version.
As
you might imagine, the scope of the computer graphics involved in Riven
goes far beyond the sampling detailed here. Sophisticated software and
hardware notwithstanding, it took and extraordinary amount of energy,
creativity, and dedication to create Riven. The result is an extraordinary
adventure in a class by itself.
|