New OpenCL textures and materials evaluation code

Discussion related to the LuxCore functionality, implementations and API.
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade »

juangea wrote: Fri Feb 21, 2020 1:04 pm Regarding the moment of kernel compile... Why not put a button in settings called "Compile Kernel" with a warning explaining that Blender will be frozen for some minutes.

After that if someone has not compiled the kernel and enable OpenCl a message could appear saying "Please compile kernel, Blender will froze for some minutes" and inside the message the same button to compile it.

That will give the user the consciousness that something is happening and that if Blender froze is normal and they have to wait, and at the same time the power to decide if they want to wait or not.

What do you think? :)
Something like that, it could be a button appearing under the render engine selection box so people see this button to pop up the first time they switch to GPU rendering.
Support LuxCoreRender project with salts and bounties
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade »

lacilaci wrote: Fri Feb 21, 2020 1:30 pm I wouldn't worry about first time compilation... just have addon give a message about the kernel compilation and that's it

it is how blender optix/rtx cycles does it, and also how vray rt does it. Each update of the renderer/plugin triggers this "first time run compilation". I think people should be used to this already
I was think people were shipping pre-compiled kernels (is it in CUDA ?) but if it is how Cycles works, it shouldn't be a problem because people are already used to it.
Support LuxCoreRender project with salts and bounties
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade »

Side note: this change affected more than 60 textures and 20+ materials ... it is obvious to say that there likely to be new bugs.
Support LuxCoreRender project with salts and bounties
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: New OpenCL textures and materials evaluation code

Post by lacilaci »

Dade wrote: Fri Feb 21, 2020 1:34 pm
lacilaci wrote: Fri Feb 21, 2020 1:30 pm I wouldn't worry about first time compilation... just have addon give a message about the kernel compilation and that's it

it is how blender optix/rtx cycles does it, and also how vray rt does it. Each update of the renderer/plugin triggers this "first time run compilation". I think people should be used to this already
I was think people were shipping pre-compiled kernels (is it in CUDA ?) but if it is how Cycles works, it shouldn't be a problem because people are already used to it.
No one does this AFAIK... Blender maybe with cuda but not with optix and vray never did supply precompiled kernels. I'm not sure why is that, maybe based on drivers it might be more up to date doing it at first run.

BTW: last time I updated blender the rtx kernel compilation took about 40-50 seconds.. so 90 for luxcore isn't that far
juangea
Donor
Donor
Posts: 332
Joined: Thu Jan 02, 2020 6:23 pm

Re: New OpenCL textures and materials evaluation code

Post by juangea »

AAAAAAAAAAAAARGH! I want to test it right away! :D

And yes, Cycles does the same, CUDA is pre-compiled, or the Compile times are super small, but for OpenCL and Optix kernels are compiled with the first render :)
User avatar
lacilaci
Donor
Donor
Posts: 1969
Joined: Fri May 04, 2018 5:16 am

Re: New OpenCL textures and materials evaluation code

Post by lacilaci »

this is what blender tells you when rendering first time with new installation(optix)
popcorn.jpg
I say, if Simon can copypasta this infomessage for luxcore it should be good enough...

There will always be people wondering what's going on no matter how hard you try to give them a heads-up so I wouldn't bother and especially I would avoid making convoluted UI changes just to tell people they need to calm down :D
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: New OpenCL textures and materials evaluation code

Post by B.Y.O.B. »

I couldn't get a popup to show up so far (there seem to be some restrictions to what I can do while starting a render), but I can show messages in the two places marked in the screenshot.

However, the bottom place with the red text is usually used for errors, so the user might think the render failed, so it might be better not to use it.

edit: but I can also show a friendly info message in blue in that place :)
Attachments
Capture.PNG
Captur2e.PNG
User avatar
B.Y.O.B.
Developer
Developer
Posts: 4146
Joined: Mon Dec 04, 2017 10:08 pm
Location: Germany
Contact:

Re: New OpenCL textures and materials evaluation code

Post by B.Y.O.B. »

Dade wrote: Fri Feb 21, 2020 1:28 pm
B.Y.O.B. wrote: Fri Feb 21, 2020 12:04 pm Is there a way to check if the call to KernelCacheFill() is necessary?
I could add a dedicated function (however calling KernelCacheFill() when the cache is already filled takes no time).
It would be good so I know when I have to show the message and when not.
marcatore
Donor
Donor
Posts: 463
Joined: Wed Jan 10, 2018 8:04 am

Re: New OpenCL textures and materials evaluation code

Post by marcatore »

sooooo...when it will be ready for testing? :)
User avatar
Dade
Developer
Developer
Posts: 5672
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade »

marcatore wrote: Fri Feb 21, 2020 3:49 pm sooooo...when it will be ready for testing? :)
The binaries for all OS can be downloaded from here: https://dev.azure.com/LuxCoreRender/Lux ... dArtifacts (the down arrow on right)

You can replace your pyluxcore.pyd with the one inside the downloaded win64.zip (yes, it is tricky and suggested only for advanced user).
Support LuxCoreRender project with salts and bounties
Post Reply