Ambient Occlusion in the GZDoom skybox
Moderator: GZDoom Developers
Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.
If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.
Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.
If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.
Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!
-
- Posts: 13547
- Joined: Wed Jul 16, 2003 3:52 am
Ambient Occlusion in the GZDoom skybox
Dear developers,
I am using a sector-based skybox (sector special 90, GZDoom skybox) in my map and the ambient occlusion portal level is set to two. Unfortunately the ambient occlusion is also applied to the skybox even though it shouldn't be, check the screenshot for an example.
Bug or wrong setup?
I am using a sector-based skybox (sector special 90, GZDoom skybox) in my map and the ambient occlusion portal level is set to two. Unfortunately the ambient occlusion is also applied to the skybox even though it shouldn't be, check the screenshot for an example.
Bug or wrong setup?
-
-
- Posts: 3109
- Joined: Sat May 28, 2016 1:01 pm
Re: Ambient Occlusion in the GZDoom skybox
There used to be a check if the portal being drawn was a skybox and if it were then it wouldn't run SSAO on it. I guess it must have been accidentally removed during one of the refactors of that code.
-
- Lead GZDoom+Raze Developer
- Posts: 49130
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Ambient Occlusion in the GZDoom skybox
He said "sector built". I don't think these get handled properly by the AO pass.
-
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
Re: Ambient Occlusion in the GZDoom skybox
If it's a cube why not make a proper skybox in gldefs?
And if there is other geometry inside it, you could just make it a "recursive" skybox. Where the rest of the map uses skybox pickers to have that as its sky, and then the sector sky itself would have its sky set to the gldefs skybox.
And if there is other geometry inside it, you could just make it a "recursive" skybox. Where the rest of the map uses skybox pickers to have that as its sky, and then the sector sky itself would have its sky set to the gldefs skybox.
-
-
- Posts: 17454
- Joined: Mon Oct 27, 2003 12:07 am
- Location: Kuala Lumpur, Malaysia
Re: Ambient Occlusion in the GZDoom skybox
Yeah this is why I avoid fake skyboxes, as in - a physically square sector with textures applied.
As Marisa said, use real skyboxes (the GLDEFS one). If you need geometry, you can do them recursively. Skyboxeption!
As Marisa said, use real skyboxes (the GLDEFS one). If you need geometry, you can do them recursively. Skyboxeption!
-
- Lead GZDoom+Raze Developer
- Posts: 49130
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Ambient Occlusion in the GZDoom skybox
These recommendations are just stupid, considering that this style of skybox is an official engine feature. What needs to be done is to disable SSAO on any skybox portal being rendered from an appropriately tagged sector.
-
- Posts: 13547
- Joined: Wed Jul 16, 2003 3:52 am
Re: Ambient Occlusion in the GZDoom skybox
I think that is what the “GZDoom Skybox Sector Special” was meant for, but it doesn’t work.dpJudas wrote:There used to be a check if the portal being drawn was a skybox and if it were then it wouldn't run SSAO on it. I guess it must have been accidentally removed during one of the refactors of that code.
-
- Posts: 3886
- Joined: Fri Feb 08, 2008 9:15 am
- Preferred Pronouns: She/Her
- Operating System Version (Optional): (btw I use) Arch
- Graphics Processor: nVidia with Vulkan support
- Location: Vigo, Galicia
Re: Ambient Occlusion in the GZDoom skybox
I'm currently in the process of fixing this, see this thread. AO on skyboxes would be disabled by default and need to be enabled explicitly through a mapinfo flag.
-
- Posts: 1349
- Joined: Tue Nov 05, 2019 6:48 am
- Preferred Pronouns: He/Him
- Graphics Processor: nVidia with Vulkan support
Re: Ambient Occlusion in the GZDoom skybox
I was just about to make another thread about this, glad I didn't have to.
I experienced an identical issue when I played ZDCMP2, strange square-like lines on the sky. I assumed it was a mapping error or some strange video artifact initially, but apparently it's not. This really ruins the skies if you ask me, so I'm glad it's getting addressed.
I experienced an identical issue when I played ZDCMP2, strange square-like lines on the sky. I assumed it was a mapping error or some strange video artifact initially, but apparently it's not. This really ruins the skies if you ask me, so I'm glad it's getting addressed.
-
- Lead GZDoom+Raze Developer
- Posts: 49130
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: Ambient Occlusion in the GZDoom skybox
ZDCMP'2's skybox is actual sector geometry, that won't be fully fixable.
-
-
- Posts: 26540
- Joined: Tue Jul 15, 2003 4:58 pm
- Location: Scotland
Re: Ambient Occlusion in the GZDoom skybox
Purely out of interest, I'm wondering why the skybox in the OP is made from a sector anyway. Isn't it just a cube with textures applied to the sides? If so, why not define it in GLDEFS?
-
- Posts: 13547
- Joined: Wed Jul 16, 2003 3:52 am
Re: Ambient Occlusion in the GZDoom skybox
Because you can add dynamic objects to such a sector-based skybox or alter the textures of said sector. There are so many possibilities if it is sector-based.Enjay wrote:Purely out of interest, I'm wondering why the skybox in the OP is made from a sector anyway. Isn't it just a cube with textures applied to the sides? If so, why not define it in GLDEFS?
-
-
- Posts: 26540
- Joined: Tue Jul 15, 2003 4:58 pm
- Location: Scotland
Re: Ambient Occlusion in the GZDoom skybox
So it isn't just a simple cube then - it has dynamic elements too. Got it.
BTW, if all you want to do is change a GLDEFS skybox texture, that can be done using the usual changesky ACS command and the name of the skybox as defined in GLDEFS. I've done it several times myself.
BTW, if all you want to do is change a GLDEFS skybox texture, that can be done using the usual changesky ACS command and the name of the skybox as defined in GLDEFS. I've done it several times myself.
-
- Posts: 13547
- Joined: Wed Jul 16, 2003 3:52 am
Re: Ambient Occlusion in the GZDoom skybox
Yes, but adding weather effects or models into the skybox is a bit trickier