AI - Removing ghost lines from path tracing before merging to a compound path
Here's the task: I import an image, trace it black and white, and then try to convert the result into a compound path in order to use it easily later on.
Here's the problem: When I combine to a compound path, nothing shows up - either it appears as completely white or completely black. All the vectors forming the object are still there, but the result is blank.
Here's why: When I trace the object, it creates duplicate lines. Each line that appears in the result is actually two lines on top each other - even when ignoring white. In the result, the first set of lines wrap the actual object fill areas. The second set of lines either wraps all the white sections (if not ignoring white), or wraps nothing, and acts as just lines. When converted to a compound path, fill-content is ignored. Since vector shapes in compound paths invert when intersecting, everything fills together, making everything appear one solid black rectangle (or nothing at all if there's another line-vector wrapping the border).
Here's the question: How can this be avoided when tracing? Or, perhaps, how can I remove all the empty lines before combining to a compound path?
Well, I just figured it out - so for those who might wonder, here's an answer.
- Trace the object without ignoring white.
- Use the magic wand tool to select all the white areas.
- Then delete them.
- Then combine to a compound path.
Because all the white areas are gone, they won't become black when combined (since varying fill-style is ignored when combined to a compound path). For more details, read the why in the question.
Although there might be other ways, this works for me.