[4.2.4] Sprites far away get drawn over closer sprites

Is there something that doesn't work right in the latest GZDoom? Post about it here.

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!

[4.2.4] Sprites far away get drawn over closer sprites

Postby Thomas Murdforth » Sun Dec 29, 2019 9:13 am

Tested on both 4.2.4 and gzdoom-x64-g4.3pre-568-g77469e051 (latest dev build as of this post). It happens in both Vulkan and OpenGL. Hell, it happens even in SoftPoly, for what it's worth.

There is a way to see this for yourselves. I'll attach save file below. You'll need the following files:

TVR!: https://www.doomworld.com/idgames/level ... gawads/tvr
Universal Gibs: https://gitlab.com/accensi/UniversalGib ... master.zip
Hideous Destructor 4.2.4b: https://github.com/MatthewTheGlutton/Hi ... 4.2.4b.pk7
Save game & screenshots: https://drive.google.com/open?id=1mm405 ... 42qHIm0sSd
Listed in load order, although it doesn't seem to matter.

I haven't tried to reproduce in vanilla. Not sure how to reproduce it at all. It just randomly happens, usually later in the level when there are a lot of sprites (Universal Gibs probably helps trigger it). At least it persists when it happens, and between save game loading or restarting GZDoom.
It should be visible right after loading the save, just above the cursor. See screenshots, too. If you look left and right you can see the issue disappear. It only happens under certain angles. The blood consists of flatsprites, for the record, but I have seen this happen with regular sprites as well, so it's definitely not tied only to the former.

Specs:
Windows 10 Pro, x64
Nvidia GTX 1080 (updated drivers last week; problem has been present for a while and that did not help)
Thomas Murdforth
 

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby Graf Zahl » Sun Dec 29, 2019 10:27 am

From the looks of it this is caused by the translucent flat sprites in the Universal Gibs mod. This feature is unfortunately a little bit broken and without a significant feature regression it's not fixable.

The current flat and wall sprite implentations need to be gutted and replaced with something that is actuallly manageable by the renderer, but I think you can imagine how that will work out...
User avatar
Graf Zahl
Lead GZDoom Developer
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby Thomas Murdforth » Sun Dec 29, 2019 11:24 am

I mentioned in the OP that I have seen this happen with non-flatsprite actors as well. I clearly remember a regular grass sprite being visible through a chaingunner's foot when the grass was at least 500 map units away. See link below. This happened on one of Hell on Earth Starter Pack's maps. Another time, with flatsprites, I encountered flickering between normal and broken rendering, despite not moving or looking around. See 2nd link. I know about the usual problem with translucent flat sprites, but this is recent. I don't recall seeing it prior to 4.2.0, far as I can remember at least.

https://cdn.discordapp.com/attachments/ ... 160154.png
https://cdn.discordapp.com/attachments/ ... -26-21.mp4 (will download the vid)
Thomas Murdforth
 

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby phantombeta » Fri Jan 17, 2020 3:24 am

This definitely should be looked into. It's not just flatsprites, as you can see from the screenshot in the last post. I've also encountered this myself too with a pickup and a dead monster that definitely weren't flatsprites.
(Funnily enough, also with Hideous Destructor. Not with UG and TVR!, though, I was playing with Alfonzone and a Hideous Destructor weapons addon)
User avatar
phantombeta
In the meadow of sinful thoughts, every flower's a perfect one
 
Joined: 02 May 2013
Location: The United Soviet Socialist Dictatorship of Hueland
Discord: phantombeta#2461
Twitch ID: phantombeta_
Github ID: Doom2fan
Operating System: Windows 10/8.1/8 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby lowskill. » Mon Jan 20, 2020 6:15 am

Looking at the image in the first link above phantom's post, is that related to the second issue I reported here, but which was seemingly omitted (admittedly I should've probably made another topic for it to not get lost)?

viewtopic.php?f=7&t=66901

Some sprites/decals can be seen through walls: https://i.imgur.com/4EEY3To.png
User avatar
lowskill.
GZDoom RO Translator
 
Joined: 05 Nov 2019
Twitch ID: sixhundredsixteen
Github ID: sinisterseed
Operating System: Windows 10/8.1/8 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby phantombeta » Sat Jan 25, 2020 10:29 am

I just had the bug again just now, also with HD. Some tree sprites (which are fully opaque) briefly got screwed up sorting, with some trees appearing in front of others when they shouldn't. The scene where it happened is depicted in the screenshot below:

However, in this case, they suddenly got correct depth sorting back. I'm guessing something somewhere is not setting state correctly, and transparent sprites are messing up depth culling for opaque ones.
User avatar
phantombeta
In the meadow of sinful thoughts, every flower's a perfect one
 
Joined: 02 May 2013
Location: The United Soviet Socialist Dictatorship of Hueland
Discord: phantombeta#2461
Twitch ID: phantombeta_
Github ID: Doom2fan
Operating System: Windows 10/8.1/8 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby Graf Zahl » Sat Jan 25, 2020 10:46 am

Please post your INI. Something must be different from mine, as I've never seen this effect.
User avatar
Graf Zahl
Lead GZDoom Developer
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby phantombeta » Sat Jan 25, 2020 10:53 am

Here you go. Maybe it has to do with the specific transparency settings of the surrounding actors, too.
Attachments
gzdoom-Chronos.ini
(114.71 KiB) Downloaded 1 time
User avatar
phantombeta
In the meadow of sinful thoughts, every flower's a perfect one
 
Joined: 02 May 2013
Location: The United Soviet Socialist Dictatorship of Hueland
Discord: phantombeta#2461
Twitch ID: phantombeta_
Github ID: Doom2fan
Operating System: Windows 10/8.1/8 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: [4.2.4] Sprites far away get drawn over closer sprites

Postby Graf Zahl » Sat Jan 25, 2020 11:06 am

I think gl_sprite_blend is the culprit here. If you see it again, can you try to toggle that CVAR?
User avatar
Graf Zahl
Lead GZDoom Developer
Lead GZDoom Developer
 
Joined: 19 Jul 2003
Location: Germany


Return to Bugs

Who is online

Users browsing this forum: No registered users and 2 guests