qgis / QGIS-Enhancement-Proposals

QEP's (QGIS Enhancement Proposals) are used in the process of creating and discussing new enhancements for QGIS
119 stars 37 forks source link

Clean up point cloud index and improve its thread safety #290

Open wonder-sk opened 8 months ago

wonder-sk commented 8 months ago

QGIS Enhancement: Clean up point cloud index and improve its thread safety

Date 2024/03/14

Author Martin Dobias (@wonder-sk)

Contact wonder dot sk at gmail dot com

Version QGIS 3.38

Summary

Handling of hierarchies is one of the fundamental pieces of the point cloud implementation that makes sure that datasets with millions or billions of points can be visualized quickly. The time has shown that some parts of the code has weak points - to be more specific, QgsPointCloudIndex and its derived classes. It would be good to address these problems to make sure that the code is robust and maintainable in the future. This includes thread safety, better interface to fetch hierarchies and less code duplication.

Proposed Solution

These are the bits of code that need attention:

If the time will allow, I would like to also make it possible to fetch hierarchy of point clouds in 3D views without freezing the user interface - this is already available for tiled scene layers (implementation of canCreateChildren() and prepareChildren() in QgsChunkLoaderFactory).

Deliverables

This work would be done in a series of pull requests that implement the proposed solution as mentioned above.

Risks

This is a low-risk task - all the major pieces of code are in place and they just need fixing to improve stability and code quality.

Performance Implications

There should be no performance implications.

Backwards Compatibility

There will be changes in the QgsPointCloudIndex interface, but this should be acceptable given that the class was intentionally marked as experimental.

nyalldawson commented 8 months ago

Sounds great to me!

anitagraser commented 8 months ago

Thank you for submitting your proposal to the 2024 QGIS Grant Programme. The 2 week discussion period starts today. At the end of the discussion, the proposal author has to provide a 3-line pitch of their proposal for the voter information material. (For an example from last year check https://github.com/qgis/PSC/issues/58#issuecomment-1567892412)