JeffR Posted January 17, 2016 Share Posted January 17, 2016 Github branch: https://github.com/Azaezel/Torque3D/tree/Deferred_Complete_3.8This implements the full deferred shading pipeline. As there's a few things that need fixing with the DX11 branch that Timmy's still looking into, for the moment we'll push forward on giving the Deferred work a test-over so it can be rolled in first. As far as I or Az are aware of, it's all functional, so it should just be a matter of pulling the changes into a build(preferrable a game build!) and testing everything to make sure it all behaves as one expects. Link to comment Share on other sites More sharing options...
JeffR Posted January 17, 2016 Author Share Posted January 17, 2016 Side note: this includes the color linearization stuff as well, so testing this tests that too. Link to comment Share on other sites More sharing options...
saindd Posted January 18, 2016 Share Posted January 18, 2016 Does this work with the OpenGL version? Link to comment Share on other sites More sharing options...
JeffR Posted January 18, 2016 Author Share Posted January 18, 2016 Yep. Link to comment Share on other sites More sharing options...
razvanab Posted January 18, 2016 Share Posted January 18, 2016 I tested on opengl and it runs very slowly.Spec:Core 2 duo 1.8 63004gb ramRadeon 6950 1gb ramIs there any chance to make the src compile on VS2015 also ? Link to comment Share on other sites More sharing options...
Azaezel Posted January 18, 2016 Share Posted January 18, 2016 updated with https://github.com/GarageGames/Torque3D/pull/1504 + https://github.com/GarageGames/Torque3D/pull/1505 Link to comment Share on other sites More sharing options...
Nils Posted January 19, 2016 Share Posted January 19, 2016 Cool stuff!Thumbs up! Link to comment Share on other sites More sharing options...
razvanab Posted January 19, 2016 Share Posted January 19, 2016 @Azaezel Will this be push to the garage_game development bench ? Link to comment Share on other sites More sharing options...
JeffR Posted January 19, 2016 Author Share Posted January 19, 2016 @razvanabAz means that in the Deferred_Complete_3.8 branch that we'll be testing to make sure the Deferred stuff is ready, he's merged in those OpenGL fixes that Lopuska made.Once this branch has been sufficiently tested though, yes, it will be PR'd and rolled into the main repository. So, if you'd like to see that happen sooner, feel free to grab it and do some testing :) Link to comment Share on other sites More sharing options...
saindd Posted January 19, 2016 Share Posted January 19, 2016 Won't deferred shading make the engine much slower? Link to comment Share on other sites More sharing options...
razvanab Posted January 19, 2016 Share Posted January 19, 2016 @razvanabAz means that in the Deferred_Complete_3.8 branch that we'll be testing to make sure the Deferred stuff is ready, he's merged in those OpenGL fixes that Lopuska made.Once this branch has been sufficiently tested though, yes, it will be PR'd and rolled into the main repository. So, if you'd like to see that happen sooner, feel free to grab it and do some testing :) I already did that and so far it looks good. But I noticed some bugs on the water planes when I enable some post_fx for example bloom. Are there some deferred specific bugs that I should be looking for? Link to comment Share on other sites More sharing options...
Azaezel Posted January 19, 2016 Share Posted January 19, 2016 Won't deferred shading make the engine much slower?Prepass Lighting (advanced) is a deferred variant. Only major difference is we don't throw buffers out between prepass then multiply on diffuse. But I noticed some bugs on the water planes when I enable some post_fx for example bloom. Are there some deferred specific bugs that I should be looking for? http://i.imgur.com/R1kV0wY.jpg Link to comment Share on other sites More sharing options...
Timmy Posted January 19, 2016 Share Posted January 19, 2016 Won't deferred shading make the engine much slower? Depending on your scene and hardware configuration, deferred shading can be faster than Prepass Lighting. While it certainly uses more bandwidth it also avoids rendering everything twice. Link to comment Share on other sites More sharing options...
Azaezel Posted January 19, 2016 Share Posted January 19, 2016 Looks like stock, bloom was never getting applied in the first place: http://imgur.com/a/gsIOg this one'll likely be a bit tricky. Link to comment Share on other sites More sharing options...
razvanab Posted January 19, 2016 Share Posted January 19, 2016 @AzaezelThat crack me up. Link to comment Share on other sites More sharing options...
Azaezel Posted January 19, 2016 Share Posted January 19, 2016 http://imgur.com/a/krd8g that work for folks? Link to comment Share on other sites More sharing options...
razvanab Posted January 19, 2016 Share Posted January 19, 2016 http://imgur.com/a/krd8g that work for folks?It looks good to me. Link to comment Share on other sites More sharing options...
Azaezel Posted January 19, 2016 Share Posted January 19, 2016 K. Updated. Code: https://github.com/Azaezel/Torque3D/commit/d9e59178356c3d7ba85c26a79b5a506afec92f8f Link to comment Share on other sites More sharing options...
JeffR Posted January 25, 2016 Author Share Posted January 25, 2016 Did some testing on that here. Does indeed add the bloom back in, but it looks like the bloom is on even at night time in the Outpost level. Probably an artifact of how specularity is calculated on the water than anything else though. Otherwise, seems like a solid fix. Anyone else noting any other problems? Because if not, this'll probably get rolled in in the next couple days if no one elses spots any issues. Link to comment Share on other sites More sharing options...
newaged Posted January 27, 2016 Share Posted January 27, 2016 (edited) What changes do you need to make to custom materials / shaders that worked in 3.8 to get them to work here? They are always replaced with a white mat in the deferred branch. Can't share the shader code, I didn't write it. Edited January 28, 2016 by newaged Link to comment Share on other sites More sharing options...
Azaezel Posted January 27, 2016 Share Posted January 27, 2016 http://i.imgur.com/h6H6eIn.jpg looking into it. Would appear we overlooked a couple hooks. Link to comment Share on other sites More sharing options...
Lopuska Posted February 12, 2016 Share Posted February 12, 2016 Hello! (:I just talked with @Azaezel. He gave me some useful infos about what are source parts to check.I'm taking a look now to resolve this custom material issue.I'll give updates as soon as possible. Link to comment Share on other sites More sharing options...
Lopuska Posted February 13, 2016 Share Posted February 13, 2016 https://github.com/Azaezel/Torque3D/commit/65238d320fd97c7498cf788efecf41244b3f934cWith this fix it works.On deferred lighting we use the prepass buffer (normal+z) and now in fully deferred pipeline we have 2 additional render targets (color + material) used to avoid the forward step (draw everything twice).Briefly, the correct way to fix this, is to draw custom materials as forward rendering because custom materials have custom shaders that bypass torque material system. (and obviously these are not the shaders used during the prepass draw). Effectively, deferred shading allow to use only one material type. ( it's one of the limitations ). However we support also traditional forward render and that's the correct way to draw custom or complex materials as other engines does.Hope it helps.Anis Link to comment Share on other sites More sharing options...
Recommended Posts