Paolo Posted May 18, 2020 Share Posted May 18, 2020 Hello all, is there a way to get the rotation angle of an image (bitmap) inserted in Vectorworks? The angle is clearly shown in the OIP but it seems to be unreachable by code 🤔  Here's what I tried: vs.HAngle(h) This returns always 0.  I also searched in the appendix for some documented index to get the angle, but found nothing… vs.GetObjectVariableReal(h, index)  Also tried to get it from record fields… vs.GetParametricRecord(h) but Bitmaps are a native type and not plugin objects, so neither this worked…  Other ideas / suggestions? Quote Link to comment
JBenghiat Posted May 18, 2020 Share Posted May 18, 2020 vs.GetEntityMatrix() should do it. The z rotation should give you the plan rotation. 1 Quote Link to comment
Paolo Posted May 18, 2020 Author Share Posted May 18, 2020 I’ll give it a try, thanks 🙂 Quote Link to comment
Paolo Posted May 19, 2020 Author Share Posted May 19, 2020 Thank you JBenghiat, just tested and it works! Â r, offset, rotationXAngle, rotationYAngle, rotationZAngle = vs.GetEntityMatrix(imageHandle) rotationZAngle is the image (imageHandle) rotation value (the same showed in the OIP) Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.