RFC: ICC Profiles in PS Output
This is a new try to fix Issue #125 (closed). The showstopper so far was that lcms2 emitted CSA code that would cause a hiccup in some Postscript interpreters, but this got fixed today [1].
The merge request so far consists of two commits: One that reverts a cleanup commit from a year ago and a refurbished version of @ajohnson 's original patch.
@ajohnson: Could you give this another round of testing?
It works, but maybe some general remarks on what could possibly be addressed in the future:
- The cmsHPROFILE ownership is so far handled suboptimally. I guess longterm some shared_ptr solution with a custom deleter would be the way to go.
- One could also think of adding the icc profiles as a procset resource to the ps output in the DSC-sense, very much like fonts are already added to the output. This way one maybe could also use the existing iccColorSpaceCache.