Author Topic: Structure optimization trajectory  (Read 3009 times)

0 Members and 1 Guest are viewing this topic.

Offline ramkrishna

  • Supreme QuantumATK Wizard
  • *****
  • Posts: 253
  • Country: us
  • Reputation: 5
    • View Profile
Structure optimization trajectory
« on: December 9, 2013, 19:53 »
Dear Sir,
      If we want to put the structure optimization trajectory as a video on the power point presentation, is that possible? If so, then what is the procedure to extract the structure trajectory as a video.

Thanks
Ramkrishna 

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5576
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
Re: Structure optimization trajectory
« Reply #1 on: December 9, 2013, 23:09 »
Give me a few days and a few nights, I have a prototype, time to finish it, I think a lot of people will be glad.
You can prepare by downloading MPlayer from http://www.mplayerhq.hu/design7/dload.html - you will need it! :)

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5576
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
Re: Structure optimization trajectory
« Reply #2 on: December 10, 2013, 00:16 »
Ok, part of this turned out to be simpler than before, thanks to some prototype features in ATK 13.8! 8)

As mentioned, start by downloading MPlayer. For Linux you can probably get mencoder or the full mplayer suite via your package manager. On Windows, get the binary package from http://mplayerwin.sourceforge.net/downloads.html (32 or 64 bit) and extract mencoder.exe and the fonts directory into a directory that is in your PATH.

1. In VNL, open your trajectory in the Viewer.
2. Make all settings as you want them, meaning the view angle, colors, zoom level, etc.
3. Now, right-click the 3D window and choose "Export frames"; there are some options, fairly obvious.
4. When you click "OK", the movie will start to play in the Viewer (you can't stop it), and what it's actually doing is exporting each frame as a picture into the directory "Frames" in your current project.
5. Rename the directory immediately - in case you will export another set of frames later, you don't want to overwrite them, or intermix the image files.

The final part is something we will work on automating, but for now it will be a manual procedure. It needs to be performed from the command line.

6. Open a terminal and navigate to the directory with the frames.

mencoder takes a gazillion options which are very obscure unless you are familiar with video encoding. There are many suggestion on the web for what works, and gives best quality, etc - some work, some don't, some only in particular versions of mencoder, etc. When you export the frames, a file "encode" is actually created. You can try to run it (./encode) on Linux; on Windows, I could not get it to work, but I use another version:

7. Run

Quote
mencoder mf://*.png -o movie.avi -ovc lavc -lavcopts vcodec=msmpeg4v2:autoaspect:vbitrate=2160000:mbd=2:keyint=132:vqblur=1.0:cmp=2:subcmp=2:dia=2:mv0:last_pred=3 -mf w=800:h=600:fps=25:type=png

This will create movie.avi - sometimes there are some warnings or even error messages from mencoder but as long as movie.avi is created you're good.

8. The aspect ratio and frame rate should probably be changed - look in the "encode" file for the options to use for "-mf" to set the width (w) and height (h) matching the size of the Viewer scene window.

9. The movie should play in most players, but if in doubt, always look to VLC - or "mplayer" that you just downloaded and installed ;)

10. To make an flv file (smaller file size, suitable for online stuff), try

Quote
mencoder mf://*.png -o movie.flv -of lavf -oac mp3lame -lameopts abr:br=56 -srate 22050 -ovc lavc -lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:last_pred=3 -mf w=800:h=600:fps=25:type=png

The same point about the aspect ratio as above applies.

11. Have fun (and share your movies on YouTube or our Google+ group)!
« Last Edit: December 10, 2013, 00:21 by Anders Blom »