Subtracting the stroke outside the rectangle.


i've got stroked rectangle , want stroke inside rectangle show.

 

the bottom layer has stroke on fill. 

 

the top layer duplicate of bottom layer, except fill black, fill on stroke, , layer mode subtract.

 

everything looks perfect, except there thin (one pixel?) line on both right , left side of rectangle (where outside of stroke be).

 

why 2 thin lines there?  have antialiasing?  how ought make work right?

 

is there better way it? 

this work if rectangle number of pixels high , wide , anchor point on whole pixel value. otherwise sub pixel sampling. can mitigate errors changing blend mode alpha add both layers.

 

if suggestion not fix problem need know lot more project. how rectangles created? how stroke created? i'm assuming using shape layers. if correct suggestions should work.



More discussions in After Effects


adobe

Comments

Popular posts from this blog

How to set the order of FAQs instead of alphabetical

Thread: Get UK Keyboard working

how do I change the e-mail address for my merchant account