Page 3 of 3

Re: Pre-Pull Request: Deferred Shading

Posted: Thu Jan 28, 2016 12:46 am
by Azaezel
http://i.imgur.com/h6H6eIn.jpg looking into it. Would appear we overlooked a couple hooks.

Re: Pre-Pull Request: Deferred Shading

Posted: Fri Feb 12, 2016 5:00 pm
by Lopuska
Hello! (:
I just talked with @
User avatar
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.

Re: Pre-Pull Request: Deferred Shading

Posted: Sat Feb 13, 2016 4:35 pm
by Lopuska
https://github.com/Azaezel/Torque3D/com ... 244b3f934c

With 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