Maya CGFX Shader : Inspired by Guilty Gear Xrd GDC Presentation

Junya C Motomura's gave an amazing GDC presentation of how Guilty Gear Xrd achieved it's incredible 2D look.  And I was inspired to write a variant of what Junya presented as a Maya Cgfx Shader.  Check it out, it's available on Github:

https://github.com/miketon/Maya_Tools/tree/master/Shaders/Toon_xrd

Notable differences :

  * Team Red appears to be straight up using a dot product.  This shader uses a dot product to do a uv lookup on a 1D ramp texture.  Affords more flexibility with changing light-to-shadow palette via texture edit.  Tradeoff is lower perf

  * Team Red actually altered the normals, I'm using vertex color (red channel) to alter the uv lookup.

Future improvements could include other 2D effects such as ziptone and crosshatch shading.


Halo 4 Custom Shader

Digging through my old archive, I found this old documentation for a matcap shader I wrote for Halo 4 a few years back.  Our pipeline was entirely proprietary, and didn't feature any kind of node based editor such as Unity's ShaderForge or UDK's shader editor.  

Luckily my previous experience working on the hardware side at Nintendo Technology Development and interfacing with OpenGL at a low level helped me find my way around our engine.  

Much of my work nowadays doesn't require the level of linear algebra as it used to, but I still find concepts derived from that foundation useful for debugging collision and raycasting logic in my character/camera controllers.  Like anatomy knowledge, linear algebra has a very low decay, and I'm very glad to have invested in adding that to the tool belt.

Shaders : The dark side of lighting

IMHO, well crafted shaders address both how light reacts to the surface (diffuse and specular), as well as how the surface behaves absent of lighting (ambient).  Generally what happens when the ambient aspect is neglected, is that lighting flattens out to black.  

This can certainly be used as a great artistic effect, but more often than not it's unintentional.  As a result the spatial aspect of play spaces/environment becomes greatly diminished.  Players have to work harder to discern the play space, leading to visual fatigue.

Unreal : Shader Development

Collaborating with the principle players from art and tech to deliver solutions are my favorite project highlights.  Here's a slice from my time working on Unreal Shader Development for an older Sony Online Project:

  • Initial Standard : The project's character clothing used the standard normal, specular, diffuse uber shader.  There was an interesting tweak to the specular to 'pop' more detail with front facing normals.  And that worked great on surfaces such as leather and velvet.  But not so much on on cloth and materials where specular was minimal.
  • Hue Shift Pivot : Adding a complementary hue shift to the tangent facing normals of the material colors on the character's cloth pumped up the palette.  I utilized calculations already being processed to add minimal perf cost to the process.
  • Art Direction : The art director liked the expanded palette, but felt my shaders defaults were too heavy handed with color usage.  I worked with him to dial down many of the settings(it's easier to rein a shader artist back to push him for more:).  The Lead Tech Artist also exposed a custom sample of the dominant scene light.  Changing the shader to sample the complementary color from scene lighting as opposed to local material colors.  The final look something more along the lines of the palette brilliantly achieved in Unchartered 2. 

Shaders : Hue Shifting

Nintendo characters tend to emphasize shape and volume over details.  In addition to value attenuation, a complementary amount of hue shifting can really emphasize the simplicity and beauty of this style.  And the shaders I've adapted from this approach can run on a wide set of hardware from fixed pipeline mobile devices to highly programmable CGFX/HLSL environments.  Normals are fundamentally one's best friend for getting high mileage here<g>.