POV-Ray : Newsgroups : povray.binaries.images : First Image: Inverted 3d truchet tiling : Re: First Image: Inverted 3d truchet tiling Server Time
10 Aug 2024 11:20:50 EDT (-0400)
  Re: First Image: Inverted 3d truchet tiling  
From: scam
Date: 23 Aug 2004 21:20:00
Message: <web.412a968e3db75be1c19ea0ce0@news.povray.org>
Florian Brucker <tor### [at] torfboldcom> wrote:
> > Once you have your 3d 'tile', you can stick a bunch of
> > them together, and then use the operation r -> r/(r.r), where r is a vector
> > representing any point, to get the effect in the image posted.
>
> OK. Understood all of it but this part. Could you explain it some more
> please? To me it looks like your applying some kind of
> matrix/transformations to all points of the object, to get that uneven
> scaling, is that true?
The easiest way to understand the transformation is to consider a plane.
Pick any point as your origin, and then draw a unit circle in the plane
centered on the origin. If you were to apply the transformation r -> r/|r|,
where |r| is the mod or distance of the point from the origin, then all
points would be mapped onto the unit circle. You can see this by
considering the length of an arbitrary transformed point: |(r/|r|)| =
|r|/|r| = 1. The transformation used in the image is r -> r/(|r|^2).
Because of the square, now every point outside the unit circle will be
moved inside the unit circle, and every point inside will be moved outside.
Again, you can see this by looking at the length of an arbitrary
transformed point: |r/(|r|^2)| = |r|/(|r|^2) = 1/|r|. Of course r can refer
to a point in three dimensions, and so the above argument is identical with
the unit circle replaced by a unit sphere. The resulting uneven scaling is
most easily understood by considering a plot of x and 1/x. One is a
straight line, the other is a curve.

The last point is that you apply the transformation to the vertices of your
polygons, so the final object has the same number of polygons, just moved
around. This is also the reason that the large parts of the object look
like they have a course mesh, while the small parts look quite smooth.

Creating the geometry in Mathematica is quite easy, although I don't know if
it is possible to do the same thing directly in povray, or if there would
be any advantages. I can't think of a way to avoid dealing with the
vertices of polygons you wish to transform, and so that seems to rule out
using the basic shapes that come with povray.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.