I am actually building a shader and I am getting the error.
Shader error in ‘shader’: Program ‘vert_surf’, output semantic attribute “TEXCOORD” has too big of a numeric index (8) at line 204
Shader error in ‘shader’: Program ‘frag_surf’, input semantic attribute “TEXCOORD” has too big of a numeric index (8) at line 204
I am lost. I don’t understand from where does it comes from. I know that there is too much TEXCOORD. But I don’t understand why my changes change nothing.
The funny thing is if I add #pragma glsl there is no more error.
To solve the error I removed Input uvs. Error solved but I need texture projection so lets try triplanar and the error comes back when I have only one uv and worldpos and worldnormal.
I thought that this comes from too much uv in the Input (I had 3 and worldnormal) but it fails with triplanar now when I compute tex2D and my Input is almost empty as I said.
Can somebody tells me more about this error ? If you need more informations just tell me.
Thanks a lot !
All additional data you request in your surface shaders input structure will add to the TEXCOORDS used, hidden from your manual added data there is some hidden automatically added stuff you can see when looking into the compiled shader.
The automatically added stuff is in most cases the reason for this error, but necessary for the surface shader, if you can calculate your data in any way without adding extra stuff into your input structure, this will most likely solve your problem. It sucks, thats true…
@reefwirrax Thanks a lot ! I changed that and now I don’t get the error. Unfortunately the texture does not applies well I don’t know why, I am investigating
@Marrrk Yep, but the strange think is that I added manually TEXCOORD on my uvs in my Input and there is no error but “only” a texture unwrap strange behaviour. I have the possibility to use triplanar texturing this will reduce the uvs needed but I don’t understand why the @reefwirrax solution suppressed the error and why with #pragma glsl there is no more error too… Yes it sucks…