Libgdx pixel level collision ditection

Hi, is there a way on libgdx to implement per pixel collision detection? How can i take the pixel color values from a texture? Is there anything online that i did not manage find?

Usually there is no need for pixel perfect collision. It does not map well on different resolutions and perform pretty badly. Also collision results are rubbish because of lack of collision on normal.

Using some approximated collision shape is much more robust, faster and give higher quality collision results. Using box2d and tool like this http://code.google.com/p/box2d-editor/ would make sens.

If you still want do pixel perfect collision use libgdx pixmap class to grab pixels and make bitmask from those and then combine bits to bit vectors(shot/int/long) so you can test many pixels at once by using AND operation.

Hi, thank you for yu responce. I know the problems with the pixel level collision but this project i can not avoid them. I will check pixmap