Add native "Stealth" infotext support (#2684)
This commit is contained in:
@@ -197,10 +197,14 @@ def connect_paste_params_buttons():
|
||||
def send_image_and_dimensions(x):
|
||||
if isinstance(x, Image.Image):
|
||||
img = x
|
||||
if img.mode == 'RGBA':
|
||||
img = img.convert('RGB')
|
||||
elif isinstance(x, list) and isinstance(x[0], tuple):
|
||||
img = x[0][0]
|
||||
else:
|
||||
img = image_from_url_text(x)
|
||||
if img is not None and img.mode == 'RGBA':
|
||||
img = img.convert('RGB')
|
||||
|
||||
if shared.opts.send_size and isinstance(img, Image.Image):
|
||||
w = img.width
|
||||
|
||||
Reference in New Issue
Block a user