Perfect Pistons in Shadertoy
Vložit
- čas přidán 27. 08. 2024
- In this tutorial I describe how to create a signed distance function like the one featured in the shader "Whack-A-Mole Pistons." I describe how you can make signed distance functions with repeated objects such that each object can differ in its own unique way, without experiencing glitches.
Errata:
- At the end I say "the worst possible SDF is the convex hull of the SDF" when the correct thing to say is "the worst possible SDF is the union of all possible configurations of the SDF." The use of the term "convex hull" is inaccurate.
Shaders in this video:
Whack-A-Mole Pistons - www.shadertoy....
Perfect Pistons Example 1 - www.shadertoy....
Perfect Pistons Example 2 - www.shadertoy....
Perfect Pistons Example 3 - www.shadertoy....
An article explaining erot and the hash function:
suricrasia.onl...
This is a goldmine of shader tricks. Thanks!
The clearest explanation of SDF over-stepping I’ve ever seen. Thanks!
6:37 - _intractable_ - excellent word choice!
Amazing breakdown!
Blackle Mori, back at it again
i had to let this soak for a few weeks and rewatch, but i am no longer as terrified of raymarching as i was!
This is gold! so many great tips, that axis rotation function looks great too. Just subscribed!
Extremely informative and clean, will be glad to see more videos from you!
This is timeless
Thank you, clearly presented. Gives me even more infinite possibilties to mix with fractals, if only i had infinite time:)
Great tutorial, very well explained!
Amazing explanation, love it. More please more 👋👋
Thanks! You managed to fix an issue I was having with repetition!
thank you, great tutorial, cool rotation function 😊
wow, that was insightful. Thanks!
Again a great video! Thanks!😀
Thanks for the tutorial!
Brilliant! Also looks like it’s time to trim down my mat4 rotation function.
Great explanation!
Super clever! Great video
I just realized the max height piston is also just the union of all possible pistons, it just happened to also be a valid piston
oh nice observation!
Blacke, seu mais novo amigo brasileiro! por favor, faça mais videos como esse! poucos tem a sua capacidade (de programação e de explicação)
This is amazing! Your a montster! Very helpful.
Thank you very much.
Good one
Great video!
For one more optimization, couldn't you query the neighbour cells and if the height of that neighbour piston is lower then the "me" piston, then you can ignore it altogether? That would I think help reduce the march count pretty cheaply (would only need to do the sin evaluation for neighbour cells).
that's an interesting idea! unfortunately, if we only check the immediate neighbour, we might have an issue where the neighbour on the other side is extremely tall and we fall into our overshoot problem again.
what you could do is use the real height of the neighbour by doing the sine evaluation, and then do the "worst case height" for the cell's other neighbour on the other side.
I'll make a little shadertoy to help explain what I mean...
here's an example: www.shadertoy.com/view/NtXGRn
But what about next neighbor?To skip checking loop of neighbor we have to take closet neighbor as worst
Gosh ! Thanks a lot !
Awesome
Thanks
nice trick!
Hello Blackle Mori. Do you plan on creating more shader videos in future? My life has purpose now :)
yes! I have one planned soon about different ways to add lighting to a model
@@suricrasia Superb! I've subscribed and switched on notifications. I love your clarity and depth. I'm already bracing myself up to ask you to come on to The OBG Show to do a half an hour interview on my series called Ordinary People. This wasn't my intention for making contact, and I hope this isn't considered spam. I just thought of it as I was replying.
Thank you for sharing a part of you with us.
thanks for the kind words. I appreciate the offer, but unfortunately I am not interested in being interviewed at this time.
I am excited for this series, great work!
i was here