1
mirror of https://github.com/comfyanonymous/ComfyUI.git synced 2025-08-02 15:04:50 +08:00

Fix MaskComposite error when destination has 2 dimensions (#8915)

Fix code that is using the original `destination` input instead of the reshaped value.
This commit is contained in:
Brandon Wallace
2025-07-15 20:08:27 -05:00
committed by GitHub
parent b1ae4126c3
commit 6b8062f414

View File

@@ -247,7 +247,7 @@ class MaskComposite:
visible_width, visible_height = (right - left, bottom - top,) visible_width, visible_height = (right - left, bottom - top,)
source_portion = source[:, :visible_height, :visible_width] source_portion = source[:, :visible_height, :visible_width]
destination_portion = destination[:, top:bottom, left:right] destination_portion = output[:, top:bottom, left:right]
if operation == "multiply": if operation == "multiply":
output[:, top:bottom, left:right] = destination_portion * source_portion output[:, top:bottom, left:right] = destination_portion * source_portion