Animating Procedurally Shaded Eyes?

I used the following tutorial to create nice-looking eyes for my first characters in Blender:

Now that I am learning to rig and animate my characters, I run into difficulty that the procedural eyeball shader, including various levels of transparency for the cornea etc cannot be baked into the eyeball mesh (Am I, perhaps, missing out on something regarding baking here?). And without baking, of course, the texture just shifts around the eyeball mesh when trying to parent the eye to the rig.

What is the regular procedure for creating and animating realistic looking eyes?

I thought the idea of a shader is: procedural and special purpose/effect. So if you wanna bake it, wouldn’t be this absurd ??

You want to split and add in texture coordinates between UV and OBJECT…
That way you can stop elements from slipping as the eye moves…
Bump maps would tend to be mapped with object coordinates while the color and masking, say for veins, would be set for UV
This is only a small part of the total but you might get the idea and be able to make things work…

1 Like

@RSEhlers Thanks a lot! I will be trying that. Do you, perhaps, know a tutorial that explains this in more detail (either paid or free)?

@Okidoki I am not sure, have been using Blender for a year, simple procedural shaders since 6 months and baking since a month :slight_smile: As far as I have heard, the regular practice would be to bake all textures for animated characters. Animating with unbaked textures would be more complicated, especially if the texture needs to stay in a fixed place, like with the eyes…

As I understand, procedural shaders also take a while to compile. You should be able to bake everything you need to a set of textures though. Anything in particular you’re having trouble with?

Tutorials are hard to come by…and I haven’t looked for Paid lessons…
But any basic Eye Rig Tutorial is all you need…like this
Starting at around 18:47 in…

Back to the example, I showed… a quick Gif of a fully procedural eye, animated in real-time…Takes a while to load…

1 Like

@stray I am quite new at baking. This particular eye consists of an iris part, which I successfully baked to an image texture, and an eyeball part, which has a transparent front part through which the iris is showing. Now, If I try to bake the eyeball’s texture containing a transparent part to an image texture, the transparent part bakes as part of the iris showing through, and the overall pattern gets mixed up and looks weird. I have shared the .blend file here, along with the baked image texture:

@RSEhlers Thank you very much! It’s very helpful. We’ll keep working on it!

To Bake a transparent texture you need to add an emissive node …
Transparency will bake as pure Black…
Your Eye-Texture…with the Emissive set up for Baking…the results of the Bake is in the Texture tabs at the bottom…

I went ahead and set up a Cornea node-set and Baked that at the same time… the result is the Left Texture…


and the eye end result with the NEW Cornea node added with your eye-Shader

1 Like