Visit ComfyUI Online for ready-to-use ComfyUI environment
Crop images based on relative coordinates for intuitive and flexible area selection, enhancing workflow efficiency.
The ImageTransformCropRelative
node is designed to crop images based on relative coordinates, allowing you to specify the cropping area as a proportion of the image's dimensions. This node is particularly useful for AI artists who want to focus on specific regions of an image without needing to calculate exact pixel values. By using relative coordinates, you can easily define the cropping area in a more intuitive and flexible manner, making it easier to apply consistent cropping across images of different sizes. This node simplifies the process of isolating parts of an image for further processing or analysis, enhancing your workflow efficiency and creative control.
This parameter expects a list of images that you want to crop. The images should be in a format that the node can process, typically tensors representing the image data.
This parameter defines the relative starting x-coordinate for the cropping area. It is a float value between 0.0 and 1.0, where 0.0 represents the left edge of the image and 1.0 represents the right edge. The default value is 0.25. Adjusting this value will shift the left boundary of the cropping area horizontally.
This parameter defines the relative starting y-coordinate for the cropping area. It is a float value between 0.0 and 1.0, where 0.0 represents the top edge of the image and 1.0 represents the bottom edge. The default value is 0.25. Adjusting this value will shift the top boundary of the cropping area vertically.
This parameter defines the relative ending x-coordinate for the cropping area. It is a float value between 0.0 and 1.0, where 0.0 represents the left edge of the image and 1.0 represents the right edge. The default value is 0.75. Adjusting this value will shift the right boundary of the cropping area horizontally.
This parameter defines the relative ending y-coordinate for the cropping area. It is a float value between 0.0 and 1.0, where 0.0 represents the top edge of the image and 1.0 represents the bottom edge. The default value is 0.75. Adjusting this value will shift the bottom boundary of the cropping area vertically.
The output is a list of cropped images. Each image is cropped according to the specified relative coordinates, resulting in a new image that contains only the defined region. This allows you to focus on specific parts of the image for further processing or analysis.
start_x
and start_y
to values around 0.25 and end_x
and end_y
to values around 0.75.start_x
and start_y
to 0.0 and end_x
and end_y
to 0.5. - Use small increments (e.g., 0.01) to fine-tune the cropping area for precise control over the region of interest.start_x
, start_y
, end_x
, or end_y
values are outside the range of 0.0 to 1.0.end_x
is less than or equal to start_x
, or end_y
is less than or equal to start_y
.end_x
and end_y
values to be greater than the start_x
and start_y
values, respectively.© Copyright 2024 RunComfy. All Rights Reserved.