[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [42035] trunk/blender/intern/cycles: Cycles:
Brecht Van Lommel
brechtvanlommel at pandora.be
Mon Nov 21 17:28:20 CET 2011
Revision: 42035
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=42035
Author: blendix
Date: 2011-11-21 16:28:19 +0000 (Mon, 21 Nov 2011)
Log Message:
-----------
Cycles:
* Fix #29354: crash on branch file. Note that for best compatibility, you need
to save your files with one of the latest branch builds, since not all version
patching code was moved to trunk.
* Rename "Cycles" to "Cycles Render" in info header menu.
* Code tweaks to try to fix #29301. It's not a real solution though, I'm thinking
cause is extended precision for floats on some cpu's, used in one case but not
in the other, leading to bounding box intersection issue...
Modified Paths:
--------------
trunk/blender/intern/cycles/blender/addon/__init__.py
trunk/blender/intern/cycles/blender/blender_shader.cpp
trunk/blender/intern/cycles/kernel/kernel_bvh.h
trunk/blender/intern/cycles/util/util_math.h
Modified: trunk/blender/intern/cycles/blender/addon/__init__.py
===================================================================
--- trunk/blender/intern/cycles/blender/addon/__init__.py 2011-11-21 14:59:26 UTC (rev 42034)
+++ trunk/blender/intern/cycles/blender/addon/__init__.py 2011-11-21 16:28:19 UTC (rev 42035)
@@ -43,7 +43,7 @@
class CyclesRender(bpy.types.RenderEngine):
bl_idname = 'CYCLES'
- bl_label = "Cycles"
+ bl_label = "Cycles Render"
bl_use_shading_nodes = True
def __init__(self):
Modified: trunk/blender/intern/cycles/blender/blender_shader.cpp
===================================================================
--- trunk/blender/intern/cycles/blender/blender_shader.cpp 2011-11-21 14:59:26 UTC (rev 42034)
+++ trunk/blender/intern/cycles/blender/blender_shader.cpp 2011-11-21 16:28:19 UTC (rev 42035)
@@ -99,6 +99,9 @@
static void get_tex_mapping(TextureMapping *mapping, BL::TexMapping b_mapping)
{
+ if(!b_mapping)
+ return;
+
mapping->translation = get_float3(b_mapping.location());
mapping->rotation = get_float3(b_mapping.rotation());
mapping->scale = get_float3(b_mapping.scale());
@@ -110,6 +113,9 @@
static void get_tex_mapping(TextureMapping *mapping, BL::ShaderNodeMapping b_mapping)
{
+ if(!b_mapping)
+ return;
+
mapping->translation = get_float3(b_mapping.location());
mapping->rotation = get_float3(b_mapping.rotation());
mapping->scale = get_float3(b_mapping.scale());
Modified: trunk/blender/intern/cycles/kernel/kernel_bvh.h
===================================================================
--- trunk/blender/intern/cycles/kernel/kernel_bvh.h 2011-11-21 14:59:26 UTC (rev 42034)
+++ trunk/blender/intern/cycles/kernel/kernel_bvh.h 2011-11-21 16:28:19 UTC (rev 42035)
@@ -97,11 +97,7 @@
float c1loz = nz.z * idir.z - ood.z;
float c1hiz = nz.w * idir.z - ood.z;
- float c0min_x = min(c0lox, c0hix);
- float c0min_y = min(c0loy, c0hiy);
- float c0min_z = min(c0loz, c0hiz);
-
- float c0min = max4(c0min_x, c0min_y, c0min_z, 0.0f);
+ float c0min = max4(min(c0lox, c0hix), min(c0loy, c0hiy), min(c0loz, c0hiz), 0.0f);
float c0max = min4(max(c0lox, c0hix), max(c0loy, c0hiy), max(c0loz, c0hiz), t);
float c1lox = n1xy.x * idir.x - ood.x;
float c1hix = n1xy.y * idir.x - ood.x;
Modified: trunk/blender/intern/cycles/util/util_math.h
===================================================================
--- trunk/blender/intern/cycles/util/util_math.h 2011-11-21 14:59:26 UTC (rev 42034)
+++ trunk/blender/intern/cycles/util/util_math.h 2011-11-21 16:28:19 UTC (rev 42035)
@@ -115,12 +115,12 @@
__device_inline float min4(float a, float b, float c, float d)
{
- return min(min(min(a, b), c), d);
+ return min(min(a, b), min(c, d));
}
__device_inline float max4(float a, float b, float c, float d)
{
- return max(max(max(a, b), c), d);
+ return max(max(a, b), max(c, d));
}
#ifndef __KERNEL_OPENCL__
More information about the Bf-blender-cvs
mailing list