From: Chris Knorowski (cdknorow_at_iastate.edu)
Date: Wed Oct 23 2013 - 17:33:14 CDT

Thanks Josh,

 this did exactly what I wanted!

On Wed, Oct 9, 2013 at 5:08 PM, Josh Vermaas <vermaas2_at_illinois.edu> wrote:

> Hi Chris,
>
> There isn't, to my knowledge, one command that will do it. There are
> however a set of them that should work just fine:
>
> North
> coordtrans [measure inverse [lindex [molinfo top get rotate_matrix] 0]]
> [list 0 1 0]
> East
> coordtrans [measure inverse [lindex [molinfo top get rotate_matrix] 0]]
> [list 1 0 0]
>
> The way to unpack the meaning behind these is to work outwards. molinfo
> top get rotate_matrix gets the current rotation matrix, measure inverse
> will invert that matrix. Then we use coordtrans to multiply this matrix
> inverse by the cardinal directions in vector form. In playing with the
> results in the clip-plane tool, the command for north will pick up the top
> half of the loaded structure in clip-plane, and east will pick up the right
> half of the loaded structure (with distance 0). South and west are just
> inversions away.
>
> -Josh Vermaas
>
>
> On 10/09/2013 03:44 PM, Chris Knorowski wrote:
>
> Thanks Axel,
>
> The problem is I am rotating the screen, the planes that I would like to
> cut are not necessarily in the x,y,z direction. Using the clipping tool
> you can set it so that the normal to view is clipped but it is just not
> very easy to line up correctly. Its much easier to line it up so that the
> plane I want to clip is perpendicular to the view (in orthographic). I can
> calculate the vector to clip but it isn't straightforward to do, especially
> when I want to do it on a lot of differently oriented crystals. I guess I'm
> asking if there is a command that outputs what the current north, south or
> east vector in the display window is.
>
> Thanks,
> Chris
>
>
> On Wed, Oct 9, 2013 at 3:19 PM, Axel Kohlmeyer <akohlmey_at_gmail.com> wrote:
>
>> On Wed, Oct 9, 2013 at 9:25 PM, Chris Knorowski <cdknorow_at_iastate.edu>
>> wrote:
>> > Dear all,
>> >
>> > I have a quick question about vmd. I am using the clip tool to aid in
>> > visualizations of crystal structures. I'm wondering if there is a quick
>> way
>> > to figure out what direction in vmd the image is oriented so I can plug
>> that
>> > into the clip tool. For example, I'd like to be able to clip the plane
>> > whose normal is straight up (not the normal to the view).
>>
>> Display->Axes
>>
>> if you don't rotate. x is to the right, y is up and z is toward you.
>>
>> axel.
>>
>> >
>> > Thanks,
>> > Chris
>> >
>> >
>> > --
>> > Christopher Knorowski
>> >
>> > Iowa State Physics Department
>>
>>
>>
>> --
>> Dr. Axel Kohlmeyer akohlmey_at_gmail.com http://goo.gl/1wk0
>> International Centre for Theoretical Physics, Trieste. Italy.
>>
>
>
>
> --
> Christopher Knorowski
>
> Iowa State Physics Department
>
>
>

-- 
Christopher Knorowski
Iowa State Physics Department