Skip to main content
Question

BoundingBox for DXF

  • January 17, 2020
  • 1 reply
  • 46 views

Forum|alt.badge.img

Hi,

 

I have different DXF/DWG file and want to calculate the BoundingBox of the geometries for every file.

The BoundingBox should be a seperate layer in the output file.

What is the best way to solve my problem?

 

Thanks and best regards

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.

1 reply

lars_de_vries
Forum|alt.badge.img+10
  • 388 replies
  • January 17, 2020

The hard thing with DXF is that you'll have to rewrite the whole file.

Creating a Bounding Box of everything in the file can easliy be done with a BoundingBoxAccumulator, that transformer will create a bounding box of all input features.

The output layer can be defined in the Writer, so that shouldn't be too much of a problem.

What you can do as a small trick, is to only write the BoundingBox and to set the source DXF as a template file in the Writer parameters. There you also set both 'Preserve Model Space' and 'Preserve Paper Space' to "Yes". It is advisible (and maybe even necessary) to choose a different filename for the output.

 

I hope this will fix your problem.