|
 |
In article <qqm### [at] schlatt fmi uni-konstanz de>, Thomas
Willhalm <tho### [at] willhalm de> wrote:
> IMHO it would be more "clean" to introduce a way to invert a
> transformation.
> As far as I know, the inverse matrix is already calculated internally.
> (The struct TRANSFORM has the two members "matrix" and "inverse".)
> So, the implementation should be easy.
>
> Then you would get the desired effect like this:
>
> #declare Trans = transform { translate .. rotate .... }
> #declare InvTrans = transform { invert_transform Trans }
> object { ... texture { ... transform{InvTrans} } transform {Trans} }
While I agree that something like this would be useful(as a matter of
fact, I have been considering it for my next project), I don't see how
it helps in pretextured objects. If your example is used, you don't even
need inverse_transform, you could write it like this:
#declare Trans = transform { translate .. rotate .... }
object { ... transform {Trans} texture { ... } }
However, many times, an object is composed of many parts with different
textures, your solution requires that everything be #declared and
assembled separately.
Really, I think a way to access CSG sub-objects and their
textures/transformations/interiors/flags through a dot notation would be
the best and most elegant way to do things. MegaPOV has taken some steps
toward this already. Some way to attach variables and macros to objects
would also be very useful.
--
Christopher James Huff - Personal e-mail: chr### [at] yahoo com
TAG(Technical Assistance Group) e-mail: chr### [at] tag povray org
Personal Web page: http://chrishuff.dhs.org/
TAG Web page: http://tag.povray.org/
Post a reply to this message
|
 |