Giter VIP home page Giter VIP logo

lunasdk's People

Contributors

jx-master avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

lunasdk's Issues

Please add WebGPU support to RHI.

Thanks for your great work!
WebGPU is similar to Vulkan and is also a very modern API.
I wonder if you are interested in adding WebGPU support and enabling the project to be compiled and run on the web.

Support xmake package (xmake-repo) for LunaSDK

In xmake, third-party packages are imported by add_requires and add_package, we need to let LunaSDK users integrate LunaSDK using similar methods:
add_requires("lunasdk")
then
add_package("lunasdk") in target scope.

Add WebAssembly porting

We are considering the possibilities of introducing WebAssembly as the deploying target for LunaSDK. WebAssembly is a platform-agnostic binary standard that enables web browsers to run native codes like C++ in a high-efficient way. To port LunaSDK to WebAssembly, several jobs must be done:

  1. Add wasm32 as the compile target for LunaSDK. Some third-party libraries may not provide wasm32 versions, which will be disabled on WebAssembly target, just like what we will do in iOS/Android platforms.
  2. Write a new OS api implementation layer for WebAssembly using APIs provided by web browsers. Some system-level features may not be supported on WebAssembly.
  3. Add WebGPU as the graphics backend for WebAssembly. WebGL support is not planned.

Note that this is just a draft of what we might do for adding WebAssembly support for LunaSDK. We plan to release WebAssembly porting on v0.9, but this is not a guarantee since technical difficulties are unknown to us for now. We will update our new developing schedule on this issue as we continue to work on it.

Add memory usage profiling APIs.

We need built-in a memory usage profiling tools that will show runtime memory usage for applications. The profiling APIs support three kinds of profiling:

  1. Scope-based profiling: the API behaves like begin_event/end_event for API, and will capture all memory allocations in the call stack between these two functions.
  2. Allocation-based profiling: Mask runtime allocated memory with a specific category, so that the system knows the usage for the memory.
  3. Manual: attach arbitrary memory to the specified category directly. This can also used to track external-allocated memory like video memory. The user should call add_memory/remove_memory manually on allocation and deallocation.

Add indirect draw support to RHI.

The indirect draw feature enables GPU to read from a indirect argument buffer to issue draw and dispatch commands. This is the key feature for implementing GPU-driven rendering and is supported on all modern graphics APIs:

  • Direct3D 12: ID3D12GraphicsCommandList::ExecuteIndirect.
  • Vulkan: vkCmdDrawIndexedIndirect and VkDrawIndirectCommand.
  • Metal: MTLRenderCommandEncoder::executeCommandsInBuffer.

Find a way to add indirect draw support on RHI that works on D3D12, Vulkan and Metal.

Use uniform API to get RHI device feature and limits.

Currently device features and limits are queried using dedicated APIs (like IDevice::check_feature_support, IDevice::get_uniform_buffer_data_alignment, etc. As we are going to add more device feature and limits query APIs, it is better to use a dedicated "check_feature_support" API to handle all kinds of feature queries, so to keep IDevice interface clean.

Add a new example application to test LunaSDK on mobile devices

Currently LunaSDK only has one example application: “Studio”, which is a game editor like application designed for desktop environments only. As we are going to add iOS and Android porting of LunaSDK in v0.9, we need a new example applications that works for all such devices, including PC, mobile devices and web browsers.

BSON support for Variant serialization

BSON is a binary data exchange format that stores JSON data in a binary form, thus being more efficient for storing and transmitting. Since Variant can be serialized from/to JSON, it is feasible to serialize it from/to BSON as well. Adding support for BSON serialization will help applications use a more compact format for storing and transmitting Variant data, which is important for high-performance applications like video games.

Vector graphics module refactoring

The current version of vector graphics module (VG) was written in April, 2022, its APIs are heavily interface-dependent and hard to use from the perspectives of now. Find a more simple and clear way to implement vector graphics API and creates a new demo application (test) for this module.

Use dedicated interface to represent RHI adapter

Currently the RHI adapters present on the platform can only be specified by their indices in the adapter list. As we are adding more adapter feature request APIs to the adapter interface, this method is neither flexible nor efficient. Since all backends LunaSDK supports expose adater interfaces directly (IDXGIAdapter, VkPhysicalDevice and MTLDevice), we can add a new interface to represent the adapter directly.

Add doxygen integration for documentation site.

Currently all docs in lunasdk.org was written by hand. Such workflow is inefficient and hard to maintain as we need to write docs twice (once in source file and another in doc site) and keep them in sync. On the other hand, we already have a lot of code documentations in source file that was written in doxygen format, so we need a pipeline to parse sources files, generate documentations, translate them into markdown files and build them along with existing docs in lunasdk.org.

Add GUI module.

One of the main goals for v0.9 is to add one GUI module for LunaSDK. The GUI module is used to provide graphical user interfaces for all LunaSDK-based applications, it handles user input from graphical user interface and renders user interface using RHI and VG (Vector Graphics) module.

The GUI module applies a mixed-mode GUI model, which takes advantages of immediate-mode GUI and retained-mode GUI, here are some key points:

  1. Immediate-mode API: The only function required for one widget (GUI component) is refresh, which always reconstructs the whole widget from scratch. There is no method to modify one constructed widgets. If one existing child widget is not added in refresh, it will be deleted. This allows easy and straightforward GUI programming just like what we can do in immediate-mode GUI models.
  2. Automatic data transfer: The system manages widget state internally, and moves data from old widgets to new widgets automatically when the widget is refreshed, so that non-transient data (like animation timeline, user-modified widget size, etc.) can be kept between refreshes.
  3. Callback-based input handling: This is the key to distinguish our mixed-mode GUI model from immediate-mode GUI, which usually returns the state of one widget immediately as function return values. In our GUI model, the input handler is registered during widgets refreshing, and will be called at a later time when all widgets are built and properly resized. This allows us to implement multi-pass layouting techniques that are hard to achieve in traditional immediate-mode GUI frameworks.

Add `shader_write_ps` support.

The current version of RHI does not support buffer/texture write operation (unordered access) on pixel shader/fragment shader, which is supported on Direct3D 12 and Metal, and is optionally supported on Vulkan 1.0 (if VkPhysicalDeviceFeatures::fragmentStoresAndAtomics is VK_TRUE). So it can be added to the RHI API without any additional backend requirements.

Add offline shader compiling support

Currently LunaSDK only supports compiling shaders at run time using ShaderCompiler module. However, dxc and spirv-cross is not supported on some platforms (like Android, iOS and armv7 Linux), so we need a offline shader compiling command-line tool that can generate DXIL, SPIR-V and metallib binary shader files in compile time, and package such compiled shader binary into the final application to avoid compiling then at run time.

Add audio abstraction layer.

Current version of LunaSDK lacks audio playback capacity. Find a way to design an audio abstraction layer module that can play audio files using a uniform API on multiple platforms.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.