Amber Evans
​​​~ Effects Artist ~
This website is old, please visit amberevansvsfx.com for my new site.
ST Coloration
For this project, I was given the task of creating an original shader in Cutter.
For more information about Cutter, visit Fundza.com for more details.
Simple Shaders
For the first part of this assignment, I had to re-create at least three of the simple shaders below.
Re-Creations
|
Cross
if(s < s_cutoff && t > t_cutoff) surfcolor=t_color;
if(s > s_cutoff2 && t < t_cutoff2) surfcolor=t_color;
if(s < s_cutoff3 && t < t_cutoff3) surfcolor=t_color;
if(s > s_cutoff4 && t > t_cutoff4) surfcolor=t_color; |
The cross was the second shader I was able to figure out by myself. After I realized I could add more s_cutoff and t_cutoffs, I found the correct number placement for each cutoff and got the cross shader.
|
Circle
if(((s - center) * (s - center)) + ((t - center) * (t - center)) < (radius * radius)) surfcolor=mix(s_color,t_color,t);
if (flip==1){if(((s - center) * (s - center)) + ((t - center) * (t - center)) < (radius * radius)) surfcolor=back;
if(((s - center) * (s - center)) + ((t - center) * (t - center)) > (radius * radius)) surfcolor=mix(s_color,t_color,t);} |
The circle shader was very difficult for me to do by myself, so it wasn't until after I went to class and saw my fellow classmates examples, that I figured out how to create the circle. When I first rendered it, I kept getting only 3/4th of the circle, and I didn't understand how to fix it. It eventually went away, although, I believe the problem came about from bugs in Maya.
|
Diaganol
float tt=t;if(flip_back==1)tt=1 - t;
float ss=s;if(flip_front==1)ss=1 - s;
if(s < t) surfcolor=mix (t_color,t_color2,tt);
if(s > t) surfcolor=mix (s_color,s_color2,ss);
if(flip_colors==1) { if(s < t)mix (s_color,s_color2,ss);
if(s > t)mix (t_color,t_color2,tt); } |
|
The diaganol was pretty easy to figure out and after seeing how to do the mix function, I added that to the diaganol to make it more complex. |
|
Square
if(s < s_cutoff) surfcolor=t_color;
if(s > s_cutoff2) surfcolor=t_color;
if(t < t_cutoff) surfcolor=s_color;
if(t > t_cutoff2) surfcolor=s_color; |
The square was the first shader that I was able to figure out. It was by mistake, because I was going for the cross shader, but by happy accident, I got this shader.
|
Curve
float tt=t; if(flip_back==1) tt=1 - t;
float ss=s; if(flip_front==1) ss=1 - s;
if(s < t*t) surfcolor=mix (t_color,t_color2,tt);
if(s > t*t) surfcolor=mix (s_color,s_color2,ss);
if(flip_colors==1) { if(s < t)mix (s_color,s_color2,ss); if(s > t)mix (t_color,t_color2,tt); } |
|
The curve shader came after the diaganol, because it has the same if statements, but with a slight difference between the s is greater than t parts. |
Personal Shaders
|
Part of my personal shader code: The Inputs
constant_Shader( float Kfb=1; float opacity=1; float s_cutoff=0.6; float s_cutoff2=0.95; float s_cutoff3=0.55; float s_cutoff4=1; float t_cutoff=0.08; float t_cutoff2=0.5; float t_cutoff3=0.035; float t_cutoff4=0.55; float radius=0.3; float radius2=0.2; float center=0.1; float center2=0.3; color s_color=(0,0.4,0.4); color s_color2=(0, 0.9, 0.9); color t_color=(0.2,0,0); color t_color2=(0.7, 0, 0); color back=(0,0.7,0.7)) |
My Personal Shader in Maya
My personal shader came about after playing with the diagonal shader and their placements. It took me awhile to get the diagonal to change directions and come from the bottom left to the top right. Turns out I only had to add 1 - t to my equations.
Conclusion
In the beginning, I had a hard time understand how to do the simple shapes for the shaders. I was only able to figure out how to do the cross and square by myself, and with help of my fellow students and friends, I was able to re-create all the other shaders. Adding colors was another difficult process, especially getting them to mix, but in the end, I feel that I completed this project successfully.