The-Forge-Lite is a stripped-down version of The-Forge which just supplies the renderer interface, uses CMake to build and contains the bare minimum of third-party libraries.
The public interfaces also try to reduce the amount of headers needed, but TinySTL is still needed.
The idea is also to keep these changes to a minimum so that it is easy and straightforward to update from ConfettiFX's GitHub.
If you are new to The-Forge, I highly recommend using the official one and not this one, it is fairly specific to my needs. However it might be useful to you if you just wanted the excellent graphics API abstraction and straightforward build process.
From the official The-Forge readme:
The Forge is a cross-platform rendering framework supporting
- PC
- Windows 10
- with DirectX 12 / Vulkan 1.1
- with DirectX Ray Tracing API
- DirectX 11 Fallback Layer for Windows 7 support (not extensively tested)
- Linux Ubuntu 18.04 LTS with Vulkan 1.1 and RTX Ray Tracing API
- Windows 10
- Android Pie with Vulkan 1.1
- macOS / iOS / iPad OS with Metal 2.2
- XBOX One / XBOX One X (only available for accredited developers on request)
- PS4 / PS4 Pro (only available for accredited developers on request)
- Switch (in development) (only available for accredited developers on request)
- Google Stadia (in development) (only available for accredited developers on request)
Particularly, the graphics layer of The Forge supports cross-platform
- Descriptor management
- Multi-threaded and asynchronous resource loading
- Shader reflection
- Multi-threaded command buffer generation
The Forge can be used to provide the rendering layer for custom next-gen game engines. It is also meant to provide building blocks to write your own game engine. It is like a "lego" set that allows you to use pieces to build a game engine quickly. The "lego" High-Level Features supported on all platforms are at the moment:
- Asynchronous Resource loading with a resource loader task system as shown in 10_PixelProjectedReflections
- Lua Scripting System - currently used in 06_Playground to load models and textures and animate the camera
- Animation System based on Ozz Animation System
- Consistent Math Library based on an extended version of Vectormath with NEON intrinsics for mobile platforms
- Extended version of EASTL
- For loading art assets we have a modified and integrated version of Assimp
- Consistent Memory Managament:
- on GPU following Vulkan Memory Allocator
- on CPU Fluid Studios Memory Manager
- Input system with Gestures for Touch devices based on an extended version of gainput
- Fast Entity Component System based on our internally developed ECS
- UI system based on imGui with a dedicated unit test extended for touch input devices
- Audio based on integrating SoLoud
- Various implementations of high-end Graphics Effects as shown in the unit tests below
Please find a link and credits for all open-source packages used at the end of this readme.
Join the Discord channel at https://discord.gg/hJS54bz
Join the channel at https://twitter.com/TheForge_FX?lang=en
Release 1.31 - July 12th - Metal 2.2 | More Android Support | Discord Channel | User Group Meetings | Support for Education
- macOS / iOS - we are now supporting Metal 2.2 on those platforms. The macOS version of the Visibility Buffer now uses primitive_id argument that allows to use indexed geometry similar to the Vulkan and DirectX 12 versions. There is a significant increase in performance and reduction in memory consumption
- Debug labels for buffers and textures now present in frame captures;
- cmdSynchronizeResources for MacOS and iOS;
- Minor fixes in GPU synchronization with memory barriers
- Minor fixes in ArgumentBuffers implementation
Please note that we use the early beta system and XCode versions for development. So there might some instabilities.
Here is a screenshot: Macbook Pro 2017 with Radeon Pro 560 3360x2100 resolution
-
Android - we increased the number of unit tests support. With this release we additionally support on the devices mentioned below:
- 06_MaterialPlayground
- 18_Playback
- 19_Blending
- 20_JoinAttachment
- 21_PartialBlending
- 22_AdditiveBlending
- 23_BakedPhysics
- 24_MultiThread
- 25_Skinning
- 26_Audio
-
Vulkan:
- Updated volk Metaloader for Vulkan to latest
- The Forge supports now as the min spec for the Vulkan SDK 1.1.82.0 and as the max spec is 1.1.101.0
-
Discord: we offer now also support through a discord channel. Sign up here: Join the Discord channel at https://discord.gg/hJS54bz
-
User Group Meetings - there will be a user group meeting during GDC. In case you want to organize a user group meeting in your country / town at any other point in time, we would like to support this. We could send an engineer for a talk.
-
Support for Education - in case your School / College / University uses The Forge for education, we would like to support this as well. We could send an engineer or help create material. So far the following schools use The Forge for teaching:
Breda University of Applied Sciences
Contact:
Jeremiah van Oosten
Monseigneur Hopmansstraat 1
4817 JT Breda
Contact:
Andrew Hogue
Ontario Tech University
SIRC 4th floor
2000 Simcoe St N
Oshawa, ON, L1H 7K4
- Writing Guidelines - For contributions to The Forge we apply the following writing guidelines:
- We limit now all code to C++ 11 by setting the Clang and other compiler flags
- We follow the [Orthodox C++ guidelines] (https://gist.github.com/bkaradzic/2e39896bc7d8c34e042b) minus C++ 14 support (see above)
Release 1.30 - June 28th, 2019 - Ephemeris 2 - New Skydome System | Android Unit Tests | New Entity Component System | SoLoud Audio
- Ephemeris 2: this is a new volumetric skydome system developed for PS4 / XBOX One class of hardware. Click on the image to watch a video:
For Ephemeris and the rest of our commercial custom middleware there is now a new GitHub repository here Custom-Middleware
We also have a skydome system for mobile hardware called Ephemeris 1, that will be released on GitHub later.
- Android: we are supporting now more and more unit tests in Android by improving the run-time support. Here are screenshots:
We added the Samsung S10 Galaxy phone (Qualcomm Adreno 640 Graphics Card (Vulkan 1.1.87)) to the test devices for Android.
-
ENTT: we decided to remove ENTT and replace it with our own ECS system that we use internally for tools. ENTT in debug is too slow for practical usage because it decreases execution speed and increases compile times substantially. It appears that "modern C++ 17" and probably also "modern C++ 14" is not ready for usage in a team environment because it decreases productivity too much. We tried to remove C++ 17 and 14 features to make it run faster but it ended up too much work. We went from more than 200 ms with ENTT to 60 ms with our own ECS running a Debug build on a Intel Core i7-6700T 2.8GHz. In release our own system is in the moment not as fast as ENTT but we will fix that.
-
Audio: we did a first pass on integrating SoLoud for all our platforms. There is a new unit test:
-
Linux: following STEAM, we are switching to the Mesa RADV driver in our test environment for AMD GPUs. For NVIDIA GPUs we are still using the NVIDIA driver.
-
Texture Asset pipeline: we did a first pass on a unified texture asset pipeline. On the app level only the name of the texture needs to be provided and then depending on the underlying platform it will attempt to load the "optimal compressed" texture, which in the moment is either KTX or dds. In the future there will be Google Basis support as well.
- Removed support for various non-optimal texture file formats - png, jpg, tga, hdr, exr
- Add ASTC support for iOS through KTX container
- Add compressed textures for all unit test resources
- Add BC6H signed and unsigned float variants
Please make sure you download the art asset zip file again with the help of the batch file.
- Issue list:
- issue #109 "Texture updates broken" is fixed now
- NVIDIA GTX 1660 bug: this card with the Vulkan run-time and driver 419.35 became unresponsive, while the DirectX 12 run-time works as expected. Any other NVIDIA GPU works fine ... this looks like a driver bug ...
See the release notes from previous releases in the Release section.
-
Windows 10
-
Drivers
- AMD / NVIDIA / Intel - latest drivers
-
Visual Studio 2017 with Windows SDK / DirectX version 17763.132 (you need to get it via the Visual Studio Intaller) https://developer.microsoft.com/en-us/windows/downloads/sdk-archive
-
The Forge supports now as the min spec for the Vulkan SDK 1.1.82.0 and as the max spec is 1.1.101.0
-
The Forge is currently tested on
- AMD 5x, VEGA GPUs (various)
- NVIDIA GeForce 9x, 10x. 20x GPUs (various)
- Intel Skull Canyon
-
macOS 10.15 Beta (19A487m)
-
Xcode 11.0 beta 2 (11M337n)
-
The Forge is currently tested on the following macOS devices:
- iMac with AMD RADEON 560 (Part No. MNDY2xx/A)
- iMac with AMD RADEON 580 (Part No. MNED2xx/A)
- MacBook Pro 13 inch (MacBookPro13,2)
- Macbook Pro 13 inch (MacbookPro14,2)
In the moment we do not have access to an iMac Pro or Mac Pro. We can test those either with Team Viewer access or by getting them into the office and integrating them into our build system. We will not test any Hackintosh configuration.
-
iOS 13 beta
-
XCode: see macOS
To run the unit tests, The Forge requires an iOS device with an A9 or higher CPU (see GPU Processors or see iOS_Family in this table iOS_GPUFamily3_v3). This is required to support the hardware tessellation unit test and the ExecuteIndirect unit test (requires indirect buffer support). The Visibility Buffer doesn't run on current iOS devices because the texture argument buffer on those devices is limited to 31 (see Metal Feature Set Table and look for the entry "Maximum number of entries in the texture argument table, per graphics or compute function") , while on macOS it is 128, which we need for the bindless texture array.
We are currently testing on
- iPhone 7 (Model A1778)
- iPhone Xs Max (Model MT5D2LL/A)
-
iPad OS beta 2
-
XCode: see macOS
We are currently testing on:
- iPad (Model A1893)
-
Ubuntu 18.04 LTS Kernel Version: 4.15.0-20-generic
-
GPU Drivers:
- AMD GPUs: we are testing on the Mesa RADV driver
- NVIDIA GPUs: we are testing with the NVIDIA driver
-
Workspace file is provided for codelite 12.0.6
-
Vulkan SDK Version 1.1.101: download the native Ubuntu Linux package for all the elements of the Vulkan SDK LunarG Vulkan SDK Packages for Ubuntu 16.04 and 18.04
-
The Forge is currently tested on Ubuntu with the following GPUs:
- AMD RADEON RX 480
- AMD RADEON VEGA 56
- NVIDIA GeForce 2070 RTX
-
Android Phone with Android Pie (9.x) for Vulkan 1.1 support
-
Android Studio with API level 28
-
We are currently testing on
- Samsung S10 Galaxy (Qualcomm Adreno 640 Graphics Cardv(Vulkan 1.1.87)) with Android 9.0. Please note this is the version with the Qualcomm based chipset.
- Essential Phone with Android 9.0 - Build PPR1.181005.034
-
For PC Windows run PRE_BUILD.bat. It will download and unzip the art assets and install the shader builder extension for Visual Studio 2017.
-
For Linux and Mac run PRE_BUILD.command. If its the first time checking out the forge make sure the PRE_BUILD.command has the correct executable flag by running the following command chmod +x PRE_BUILD.command
It will only download and unzip required Art Assets (No plugins/extensions install).
There are the following unit tests in The Forge:
This unit test just shows a simple solar system. It is our "3D game Hello World" setup for cross-platform rendering.
This unit test shows a Julia 4D fractal running in a compute shader. In the future this test will use several compute queues at once.
This unit test shows how to generate a large number of command buffers on all platforms supported by The Forge. This unit test is based on a demo by Intel called Stardust.
This unit test shows the difference in speed between Instanced Rendering, using ExecuteIndirect with CPU update of the indirect argument buffers and using ExecuteIndirect with GPU update of the indirect argument buffers. This unit test is based on the Asteroids example by Intel.
Using ExecuteIndirect with GPU updates for the indirect argument buffers
Using ExecuteIndirect with CPU updates for the indirect argument buffers
This unit test shows the current state of our font rendering library that is based on several open-source libraries.
This unit test shows a range of game related materials:
Hair: Many years ago in 2012 / 2013, we helped AMD and Crystal Dynamics with the development of TressFX for Tomb Raider. We also wrote an article about the implementation in GPU Pro 5 and gave a few joint presentations on conferences like FMX. At the end of last year we revisited TressFX. We took the current code in the GitHub repository, changed it a bit and ported it to The Forge. It now runs on PC with DirectX 12 / Vulkan, macOS and iOS with Metal 2 and on the XBOX One. We also created a few new hair assets so that we can showcase it. Here is a screenshot of our programmer art:
Metal:
Wood:
This unit test showcases the rendering of grass with the help of hardware tessellation.
In the spirit of the shadertoy examples this unit test shows a procedurally generated planet.
This unit test shows various shadow and lighting techniques that can be chosen from a drop down menu. There will be more in the future.
iMac with AMD RADEON 580 (Part No. MNED2xxA) with resolution of 5120x2880:
iPhone 7 iOS 12.1.4 (16D57) with a resolution of 1334x750:
Linux Ubuntu 18.04.1 LTS Vulkan 1.1.92 RADEON 480 Driver 18.30 with a resolution of 1920x1080:
This unit test was build by Kostas Anagnostou @KostasAAA to show how to ray trace shadows without using a ray tracing API like DXR / RTX. It should run on all GPUs (not just NVIDIA RTX GPUs) and the expectation is that it should run comparable with a DXR / RTX based version even on a NVIDIA RTX GPU. That means the users of your game do not have to buy a NVIDIA RTX GPU to enjoy HRT shadows :-)
This unit test shows reflections that are ray traced. It is an implementation of the papers Optimized pixel-projected reflections for planar reflectors and IMPLEMENTATION OF OPTIMIZED PIXEL-PROJECTED REFLECTIONS FOR PLANAR REFLECTORS
This unit test shows a typical VR Multi-GPU configuration. One eye is rendered by one GPU and the other eye by the other one.
This unit test shows how to switch between the Vulkan and DirectX 12 graphics API during run-time.
This unit test shows how the integration of imGui with a wide range of functionality.
This unit test compares various Order-Indpendent Transparency Methods. In the moment it shows:
- Alpha blended transparency
- Weighted blended Order Independent Transparency Morgan McGuire Blog Entry 2014 and Morgan McGuire Blog Entry 2015
- Weighted blended Order Independent Transparency by Volition GDC 2018 Talk
- Adaptive Order Independent Transparency with Raster Order Views paper by Intel, supports DirectX 11, 12 only, and a Primer
- Phenomenological Transparency - Diffusion, Refraction, Shadows by Morgan McGuire
This unit test shows how to use the new wave intrinsics. Supporting Windows with DirectX 12 / Vulkan, Linux with Vulkan and macOS / iOS.
Ray Tracing API unit test, showing how the cross-platfrom Ray Tracing Interface running on Windows, Ubuntu with Vulkan RTX, macOS and iOS
PC Windows 10 RS5, DirectX12, GeForce RTX 2070, Driver version 418.81 1080p:
PC Ubuntu Vulkan RTX, GeForce RTX 2070, Driver Version 418.56 1080p
Mac Mini with Intel Core i5 3GHz cpu with integrated graphics Intel UHD Graphics 630 (Part No. MRTT2RU/A) with resolution 3440x1440:
iPad 6th Generation iOS 12.1.3 (16D39) with a resolution of 2048x1536
This unit test was originally posted on ShaderToy by Inigo Quilez and Sopyer. It shows how a scene is ray marched with shadows, reflections and AO
This unit test shows how to use the high-performance entity component system in The Forge. This unit test is based on a ECS system that we developed internally for tools.
This unit test shows how to playback a clip on a rig.
This unit test shows how to blend multiple clips and play them back on a rig.
This unit test shows how to attach an object to a rig which is being posed by an animation.
This unit test shows how to blend clips having each only effect a certain portion of joints.
This unit test shows how to introduce an additive clip onto another clip and play the result on a rig.
This unit test shows how to use a scene of a physics interaction that has been baked into an animation and play it back on a rig.
This unit test shows how to animate multiple rigs simultaneously while using multi-threading for the animation updates.
This unit test shows how to use skinning with Ozz
We integrated SoLoad. Here is a unit test that allow's you make noise ...
There is an example implementation of the Triangle Visibility Buffer as covered in various conference talks. Here is a blog entry that details the implementation in The Forge.
Below are screenshots and descriptions of some of the tools we integrated.
We integrated the Micro Profiler into our code base.
To enable/disable profiling, go to file ProfileEnableMacro.h line 9 and set it to 0(disabled) or 1(enabled). It's supported on the following platforms:
- Windows
- Linux
- macOS (GPU profiling is disabled)
- iOS (GPU profiling is disabled)
- Android
MicroProfile provides us an easy to use UI and visualization our frame.
How to use it: MicroProfile has different display modes. The most useful one when running inside the application is Timers. We can change the display mode going to Mode and right clicking the one we want.
If we are on Timer, we will be able to right click on the labels. This will enable a graph at the bottom left.
If we wanted to just see some of the groups inside the profile display, go to Groups and select the ones you want.
The other options are self explanatory.
If the user wants to dump the profile to a file, we just need to go to dump, and right click on the amount of frames we want. This generates a html file in the executable folder. Open it with your prefered web browser to have a look.
Dumping is useful, because we will be able to see the profile frame by frame, without it being updated every frame. This will be useful when displaying in Detailed mode.
For any doubt on the use of the MicroProfile, hover Help.
Confetti will prepare releases when all the platforms are stable and running and push them to this GitHub repository. Up until a release, development will happen on internal servers. This is to sync up the console, mobile, macOS and PC versions of the source code.
We would appreciate it if you could send us a link in case your product uses The Forge. Here are the ones we received so far:
The Forge is used to build the StarVR One SDK:
The Forge is used as the rendering framework in Torque 3D:
SWB is an editor for the 2003 game 'Star Wars Galaxies' that can edit terrains, scenes, particles and import/export models via FBX. The editor uses an engine called 'atlas' that will be made open source in the future. It focuses on making efficient use of the new graphics APIs (with help from The-Forge!), ease-of-use and terrain rendering.
For contributions to The Forge we apply the following writing guidelines:
- We limit all code to C++ 11 by setting the Clang and other compiler flags
- We follow the [Orthodox C++ guidelines] (https://gist.github.com/bkaradzic/2e39896bc7d8c34e042b) minus C++ 14 support (see above)
There will be a user group meeting during GDC. In case you want to organize a user group meeting in your country / town at any other point in time, we would like to support this. We could send an engineer for a talk.
In case your School / College / University uses The Forge for education, we would like to support this as well. We could send an engineer or help create material. So far the following schools use The Forge for teaching:
Breda University of Applied Sciences
Contact:
Jeremiah van Oosten
Monseigneur Hopmansstraat 1
4817 JT Breda
Contact:
Andrew Hogue
Ontario Tech University
SIRC 4th floor
2000 Simcoe St N
Oshawa, ON, L1H 7K4
The Forge utilizes the following Open-Source libraries:
- Assimp
- Bullet Physics
- Fontstash
- Vectormath
- Nothings single file libs
- shaderc
- SPIRV_Cross
- TinyEXR
- Vulkan Memory Allocator
- GeometryFX
- WinPixEventRuntime
- Fluid Studios Memory Manager
- volk Metaloader for Vulkan
- gainput
- hlslparser
- imGui
- DirectX Shader Compiler
- Ozz Animation System
- Lua Scripting System
- TressFX
- Micro Profiler
- MTuner
- EASTL
- enkiTS
- SoLoud