by NM-8 in Materials, Shaders, Textures

An all in one shader for eyes

Color the Iris, set its size, squeeze it if it's a dragoneye, set depth for a fake refractive effect and amplify the translucency of the iris.
This shader is meant to fake the complex geometry of an eyeball.


No Textures needed!
No UV-Maps needed!



eyeball/iris1/iris2 : coloring the eye.
distort : how much does noise mix the colors.
scale : the scale of the noise.
homogenious : relaxing/stretching the noisepattern in radial direction.
iris%/pupil% : the radius relative to the eyeball surface in percent.
stretch : squeeze the pupil to a slit to simulate a cats eye.
depth : refractive fake effect to simulate depth of the pupil (works best if stretch is 0).
caustic : intensity of the translucent effect.
bump : bumpintensity of the iris-noisepattern.
vector : the space of the mapping. Input>TextureCoordinate>Object will direct the iris in z-direction of the object coordinates.

As the stretchvalue squeezes the eye, you can animate it to transform the pupil from round to slit, like a human transforming into a dragon.

The pupil is oriented into the -z Axis of objectspace. so eyes will look "down" initially.