/cournia.com/dev/null - vertex toon shading | home |
vertex program toon shading | June 2003 |
Having finally grabbed a hold of a graphics card that is capable of vertex programs, I thought I'd try to write a simple program that took advantage of modern hardware's programmable vertex processing. The first idea that came to mind: toon shading. Using ARB_vertex_program I was able to write a simple program which used the dot product of each vertex's normal with the light as a lookup into a 1D ramp texture:
So given the Stanford Bunny, we get: By drawing the silhouette we get some nice outlines: And throwing in some stencil shadows we arrive at: A scene that's a little more complex: |
|
index |