Blender  V3.3
gpu_shader_3D_uniform_color_info.hh
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2022 Blender Foundation. All rights reserved. */
3 
9 
10 GPU_SHADER_CREATE_INFO(gpu_shader_3D_uniform_color)
11  .vertex_in(0, Type::VEC3, "pos")
12  .fragment_out(0, Type::VEC4, "fragColor")
13  .push_constant(Type::MAT4, "ModelViewProjectionMatrix")
14  .push_constant(Type::VEC4, "color")
15  .vertex_source("gpu_shader_3D_vert.glsl")
16  .fragment_source("gpu_shader_uniform_color_frag.glsl")
17  .additional_info("gpu_srgb_to_framebuffer_space")
18  .do_static_compilation(true);
19 
20 GPU_SHADER_CREATE_INFO(gpu_shader_3D_uniform_color_clipped)
21  .additional_info("gpu_shader_3D_uniform_color")
22  .additional_info("gpu_clip_planes")
23  .do_static_compilation(true);
24 
25 /* Confusing naming convention. But this is a version with only one local clip plane. */
26 GPU_SHADER_CREATE_INFO(gpu_shader_3D_clipped_uniform_color)
27  .vertex_in(0, Type::VEC3, "pos")
28  .fragment_out(0, Type::VEC4, "fragColor")
29  .push_constant(Type::MAT4, "ModelViewProjectionMatrix")
30  .push_constant(Type::VEC4, "color")
31  /* TODO(@fclem): Put those two to one UBO. */
32  .push_constant(Type::MAT4, "ModelMatrix")
33  .push_constant(Type::VEC4, "ClipPlane")
34  .vertex_source("gpu_shader_3D_clipped_uniform_color_vert.glsl")
35  .fragment_source("gpu_shader_uniform_color_frag.glsl")
36  .additional_info("gpu_srgb_to_framebuffer_space")
37  .do_static_compilation(true);
#define GPU_SHADER_CREATE_INFO(_info)