JX-Master / LunaSDK

Luna SDK is a C++ software development framework for real-time rendering applications.
Other
124 stars 8 forks source link

This is an experimental project and is in actively development. The APIs, implementations and docs may subject to rapid changes. Please don't use this project in production environments.

Luna SDK

Luna SDK LOGO

Luna SDK is a C++ software development framework for real-time rendering applications like video games, interactive multimedia programs, data visualization programs and so on.

Specifications:

Designed target platforms:

Building

windows-build macos-build

Prerequisites

Visual Studio

  1. Clone or download this project.

  2. Double click setup.bat to perform project setup.

  3. Double click gen_vs2019.bat or execute the following commands:

    xmake project -y -k vsxmake2019 -m "debug;profile;release" Solution

    if you user other Visual Studio versions, change vsxmake2019 to your version, like vsxmake2021.

  4. Open solution file in /Solution/vsxmake2019/Luna.sln

  5. Build solution in Visual Studio.

Visual Studio Code

  1. Clone or download this project.
  2. Run setup.bat (on Windows) or setup.sh (on macOS) to perform project setup.
  3. Open Code editor on the project root directory, then choose xmake toolchain in Code editor.
  4. Configure the building option by executing xmake f {options}. Possible options include:
    1. -p for target platform, including windows and macosx. This can be set automatically for most of the time.
    2. -a for architecture, including x64 and arm64.
    3. -m for mode, including debug, profileand release.
    4. --rhi_debug=y if you want to enable the debug layer of the rendering backend (D3D12 debug layer or Vulkan validation layer).
    5. --rhi_api=XXX for choosing the rendering backend, including D3D12 (default on Windows), Vulkan (default on Linux) and Metal (default on macOS).
  5. Open terminal and execute xmake build for all projects, or xmake build {target} for a specific target, like Studio. You may also use Run and Debug tab to build project if you install the XMake extension.

XCode

  1. Clone or download this project.
  2. Run setup.sh to perform project setup.
  3. Run gen_xcode.sh on terminal:
    chmod +x ./gen_xcode.sh
    ./gen_xcode.sh
  4. Since the current version of xmake does not support running custom post-build scripts in XCode, you may need to copy images, shaders and other files to build/macosx/{arch}/release/Debug directory if the program fails to find them.
  5. Open Luna.xcodeproj on the root directory of Luna SDK.
  6. Build products in XCode.

System Requirements

The following requirements must be satisfied to run Luna SDK with Direct3D 12 rendering backend:

The following requirements must be satisfied to run Luna SDK with Vulkan rendering backend:

The following requirements must be satisfied to run Luna SDK with Metal rendering backend:

Docs

See Luna SDK Docs.

Feedback & Discussion

Contact Author

Third Party SDKs and References

Luna SDK uses the following third party SDKs:

  1. Dear ImGui for GUI rendering (MIT License).
  2. ImGuizmo for rendering gizmos using ImGui (MIT License).
  3. DirectX Shader Compiler for compiling HLSL shaders (University of Illinois Open Source License).
  4. GLFW for window management on Windows, macOS and Linux (zlib License).
  5. STB for image file reading/writing and ttf font file processing (public domain).
  6. Vulkan Memory Allocator for allocating device memory on Vulkan backend (MIT License).
  7. D3D12 Memory Allocator for allocating device memory on D3D12 backend (MIT License).
  8. miniaudio for cross-platform low-level platform audio interface (public domain).

All SDKs are either embedded in the project, or can be fetched automatically by xmake scripts, the user does not need to install them manually.

The following SDKs are not directly used Luna SDK, but part of their design and implementation is referred when developing similar functionalities in Luna SDK:

  1. jsondiffpatch.net when developing the variant differential library (MIT License).
  2. DirectXMath when developing the math library (MIT License).

Alternatives

Here are some alternative real-time rendering engines/frameworks that have similar design goals to Luna SDK.

License

Luna SDK is licensed under the zlib/libpng license, see LICENSE.txt for more information.

Mascot

Say Hi to our mascot, a Luna SDK LOGO with two ellipses that look like eyes of one spherical robot.