Beispiel #1
0
    def update(self):
        super().update()

        if self.tracking: return

        origin = Point3.from_vec3(self.model.getCameraOrigin())
        target = Point3.from_vec3(self.model.getCameraTarget())
        self.trackball.reset(origin, target)
Beispiel #2
0
    def __init__(self, pt, parent=None):
        super().__init__(parent)

        self.pt = pt
        self.model = self.pt.getSceneModel()

        self.setFixedSize(pt.getWidth(), pt.getHeight())

        origin = Point3.from_vec3(self.model.getCameraOrigin())
        target = Point3.from_vec3(self.model.getCameraTarget())
        self.trackball = Trackball(origin, target)
        self.tracking = False
        self.setMouseTracking(False)