SIP is totally messed up here -- the dialog wrapper or something
is always prematurely cleaned which results in broken QObject
connections throughout.
Hack around this by storing dialog instances in a global list to
prevent too early wrapper garbage collection
- operators to move QgsBox3d by a QgsVector3D
- reproject QgsOrientedBox3D and get its axis-aligned bounding box
- get length of sides of QgsOrientedBox3D
- transform QgsOrientedBox3D with a QgsMatrix4x4
fix extent/crs handling for sphere/box bounding volume types
There's a tricky consideration here -- the default crs for sphere/
box bounding volumes is EPSG:4978. But we CANNOT transform from
EPSG:4978 without using valid z values (otherwise we get nonsense
results). This raises an issue with all the various QgsMapLayer
methods which use QgsMapLayer::crs to transform layer properties,
eg the layer's extent. If we advertise the layer (correctly) as
EPSG:4978, then the layer's extent will be incorrectly calculated
in 1000s of places in QGIS (and we are violating the api design
of these methods!)
So we handle this by always advertising these sources as EPSG:4979
(ie a geographic degrees based CRS of WGS84+height), and transform
the source's bounding volume to EPSG:4979 within the data provider,
considering correctly the source's z values, and use THIS as the
data provider's extent.
Then we add a new method to the QgsTiledMeshDataProvider interface
for meshCrs(), which returns the ACTUAL crs that the mesh
geometries are in (ie. EPSG:4978).
Care must be taken to use the correct choice of the advertised crs()
vs meshCrs() in methods which interact with tiled mesh data.
digital elevation model in order to classify pixels into ground
and non-ground cells
This is a port of the SAGA "DTM Filter (slope-based)" tool to a native
QGIS algorithm.
It also serves as a nice reference algorithm for raster based tools
which operate on a neighbourhood of pixels.
Allows returned blocks to overlap by the specified number of pixels.
Useful for algorithms which need to consider neighbouring pixels in
a tiled approach, without tile boundary artefacts.