Non-Dependent Texture Reads

I’m trying to stamp out all dependent texture reads in our mobile shaders. For instance, for reflective I’d like to calculate UV coordinates for the reflection in the vertex shader rather than using the normals in the fragment shader (for models without normal maps).

I can see how this would be done using vert and frag programs, but I was wondering if there was a way to do this using surface shaders. If we need to write everything at the vert/fragment level, we can, but I’d much rather leverage the surface shaders if possible.

I guess you should write a vertex function for your surface shader then. But I’m probably missing something.

Yeah, I’m a monkey. I didn’t realize you could use the full surface path (with a predefined lightmodel and whatnot) and only replace the vertex portion. I thought once I replaced the vert portion I was stuck replacing everything.

The sample:
Unity - Manual: Surface Shader examples - Custom data computed per-vertex does exactly what I need.