GdipSetLineBlend

 

 

Description

Sets the blend factors and the blend positions of this linear gradient brush to create a custom blend.

Syntax

GpStatus WINGDIPAPI GdipSetLineBlend(

    GpLineGradient *brush,

    GDIPCONST REAL *blend,

    GDIPCONST REAL* positions,

    INT count

);

PowerBASIC Syntax

DECLARE FUNCTION GdipSetLineBlend ( _

    BYVAL brush AS DWORD, _

    BYREF blend AS SINGLE, _

    BYREF positions AS SINGLE, _

    BYVAL count AS LONG _

) AS LONG

Parameters

 

brush

[in] Pointer to the LinearGradientBrush object.

blend

[in] Pointer to an array of real numbers that specify blend factors. Each number in the array specifies a percentage of the ending color and should be in the range from 0.0 through 1.0.

positions

[in] Pointer to an array of real numbers that specify blend positions. Each number in the array indicates a percentage of the distance between the starting boundary and the ending boundary and is in the range from 0.0 through 1.0, where 0.0 indicates the starting boundary of the gradient and 1.0 indicates the ending boundary. There must be at least two positions specified: the first position, which is always 0.0f, and the last position, which is always 1.0f. Otherwise, the behavior is undefined. A blend position between 0.0 and 1.0 indicates a line, parallel to the boundary lines, that is a certain fraction of the distance from the starting boundary to the ending boundary. For example, a blend position of 0.7 indicates the line that is 70 percent of the distance from the starting boundary to the ending boundary. The color is constant on lines that are parallel to the boundary lines.

count

[in] Integer that specifies the number of elements in the blend array. This is the same as the number of elements in the positions array. The blend factor at a given array index corresponds to the blend position at that same array index.

 

Valid HTML 4.01 Transitional