ID2D1RenderTarget::CreateLinearGradientBrush メソッド

指定されたグラデーション境界が含まれ、指定された変換と基本の不透明度が設定された ID2D1LinearGradientBrush を作成します。

構文

virtual HRESULT CreateLinearGradientBrush(
  [in]            const D2D1_LINEAR_GRADIENT_BRUSH_PROPERTIES *linearGradientBrushProperties,
  [in, optional]  const D2D1_BRUSH_PROPERTIES *brushProperties,
  [in]            ID2D1GradientStopCollection *gradientStopCollection,
  [out]           ID2D1LinearGradientBrush **linearGradientBrush
) = 0;

パラメーター

  • linearGradientBrushProperties [in]
    D2D1_LINEAR_GRADIENT_BRUSH_PROPERTIES グラデーションの始点と終点。
  • brushProperties [in, optional]
    D2D1_BRUSH_PROPERTIES 新しいブラシの変換と基本の不透明度、または NULL。この値が NULL の場合、既定では、ブラシの基本の不透明度が 1.0f、単位行列がその変換として設定されます。
  • gradientStopCollection [in]
    ID2D1GradientStopCollection ブラシのグラデーションの色とグラデーション ラインに沿った色の位置を表す D2D1_GRADIENT_STOP 構造体のコレクション。
  • linearGradientBrush [out]
    ID2D1LinearGradientBrush このメソッドが返されるときに、新しいブラシへのポインターのアドレスが格納されます。このパラメーターは初期化されずに渡されます。

戻り値

HRESULT

メソッドが成功した場合は、S_OK が返されます。 それ以外の場合は、エラー コードが返されます。HRESULT.

要件

クライアントの最小要件

Windows 7, Windows Vista SP2 および Windows Vista 用のプラットフォーム更新プログラム

サーバーの最小要件

Windows Server 2008 R2, Windows Server 2008 SP2 および Windows Server 2008 用のプラットフォーム更新プログラム

ヘッダー

D2d1.h

ライブラリ

D2d1.lib

DLL

D2d1.dll

参照

ID2D1RenderTarget

CreateGradientStopCollection

ID2D1GradientStopCollection

ID2D1LinearGradientBrush

ID2D1RadialGradientBrush

線状グラデーション ブラシを作成する方法

ブラシの概要