Skip to main content
Solved

Splitting an Oracle polygon into lines and arcs


tfcw
Participant
Forum|alt.badge.img+1
  • Participant

I have an Oracle table full of polygons, I'd like to split them into the arcs and line segments they're composed of.

Is there any way I can do this? The closest I've found is setting a Chopper to split every 2 vertices, but this has the effect of turning any arc segment into several straight line segments, which is unwanted.

Best answer by takashi

Hi @yola, you can use the GeometryPartExtractor to extract arcs and lines from the polygon. Test clauses for the Geometry XQuery should be:

  1. This part | Geometry Type = IFMEArc
  2. This part | Geometry Type = IFMELine

Then, filter the arcs and the lines with the GeometryFilter, and apply the Chopper to only the lines in order to decompose them into individual line segments. The data flow looks like this.

View original
Did this help you find an answer to your question?

4 replies

takashi
Contributor
Forum|alt.badge.img+19
  • Contributor
  • Best Answer
  • December 7, 2016

Hi @yola, you can use the GeometryPartExtractor to extract arcs and lines from the polygon. Test clauses for the Geometry XQuery should be:

  1. This part | Geometry Type = IFMEArc
  2. This part | Geometry Type = IFMELine

Then, filter the arcs and the lines with the GeometryFilter, and apply the Chopper to only the lines in order to decompose them into individual line segments. The data flow looks like this.


jpdenboer
Contributor
Forum|alt.badge.img+2
  • Contributor
  • December 8, 2016

Hi @yola,

The solution from @takashi is a good one, but by complex polygons it will not perform well. You can place a DonutHoleExtractor and a GeometryCoercer between the reader en the GeometryPartExtractor to make it perform better. The data flow then looks like this.


nielsgerrits
VIP
takashi wrote:

Hi @yola, you can use the GeometryPartExtractor to extract arcs and lines from the polygon. Test clauses for the Geometry XQuery should be:

  1. This part | Geometry Type = IFMEArc
  2. This part | Geometry Type = IFMELine

Then, filter the arcs and the lines with the GeometryFilter, and apply the Chopper to only the lines in order to decompose them into individual line segments. The data flow looks like this.

I learned something new today, thanks!

 


takashi wrote:

Hi @yola, you can use the GeometryPartExtractor to extract arcs and lines from the polygon. Test clauses for the Geometry XQuery should be:

  1. This part | Geometry Type = IFMEArc
  2. This part | Geometry Type = IFMELine

Then, filter the arcs and the lines with the GeometryFilter, and apply the Chopper to only the lines in order to decompose them into individual line segments. The data flow looks like this.

I have a similar question. I extract the boundary line of a polygon with GeometryPartExtractor, and then try to decompose it with Chopper. But instead of four lines, the result is many of broken segments. Why is that? Thank you.


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