ComfyUI > Nodes > Allor Plugin > ImageDrawPieslice

ComfyUI Node: ImageDrawPieslice

Class Name

ImageDrawPieslice

Category
image/draw
Author
Nourepide (Account age: 2900days)
Extension
Allor Plugin
Latest Updated
2024-05-22
Github Stars
0.2K

How to Install Allor Plugin

Install this extension via the ComfyUI Manager by searching for Allor Plugin
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Allor Plugin 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
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

ImageDrawPieslice Description

Draw pie slice shapes on image canvas with customizable angles, colors, and SSAA support for smooth edges.

ImageDrawPieslice:

The ImageDrawPieslice node is designed to draw a pie slice shape on an image canvas. This node is particularly useful for creating visual elements that require a segment of a circle, such as charts, icons, or decorative graphics. By specifying the start and end angles, you can control the portion of the circle that is drawn. The node also allows you to customize the appearance of the pie slice with options for outline and fill colors, as well as transparency levels. Additionally, the node supports Super-Sampling Anti-Aliasing (SSAA) to enhance the quality of the rendered shape, ensuring smooth edges and a professional finish.

ImageDrawPieslice Input Parameters:

container

This parameter represents the image container that provides the dimensions for the canvas. It is used to determine the width and height of the image on which the pie slice will be drawn.

start_x

The x-coordinate of the starting point of the pie slice. This value is relative to the width of the canvas. It determines where the pie slice begins horizontally.

start_y

The y-coordinate of the starting point of the pie slice. This value is relative to the height of the canvas. It determines where the pie slice begins vertically.

end_x

The x-coordinate of the ending point of the pie slice. This value is relative to the width of the canvas. It determines where the pie slice ends horizontally.

end_y

The y-coordinate of the ending point of the pie slice. This value is relative to the height of the canvas. It determines where the pie slice ends vertically.

start

The starting angle of the pie slice in degrees. This angle is measured from the x-axis and determines the beginning of the arc.

end

The ending angle of the pie slice in degrees. This angle is measured from the x-axis and determines the end of the arc.

outline_size

The thickness of the outline of the pie slice. This value determines how thick the border of the pie slice will be.

outline_red

The red component of the outline color. This value ranges from 0 to 255 and determines the red intensity of the outline.

outline_green

The green component of the outline color. This value ranges from 0 to 255 and determines the green intensity of the outline.

outline_blue

The blue component of the outline color. This value ranges from 0 to 255 and determines the blue intensity of the outline.

outline_alpha

The alpha (transparency) component of the outline color. This value ranges from 0.0 to 1.0 and determines the transparency level of the outline.

fill_red

The red component of the fill color. This value ranges from 0 to 255 and determines the red intensity of the fill.

fill_green

The green component of the fill color. This value ranges from 0 to 255 and determines the green intensity of the fill.

fill_blue

The blue component of the fill color. This value ranges from 0 to 255 and determines the blue intensity of the fill.

fill_alpha

The alpha (transparency) component of the fill color. This value ranges from 0.0 to 1.0 and determines the transparency level of the fill.

SSAA

Super-Sampling Anti-Aliasing factor. This value determines the level of anti-aliasing applied to the pie slice to smooth out the edges. Higher values result in better quality but may increase processing time.

method

The resampling method used when resizing the canvas back to its original dimensions. This parameter determines the quality of the final image after SSAA is applied.

ImageDrawPieslice Output Parameters:

IMAGE

The output is an image tensor containing the drawn pie slice. This tensor can be used in further image processing nodes or directly rendered as part of the final image. The pie slice will have the specified outline and fill colors, transparency levels, and will be anti-aliased according to the SSAA setting.

ImageDrawPieslice Usage Tips:

  • To create a smooth and high-quality pie slice, use a higher SSAA value, such as 2 or 4, which will apply more anti-aliasing and reduce jagged edges.
  • Experiment with different start and end angles to create various segments of a circle, which can be useful for creating pie charts or circular progress indicators.
  • Adjust the outline size and colors to make the pie slice stand out against different backgrounds or to match the overall design of your image.

ImageDrawPieslice Common Errors and Solutions:

"Invalid container dimensions"

  • Explanation: The container parameter does not have valid dimensions or is not properly formatted.
  • Solution: Ensure that the container parameter is a valid image tensor with appropriate dimensions.

"Invalid color values"

  • Explanation: One or more color components (red, green, blue, alpha) are outside the acceptable range.
  • Solution: Verify that all color values are within the specified ranges (0-255 for RGB and 0.0-1.0 for alpha).

"Invalid SSAA value"

  • Explanation: The SSAA value is not a positive integer.
  • Solution: Set the SSAA parameter to a positive integer value to enable proper anti-aliasing.

"Invalid resampling method"

  • Explanation: The method parameter does not correspond to a valid resampling method.
  • Solution: Ensure that the method parameter is set to a valid resampling method, such as "nearest", "bilinear", or "bicubic".

ImageDrawPieslice Related Nodes

Go back to the extension to check out more related nodes.
Allor Plugin
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.