0
我想在.jpg中使用C#在windows phone中转换.gif图像 应用程序。如何将.gif图像转换为使用C#的windows手机中的.Jpg
我想在.jpg中使用C#在windows phone中转换.gif图像 应用程序。如何将.gif图像转换为使用C#的windows手机中的.Jpg
我不认为有任何规定直接使用.gif图像。但一种方法是获取动画的所有关键图像并创建故事板,或者您可以使用第三方工具。
首先使用Httprequest或Webclient下载图像(任何),然后通过以下方式从gif(如果它是gif)转换为jpg或png。
GifDecoder gd = new GifDecoder();
ImageTools.ExtendedImage img = new ImageTools.ExtendedImage();
gd.Decode(img, stream); //stream means image stream
PngEncoder png = new PngEncoder();
png.Encode(img, isoFileStreamdownload); //isoFileStreamdownload means stream, which is used to save image in image file like(image.png))
使用ImageTools.dll,ImageTools.IO.Gif.dll,ImageTools.IO.Png.dll(图像工具)
你可以从CodePlex上的dll文件或者它只是谷歌。