attributes, options and message-passing

Exercice Ia write a surface shader that takes its color from a user attribute
using: attribute()
Tips:

 

img

Exercice Ib

write a surface shader that takes its color from a user option
using: option()
Tips:

 

img

Exercice II

a surface that is red if visible to raytracing, green otherwise
using: attribute()
Tips:

 

img

Exercice III

a surface that gets its parameter values from a light, and a light shader that gets its parameter values from a surface
using: lightsource() and surface()
Tips:

-this is called message-passing.
-although this type of message-passing is deprecated qith the co-shaders, you should be failiar with it's useage because of the vast number of shaders that used it.

img

 

 

Content on this page requires a newer version of Adobe Flash Player.

Get Adobe Flash player

 

 

- home - curriculum - competences - gallery -MEL scripts - shaders - contact - links -