Public Member Functions | |
| Gradient (Color color) | |
| Initializes a gradient with the same color in all four corners. | |
| Gradient (Color tl, Color tr, Color bl, Color br) | |
| Initializes a gradient. | |
| void | SetAlpha (double alpha) |
| Sets the alpha value for all corners. Valid values are 0.0 to 1.0. Values outside this are clamped. | |
| Color | Interpolate (double x, double y) |
| Interpolates the color into the interior of the gradient. Parameters should be in the range 0.0 to 1.0; they are clamped if outside this range. | |
Properties | |
| Color | TopLeft [get, set] |
| Gets or sets the color for the top left. | |
| Color | TopRight [get, set] |
| Gets or sets the color for the top right. | |
| Color | BottomLeft [get, set] |
| Gets or sets the color for the bottom left. | |
| Color | BottomRight [get, set] |
| Gets or sets the color for the bottom right. | |
| Color | AverageColor [get] |
| Calculates the color which is the average of all four colors. | |
| AgateLib.Geometry.Gradient.Gradient | ( | Color | color | ) |
Initializes a gradient with the same color in all four corners.
| color |
Initializes a gradient.
| tl | The top left color. | |
| tr | The top right color. | |
| bl | The bottom left color. | |
| br | The bottom right color. |
| Color AgateLib.Geometry.Gradient.Interpolate | ( | double | x, | |
| double | y | |||
| ) |
Interpolates the color into the interior of the gradient. Parameters should be in the range 0.0 to 1.0; they are clamped if outside this range.
| x | Distance from the left side of the gradient. 0.0 is on the left side, 1.0 is on the right. | |
| y | Distance from the top of the gradient. 0.0 is on the top, 1.0 is on the bottom. |
| void AgateLib.Geometry.Gradient.SetAlpha | ( | double | alpha | ) |
Sets the alpha value for all corners. Valid values are 0.0 to 1.0. Values outside this are clamped.
| alpha |
Color AgateLib.Geometry.Gradient.AverageColor [get] |
Calculates the color which is the average of all four colors.
Color AgateLib.Geometry.Gradient.BottomLeft [get, set] |
Gets or sets the color for the bottom left.
Color AgateLib.Geometry.Gradient.BottomRight [get, set] |
Gets or sets the color for the bottom right.
Color AgateLib.Geometry.Gradient.TopLeft [get, set] |
Gets or sets the color for the top left.
Color AgateLib.Geometry.Gradient.TopRight [get, set] |
Gets or sets the color for the top right.
|
AgateLib Awesome Game and Tool Engine Library |
|