tonemap is broken after a time

Bugs that have been resolved.

Moderator: Graf Zahl

ibm5155
Posts: 152
Joined: Tue Oct 25, 2011 13:05

tonemap is broken after a time

Post by ibm5155 »

Both AMD HD8870m and intel hd 4000 could produce the same error.
After a time playing my mod (i should test with vanilla doom2 later), the screen stops refreshing and just a part of the screen will get rendered...

The effect only stops if you disable tonemap, but all the tonemaps are affected by that (and it looks like it's not affected when viewed from different angle...
EDIT: oops, posted in the wrong área, please move to the bug area
Last edited by ibm5155 on Mon Aug 01, 2016 21:01, edited 1 time in total.
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time (mov to bug thread)

Post by dpJudas »

Where do I get a copy of that wad? And how to get to this location? Would like to test it on my card.
ibm5155
Posts: 152
Joined: Tue Oct 25, 2011 13:05

Re: tonemap is broken after a time (mov to bug thread)

Post by ibm5155 »

The mod file is kinda big but here is it: http://www.mediafire.com/download/l39yj ... C_0010.pk3
Just run for some doors (they are random) and you'll get that glitch...
Ehm, could it be related to the map size? because the map is near if not reached the 3k size
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time (mov to bug thread)

Post by dpJudas »

The link isn't working for me. I get an site is down message when I click on it (tried a couple of times now over a minute or two).

What I'm seeing on the video looks like scene render corruption - so there could be a connection. Or it could be related to the driver crash you are having. If you look closely on the video you can see that the 2D HUD parts rendered after the scene is updating while the scene behind is not. Why the tonemap is triggering it I cannot say yet - maybe its related to the camera exposure calculations. What range are the sector light levels at in this area of the map?
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time (mov to bug thread)

Post by dpJudas »

OK managed to download the file now.
ibm5155
Posts: 152
Joined: Tue Oct 25, 2011 13:05

Re: tonemap is broken after a time (mov to bug thread)

Post by ibm5155 »

The link is working here (tried now)
all the sectors have the bright level to 104.
Here are some more pics
Image not glitched
Image
walk a bit and there you go
Image
and another área
Image

Also I tried to change from windowed mode to fullscreen using the amd gpu and this is what happened

Code: Select all

map01 - Spooky House Of Jump Scares - ibm5155

"fullscreen" is "true"
R_OPENGL: No valid pixel formats found. Retrying in compatibility mode
Warning: 'Object' is freed outside the GC process.

R_OPENGL: Couldn't set pixel format.
CrashReport.zip
(27.15 KiB) Downloaded 72 times
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Re: tonemap is broken after a time (mov to bug thread)

Post by Graf Zahl »

That looks like a driver problem or some system related issue. What I'd do next is making sure that it's not some interference between the AMD and Intel driver by uninstalling one of them.
User avatar
Rachael
Developer
Developer
Posts: 3646
Joined: Sat May 13, 2006 10:30

Re: tonemap is broken after a time (mov to bug thread)

Post by Rachael »

ibm5155 wrote:EDIT: oops, posted in the wrong área, please move to the bug area
Done, surprised nobody beat me to it.
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time

Post by dpJudas »

Interestingly this happens on my nv980 as well. The odd thing is it only happens when the camera faces a certain direction and at specific spots. Apparently when something is visible it messes up the rendering somehow. And to make it even more weird it only happens if tonemap is enabled.
ibm5155
Posts: 152
Joined: Tue Oct 25, 2011 13:05

Re: tonemap is broken after a time

Post by ibm5155 »

Here's the map size just in case...
Image
Even removing the big "IBM5155" sector, it does the same thing
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time

Post by dpJudas »

Graf: Do you see anything wrong with what FFlatVertexBuffer::RenderScreenQuad (https://github.com/coelckers/gzdoom/blo ... fer.h#L108) is doing?

I've managed to fix the glitch, but what solved it is really worrying me. If you look at the last screenshot from ibm5155 (with all the yellow) the two triangles you can see there is actually the screen quad supposed to cover the entire viewport. If I replace it with a static VBO (https://github.com/dpjudas/zdoom/commit ... b38eb221d9) the glitch go away and everything is fine.

This seems to imply some kind of corruption issue with the vertices in the VBO, or, hopefully, something very wrong in the RenderScreenQuad function I added. I recall seeing a bug report earlier about occational vertices acting up in the skybox - maybe there's a connection with that? What do you think?
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time

Post by dpJudas »

The location on the map where it always happens: warp -14310.758 -6790.552
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Re: tonemap is broken after a time

Post by Graf Zahl »

@dpJudas:

The only explanation I can come up with is that for some reason the FlatVertexBuffer is not active when you try to use it.
The sky glitch cannot be related because the sky sphere uses its own static buffer.
dpJudas
Developer
Developer
Posts: 798
Joined: Sat Jul 23, 2016 7:53

Re: tonemap is broken after a time

Post by dpJudas »

Ah, there's the chance of other VBO's being active. That was the smoking gun I was looking for. Thanks Graf. :)

PR fix: https://github.com/coelckers/gzdoom/pull/73
Also, I fixed an other minor bug I noticed earlier today: https://github.com/coelckers/gzdoom/pull/72 (some alignment issue if you maximize the window)
ibm5155
Posts: 152
Joined: Tue Oct 25, 2011 13:05

Re: tonemap is broken after a time

Post by ibm5155 »

I tested your fix and indeed, they fixed the problem :D

But with that I found another iuse :| my "baby" isn't more shaking D:

yeah, it's with an opengl shader :O

Code: Select all

uniform float timer;
const float pi = 3.14159265358979323846;
const float speed = 2.5;

vec4 Process(vec4 color)
{
	vec2 t = gl_TexCoord[0].st - 0.5;

	float tcos = cos(pi/50000 * cos(timer*10) * speed);
	float tsin = sin(pi/50000 * cos(timer*10) * speed);
  
	float tx = mod((tcos * t.x - tsin * t.y) - 0.5, 1.0);
	float ty = mod((tsin * t.x + tcos * t.y) - 0.5, 1.0);

  return getTexel(vec2(tx, ty)) * color;
}
warp -15200 -8576 0
idkfa , press zero and see with the flash light the baby
Locked

Return to “Closed Bugs”