{"id":22733816,"url":"https://github.com/angelogalav/raycastenstein-3d","last_synced_at":"2025-08-14T18:42:23.487Z","repository":{"id":207601207,"uuid":"713848453","full_name":"AngeloGalav/raycastenstein-3d","owner":"AngeloGalav","description":"A \"3D\" renderer in the style of 1992's Wolfenstein 3D, also known as a Raycast renderer. Made in SDL and C++. ","archived":false,"fork":false,"pushed_at":"2024-05-18T13:33:50.000Z","size":135,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-30T02:11:28.849Z","etag":null,"topics":["cpp","graphics","raycasting","renderer","sdl2","wolfenstein-3d"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AngeloGalav.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-11-03T11:10:17.000Z","updated_at":"2024-11-07T02:39:19.000Z","dependencies_parsed_at":"2023-11-16T17:29:33.293Z","dependency_job_id":"a30a4083-e352-4218-80bf-c01e6556fdb4","html_url":"https://github.com/AngeloGalav/raycastenstein-3d","commit_stats":null,"previous_names":["angelogalav/raycastenstein-3d"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/AngeloGalav/raycastenstein-3d","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngeloGalav%2Fraycastenstein-3d","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngeloGalav%2Fraycastenstein-3d/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngeloGalav%2Fraycastenstein-3d/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngeloGalav%2Fraycastenstein-3d/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AngeloGalav","download_url":"https://codeload.github.com/AngeloGalav/raycastenstein-3d/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AngeloGalav%2Fraycastenstein-3d/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270466647,"owners_count":24588791,"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","status":"online","status_checked_at":"2025-08-14T02:00:10.309Z","response_time":75,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cpp","graphics","raycasting","renderer","sdl2","wolfenstein-3d"],"created_at":"2024-12-10T20:16:19.169Z","updated_at":"2025-08-14T18:42:23.409Z","avatar_url":"https://github.com/AngeloGalav.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# raycastenstein-3d\n\nSoftware renderer that functions in a similar way as the renderer used in Wolfenstein 3D from 1992.\nCompatible with both Linux and Windows.\n\n## How to play\n\n- Move the camera using `A` and `D`\n- Move forward and backward using `W` and `S`\n\n## Screenshots\n\n![](res/screenshot2.png)\n![](res/screenshot.png)\n\n## Compilation\n\n#### Linux\n\nTo compile the project, simply use the provided `CMakeLists.txt` by typing the following commands:\n```\nmkdir build\ncd build\ncmake .. \u0026\u0026 make\n./raycast-engine\n```\n\n#### Windows\n\nProvided that you've installed the `SDL2` and `SDL2_image` libraries properly, you can build the executable by using this commands:\n```\nmkdir build\ncd build\ncmake .. -G \"MinGW Makefiles\"; make -j8\n./raycast-engine\n```\n\n### Texture-less version\nTo compile the version of this project that does not use textures, simply define the flag `-DNO_TEXTURES=1` when generating the Makefile using CMake.\n\n\n## How it works\n\nThe rendering side of this program is rather simple.\nYou simply draw the world column by column (where each column is a vertical line on the framebuffer).\nEach column of the framebuffer corresponds to a ray that goes from the camera to the object. When an object has been hit (i.e. a wall), the corresponding column is rendered using the color of the object.\n\nThe size of the column depends on the distance between the player and the object, rather than the distance traveled by the ray from the center of the camera, otherwise we would get the so called \"fisheye effect\".\n\nTo detect when a wall has been hit, we make use of an algorithm called **DDA** (Digital Differential Analyzer). This allows the ray to travel very fast on the map, without needing to use a fixed step size that would either miss walls or take too many steps to hit a wall (thus resulting in a performance hit).\n\nA more thorough explanation can be found [here](https://lodev.org/cgtutor/raycasting.html).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangelogalav%2Fraycastenstein-3d","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fangelogalav%2Fraycastenstein-3d","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangelogalav%2Fraycastenstein-3d/lists"}