NVIDIA GameWorks Integration

I was wondering: NvFlow is based on some low order approximation of Navier/Stokes flow solving ?

In which file can i look into for the main math computation?

Is the future of NvFlow some neural network based solution? ^^

I also have a 4.16.2 build working so I’m pulling yours down to compare. I’ve looked at a few key files and we seem to have patched the RHI code in much the same way so that’s gives me hope I wasn’t to far off the mark. Still stuck with those few depreciated function calls in D3D11NvRHI.cpp applyState. I’ll be interested to see if I’ve missed anything big that you haven’t.

I have my version packaging and building for distribution, mostly came down to the new approach to headers and including the x86 libs/dlls for the distribution build. I’ve also resolved most of the issues to do with VR support although I’m sure much more can be done in department but it works and with carefully tweaked settings the results are good.

In my content I could never get the result I was after when it came to the skylight and the voxel reflections never matched the screen space reflections. I tried all sorts of hacky solutions, messing around with the vxgi voxel shader and reflection shader to try and occlude the skylights influence and got mixed results. In the end I realised I was being an idiot and patched the skylight texture into the vxgi diffuse and spec environment maps and stopped all other forms of skylight influence except the reflection sample. I also put some constants in to adjust the results from the vxgi specular reflection buffer (I’m not happy with these but they seem to work on a superficial level).

is a shot from our dirt simple VR test map.

@Joti
VXGI Specular really cost a lot of performance and only fit some specific kind of reflections, i wonder which kind of performance you achieve in VR ^^.
I usually only use the diffuse and some 75+quality screen-space reflection.

At the time i did the VXGI port to 4.16 (in pre-release, might have been back in March, i don’t remember) i tried to implement as much as possible the new Graphic Pipeline Interface as i wasn’t sure the actual released 4.16 would still support legacy pipeline. I built on top of what i did on march when i made new 4.16.2 version the other day, just had to update 2 function definitions.

If you can package i would love check what i’ve missed ^^.
Your render looks great!

Try adding collision shapes to those other meshes. At the moment, the Flow integration finds emitters using collision shapes. A simple box collision shape will work.

I’m sure it’s navier stokes type stuff. The visual results and a lot of the parameters are too similar to other systems I’ve seen, usually based on navier-stokes simulation techniques and making use of 3d textures and compute shaders, for me to assume anything else. The main difference with flow is the ā€˜adaptive sparse voxel grid’ stuff that allows the simulation cell grid to expand on demand without totally destroying performance. Perhaps I describe wrongly and its better to think of it as not needing to run lots of unnecessary math on cells within the overall grid that dont actually contain anything useful at that frame of simulation. (since there is still an overall grid that means the simulation work only within limited bounds, albeit grid is now moveable)

As for which file to look in, as best I’m aware stuff is not open-source, so we dont get to see inside the flow ā€˜black box’.

Hey all, I’m new to the VXGI branch of UE4. Been curious about it for some client work that needs to push the visual quality on a quick turnaround since I don’t want to deal with lightmaps and lightmass.

Question: does the VXGI build support SLI? Clients have no issues spending money on an SLI system if it means their projects look good.

Is it safe to target 45 FPS with VXGI and use Async Reprojection to get them to 90FPS in Steam VR for a strictly architectural rendering with no actual ā€œgameplayā€?

I was hoping to outfit systems with a 1080ti to run the renderings, and go SLI if I REALLY have to.

Curious to know if it would even work. Thanks!

A.

Also side note: does VXGI work with the forward renderer? Thanks!

Following on from my previous reply, if you are still interested in whats going on despite not having access to the code that makes it happen, you could do a lot worse than look at stuff from a couple of years ago. I dont know how much Dunn was actually involved with flow, or to what extent the actual implementation varies from the detail he gave in 2015, but at the very least its clearly a strong inspiration for flow with a large overlap in terms of theory.

://on-demand.gputechconf/siggraph/2015/video/SIG506–Dunn.html

://developer.download.nvidia/assets/events/GDC15/Dunn_Alex_SparseFluidSimulation.pdf

Thanks for all those precious information !

Well you got me started on a subject close to my heart - I’ve been obsessed with such simulations for years, albeit flow is the only one I know that has taken leap towards trying to be performant enough that sort of simulation actually gets used in some more games.

Most of what I’ve said and linked to in recent posts covers aspects of the computational & memory performance stuff that the likes of Flow bring to the table. For more information about the actual simulation steps, minus the efficiency stuff, there are various resources around on the net and have been for quite a number of years now. Since is a UE4 forum I should probably try to come up with an example that runs in engine and that you can actually look at the guts of. Happily I can actually do that year, albeit with something that gives very pretty results but not even designed with the idea of running the simulation at the sort of framerates we’d want in a game (he envisages baking the results in flipbook form). Great for understanding the simulation technique though if you are familiar with UE4 material node graph stuff:

https://forums.unrealengine/showthread.php?143821-Realtime-Simulation-and-Volume-Modelling-Experiments-Livestream-Plugin-Content

Without the performance-enhancing techniques discussed earlier, it is still possible to get a simulation you can use with the desired framerates, the thing I just linked to is not representative of how quite fast things can be done using compute shaders and the old non-adapting grid stuff. But all the limitations of the older, simpler approach are covered in the talk I linked to anyway and I dont have a more performant example for UE4, so thats enough of my rambling for now!

Brucks work is always a pleasure to look at, learning a lot about Unreal Engine thanks to his work. It’s rather funny because while i come from a Math higher education background i’m still figuring out how it ends up in such wonderful 3D work.
The most advanced stuff i’ve done outside of UE4 regarding 3D is coding a GPU CUDA-based renderer+raytracer using Monte-Carlo. I assume the Nvflow solving is along those lines.

No forward rendering support yet and it would be hard to implement it with the current SDK. Maybe a hybrid render that created the buffer VXGI requires and applied it in post could work and would be cheaper than full differed rendering.

No SLI support yet but also possible.

The best you can do at point is one 1080ti which is only just enough.

Sorry been a bit distracted. Yeah spec reflection is about twice as expensive as diffuse, i’m maxing out a 1080ti to get VR performance although the simple scene does work on a stock 980. I’m getting a little over 18ms per frame with my simple scene and good chunk of that is convolution bloom which I like too much to turn off. Without out it I get my 90fps, just.

I see you patched the directx12 rhi code, I haven’t tested it yet I read a post a while back saying was actually slower with VXGI is that still true? I had missed a few modernisation’s in some of the function parameter definitions and we had some different assumptions in the Graphic Pipeline Interface conversions but mostly on the same page. My version also has a working version of cone tracing material node for reflections on transparent materials. I’ve made a hybrid version in my branch and done a bit of testing and tweaking of some the reflection changes I had made. When I’m happy I’ve not done anything two silly and I get a moment I’ll commit a bunch of features and fixes to your branch if your cool with it.

just a tweaked up version of the lake house content. I can run it in VR at 45fps on the 1080ti.

Looks fantastic, please feel free to commit any update on my VXGI branch. Not sure if you’ve seen bit too, but i’ve added a Tesselation fix in the VXGI shaders for a that got broken last summer.

I’ve not tried the part, but indeed as far as i remember i updated it. For the new Graphic Pipeline interface, it’s just been a whole lot of trial and error, a lot.

yeah same . I suspect the rhi integration could do with a rewrite but that would require a clearer understanding of the systems than I have at point. Messing around with sort of code certainly helps though. I’d also like to redo the voxelization rendering to have it’s own veiw so that it could collect lower level LODs or proxy meshes and be isolated from the vertex buffers of the main views. Although I’m not sure I’m understanding how that works properly yet either.

With SLI there a bunch of approaches that could work:

  1. Card per eye - Need to voxelize on both cards but only a half frame sync after render and minimal frag fills per card.
  2. Interleaved Frames - Full frame sync but no extra voxelization cost.
  3. Dedicated Voxelization card - Not sure how much the voxel data structure would cost to sync but would potentially be mixable with a standard SLI setup for VR rendering and perhaps allow for higher quality voxel processing.

The next step for me is to put VRWorks back in to get the SLI fundamentals and the improved frame clipping as well. I say back in because I had them together in a 4.13 version I had awhile back. Any reduction in frag fills is essential.

" 4.16.2 (no packaging): VXGI - "

Any reason why the link isn’t working anymore? I’d love to test things out :)!

Works fine for me. Are you logged in and registerred with UnrealEngine?

Hi , I tried out your latest Gameworks 4.16.2 build, but wasn’t able to get it to build in Visual Studio Community 2017. So basically I did-

  1. Download your 4.16.2 zip from github, extracted it and ran the setup command.
  2. Next I ran generateprojectfiles command and then installed Visual Studio Community 2017. I ticked for Unreal Engine 4 during installation of modules.
  3. Next I ran the UE4.sln from the files, and per documentation I built it but got a bunch of errors.
  4. When I tried to StartNewInstance it says you need to build the ShaderCompileworker and development editor.
  5. If I hit yes it does a quick build and then gives me error-

://i.imgur/WEmOgtE.jpg

How can I fix ? Thanks

You indeed need your github account to be linked with Unreal and Nvidia to access the repo.