ComfyUI > Nodes > ComfyUI-Unfake-Pixels > Pixel Art Scaler (Edge-Aware Auto-Scale)

ComfyUI Node: Pixel Art Scaler (Edge-Aware Auto-Scale)

Class Name

PixelArtScaler

Category
image/postprocessing
Author
tauraloke (Account age: 4960days)
Extension
ComfyUI-Unfake-Pixels
Latest Updated
2025-08-01
Github Stars
0.04K

How to Install ComfyUI-Unfake-Pixels

Install this extension via the ComfyUI Manager by searching for ComfyUI-Unfake-Pixels
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-Unfake-Pixels 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

Pixel Art Scaler (Edge-Aware Auto-Scale) Description

Transform RGB images into pixel art with edge-aware auto-scaling and cropping in ComfyUI framework.

Pixel Art Scaler (Edge-Aware Auto-Scale):

PixelArtScaler is a node designed for the ComfyUI framework, specifically aimed at transforming RGB images into pixel art by utilizing an edge-aware auto-scaling and cropping technique. This node is particularly beneficial for artists and designers who wish to convert high-resolution images into pixelated versions while maintaining the integrity of the original image's edges and details. The primary goal of PixelArtScaler is to automatically detect the optimal scale for pixelation based on the image's edge features, ensuring that the resulting pixel art is both aesthetically pleasing and true to the original composition. By leveraging advanced algorithms such as edge-aware detection, runs-based voting, and optimal cropping, this node provides a sophisticated yet user-friendly solution for creating pixel art from any image.

Pixel Art Scaler (Edge-Aware Auto-Scale) Input Parameters:

image

The image parameter is the input image that you want to transform into pixel art. It should be provided as a tensor, which is a multi-dimensional array used to represent the image data. This parameter is crucial as it serves as the base for all subsequent processing and transformations.

max_colors

The max_colors parameter defines the maximum number of colors that the resulting pixel art image should contain. This parameter helps in reducing the color palette of the image, which is a common characteristic of pixel art. By limiting the number of colors, you can achieve a more stylized and retro look. The exact range and default value are not specified, but typically, a lower number of colors results in a more pronounced pixel art effect.

cleanup_jaggies

The cleanup_jaggies parameter is a boolean option that, when enabled, applies a post-processing step to smooth out jagged edges in the pixel art image. This is particularly useful for enhancing the visual quality of the image by reducing unwanted artifacts that can occur during the pixelation process. The default value is not specified, but enabling this option can improve the overall appearance of the final image.

downscale_method

The downscale_method parameter specifies the method used to downscale the image during the pixelation process. Options include methods like 'nearest', which uses nearest-neighbor interpolation, and potentially others. The choice of downscale method can affect the sharpness and clarity of the resulting pixel art, with 'nearest' typically preserving hard edges better.

scale_detection_method

The scale_detection_method parameter determines the approach used to automatically detect the optimal scale for pixelation. The default method is 'edge_aware', which analyzes the image's edges to find the most suitable scale. This parameter is essential for ensuring that the pixel art maintains the original image's structure and details.

ea_tile_grid_size

The ea_tile_grid_size parameter is used in the edge-aware detection process to define the size of the grid tiles over which the edge analysis is performed. A larger grid size may result in a more generalized scale detection, while a smaller grid size allows for more detailed analysis. The specific range and default value are not provided, but adjusting this parameter can fine-tune the scale detection process.

ea_min_peak_distance

The ea_min_peak_distance parameter sets the minimum distance between peaks in the edge detection process. This helps in distinguishing significant edges from noise, ensuring that the scale detection focuses on the most prominent features of the image. The exact range and default value are not specified, but this parameter is crucial for accurate scale detection.

ea_peak_prominence_factor

The ea_peak_prominence_factor parameter influences the prominence of peaks considered during edge detection. A higher value may result in fewer, more significant peaks being detected, while a lower value could include more subtle edges. This parameter is important for refining the scale detection to match the desired level of detail in the pixel art.

Pixel Art Scaler (Edge-Aware Auto-Scale) Output Parameters:

output_tensor

The output_tensor is the transformed image data, represented as a tensor, that results from the pixelation process. This output is the pixel art version of the input image, with the specified scale and color limitations applied. It is the primary output of the node and can be used for further processing or display.

manifest

The manifest is a string that provides metadata about the pixelation process, including details about the scale, color reduction, and any other transformations applied. This output is useful for understanding the specific parameters and methods used during the pixelation, allowing for reproducibility and analysis of the results.

Pixel Art Scaler (Edge-Aware Auto-Scale) Usage Tips:

  • To achieve the best results, start with a high-resolution image and experiment with different max_colors settings to find the optimal color palette for your pixel art.
  • Use the cleanup_jaggies option to enhance the visual quality of the pixel art, especially if the initial results have noticeable jagged edges.

Pixel Art Scaler (Edge-Aware Auto-Scale) Common Errors and Solutions:

Scale detection failed: <error_message>

  • Explanation: This error occurs when the edge-aware scale detection process encounters an issue, possibly due to an unsuitable image or parameter settings.
  • Solution: Ensure that the input image is suitable for edge detection and adjust parameters like ea_tile_grid_size, ea_min_peak_distance, and ea_peak_prominence_factor to improve detection accuracy.

Downscaling failed: <error_message>

  • Explanation: This error indicates a problem during the downscaling process, which could be due to an unsupported downscale method or an issue with the image data.
  • Solution: Verify that the downscale_method is correctly specified and supported. If the problem persists, try using a different method or check the integrity of the input image.

Pixel Art Scaler (Edge-Aware Auto-Scale) Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-Unfake-Pixels
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 Models, enabling artists to harness the latest AI tools to create incredible art.