From 2f286e9ec9d872625f8f82bbcdcfc588913ec4a3 Mon Sep 17 00:00:00 2001 From: 3gg <3gg@shellblade.net> Date: Wed, 9 Jul 2025 20:19:47 -0700 Subject: Track active material in the LLR --- src/llr/llr_impl.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/llr/llr_impl.h') diff --git a/src/llr/llr_impl.h b/src/llr/llr_impl.h index ada2d79..3f6a68f 100644 --- a/src/llr/llr_impl.h +++ b/src/llr/llr_impl.h @@ -43,6 +43,7 @@ typedef struct LLR { bool camera_changed : 1; // Whether the camera parameters have changed. bool lights_changed : 1; // Whether the lights have changed. bool skeleton_changed : 1; // Whether the skeleton has changed. + bool material_changed : 1; // Whether the material has changed. bool matrix_changed : 1; // Whether the matrix stack has changed. }; uint8_t changed_flags; @@ -53,6 +54,8 @@ typedef struct LLR { ShaderProgram* shader; // Active shader. Not owned. + const Material* material; // Active material. Not owned. + vec3 camera_position; mat4 camera_rotation; mat4 view; // Camera view matrix. -- cgit v1.2.3