سؤال
أبحث عن مكتبة الرسومات مع دعم CMYK (JPG أو TIF). لا بد لي من قراءة ملف صورة كبير واحد وواحد صغير ، ثم اكتب الثانية في البداية. يجب أن يكون الإخراج أيضًا CMYK (بدون أي تحويل CMYK-> RGB). هناك أي؟ (C#/C ++/Java أو شيء آخر)
المحلول
(إخلاء المسئولية ، أعمل في Atalasoft)Atalasoft dotimage سوف تقرأ وكتابة الصور في CMYK وكذلك إجراء عمليات تراكب في CMYK Space.
الرمز الذي ستحتاج إلى القيام بذلك هو:
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);
}
}
لا تنتمي إلى StackOverflow