Basic Geometry.Transform Coordinate System Question

Hello!

I’m wondering if I have a fundamental misunderstanding of what a coordinate system is, and how the Geometry.Transform node is supposed to work.

In this example, I have a point which is the center point of the circle at the top of the screenshot, reporting 29.095,63.340.

I made 2 coordinate systems, one is just with a different origin (CS1), and another where I defined the rotation by creating vectors for the X and Y axes.

I would expect that if I put the circle’s center point through Geometry.Transform, I would get the X/Y coordinates that I have dimensioned, aka -39.449,55.84 for CS1 and 17.856,41.567 for CS2, but the results I get are wildly different. Am I missing something? Is there a better way of achieving this?

Many thanks!

For this I would use the transform override method with a context coordinate system. You want to go from the local coordinate system (CS2) to the global (CS1) so that the XYZ values of the point are shifted to the global coordinate system.

The specific call would look something like this: transformedPoint = Geometry.Transform(centerPoint,cs2,cs1);

The distance from the centerPoint to the origin of CS2 should be equal to the length of the transformedPoint as a vector, otherwise you’ve likely gone the wrong direction with your coordinate systems.

Thanks! I think it was because I didn’t define the original coordinate system.

1 Like