|
 |
In article <3905aa7f@news.povray.org>, Warp <war### [at] tag povray org>
wrote:
> There's another problem. What about this:
>
> box
> { <1,2,3>, <4,5,6>
> rotate x*30
> texture { Whatever }
> rotate y*45
> }
>
> What will be the transformation got out of that?
transform {rotate x*30 rotate y*45}
There is only one transform struct per object, all transforms are added
into it. The transform struct contains two matrices, this is what made
implementing "inverse" so easy.
> In povray this kind of labeling would just be a shortcut for first
> #declaring the thing and then creating an instance of it. It would just
> do both things at once.
> Then perhaps you could do something like (not necessarily with this
> syntax):
>
> box \label{MyBox}
> { <1,2,3>, <4,5,6>
> transform \label{MyBoxTrans}
> { rotate x*30
> }
> }
>
> object { MyBox transform { MyBoxTrans inverse } }
>
> This would create two boxes. The first with transformations and the
> second without.
Maybe an "identifier" keyword could be added to everything that can be
defined, something like this:
object {...
identifier local LocalObject
texture {...
identifier global GlobalTex
}
}
While I think all #declare and #local statements should at least allow a
semicolon ending, I don't think one should be used here. It would be
inconsistent with the other flags/settings.
While something like this might be handy, I don't think it is really
necessary.
--
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
|
 |