Skip to content

Polygon-smooth crashes when dealing with MultiPolygons including more than one polygon with hole(s) #2323

@Pitouli

Description

@Pitouli

For example, if you test on this MultiPolygon, it will crashes:

{
  "type": "MultiPolygon",
  "coordinates": [
    [
      [
        [102.0, 2.0],
        [103.0, 2.0],
        [103.0, 3.0],
        [102.0, 3.0],
        [102.0, 2.0]
      ]
    ],
    [
      [
        [100.0, 0.0],
        [101.0, 0.0],
        [101.0, 1.0],
        [100.0, 1.0],
        [100.0, 0.0]
      ],
      [
        [100.2, 0.2],
        [100.8, 0.2],
        [100.8, 0.8],
        [100.2, 0.8],
        [100.2, 0.2]
      ]
    ],
    [
      [
        [105.0, 0.0],
        [106.0, 0.0],
        [106.0, 1.0],
        [105.0, 1.0],
        [105.0, 0.0]
      ],
      [
        [105.2, 0.2],
        [105.8, 0.2],
        [105.8, 0.8],
        [105.2, 0.8],
        [105.2, 0.2]
      ]
    ]
  ]
}

I found the issue and I am sending a PR (I simply create this ticket to link the PR to it)

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