Author Topic: rotation single frame  (Read 416 times)

enriquemasa

  • Newbie
  • *
  • Posts: 6
rotation single frame
« on: January 19, 2018, 12:41:50 AM »
Hi Alex,

Is it possible with Ovito to create a video with a rotation of a single frame?

Thanks,
Best
Enrique

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 476
Re: rotation single frame
« Reply #1 on: January 19, 2018, 08:35:53 AM »
Hi Enrique,

Yes, all you need to know about this is described on this page: http://ovito.org/manual/usage.animation.html

Here is an overview of the steps:

  • Open the Animation Settings dialog and set the desired animation length
  • Activate Auto-Key mode
  • Go to the last animation frame
  • Activate the Rotation tool in the upper toolbar and enter a rotation angle of 360° into the z-axis axis input field that appears below the viewports.
  • That's it, the selected object should now perform a 360° rotation. You can deactivate Auto-Key mode again

zhen

  • Newbie
  • *
  • Posts: 8
Re: rotation single frame
« Reply #2 on: June 06, 2018, 05:59:05 PM »
Hi Alex,

I've tried to do what you have suggested. In the end I have two problems:

1. The axis of rotation is one edge of the simulation cell. I'd like to rotate the box along the center of the box, just like orbit camera does. Is this possible?
2. If I set the rotation angle of the last frame to 360, then it seems that the first frame will automatically be set to 0. Is it possible that I can make a movie of rotation only using one frame?

Thank you.

Best regards,
Zhen

Alexander Stukowski

  • Administrator
  • Sr. Member
  • *****
  • Posts: 476
Re: rotation single frame
« Reply #3 on: June 06, 2018, 07:39:04 PM »
1) The animated object will always rotate around its origin, i.e. (0,0,0) in the simulation coordinate system. But note that you can make use of the Affine Transformation modifier to shift all particles and the simulation cell by an arbitrary translation vector. With that, you can adjust the (apparent) center of rotation.

2) I'm not sure what you mean with that. My instructions were based on the assumption that you have loaded exactly one static simulation frame and that you have used the animation settings dialog to set the length of the animation to N animation frames (N>1). So what kind of frame do you mean when you ask how to make a movie using one "frame"? And yes: The idea is to set the rotation angle of the object to 0 degrees at animation frame 0, and to 360 degrees at the last animation frame. The program should interpolate between the two values.

If you think you did something wrong, and don't know what it is, please save the scene to an .ovito file and uploaded it here. I will take a look.
« Last Edit: June 06, 2018, 07:41:04 PM by Alexander Stukowski »

zhen

  • Newbie
  • *
  • Posts: 8
Re: rotation single frame
« Reply #4 on: June 07, 2018, 02:44:22 PM »
Hi Alex,

Thank you for your answer.

1) The first point regarding affine transformation is the problem solver. Very good to know.
2) I mean that I'd like to make a rotation movie using a single simulation configuration, e.g., one lammps dump file. But before I didn't realize that I can set the length of the animation to N animation frames with just one configuration loaded.

Now I have made the rotation movie follow your instructions. Thanks again.

Have a good day,
Zhen