kaleido3d is a cross-platform graphics library.
Main Feature
Next Generation Graphics Library
- Modern C++ Code
- Modern Graphics Renderer (
Metal
,Vulkan
,Direct3D 12
,OpenGL|ES
)Maya
Digital Content Creation Tools- Task-Oriented, support
multi-thread
rendering- Support Windows, Android, iOS, MacOS & Linux.
Windows | Android | MacOS/iOS | |
---|---|---|---|
CI Status | |||
IDE | VS2015+ | Android Studio 2.2+ | Xcode 8.1+ |
OS Requirements | Win10 | Android 7.+ | MacOS Sierra |
Dependency | ThirdParty/CMake 3.4+ | ThirdParty/NDK r12+/Gradle | ThirdParty/CMake 3.4+ |
- Windows: make.bat
- Mac OS X: ./make_macos.sh
- Android: (./)gradlew build
-
RHI(Render Hardware Interface)
- Vulkan backend ready.
- DirectX 12 backend WIP
- Metal backend WIP
-
Core.Platform
- Windows implementation ready.
- Android RendererView.
- iOS/MacOS WIP.
-
Tools
- HLSL ShaderCompiler (D3DCompiler & GLSLANG)
- Maya exporter.
-
Planned Samples
- Triangle
- Textured Cube
- Compute Shader (WIP)
- Physically Based Shading (Material Model)
- Skinned Skeleton Animation
- Shadow Mapping (Render To Texture, Z-Pass)
- Deferred Shading (Multi-RenderTarget)
- Tile-Based Cluster Lighting (Compute Shading)
- Multi-Thread Rendering
- Multi-GPU/CrossAdapter Rendering
- Cross Shader Language Compiler
- Hand-writing Recognition CNN Sample (GPGPU)
- Include: common definitions & template library
- Source.Core
- Source.RHI: Implementation Include Vulkan, Direct3D 12 And Metal API
- Source.Render
- Source.Tools.ShaderCompiler : cross shader language compiler and translator.
- Source.Tools.MayaDcc : maya plugin for engine assets exportation.
- Source.UnitTest: unit tests of engine modules
- ThirdParty
- rapidJson
- glslang
- spir2cross
- freetype
- DXSDK
Note: This project is under MIT License.
RHIDevices[Global Variable]
RHIQueues[Global]
-- PerThreadCode
rhi::PipelineDesc pipelineDesc = {shaders, raster, depthStencil...};
rhi::IPipelineState pState = device->NewPipelineState(pipelineDesc);
rhi::ICommandContext* gfxCmd = CommandContext::Begin(pDevice, pQueue);
gfxCmd->Begin();
gfxCmd->SetPipelineLayout(m_pl);
rhi::Rect rect{ 0,0, (long)m_Viewport->GetWidth(), (long)m_Viewport->GetHeight() };
gfxCmd->SetRenderTarget(pRT);
gfxCmd->SetScissorRects(1, &rect);
gfxCmd->SetViewport(rhi::ViewportDesc(m_Viewport->GetWidth(), m_Viewport->GetHeight()));
gfxCmd->SetPipelineState(0, m_pPso);
gfxCmd->SetIndexBuffer(m_TriMesh->IBO());
gfxCmd->SetVertexBuffer(0, m_TriMesh->VBO());
gfxCmd->DrawIndexedInstanced(rhi::DrawIndexedInstancedParam(3, 1));
gfxCmd->EndRendering();
gfxCmd->TransitionResourceBarrier(pRT->GetBackBuffer(), rhi::ERS_RenderTarget, rhi::ERS_Present);
gfxCmd->End();
gfxCmd->FlushAndWait();
--
swapChain.Present(pQueue, pImage, pWindow[, semaphore])
If you have any suggestion, please contact me via email .
Please join the gitter chat or QQ Group to discuss on this project. Framework development discussions and thorough bug reports are collected on Issues.