Skip to main content
Question

Move all data to zero


jp12212
Contributor
Forum|alt.badge.img+4

I'm new to FME and want to create a workbench that translates 3D data to zero.

 

I have IN (reader) -> CenterPointExtractor -> Affiner -> OUT (writer).

 

Within Affiner have:

1, 0, @mult(@Value(_inside_x),(-1))

0, 1, @mult(@Value(_inside_y),(-1))

 

I've tried a bunch of variants of this but am struggling to get the data to move to zero. Workbench attached.

 

Thanks for the assistance.

6 replies

daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • April 17, 2023

Hi @jp12212​,

The Offsetter might be simpler than the Affiner, since you can just us the negatives of the center values as your offsets.


jp12212
Contributor
Forum|alt.badge.img+4
  • Author
  • Contributor
  • April 18, 2023

Hi @daveatsafe​ ,

 

I have modified as per below but it seems to not be working still. Any suggestions.

 

Cheers


david_r
Celebrity
  • April 18, 2023

You'll still need to offset relative to the geometry reference point (in this case it's the center point), otherwise you'll just move the geometry 1 ground unit south-west relative to the original position.

Try this:

image


jp12212
Contributor
Forum|alt.badge.img+4
  • Author
  • Contributor
  • April 18, 2023
david_r wrote:

You'll still need to offset relative to the geometry reference point (in this case it's the center point), otherwise you'll just move the geometry 1 ground unit south-west relative to the original position.

Try this:

image

Hi David,

 

Thanks for getting back to me - this seem to be working but not all the elements are moving (only the lines, not the solid box). Is this behaving as it should? I will go and test a couple of other files in case. If you see anything incorrect here though please let me know.

 

image.png


daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • April 18, 2023
jp12212 wrote:

Hi David,

 

Thanks for getting back to me - this seem to be working but not all the elements are moving (only the lines, not the solid box). Is this behaving as it should? I will go and test a couple of other files in case. If you see anything incorrect here though please let me know.

 

image.png

Remove the connection between the source feature type and the Offsetter - it is bypassing the CenterPointExtractor, creating a second set of features at the original location.


jp12212
Contributor
Forum|alt.badge.img+4
  • Author
  • Contributor
  • April 18, 2023

Great, thank you!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings