Blobs are complex shapes with an "organic" look defined as surfaces with the same potential in a field defined using point sources.
Blob definitions requires a list of blob items, a threshold and a material:
There are four blob item classes: balls, pipes, caps and repeaters. A ball is defined this way:
We can also define ellipsoids, substituting the single radius parameter with a vector giving the three main axis of the ellipsoid:
Pipes are cylindrical segments with open extremes, and must be specified like this:
You can close one or both extremes from a pipe using caps. Caps are hemispheres, so you create a cap the same way you create a ball, except that a top vector is needed for the cap:
Repeaters are created like this:
BlobRepeater can translate and rotate the repeating item. Of course, you don't have to translate and rotate at the same time. The scene optimizer always expands blob repeaters before render.
There are no equivalent for classes like Translate and Rotate for transforming blob items: the whole blob is a shape and you can rotate, translate and scale it as usual, but each individual blob item is not a shape. However, you still can use the move, spin and loop operators with individual blob items:
blob( ball(^y, 1, 0.9) move +0.5^z loop 3 by 1.15^z, ball(^y, 1, 0.9) spin 60^z loop 3 by 1.15^z, ball(^y, 1, 0.9) spin 120^z move +0.5^z loop 3 by 1.15^z, ball(^y, 1, 0.9) spin 180^z loop 3 by 1.15^z, ball(^y, 1, 0.9) spin 240^z move +0.5^z loop 3 by 1.15^z, ball(^y, 1, 0.9) spin 300^z loop 3 by 1.15^z, threshold: 0.6, material: metalPigment(gradient( darkorange, [-1,-1,-1], gold, [+1,+1,+1]), 0.0, 0.6, 0.9, 0.2, 90))
These transformations are always applied by the scene optimizer and they impose no additional runtime burden.
Let's imagine an energy field defined around a point:
For our needs, the field will achieve it's maximum at it's source, and a zero intensity at a given distance from the source. If we ask for the surfaces were the intensity is 0.5 and 0.8, for instance, we'll get two concentric spheres:
If we add another source, things get more complicated... and more interesting. If we ask for the surface with a given field intensity, we'll obtain a shape like this:
That's how blobs are defined: we start with a set of points. For each point, we define it's radius and a maximum intensity, and then, a threshold intensity. The blob is the surface where the total field intensity is the one defined by the threshold parameter.
I'm sure you'll find applications for blobs my philosophy never dreamt of... but until you get familiar with blobs, it's advisable to follow these tips, at least, if you appreciate enough you hair:
Home | Small Instantiation Language reference | Scenes | Shapes | Box | Sphere | Cone | Cylinder | Torus | Polyhedra