|
|
Le 22/02/2023 à 16:09, yesbird a écrit :
> On 21/02/2023 21:22, Bald Eagle wrote:
>> Non-linear scale
>> #declare P = function {x*x + y*y + z*z - 1}
>> isosurface {
>> function {P(x, y*(1.05-y/5), z)}
>> ....
>> A non-linear stretch has turned this sphere into something like a
>> hen's egg. The
>> sphere is stretched more as y
>> becomes larger, and compressed more as y becomes more negative.
> It works fine for isosurfaces, but is it possible to scale arbitrary
> object non-linear way ?
On any objects, you can only have linear transformation, because of the
transformation arithmetic used: it's only a matrix of constant
coefficients applied to the ray equation.
non-linear scale is only possible on object whose definition is updated
by the operation: you get a new object.
That's what happen for isosurface by pushing the transformation over
input data.
You can also mangle the same way the data which create mesh/mesh2 and
maybe parametric and bicubic_patch.
I did play a bit with transforming mesh ( to get another mesh) with
non-linear transformation on hg-povray
https://wiki.povray.org/content/User:Le_Forgeron#Getting_a_new_mesh_from_a_mesh
> https://wiki.povray.org/content/User:Le_Forgeron#Getting_a_new_mesh_from_a_mesh
and https://wiki.povray.org/content/User:Le_Forgeron/mesh
> https://wiki.povray.org/content/User:Le_Forgeron/mesh
Post a reply to this message
|
|