Color.FromAValues(Single, Single[], Uri) 메서드

정의

지정한 알파 채널, 색 채널 값 및 색 프로필을 사용하여 새 Color 구조체를 만듭니다.

public:
 static System::Windows::Media::Color FromAValues(float a, cli::array <float> ^ values, Uri ^ profileUri);
public static System.Windows.Media.Color FromAValues (float a, float[] values, Uri profileUri);
static member FromAValues : single * single[] * Uri -> System.Windows.Media.Color
Public Shared Function FromAValues (a As Single, values As Single(), profileUri As Uri) As Color

매개 변수

a
Single

0에서 1 사이의 값으로 표시되는 새 색의 알파 채널 값입니다.

values
Single[]

새 색의 색 채널을 지정하는 값의 컬렉션입니다. 이들 값은 profileUri에 매핑됩니다.

profileUri
Uri

새 색에 대한 ICC(International Color Consortium) 또는 이미지 색 관리(ICM) 색 프로필입니다.

반환

Color

지정한 값을 가진 Color 구조체입니다.

예제

다음 예제에서는 사용 하는 방법을 보여 줍니다 합니다 FromAValues 메서드를를 Color 구조입니다.

private Color FromAValuesExample()
{
    // Create a brown color using the FromAValues static method.
    Color myAValuesColor = new Color();
    float [] colorValues = new float[4];
    colorValues[0] = 0.0f;
    colorValues[1] = 0.5f;
    colorValues[2] = 0.5f;
    colorValues[3] = 0.5f;

    // Uri to sample color profile. This color profile is used to 
    // determine what the colors the colorValues map to.
    Uri iccUri = new Uri("C:\\sampleColorProfile.icc");

    // The FromAValues method requires an explicit value for alpha
    // (first parameter). The values given by the second parameter are
    // used with the color profile specified by the third parameter to 
    // determine the color.
    myAValuesColor = Color.FromAValues(1.0f, colorValues, iccUri);
    return myAValuesColor;
}
Private Function FromAValuesExample() As Color
    ' Create a brown color using the FromAValues static method.
    Dim myAValuesColor As New Color()
    Dim colorValues(3) As Single
    colorValues(0) = 0.0f
    colorValues(1) = 0.5f
    colorValues(2) = 0.5f
    colorValues(3) = 0.5f

    ' Uri to sample color profile. This color profile is used to 
    ' determine what the colors the colorValues map to.
    Dim iccUri As New Uri("C:\sampleColorProfile.icc")

    ' The FromAValues method requires an explicit value for alpha
    ' (first parameter). The values given by the second parameter are
    ' used with the color profile specified by the third parameter to 
    ' determine the color.
    myAValuesColor = Color.FromAValues(1.0f, colorValues, iccUri)
    Return myAValuesColor
End Function

설명

ICC(International Color Consortium) 또는 ICM(Image Color Management) 색 프로필에는 색 프린터와 같은 특정 응용 프로그램 또는 장치에 대한 색 시스템 프로필이 포함되어 있습니다. 이 프로필은 다시 다른 디바이스의 개별 프로필에 매핑할 수 있는 공용 프로필에 일치 합니다. 이 통해 다른 애플리케이션 및 디바이스를 동일한 또는 다른 컴퓨터 시스템에서 색을 일치 시키는 데 컴퓨터 디바이스 색 시스템입니다.

적용 대상