Well, first thing is - if you loaded the BitmapImage
in the first place - then you have access to the source file, so the easiest solution would be to copy the source file. As for the WriteableBitmap
- it's a bit similar to the C# version, but of course slightly more complicated as you start working with COM-like techniques. See if James's answer to my question about getting access to the pixels helps you a bit:
How to get access to WriteableBitmap.PixelBuffer pixels with C++?