The hue-rotate()
CSS function applies a hue rotation to the input image. Its result is a <filter-function>
.
Syntax
hue-rotate(angle)
Parameters
angle
- The rotation around the color circle by which the input samples will be adjusted, specified as an
<angle>
. A value of0deg
leaves the input unchanged. The lacuna value for interpolation is0
. Though there is no maximum value, the effects of values above360deg
and below0deg
wrap around.
Examples
hue-rotate(-90deg) /* Same as 270deg rotation */ hue-rotate(0deg) /* No effect */ hue-rotate(90deg) /* 90deg rotation */ hue-rotate(.5turn) /* 180deg rotation */ hue-rotate(405deg) /* Same as 45deg rotation */