Jump to content
Sign in to follow this  
Cam

Gap between shape and stroke

Recommended Posts

Hi,

 

When setting a strokes alignment to outside, a slight gap appears between the shapes fill and stroke.

 

I'm using the latest beta build.

 

post-1764-0-14766100-1414618767_thumb.png

Share this post


Link to post
Share on other sites

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.

Share this post


Link to post
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


2014 iMac, 3.5 Ghz Intel Core i7, Secondary Samsung SyncMaster B2430 display, 16GB RAM, MacOS10.12 || Magic keyboard w/numeric keypad, wireless trackpad, Kengsington Edge Trackball, Wacom Pro Large tablet || 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?

Share this post


Link to post
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.

Share this post


Link to post
Share on other sites

ugggg - 2018 - still not fixed. The AF statement that it's aliasing can't be that true since using FX for the layer adds stroke properly to inside without gap. Someone's not being honest here.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

These are the Terms of Use you will be asked to agree to if you join the forum. | 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.