Here is my vertex shader:
#version 330 core
layout (location = 0) in vec3 vertexPos;
uniform mat4 viewMatrix_;
uniform mat4 projectionMatrix_;
uniform mat4 modelMatrix_;
void main()
{
gl_Position = projectionMatrix_*viewMatrix_*modelMatrix_*vec4(vertexPos, 1.0);
}
I am trying to scale my points by scaling the model matrix as multiples of the identity. Ie,
glm::mat4 model = glm::mat4(1.0f)*scale;
shaderProgram_->SetUniformMat4("modelMatrix_", model);
But I seem to get no change at all. If I add a uniform float and multiply the vertex vector position by the scale, then I get my desired effect.
If the scale is 0, the vertices disappear as expected.
Why is this?