How can I work around the thin 'polygon skin'?

Topics: User Forum
Sep 25, 2011 at 1:42 PM

I just learned of the existence of the thin polygon skin around shapes. I want to work around this by shrinking my shapes slightly.

It's a single pixel on my screen, but I'd like a more exact measurement. What is the exact size?

Or, could someone tell me which source file handles this skin, so that I can view its size myself?

Thanks for the help.

  -Derrick Creamer

Sep 26, 2011 at 12:32 PM
Edited Sep 26, 2011 at 12:33 PM

i don't understand what is your porblem or what are you trying to do. :/

plz explain it a little bit more or show a screenshot

 

Edit: wait. do you mean this outlining of debug view? or the outlining of the original render?

Sep 28, 2011 at 5:08 PM

Well, as far as I can tell, Farseer inherits box2d's 'polygon skin', as seen here: http://box2d.org/manual.html#_Toc258082970

This causes a very small gap between polygonal objects(a single pixel on screen), and I'd like to eliminate that gap by shrinking the size of my objects (while keeping their visual representations the same).

My problem is that I don't know the exact size of the polygon skin, and therefore don't know how much I should shrink my objects.

Thanks for the help.

  -Derrick Creamer

Oct 2, 2011 at 6:57 PM

In case it helps, here are the pages I've been referring to:

http://www.box2d.org/forum/viewtopic.php?f=3&t=7344

http://www.box2d.org/forum/viewtopic.php?f=4&t=5903

These pages cite measurements, but I've been unable to confirm these measurements or whether they're the same in Farseer.

It seems I also need to adjust the center of the image, too - otherwise one object will be slightly higher than the other if they're resting on the same surface and one has been turned upside-down.

Thoughts?

 

Thanks again.

  -Derrick Creamer