More work on Material system.

Signed-off-by: John McCutchan <john@johnmccutchan.com>