API Documentation
Loading...
Searching...
No Matches
CameraLocationWidget.h
Go to the documentation of this file.
1/*--------------------------------------------------------------------------------------------
2Copyright (c) 2019, NDEVR LLC
3tyler.parke@ndevr.org
4 __ __ ____ _____ __ __ _______
5 | \ | | | __ \ | ___|\ \ / / | __ \
6 | \ | | | | \ \ | |___ \ \ / / | |__) |
7 | . \| | | |__/ / | |___ \ V / | _ /
8 | |\ |_|_____/__|_____|___\_/____| | \ \
9 |__| \__________________________________| \__\
10
11Subject to the terms of the Enterprise+ Agreement, NDEVR hereby grants
12Licensee a limited, non-exclusive, non-transferable, royalty-free license
13(without the right to sublicense) to use the API solely for the purpose of
14Licensee's internal development efforts to develop applications for which
15the API was provided.
16
17The above copyright notice and this permission notice shall be included in all
18copies or substantial portions of the Software.
19
20THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
21INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
22PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
23FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
24OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25DEALINGS IN THE SOFTWARE.
26
27Library: NDEVR
28File: CameraLocationCombo
29Included in API: True
30Author(s): Tyler Parke
31 *-----------------------------------------------------------------------------------------**/
32#pragma once
33#include <NDEVR/QTModelManager.h>
34#if NDEVR_VIEWPORT
35#include <NDEVR/QTWindowManager.h>
36#include <NDEVR/QTDesignObject.h>
37#include <NDEVR/DesignObjectWidgetInterface.h>
38#include <NDEVR/CameraPane.h>
39#include <NDEVR/Button.h>
40#include <NDEVR/QTTools.h>
41#include <NDEVR/Camera.h>
42#include <NDEVR/Pointer.h>
43#include <QAction>
44#include <QRadioButton>
45#include <QActionGroup>
46#include <QMenu>
47#include <QHBoxLayout>
48namespace NDEVR
49{
50 class NDEVR_API CameraLocationWidget : public QTResourceListener, public DesignObjectWidgetInterface
51 {
52 public:
53 CameraLocationWidget(QTModelManager* manager);
54 CameraLocationWidget(QTModelManager* manager, DynamicPointer<Camera> camera);
55 void removeTarget(const DynamicPointer<QTDesignObject>& object) override;
56 void addTarget(const DynamicPointer<QTDesignObject>& object) override;
57 void setupMenu();
58 void setupAutoCamera();
59 void onZoom(SnapLocation location);
60 void valueChanged();
61 virtual void onTargetUpdated(UUID) override;
62 void setCamera(const DynamicPointer<Camera>& camera);
63 QWidget* widget() const;
64 DynamicPointer<Camera> camera() const;
65 signals:
66 void requestSettingsSignal();
67 protected:
68 void setup();
69 protected:
70 DynamicPointer<Camera> m_active_camera;
71 QTModelManager* m_manager = nullptr;
72 TimeSpan m_animation_time;
73 QRadioButton* m_perspective = nullptr;
74 QRadioButton* m_orthographic = nullptr;
75 Button* m_top = nullptr;
76 Button* m_bottom = nullptr;
77 Button* m_front = nullptr;
78 Button* m_back = nullptr;
79 Button* m_left = nullptr;
80 Button* m_right = nullptr;
81 QAction* m_settings = nullptr;
82 QWidget* m_widget;
83 bool m_has_pending;
84 };
85}
86#endif
#define NDEVR_API
Definition DLLInfo.h:67
Definition ACIColor.h:37