Fix alpha image issue in more nodes. · code/app-python-comfyui@3d2e3a6 · GitHub
Skip to content

Commit 3d2e3a6

Browse files
Fix alpha image issue in more nodes.
1 parent 2222cf6 commit 3d2e3a6

3 files changed

Lines changed: 12 additions & 6 deletions

File tree

‎comfy_extras/nodes_mask.py‎

Lines changed: 2 additions & 5 deletions

‎comfy_extras/nodes_post_processing.py‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import comfy.utils
88
import comfy.model_management
9-
9+
import node_helpers
1010

1111
class Blend:
1212
def __init__(self):
@@ -34,6 +34,7 @@ def INPUT_TYPES(s):
3434
CATEGORY = "image/postprocessing"
3535

3636
def blend_images(self, image1: torch.Tensor, image2: torch.Tensor, blend_factor: float, blend_mode: str):
37+
image1, image2 = node_helpers.image_alpha_fix(image1, image2)
3738
image2 = image2.to(image1.device)
3839
if image1.shape != image2.shape:
3940
image2 = image2.permute(0, 3, 1, 2)

‎node_helpers.py‎

Lines changed: 8 additions & 0 deletions

0 commit comments

Comments
 (0)