Thanks for the explanation; I pretty much followed your suggestion (very
simple).
SetICCProfile is something like this:
void PdfImage::SetICCProfile (PdfVecObjects* parent, const PdfName&
alternate, char* profileData, long profileSize(
{
PdfObject* iccObject =
parent->CreateObject((alternate.GetName()).c_str());
PdfStream* iccStream = iccObject->GetStream();
iccStream->Set( profileData, profileSize);
{
Where alternate being passed is "ICCBased":
pImage.SetICCProfile(parent, PdfName("ICCBased"), profileData,
profileSize);
I see that the object is being added however it doesn't seem to take
effect (should a profile be attached to an image file, photoshop for
example would immediately ask whether to use the profile or discard it,
or even when just inquiring the profile it should return the profile
instead of the default)
Any clue?
Thanks
jonathan
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Craig
Ringer
Sent: Wednesday, September 12, 2007 3:02 PM
To: Jonathan Sibony
Cc: [email protected]
Subject: Re: [Podofo-users] ICC Profile support
...
Each PDF document has a single PdfVecObjects instance. You'll need to
take this as an argument to your `SetICCProfile(...)' or whatever
method, since the PdfImage doesn't keep track of its owning document. To
the caller, the interface would thus be something like:
SetICCProfile(PdfVecObjects* parent,
const PdfName& alternate,
const char * psProfileBytes,
long int psProfileLength);
Much of this is probably less than ideal in terms of interface and API.
Just explaining it has helped me get some ideas about how it could
perhaps be made easier to understand through documentation and a few
changes.
--
Craig Ringer
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Podofo-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/podofo-users