Seamless3d Node Index



Examples for this Tutorial contained in seamless_way_examples.zip


CCLathe  (Circular Curve Lathe)
 

The example file CCLathe.smls is a file set up with a stem node and a CCLathe node. The CCLathe node convertes the flat vertical triangles created by the Stem node into a lathe like shape. If the parent Stem's field sync is checked it will use the distance field from the CCLathe node in place if it's own yDistance field. This in effect syncronizes the CCLathe to the Stem node. When the Stem is synchronized it's distance field will be emptied automatically by Seamless3d.
 

If spaghetti mode is set

and the node that is selected is a CCLathe node then we should be able to see in the 3d window a thin spaghetti like object to the right side of the generated lathe shape when the index up-down control is clicked up or down. The piece of spaghetti is not meant to be part the 3d scene it is just a visual aide to let us know which curve segment is selected for editing as well as how long the curve segment is, how much it curves, where it begins and where it ends.When the index field is changed we should be able to see the piece of spaghetti flip from one segment to the other.

If you play with the CCLathe fields and look at the way the shape is altered as a result of changing the CCLathe it should become self explanatory how the fields control the shape. The two main fields to understand are the distance and curve fields. Changing the value of the distance field simply changes the length of the curve and changing the curve field changes how much the curve angle changes from the beginning of the segment to the end of the segment. Ticking the autoClose field makes the curve end in a perfect spherical curve. You wont be able to change the last fields for the distance and curve when autoClose is set because the CCLathe node automatically sets these last two fields when autoClose is active. The fields beginSP and endSP from the Stem node are useful for when we want our triangles to start from a single vertex point and or end in a single vertex point. This not only makes for greater efficiency in triangles by removing unwanted triangles from the ends but can also stop unpredictable side effects due to triangles on the ends being squashed to thin to be able to be logically understood as triangles (very thin triangles may cause the ends to appear dark or bright)

latheCylinder.smls
It is not hard to make near perfect cylinders using the CCLathe set up as one single segment and having the curve field set to a value close to 0. We cant make it = exactly 0 because the CCLathe strictly only works with curves. By having a curve of say .0001 radians (for index 1) the curve will be close enough to being straight to be treated as straight for most applications. To set the height of the cylinder change the distance field. To change the radius (thickness) of the cylinder change the baseRad field.

 CCLathe
index  1                           count 2
curve  0
distance  1
baseRad 
.2
autoClose 

curve and distance fields for index 0 and 1

index curve distance
0 0
1 .0001 1


 

latheSphere.smls
To make a sphere its very easy, just set the curve and distance fields for index 0 and 1 to:

index curve distance
0 -1.5708
1 3.1416 3.1416

and both beginSP and endSP should be checked and the baseRad should be 0. The size of the sphere is determined by the distance field. A distance of 3.1416 gives us a sphere with a radius of 1 meter. To calculate a sphere to have specific radius multiply 3.1416 with the desired radius and use this value for the distance field.





Seamless3d Node Index



Copyright© 2000-2006 Graham Perrett thyme@seamless3d.com