Skip to main content
Question

How to convert a fme_collection(solid) to polygon?

  • September 16, 2021
  • 3 replies
  • 467 views

mahbouberezaiee

Hi.

I have some aggregated solids. In 2D view, they are like the attached image. I want to exactly convert them to polygon, keeping the inner lines (not a footprint). Do you know how can I do that?

3 replies

virtualcitymatt
Celebrity
Forum|alt.badge.img+36

Hmm, Have you tried deaggregating, using a surfacefootprintreplacer and the Re Aggregating? Would this give you the result you want?

Another option is to use a 2DForcer, but the result would probably need a bit of cleaning up to remove possible duplicate segments


mahbouberezaiee

Hi @virtualcitymatt​  and thank you for your suggestions, but in both I will get a surface at the end. How can I convert a surface to polygon? I tried by many transformers but it was unsuccessful. Actually, I want to differentiate between polygons(roofs) that are constructed from some parts and those which are just one simple polygon. If you have any idea .


virtualcitymatt
Celebrity
Forum|alt.badge.img+36
mahbouberezaiee wrote:

Hi @virtualcitymatt​  and thank you for your suggestions, but in both I will get a surface at the end. How can I convert a surface to polygon? I tried by many transformers but it was unsuccessful. Actually, I want to differentiate between polygons(roofs) that are constructed from some parts and those which are just one simple polygon. If you have any idea .

To get the roof surfaces out of a solid this is one approach:

First use a GeomeryPartExtractor to extract the faces (this part, geometry type = IFMEFace). This should give you individual faces. You can then feed the faces through a PlanarityFilter which can extract the surface normals. Use a test filter to test for postive z (roof) negative z (ground) z = 0 (wall).

If you want polygons you can use a GeometryCoercer to force the faces to polygons.

You can then use a Matcher (match in the building ID) to get building which are made up of multiple faces, those which have no match will be just single polygons​


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