Jump to content
You must now use your email address to sign in [click for more info] ×

Gap between shape and stroke


Recommended Posts

  • Staff

That's to be expected. It is the result of antialiasing two separate entities/objects where the edges overlap (in this case the fill and the stroke). You can overcome this by pixel aligning your objects wherever possible, overlapping the shapes a little to cover the background, or adding a shape of a similar color below them.

Related thread.

Link to comment
Share on other sites

Since the issue is one of the outlines of the Stroke and Fill being anti-aliased and the border of those 2 anti-aliased borders fuzzing out to transparency. A workaround that doesn't entail creating "filler" objects is to set the stroke to align to center and double the stroke width. Tested it and it works fine. 

 

Here's a screen cap of what I'm saying. The cogs on the left have a 6pt stroke aligned to center, the right cog has a 3pt stroke aligned to outside. First, both cogs look identical. Second, on the right cog, you can see how the pink rectangle in the back ground is visible in the artifact-fuzzy-area where the shape and stroke "meet" so that gap is caused by the borders of the stroke and fill not overlapping at all.

 

post-895-0-14046600-1414634120_thumb.png

 

From other postings about anti-aliasing of vectors, this is just the way it works. Albeit, every solution has unintended consequences and what you, Cam, have found is one of them. 

 

A real solution would be some kind of over-print behavior like what print has to prevent (or hide) misalignment of print plates, so when they go "out of register" it's not so ugly with gaps and such. For rasterization of vectors (i.e. turning the shapes, curves and such into pixels) it could be something like extending the border of the fill (which in this case is "behind" the stroke) a pixel or two and the gap should vanish. But that's veering into Feature suggestion.

 

(edit: uploaded a second image to better show the gap, so click on that in the attachment area to see it. It's still hard to see, can't figure out why the forum's reducing images. Downloading the images and viewing them in Preview may work better.)

 

 

post-895-0-93691200-1414635264_thumb.png

Mac OS X Catinlina, 2014 iMac, 3.5 Ghz Intel Core i7, Huion Kamvas Pro 22 Graphic Tablet, 16GB RAM, MacOS10.12 || Magic keyboard w/numeric keypad, wireless trackpad, Kengsington Edge Trackball || Flux Capacitor in a secure location

---

I encourage kids to go ahead and play on my lawn. I mean, how else can I make sure the death-traps work?

Link to comment
Share on other sites

Hi MEB,

 

Thanks for the reply. I remember seeing a similar thread to the one you posted a few days ago and your response makes sense.

 

However, in regards to a single object with a fill and a stroke, I noticed in Illustrator setting a strokes alignment to outer doesn't leave a slight gap. Perhaps Illustrator is doing something behind the scenes to make that happen?

 

As CartoonMike kindly pointed out, a workaround would be centre align the stroke and double it's size. Yay, that'll work! :)

 

Thanks CartoonMike for your examples and for the clever workaround.

Link to comment
Share on other sites

  • 4 years later...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.