I need to resize a BitmapImage to 50x50 before uploading it to my server. How do I do this on Windows Phone 7 with Silverlight C# .NET on the latest SDK 7.5?
Try this
WriteableBitmap wBitmap = new WriteableBitmap(yourBitmapImage);
MemoryStream ms = new MemoryStream();
wBitmap.SaveJpeg(ms, 50, 50, 0, 100);
The stream will contain your resized image
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.