making a cube with jit.gl.isosurf/jit.expr
Hello all
I being use a old nesa patch metaballs, but i what to make a cube in jit.gl.isosurf, and not a sphere
the sphere is being generated from maths in jit.expr, can show me how to make a cube from it instead or give me some points?
thanks Ben
sorry, i've re-read my post and it did not make lots of sense here was the question:
I've been using an old Nesa patch, Metaballs, and I want to make a cube in jit.gl.isosurf, not a sphere.
The sphere is being generated from maths in jit.expr. Can someone show me how to make a cube from it instead, or give me some pointers?
thanks Ben
-- Pasted Max 5 Patch, click to expand. --
A cube is trickier. You'll need to come up with a distance function for a cube. Have a look at this page:
http://www.iquilezles.org/www/articles/distfunctions/distfunctions.htm
thanks for the answer, however i am struggling to understand how to implement the code from the page into jit.expr,
do i understand this right?
for making a cube in jit.gl.isosurf you would use a multi plane image with the xy being on the same plane and the z would be the plane number
any more help would be fab!
thanks
Ben
It'll be tricky to do with jit.expr because you need a length function. With jit.gen it's trivial:
wow thank you!! i am excited