cool thanks both for the help. this vector stuff is confusing thanks, Sam
On 10 November 2016 at 04:51, jonn <[email protected]> wrote: > def getLocalVecToWorldSpace(node, vec=om.MVector.kXaxisVector): > matrix = om.MGlobal.getSelectionListByName(node).getDagPath(0).inclus > iveMatrix() > vec = (vec * matrix).normal() > return vec > def axisVectorColinearity(node, vec): > vec = om.MVector(vec) > x = getLocalVecToWorldSpace(node, vec=om.MVector.kXaxisVector) > y = getLocalVecToWorldSpace(node, vec=om.MVector.kYaxisVector) > z = getLocalVecToWorldSpace(node, vec=om.MVector.kZaxisVector) > #return the dot products > return {'x': vec*x, 'y':vec*y, 'z':vec*z} > jnt = cmds.joint() > print axisVectorColinearity(jnt, [0,0,1]) > > 在 2016年11月9日星期三 UTC+8上午5:19:14,[email protected]写道: > >> Hello, >> >> i was wondering if there was a quick way of finding the equation of a >> plane normal to a vector in maya >> >> say the vector is (3,5,1) and passing through point (2,4,5) >> >> i was wondering if there was maybe a math command that could make this >> easier >> >> >> thanks, >> Sam > > -- You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/CA%2BGceHXMmqe3moc0Mr2FO5XAUfOp5BsvnBnK216FkP2A8tYYsw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
