From: Mikko Rasa Date: Mon, 8 Nov 2021 16:19:12 +0000 (+0200) Subject: Store object transform in a push constant block X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=6dca30085f7a02155b6e44a33ca4244a4c0691a0;p=libs%2Fgl.git Store object transform in a push constant block --- diff --git a/shaderlib/msp_interface.glsl b/shaderlib/msp_interface.glsl index 724538ff..3ad27c43 100644 --- a/shaderlib/msp_interface.glsl +++ b/shaderlib/msp_interface.glsl @@ -6,8 +6,11 @@ struct LightSourceParameters vec3 attenuation; }; -uniform mat4 world_obj_matrix; -uniform mat3 world_obj_normal_matrix; +layout(push_constant) uniform ObjectTransform +{ + mat4 world_obj_matrix; + mat3 world_obj_normal_matrix; +}; uniform CameraTransform { mat4 eye_world_matrix;