December 2014
Intermediate to advanced
512 pages
17h 4m
English
WriteableBitmap, the other BitmapSource subclass, is designed for displaying dynamic pixel content. You construct an instance with a specific width and height, modify its pixels exposed via a PixelBuffer property, and set it as the Source of an Image element.
One common point of confusion is that PixelBuffer is a useless-looking Windows Runtime interface called IBuffer. IBuffer exposes only two properties: Capacity (the maximum number of bytes it can hold) and Length (the number of bytes currently in use).
C++ code can query the object for the IBufferByteAccess COM interface to read/write its data, but this is not an option for an app’s C# code. Instead, you can use the DataReader and DataWriter ...
Read now
Unlock full access