/MoxieEngine

D3D12 Render Engine

Primary LanguageC++MIT LicenseMIT

Moxie Engine

Direct3D 12 multithreaded render engine.

License: MIT

Example application built with Moxie: showing usage of cubemaps, 2d textures, dynamic buffers and world entities.

Moxie Logo App

Features

Direct3D 12 Renderer

D3D12CommandQueue class is used to execute D3D12CommandList objects.

The D3D12GraphicsAllocator class handles allocation for for

The engine takes care of operating all the required resource transitions and an optional debug layer ensures that rendering is setup as intended.

Multithreaded On CPU

The Application class synchronises updates between the Simulation thread and the Render thread.

Visible entities are each represented by a RenderProxy object owned by the render thread.

Abstraction Layer

The whole engine code is abstracted so that it can support multiple rendering APIs and platforms underneath. Examples are the GraphicsAllocator class, the Window and all the GraphicsTypes.

The engine currently runs with Direct3D 12 on Windows, but it can potentially be extended to operate in environments such as Vulkan on Linux.

Render Passes

Rendering is organised in self-registering render passes, deriving from RenderPass.

Concrete example is the BasePass which is currently rendering all the geometry.

Each render pass answers to different shader parameters read from Drawable objects.

CMake Project Structure

The entire project is configured with CMake files and it is composed of:

Misc

Applications built with Moxie can use delegate objects to answer events, for example mouse and keyboard events from the window class, like done in the textures example.

DDS file format for cubemap and 2D textures loading is supported through D3D12ResourceLoader which internally relies on the dependency from DirectXTex library.

Disclaimer

All the code is given without guarantees and under MIT license.

Textures by Solar System Scope: https://www.solarsystemscope.com/textures/.