[Bf-blender-cvs] [d05a843] soc-2016-cycles_images: Fixes for Fermi.

Thomas Dinges noreply at git.blender.org
Thu May 19 02:42:46 CEST 2016


Commit: d05a843543cb26c2334e9e089bab2170c6623bab
Author: Thomas Dinges
Date:   Thu May 19 02:42:32 2016 +0200
Branches: soc-2016-cycles_images
https://developer.blender.org/rBd05a843543cb26c2334e9e089bab2170c6623bab

Fixes for Fermi.

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

M	intern/cycles/device/device_cuda.cpp

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

diff --git a/intern/cycles/device/device_cuda.cpp b/intern/cycles/device/device_cuda.cpp
index 94abc1d..ef9b7cc 100644
--- a/intern/cycles/device/device_cuda.cpp
+++ b/intern/cycles/device/device_cuda.cpp
@@ -222,7 +222,8 @@ public:
 	{
 		task_pool.stop();
 
-		tex_free(bindless_mapping, -1);
+		if(info.has_bindless_textures)
+			tex_free(bindless_mapping, -1);
 
 		cuda_assert(cuCtxDestroy(cuContext));
 	}
@@ -403,7 +404,7 @@ public:
 
 	void load_bindless_mapping()
 	{
-		if(sync_bindless_mapping) {
+		if(info.has_bindless_textures && sync_bindless_mapping) {
 			tex_alloc("__bindless_mapping", bindless_mapping, INTERPOLATION_NONE, EXTENSION_REPEAT, 0);
 			sync_bindless_mapping = false;
 		}
@@ -745,7 +746,7 @@ public:
 		}
 
 		/* Free CUtexObject (Bindless Textures) */
-		if(flat_slot != -1) {
+		if(info.has_bindless_textures && flat_slot != -1) {
 			cuTexObjectDestroy(bindless_mapping.get_data()[flat_slot]);
 		}
 	}




More information about the Bf-blender-cvs mailing list