|
CortonaExtrusion is an extension of the standard Extrusion node. It allows for preventing the twist of extrusion models that have complicated spines.
CortonaExtrusion has preventTwist field, which value determines how the Z-axis of the SCP is computed.
If preventTwist is FALSE, then CortonaExtrusion is identical to the standard Extrusion. The orientation of each cross-section is calculated from the local curvature of the spine. In some cases this algorithm can cause undesirable twists and distortions of the surface.
The Z-axis for points other than the first or last is determined as follows:
z = (spine[i+1] - spine[i]) * (spine[i-1] - spine[i])
If preventTwist is TRUE, then the orientation of each cross-section (except the first one) is approximately parallel to the orientation of the previous cross-section. This algorithm can help avoid undesirable twists and distortions.
The Z-axis for points other than the first or last is determined as follows:
z = x[i-1] * y[i]
CortonaExtrusion {
eventIn MFVec2f set_crossSection
eventIn MFRotation set_orientation
eventIn MFVec2f set_scale
eventIn MFVec3f set_spine
field SFBool preventTwist FALSE
field SFBool beginCap TRUE
field SFBool ccw TRUE
field SFBool convex TRUE
field SFFloat creaseAngle 0
field MFVec2f crossSection [1 1 1 -1 -1 -1 -1 1 1 1]
field SFBool endCap TRUE
field MFRotation orientation [0 0 1 0]
field MFVec2f scale [1 1]
field SFBool solid TRUE
field MFVec3f spine [0 0 0 0 1 0]
}
|
Example
|