Skip to content

saturation_

villares edited this page May 24, 2020 · 4 revisions

Nome

saturation()

Exemplos

noStroke(); 
colorMode(HSB, 255); 
color c = color(0, 126, 255); 
fill(c); 
rect(15, 20, 35, 60); 
float value = saturation(c);  // atribui 126 a "value"
fill(value); 
rect(50, 20, 35, 60); 

Descrição

Extrai o valor de saturação de uma cor

Sintaxe

saturation(<font color="#996600">cor</font>)

Parâmetros cor qualquer valor do tipo de dados color

Retorno

float

Utilização

Web & Applicações

Relacionado

red() green() blue() hue() brightness()

Clone this wiki locally