ComfyUI > Nodes > ComfyUI-YCNodes > Image Mirror

ComfyUI Node: Image Mirror

Class Name

ImageMirror

Category
YCNode/Image
Author
yichengup (Account age: 473days)
Extension
ComfyUI-YCNodes
Latest Updated
2025-06-03
Github Stars
0.02K

How to Install ComfyUI-YCNodes

Install this extension via the ComfyUI Manager by searching for ComfyUI-YCNodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-YCNodes in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Image Mirror Description

Create mirrored versions of images horizontally or vertically for artistic symmetry and aesthetic effects without complex editing.

Image Mirror:

The ImageMirror node is designed to provide a simple yet powerful way to create mirrored versions of images, either horizontally or vertically. This node is particularly useful for artists and designers who want to explore symmetry in their artwork or need to create mirrored effects for aesthetic purposes. By flipping the image along the specified axis, the node allows you to easily achieve a mirrored look without the need for complex image editing software. The ImageMirror node is an essential tool for enhancing creativity and adding a unique touch to your visual projects.

Image Mirror Input Parameters:

image

The image parameter is the primary input for the ImageMirror node, and it expects a tensor representation of the image you wish to mirror. This parameter is crucial as it provides the visual data that will be manipulated by the node. The input must be a torch.Tensor type, ensuring compatibility with the node's processing functions. The image should be pre-processed and ready for transformation, as the node will directly apply the mirroring effect based on the specified mirror_type.

mirror_type

The mirror_type parameter determines the axis along which the image will be mirrored. It offers two options: "horizontal" and "vertical". Choosing "horizontal" will flip the image from left to right, creating a mirror effect along the vertical axis. Conversely, selecting "vertical" will flip the image from top to bottom, creating a mirror effect along the horizontal axis. This parameter is essential for defining the direction of the mirroring effect, allowing you to customize the output according to your artistic needs.

Image Mirror Output Parameters:

IMAGE

The output of the ImageMirror node is an IMAGE, which is a tensor representing the mirrored version of the input image. This output retains the original image's dimensions and color information but reflects the specified mirroring transformation. The mirrored image can be used directly in your projects or further processed with other nodes to achieve more complex visual effects. The output is crucial for visualizing the impact of the mirroring operation and integrating it into your creative workflow.

Image Mirror Usage Tips:

  • To achieve a symmetrical effect, use the "horizontal" mirror type on images with a central focal point.
  • For creating reflections, the "vertical" mirror type can simulate a water reflection effect when combined with other visual elements.

Image Mirror Common Errors and Solutions:

输入必须是torch.Tensor类型

  • Explanation: This error occurs when the input image is not provided as a torch.Tensor.
  • Solution: Ensure that the image is converted to a torch.Tensor before passing it to the node. You can use libraries like NumPy and PyTorch to handle this conversion.

Invalid mirror_type value

  • Explanation: This error happens when the mirror_type parameter is set to a value other than "horizontal" or "vertical".
  • Solution: Double-check the mirror_type parameter and ensure it is set to either "horizontal" or "vertical" to avoid this error.

Image Mirror Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-YCNodes
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Playground, enabling artists to harness the latest AI tools to create incredible art.