WmpBitmapEncoder Constructor ()

 

Initializes a new instance of the WmpBitmapEncoder class.

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

[SecurityCriticalAttribute]
public WmpBitmapEncoder()

The following example demonstrates how to initialize a WmpBitmapEncoder to encode a new bitmap image.

FileStream stream = new FileStream("new.wdp", FileMode.Create);
WmpBitmapEncoder encoder = new WmpBitmapEncoder();
TextBlock myTextBlock = new TextBlock();
myTextBlock.Text = "Codec Author is: " + encoder.CodecInfo.Author.ToString();
encoder.Frames.Add(BitmapFrame.Create(image));
encoder.Save(stream);

.NET Framework
Available since 3.0
Return to top
Show: