Meshroom/meshroom/ui/__main__.py
Yann Lanthony 48941a5782 [ui] first basic debugging UI + elementary commands
* nodes as a ListView (right click to delete a node)
* editable attributes 
* undo/redo for adding/removing nodes and attribute edition
2017-09-25 20:18:27 +02:00

26 lines
713 B
Python

import PySide2
import os
import sys
from PySide2.QtGui import QGuiApplication
from PySide2.QtQml import QQmlApplicationEngine
from meshroom.ui.reconstruction import Reconstruction
# TODO: remove this
pysideDir = os.path.dirname(PySide2.__file__)
os.environ['QT_QPA_PLATFORM_PLUGIN_PATH'] = pysideDir + '/plugins/platforms'
if __name__ == "__main__":
app = QGuiApplication(sys.argv)
url = os.path.join(os.path.dirname(__file__), "qml", "main.qml")
engine = QQmlApplicationEngine()
r = Reconstruction()
engine.rootContext().setContextProperty("_reconstruction", r)
engine.addImportPath(pysideDir + "/qml/") # TODO: remove this
engine.load(os.path.normpath(url))
app.exec_()