Skip to main content
Question

How to rotate a polygon around an axis?

  • April 18, 2019
  • 2 replies
  • 81 views

arthy
Contributor
Forum|alt.badge.img+8
  • Contributor
  • 101 replies

Hello,

 

I have a 3D polygon.

I would like to perform a rotation of that polygon around an axis with a specific angle value given a defined x,y,z point.

 

 

How can I do that inside a python caller?

 

Thanks

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

erik_jan
Contributor
Forum|alt.badge.img+22
  • Contributor
  • 2179 replies
  • April 18, 2019

Have a look at the 3DRotator transformer.

The functionality seems available, so why use Python?


jdh
Contributor
Forum|alt.badge.img+37
  • Contributor
  • 2002 replies
  • April 18, 2019

If you absolutely need to use python, since there is no build-in method to rotate in 3D like there is in 2D, you can use

fmeobjects.FMEFeature.performFunction(str) or

fmeobjects.FMEFactoryPipeline

I'm not sure which, as the 3DRotator does not appear to be in the functions and factories documentation

https://docs.safe.com/fme/html/FME_FactFunc/index.html

 

EDIT: It looks like the 3D rotator uses the @affine function