You usually apply a transformation to your object before you draw them. There is three way to apply transormation:

[ul][li]use old deprecated openGL function like glTranslate, glRotate, glScale… etc…[*]Use your math library to compute the transformation matrix and then use glLoadMatrix[*] Apply the transformation matrix as an uniform in your shader[/ul][/li]In the last two points you already know the modelview matrix.

In case 1 openGL compute the matrix for you (taking care of multiple transformation, hierarchy, and camera transformation). To get the current modelview matrix you have to call

glGetFloatv(GL_MODELVIEW_MATRIX)

obviously I don’t have/want to repeat again that using glGet slow down the whole program. So if performance is critical use point 2 or 3