mathematical functions for scripting in LDCad


RE: mathematical functions for scripting in LDCad
#13
(2018-03-16, 17:15)Jarema Wrote: How calculate the angle of Technic Axle 6 relative to the Y axis.   See attached file.

Axles point into their local X direction, so...

Take a vector of 1 0 0
Transform it by the axles rotation ( :getRef, :getOri)
Take a vector of abs Y (0 -1 0)
Get the angle between the two by
absYVector:getAngle(absAxleXVector)


Hope this get you on the right path.

ps: I'm assuming you need this for scripting, during editing you better off using the selection information feature.
Reply
« Next Oldest | Next Newest »



Messages In This Thread
RE: mathematical functions for scripting in LDCad - by Roland Melkert - 2018-03-16, 18:08

Forum Jump:


Users browsing this thread: 4 Guest(s)