|
 |
Josh English <Jos### [at] joshuarenglish com> wrote:
> On 7/24/2025 3:32 PM, Bald Eagle wrote:
> > "jr" <cre### [at] gmail com> wrote:
> >
> >> "there you are" ;-). (attached, 42 vectors, 80 faces)
> >
> > Rock, paper, scissors.
> >
> > Bezier Parallelpiped crushes them all.
> >
> > - BE
>
> Are you transforming the mesh as a whole or pulling the vertices out and
> transforming them?
>
> Josh
Unfortunately, there's not a way (that I know of) to access the vertices in a
native mesh.
So I cut/pasted the vertices into an array, and put a loop into the mesh2 to
cycle through the array.
To be able to easily reuse the mesh2 definition, I set a flag to either use the
original vertices, or run a macro to apply the Bezier distortion.
#macro MakeMesh (Distorted)
mesh2 {
vertex_vectors {
42,
#for (V, 0, 41)
#if (Distorted)
DistortedVertex (MeshVertices [V]),
#else
MeshVertices [V],
#end
#end
}
.. . . etc.
I know it would be great if we could just easily include any mesh, or run it
through a macro, but at present, I don't think that there's any way to do that.
I am pretty happy that it just required some "minor" modification to the formula
generating code, and this wasn't a major multiple-month project.
Anyway, it shows proof of concept. :)
- BE
Attached please find all the gnarly, hastily modified code.
Post a reply to this message
Attachments:
Download 'bezier_3d_for_mesh.pov.txt' (19 KB)
|
 |