I’m trying to get the global coordinates of a vertice.
This is probably very easy to do, but I don’t understand matrices. My guess is that I should multiply the vertex coordinate with the object matrix. Is this right? And how do I multiply that matrix with coordinates? Is there a function in Mathutils?
Yes! I got it… It always helps posting your question. Some way or the other it makes you think about the problem, and a few minutes after you get the solution. It was indeed multiplying the object matrix with the vector of the vertex coordinates. That rotates. And afterwards add the object location to the vertex location.
Thanks for the tip cambo, but it’s just to get the coordinate of one point. It’s part of a bigger picture, but it’s for centering the cursor to the lower left point in the mesh, together with jmsoler’s script that centers at cursor position.