Skip to content

sumimakito/A-star

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A-star

A* pathfinding algorithm (a.k.a. A* search algorithm) written in C++

This is an widely used pathfinding and searching algorithm; learn more about A* at Wikipedia.

OpenCV is not necessarily required, provided that you have found another way to convert input images into arrays which have the same format used in the example.

Since there might still be some problems in my implementation, so please feel free to give me any advice!

Map samples

Map 50px 1 Map 50px 2 Map 50px 3
Map 50px 1 Map 50px 2 Map 50px 3

Previews

DO NOT use images below as input images, they have been scaled up for better visual effect.

Input Output (Original) Output (Improved, see #1)
Input Output Output
Input Output Output
Input Output Output

Special thanks

Thanks @HjalteBested for pointing out the problem and giving me some useful advice on how to improve the algorithm in the issue #1.

License

Beloved MIT

MIT License

Copyright (c) 2017 Makito Sumi

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

About

A*(A-star) pathfinding algorithm in C++

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published