From 195d8fed04cfc815837c5fdf76e50c09a2b1f70f Mon Sep 17 00:00:00 2001 From: Andre Weissflog Date: Sat, 26 Oct 2024 15:06:00 +0200 Subject: [PATCH] sokol_gfx.h: remove sg_shader_uniform.offset --- sokol_gfx.h | 1 - util/sokol_gfx_imgui.h | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/sokol_gfx.h b/sokol_gfx.h index 7ad4d65eb..1dcebbe5a 100644 --- a/sokol_gfx.h +++ b/sokol_gfx.h @@ -2960,7 +2960,6 @@ typedef struct sg_shader_vertex_attr { typedef struct sg_glsl_shader_uniform { sg_uniform_type type; - uint32_t offset; // optional explicit offset into uniform block struct (if zero, the offset will be computed) uint16_t array_count; // 0 for scalars, or >1 for arrays const char* glsl_name; // glsl name binding is required on GL 4.1 and WebGL2 } sg_glsl_shader_uniform; diff --git a/util/sokol_gfx_imgui.h b/util/sokol_gfx_imgui.h index a6f868d83..f2ed488d5 100644 --- a/util/sokol_gfx_imgui.h +++ b/util/sokol_gfx_imgui.h @@ -3522,9 +3522,9 @@ _SOKOL_PRIVATE void _sgimgui_draw_shader_panel(sgimgui_t* ctx, sg_shader shd) { const sg_glsl_shader_uniform* u = &ub->glsl_uniforms[j]; if (SG_UNIFORMTYPE_INVALID != u->type) { if (u->array_count <= 1) { - igText(" %s %s (offset: %d)", _sgimgui_uniformtype_string(u->type), u->glsl_name ? u->glsl_name : "", u->offset); + igText(" %s %s", _sgimgui_uniformtype_string(u->type), u->glsl_name ? u->glsl_name : ""); } else { - igText(" %s[%d] %s (offset: %d)", _sgimgui_uniformtype_string(u->type), u->array_count, u->glsl_name ? u->glsl_name : "", u->offset); + igText(" %s[%d] %s", _sgimgui_uniformtype_string(u->type), u->array_count, u->glsl_name ? u->glsl_name : ""); } } }