diff options
| author | DH4 | 2017-05-28 07:36:34 -0500 |
|---|---|---|
| committer | DH4 | 2017-05-28 07:36:34 -0500 |
| commit | d9a5f2dd34c0bf14bfc99b58183b00d43217d889 (patch) | |
| tree | 7b420d9dc5215a51f1c16e4cfb14371ed1529a40 | |
| parent | 75c1c65c9d63515a1488b63e9df9971984e1f7e8 (diff) | |
Fixed Resolution Change in preview. Removed debugging print statements.
| -rw-r--r-- | main.py | 3 | ||||
| -rw-r--r-- | preview_thread.py | 8 |
2 files changed, 4 insertions, 7 deletions
@@ -299,7 +299,7 @@ class Main(QtCore.QObject): res = self.resolutions[resIndex].split('x') self.settings.setValue('outputWidth',res[0]) self.settings.setValue('outputHeight',res[1]) - self.drawPreview + self.drawPreview() def drawPreview(self): #self.settings.setValue('visLayout', self.window.comboBox_visLayout.currentIndex()) @@ -350,7 +350,6 @@ class Main(QtCore.QObject): self.window.stackedWidget.removeWidget(self.pages[index]) self.window.listWidget_componentList.takeItem(index) self.selectedComponents.pop(index) - print(self.selectedComponents) self.drawPreview() def changeComponentWidget(self): diff --git a/preview_thread.py b/preview_thread.py index e8b2021..7a7e619 100644 --- a/preview_thread.py +++ b/preview_thread.py @@ -28,7 +28,6 @@ class Worker(QtCore.QObject): "backgroundImage": backgroundImage, "components": components, } - print(components) self.queue.put(dic) @pyqtSlot() @@ -51,16 +50,15 @@ class Worker(QtCore.QObject): bgImage = bgImage[0] im = self.core.drawBaseImage(bgImage) - frame = Image.new("RGBA", (1280, 720),(0,0,0,255)) + width = int(self.core.settings.value('outputWidth')) + height = int(self.core.settings.value('outputHeight')) + frame = Image.new("RGBA", (width, height),(0,0,0,255)) frame.paste(im) componentWidgets = [self.stackedWidget.widget(i) for i in range(self.stackedWidget.count())] components = nextPreviewInformation["components"] - print(components) - print(componentWidgets) for component, componentWidget in zip(components, componentWidgets): - print('drawing') newFrame = Image.alpha_composite(frame,component.previewRender(self, componentWidget)) frame = Image.alpha_composite(frame,newFrame) |
