blobBean is an extension of ifsBean. I am experimenting with this as a way to model non-rigid shapes.
The vertex coordinates are recalculated at each frame. When blobBean starts it adds a propertyChange Listener with rootBean. This is called by s_canvas which overloads the postRender() method of canvas3D. This calls back blobBean.propertyChange() every frame, which calls relax(), every frame, to recalculate the coordinates.

blobBean adds two new parameters to ifsBean, these allow you to specify which nodes can move, and which edges take part in the calculations.
nodeIndex is an array of indexes to the coordinates that can be moved. If a coord is referenced by coordIndex but not nodeIndex, then it is rendered, but does not move. If a coord is referenced in nodeIndex, but not in coordIndex, then it is just used for structure, but cant be seen. If its referenced by both then its rendered and can move.
Edges is an array of edges. Each edge specifies the indexes of the coords at each end (from and to), it also contains its nominal length. The length is calculated when the edge is first created. The coords referenced by the edge to and from fields may, or may not, be referenced in nodeIndex. In other words edges can connect moving and fixed coords.
The normals are calculated each frame, because if the coordinates move the normals are different. So and normals read from a file are ignored, also blobBean does not save normals.
This is like a 3D version of the GraphLayout demonstration program that comes with the JDK
| Classes written for this program | Java3D classes (scene graph structure) |

VRML2 definition:
Blob {
as for IFS with the addition of:
field MFInt32 nodeIndex
field MFEdge edges
}
VRML2 format
When an blob is saved it looks like this:
#VRML V2.0 utf8
Transform {
children [
Shape
{
geometry Blob {
coord Coordinate {
point
[
0.5 -0.5 0.5,
0.5 0.5 0.5,
-0.5 0.5 0.5,
-0.5 -0.5 0.5,
-0.5 -0.5 -0.5,
-0.5 0.5 -0.5,
0.5 0.5 -0.5,
0.5 -0.5 -0.5,
]
}
coordIndex [
0, 1, 2, 3, -1,
4, 5, 6, 7, -1,
7, 6, 1, 0, -1,
3, 2, 5, 4, -1,
1, 6, 5, 2, -1,
3, 4, 7, 0, -1,
]
texCoord TextureCoordinate {
point
[
1.0 0.0,
1.0 1.0,
0.0 1.0,
0.0 0.0,
1.0 0.0,
1.0 1.0,
0.0 1.0,
0.0 0.0,
]
}
texCoordIndex [
0, 1, 2, 3, -1,
4, 5, 6, 7, -1,
7, 6, 1, 0, -1,
3, 2, 5, 4, -1,
1, 6, 5, 2, -1,
3, 4, 7, 0, -1,
]
nodeIndex [
0, 1, 2, 3, 4, 5, 6
] edges [ 0 1, 1 2, 2 3, 3 0, 4 5, 5 6, 6 7, 7 4, 1 6, 2 5, 3 4, 0 7 ]
}
}
]
}





