Graf Zahl wrote:I believe it's absolutely necessary to implement some means to selectively exclude things from the SSAO pass.
One problem with excluding a sector skybox from the SSAO pass is - what if the mapper constructs actual geometry into the sector skybox? Like distant buildings and things like that. Would be weird to see those not have shadows...
Re: SSAO discussion
Posted: Sun Sep 11, 2016 19:11
by dpJudas
The way it is implemented right now, if the main shader outputs 0 in the alpha channel then that will be excluded from SSAO. We just need to figure out which walls/floors/ceilings we should do that for.
Re: SSAO discussion
Posted: Sun Sep 11, 2016 23:55
by Gez
One-sided walls plus floor and ceiling in skybox sectors would perhaps be a safe assumption. Though perhaps there could be a special mechanism (a texture flag? or a line/sector flag?) to mark skybox textures since sector skyboxes have other issues than SSAO, issues that are IIRC automatically solved for GLDEFS skyboxes.
[spoiler]I'm referring to the visible vertical and horizontal lines here: IIRC it's caused by tiling the texture. [/spoiler]
Re: SSAO discussion
Posted: Mon Sep 12, 2016 16:05
by dpJudas
Actually I don't think you would want them on one-sided walls because that would could secrets behind a one sided wall. A line/sector flag or texture flag is probably the most flexible way. I'm not sure what is best here.
Re: SSAO discussion
Posted: Mon Sep 12, 2016 17:01
by Rachael
I dunno but I think both would probably work. Line/sector flag is probably best if you choose only one, though. However, the biggest concern is that older maps would not be updated enough to handle it.
Maybe the best thing to do is to declare in a map definition that SSAO must be specifically enabled in order to use it, and then allow a possible user option to override it (through the console only)?
Re: SSAO discussion
Posted: Mon Sep 12, 2016 17:22
by Nash
Just a tiny update on my FPS drop situation, testing with vid_maxfps = 0 and vid_vsync = 0.
With ALL post processing turned off (even AA, which apparently drains hundreds of frames per second as I've only found out :O)
1) Looking away from portal and into the wall - 880 FPS
2) Looking into the portal - 350 FPS
3) Same as (2) but with only SSAO enabled: 70 FPS
Of course with more post processing enabled (my normal play settings are 8x AA, bloom and lens distortion), plus the SSAO, my FPS drops to 30 FPS (vsync on) or 40 FPS (vsync off)
Despite these numbers, under normal play circumstances (ie with normal Doom maps), my framerate stays at 60. It's only with this portal demo that I see all of these performance costs.
Re: SSAO discussion
Posted: Mon Sep 12, 2016 18:26
by Graf Zahl
Portals can cause really bad stalls, and SSAO is a relatively costly pass. Before finalizing a portal this all needs to be finished so such drops are to be expected.
Re: SSAO discussion
Posted: Mon Sep 12, 2016 21:49
by Gez
dpJudas wrote:Actually I don't think you would want them on one-sided walls because that would could secrets behind a one sided wall.
If you hide a secret in a skybox sector, you're really devious!
Re: SSAO discussion
Posted: Mon Sep 12, 2016 22:30
by dpJudas
If Romero could hide a secret in a secret, then surely I can hide one in a skybox.
Re: SSAO discussion
Posted: Mon Sep 12, 2016 22:54
by Edward-san
How about the skybox secret in Jumpmaze 2 map40?
Re: SSAO discussion
Posted: Thu Sep 15, 2016 2:21
by AFADoomer
Possibly dumb question, but I don't remember seeing it discussed here after the very beginning of the thread...
Are sprites intentionally excluded from the SSAO pass? Translucent textures with solid patterns in them are handled fine, so I'm curious why sprites aren't handled similarly.
I only really noticed because I use a lot of wall sprites, and they are drawn after the SSAO is applied (they still show up full-color, with standard shading with gl_ssao_debug enabled).
Re: SSAO discussion
Posted: Thu Sep 15, 2016 7:05
by Graf Zahl
Sprites are rendered without any depth information at all. This is to avoid z-fighting when they overlap.
For wall sprites with no translucency at all this was changed recently, but this change probably hasn't filtered down to the SSAO branch.
Re: SSAO discussion
Posted: Thu Sep 15, 2016 11:29
by dpJudas
Depends on where in the rendering step it renders those sprites with no translucency. In DrawScene it calls RenderScene, AmbientOccludeScene, and then RenderTranslucent.
Re: SSAO discussion
Posted: Thu Sep 15, 2016 12:03
by Tormentor667
Tormentor667 wrote:
Spoiler:
It is getting better and better, but I still have issues with skybox sectgors:
Another thing I noticed: Sound isn't working anymore with the SSAO builds.
Beyond in snowy bright maps I find the bloom effect not really usable. Can it be somehow altered that if the majority of the screen is very bright, the bloom effect gets lowered so the surrounding areas are visible again and not overblindingly bright?
Bloom on
Bloom off
Sorry for double-posting this, but I just wanted to ask again concerning the portal fixes and especially the bloom issue with very bright maps.
Re: SSAO discussion
Posted: Thu Sep 15, 2016 12:25
by dpJudas
About the skybox shadowing thing, there is a plan for how to deal with this, but nothing implemented yet.
For the bloom, the problem here is how it calculates camera exposure. I cheated and used the sector brightness level as the indicator instead of what pixels are on the screen. I can probably fix this by calculating the real exposure, but it won't make it into the upcoming release I'm afraid.