Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help
Special pages
SBGrid Resources
SBGrid Consortium
SBGrid Data Bank
Software Webinars
PyMOL Webinar
PyMOL Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
MovieSchool 5
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
===Object Motions=== Now that we're experts at moving the PyMOL camera around, let's start moving objects around while keeping the camera steady. To do this '''you must have matrix_mode set to 1''', otherwise PyMOL won't save your object's repositioning. Let's use the same proteins as from the above inhibitor example. This time, let's try to get a simple movie that shows one of the proteins and then have the other one fly in to do the inhibiting. <source lang="python"> # setup PyMOL for movies reinitialize set matrix_mode, 1 set movie_panel, 1 set scene_buttons, 1 set cache_frames, 1 config_mouse three_button_motions, 1 # download the complex and setup it up fetch 1te1, async=0 extract AA, c. A extract BB, c. B color marine, AA color grey, BB as surface, BB as cartoon, AA # intialize the movie mset 1 x410 # orient the scene set_view (\ 0.423117876, 0.061672822, 0.903973043,\ 0.789699256, -0.514252067, -0.334546506,\ 0.444237947, 0.855418444, -0.266292989,\ 0.000107866, -0.000027858, -196.784057617,\ 28.171787262, 70.919288635, 52.095287323,\ 155.143981934, 238.418914795, -20.000000000 ) # move the inhibitor off the screeen translate [0,0,100], object=AA # first movie scene frame 1 wizard message, "Let's watch the binder float it, while the camera doesn't move." mview store, object=AA mview store, object=BB # 2 second pause for the user to catch up frame 60 mview store, object=AA mview store, object=BB frame 300 # slide the inhibitor in from over the camera. :-) translate [0,0,-100], object=AA mview store, object=AA mview interpolate, object=AA # store & wait 2 seconds... frame 360 mview store, object=AA mview store, object=BB mview reinterpolate, object=AA mview reinterpolate, object=BB # 'explode' apart frame 380 translate [-70, 70, 70], object=AA translate [70, -70, -70], object=BB mview store, object=AA mview store, object=BB mview reinterpolate, object=AA mview reinterpolate, object=BB mplay </source> Hints: * Use the mouse to get the 'right orientation & zoom'. Then use [[get_view]] to get the view matrix. Finally, store that camera-position view matrix in your script. Works every time. * For object motions, the command '''translate [-70,70,70], object=AA''' would be the same as using the mouse and moving the object AA -70 units on the X-axis, +70 units on the Y and 70 on the Z. If you don't use the '''object=''' you will not get the desired effect. * For the above 'explosion' you can get quick motions by interpolating a large change over just a few frames.
Summary:
Please note that all contributions to PyMOL Wiki are considered to be released under the GNU Free Documentation License 1.2 (see
PyMOL Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
MovieSchool 5
(section)
Add topic