ColorConvertedBitmap.EndInit ColorConvertedBitmap.EndInit ColorConvertedBitmap.EndInit ColorConvertedBitmap.EndInit Method

Definition

Signals the end of the ColorConvertedBitmap initialization.

public:
 virtual void EndInit();
[System.Security.SecurityCritical]
public void EndInit ();
abstract member EndInit : unit -> unit
override this.EndInit : unit -> unit
Public Sub EndInit ()

Implements

Exceptions

Examples

The following example shows how to use the EndInit method in order to change the properties of a ColorConvertedBitmap.

ColorConvertedBitmap myColorConvertedBitmap = new ColorConvertedBitmap();
myColorConvertedBitmap.BeginInit();
myColorConvertedBitmap.SourceColorContext = myBitmapSourceFrame2.ColorContexts[0];
myColorConvertedBitmap.Source = myBitmapSource2;
myColorConvertedBitmap.DestinationFormat = PixelFormats.Pbgra32;
myColorConvertedBitmap.DestinationColorContext = new ColorContext(PixelFormats.Bgra32);
myColorConvertedBitmap.EndInit();
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()

Remarks

Property initialization must be done between BeginInit and EndInit calls. After the ColorConvertedBitmap has been initialized, property changes are ignored.

Applies to

See also