XaiJu
entagma
entagma

patreon


Volumes 101 - Custom Kernels in OpenCL

Admittedly this is as arcane as it gets in our course on volumes. Admittedly this is also the fastest (execution wise) it's gonna get. We'll have a look at writing and edge detection kernel using OpenCL. We'll be able to run our code not only on our CPU but (given the right graphics card) also on our GPU, thus speeding up the computation by orders of magnitude.

Volumes 101 - Custom Kernels in OpenCL

Comments

OK, found my answer in later tutorials... To get custom sliders I need to put my param in "Bindings" and then re-generate the kernel template to read that in as a variable. By far this is mostly working. But I keep running into this weird issue that openCL node errors out saying "Invalid volume 'density' specified" when I change my parameters. But if i exist houdini and reload the scene it evals fine. Is this the openCL bug you were pointing out in other tutorial?

Yinglei yang

This might be a noob question: so for openCL, is there a way to create custom slider using similar syntax like chf() in VEX? I tried those VEX syntax and they didn't work in openCL (obviously), and I also tried to create a custom param manually but I was having problem reading the values in... So i was wondering if I did something wrong...

Yinglei yang

Hi Alex, admittedly I haven't tried declaring and initializing my temp array in openCL directly - that would make for a nice test case. Have you tried it yet? I'd speculate however that it's gonna slow down your setup. I have a gut feeling, that allocating memory for your temp array in each iteration step might be more costly than having two volumes created before executing your openCL code. However that's pure speculation and it might be worth to actually test this case...

Entagma

Sorry for late (and probably dumb) question. But here is just a thought - do you really need to make a copy of your main volume to temp in Sop? Can't you make a copy directly in opencl code? After all, a volume is just an array, so you probably could preinitialize second array in your code and copy original density there with the rest of code unchanged. Sorry again if the question is stupid. By the way, when you generate kernel, you don't need to manually select all text before copying to clipboard, you may right click and copy text right away

alex

great

azerila idnavak

Thanks you

SOUBIRAN Stephane

Thanks!

Vitaliy Novak

Mobile version for some reason it doesn't work as Ben said, but yes on the desktop. Sorry for the scare. Thank you for the new video. Merry christmas guys!

Samuel Alonso

That is because it is christmas and we (being hippies for the season) decided it'd be a nice gesture to give this one away as a present :) Happy holidays everyone! Frohe Weihnachten! Joyeux Noël! с Рождеством!

Entagma

Also, the tag says it's a premium course but it's accessible even to me who is just following you guys. Frohe Weihnachten btw.

Niels Provos

Hm - thanks for letting us know. Gonna see if I can find out why that is... Cheers, Mo

Entagma

Vimeo links won't work on mobile for whatever reason, they work fine otherwise!

Ben Carmeli

Which one? Just checked and the video as well as the scene file are accesible over here... Weird.

Entagma

The link is broken

Samuel Alonso


More Creators