MCPcopy Create free account
hub / github.com/ValveSoftware/steam-audio / COpenCLDeviceList

Method COpenCLDeviceList

core/src/core/api_opencl_device.cpp:34–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32// --------------------------------------------------------------------------------------------------------------------
33
34COpenCLDeviceList::COpenCLDeviceList(CContext* context,
35 IPLOpenCLDeviceSettings* settings)
36{
37#if defined(IPL_USES_OPENCL)
38 auto _context = context->mHandle.get();
39 if (!_context)
40 throw Exception(Status::Failure);
41
42 auto _type = static_cast<OpenCLDeviceType>(settings->type);
43 auto _requiresTAN = (settings->requiresTAN == IPL_TRUE);
44
45 new (&mHandle) Handle<OpenCLDeviceList>(ipl::make_shared<OpenCLDeviceList>(_type, settings->numCUsToReserve, settings->fractionCUsForIRUpdate, _requiresTAN), _context);
46#endif
47}
48
49IOpenCLDeviceList* COpenCLDeviceList::retain()
50{

Callers

nothing calls this directly

Calls 2

ExceptionClass · 0.85
getMethod · 0.45

Tested by

no test coverage detected