Replies: 4 comments 1 reply
-
I notice @mkeeter 's original solution https://www.shadertoy.com/view/dls3Wr doesn't use the special |
Beta Was this translation helpful? Give feedback.
-
Winding sign has been modified and tested to use no comparators: https://gist.github.com/lf94/ca79b13d3d474eb20393468861e9ae79 |
Beta Was this translation helpful? Give feedback.
-
Something's still off but at least there is some geometry being output now. It appears much more efficient than the "simpler" method: https://gist.github.com/lf94/3e6528f1f42cdf425d082ba79d6d8d81 |
Beta Was this translation helpful? Give feedback.
-
All good now π Next up: Then we can have SVGs loading with libfive (and fidget), as I've done with Curv3d: https://github.com/curv3d/svg2curv (my GitHub cleanup accidentally wiped it out and rehosted it on my website) |
Beta Was this translation helpful? Give feedback.
-
Hey!
So I've been at it again this weekend trying to implement a sketching API. Obviously many try this with various degrees of success - I looked at Pidhorskyii's solution https://www.shadertoy.com/view/3dtBR4 since @mkeeter seemed to have interest in it for being simpler . Wanting to directly port this to libfive, immediately when seeing comparators I know the job becomes a bit of a time sink, trying to find alternatives.
After a bit, I found an exact equivalent using step/clamp/mix etc. https://gist.github.com/lf94/f12cefd593a5e8c83e5adf4fe1cf14b2#file-sketching-glsl-L68 It renders exactly like the original.
Then, I ported this to libfive, which required me to further implement step/clamp/mix without comparators.
Unfortunately, when I try to render it, Linux kills the process. It seems the explosion in resource usage is too much.
It would be fantastic if we could get this working. It would mean a ubiquitous sketching API in both libfive and fidget, since no comparators are used. After
sdLine
is working I'll dosdBezier
.For what it's worth, here is the tree of operations for a simple square example:
Beta Was this translation helpful? Give feedback.
All reactions