Giraffpaj

12-06-2017, 03:30 AM

Im struggling with an texture ontop of a two triangles,

recently when I only had a vertex Shader and a Fragment shader, everything worked fine, with applying the texture to the square.

but Then I added the geometry shader and the square just picks up one color.

I used a varying variable to pass the texCoord between v shader and f shader, am I supposed to use a varying var from v shader to geometry shader instead or just from geometry to f shader?

Where does the interpolation usually take place?

recently when I only had a vertex Shader and a Fragment shader, everything worked fine, with applying the texture to the square.

but Then I added the geometry shader and the square just picks up one color.

I used a varying variable to pass the texCoord between v shader and f shader, am I supposed to use a varying var from v shader to geometry shader instead or just from geometry to f shader?

Where does the interpolation usually take place?