[Bf-blender-cvs] [64d719d68cf] cycles_embree: Merge branch 'master' of git.blender.org:blender into cycles_embree

Stefan Werner noreply at git.blender.org
Wed Nov 7 11:11:28 CET 2018


Commit: 64d719d68cfd6ee8d57deb7bbd6fb63b17961e58
Author: Stefan Werner
Date:   Wed Nov 7 11:11:23 2018 +0100
Branches: cycles_embree
https://developer.blender.org/rB64d719d68cfd6ee8d57deb7bbd6fb63b17961e58

Merge branch 'master' of git.blender.org:blender into cycles_embree

===================================================================



===================================================================

diff --cc intern/cycles/bvh/bvh.cpp
index 271f90fd1e6,bc73a3ad264..ac0614e3659
--- a/intern/cycles/bvh/bvh.cpp
+++ b/intern/cycles/bvh/bvh.cpp
@@@ -45,8 -41,7 +45,8 @@@ const char *bvh_layout_name(BVHLayout l
  		case BVH_LAYOUT_BVH4: return "BVH4";
  		case BVH_LAYOUT_BVH8: return "BVH8";
  		case BVH_LAYOUT_NONE: return "NONE";
- 		case BVH_LAYOUT_ALL:  return "ALL";
 +		case BVH_LAYOUT_EMBREE: return "EMBREE";
+ 		case BVH_LAYOUT_ALL:  return "ALL";
  	}
  	LOG(DFATAL) << "Unsupported BVH layout was passed.";
  	return "";
diff --cc intern/cycles/device/device_cpu.cpp
index 4db626b6bfd,731d6c0d631..9e27a48b341
--- a/intern/cycles/device/device_cpu.cpp
+++ b/intern/cycles/device/device_cpu.cpp
@@@ -278,6 -278,17 +278,20 @@@ public
  		return (info.cpu_threads == 1);
  	}
  
+ 	virtual BVHLayoutMask get_bvh_layout_mask() const {
+ 		BVHLayoutMask bvh_layout_mask = BVH_LAYOUT_BVH2;
+ 		if(DebugFlags().cpu.has_sse2() && system_cpu_support_sse2()) {
+ 			bvh_layout_mask |= BVH_LAYOUT_BVH4;
+ 		}
+ 		if(DebugFlags().cpu.has_avx2() && system_cpu_support_avx2()) {
+ 			bvh_layout_mask |= BVH_LAYOUT_BVH8;
+ 		}
++#ifdef WITH_EMBREE
++		bvh_layout_mask |= BVH_LAYOUT_EMBREE;
++#endif /* WITH_EMBREE */
+ 		return bvh_layout_mask;
+ 	}
+ 
  	void load_texture_info()
  	{
  		if(need_texture_info) {



More information about the Bf-blender-cvs mailing list