{"id":19998730,"url":"https://github.com/tenry92/libluna","last_synced_at":"2025-10-14T09:34:25.279Z","repository":{"id":249574899,"uuid":"812821403","full_name":"tenry92/libluna","owner":"tenry92","description":"Luna multimedia framework.","archived":false,"fork":false,"pushed_at":"2025-09-26T15:42:12.000Z","size":14142,"stargazers_count":2,"open_issues_count":9,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-14T09:34:24.891Z","etag":null,"topics":["cpp17","cpp17-library","cross-platform","game-development","game-engine","game-framework"],"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/tenry92.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-06-10T00:31:16.000Z","updated_at":"2025-09-26T15:42:15.000Z","dependencies_parsed_at":"2024-07-21T23:48:47.611Z","dependency_job_id":"e32b321a-c899-4606-bc68-3f7f9d1da4b3","html_url":"https://github.com/tenry92/libluna","commit_stats":null,"previous_names":["tenry92/libluna"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tenry92/libluna","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tenry92%2Flibluna","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tenry92%2Flibluna/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tenry92%2Flibluna/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tenry92%2Flibluna/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tenry92","download_url":"https://codeload.github.com/tenry92/libluna/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tenry92%2Flibluna/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279018626,"owners_count":26086404,"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-10-14T02:00:06.444Z","response_time":60,"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":["cpp17","cpp17-library","cross-platform","game-development","game-engine","game-framework"],"created_at":"2024-11-13T05:09:20.932Z","updated_at":"2025-10-14T09:34:25.274Z","avatar_url":"https://github.com/tenry92.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"**libluna** is a multimedia framework designed to make video games\ncross-platform for modern and retro platforms.\nIt's in a very early stage and not meant for real usage yet.\nThe API is currently very unstable.\n\nUnlike a real game engine or framework, libluna is designed to only provide\nthe basic multimedia functionality such as drawing 2D and 3D stuff, playing\naudio and receiving input. libluna does not provide any functionality for\nloading specific file formats, handling game objects, physics, etc.\n\nThis framework is currently being implemented for Windows, Linux and the\nNintendo 64 (using [libdragon](https://github.com/DragonMinded/libdragon)).\n\n## Getting started\n\nA very basic program based on libluna looks like this:\n\n```cpp\n#include \u003clibluna/Application.hpp\u003e\n\nclass GameApp : public Luna::Application {\n  public:\n  using Application::Application;\n\n  protected:\n  void init() override final {\n    // Create a canvas.\n    // On desktop, this simply creates a window with the desired dimensions.\n    mCanvas = this-\u003emakeCanvas({800, 600});\n\n    // Choose default video driver (can be changed via command line).\n    mCanvas-\u003esetVideoDriver(this-\u003egetDefaultVideoDriver());\n\n    // The stage is where all the sprites and models will be.\n    // The same stage can be displayed on different canvases.\n    // Tell the canvas to use the given stage for rendering.\n    mCanvas-\u003esetStage(\u0026mStage);\n  }\n\n  void update(float deltaTime) override final {\n    // Perform game logic update here\n  }\n\n  private:\n  Luna::Canvas* mCanvas;\n  Luna::Stage mStage;\n};\n\nint main(int argc, char** argv) {\n  GameApp app(argc, argv);\n\n  return app.run();\n}\n```\n\n## Building\n\nIn order to compile the library, make sure the following dependencies are\ninstalled on your machine:\n\n- a C++ compiler (e.g. g++, clang, MSVC)\n- CMake\n- libglm\n- libsdl2\n\nFor installing the library dependencies, you may run\n`scripts/install-dependencies.sh` (Linux) or `scripts/install-dependencies.ps1`\n(Windows). On Windows, the script will install Chocolatey, git and vcpkg and\ninstall the libraries via vcpkg.\n\nOn Linux, you may also use the provided Dockerfile to have an isolated and ready\ndevelopment environment:\n\n```sh\n$ docker build -t cpp-cmake-env .\n$ docker run -it --rm cpp-cmake-env\n```\n\nIn order to increase the build speed, you can enable parallel builds for CMake\nby running the following command first:\n\n```sh\nexport CMAKE_BUILD_PARALLEL_LEVEL=4\n```\n\nTo find out the optimal number, check the number of logical cores your computer\nhas:\n\n```sh\n# linux\nnproc\n\n# windows\nwmic cpu get NumberOfLogicalProcessors\n\n# macos\nsysctl -n hw.logicalcpu\n```\n\nWhen everything is ready, use the following commands to configure the build:\n\n```sh\nmkdir build \u0026\u0026 cd $_\ncmake -DCMAKE_BUILD_TYPE=Release ..\n```\n\nWhen using vcpkg (on Windows), make sure to also add\n`-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake`.\n\nIf you want to cross-compile using devkitpro, use the following CMake command:\n\n```sh\nexport DEVKITPRO=/opt/devkitpro\ncmake -DCMAKE_TOOLCHAIN_FILE=/opt/devkitpro/cmake/Switch.cmake ..\n```\n\nReplace `Switch.cmake` according to your target platform.\n\nNext you can build the library, internal dependencies and tools using:\n\n```sh\ncmake --build . --config Release\n```\n\n## Generating documentation\n\nThere are two types of documentation.\n\n### In-depth documentation (sphinx)\n\nThis documentation is generated using sphinx. Use the following commands to\ngenerate the documentation:\n\n```sh\ncd docs/sphinx\n./build.sh\n```\n\nThis will use Docker for preparing an image and executing sphinx.\n\nIf you want to generate the documentation without Docker, ensure that sphinx is\ninstalled on your machine and run:\n\n```sh\ncd docs/sphinx\nmake html\n```\n\nThe generated documentation is located at **docs/sphinx/build/html**.\n\n### API documentation (Doxygen)\n\nThis documentation is generated from the actual source code using Doxygen.\nJust run `doxygen` from the root directory and it will generate the\ndocumentation at **docs/doxygen/html**.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftenry92%2Flibluna","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftenry92%2Flibluna","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftenry92%2Flibluna/lists"}