POV-Ray : Newsgroups : povray.general : Convert translate/rotate list to single translate/rotate-Statement : Convert translate/rotate list to single translate/rotate-Statement Server Time
29 Jul 2024 00:30:05 EDT (-0400)
  Convert translate/rotate list to single translate/rotate-Statement  
From: Juergen
Date: 7 Dec 2013 12:25:00
Message: <web.52a359beeb205622a1cf996b0@news.povray.org>
Hello,

I've the following problem:
I'am using a big smooth_triangle mesh, which I translate and rotate on vertics
level by macros. The translate's and rotate's are needed for modification to the
mesh for a later animation.

After the modification I want to translate/rotate the mesh in it's original
postion. Currently I'm storing all applied translate/rotate in a list and do
them backwards. This works but needs lot of parsing time.

My question is now, how can I convert the list of translate's/rotate's to a
single translate/rotate statement ?


translate <1,2,3>
rotate <30,50,-20>
translate<-2,4,-5>
rotate<-40,130,70>
.....// lots of more transforms
rotate <10,0,40>

  |
  |
  V

translate <tx,ty,tz>
rotate <rx,ry,rz>

I need the values t?,r? so that I can use them in macros.



Post a reply to this message

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