I am new to OpenGL ES 2.0, and cannot understand the following simplest shader:
attribute vec4 vPosition;
void main()
{
gl_Position = vPosition;
}
My question is, since a position would be a vector of (x, y, z)
, why is gl_Position a vec4 instead of vec3?