MCPcopy Create free account
hub / github.com/RenderKit/oidn / submitKernels

Method submitKernels

devices/cpu/cpu_input_process.cpp:19–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17 }
18
19 void CPUInputProcess::submitKernels(const Ref<CancellationToken>& ct)
20 {
21 check();
22
23 ispc::CPUInputProcessKernel kernel;
24 Image nullImage;
25
26 kernel.input = color ? *color : (albedo ? *albedo : *normal);
27 kernel.albedo = (color && albedo) ? *albedo : nullImage;
28 kernel.normal = (color && normal) ? *normal : nullImage;
29 kernel.dst = *dst;
30 kernel.tile = toISPC(tile);
31 kernel.transferFunc = toISPC(*transferFunc);
32 kernel.hdr = hdr;
33 kernel.snorm = snorm;
34
35 auto kernelFunc = (dst->getDataType() == DataType::Float16)
36 ? ispc::CPUInputProcessKernel_run_f16
37 : ispc::CPUInputProcessKernel_run_f32;
38
39 engine->submitFunc([=]
40 {
41 parallel_for(kernel.dst.H, [&](int hDst)
42 {
43 kernelFunc(&kernel, hDst);
44 });
45 }, ct);
46 }
47
48OIDN_NAMESPACE_END

Callers

nothing calls this directly

Calls 4

toISPCFunction · 0.85
parallel_forFunction · 0.85
submitFuncMethod · 0.80
getDataTypeMethod · 0.45

Tested by

no test coverage detected