Mixin: ColorMixin

util.ColorMixin

This mixin implement color and contrast changes for visual stimuli

Source:

Methods

getContrastedColor(color, contrast)

Get a new contrasted Color.
Parameters:
Name Type Description
color string | number | Array.<number> the color
contrast number the contrast (must be between 0 and 1)
Source:

setColor(color, logopt)

Setter for Color attribute.
Parameters:
Name Type Attributes Default Description
color Color the new color
log boolean <optional>
false whether or not to log
Source:

setContrast(contrast, logopt)

Setter for Contrast attribute.
Parameters:
Name Type Attributes Default Description
contrast number the new contrast (must be between 0 and 1)
log boolean <optional>
false whether or not to log
Source: