If the art work is a shaded sphere, then we can apply the lit sphere
model of the last section directly, using the art work as the
``photograph.'' Figure 3 shows artistically rendered
spheres and the resulting lit sphere shading applied to a 3D model.
Note that complex shading and indirect lighting effects encoded by the
artist transfer naturally to the rendered images.
However, it is too restrictive to require that an artistically rendered sphere be produced for each geometric object in the scene. Instead, we derive a method for extracting lit spheres from source art. Suppose that a piece of art work contains surfaces with locally spherical patches. These patches possess an approximately correct distribution of normals. Thus, we can approximate the artistic lighting model by projecting the shaded patch onto a lit sphere. The patch may lack part of the hemispherical normal space or distort the distribution of normals. Thus, our system must provide a method for modifying the mapping from the patch to the lit sphere environment map.
It is easiest to explain our interface by walking through an example, illustrated in Figure 4. A user starts by loading a 2D artistic source image. The user then selects a triangular region in the source image. A corresponding spherical triangle is automatically created on the hemisphere. The user can interactively move and edit both triangles. Moving the planar triangle changes the texture coordinates of the corresponding spherical triangle. Moving the spherical triangle changes the set of normals which correspond to the illumination in the texture. The user can proceed to create triangles and stretch them over the hemisphere until the entire set of normals has been covered and the desired artistic effect is achieved. The effects of all edits can be observed in real time, providing useful feedback to guide the user's choices. Any gaps in the resulting lit sphere are patched using the splat-push-pull method of Gortler et al. [6].
The user should have some control over the parameterization of the image triangles so that the texture can be manipulated to achieve a correct distribution of normals. As illustrated in Figure 5, we provide a simple approximate mechanism that works well in practice. The edge of each planar texture triangle has a ``midpoint'' which the user can slide along that edge. The midpoints along with the vertices of the planar triangle imply a 4-1 subdivision of the parameterized triangle. This is mapped to a uniform 4-1 subdivision of the spherical triangle, as shown in Figure 5. The result is a piecewise smooth distortion of the texture with continuity along the boundaries. Any unpleasant artifacts due to the discontinuity along the boundaries can be diminished by applying Gaussian blur to the resulting lit sphere map. The lit sphere maps are stored as images like those seen in Figure 6. The central pixel corresponds to the normal which points toward the eye, and the peripheral edges to silhouettes. Our method employs the SGI environment mapping hardware to achieve real-time display, thereby facilitating user-directed interactive lighting of scenes.
|
|
|
| Load a 2D source image~\cite{olivia93} and select a triangular region from the 2D source image (left window). A spherical triangle is automatically created on the hemisphere (upper right window). | Move the corresponding spherical triangle into place on the hemisphere. | Our interface allows the user to create additional spherical triangles, mapped from the same 2D triangle created previously. Now the user moves the newly created spherical triangle into place. |
|
|
|
| Our interface also allows users to select a new region in the 2D source image, which also automatically creates a spherical triangle on the hemisphere. | Now the user moves the corresponding spherical triangle into place. | Again the user instances the previously created 2D triangle and moves the newly created corresponding spherical triangle into place on the hemisphere. |
![]() |
![]() |
|
| We have covered the entire hemisphere, but need to minimize the discontinuity between regions. | The mapping between planar and spherical triangles can be changed by sliding the midpoints on the triangles in the 2D source image. These sliders can be used to exagerate shading at the boundary of the triangles, or to help create some continuity between spherical triangles. We can then apply the lit sphere to the appropriate parts of the model. | |
Each object in a scene can be assigned a unique lit sphere map (see Figures 6 and 7). We provide a complete facility for moving between objects, adding, modifying, and deleting both spherical and planar triangles, and for loading image files. For a given object, it is not required that the user choose adjacent triangles or even find the correct distribution of normals in the image. Some interesting effects are possible by violating the assumption that the pieces are drawn from the same locally spherical patch. In the example illustrated in Figure 4 we only needed to choose two triangular regions in the source image, instance those 2D triangles to create four spherical triangles, and then place the spherical triangles on the hemisphere to create a lit sphere.
An important issue is that the geometry to which the shading model is
targeted may reflect light or cast shadows onto itself. In addition,
surfaces in the scene may be close, whereas the surfaces in the source
art from which the illumination models were drawn may be distant, or
vice versa. Thus, indirect lighting effects may be incompatible.
Furthermore if several art sources are utilized, the
artistic illumination models may be inconsistent.
We leave it to the user to sort out which assumptions can be relaxed for
their application, and provide real-time feedback to guide their
choices. We have found that sensible violations do not degrade the
resulting output image, allowing the user to exercise a large degree
of creative freedom in the selection of source art work.