[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [51251] branches/soc-2012-fried_chicken: * Revert "zer000"'s Cycles test node commits.
Miika Hamalainen
miika.hamalainen at kolumbus.fi
Wed Oct 10 12:39:50 CEST 2012
Revision: 51251
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=51251
Author: miikah
Date: 2012-10-10 10:39:49 +0000 (Wed, 10 Oct 2012)
Log Message:
-----------
* Revert "zer000"'s Cycles test node commits. (r47479 and 47556)
* Some cleanup to smoke code.
Revision Links:
--------------
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=47479
Modified Paths:
--------------
branches/soc-2012-fried_chicken/intern/cycles/blender/blender_shader.cpp
branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm.h
branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_bsdf.h
branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_closure.h
branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_types.h
branches/soc-2012-fried_chicken/intern/cycles/render/nodes.cpp
branches/soc-2012-fried_chicken/intern/cycles/render/nodes.h
branches/soc-2012-fried_chicken/source/blender/blenkernel/BKE_node.h
branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/node.c
branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/smoke.c
branches/soc-2012-fried_chicken/source/blender/blenloader/intern/readfile.c
branches/soc-2012-fried_chicken/source/blender/gpu/GPU_extensions.h
branches/soc-2012-fried_chicken/source/blender/gpu/intern/gpu_draw.c
branches/soc-2012-fried_chicken/source/blender/gpu/intern/gpu_extensions.c
branches/soc-2012-fried_chicken/source/blender/makesdna/DNA_modifier_types.h
branches/soc-2012-fried_chicken/source/blender/makesrna/intern/rna_nodetree_types.h
branches/soc-2012-fried_chicken/source/blender/nodes/CMakeLists.txt
branches/soc-2012-fried_chicken/source/blender/nodes/NOD_shader.h
branches/soc-2012-fried_chicken/source/blender/nodes/shader/nodes/node_shader_bsdf_diffuse.c
Removed Paths:
-------------
branches/soc-2012-fried_chicken/source/blender/nodes/shader/nodes/node_shader_mybsdf_diffuse.c
Modified: branches/soc-2012-fried_chicken/intern/cycles/blender/blender_shader.cpp
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/blender/blender_shader.cpp 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/blender/blender_shader.cpp 2012-10-10 10:39:49 UTC (rev 51251)
@@ -318,11 +318,7 @@
case BL::ShaderNode::type_BSDF_DIFFUSE: {
node = new DiffuseBsdfNode();
break;
- }
- case BL::ShaderNode::type_MYBSDF_DIFFUSE: {
- node = new MYBsdfNode();
- break;
- }
+ }
case BL::ShaderNode::type_BSDF_GLOSSY: {
BL::ShaderNodeBsdfGlossy b_glossy_node(b_node);
GlossyBsdfNode *glossy = new GlossyBsdfNode();
Modified: branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm.h
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -187,9 +187,6 @@
case NODE_CLOSURE_BSDF:
svm_node_closure_bsdf(kg, sd, stack, node, randb, path_flag);
break;
- /* case CLOSURE_MYBSDF_ID:
- svm_node_closure_bsdf(kg, sd, stack, node, randb, path_flag);
- break;*/
case NODE_CLOSURE_EMISSION:
svm_node_closure_emission(sd, stack, node);
break;
Modified: branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_bsdf.h
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_bsdf.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_bsdf.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -38,9 +38,6 @@
case CLOSURE_BSDF_DIFFUSE_ID:
label = bsdf_diffuse_sample(sd, sc, randu, randv, eval, omega_in, &domega_in->dx, &domega_in->dy, pdf);
break;
- case CLOSURE_MYBSDF_ID:
- label = bsdf_diffuse_sample(sd, sc, randu, randv, eval, omega_in, &domega_in->dx, &domega_in->dy, pdf);
- break;
#ifdef __SVM__
case CLOSURE_BSDF_OREN_NAYAR_ID:
label = bsdf_oren_nayar_sample(sd, sc, randu, randv, eval, omega_in, &domega_in->dx, &domega_in->dy, pdf);
@@ -97,9 +94,6 @@
case CLOSURE_BSDF_DIFFUSE_ID:
eval = bsdf_diffuse_eval_reflect(sd, sc, sd->I, omega_in, pdf);
break;
- case CLOSURE_MYBSDF_ID:
- eval = bsdf_diffuse_eval_reflect(sd, sc, sd->I, omega_in, pdf);
- break;
#ifdef __SVM__
case CLOSURE_BSDF_OREN_NAYAR_ID:
eval = bsdf_oren_nayar_eval_reflect(sd, sc, sd->I, omega_in, pdf);
@@ -149,9 +143,6 @@
case CLOSURE_BSDF_DIFFUSE_ID:
eval = bsdf_diffuse_eval_transmit(sd, sc, sd->I, omega_in, pdf);
break;
- case CLOSURE_MYBSDF_ID:
- eval = bsdf_diffuse_eval_transmit(sd, sc, sd->I, omega_in, pdf);
- break;
#ifdef __SVM__
case CLOSURE_BSDF_OREN_NAYAR_ID:
eval = bsdf_oren_nayar_eval_transmit(sd, sc, sd->I, omega_in, pdf);
@@ -206,9 +197,6 @@
case CLOSURE_BSDF_DIFFUSE_ID:
bsdf_diffuse_blur(sc, roughness);
break;
- case CLOSURE_MYBSDF_ID:
- bsdf_diffuse_blur(sc, roughness);
- break;
#ifdef __SVM__
case CLOSURE_BSDF_OREN_NAYAR_ID:
bsdf_oren_nayar_blur(sc, roughness);
Modified: branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_closure.h
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_closure.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_closure.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -88,17 +88,6 @@
bsdf_oren_nayar_setup(sd, sc, roughness);
break;
}
- case CLOSURE_MYBSDF_ID: {
- ShaderClosure *sc = svm_node_closure_get(sd);
- svm_node_closure_set_mix_weight(sc, mix_weight);
-
- float roughness = param1;
- if(roughness == 0.0f)
- bsdf_diffuse_setup(sd, sc);
- else
- bsdf_oren_nayar_setup(sd, sc, roughness);
- break;
- }
case CLOSURE_BSDF_TRANSLUCENT_ID: {
ShaderClosure *sc = svm_node_closure_get(sd);
svm_node_closure_set_mix_weight(sc, mix_weight);
Modified: branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_types.h
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_types.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/kernel/svm/svm_types.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -285,7 +285,6 @@
CLOSURE_BSDF_ID,
CLOSURE_BSDF_DIFFUSE_ID,
- CLOSURE_MYBSDF_ID, //diffuse clone, added for learning
CLOSURE_BSDF_OREN_NAYAR_ID,
CLOSURE_BSDF_GLOSSY_ID,
Modified: branches/soc-2012-fried_chicken/intern/cycles/render/nodes.cpp
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/render/nodes.cpp 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/render/nodes.cpp 2012-10-10 10:39:49 UTC (rev 51251)
@@ -1349,25 +1349,6 @@
compiler.add(this, "node_diffuse_bsdf");
}
-/* START test bsdf closure */
-MYBsdfNode::MYBsdfNode()
-{
- closure = CLOSURE_MYBSDF_ID;
- add_input("Roughness", SHADER_SOCKET_FLOAT, 0.0f);
-}
-
-void MYBsdfNode::compile(SVMCompiler& compiler)
-{
- BsdfNode::compile(compiler, input("Roughness"), NULL);
-}
-
-void MYBsdfNode::compile(OSLCompiler& compiler)
-{
- compiler.add(this, "node_mydiffuse_bsdf");
-}
-
-/* END test bsdf closure */
-
/* Translucent BSDF Closure */
TranslucentBsdfNode::TranslucentBsdfNode()
Modified: branches/soc-2012-fried_chicken/intern/cycles/render/nodes.h
===================================================================
--- branches/soc-2012-fried_chicken/intern/cycles/render/nodes.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/intern/cycles/render/nodes.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -208,13 +208,6 @@
SHADER_NODE_CLASS(DiffuseBsdfNode)
};
-/* Test Node for learning purposes. Copy of bsdf node */
-class MYBsdfNode : public BsdfNode {
-public:
- SHADER_NODE_CLASS(MYBsdfNode)
-};
-
-
class TranslucentBsdfNode : public BsdfNode {
public:
SHADER_NODE_CLASS(TranslucentBsdfNode)
Modified: branches/soc-2012-fried_chicken/source/blender/blenkernel/BKE_node.h
===================================================================
--- branches/soc-2012-fried_chicken/source/blender/blenkernel/BKE_node.h 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/source/blender/blenkernel/BKE_node.h 2012-10-10 10:39:49 UTC (rev 51251)
@@ -551,7 +551,6 @@
#define SH_NODE_OBJECT_INFO 167
#define SH_NODE_PARTICLE_INFO 168
#define SH_NODE_TEX_BRICK 169
-#define SH_NODE_MYBSDF_DIFFUSE 170 //Diffuse copy node added for test purposes
/* custom defines options for Material node */
#define SH_NODE_MAT_DIFF 1
Modified: branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/node.c
===================================================================
--- branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/node.c 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/node.c 2012-10-10 10:39:49 UTC (rev 51251)
@@ -2249,7 +2249,6 @@
register_node_type_sh_background(ttype);
register_node_type_sh_bsdf_diffuse(ttype);
- register_node_type_sh_mybsdf_diffuse(ttype);//Test node
register_node_type_sh_bsdf_glossy(ttype);
register_node_type_sh_bsdf_glass(ttype);
register_node_type_sh_bsdf_translucent(ttype);
Modified: branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/smoke.c
===================================================================
--- branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/smoke.c 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/source/blender/blenkernel/intern/smoke.c 2012-10-10 10:39:49 UTC (rev 51251)
@@ -295,7 +295,7 @@
/* set domain dimensions from derivedmesh */
smoke_set_domain_from_derivedmesh(sds, ob, dm);
/* reset domain values */
- zero_v3(sds->shift);
+ zero_v3_int(sds->shift);
zero_v3(sds->shift_f);
add_v3_fl(sds->shift_f, 0.5f);
zero_v3(sds->prev_loc);
Modified: branches/soc-2012-fried_chicken/source/blender/blenloader/intern/readfile.c
===================================================================
--- branches/soc-2012-fried_chicken/source/blender/blenloader/intern/readfile.c 2012-10-10 10:05:56 UTC (rev 51250)
+++ branches/soc-2012-fried_chicken/source/blender/blenloader/intern/readfile.c 2012-10-10 10:39:49 UTC (rev 51251)
@@ -8056,40 +8056,30 @@
if (md->type == eModifierType_Smoke) {
SmokeModifierData *smd = (SmokeModifierData *)md;
if ((smd->type & MOD_SMOKE_TYPE_DOMAIN) && smd->domain) {
- /* hack to keep branch changes without version number */
+ /* keep branch saves if possible */
if (!smd->domain->flame_max_temp) {
smd->domain->burning_rate = 0.75f;
smd->domain->flame_smoke = 1.0f;
smd->domain->flame_vorticity = 0.5f;
smd->domain->flame_ignition = 1.25f;
smd->domain->flame_max_temp = 1.75f;
- }
- if (!smd->domain->adapt_threshold) {
smd->domain->adapt_threshold = 0.02f;
smd->domain->adapt_margin = 4;
- }
- if (smd->branch_v < 1) {
smd->domain->flame_smoke_color[0] = 0.7f;
smd->domain->flame_smoke_color[1] = 0.7f;
smd->domain->flame_smoke_color[2] = 0.7f;
}
}
else if ((smd->type & MOD_SMOKE_TYPE_FLOW) && smd->flow) {
- if (!smd->flow->fuel_amount) {
+ if (!smd->flow->texture_size) {
smd->flow->fuel_amount = 1.0;
smd->flow->surface_distance = 1.5;
- }
-
- if (smd->branch_v < 1) {
smd->flow->color[0] = 0.7f;
smd->flow->color[1] = 0.7f;
smd->flow->color[2] = 0.7f;
- }
- if (smd->branch_v < 2) {
smd->flow->texture_size = 1.0f;
}
}
- smd->branch_v = 2; /* hack to keep branch changes without version number */
}
}
}
@@ Diff output truncated at 10240 characters. @@
More information about the Bf-blender-cvs
mailing list