365 Commits

Author SHA1 Message Date
Nyall Dawson
c2e1ea3b39 QgsGeometry::Change operator== should be const 2021-07-20 17:25:48 +10:00
Nyall Dawson
81b934d9d1 Rework API and improve memory handling of graph objects
Instead of QgsGraphBuilder::graph() taking the ownership of the graph
and leaving the QgsGraphBuilder in an unpredictable state, add an
explicit "takeGraph" method which takes the existing graph and
make the existing "graph" method just return a copy of the graph.

Also fix corresponding memory leaks in network analysis processing
algorithms.

Fixes #44079
2021-07-20 13:54:46 +10:00
Vincent Cloarec
8cd8bec5f2
[mesh] mesh frame editing part 3 - Advanced editing (#44169)
[mesh] [feature] Delaunay triangulation and face refinement for advanced mesh editing tools
2021-07-19 08:21:31 +02:00
nirvn
09760f07f0 Preserve python compatibility 2021-07-07 13:46:11 +07:00
nirvn
4b52b7be7f Move QgsExifTools utility class to core 2021-07-07 13:46:11 +07:00
Nyall Dawson
c8156b0106 Add c++20 todo for replacing equality operators with default implementations 2021-07-02 12:19:58 +10:00
Vincent Cloarec
d326d38660
[mesh] mesh frame editing part-1 (qgis_core) (#43828)
[feature] qgis_core changes to allow mesh layer editing (part-1 or QEP#228)
2021-06-25 16:17:13 +02:00
nirvn
54e8d80513 Add missing SIP bits 2021-06-01 13:49:56 +07:00
Alessandro Pasotti
d06f1e6467 Fix SIP issue with return results from calculateStatistics
Fixes #43245

SIP failed to convert the QMap<QgsZonalStatistics::Statistic, QVariant>
so we give it an QMap<int, QVariant>.
2021-05-22 07:04:16 +10:00
Nyall Dawson
eaf70803b0
Cleanup auto generated sip files and remove orphaned files (#43240) 2021-05-17 08:09:27 +02:00
Mathieu Pellerin
c259a408a4
Merge pull request #42781 from nirvn/snap_opti
Big optimization gains to the geometry snapper class
2021-04-22 14:26:14 +07:00
nirvn
2436f82bdf [optimization][geometry snapper] Get rid of custom tree, use GEOS 2021-04-19 13:37:21 +07:00
Nyall Dawson
ffa99b7b64 Fix doxygen blocks which don't use the * prefix on all lines, which
prevents the auto format and sipify scripts from doing their full
formatting magic
2021-04-19 12:54:13 +10:00
Denis Rouzaud
ba8a445850 run sipify 2021-03-22 21:13:52 +01:00
Nyall Dawson
e18584239f Force c++14 only for sip builds, as sip generated code uses deprecated c++ removed in c++17 2021-02-25 11:08:56 +10:00
Nyall Dawson
a7fd8e07f5 Revert 2021-02-25 11:08:56 +10:00
Nyall Dawson
d8a6d36780 Nice and friendly API 2021-02-21 15:18:57 +10:00
Nyall Dawson
fd7149ac97 Create class QgsGcpGeometryTransformer, which allows transformation
of geometry objects via a ground control points based transformation
2021-02-21 15:18:57 +10:00
Nyall Dawson
ce54321220 Rename pixel/layer/map coordinates to "source" and "destination", to
make classes more generic and avoid confusion with non-raster based
GCPs

Also flip function arguments to source, destination order instead
of destination, source
2021-02-21 15:18:57 +10:00
Nyall Dawson
ef78bf9a51 Add public transform method 2021-02-21 15:18:57 +10:00
Nyall Dawson
30245eef4d Add clone method 2021-02-21 15:18:57 +10:00
Nyall Dawson
ff195b373d Pixel -> layer 2021-02-21 15:18:57 +10:00
Nyall Dawson
f2f1d70fa7 Add factory method which creates an initialized transformer from method and list of GCPs 2021-02-21 15:18:57 +10:00
Nyall Dawson
125c33bf5c Move factory method to base class 2021-02-21 15:18:57 +10:00
Nyall Dawson
6628d5d27a Move method to string to QgsGcpTransformerInterface class 2021-02-21 15:18:57 +10:00
Nyall Dawson
fe8c768682 Move transform enum to base class 2021-02-21 15:18:57 +10:00
Nyall Dawson
8bf253d6ef Move classes representing GCP based transformations from app to analysis,
and make ready for exposure to public API
2021-02-21 15:18:57 +10:00
Alessandro Pasotti
7b2fc4c1f8 More doxy nonsense, pt 2 2021-02-19 08:15:29 +10:00
Nyall Dawson
50b9beaad6 [sipify] Catch more class references and insert :py:class: annotations 2021-01-31 05:41:22 +10:00
Nyall Dawson
578813ac78 Geocoder algorithms can be run in in-place mode too 2020-12-14 16:49:48 +10:00
Nyall Dawson
6ae7a17bf0 [API] Add an adapter class QgsBatchGeocodeAlgorithm which creates
a batch geocoding algorithm from a QgsGeocoderInterface

Example usage:

  # create a class which implements the QgsGeocoderInterface interface:
  class MyGeocoder(QgsGeocoderInterface):

     def geocodeString(self, string, context, feedback):
        # calculate and return results...

  my_geocoder = MyGeocoder()

  # create an algorithm which allows for batch geocoding operations using the custom geocoder interface
  # and implement the few required pure virtual methods
  class MyGeocoderAlgorithm(QgsBatchGeocodeAlgorithm):

      def __init__(self):
          super().__init__(my_geocoder)

      def displayName(self):
          return "My Geocoder"

      def name(self):
          return "my_geocoder_alg"

      def createInstance(self):
          return MyGeocoderAlgorithm()

      # optionally, the group(), groupId(), tags(), shortHelpString() and other metadata style methods can be overridden and customized:
      def tags(self):
          return 'geocode,my service,batch'
2020-12-14 16:49:48 +10:00
vcloarec
0a2af53c28 fix spelling doc ans SIP 2020-11-10 15:11:48 +01:00
Nyall Dawson
4f6f163ead Move geocoder classes to core 2020-10-30 14:31:04 +10:00
Nyall Dawson
d484beb7f3 Spelling 2020-10-30 09:19:48 +10:00
Nyall Dawson
0725112196 Spelling, since updates 2020-10-30 09:19:48 +10:00
Nyall Dawson
94f3ea0d14 Add interface API for geocoders 2020-10-30 09:19:48 +10:00
Matthias Kuhn
6ec342b4c0 Fix dox 2020-10-22 21:09:49 +02:00
vcloarec
abc112befc typo and spelling 2020-10-19 14:53:08 +10:00
vcloarec
b5c787bd06 fix feedback of TIN mesh creation 2020-10-19 14:53:08 +10:00
Nyall Dawson
746ee315bd Fix boolean literal presentation in dox/PyQGIS docs 2020-10-16 16:03:26 +10:00
vcloarec
89e4d4925a enable QgsMeshTriangulation with SIP and change SIP_CONCAT_PARTS 2020-09-10 20:16:44 -04:00
vcloarec
0f60631711 disable analysis/mesh/QgsMeshTriangulation with SIP 2020-09-10 14:50:25 -04:00
vcloarec
5ffc4f298a some fixes and add tests 2020-09-10 14:03:11 -04:00
vcloarec
07714f3931 port alg to c++
and minor fixes
2020-09-10 14:03:11 -04:00
vcloarec
9db4032d59 fix sip and doc 2020-09-10 14:03:11 -04:00
vcloarec
d2f4c40f8a TIN Mesh creation 2020-09-10 14:03:11 -04:00
Matthias Kuhn
3df789f8ff Sipdate 2020-09-09 19:22:55 +02:00
Matthias Kuhn
47a48bb0da More docs 2020-09-09 09:47:49 +02:00
Matthias Kuhn
94fe2f8d1d Add new algorithm to calculate zonal statistics into a new sink 2020-09-09 08:21:27 +02:00
Matthias Kuhn
c20ebcf182 [processing] Zonal Statistics create a new output instead of updating an existing one
Implements #29504
2020-09-08 20:16:21 +02:00