Eurecat / astar-gridmap-2d

A* algorithms for 2D gridmaps. The fastest one, until you prove me wrong
Apache License 2.0
57 stars 19 forks source link

support optional image padding #3

Closed chataign closed 5 years ago

chataign commented 5 years ago

most large image have padded data-lines, handle optional padding to avoid unnecessary copies

facontidavide commented 5 years ago

The gridmap is monocromatic. bytes_per_line is ALWAYS equal to width.

I don't see what this changes

facontidavide commented 5 years ago

If you are try to pass RGB images, the code is wrong, by the way

chataign commented 5 years ago

We found the issue when passing large gridmaps to the library. They are grayscale images but still padded, ie. the image has more bytes per line than width. You can reproduce the issue by loading large images using opencv or Qt. In that situation the world data is invalid and path planning fails

facontidavide commented 5 years ago

Ok

chataign commented 5 years ago

Are you OK to merge?