Hi,
I’m wondering how one would go about making a “flattener” type modifying technique to:
Take a torus geometry and flatten “to taste” the top and bottom of the poles of it…
(Considering its the usual horizontal orientation)
Imagine a torus sliced into horizontal sections.
How would I go about generating those one by one using a “flattening” of the points in the up/down axis?
(Not slicing a whole torus up)
Since it starts with a super-flat torus, and then just expands it according to your needs and the displacement map - this solution could likely be also used here.
Actually I wonder if I made a circle with a displacement map of horizontal stripes on it, then lathed THAT… To have the non displaced stripes be the only ones extruded along the lathe…hmmm what do you guys think?
Hmm but although the displacement will flatten, it would never completely “cut” or disallow extrusion huh.
If I use the flattening, via either method, and wanted just say, a torus in just 6 slices total, is just have to make 3 at different settings, then group and clone the group…then flip the cloned group on its vertical axis…
let v = new THREE.Vector3();
for( let i = 0; i < pos.count; i++ ){
v.fromBufferAttribute( pos, i );
pos.setZ( i, Math.abs( v.z ) > 0.3 ? Math.sign( v.z ) * 0.3 : v.z );
}