Method Rgb
- Namespace
- Yeelight
- Assembly
- YeelightClient.dll
Rgb(int, int, int, TimeSpan, int?)
Makes a step that changes the colour.
public static ColorFlowStep Rgb(int red, int green, int blue, TimeSpan duration, int? brightness = null)
Parameters
redintThe red part of the colour, 0 to 255.
greenintThe green part of the colour, 0 to 255.
blueintThe blue part of the colour, 0 to 255.
durationTimeSpanHow long the change takes, at least MinFlowStep.
brightnessint?The brightness to change to, 1 to 100, or
nullto leave it as it is.
Returns
- ColorFlowStep
The step.
Exceptions
- ArgumentOutOfRangeException
An argument is out of the range that the protocol allows.
Rgb(Color, TimeSpan, int?)
Makes a step that changes the colour.
public static ColorFlowStep Rgb(Color color, TimeSpan duration, int? brightness = null)
Parameters
colorColorThe colour. Its alpha is ignored.
durationTimeSpanHow long the change takes, at least MinFlowStep.
brightnessint?The brightness to change to, 1 to 100, or
nullto leave it as it is.
Returns
- ColorFlowStep
The step.
Exceptions
- ArgumentOutOfRangeException
An argument is out of the range that the protocol allows.