Commit e6ba2d4d authored by Eric Duminil's avatar Eric Duminil
Browse files

Write trees attributes too

parent 8f53b17a
......@@ -11,6 +11,7 @@ import org.locationtech.jts.geom.Coordinate;
import org.xmlobjects.gml.model.basictypes.Code;
import org.xmlobjects.gml.model.geometry.aggregates.MultiSurface;
import org.xmlobjects.gml.model.geometry.aggregates.MultiSurfaceProperty;
import org.xmlobjects.gml.model.measures.Length;
public class TreeUtils
......@@ -79,6 +80,8 @@ public class TreeUtils
crownRadius, crownHeight);
SolitaryVegetationObject cover = new SolitaryVegetationObject();
cover.setSpecies(new Code(tree.getType()));
cover.setCrownDiameter(new Length(crownRadius * 2));
cover.setHeight(new Length(trunkHeight + crownHeight));
cover.setId(UUID.randomUUID().toString());
cover.setLod2MultiSurface(new MultiSurfaceProperty(generatedTree));
cityModel.getCityObjectMembers().add(new AbstractCityObjectProperty(cover));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment