I am following the shader tutorial for Panda3d and until now everything was very well explained and understandable. Thank you very much, I was looking for exactly such a tutorial.
However, I now ran into a problem, and I was hoping you might be able to help me. In the 4th tutorial we see a custom variable, l_my. In the vertex shader we assign vtx_color to l_my, then in the fragment shader we assign l_my to o_color.
What I don’t understand is the fact that doing that the colors of the three cubes are not the correct ones from the egg file. The shader comments mention that we assign the vertex coordinates to the color directly, which would explain the odd colors on the cubes. However. I don’t see that coordinates are being assigned to the color – as said, the vtx_color is assigned to l_my (which sounds correct to me as a shader noob).
Any ideas what I am misunderstanding here?