简体   繁体   English

将图像分辨率更改为300 dpi

[英]Change the image resolution to 300 dpi

Is there any way to change the resolution of an image in the Windows Phone 8 ?. 是否有任何方法可以在Windows Phone 8中更改图像的分辨率? Actually i need to change the image dpi to 300 dpi. 实际上,我需要将图像dpi更改为300 dpi。 I actually have that image inside of my application. 实际上,我的应用程序中包含该图像。 In WPF we have the following way. 在WPF中,我们采用以下方式。

Bitmap b=new Bitmap(Image)
b.SetResolution(xxx,yyy)

Is it possible to achieve the same in Windows Phone 8 ? 是否可以在Windows Phone 8中实现相同的目的?

There is an option in the Windows Phone 8 to change the resolution of an image stream through PictureDecoder. Windows Phone 8中有一个选项可以通过PictureDecoder更改图像流的分辨率。 Input should be 输入应为

  1. Stream. 流。
  2. Width and Height for the resolution. 分辨率的宽度和高度。

    PictureDecoder.DecodeJpeg(jpgstream, 1200, 480); PictureDecoder.DecodeJpeg(jpgstream,1200,480);

For more information you can look at the below link. 有关更多信息,请查看以下链接。

http://blogs.msdn.com/b/swick/archive/2011/04/07/image-tips-for-windows-phone-7.aspx http://blogs.msdn.com/b/swick/archive/2011/04/07/image-tips-for-windows-phone-7.aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM