vase shader

Surface and displacement shading techniques can make the geometry that represents a real world object appear far more complex than its true underlying form. This page shows the development of a shader(s) that exhibits a non-uniform response to light. The shader(s) also provide a viewer with the illusion that the surface of an object - in this instance a vase - has a rich sub-surface texture.

 

The main goal of this assignment was to create a realistic vase shader, without raytracing, that gave the illusion of a detailed surface underneath a layer of glaze. This is actually possible with a bit of lighting trickery in the shader source and incorporating a displacement element to create a bump on the surface, something that really should not be possible in a surface shader.

Basically, to create this effect, we have to first calculate the lighting component to a smooth un-bumped surface, save those lighting and normal values, generate a bump on the surface, restore the normal values and project the original lighting over top of the bump, like a seperate layer. We also wanted to create a reflection specular rather than a generic highlight on the surface, but again using no raytracing. Its not really actually reflecting or refracting anything, it just looks like it is.


 

One thing I immediately noticed once I got my reflections working properly, is that no matter how high or low they're dialed in the shader parameters, they still didn't look quite right. They looked close, no doubt, but they still stood out in some way. I decided that it might be worthwhile to multiply the base color of the vase with the environment map, as it seemed to me that the color on the vase would show through in the reflection.

 
With multiply
 
Without multiply

 

Here is the final turntable animation, displaying the color changing by viewing angle and the environment map as the camera rotates around the vase.


source