Dear all,

I am trying to use the Rotate() function through the python API.
However, the method want as argument, something in the for of "double
const [9]" (there are also other overloads, but the problem is the
same). In what format do I pass a list/vector/matrix to Rotate()?
Ideally, I want to use the output from RotAboutAxisByAngle(), but I
can't just pass the resulting matrix3x3. However, I can get the
elements of the generated rotation matrix through something along the
lines of the following hoops+loops:

some_rotation_matrix = openbabel.matrix3x3(1)
some_rotation_matrix.RotAboutAxisByAngle(openbabel.vector3(1,2,3), 90)

rotation_matrix  =[ [0.0 for i in range(3)] for j in range(3)]
for i in range(3):
        for j in range(3):
                print lol.Get(i,j)
                rotation_matrix[i][j] = some_rotation_matrix.Get(i,j)

So how can I pass these elements on to Rotate(), in order to give my
molecule a specific rotation?

Best regards
Anders

------------------------------------------------------------------------------
Increase Visibility of Your 3D Game App & Earn a Chance To Win $500!
Tap into the largest installed PC base & get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to