22481 Commits

Author SHA1 Message Date
bdm-oslandia
e0f71afeaa
qgsgeometry: Add fromBox3D constructor 2023-07-26 09:17:17 +02:00
bdm-oslandia
4c23966008
qgsgeometry: Add fromPoint constructor 2023-07-26 08:58:49 +02:00
Nyall Dawson
d7ba6b5ca6 Port Processing "Keep N Biggest Parts" algorithm to c++
Also:
- Ensure that z/m coordinates in parts are not stripped away
- Handle curved geometries
- Allow dynamic data defined num of parts
2023-07-25 13:27:33 +10:00
Yoann Quenach de Quivillic
a4a49b05bc Fix hasFixedMapPosition logic 2023-07-25 05:06:49 +10:00
Yoann Quenach de Quivillic
a1c2885ea1 Add hasFixedMapPosition to QgsMapDecoration 2023-07-25 05:06:49 +10:00
pathmapper
5fee930371 Fix plugin voting from within plugin manager
Update URL, check reply status code and use blockingPost to be able to handle redirects.
2023-07-25 05:05:29 +10:00
Nyall Dawson
83bc6be01c Fix broken processing script editor actions
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
2023-07-24 19:44:04 +10:00
Martin Dobias
ecc1bf2c19 sip fix 2023-07-20 14:03:55 +02:00
Martin Dobias
e8f0e1cca1 fixes after rebase 2023-07-20 14:03:55 +02:00
Martin Dobias
5e3c230262 Small additions to QgsBox3d and QgsOrientedBox3D API
- 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
2023-07-20 14:03:55 +02:00
Nyall Dawson
a39b5df615 Rename mesh "3d" classes to "3D" and monkey patch compatibility 2023-07-20 15:31:00 +10:00
Nyall Dawson
5967344117 Rename QgsBox3d to QgsBox3D for consistency, monkey patch in old
name for PyQGIS compatibility
2023-07-20 15:31:00 +10:00
vcloarec
c3611c60a1 create postgres RO connection in the thread where the provider live 2023-07-19 10:10:11 +02:00
Nyall Dawson
aafd4f96fe Add more efficient multipoint constructor which can avoid point cloning 2023-07-19 16:52:05 +10:00
Nyall Dawson
78ecd083d3 Add a bunch of optimised/easier to use constructor variants
for creating QgsMultiPoint objects
2023-07-19 16:52:05 +10:00
Nyall Dawson
8c91e8fa97 By default, QgsProjectionSelectionTreeWidget should only
show horizontal (and compound) CRS in order to match behavior
of older releases

But allow opt in filters for display of vertical crs
2023-07-19 10:47:47 +10:00
Nyall Dawson
ef6057aadd Documentation, string cleanups 2023-07-19 10:47:47 +10:00
Nyall Dawson
dd933c9565 Use actual model in projection selection widget 2023-07-19 10:47:47 +10:00
Nyall Dawson
731123a425 Create a QAbstractItemModel and proxy model for displaying tree
view of coordinate reference systems
2023-07-19 10:47:47 +10:00
Nyall Dawson
ce95f9a522 Do a one-time read and store of qgis srs db, instead of re-reading with every widget construction 2023-07-19 10:47:47 +10:00
Martin Dobias
a271a36fda Expose QgsMatrix4x4 in Python + add PyQGIS test 2023-07-19 05:42:09 +10:00
Nyall Dawson
8a259dd1d4 Fix documentation warning 2023-07-18 12:35:45 +02:00
Nyall Dawson
8f995fbdba Make root bounding volume accessible from tiled mesh data provider,
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.
2023-07-18 12:35:45 +02:00
Nyall Dawson
f658e5de7b Create class for representing tiled mesh node bounding volumes
And implement for sphere, region and oriented box bounding volume
types
2023-07-18 12:35:45 +02:00
Nyall Dawson
9e5015aa47 Add equality operators for QgsOrientedBox3D 2023-07-18 12:35:45 +02:00
Nyall Dawson
8beb6a08c4 Add method to get corners of oriented box 3d 2023-07-18 12:35:45 +02:00
AkosSeres
14e2be69ae Fix formatting 2023-07-18 15:50:45 +10:00
AkosSeres
b800c90aa7 Fix high ram usage of XYZ tile generation 2023-07-18 15:50:45 +10:00
Alessandro Pasotti
37fc5d5a61
Merge pull request #53841 from elpaso/raster-band-description-gh-53831
Support raster band description
2023-07-17 19:00:31 +02:00
Alessandro Pasotti
8b5a2b55d3 Move comment 2023-07-17 15:53:30 +02:00
Nyall Dawson
c4b3608462 Rename to QgsOrientedBox3d 2023-07-16 14:43:38 +10:00
Nyall Dawson
8ca716907e Move QgsOrientedBoundingBox out to own file 2023-07-16 14:43:38 +10:00
Nyall Dawson
f5b4fbd9f1 Add QgsSphere::centerVector for returning center of sphere as a
vector
2023-07-16 14:43:38 +10:00
Nyall Dawson
d1d0f02661 Handle spherical volumes for cesium layer bounds 2023-07-16 14:43:38 +10:00
Nyall Dawson
5ab122bc62 Add new class QgsSphere for representing 3d spheres 2023-07-16 14:43:38 +10:00
Nyall Dawson
015fff4d39 Add support for oriented boxes as cesium volumes 2023-07-16 14:43:38 +10:00
Alessandro Pasotti
96e7f9eb5a Show raster band description
Fix #53831
2023-07-14 17:41:26 +02:00
Nyall Dawson
e567b35cab Fix crash when trying to re-load a layer from processing results
into the project when that layer already exists in the project

Fixes #53576
Fixes #53729
2023-07-13 15:03:29 +10:00
Nyall Dawson
c547f56776 [feature] Add 'DTM Filter (slope-based)' algorithm for filtering a
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.
2023-07-13 14:10:00 +10:00
Martin Dobias
1e48ebff1f Add setX, setY, setZ functions to QgsVector3D 2023-07-13 10:09:37 +10:00
Nyall Dawson
3641670b01 Add optional tile padding boundary to QgsRasterIterator
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.
2023-07-12 19:04:59 +10:00
Nyall Dawson
a739ad7097 Use nlohmann for json instead of QVariant
But leave QVariant version of util function for use in Python scripts
2023-07-12 14:58:33 +10:00
Nyall Dawson
b81e52dd43 Parse bounding region values from cesium tiles root tileset 2023-07-12 14:58:33 +10:00
Nyall Dawson
abeb8ae5fa Read tileset on creating cesium tiles data provider
And add some very basic provider metadata
2023-07-12 14:58:33 +10:00
Nyall Dawson
aa59687137 Setup framework for tiled mesh data providers to be cloned 2023-07-12 14:58:33 +10:00
Nyall Dawson
bc8c3a75b0 Add method to translate proj projection names
And abort crssync if unhandled projection strings are found
2023-07-11 14:57:04 +10:00
Nyall Dawson
95dc22f6b5 Fix handling of ' in enum docstrings in sipify 2023-07-09 22:48:59 +10:00
Nyall Dawson
71d6188e3d Add method to return CRS type, based on proj_get_type() values
And show in CRS details for layer properties
2023-07-09 22:48:59 +10:00
Nyall Dawson
31138aa970 Add method to retrieve list of known crs authorities 2023-07-09 18:14:10 +10:00
Nyall Dawson
3b1b6d56ec Correctly use horizontal vs single crs extraction methods in different
functions
2023-07-09 18:14:10 +10:00