A collection of useful ( and not so useful ) procedurally generated meshes. All generated with a Grid2DOnly MeshBox using U and V coordinates ranging from -Pi to Pi ( unless notified ).
Cool! thanks for posting these,. more fun stuff to play around with!
The more I work with these generative type geometries the better understanding I am developing of the math that defines them,. it is just great to have some starting places for gaining that.
I am wondering if we had a torus prim. if we could get rid of that seam on that very usefull torus bit you post elsewere? You know so the primitve, to begin with, was a solid torus geometry,. and we could use the equations to warp it from there? peace.
I'm posting here also the Sphere and the cylinder with subdivided upper and lower faces. A cylinder is to come if someone ask for it
Note: for the cylinder, you can change the variable "VarQ" that indicates how many "circles" you are going to have on upper and lower surface.
For Ville: try using "int" instead of "float" for VarP and tell me if it's working for you. I get different results. Is this because of truncate on integer divisions? If yes, it's fine
In the fall of 1972 President Nixon announced that the rate of increase of inflation was decreasing. This was the first time a sitting president used the third derivative to advance his case for reelection.
-=Hugo Rossi=-
Excellent! These are both great and usefull!! I apretiate the normal correctness, for perfect smoothing.
Keep 'em coming,. can you design a routine for a Icosphere?!?!
Hay,. I was just wundering about using renderMesh components to buils animated object,. would they be faster to animate? can closed shapes be made using these techneques??
I'm still looking for a way to do nice poly-trails,. you know 3d ribbons,. that fade in width,. and alpha preferably,. . I can get the points and build a list in arrays but havent figured how to draw them,.
Very cool,. this reminded me that the mesh component now has the nifty Graph feature! Curious, how have you have implemented Capsule Collision? Can it be added to the standard ZGE collision tests or is it dependent on a bunch of your own code?
ZZDC<?xml version="1.0" encoding="iso-8859-1" ?>
<Mesh Name="g_Z">
<Producers>
<MeshBox Grid2DOnly="255"/>
<MeshExpression>
<Expression>
<![CDATA[//V : current vertex
//N : current normal (turn off AutoNormals when modifying normals)
//C : current color (turn on VertexColors)
//TexCoord : current texture coordinate (turn on HasTexCoords)
v.y*=0.035;
v.x*=0.5;
v.x+=0.019;
v.y+=.385;]]>
</Expression>
</MeshExpression>
<MeshBox Grid2DOnly="255"/>
<MeshExpression>
<Expression>
<![CDATA[//V : current vertex
//N : current normal (turn off AutoNormals when modifying normals)
//C : current color (turn on VertexColors)
//TexCoord : current texture coordinate (turn on HasTexCoords)
v.x*=0.07;
if (v.y<-.5) v.y+=.65;
if (v.y<-.25) v.x-=.45;
if (v.y>.5) v.y-=.65;
if (v.y>.25) v.x+=.45;]]>
</Expression>
</MeshExpression>
<MeshCombine/>
<MeshBox Grid2DOnly="255"/>
<MeshExpression>
<Expression>
<![CDATA[//V : current vertex
//N : current normal (turn off AutoNormals when modifying normals)
//C : current color (turn on VertexColors)
//TexCoord : current texture coordinate (turn on HasTexCoords)
v.y*=0.035;
v.x*=0.5;
v.x-=0.019;
v.y-=.385;]]>
</Expression>
</MeshExpression>
<MeshCombine/>
<MeshTransform Scale="1 1.3 1"/>
</Producers>
</Mesh>