Page 1 of 1

OpenGL bug with dynamic lights

Posted: Thu Jul 22, 2021 11:12 pm
by kfpopeye2
Not sure if this is a bug but...

I have the following object defined in GLDEF:

Code: Select all

object COLUMN_1
{
    frame COL1 {light LIGHT_COL1_1}
    frame COL1A {light LIGHT_COL1_2}
    frame COL1B {light LIGHT_COL1_3}
    frame COL1C {light LIGHT_COL1_4}
}
the lights are just simple point lights. Then I have the following states in the actor class:

Code: Select all

States
	{
		Spawn:
			COL1 A 1;
		IdleOn:
			COL1 ABC 1;
			Loop;
	}
The problem I have is the 3 frame bound lights are always flashing. I would have thought that 1 tic would be too fast to see the lights turn off but it isn't. Am I missing something?

Re: OpenGL bug with dynamic lights

Posted: Fri Jul 23, 2021 1:53 pm
by Graf Zahl
Please post a runnable example.

Re: OpenGL bug with dynamic lights

Posted: Sat Jul 24, 2021 5:43 pm
by kfpopeye2
See attached PK3 for Doom2 map with column resources.

Re: OpenGL bug with dynamic lights

Posted: Sat Jul 24, 2021 8:02 pm
by Blue Shadow
kfpopeye2 wrote:The problem I have is the 3 frame bound lights are always flashing. I would have thought that 1 tic would be too fast to see the lights turn off but it isn't. Am I missing something?
To me, at least, the effect you see is normal. Think about it for a bit: each of the three sides of the column is lit for 1 tic (~0.028571 seconds) and is unlit for 2 tics (~0.057142 seconds). That would create the light flickering effect you see, wouldn't it?

Re: OpenGL bug with dynamic lights

Posted: Sat Jul 24, 2021 10:31 pm
by kfpopeye2
I'd think the flickering would be too fast for the human eye to see. I could be wrong though.

Re: OpenGL bug with dynamic lights

Posted: Sun Jul 25, 2021 12:12 am
by Graf Zahl
What makes you think it's too fast to be seen? No, sorry, this behaves exactly like intended.