Hey guys, I’d like to share a project that I’ve been working on the last couple of months, it’s a massive improvement over my previous raymarching plugin that can be found here.
The whole thing can be found on my github and works out of the box (even contains the scan that you can see in the screenshots).
Long story short - it lets you render volumetric data (mostly used for medicinal visualization, but hey, whatever data you got, we will render).
Some screenshots to quickly grab your attention:
On the left you can see the volumetric rendering and on the right is a cut through the original data volume.
Both of these are rendered from the same CT scan, just using a different transfer function.
- Works out of the box with binary UE 4.26
- Volume raymarching for arbitrary UVolumeTexture textures (true 3D textures, no flipbooks).
- .dcm (DICOM), .mhd and .raw file import into volume textures.
- Precomputed Volume illumination with unlimited number of light sources implemented in compute shaders using concepts from Efficient Volume Illumination with Multiple Light Sources through Selective Light Updates (2015) by Sundén and Ropinski, implemented using URenderTargetVolume and compute shaders.
- Uses color curves for transfer function definition
- Fully integrated and functional within UE editor viewport.
- Windowing support (google DICOM Window center / Window Width or watch my youtube description for an explanation of what windowing does)
- Basic menus for manipulating the volume
- Basic VR support and example map
- Raymarched volume doesn’t cast or receive shadows info to/from the scene, it only self-shadows
- We use a very simple (but fast) raymarching and illumination algorithm with no specular, refraction or scattering
- Algorithm is already a bit dated and implementation leaves a lot to be desired as for efficiency. It is however, good enough for real-time applications with several lights and large (512^3 or more) volumes.
- Currently do not support persistent (saveable) 32bit grayscale textures, so saving is limited to G8 or G16
If you want to give it a shot, just clone the repo, generate VS files, compile and play with it in the editor or in play mode. Everything should work out of the box, there is an extensive readme on my github for usage details and I went crazy with commenting my code, so everything should be pretty clear.
For a showcase video where I show off all the things you can do with this, here’s my 40 minute rant about it - new one should be coming soon, as this one is already kind of outdated.
Here’s a discord channel I made for the project:
Any suggestions, criticisms, bug-reports, pull-requests etc. are more than welcome!
Edit: updated info to reflect that DICOM loading is now possible.