大佬教程收集整理的这篇文章主要介绍了使用ASP.NET创建缩略图的最佳方法是什么?,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
这里的“最佳”定义为
>相对容易实施,理解和维护
>结果质量合理的缩略图
性能和高质量的缩略图是次要的。
// Example in C#,should be quite alike in ASP.NET // Assuming filename as the uploaded file using ( Image bigImage = new Bitmap( filename ) ) { // Algorithm simplified for purpose of example. int height = bigImage.Height / 10; int width = bigImage.Width / 10; // Now create a thumbnail using ( Image smallImage = image.GetThumbnailImage( width,height,new Image.GetThumbnailImageAbort(Abort),IntPtr.Zero) ) { smallImage.Save("thumbnail.jpg",ImageFormat.Jpeg); } }
以上是大佬教程为你收集整理的使用ASP.NET创建缩略图的最佳方法是什么?全部内容,希望文章能够帮你解决使用ASP.NET创建缩略图的最佳方法是什么?所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。