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