Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2017-11-04 13:45:52 +0300
committerCampbell Barton <ideasman42@gmail.com>2017-11-04 13:45:52 +0300
commitd4fe083b356d7967ce6d9716cd0e6ba3039d1655 (patch)
tree49eb05d3589f180c1056691efa5dd7c67b28dca8 /intern/cycles/device/device.cpp
parent10024603ee904a4201ae35b87643012543274d0f (diff)
parent01a3c9560938c98793a2d2a0b61e574ed5c27e4a (diff)
Merge branch 'master' into blender2.8
Diffstat (limited to 'intern/cycles/device/device.cpp')
-rw-r--r--intern/cycles/device/device.cpp29
1 files changed, 19 insertions, 10 deletions
diff --git a/intern/cycles/device/device.cpp b/intern/cycles/device/device.cpp
index 923b9bd45bf..6a666eb946e 100644
--- a/intern/cycles/device/device.cpp
+++ b/intern/cycles/device/device.cpp
@@ -507,39 +507,48 @@ DeviceInfo Device::get_multi_device(const vector<DeviceInfo>& subdevices, int th
info.description = "Multi Device";
info.num = 0;
- info.has_bindless_textures = true;
+ info.has_fermi_limits = false;
+ info.has_half_images = true;
info.has_volume_decoupled = true;
info.has_qbvh = true;
info.has_osl = true;
foreach(const DeviceInfo &device, subdevices) {
- info.has_bindless_textures &= device.has_bindless_textures;
- info.has_volume_decoupled &= device.has_volume_decoupled;
- info.has_qbvh &= device.has_qbvh;
- info.has_osl &= device.has_osl;
-
+ /* Ensure CPU device does not slow down GPU. */
if(device.type == DEVICE_CPU && subdevices.size() > 1) {
if(background) {
int orig_cpu_threads = (threads)? threads: system_cpu_thread_count();
int cpu_threads = max(orig_cpu_threads - (subdevices.size() - 1), 0);
+ VLOG(1) << "CPU render threads reduced from "
+ << orig_cpu_threads << " to " << cpu_threads
+ << ", to dedicate to GPU.";
+
if(cpu_threads >= 1) {
DeviceInfo cpu_device = device;
cpu_device.cpu_threads = cpu_threads;
info.multi_devices.push_back(cpu_device);
}
-
- VLOG(1) << "CPU render threads reduced from "
- << orig_cpu_threads << " to " << cpu_threads
- << ", to dedicate to GPU.";
+ else {
+ continue;
+ }
}
else {
VLOG(1) << "CPU render threads disabled for interactive render.";
+ continue;
}
}
else {
info.multi_devices.push_back(device);
}
+
+ /* Accumulate device info. */
+ info.has_fermi_limits = info.has_fermi_limits ||
+ device.has_fermi_limits;
+ info.has_half_images &= device.has_half_images;
+ info.has_volume_decoupled &= device.has_volume_decoupled;
+ info.has_qbvh &= device.has_qbvh;
+ info.has_osl &= device.has_osl;
}
return info;