|
![](/i/fill.gif) |
In article <390581e3@news.povray.org>, Warp <war### [at] tag povray org>
wrote:
> I think that this patch is not of very much use if we can't get the
> transformations from an object. You seldom define the transformations of
> an object separately.
> How about a function to get the transformations applied to an object?
> Something like:
>
> #declare Trans = transformations(MyObject)
>
> object
> { MyObject
> transform { Trans inverse }
> }
>
> This would create an instance of MyObject without transformations.
>
> Of course there's a problem: What if MyObject is a CSG with nested
> transformations?
I would really prefer the dot operator instead, it is shorter by 1
character and a lot more flexible(it doesn't have the problems with CSG
transforms).
#declare Trans = transform {transformations(MyObject)}
#declare Trans = transform {MyObject.transformations}
#declare Trans = transform {MyObject.SubObject.transformations}
However, I don't know how easy this would be...it would have to use the
label feature, and there is probably already code that can be adapted to
do the job in MegaPOV. The same thing would be useful for textures and
interior.
This patch is still useful in some cases, though. We could implement
functions to access those variables as a stop-gap measure, but I don't
think that is a good idea...people would begin to use them, and they
would have to be removed later.
I will check out the label code, and see if I can do anything about it.
--
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
|
![](/i/fill.gif) |