VTK: GUISupport/QtQuick/qml/QQmlVTKPlugin.h Source File

| VTK 9.3.1

QQmlVTKPlugin.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
3 #ifndef QQmlVTKPlugin_h
4 #define QQmlVTKPlugin_h
5
6 #include "vtkABINamespace.h"
7 #include "vtkDeprecation.h"
8
9 // Qt includes
10 #include <QQmlExtensionPlugin>
11
51 VTK_ABI_NAMESPACE_BEGIN
52 class VTK_DEPRECATED_IN_9_3_0("Use QQuickVTKItem instead") QQmlVTKPlugin
53 : public QQmlExtensionPlugin
54 {
55 Q_OBJECT
56 typedef QQmlExtensionPlugin Superclass;
57
58 Q_PLUGIN_METADATA(IID "org.kitware.VTK")
59
60 public:
64 QQmlVTKPlugin() = default;
65
69 ~QQmlVTKPlugin() override = default;
70
74 void registerTypes(const char* uri) override;
75
81 void initializeEngine(QQmlEngine* engine, const char* uri) override;
82
83 protected Q_SLOTS:
89 void cleanup();
90
91 private:
92 Q_DISABLE_COPY(QQmlVTKPlugin);
93 };
94
95 VTK_ABI_NAMESPACE_END
96 #endif // QQmlVTKPlugin_h
QQmlVTKPlugin
Plugin class to expose a VTK C++ module to QML applications.
Definition: QQmlVTKPlugin.h:54
QQmlVTKPlugin::registerTypes
void registerTypes(const char *uri) override
Register QML types provided by VTK.
QQmlVTKPlugin::~QQmlVTKPlugin
~QQmlVTKPlugin() override=default
Destructor.
QQmlVTKPlugin::QQmlVTKPlugin
QQmlVTKPlugin()=default
Constructor.
QQmlVTKPlugin::cleanup
void cleanup()
Destroy any singleton instances that were created during initializeEngine.
QQmlVTKPlugin::initializeEngine
void initializeEngine(QQmlEngine *engine, const char *uri) override
Initialize the extension using the QQmlEngine.
QQuickVTKItem
QQuickItem that manages a VTK rendering in the QML scenegraph.
Definition: QQuickVTKItem.h:27
vtkDeprecation.h
VTK_DEPRECATED_IN_9_3_0
#define VTK_DEPRECATED_IN_9_3_0(reason)
Definition: vtkDeprecation.h:99