Inventor Engineer-to-Order

Inventor Engineer-to-Order

Active Contributor
Posts: 39
Registered: ‎09-19-2011
Message 1 of 4 (151 Views)

Intent function : Transformpoint

151 Views, 3 Replies
09-21-2012 05:38 AM

Hi,

I have a point p1 defined in frame1 and I want to know what its X,Y and Z values are in frame 2. I thought, according the documentation http://wikihelp.autodesk.com/Inventor_ETO/enu/2013/Help/0148-Inventor148/0525-Library_525/0870-Syste..., I could use the function Transformpoint. When I try this, Intent returns a point in worldframe instead of a point in frame2 coordinates. When I check these returned coordinates then they point towards another point in space but not my original point p1. Am I missing something ,or Am I doing something wrong. If so, what function should I use ?

Cheers,

Mark

Thanks Jon and Jack.

Both solutions helped me out !

Cheers, Mark

Board Manager
Posts: 243
Registered: ‎08-23-2006
Message 2 of 4 (135 Views)

Re: Intent function : Transformpoint

09-24-2012 11:50 AM in reply to: MarkBrouwersIntent

I think you want "invertFrame" or perhaps "relateFrame".  Look at the following rules, and their values:

```	Rule otherFrame As Frame = TranslateFrame(localFrame, Vector(1,1,1))

Rule otherPoint As Point = point_(0,0,0,otherFrame)

Rule originInOtherFrame As Point = transformPoint(origin, otherFrame)

Rule otherPointInMyFrame As Point = transformPoint(otherPoint, localFrame)

Rule otherPointInOtherFrame1 As Point = transformPoint(otherPoint, invertFrame(otherFrame))

Rule otherPointInOtherFrame2 As Point = transformPoint(otherPoint, relateFrame(otherFrame, localFrame))```

Jon Balgley
Autodesk Configurator 360 / Inventor ETO team
Autodesk, Inc.

Employee
Posts: 196
Registered: ‎03-06-2006
Message 3 of 4 (134 Views)

Re: Intent function : Transformpoint

09-24-2012 11:54 AM in reply to: MarkBrouwersIntent

The basic answer is simple.  "I have a point p1 defined in frame1 and I want to know what its X,Y and Z values are in frame 2."  Just call LocalX(p1) in the context of frame 2.  And LocalY, LocalZ, of course.

But I have answered this enough times in the last 20 years to think that maybe that isn't what you really want, though I hope it is.

You have to be very careful when you say "Intent returns a point in ..."  Intent doesn't really return things in the normal sense.  It knows the world coordinates of every point, and in theory handles all transformations for you.  Don't be misled by coordinates displayed in various windows; points should be treated as coordinate-free.  As a result, the ONLY time you really need LocalX and friends is when you are exporting data.  If you are playing with X Y and Z components in rules, for feeding to other rules, you are almost certainly doing the Wrong Thing (tm).

Active Contributor
Posts: 39
Registered: ‎09-19-2011
Message 4 of 4 (122 Views)

Re: Intent function : Transformpoint

09-24-2012 11:36 PM in reply to: MarkBrouwersIntent

Thanks Jon and Jack.

Both solutions helped me out !

Cheers, Mark

Announcements
Manufacturing Community