Inpaint Paste Back — legacy (C2C):
The InpaintPasteBackMEC node is designed to seamlessly integrate an inpainted crop back into its original image using a specified STITCHER dictionary. This node focuses on a straightforward resize and alpha-paste operation, with the option to apply Gaussian-feathered edges for a smoother transition. It leverages a schema compatible with the InpaintCropProMEC, ensuring that the inpainted section is accurately resized and placed back into the original image without blending artifacts. This node is particularly beneficial for users looking to maintain the integrity of the original image while incorporating inpainted sections, offering a clean and efficient method to achieve professional results.
Inpaint Paste Back — legacy (C2C) Input Parameters:
stitcher
The stitcher parameter is a dictionary that provides the necessary schema for placing the inpainted crop back onto the original image. It is crucial for defining how the inpainted section aligns with the original image, ensuring that the placement is accurate and seamless. This parameter does not have a default value and must be provided by the InpaintCropProMEC.
inpainted_image
The inpainted_image parameter represents the inpainted crop result, formatted as a multi-dimensional array (B, H, W, C). This input is the section of the image that has been processed and is ready to be reintegrated into the original image. It is essential for the node to function, as it provides the content that will be pasted back.
upscale_method
The upscale_method parameter determines the interpolation method used when resizing the inpainted crop to fit back into the original image. Available options include "lanczos", "bicubic", "bilinear", "nearest", and "area". The choice of method can affect the quality and smoothness of the resized image, with "bicubic" often being the default for a balance between quality and performance.
feather_edges
The feather_edges parameter is a boolean that, when enabled, applies Gaussian-feathered edges to the inpainted crop. This option helps to blend the edges of the inpainted section with the original image, reducing visible seams and creating a more natural transition. The default value is typically False, meaning no feathering is applied unless specified.
feather_radius
The feather_radius parameter specifies the radius of the Gaussian feathering applied to the edges of the inpainted crop. This value determines the extent of the feathering effect, with larger values resulting in a more gradual transition. The parameter is only relevant if feather_edges is enabled.
Inpaint Paste Back — legacy (C2C) Output Parameters:
out
The out parameter is the final output image, which includes the inpainted crop seamlessly integrated back into the original image. This output is a multi-dimensional array that reflects the combined result of the original and inpainted sections, ensuring that the inpainting process is visually coherent and professionally executed.
info
The info parameter provides a summary of the operation, including details such as the number of frames processed, the upscale method used, and whether feathering was applied. This information is useful for understanding the processing steps and verifying that the desired settings were applied during the operation.
Inpaint Paste Back — legacy (C2C) Usage Tips:
- Ensure that the
stitcherdictionary is correctly configured and compatible with theInpaintCropProMECto avoid misalignment issues. - Choose the
upscale_methodbased on the desired quality and performance trade-offs; "bicubic" is often a good starting point for most applications. - Enable
feather_edgesand adjust thefeather_radiusto achieve smoother transitions between the inpainted crop and the original image, especially when dealing with complex textures or patterns.
Inpaint Paste Back — legacy (C2C) Common Errors and Solutions:
" Inpaint Paste Back — legacy (C2C): Invalid stitcher format"
- Explanation: This error occurs when the
stitcherinput is not a valid dictionary or does not conform to the expected schema. - Solution: Verify that the
stitcheris correctly generated by theInpaintCropProMECand that it contains all necessary information for the paste-back operation.
" Inpaint Paste Back — legacy (C2C): Inpainted image dimensions mismatch"
- Explanation: This error indicates that the dimensions of the
inpainted_imagedo not match the expected format or size for the operation. - Solution: Ensure that the
inpainted_imageis correctly processed and formatted as a multi-dimensional array (B, H, W, C) before inputting it into the node.
" Inpaint Paste Back — legacy (C2C): Unsupported upscale method"
- Explanation: This error is triggered when an invalid
upscale_methodis selected. - Solution: Choose from the supported interpolation methods: "lanczos", "bicubic", "bilinear", "nearest", or "area". Double-check the spelling and case of the method name.
