def onClicked(value):
     if self.playPause.label.getText() == 'Play':
         self.playPause.label.setText('Pause')
         self.timer = mh.addTimer(max(30, int(self.__skeleton.frameTime * 1000)), self.onFrameChanged)
     else:
         self.playPause.label.setText('Play')
         mh.removeTimer(self.timer)
예제 #2
0
 def stopPlayback(self):
     if not self.playPause:
         return
     self.playPause.setText('Play')
     if self.timer:
         mh.removeTimer(self.timer)
         self.timer = None
예제 #3
0
 def povwatch():
     if povwatchApp.poll() is not None:
         gui3d.app.getCategory('Rendering').getTaskByName(
             'Viewer').setImage(povwatchPath)
         mh.changeTask('Rendering', 'Viewer')
         gui3d.app.statusPersist('Rendering complete')
         mh.removeTimer(povwatchTimer)
예제 #4
0
 def startPlayback(self):
     self.playPause.setText('Pause')
     if self.timer:
         mh.removeTimer(self.timer)
         self.timer = None
     self.timer = mh.addTimer(
         max(30, int(1.0 / self.anim.frameRate * 1000)),
         self.onFrameChanged)
 def startPlayback(self):
     self.playPauseBtn.setText('Pause')
     if self.timer:
         mh.removeTimer(self.timer)
         self.timer = None
     if self.perFramePlayback:
         self.timer = mh.addTimer(max(30, int(1.0/self.animTrack.frameRate * 1000)), self.onFrameChanged)
     else: # 30 FPS fixed
         self.timer = mh.addTimer(30, self.onFrameChanged)
예제 #6
0
 def startPlayback(self):
     self.playPauseBtn.setText('Pause')
     if self.timer:
         mh.removeTimer(self.timer)
         self.timer = None
     if self.perFramePlayback:
         self.timer = mh.addTimer(
             max(30, int(1.0 / self.animTrack.frameRate * 1000)),
             self.onFrameChanged)
     else:  # 30 FPS fixed
         self.timer = mh.addTimer(30, self.onFrameChanged)
예제 #7
0
 def povwatch():
     if povwatchApp.poll() is not None:
         if os.path.exists(povwatchPath):
             imgpath = os.path.join(path, settings['name'] + '.png')
             shutil.move(povwatchPath, imgpath)
             gui3d.app.getCategory('Rendering').getTaskByName(
                 'Viewer').setImage(imgpath)
             mh.changeTask('Rendering', 'Viewer')
             gui3d.app.statusPersist('Rendering complete. Output path: %s' %
                                     imgpath)
         else:
             log.notice("POV - Ray did not produce an output file!")
             gui3d.app.statusPersist('Rendering failed!')
         mh.removeTimer(povwatchTimer)
예제 #8
0
 def startPlayback(self):
     self.playPause.setText('Pause')
     if self.timer:
         mh.removeTimer(self.timer)
         self.timer = None
     self.timer = mh.addTimer(max(30, int(1.0/self.anim.frameRate * 1000)), self.onFrameChanged)
예제 #9
0
 def povwatch():
     if povwatchApp.poll() is not None:
         gui3d.app.getCategory('Rendering').getTaskByName('Viewer').setImage(povwatchPath)
         mh.changeTask('Rendering', 'Viewer')
         gui3d.app.statusPersist('Rendering complete')
         mh.removeTimer(povwatchTimer)