set image mode before preview
This commit is contained in:
parent
200a85335c
commit
85e3c36381
@ -183,7 +183,6 @@ def save_image(filepath, image):
|
|||||||
stop = False
|
stop = False
|
||||||
while not stop:
|
while not stop:
|
||||||
try:
|
try:
|
||||||
image.mode = 'RGB'
|
|
||||||
image.save(filepath)
|
image.save(filepath)
|
||||||
stop = True
|
stop = True
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
@ -269,6 +268,8 @@ def main():
|
|||||||
if emblem:
|
if emblem:
|
||||||
image = add_emblem(image, emblem)
|
image = add_emblem(image, emblem)
|
||||||
|
|
||||||
|
image.mode = 'RGB'
|
||||||
|
|
||||||
if preview:
|
if preview:
|
||||||
image.show()
|
image.show()
|
||||||
if not output:
|
if not output:
|
||||||
|
Loading…
Reference in New Issue
Block a user