OpenCL Kernel Compilation
OpenCL Kernel Compilation
I was curious if it was possible to compile the kernels before rendering in the API (v2.4), or is a there a way to know when the kernels are compiling so I can display the appropriate message? I noticed the blender addon is able to do something like this.
Re: OpenCL Kernel Compilation
Not really with OpenCL. It would be using SPIR-V but, as far as I know, it is not supported by NVIDIA (70%+ of GPUs sold).
It is possible with CUDA but requires some work.
You can use this LuxCore API method to know if a (long) kernel compilation time is going to be required for the rendering: https://github.com/LuxCoreRender/LuxCor ... re.h#L1233
Re: OpenCL Kernel Compilation
In the BlendLuxCore addon I do it here for the viewport: https://github.com/LuxCoreRender/BlendL ... rt.py#L109
Re: OpenCL Kernel Compilation
Okay thank you very much for the quick response, this should do the trick, will play around with this. For now just focusing on OpenCL, will focus on CUDA later.