[Bf-blender-cvs] [23fa5bb7230] master: GPU: Remove unused resources in shader create info.

Jeroen Bakker noreply at git.blender.org
Fri Jan 21 10:02:14 CET 2022


Commit: 23fa5bb723049684b06192afbdd1714e4109be72
Author: Jeroen Bakker
Date:   Fri Jan 21 09:58:58 2022 +0100
Branches: master
https://developer.blender.org/rB23fa5bb723049684b06192afbdd1714e4109be72

GPU: Remove unused resources in shader create info.

When adding the shader create infos some additional resources where defined
that doesn't exist in the shader itself. This commit will remove them.

===================================================================

M	source/blender/gpu/shaders/infos/gpu_shader_2D_image_rect_color_info.hh
M	source/blender/gpu/shaders/infos/gpu_shader_3D_flat_color_info.hh
M	source/blender/gpu/shaders/infos/gpu_shader_3D_point_info.hh

===================================================================

diff --git a/source/blender/gpu/shaders/infos/gpu_shader_2D_image_rect_color_info.hh b/source/blender/gpu/shaders/infos/gpu_shader_2D_image_rect_color_info.hh
index b94556bbb25..4e10b91ef39 100644
--- a/source/blender/gpu/shaders/infos/gpu_shader_2D_image_rect_color_info.hh
+++ b/source/blender/gpu/shaders/infos/gpu_shader_2D_image_rect_color_info.hh
@@ -25,8 +25,6 @@
 #include "gpu_shader_create_info.hh"
 
 GPU_SHADER_CREATE_INFO(gpu_shader_2D_image_rect_color)
-    .vertex_in(0, Type::VEC2, "pos")
-    .vertex_in(1, Type::VEC2, "texCoord")
     .vertex_out(smooth_tex_coord_interp_iface)
     .fragment_out(0, Type::VEC4, "fragColor")
     .push_constant(0, Type::MAT4, "ModelViewProjectionMatrix")
diff --git a/source/blender/gpu/shaders/infos/gpu_shader_3D_flat_color_info.hh b/source/blender/gpu/shaders/infos/gpu_shader_3D_flat_color_info.hh
index 70b2dac8266..14a6986f478 100644
--- a/source/blender/gpu/shaders/infos/gpu_shader_3D_flat_color_info.hh
+++ b/source/blender/gpu/shaders/infos/gpu_shader_3D_flat_color_info.hh
@@ -30,7 +30,6 @@ GPU_SHADER_CREATE_INFO(gpu_shader_3D_flat_color)
     .vertex_out(flat_color_iface)
     .fragment_out(0, Type::VEC4, "fragColor")
     .push_constant(0, Type::MAT4, "ModelViewProjectionMatrix")
-    .push_constant(1, Type::BOOL, "srgbTarget")
     .vertex_source("gpu_shader_3D_flat_color_vert.glsl")
     .fragment_source("gpu_shader_flat_color_frag.glsl")
     .additional_info("gpu_srgb_to_framebuffer_space")
diff --git a/source/blender/gpu/shaders/infos/gpu_shader_3D_point_info.hh b/source/blender/gpu/shaders/infos/gpu_shader_3D_point_info.hh
index b62c8fe7518..27357eef8c9 100644
--- a/source/blender/gpu/shaders/infos/gpu_shader_3D_point_info.hh
+++ b/source/blender/gpu/shaders/infos/gpu_shader_3D_point_info.hh
@@ -29,7 +29,6 @@ GPU_SHADER_CREATE_INFO(gpu_shader_3D_point_fixed_size_varying_color)
     .vertex_out(smooth_color_iface)
     .fragment_out(0, Type::VEC4, "fragColor")
     .push_constant(0, Type::MAT4, "ModelViewProjectionMatrix")
-    .push_constant(16, Type::FLOAT, "size")
     .vertex_source("gpu_shader_3D_point_fixed_size_varying_color_vert.glsl")
     .fragment_source("gpu_shader_point_varying_color_frag.glsl")
     .do_static_compilation(true);
@@ -52,7 +51,6 @@ GPU_SHADER_CREATE_INFO(gpu_shader_3D_point_uniform_size_uniform_color_aa)
     .push_constant(0, Type::MAT4, "ModelViewProjectionMatrix")
     .push_constant(16, Type::VEC4, "color")
     .push_constant(20, Type::FLOAT, "size")
-    .push_constant(24, Type::FLOAT, "outlineWidth")
     .vertex_source("gpu_shader_3D_point_uniform_size_aa_vert.glsl")
     .fragment_source("gpu_shader_point_uniform_color_aa_frag.glsl")
     .do_static_compilation(true);



More information about the Bf-blender-cvs mailing list