QGIS API Documentation  3.20.0-Odense (decaadbb31)
qgspointcloudblockrequest.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgspointcloudblockrequest.h
3  --------------------
4  begin : March 2021
5  copyright : (C) 2021 by Belgacem Nedjima
6  email : belgacem dot nedjima at gmail dot com
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef QGSPOINTCLOUDBLOCKREQUEST_H
19 #define QGSPOINTCLOUDBLOCKREQUEST_H
20 
21 #include <QObject>
22 
23 #include "qgspointcloudattribute.h"
24 #include "qgstiledownloadmanager.h"
25 #include "qgspointcloudindex.h"
26 
27 #define SIP_NO_FILE
28 
30 class QgsPointCloudBlock;
31 
40 class CORE_EXPORT QgsPointCloudBlockRequest : public QObject
41 {
42  Q_OBJECT
43  public:
44 
49  QgsPointCloudBlockRequest( const IndexedPointCloudNode &node, const QString &Uri, const QString &dataType,
50  const QgsPointCloudAttributeCollection &attributes, const QgsPointCloudAttributeCollection &requestedAttributes,
51  const QgsVector3D &scale, const QgsVector3D &offset );
52 
58 
60  QString errorStr();
61 
62  signals:
64  void finished();
65  private:
67  QString mDataType;
69  QgsPointCloudAttributeCollection mRequestedAttributes;
70  std::unique_ptr<QgsTileDownloadManagerReply> mTileDownloadManagetReply = nullptr;
71  QgsPointCloudBlock *mBlock = nullptr;
72  QString mErrorStr;
73  QgsVector3D mScale, mOffset;
74  private slots:
75  void blockFinishedLoading();
76 };
77 
78 #endif // QGSPOINTCLOUDBLOCKREQUEST_H
Represents a indexed point cloud node in octree.
Collection of point cloud attributes.
Base class for handling loading QgsPointCloudBlock asynchronously.
QString errorStr()
Returns the error message string of the request.
QgsPointCloudBlockRequest(const IndexedPointCloudNode &node, const QString &Uri, const QString &dataType, const QgsPointCloudAttributeCollection &attributes, const QgsPointCloudAttributeCollection &requestedAttributes, const QgsVector3D &scale, const QgsVector3D &offset)
QgsPointCloudBlockRequest constructor Note: It is the responsablitiy of the caller to delete the bloc...
QgsPointCloudBlock * block()
Returns the requested block.
void finished()
Emitted when the request processing has finished.
Base class for storing raw data from point cloud nodes.