Skip to content

Commit

Permalink
Blender: Create thread/worker per-transaction
Browse files Browse the repository at this point in the history
- Each preview / animation render task will launch in its own
  thread, which shuts down immediately on completion so that
  the next one gets its own, fresh thread.
  • Loading branch information
ferdnyc committed Oct 7, 2020
1 parent 6f6f653 commit 1d32542
Show file tree
Hide file tree
Showing 2 changed files with 179 additions and 166 deletions.
8 changes: 1 addition & 7 deletions src/windows/animated_title.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,19 +83,13 @@ def accept(self):
# Render
self.blenderView.Render()

def close(self):
def closeEvent(self, event):
""" Actually close window and accept dialog """
self.blenderView.end_processing()
super().accept()

def closeEvent(self, event):
self.blenderView.end_processing()
# Stop threads
self.blenderView.background.quit()

def reject(self):
# Stop threads
self.blenderView.background.quit()
self.blenderView.Cancel()
super().reject()

Expand Down
Loading

0 comments on commit 1d32542

Please sign in to comment.