POV-Ray : Newsgroups : povray.general : The Box Object : Re: The Box Object Server Time
13 Aug 2024 03:10:54 EDT (-0400)
  Re: The Box Object  
From: Ron Parker
Date: 17 Nov 1998 14:29:02
Message: <3651ce7e.0@news.povray.org>
On Tue, 17 Nov 1998 10:54:00 -0700, Twyst <twy### [at] twystednet> wrote:
>As far as I can tell, it's because it's not scaling it. The XYZ coords are
>valid, as far as Pov is concerned, because it builds to those dimensions.

but you'd have a coincident surface problem that makes it unusable in any
practical sense, so you might as well use triangles or a polygon.

>Also, a scale <0,1,0> doesn't scale an object down to 0. Look at how scale
>works.. It's a percentage. think "scale by X" instead of "scale to X".

No, it does scale down to zero.  Effectively, it would project into a
plane.  While it's true that scale doesn't mean "scale to x," the result
is the same when x is zero, because anything multiplied by zero is zero.

The problem with zero scale is, the way transforms work is backwards of 
what one might expect.  The object doesn't move, the rays get transformed 
from "world space" into "object space" using the inverse of the specified 
transform.  Scales by zero are noninvertable (as is any matrix with a zero
determinant, such as an inappropriate combination of two shear transforms)
and therefore impossible to use in such a scheme.  Yes, it's avoiding 
division by zero, but there is no reasonable alternative.  

This model is also what makes nonlinear transforms difficult or impossible: 
a straight ray in world space turns into a curve when you try to transform 
it into object space, assuming you can even find an inverse transform, and
finding the intersection of an arbitrary curve with an object tends to be 
a bit tougher. (Though there are a class of transformations which are 
not linear yet still map lines to lines. These are the oft-requested 
perspective transforms, commonly stated as "scale X by Y".  They are not
invertible everywhere.)


Post a reply to this message

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