WRITING SHADERS
FOR RENDERMAN AND MENTAL RAY

Sometimes, in the quest to create the perfect image, it is necessary to get one's hands dirty in the complicated business of writing shaders. Be it a new lighting equation or a neat trick from this year's SIGGRAPH, shader writing is the single most powerful way to customize your rendering and set it apart from the herd.

In this 8 week online vfx training course we jump into the deep waters of shader creation for the two most popular rendering engines: Renderman and mental ray. We will see how many concepts transfer from one to the other easily - and we'll see where each differs. We will cover a wide range of shader types and uses, including: surface, light, volume, displacement and lens shaders - illumination, procedural texturing, raytracing, HDRI lighting, ray marching, and more.

This material was developed originally as a commercial CGSosciety Maya course. It is now freely available.

WEEK1

The first order of business in our class is to setup our Maya environment and write the most basic of all shaders: Hello World. We also explore the idea of textures and texture coordinates, and see how we can debug our code when it invariably doesn't work the first time.

Welcome
Writing a Hello World shader
Writing a brick shader
Renderman tips and tricks
Homework
Office hours

WEEK2

In our second week we get straight to the business of procedural noise - some of the most powerful concepts in shader writing. We'll cover many of the basic types, and see simple applications.

Writing a Mandelbrot shader
The Perlin noise function
Writing a caustics shader
The fBm noise function
Writing a landscape shader
Tubulence based noise
Cellular based noise
Homework
Office hours

WEEK3

In week three we study illumination models - the mathematics of why different materials appear different under the same lighting. And how that appearance changes as the lighting changes. It's all about light this week.

Writing a Lambert shader
Writing a Phong shader
Writing a Ward shader
Writing a glossy shader
Writing an Oren/Nayar shader
Writing a velvet shader
Homework

WEEK4

This week we look light itself - how to create and manipulate light: shadows, projections, translucence, imaged based lighting, and more.

Writing ambient, directional, and point light shaders
Writing projected light shaders
Shadowing and translucence
High dynamic range image based light (HDR IBL)
Cached lighting with point clouds
Homework

WEEK5

In week five we switch over to the Mental Ray renderer and start writing our shaders in full fledged C. Mental Ray's specialty is raytracing and we explore how to write a variety of raytracing shaders.

Writing a Hello World shader for Mental Ray
Tips and tricks for Mental Ray
Notes for Windows
Writing a reflection shader
Writing a glass shader
Writing an ambient occlusion shader
Writing a "Portal" shader
Homework

WEEK6

Coming 3 August 2015

ABOUT

Karl Stiefvater is a visual effects artist with over 20 years experience in the field of computer graphics. He has worked on games and film, in academia and the industry, with traditional and real-time rendering. Karl's accomplishments include: effects for the Nebuchadnezzar destruction sequence in Matrix: Reloaded; the swarming sentinel destruction effects used throughout the battle sequences of Matrix: Revolutions; procedural generation of the infamous bottomless pit from 300; the then-groundbreaking HDR lighting shaders for Riven: The Sequel to Myst; those shaders and others developed into the LumeTools shader collection; teaching graphics courses at Washington University; the interactive exhibit Waterworks shown at SIGGRAPH 2001; working on the infrastructure of the metaverse for Second Life. Most recently Karl has been teaching a series of online courses in visual effects programming.

Karl grew-up in a funeral home; he owned/ran a cafe on a naked beach in Mexico; he lived on the streets of San Francisco in a 1970 RV. His three-year-old daughter Lily is the smartest, funniest, and most beautiful girl ever born (except for his wife.)