NVIDIA GameWorks Merged Branch by

I have created this thread as a way to provide support and updates on my Merged GameWorks branch (I am in no way affiliated with NVIDIA, I manage this branch in my own time). It has been a while since I last gave any kind of update, as I have been out of the loop, so here goes, I have started the merging process for v4.12.5 of the engine.

[shot]http://i.imgur.com/dwzt5I1.jpg[/shot]

Link (4.12.5): https://github.com//UnrealEngine/tree/4.12.5_NVIDIA_Techs
Link (Experimental 4.13 p2): https://github.com//UnrealEngine/tree/4.13_Preview_NVIDIA_Techs

Remember you need to be logged into a valid Github account, and this account needs to be linked to your Epic account. Please refer to the following link on how to do this: Unreal Engine on GitHub - Unreal Engine

Any issues not listed in the below FAQ, please report to this thread and the issues tab of my branch

Link to Issues: https://github.com//UnrealEngine/issues

If you require support for a specific GameWorks tech, you are better off posting in the relevant thread for that tech (at the time of writing, VXGI: NVIDIA VXGI Integration - Community & Industry Discussion - Epic Developer Community Forums and all others: NVIDIA GameWorks Integration - Asset Creation - Epic Developer Community Forums).

Otherwise I will try my best to keep this branch up to date, and help anyone get this branch up and running.

Right now this is just a straight merge, I have not transferred anything over from my previous branch, which means this branch may not be packagable (This all depends on if NVIDIA fixed the issues in their own branches). Below you will find a small roadmap of what I have merged and what is coming next:

VXGI (HBAO+): Merged into 4.12.5; 4.13 p1
FLEX: Merged into 4.12.5; 4.13 p1
HairWorks: Merged into 4.12.5; 4.13 p1
WaveWorks: Merged into 4.12.5
MultiRes: Merged into 4.12.5
Cataclysm: Merged into 4.12.5
Volumetric Lighting: I really want to merge this, but I need help regarding changing the code to be usable with a reverse Z buffer, as well as changing the code to support UE4 shadow mapping
Flow: If and when NVIDIA release a branch, I will ensure this gets merged
Turbulence: Will not merge, has been superseded by Flow

I also am aware of the NVIDIA VR Funhouse (Which apparently was made in UE4, which means they have their own merged branch which they may release at any time). So consider this just a stop gap until if and when NVIDIA release theirs.

Thanks all, and have fun, also feel free to post any pics of work being done using my merged branch in this thread.

Frequently Asked Questions

Q/ The HairWorks apx file failed to import, whats wrong?
A/ The UE4 integration is based on HairWorks v1.2. The plugins are v1.1.1 or v1.1.2. NVIDIA have reported that these will work with v1.2. But you need to ensure that your growth mesh is skinned to a root node (If its unskinned, skinned meshes should work fine), failing to do this will result in an unreadable file.

Q/ I set up a particle system utilising Cataclysm, but no particles are rendering, why?
A/ The Cataclysm demo requires a card capable of Direct3D 11.1 or greater, as well as Windows 10. If you wish to run the demo on a lower OS. You will need to open WindowsD3D11Device.cpp and go to line 97 and change the OS version. Do this at your own risk.

Q/ How to enable MultiRes?
A/ Go into your Project Settings, under rendering, search for MultiRes and tick “MultiRes Rendering” optionally you can tick “Instanced Stereo”. Restart project and wait for shaders to compile. Then in game open the console and type “vr.MultiResRendering 0/1/2/3” to enable/disable MultiRes with more or less aggressive settings. Bare in mind there are limitations especially with other GameWorks techs. See the list below.

MultiRes support for GameWorks techs is as follows:

FLEX - Object and Liquid Rendering works
HairWorks - Not working. Hair gets smaller as the MultiRes gets more aggressive (Not sure about how to fix this one)
WaveWorks - Not working. Only renders to the top left scissor area (Can probably fix)
VXGI - Not working. Voxelization is fine (since it should not be MultiRes’d). Light contribution is broken (Can probably fix)
Cataclysm - Not tested

Gallery

[shot]http://i.imgur.com/3guhbVr.jpg[/shot]
VXGI emissive lighting and translucency rendering

[shot]http://i.imgur.com/pkxXfhO.gif[/shot]
New flex particles component allowing bodies of liquid (simulation saving) and diffuse particles

[shot]http://i.imgur.com/a6GyOUo.gif[/shot]
Flex soft body permanent deformation

Thank You .
Any special instructions for the compile?

I think the only thing is, when you run setup.bat, if your prompted to overwrite any files, make sure to hit ‘N’. Also let me know if it fails to compile, or fails to run. Hopefully I didnt miss any files during the upload. Also you will see some warnings during GenerateProjectFiles, they can be ignored for now, as well as warnings during compilation.

I see they have a branch called CataclysmDemo but I have no idea what it is. Can someone post a link or something to it. Trying to look it up myself just pulled up a lot of results for WOW.

EDIT: Well it seems all I had to do was take a look at the branch. Its a Liquid Solver. Looks pretty darn cool. Adding to the list for merging.

thanx its great what about facework:rolleyes:

Cataclysm looks incredible from that video. I’m curious if it’ll replace FLEX’s fluid solver now, since it would presumably need to run faster to affect an area that large with that many particles.

Out of curiosity, what sort of skills did you need to learn to be able to merge these branches? Even as just an artist, I’m starting to get an interest in programming and all that, and being able to do these sorts of things myself when necessary would be helpful.

Maybe some time in the future, there is no branch for FaceWorks integrated into UE4, so I would have to write the entire integration myself.

They aren’t necessarily issues, they are just different ways of rendering to depth. The volumetric sample demo only supports standard z buffers. UE4 by default uses reversed Z buffer (it can be configured to use standard, but its quite challenging to change). Same goes for the shadow mapping methods, UE4 uses different shadow mapping methods to the sample, and I just don’t have the knowledge to change these things on my own.

Basically I need someone who knows more about math and shaders than I do to help, or someone from NVIDIA.

Mostly just how to use git. When the engine and the integration are on the same version, its very trivial. It becomes much more challenging to upgrade an integration, there you need to understand the engine source so that u can rewrite portions of code to adapt to the new engine. ie. I am in the process of upgrading the WaveWorks integration to 4.12.5 from 4.9.2 and a few things have changed, making it more difficult where as VXGI, FLEX, and HairWorks were seamless.

Are there any good learning resources for Git you happen to know of? Whenever I want to merge two Git branches, I’ve always just been using WinMerge to find the differences in each file and manually copy stuff over in hopes nothing breaks. Not exactly the best option out there.

And out of curiosity, is there any risk in using the merged branch for a long term project (as in a year or longer)? It’ll probably be fine, I’m just worried about what might happen if for any reason you don’t keep up with later engine builds and I end up using a branch that doesn’t have every single tech integrated in the engine. That’s the main reason I’ve stuck to just the VXGI build this entire time.

I’m still no master of git, I tend to break branches more frequently than anything, but I find trial and error to be the best way to learn, just search for the commands that you need, make a new branch and try, if it fails, u can always just delete the branch and try again, most of the time, you just need to merge, then resolve conflicts and your done.

The risk will always be relying on someone else to update, as can be evident with the fact that I didnt update the 4.9.2 branch (Due to personal reasons). I will always strive to keep up to date with the latest engine updates, but I too have my own projects and things happening in RL that might conflict, so its up to you wether or not its worth the risk. However I am generally available on Skype to work out some one on one time to do special integration work for certain projects, I have done this in the past, such as integrating FLEX and WaveWorks into 4.10, etc.

I have merged Cataclysm, but I was unable to get anywhere close to the same results as the youtube video, coz I have no idea how to setup the particle system, everything I tried resulted in particles having incredibly short lifespans, and the more I increased the particle count, the less particles there were. I have reached out to the main dev of the Cataclysm branch to see if he will send me the test project, until then, I can say its in, but can’t really say if its working correctly.

Also the cataclysm branch came with some improved super sampling code, so I have included that as well.

this is amazing… really awesome work! I was curious though if you might be able to ALSO merge the VRworks too for 4.12? VRworks is incredible… it’s provided a 45% frame rate for us when using with the HTC Vive… insanely useful tech with a massive impact. I’m not sure if the FLEX/Hair-newly-recompiled multi-res materials will work or look right… but it would be worth playing with. Anyway, let me know if you might be able to merge it…it would be really helpful. Great job with everything and thanks so much for your contributions!!!

I don’t see a VRWorks branch, so if I do end up integrating it, it will be further down the path when I have more time, as I will have to write the entire integration myself. Unless I’m missing something (Its not the multires branch is it?)

i have 4.12.5 vxgi working project but i m open inr your intig. flat tasslation not work with vertex normal ws . i change to pn tass this work ok any idea?

You might have to explain the setup some more. I just tested world space normals with flat tessellation, and had no issues. So show the material setup and the level setup so I can see what ur doing.

Error [SM5] FlatTessellation.usf(140,32): error X3004: undeclared identifier ‘VertexFactoryWaveWorksInterpolate’ in your ue but i have vxgi 4.12.5 other setup work fine material proceed natuere park

I still need more info, I cannot replicate the issue. I can see its the WaveWorks code thats causing the issue, but I dont know under what circumstance. Please show me ur material setup, and if at all possible, send me ur project.

Technically that block of code should not even run without a WaveWorks node being placed in the material, so something is very wrong there.

I tried Flat Tessellation with crack free displacement, Vxgi Allow Tessellation, set up a world displacement, set the multiplier to 2. No issues compiling, no issues during voxelization, no issues rendering.

Actually what type of object is it? ie. Static Mesh, Skeletal Mesh, etc. Or is it a custom object. More interested in the Vertex Factory it uses - Since every vertex factory requires the VertexFactoryWaveWorksInterpolate method to be implemented even when its not used so that it wont error with the error ur getting. So if you are using a custom vertex factory of your own creation, you’ll need to implement that method yourself, just make it empty.

Hey , sorry about the VRworks request mixup. Yes, I actually meant multires branch (you’re right, that’s the only bit or their VRworks suite that they’ve provided for UE4.) the multires tech is SO helpful… can’t believe Epic hasn’t just decided to integrate it natively. It would be really really useful for knowledgeable VR revs to have this available with the rest of your awesome merged branch… any chance of it happening soon? :slight_smile:

As I said in my main post, it depends on the interest in it. As I really have no need for it at this time. So if more people request it then I will work on it immediately.

. Thank you for providing this branch. I successfully built the “Development Editor” configuration and run the editor, but the build fails for “Development” and “Shipping” game configurations (i.e. trying to build UE4Game.exe). Here’s the compiler output:


4>  Engine.generated.1.cpp
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes\Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes\Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Private\Materials\MaterialExpressions.cpp(10332): error C2039: 'Expression': is not a member of 'FExpressionInput'
4>  H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Public\MaterialExpressionIO.h(11): note: see declaration of 'FExpressionInput'
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Private\Materials\MaterialExpressions.cpp(10337): error C2039: 'Compile': is not a member of 'FExpressionInput'
4>  H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Public\MaterialExpressionIO.h(11): note: see declaration of 'FExpressionInput'
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Private\Materials\MaterialExpressions.cpp(10337): error C2660: 'FMaterialCompiler::WaveWorks': function does not take 3 arguments
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes\Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes\Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>  Engine.generated.3.cpp
4>  Engine.generated.4.cpp
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Private\SceneView.cpp(1971): error C2614: 'FSceneViewFamily': illegal member initialization: 'bVxgiAvailable' is not a base or member
4>  Engine.generated.5.cpp
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>  Engine.generated.2.cpp
4>  Module.Renderer.1_of_10.cpp
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>  Module.Renderer.9_of_10.cpp
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Renderer\Private\DeferredShadingRenderer.cpp(1285): error C2039: 'bVxgiAvailable': is not a member of 'FSceneViewFamily'
4>  h:\develop\unrealengine-4.12.5_nvidia_techs\engine\source\runtime\engine\public\SceneView.h(980): note: see declaration of 'FSceneViewFamily'
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Renderer\Private\VxgiRendering.cpp(442): error C2039: 'bVxgiAvailable': is not a member of 'FSceneViewFamily'
4>  h:\develop\unrealengine-4.12.5_nvidia_techs\engine\source\runtime\engine\public\SceneView.h(980): note: see declaration of 'FSceneViewFamily'
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(22): error C3668: 'UMaterialExpressionWaveWorks::Compile': method with override specifier 'override' did not override any base class methods
4>H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Source\Runtime\Engine\Classes/Materials/MaterialExpressionWaveWorks.h(23): error C3668: 'UMaterialExpressionWaveWorks::GetCaption': method with override specifier 'override' did not override any base class methods
4>ERROR : UBT error : Failed to produce item: H:\Develop\UnrealEngine-4.12.5_NVIDIA_Techs\Engine\Binaries\Win64\UE4Game-Win64-Shipping.exe


Checking to see if it’s just my set up having this issue.

I stated in the original post that it was most likely unpackagable, I haven’t applied any fixes yet, this is a direct merge of the branches as they come from NVIDIA.