Download

Port C++/DirectX 11 Global Illumination project to UE4

Absolute UE4 beginner here so, please, be merciful.

Lately, I have been working on a new GI technique as part of my master thesis. At this moments, I have prepared a very initial prototype of the technique built in C++/DirectX 11, which I would like to port to UE4. However, given my scarce experience with the engine, I’m not sure how to approach this. Here is a list of core features that I need to be able to implement in UE4 in order for the technique to work.

For a certain mesh, I need the Spherical Harmonics coefficients of the Irradiance Map at the mesh’s position. Ideally, it would be great if UE4 had a function like this one http://docs.unity3d.com/400/Documentation/ScriptReference/LightProbes-coefficients.html. In case there is no way to get the SH coefficients directly, I will need to render a dynamic cubemap from the objects point of view and convolve such cubemap. Some instructions on how to do this would be greatly appreciated.

I need a dynamic omni-directional shadowmap (basically a cubic shadowmap, or a dual parabolic one) centered at the mesh’s position. Basically, in deferred shading, I need a way to determine if each pixel (or better the small portion of geometry represented by each pixel) can “see” the (center of the) considered mesh or not. Any ideas how to get such a map?

Still in deferred shading, for each pixel that is visible from the object point of view, i.e. for each pixel that survives the depth test using the previously mentioned shadowmap, a post processing effect needs to be applied. More exactly, the color of each pixel surviving the test is modified adding to it the product of the previously mentioned SH coefficients with some values sampled from a particular cubemap. Details regarding this cubemap are not necessary, just assume it’s any random cubemap. In my C++/DirectX 11 project this last step is done in a single HLSL shader. How can I achieve this in UE4?

So this is basically it. I hope everything is clear, otherwise let me know and I will add further detail or clarify any ambiguous point. I know it’s a rather broad question, but all I need is a few pointer and suggestions to put me on the right track. It’s also important for me to know if you think this is feasible, or if there is a particular part of my C++/DirectX implementation that is hard or impossible to translate into UE4.

Thanks in advance!