diff options
author | OmarSquircleArt <omar.squircleart@gmail.com> | 2019-09-12 18:42:13 +0300 |
---|---|---|
committer | OmarSquircleArt <omar.squircleart@gmail.com> | 2019-09-12 18:42:13 +0300 |
commit | 2ea82e86ca60c1c268c6074ecba10524cebd97ed (patch) | |
tree | bf355c2a930f584685f68a833ce620ad15e63a70 /source/blender/gpu/intern/gpu_material_library.h | |
parent | f80018b5f7497d7ed0fe79783c4cd76f05ec1c7c (diff) |
Shading: Add Vertex Color node.
This patch adds a new Vertex Color node. The node also returns the alpha
of the vertex color layer as an output.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D5767
Diffstat (limited to 'source/blender/gpu/intern/gpu_material_library.h')
-rw-r--r-- | source/blender/gpu/intern/gpu_material_library.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_material_library.h b/source/blender/gpu/intern/gpu_material_library.h index 06544d27af9..3a38eb5c600 100644 --- a/source/blender/gpu/intern/gpu_material_library.h +++ b/source/blender/gpu/intern/gpu_material_library.h @@ -114,6 +114,7 @@ extern char datatoc_gpu_shader_material_vector_curves_glsl[]; extern char datatoc_gpu_shader_material_vector_displacement_glsl[]; extern char datatoc_gpu_shader_material_vector_math_glsl[]; extern char datatoc_gpu_shader_material_velvet_glsl[]; +extern char datatoc_gpu_shader_material_vertex_color_glsl[]; extern char datatoc_gpu_shader_material_volume_absorption_glsl[]; extern char datatoc_gpu_shader_material_volume_info_glsl[]; extern char datatoc_gpu_shader_material_volume_principled_glsl[]; @@ -527,6 +528,11 @@ static GPUMaterialLibrary gpu_shader_material_velvet_library = { .dependencies = {&gpu_shader_material_diffuse_library, NULL}, }; +static GPUMaterialLibrary gpu_shader_material_vertex_color_library = { + .code = datatoc_gpu_shader_material_vertex_color_glsl, + .dependencies = {NULL}, +}; + static GPUMaterialLibrary gpu_shader_material_volume_absorption_library = { .code = datatoc_gpu_shader_material_volume_absorption_glsl, .dependencies = {NULL}, @@ -638,6 +644,7 @@ static GPUMaterialLibrary *gpu_material_libraries[] = { &gpu_shader_material_vector_displacement_library, &gpu_shader_material_vector_math_library, &gpu_shader_material_velvet_library, + &gpu_shader_material_vertex_color_library, &gpu_shader_material_volume_absorption_library, &gpu_shader_material_volume_info_library, &gpu_shader_material_volume_principled_library, |