Fix #33243: cycles CUDA going missing sometimes, disabled the new code now that

can detect if a device becomes available while Blender runs, appears to be
unreliable for some reason.
This commit is contained in:
Brecht Van Lommel
2012-11-20 17:39:56 +00:00
parent 68e9fdeb81
commit a80b0915c7

View File

@@ -189,18 +189,6 @@ vector<DeviceInfo>& Device::available_devices()
{
static vector<DeviceInfo> devices;
static bool devices_init = false;
static double device_update_time = 0.0;
/* only update device list if we're not actively rendering already, things
* could go very wrong if a device suddenly becomes (un)available. also do
* it only every 5 seconds. it not super cpu intensive but don't want to do
* it on every redraw. */
if(devices_init) {
if(!TaskScheduler::active() && (time_dt() > device_update_time + 5.0)) {
devices.clear();
devices_init = false;
}
}
if(!devices_init) {
#ifdef WITH_CUDA
@@ -224,7 +212,6 @@ vector<DeviceInfo>& Device::available_devices()
#endif
devices_init = true;
device_update_time = time_dt();
}
return devices;