Cycles: replace surface/volume sockets in output nodes with a single shader socket,

decided it's better to render objects as either surface or volume.

This may break the volume rendering patch, but shaders with volume closures still
get tagged as having volume closures, so it should be fixable without too many
changes.
This commit is contained in:
2011-10-12 15:42:35 +00:00
parent 85818c8209
commit 7503a7edfb
20 changed files with 1496 additions and 1601 deletions

View File

@@ -42,7 +42,6 @@ Shader::Shader()
sample_as_light = true;
homogeneous_volume = false;
has_surface = false;
has_surface_transparent = false;
has_surface_emission = false;
has_volume = false;
@@ -210,7 +209,7 @@ void ShaderManager::add_default(Scene *scene)
closure->input("Color")->value = make_float3(0.8f, 0.8f, 0.8f);
out = graph->output();
graph->connect(closure->output("BSDF"), out->input("Surface"));
graph->connect(closure->output("BSDF"), out->input("Closure"));
shader = new Shader();
shader->name = "default_surface";
@@ -228,7 +227,7 @@ void ShaderManager::add_default(Scene *scene)
closure->input("Strength")->value.x = 0.0f;
out = graph->output();
graph->connect(closure->output("Emission"), out->input("Surface"));
graph->connect(closure->output("Emission"), out->input("Closure"));
shader = new Shader();
shader->name = "default_light";
@@ -245,7 +244,7 @@ void ShaderManager::add_default(Scene *scene)
closure->input("Color")->value = make_float3(0.8f, 0.8f, 0.8f);
out = graph->output();
graph->connect(closure->output("Background"), out->input("Surface"));
graph->connect(closure->output("Background"), out->input("Closure"));
shader = new Shader();
shader->name = "default_background";