Most CG lights only lose luminosity as they fall off. This can look dull.
If you can calculate what amounts to the light's facing ratio with respect to objects, you can use it to drive ramp-based color on the light itself.
Here's a brief overview:
1) Get the world position of the point being shaded by using the samplerInfoNode.
2) Get the world position of the light using the lightInfo node.
3) Subtract (1) from (2) to get a vector from the surface point to the light.
4) Get the surface normal in camera space using the samplerInfo node.
5) Convert the surface normal to world space using a vectorProduct node set appropriately.
6) Take the dot product of (3) and (5) using another vectorProduct node set to "dot product" -- this is the light facing ratio.
7) Clamp the light facing ratio (6) to between 0 and 1.
8) Run the facing ratio intoi the V-coordinate of a V-ramp set to colors of your choice.
9) Loop the output of the ramp back into the light color.
You now have angle-based hue falloff built into the light.
To explore this in detail, download the maya scene file:
hueFalloffLight.ma
Author: jfrancis
Submitted: 2005-08-26 01:12:22 UTC
Tags:
Software: Maya
Views: 51,996
Related Items
-
1-Click Texture Batch Bake for Maya for Maya 1.0.0 (maya script)
$20.00 (USD) -
"Rapid Rig: Poser" for Maya for Maya 2.0.9 (maya script)
$20.00 (USD) -
The Alchemy Tools for Maya for Maya 1.0.0 (maya script)
$20.00 (USD) -
Arab Rig for Maya with Ncloth simulation for Maya 0.0.1
$99.00 (USD) -
Poly Tools for Maya for Maya 0.4.2 (maya script)
$20.00 (USD) -
Gradient Data Manager script for Maya for Maya 1.1.1 (maya script)
$20.00 (USD) -
Casual Male 03 Rigged for Maya 3D Model
$39.00 (USD) -
Quick set panel for Maya 1.0.0 for Maya (maya script)
$20.00 (USD) -
Wireform for Maya 2020-2023 1.0.0 for Maya (maya plugin)
$49.00 (USD)