参考 blue()

blue()

Gets the blue value of a color.

blue() extracts the blue value from a p5.Color object, an array of color components, or a CSS color string.

By default, blue() returns a color's blue value in the range 0 to 255. If the colorMode() is set to RGB, it returns the blue value in the given range.

示例

语法

blue(color)

参数

color
p5.Color|Number[]|String:

p5.Color object, array of color components, or CSS color string.

返回值

Number: the blue value.
This page is generated from the comments in src/color/creating_reading.js . Please feel free to edit it and submit a pull request!

相关参考