Skip to content

Complex geometries can generate a large number of cad guides #267

@megawac

Description

@megawac

Problem

As guides are generated by the edges of features registered for snapping, when map features have any complexity they can result in a large number of guides being generated. As shown in the image below, 2 features can generate a large number of lines (in the image 10). In our application we have seen in real maps 50+ lines being generated using nbClosestFeatures: 5. In cases like this the guides are essentially meaningless.

image

Proposal

Add a new option (limitGuidesFromFeature) to the cad control which provides the user the ability to limit the number of features that can be generated from any given feature. For example, you might limit the number of lines that can be possibly generated from a feature to 3; we would then limit the number of lines added to the map to the 3 most proximal to the users cursor. This way, there will be a hard maximum of lines ever shown on the users screen to nbClosestFeatures times the limitGuidesFromFeature.

(This is the strategy I plan to implement in my companies fork of the project, we will be happy to submit the implementation if this sounds reasonable).

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