Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geometry checker into processing #59637

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

Djedouas
Copy link
Member

@Djedouas Djedouas commented Nov 28, 2024

Description

Supersedes #55939

This Pull Request aims to integrate the geometry checker in the processing toolbox within the scope of QEP 236.

Each process will follow a consistent logic: one input layer and two distinct outputs.

For check processing outputs are

  • a layer of the same type as the input layer with erroneous geometries only
  • a point layer with the error locations and information (feature id, part and vertex number, etc.)

For fix processing outputs are

  • a fixed layer of the same type as the input layer with corrected features according the the chosen method
  • a point layer with the error locations and report about the fix (fixed or not, message about the processed feature)

To ensure a consistent user experience, each process will operate similarly:

A default tolerance parameter is set at 8 (for 1e-8) in the advanced settings of every processing.

Demo video

https://vimeo.com/991495790

Screenshots

1. Check errors

Check geometry: errors will be created as a point layer showing places where the angle is < min angle

Launch processing

image

Errors layer attribute table

image

Source and errors layer

image

2. Fix with appropriate processing

Launch the delete vertex processing With the errors layer (output from the previous check) as input

image

Source and fixed layer (neon red)

image

Report layer showing what was done

image

Remarks - feedbacks welcome

The new processes are grouped under new categories named "Check geometry" and "Fix geometry". Suggestions for improved naming are welcome. The aim is to unify verification and correction processes from topology and geometry_checker plugins within these categories.

The current displayName, "Check/FIX Geometry (algorithm name)", is provisional. Any suggestions for enhancing this are welcome.

To avoid overwhelming process options, I've opted to enforce the "gc_" prefix for field names (see outputFields). It's worth considering whether to make this parameter configurable.

Next

Other Geometry Checker processes will be added following this review, and we plan to include additional correction/manipulation processes.


Funded by QGIS (Grant OpenSource 2023) and Oslandia

Part of qgis/QGIS-Enhancement-Proposals#236

cc @lbartoletti

@github-actions github-actions bot added this to the 3.42.0 milestone Nov 28, 2024
Porting angle check from geometry checker to processings
Porting angle fix from geometry checker to processings
Porting area check from geometry checker to processings
Porting area fix from geometry checker to processing
Porting hole check from geometry checker to processings
Porting hole fix from geometry checker to processings
Porting missing vertex check from geometry checker to processings
Porting missing vertex fix from geometry checker to processings
@Djedouas Djedouas force-pushed the geometry_checker_into_processing branch from 54438c3 to 2bd6a42 Compare November 28, 2024 17:02
Copy link

github-actions bot commented Nov 28, 2024

🪟 Windows builds

Download Windows builds of this PR for testing.
Debug symbols for this build are available here.
(Built from commit 2f69603)

🪟 Windows Qt6 builds

Download Windows Qt6 builds of this PR for testing.
(Built from commit 2f69603)

@Djedouas Djedouas force-pushed the geometry_checker_into_processing branch from de7cecc to 5b57909 Compare November 29, 2024 10:29
@Djedouas Djedouas force-pushed the geometry_checker_into_processing branch from 5b57909 to 2f69603 Compare November 29, 2024 13:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant