Skip to content
This repository was archived by the owner on Apr 27, 2024. It is now read-only.
This repository was archived by the owner on Apr 27, 2024. It is now read-only.

Polygon hole can not show on VectorLayer #178

@sunshine0576

Description

@sunshine0576

when i add "PolygonDrawable " to the VectorLayer
Polygon holes cannot be drawn,Is there a way to solve this problem?,Is my style wrong?

VectorLayer vectorLayer = new VectorLayer(mMap);
Polygon shell =(Polygon) new GeomBuilder()
.point(0, 0)
.point()
.buffer(20)
.get();

    Polygon hole = (Polygon)new GeomBuilder()
            .point(0, 0)
            .point()
            .buffer(10)
            .get();

    Polygon polygon=new GeometryFactory().createPolygon((LinearRing) shell.getExteriorRing(),
            new LinearRing[]{(LinearRing)hole.getExteriorRing()});

    vectorLayer.add(new PolygonDrawable(polygon, defaultStyle()));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions