Table of Contents

Method Choose

Namespace
Gamelogic.Colors
Assembly
Gamelogic.Colors.dll

Choose(Gradient, IGenerator<float>)

Creates a color generator which generates colors from a gradient.

public static IGenerator<Color> Choose(this Gradient gradient, IGenerator<float> timeGenerator)

Parameters

gradient Gradient

The gradient from which colors are selected.

timeGenerator IGenerator<float>

The generator that determines where on the gradient the colors are selected. This generator should generate values between 0 and 1.

Returns

IGenerator<Color>

Choose(GradientHSL, IGenerator<float>)

Creates a color generator which generates colors from a HSL gradient.

public static IGenerator<Color> Choose(this GradientHSL gradient, IGenerator<float> timeGenerator)

Parameters

gradient GradientHSL

The gradient from which colors are selected.

timeGenerator IGenerator<float>

The generator that determines where on the gradient the colors are selected. This generator should generate values between 0 and 1.

Returns

IGenerator<Color>