3Dscript icon indicating copy to clipboard operation
3Dscript copied to clipboard

Smoothly return to starting position

Open habi opened this issue 3 years ago • 1 comments

I'd like to make an animation that will be shown looped. After cropping, rotating and zooming in to different parts of the sample I'd like to just -reset transformation in a last step of the animation to go back to the starting state.

I couldn't find a way of doing this smootly, e.g. just do

From frame X to frame Y:
  - reset transformation
  - change channel 1 bounding box x to (0.0, 2202.0)
  - change channel 1 bounding box y to (0.0, 1468.0)
  - change channel 1 bounding box z to (0.0, 1054.0)

and have the animation smoothly go back to the starting state. How can I achieve this?

habi avatar Jun 17 '22 10:06 habi

I think I figured out a way to do it. At the 'end' position of the animation started to record the transition and then 'reset' the transformation in the Interactive raycaster and stopped the recording of the transition. I then manually reset the clipping planes and also recorded the cropping. Putting all this together resulted in putting the sample back to the starting position (minus a rounding error in zooming).

Nonetheless I think it should be possible to animate -reset transformation.

habi avatar Jun 17 '22 11:06 habi