1
General / Re: glm::mat4 in setUniform?
« on: October 09, 2016, 02:50:57 pm »It's not that hard, just look at the documentation.QuoteThe matrix can be constructed from an array with 4x4
elements, aligned in column-major order. For example,
a translation by (x, y, z) looks as follows:float array[16] =
{
1, 0, 0, 0,
0, 1, 0, 0,
0, 0, 1, 0,
x, y, z, 1
};
sf::Glsl::Mat4 matrix(array);
And then in glm::mat4 you have glm::value_ptr to get a float* out of a glm::mat4.
Thank you that solved it!