Page 1 of 1
Locate clipping paths among all paths in 8BIM profile?
Posted: 2008-09-02T04:41:26-07:00
by fredrik@axpa.se
In the documentation it says that -clip uses the first path found in the 8BIM profile.
This is odd since this is not necessarily "the clipping path" as flagged in the profile.
I am not familiar with how Photoshop flags a path as being "the clipping path", but I do know that it does.
This should be the path used by -clip.
Also, the presence of paths in the 8BIM profile is not indication that the image has a clipping path at all.
I regularly get images with 10 or more paths, but no clipping path.
In these cases -clip should do nothing.
I have not been able to read neither names nor ids of paths in the 8BIM profile using IM command-line tools.
Is this possible?
If it is, how do I do it and can I also retrieve the "is clipping path" property for each path?
If it isn't, I would like to formally request this as an enhancement.
Re: Locate clipping paths among all paths in 8BIM profile?
Posted: 2008-09-08T02:09:35-07:00
by fredrik@axpa.se
I am a bit disappointed by the total lack of responses to this.
This is a major issue for us, and should be for anyone using IM to convert images used in print production.
Does anyone know of a separate tool to read the paths in a Photoshop image that could be used as a workaround?
Best regards
Fredrik
Re: Locate clipping paths among all paths in 8BIM profile?
Posted: 2008-09-08T17:43:48-07:00
by anthony
The clip path is a 'profile' abstraction, and NOT directly involved with the given image. That is it is a provided option, not a requirement. that said.... IM does handle it.
Basically it is a SVG path that IM extracts (using -clip) then draws to generate a 'region mask' or -clip-mask for the later operations on the image. That is later operations will only effect the area specified by the clip mask. At least that is my understanding.
Sorry I have not had any practical experience in this, only in what I have seen, read, and made notes of, from other forum discussions. You may like to do a search of the forum for other '-clip' usage notes.
NOTE: you can extract the path from the profile then 'draw' or generate the mask for what ever purpose the clip path was provided for.
And please let us know your findings results and views, here in this topic, so others searching the forum can also see what you find.
Re: Locate clipping paths among all paths in 8BIM profile?
Posted: 2008-09-09T04:49:03-07:00
by fredrik@axpa.se
Thanks for your reply.
My problem is that my images typically don't have "a path".
They have many paths, one of which may be flagged as a clipping path.
Photoshop supports many concurrent paths in the 8BIM profile, but only one of them can be flagged as "clipping path".
However, IM doesn't seem to read the "is clipping path" flag in the 8BIM profile, but instead simply assumes that the first path in the profile is the clipping path, and therefore applies it when -clip is invoked.
This assumption is the problem.
The profile holds information on which paths are in there and which (if any) is the clipping path.
I have not been able to read the list of paths, nor the "is clipping path" flag from the 8BIM profile.
This is really what I need.
Ideally I would like to read in a list of the path names and let a user choose which one to clip with when converting.
Re: Locate clipping paths among all paths in 8BIM profile?
Posted: 2008-09-09T22:59:00-07:00
by anthony
IM is a general image processor. It can not and will not be able to handle all aspects of all image formats or specific special aspects of a specific format.
However you should be able to extract the clipping paths using a external script or with the help of IM's profile extractor (even if it does not understand the contents of that profile), and do things in a more round about way.
As for the 'flagged' clipping path. If you consider this a problem. open a discussion in BUGs with a link to a image that has the problem, what you get and what you expect.