Search Docs
Loading...
Skip to content

Interface: DominantColorsOptions

Options for BlockAPI.getDominantColors.

Properties#

PropertyTypeDefault valueDescription
count?number5Number of dominant colors to extract. The returned palette may contain fewer entries for images with very little variation, and is empty when count is 0.
ignoreWhite?booleanfalseIf true, near-white pixels are excluded from the analysis. Useful when analyzing images on white backgrounds to avoid the background dominating the result.