Is there a way to get preprocessor lines to control which #pragma lines are used? I'm trying to use #pragma_multi_compile keywords and it seems that the associated #if blocks are ignored where #pragma statements are concerned. I'm trying to collapse some blend and tessellation shaders for easier updates, but it seems like neither the properties block nor the #pragma lines respect the keyword preprocessor tests. This makes sense, but I wondered if there was a magical way of achieving this or a similar effect some other way. The main issue right now is that the tessellation feature requires a single-parameter vertex shader, while the normal surface shader workflow requires two, so the signature conflict prevents using a single line like "#pragma surface surf Standard vertex:vert tessellate:tessEdge nolightmap addshadow" and the preprocessor doesn't help. Any insight would be appreciated! Adrian
Unfortunately no. Your best bet is to use cginc files to put common code, or even all of the code, and have separate shader files to define the #pragma lines.