QGIS API Documentation  3.10.0-A Coruña (6c816b4204)
qgsabstract3dengine.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgsabstract3dengine.h
3  --------------------------------------
4  Date : July 2018
5  Copyright : (C) 2018 by Martin Dobias
6  Email : wonder dot sk at gmail dot com
7  ***************************************************************************
8  * *
9  * This program is free software; you can redistribute it and/or modify *
10  * it under the terms of the GNU General Public License as published by *
11  * the Free Software Foundation; either version 2 of the License, or *
12  * (at your option) any later version. *
13  * *
14  ***************************************************************************/
15 
16 #ifndef QGSABSTRACT3DENGINE_H
17 #define QGSABSTRACT3DENGINE_H
18 
19 #include "qgis_3d.h"
20 
21 #include <QObject>
22 
23 class QColor;
24 class QRect;
25 
26 namespace Qt3DCore
27 {
28  class QEntity;
29 }
30 
31 namespace Qt3DRender
32 {
33  class QRenderSettings;
34  class QCamera;
35 }
36 
50 class _3D_EXPORT QgsAbstract3DEngine : public QObject
51 {
52  Q_OBJECT
53  public:
54 
56  virtual void setClearColor( const QColor &color ) = 0;
58  virtual void setFrustumCullingEnabled( bool enabled ) = 0;
60  virtual void setRootEntity( Qt3DCore::QEntity *root ) = 0;
61 
63  virtual Qt3DRender::QRenderSettings *renderSettings() = 0;
65  virtual Qt3DRender::QCamera *camera() = 0;
67  virtual QSize size() const = 0;
68 
74  virtual void requestCaptureImage() = 0;
75 
76  signals:
78  void imageCaptured( const QImage &image );
79 };
80 
81 
82 #endif // QGSABSTRACT3DENGINE_H
3 Base class for 3D engine implementation.