简体   繁体   English

在Mono / C#/ ASP.NET中进行高质量的图像重采样

[英]High quality image re-sampling in Mono/C#/ASP.NET

I've developed a site that requires high quality resizing of uploaded photos. 我开发了一个网站,要求对上传的照片进行高质量调整。 The site works perfectly under ASP.NET on Windows. 该站点可以在Windows的ASP.NET下完美运行。 This afternoon I tried running it under Mono/Apache/Ubuntu 10.10. 今天下午,我尝试在Mono / Apache / Ubuntu 10.10下运行它。 To my surprise, it worked - except for the image resampling. 令我惊讶的是,它有效-除了图像重采样。

It seems the libraries underlying Mono's Graphics/GDI+ implementation don't implement the bi-cubic interpolation mode. 似乎Mono的Graphics / GDI +实现基础的库未实现双三次插值模式。 (See Mono Ignores Graphics.InterpolationMode? ). (请参见Mono忽略Graphics.InterpolationMode? )。

So I'm looking for a library that can do high quality image resizing. 因此,我正在寻找可以进行高质量图像调整大小的库。 I'm willing to put in the effort to interop to it from C# since this is important functionality and I'd like to be able to run under mono if at all possible. 我愿意从C#中互操作,因为这是重要的功能,并且我希望能够在mono之下运行。 I don't really need any other graphics processing capabilities - just resize. 我真的不需要任何其他图形处理功能-只需调整大小即可。

Follow up: as suggested below ImageMagick works really well for this and was pretty easy to interop to. 跟进:如下所示,ImageMagick对此非常有效,并且很容易交互。 More details here: http://www.toptensoftware.com/blog/posts/17/high-quality-image-resampling-in-monolinux 此处有更多详细信息: http : //www.toptensoftware.com/blog/posts/17/high-quality-image-resampling-in-monolinux

ImageMagick既是命令行工具,又是具有高质量插值和抗锯齿算法的库。

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

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