From 378a78bc1a484ca8da724ec0d2158fc24b350a59 Mon Sep 17 00:00:00 2001 From: Khoi Nguyen Date: Wed, 24 Aug 2022 15:24:59 -0400 Subject: [PATCH] Comment out Crop region feature --- wrapper.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/wrapper.py b/wrapper.py index 81c72a7..e89f0a2 100644 --- a/wrapper.py +++ b/wrapper.py @@ -119,10 +119,10 @@ class PixelInteractive(RodanTask): 'type': 'boolean', 'default': False }, - 'Crop Image': { - 'type': 'boolean', - 'default': True - }, + # 'Crop Image': { + # 'type': 'boolean', + # 'default': True + # }, }, 'job_queue': 'Python3', } @@ -262,21 +262,21 @@ def convert(img): retval, buf = cv.imencode('.png', tmp) else: result = remove_bg(array) - if settings['Crop Image']: - result = result[y:y+h, x:x+w] + # if settings['Crop Image']: + # result = result[y:y+h, x:x+w] retval, buf = cv.imencode('.png', result) if i == 0: zipMe.writestr(('rgba PNG - Layer 0 (Background).png'), buf) elif i == len(output_list) - 1: - if settings['Crop Image']: - break + # if settings['Crop Image']: + # break zipMe.writestr(('rgba PNG - Selected regions.png'), buf) else: zipMe.writestr(('rgba PNG - Layer {0}.png').format(i), buf) - if settings['Crop Image']: - background = background[y:y+h, x:x+w] + # if settings['Crop Image']: + # background = background[y:y+h, x:x+w] retval, buf = cv.imencode('.png', background) zipMe.writestr(('Image.png'), buf)