28 Q_PROPERTY(
float clipNear READ clipNear WRITE setClipNear NOTIFY clipNearChanged)
29 Q_PROPERTY(
float clipFar READ clipFar WRITE setClipFar NOTIFY clipFarChanged)
30 Q_PROPERTY(
float fieldOfView READ fieldOfView WRITE setFieldOfView NOTIFY fieldOfViewChanged)
31 Q_PROPERTY(FieldOfViewOrientation fieldOfViewOrientation READ fieldOfViewOrientation WRITE setFieldOfViewOrientation NOTIFY fieldOfViewOrientationChanged)
33 QML_NAMED_ELEMENT(PerspectiveCamera)
36 enum FieldOfViewOrientation {
40 Q_ENUM(FieldOfViewOrientation)
42 explicit QQuick3DPerspectiveCamera(QQuick3DNode *parent =
nullptr);
44 float clipNear()
const;
45 float clipFar()
const;
46 float fieldOfView()
const;
47 FieldOfViewOrientation fieldOfViewOrientation()
const;
50 void setClipNear(
float clipNear);
51 void setClipFar(
float clipFar);
52 void setFieldOfView(
float fieldOfView);
53 void setFieldOfViewOrientation(QQuick3DPerspectiveCamera::FieldOfViewOrientation fieldOfViewOrientation);
56 void clipNearChanged();
57 void clipFarChanged();
58 void fieldOfViewChanged();
59 void fieldOfViewOrientationChanged();
62 explicit QQuick3DPerspectiveCamera(QQuick3DNodePrivate &dd, QQuick3DNode *parent =
nullptr);
63 QSSGRenderGraphObject *updateSpatialNode(QSSGRenderGraphObject *node) override;
66 float m_clipNear = 10.0f;
67 float m_clipFar = 10000.0f;
68 float m_fieldOfView = 60.0f;
69 FieldOfViewOrientation m_fieldOfViewOrientation = Vertical;