Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/device/device_optix.cpp
| Show First 20 Lines • Show All 1,552 Lines • ▼ Show 20 Lines | if (cuDeviceGet(&cuda_device, info.num) == CUDA_SUCCESS && | ||||
| &rtcore_version, | &rtcore_version, | ||||
| sizeof(rtcore_version)); | sizeof(rtcore_version)); | ||||
| optixDeviceContextDestroy(optix_context); | optixDeviceContextDestroy(optix_context); | ||||
| } | } | ||||
| cuDevicePrimaryCtxRelease(cuda_device); | cuDevicePrimaryCtxRelease(cuda_device); | ||||
| } | } | ||||
| // Only add devices with RTX support | // Only add devices with RTX support | ||||
| if (rtcore_version == 0) | if (rtcore_version == 0 && getenv("CYCLES_OPTIX_RTX_BYPASS") == nullptr) | ||||
| it = cuda_devices.erase(it); | it = cuda_devices.erase(it); | ||||
| else | else | ||||
| ++it; | ++it; | ||||
| } | } | ||||
| devices.insert(devices.end(), cuda_devices.begin(), cuda_devices.end()); | devices.insert(devices.end(), cuda_devices.begin(), cuda_devices.end()); | ||||
| } | } | ||||
| Device *device_optix_create(DeviceInfo &info, Stats &stats, Profiler &profiler, bool background) | Device *device_optix_create(DeviceInfo &info, Stats &stats, Profiler &profiler, bool background) | ||||
| { | { | ||||
| return new OptiXDevice(info, stats, profiler, background); | return new OptiXDevice(info, stats, profiler, background); | ||||
| } | } | ||||
| CCL_NAMESPACE_END | CCL_NAMESPACE_END | ||||
| #endif | #endif | ||||