{"id":20851196,"url":"https://github.com/elementbound/gms-dijkstra-gpu","last_synced_at":"2026-03-16T11:33:42.422Z","repository":{"id":34879378,"uuid":"38892865","full_name":"elementbound/gms-dijkstra-gpu","owner":"elementbound","description":"Pathing with GPU, in Game Maker Studio","archived":false,"fork":false,"pushed_at":"2015-07-10T17:41:57.000Z","size":220,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-19T06:13:15.809Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"NSIS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"volatiletech/authboss-sample","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elementbound.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-07-10T17:22:02.000Z","updated_at":"2024-12-31T16:41:40.000Z","dependencies_parsed_at":"2022-09-14T01:00:39.989Z","dependency_job_id":null,"html_url":"https://github.com/elementbound/gms-dijkstra-gpu","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elementbound%2Fgms-dijkstra-gpu","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elementbound%2Fgms-dijkstra-gpu/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elementbound%2Fgms-dijkstra-gpu/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elementbound%2Fgms-dijkstra-gpu/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elementbound","download_url":"https://codeload.github.com/elementbound/gms-dijkstra-gpu/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243222184,"owners_count":20256220,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-18T03:12:47.335Z","updated_at":"2025-12-26T11:52:45.226Z","avatar_url":"https://github.com/elementbound.png","language":"NSIS","readme":"# Dijkstra on GPU\nA simplified proof-of-concept implementation. \n\nA popular approach is to use a grid and feed that to the algorithm as a graph. Grids fit really well into textures, \nand given the algorithm, it is not too difficult to do it in a pixel shader. \n\nEach pixel's distance from the destination is stored in a texture which is fed to the pixel shader. \nThe pixel shader, for each open* pixel, finds the neighboring pixel with the lowest value ( distance from destination ). \nThis search excludes neighbors occupied by walls. \n\nOnce each pixel has its value, navigation is easy. Starting from the source, move to the neighbor with the lowest value. \nWhen a local minimum is reached, it's either at the goal, or at a place where further pathing is not possible \n( i. e. the goal is not reachable from there ). \n\n## Limitations ##\nThe source includes proper functions for packing and unpacking large values to colors. However, for visualisation, only \nthe red channel is used for now. This limits the maximum distance to 254.\n\nCurrently, the shader only works for 4 neighbors. Attempts were made to work with 8 neighbors, no success so far. \nOther possibilities weren't tested yet. It would be cool to do one with 3 neighbors. \n\n## Usage ##\nControls are displayed while running the app, but I'll include them here, too. \n\nOnce started, you can draw walls with the left mouse button. To erase, use the right mouse button.\n\nOnce done, position the mouse over the destination and press Q. The pathing surface will be gradually \nfilled with distances. This will probably be fast, and spectacular. \n\nWhen the filling is done, press W. The app will find a path from the mouse to the destination. \n\nYou can save your map anytime with S. Load with L. Two sample maps are included with \nthe repository - maze.png and walls.png. The maze was generated with GIMP.\n\n## Promises ##\nNone :P This is something I spend a single afternoon with and rarely if ever look back. However, the code could \nuse some obvious improvements, so who knows. *However, you are free to work on it, too.* I'd be glad to be \nnotified if so :) \n\n## License ##\nSee the file named LICENSE. The source is under the MIT license. \n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felementbound%2Fgms-dijkstra-gpu","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felementbound%2Fgms-dijkstra-gpu","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felementbound%2Fgms-dijkstra-gpu/lists"}