VMD-L Mailing List
From: John Stone (johns_at_ks.uiuc.edu)
Date: Fri Jun 10 2011 - 09:40:45 CDT
- Next message: John Stone: "Re: Selecting multiple ranges"
- Previous message: John Stone: "Re: VMD does not exit after running closest.tcl script in combination with bigdcd"
- In reply to: Alberto Sergio Garay: "Problem using rotate command in a script ...(2)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Hi,
I tracked this down. The way the "rotate by" command currently works,
this behavior is expected and unavoidable. I can fix it so that this
doesn't occur in the next rev of VMD, but for now, do get around this,
rather than specifying the final increment parameter at the end of your
command, you need to change these to use loops, e.g.:
proc rotateX {} {
for {set i 0} {$i < 90} {incr i} {
rotate x by 1
display update
}
}
proc rotateY {} {
for {set i 0} {$i < 90} {incr i} {
rotate y by 1
display update
}
}
proc rot_X_Y {} {
set mymolid [molinfo top]
mol showrep $mymolid 0 on
display resetview
rotateX
rotateY
}
Cheers,
John Stone
vmd_at_ks.uiuc.edu
On Thu, Jun 09, 2011 at 03:11:01PM -0300, Alberto Sergio Garay wrote:
> Thank you Dr. Stone for the answer of my 1st e-mail
>
> Here I paste a part of my tcl script
>
> proc rotateX {} {
> rotate x by 90 1
> display update
> }
> proc rotateY {} {
> rotate y by 90 1
> display update
> }
> proc rot_X_Y {} {
> set mymolid [molinfo top]
> mol showrep $mymolid 0 on
> display resetview
> rotateX
> rotateY
> }
>
> When I run rot_X_Y (After source the script) I can only see the
> rotation about Y axis, but I want to see a rotation about x axis and
> then a rotation about y axis...
>
> Thank you for your help...
>
> Sergio
>
>
> --
> Dr. Sergio Garay
> Facultad de Bioquimica y Cs. Biológicas
> Universidad Nacional del Litoral
> Santa Fe - Argentina
> C.C. 242 - Ciudad Universitaria - C.P. S3000ZAA
> Argentina
> Ph. +54 (342) 4575-213
> Fax. +54 (342) 4575-221
>
>
>
>
>
-- NIH Resource for Macromolecular Modeling and Bioinformatics Beckman Institute for Advanced Science and Technology University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801 http://www.ks.uiuc.edu/~johns/ Phone: 217-244-3349 http://www.ks.uiuc.edu/Research/vmd/ Fax: 217-244-6078
- Next message: John Stone: "Re: Selecting multiple ranges"
- Previous message: John Stone: "Re: VMD does not exit after running closest.tcl script in combination with bigdcd"
- In reply to: Alberto Sergio Garay: "Problem using rotate command in a script ...(2)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]