Skip to content

should the DouglasPeucker be used for the whole geometry instead of only pillar nodes? #1353

Closed

Description

@zhiqiangZHAO

I found in the OSMReader,
simplifyAlgo.simplify(pillarNodes);

I feel it's better to apply DouglasPeucker to the whole edges.
Guess it could reduce more unnecessary points.

Activity

  1. boldtrn commented on May 2, 2018

    @boldtrn
    Member

    I feel it's better to apply DouglasPeucker to the whole edges.
    Guess it could reduce more unnecessary points.

    Interesting, I think you are right. DouglasPeucker should not remove the first and last point, so we would only simplify pillar nodes, but consider the whole geometry including tower nodes, which could save up to two coordinates per edge.

  2. zhiqiangZHAO commented on May 2, 2018

    @zhiqiangZHAO
    ContributorAuthor

    I found this problem when I found a very rare case: duplicated lat/lon of the first node and second node . (anything could be true for OSM, 🤷‍♂️ ) Then I am curious why the DouglasPeucker doesn't remove the second node.

  3. zhiqiangZHAO commented on May 2, 2018

    @zhiqiangZHAO
    ContributorAuthor

    another question about DouglasPeucker, if the road is a z shape line.

    __________________________
                            /_________________________
    

    It seems DouglasPeucker will remove the z structure.
    Might not be a concern for road networks.

  4. boldtrn commented on May 3, 2018

    @boldtrn
    Member

    Douglas Peucker can remove details from a road, yes, but this should be only minimal, also see the Wiki about DP. If you think our implementation of DP is erroneous, it would be great if you could provide a sample test case (in a different issue :) or in our forum).

  5. added this to the 1.0 milestone on Mar 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions