Skip to main content
Solved

Create Geometry from XML (GML)


pflegpet
Contributor
Forum|alt.badge.img+8

Hi,

I am trying to create geometry from a coordinate list in GML but it does not work with the GeometryReplacer (GML). I don't know if I did anything wrong with exposing the XML attribute containing the geo or if the format is the problem.

The following template contains the workspace and the XML source. The coordinates are stored in the XML tag "Building.geometry2D.BuildingGeometry2D.geometry.Polygon.exterior.LinearRing.posList

Thanks in advance for any help!

Best answer by itay

Hi @kasparlov,

Use the xml_fragment attribute in the GeometryReplacer, this will work like a charm.

Itay

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

6 replies

itay
Supporter
Forum|alt.badge.img+17
  • Supporter
  • Best Answer
  • March 21, 2019

Hi @kasparlov,

Use the xml_fragment attribute in the GeometryReplacer, this will work like a charm.

Itay


pflegpet
Contributor
Forum|alt.badge.img+8
  • Author
  • Contributor
  • March 22, 2019
itay wrote:

Hi @kasparlov,

Use the xml_fragment attribute in the GeometryReplacer, this will work like a charm.

Itay

It does work but the xml_fragment only contains one point coordinate. I want to create polygon features from the "....posList" attribute that contains multiple coordinates.


ebygomm
Influencer
Forum|alt.badge.img+38
  • Influencer
  • March 22, 2019
pflegpet wrote:

It does work but the xml_fragment only contains one point coordinate. I want to create polygon features from the "....posList" attribute that contains multiple coordinates.

There doesn't appear to be any polygon geometry within your xml, only points...


nielsgerrits
VIP
Forum|alt.badge.img+54
pflegpet wrote:

It does work but the xml_fragment only contains one point coordinate. I want to create polygon features from the "....posList" attribute that contains multiple coordinates.

What @itay describes works very well, just use a GeometryFilter to split the points from the areas, as they are hard to find.


pflegpet
Contributor
Forum|alt.badge.img+8
  • Author
  • Contributor
  • March 22, 2019
nielsgerrits wrote:

What @itay describes works very well, just use a GeometryFilter to split the points from the areas, as they are hard to find.

Thank you, that works beautifully!


gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • March 22, 2019

@kasparlov

 

The member file wich is 564087.xml. Is zipped with fonts.

The canvas does not recognise it as a gml, which it is.

If you pull out the 564087.xml and put it on the canvas and choose gml, you get the geometry.

 

No geometryreplacer or anything needed.

 


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