Grasshopper

algorithmic modeling for Rhino

Is it possible to create a Generalized IsoSurface Formula?

I have been exploring IsoSurfaces using K3dsurf for some time. I recently tried a Houdini Demo. It also has a Python math engine to create IsoSurface Geometry, but I found it extremely slow. Below are some examples from a site, showing the resulting geometry created in Houdini.

http://www.z-way.org/script-and-gizmo/houdini/isosurface/isocubes

The Math conventions are similar to those used in K3dsurf, or Mathematica, with some function definitions such as "$" are specific to the Houdini input format.

I'm curious if a complex IsoFormula of the example below,....(minus the non-conventional "$")

min( abs( abs( min( min( abs($X), abs($Y)), abs($Z))) -2)* cos( deg($PI/4))+ abs( abs( min( min( max( abs($X), abs($Y)), max( abs($X), abs($Z))), max( abs($Y), abs($Z)) ))-2)*sin(deg($PI/4))-0.4 , min( abs( abs( min( min( abs($X), abs($Y)), abs($Z)))-2), abs( abs( min( min( max( abs($X), abs($Y)), max( abs($X), abs($Z))), max( abs($Y), abs($Z)) ))-2)) )^2+(max(max(abs($X),abs($Y)),abs($Z))-3.4)^2-0.0225

can simply be copied into a Grasshopper Panel, attached to the rest of the Generalized IsoFormula.gh for evaluation and displayed in Rhino?

Views: 1749

Replies to This Discussion

Millipede has a great isosurfacing component. Here I'm using it along with Weaverbird to smooth. With something like this formula, you'll have to evaluate it in a 3D grid of values. I'm using VB to translate your formula because using a code component is generally faster than the expression editor for these kinds of things and "^2" translates to raising to the power, and I'm too lazy to do the Math.Pow(X,2) in C#. So you can see it's not quite as easy as a cut and paste, but it's pretty close...you have to reference Math.Sin, and you don't need any Deg conversions. Easily the longest part is the numerical calculation itself...the meshing component is really quick.

Attachments:

Thanks David, I will have a look at using Millipede, I did not think it would be a simple cut and paste either. :)

Hi David: I was just trying your iso.gh, which I'm unable to bake. Appears to be related to Millipede :(  My brand new install of Millipede appears to have expired)  So sad!

any ideas?

Hmm, that's odd...mine is also telling me that it's expired and is encouraging me to download a new one, but that doesn't stop me from either using it or baking to Rhino geometry.

What happens when you attach a just a mesh component to the output from the isosurface component, and try to internalize the geometry? 

Strange case of gremlins: its still expired, but its baking today. :)
Interestingly the GH mesh is a lot cleaner then the inset K3Dsurf mesh

Attachments:

Hi David:

your VB script and millipede is working well.  :) I have 3 questions

1. Whats causing the iso surfaces to appear stretched along the Z axis?

2. How can the iso surfaces be generated at the origin?

3. In order to create a 3d printable object, is it better to use grasshopper or rhino?

Attachments:

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service