New OpenCL textures and materials evaluation code

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

Re: New OpenCL textures and materials evaluation code

Post by Dade » Fri Feb 21, 2020 1:32 pm

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
Posts: 3891
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade » 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.
Support LuxCoreRender project with salts and bounties

User avatar
Dade
Developer
Posts: 3891
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade » Fri Feb 21, 2020 1:36 pm

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
Posts: 1836
Joined: Fri May 04, 2018 5:16 am

Re: New OpenCL textures and materials evaluation code

Post by lacilaci » Fri Feb 21, 2020 1:38 pm

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
Posts: 107
Joined: Thu Jan 02, 2020 6:23 pm

Re: New OpenCL textures and materials evaluation code

Post by juangea » Fri Feb 21, 2020 1:45 pm

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
Posts: 1836
Joined: Fri May 04, 2018 5:16 am

Re: New OpenCL textures and materials evaluation code

Post by lacilaci » Fri Feb 21, 2020 1:51 pm

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
Posts: 3344
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. » Fri Feb 21, 2020 2:06 pm

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
Posts: 3344
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. » Fri Feb 21, 2020 2:14 pm

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
Posts: 395
Joined: Wed Jan 10, 2018 8:04 am

Re: New OpenCL textures and materials evaluation code

Post by marcatore » Fri Feb 21, 2020 3:49 pm

sooooo...when it will be ready for testing? :)

User avatar
Dade
Developer
Posts: 3891
Joined: Mon Dec 04, 2017 8:36 pm
Location: Italy

Re: New OpenCL textures and materials evaluation code

Post by Dade » Fri Feb 21, 2020 6:54 pm

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