Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brecht@blender.org>2022-01-25 15:25:33 +0300
committerBrecht Van Lommel <brecht@blender.org>2022-01-25 19:14:20 +0300
commitc813a1b3583e9a3bf17c75e16995ebadb046361a (patch)
tree8f5405c7f0a05aef8d43342764fc0a42ef577a54 /source/blender/gpu/intern
parenteab066cbf2da1fdb8162d9ed814a9491f9acf02d (diff)
Cycles: add Point Info node
With (center) position, radius and random value outputs. Eevee does not yet support rendering point clouds, but an untested implementation of this node was added for when it does. Ref T92573
Diffstat (limited to 'source/blender/gpu/intern')
-rw-r--r--source/blender/gpu/intern/gpu_material_library.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/source/blender/gpu/intern/gpu_material_library.c b/source/blender/gpu/intern/gpu_material_library.c
index 74e0270c42a..712ab44adb3 100644
--- a/source/blender/gpu/intern/gpu_material_library.c
+++ b/source/blender/gpu/intern/gpu_material_library.c
@@ -91,6 +91,7 @@ extern char datatoc_gpu_shader_material_output_aov_glsl[];
extern char datatoc_gpu_shader_material_output_material_glsl[];
extern char datatoc_gpu_shader_material_output_world_glsl[];
extern char datatoc_gpu_shader_material_particle_info_glsl[];
+extern char datatoc_gpu_shader_material_point_info_glsl[];
extern char datatoc_gpu_shader_material_principled_glsl[];
extern char datatoc_gpu_shader_material_refraction_glsl[];
extern char datatoc_gpu_shader_material_rgb_curves_glsl[];
@@ -295,7 +296,7 @@ static GPUMaterialLibrary gpu_shader_material_glass_library = {
static GPUMaterialLibrary gpu_shader_material_hair_info_library = {
.code = datatoc_gpu_shader_material_hair_info_glsl,
- .dependencies = {NULL},
+ .dependencies = {&gpu_shader_material_hash_library, NULL},
};
static GPUMaterialLibrary gpu_shader_material_holdout_library = {
@@ -388,6 +389,11 @@ static GPUMaterialLibrary gpu_shader_material_particle_info_library = {
.dependencies = {NULL},
};
+static GPUMaterialLibrary gpu_shader_material_point_info_library = {
+ .code = datatoc_gpu_shader_material_point_info_glsl,
+ .dependencies = {&gpu_shader_material_hash_library, NULL},
+};
+
static GPUMaterialLibrary gpu_shader_material_principled_library = {
.code = datatoc_gpu_shader_material_principled_glsl,
.dependencies = {NULL},
@@ -644,6 +650,7 @@ static GPUMaterialLibrary *gpu_material_libraries[] = {
&gpu_shader_material_output_material_library,
&gpu_shader_material_output_world_library,
&gpu_shader_material_particle_info_library,
+ &gpu_shader_material_point_info_library,
&gpu_shader_material_principled_library,
&gpu_shader_material_refraction_library,
&gpu_shader_material_rgb_curves_library,