我正在寻找支持 CMYK 的图形库(JPG 或 TIF)。我必须读取一个大图像文件和一个小图像文件,然后在第一个图像文件上写入第二个图像文件。输出也必须是 CMYK(没有任何 CMYK->RGB 转换)。有吗? (C#/C++/Java 或其他)
(免责声明,我在 Atalasoft 工作)Atalasoft dotImage http://www.atalasoft.com将读取和写入 CMYK 图像以及在 CMYK 空间中执行叠加操作。
您需要执行此操作的代码是:
public void OverlayCMYKOnCMYK(Stream bottomStm, Stream topStm, Point location, Steam outStm)
{
using (AtalaImage bottom = new AtalaImage(bottomStm, null), top = new AtalaImage(topStm, null)) {
// might want to check that both bottom and top have the same PixelFormat
// OverlayCommand will silently do conversions if they don't match.
OverlayCommand overlay = new OverlayCommand(top, location);
overlay.Apply(bottom);
bottom.Save(outStm, new TiffEncoder(), null);
}
}
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)