D3DCOLOR_COLORVALUE

Initializes a color with the supplied red, green, blue, and alpha floating-point values.

#define D3DCOLOR_COLORVALUE(r,g,b,a) \  D3DCOLOR_RGBA((DWORD)((r)*255.f),(DWORD)((g)*255.f),(DWORD)((b)*255.f),(DWORD)((a)*255.f))

Parameters

r
Red component of the color. This value must be a floating-point value in the range 0.0 through 1.0.
g
Green component of the color. This value must be a floating-point value in the range 0.0 through 1.0.
b
Blue component of the color. This value must be a floating-point value in the range 0.0 through 1.0.
a
Alpha component of the color. This value must be a floating-point value in the range 0.0 through 1.0.

Return Values

Returns the D3DCOLOR value that corresponds to the supplied RGBA values.