simplified "fog + shadows" to no longer have to use a custom GL_BLEND or use gl.drawArrays twice within the shadow pass. Instead use fog to "mask" the shadows so only the "shadows - fog" are returned from renderShadows. Also applied this same logic to the SSAO pass as it feels more natural visually to have the SSAO disappear into the fog.
Thanks ! I think this could work well as simplifications are always welcome. Please run npm run lint-fix which should take care of the formatting. There may also be some comments on the code.
simplified "fog + shadows" to no longer have to use a custom GL_BLEND or use gl.drawArrays twice within the shadow pass. Instead use fog to "mask" the shadows so only the "shadows - fog" are returned from renderShadows. Also applied this same logic to the SSAO pass as it feels more natural visually to have the SSAO disappear into the fog.