ColorConvertedBitmap.SourceColorContext Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets or sets a value that identifies the color profile of the source bitmap.

Namespace:   System.Windows.Media.Imaging
Assembly:  PresentationCore (in PresentationCore.dll)

Public Property SourceColorContext As ColorContext

Property Value

Type: System.Windows.Media.ColorContext

An instance of ColorContext.

When you make property changes to a ColorConvertedBitmap, the changes must be done within a BeginInit and EndInit block.

Identifier field

SourceColorContextProperty

Metadata properties set to true

None

The following example shows how to set the value of the SourceColorContext property.

Dim myColorConvertedBitmap As New ColorConvertedBitmap()
myColorConvertedBitmap.BeginInit()
myColorConvertedBitmap.SourceColorContext = myBitmapSourceFrame2.ColorContexts(0)
myColorConvertedBitmap.Source = myBitmapSource2
myColorConvertedBitmap.DestinationFormat = PixelFormats.Pbgra32
myColorConvertedBitmap.DestinationColorContext = New ColorContext(PixelFormats.Bgra32)
myColorConvertedBitmap.EndInit()

.NET Framework
Available since 3.0
Return to top
Show: