ReLite
Forum rules
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
-
- Posts: 43
- Joined: Mon May 15, 2023 12:13 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: ReLite
Dude... Reset solves the issue, but I found that ReLite menu is only at simple menu of Gzdoom and not full menu, that's why I couldn't find it. https://imgur.com/a/ZqSWibr Thanks.. now looks great. By the way...
Width ReLite 0.5.2a has some lights that enhances great some areas like in the E2M1 ath the red cross, with relight 0.61a, these lights are not present. https://imgur.com/a/AOGzmxL
Great job dude.
Width ReLite 0.5.2a has some lights that enhances great some areas like in the E2M1 ath the red cross, with relight 0.61a, these lights are not present. https://imgur.com/a/AOGzmxL
Great job dude.
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: ReLite
Thanks! I appreciate it.cortes2k wrote: ↑Sun Oct 15, 2023 6:12 pm Dude... Reset solves the issue, but I found that ReLite menu is only at simple menu of Gzdoom and not full menu, that's why I couldn't find it. https://imgur.com/a/ZqSWibr Thanks.. now looks great. By the way...
Width ReLite 0.5.2a has some lights that enhances great some areas like in the E2M1 ath the red cross, with relight 0.61a, these lights are not present. https://imgur.com/a/AOGzmxL
Great job dude.
The REDWALL1 texture does not have a brightmap, and so I added this to the list initially. The problem with that is it makes the red room in E2M4 look ridiculous, so I've reverted this until I can figure something out.
-
- Posts: 202
- Joined: Mon Dec 20, 2021 6:16 am
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: ReLite
Relite works great on delta touch! However i did notice that using flashlight ++ it does tend to drop fps.
-
- Posts: 43
- Joined: Mon May 15, 2023 12:13 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: ReLite
Oh... ok ok... I understand... you're right with that red room. I have a question, do you have plan to add lights to the windows like Relighting?Hey Doomer_ wrote: ↑Mon Oct 16, 2023 5:53 amThanks! I appreciate it.cortes2k wrote: ↑Sun Oct 15, 2023 6:12 pm Dude... Reset solves the issue, but I found that ReLite menu is only at simple menu of Gzdoom and not full menu, that's why I couldn't find it. https://imgur.com/a/ZqSWibr Thanks.. now looks great. By the way...
Width ReLite 0.5.2a has some lights that enhances great some areas like in the E2M1 ath the red cross, with relight 0.61a, these lights are not present. https://imgur.com/a/AOGzmxL
Great job dude.
The REDWALL1 texture does not have a brightmap, and so I added this to the list initially. The problem with that is it makes the red room in E2M4 look ridiculous, so I've reverted this until I can figure something out.
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: ReLite
Possible. The problem in Relighting was deciding what a window is, since these can exist inside-inside and outside-inside. I tried spotlight window lights in the revamp Relighting for performance reasons and to show light direction, which is different from point light grids used in the original. Maybe a combination of both ideas or something different works?
No plans yet. I'm sure I'll return to the idea again.
-
- Posts: 43
- Joined: Mon May 15, 2023 12:13 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: ReLite
Ok... the problems is that you can't know what window is in a map ok ok. I think "windows" inside a building creates a projected light automaticaly if there is a light texture at the celing or a lamp. What about detcting a sector that "has a window" and is beside a sector with the sky texture and has brighter light? That way we wouldn't have lights inside a place that is not a window I don't know if is posible in the programing languange do that. In that way,Hey Doomer_ wrote: ↑Tue Oct 17, 2023 4:18 amPossible. The problem in Relighting was deciding what a window is, since these can exist inside-inside and outside-inside. I tried spotlight window lights in the revamp Relighting for performance reasons and to show light direction, which is different from point light grids used in the original. Maybe a combination of both ideas or something different works?
No plans yet. I'm sure I'll return to the idea again.
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
Re: ReLite
Sounds simple; Doom geometry is highly variable. I'll think on it. It's certainly possible.cortes2k wrote: ↑Tue Oct 17, 2023 11:40 am Ok... the problems is that you can't know what window is in a map ok ok. I think "windows" inside a building creates a projected light automaticaly if there is a light texture at the celing or a lamp. What about detcting a sector that "has a window" and is beside a sector with the sky texture and has brighter light? That way we wouldn't have lights inside a place that is not a window I don't know if is posible in the programing languange do that. In that way,
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
ReLite Progress 0.6.2a
Progress 0.6.2a
I am making good progress in decompressing PNG zipped data as part of a general image routine. This is described for Python in some detail here. It's pretty straightforward if one understands Python moderately well. I should be done with this conversion and testing in a few days.
This routine is needed because a PNG file, which consists of "chunks," zips image pixel data (usually RGB triplets for textures with alpha added for sprites) in IDAT chunks using fixed or dynamic trees. These days everything involving zips is done with libraries - including in Python - but fortunately there isn't a lot of code involved with it. It's well documented if complex.
What this lets ReLite do is use most images as light sources. In other words, it won't matter if an image is a PNG or LMP inside or outside a WAD format. (I don't know if other image formats are used.) An image can be analyzed for color, etc. Bitmaps stored as a PNG can also be read to determine how "bright" they are and thus excluded as a true light source. This routine removes limitations around images and image formats.
Release "soon."
Code: Select all
0.6.2
10/13 - fixed truncated double in shadow code
10/14 - added sprite color to decorative light routine
10/14 - exclude self as light source in shadow code
This routine is needed because a PNG file, which consists of "chunks," zips image pixel data (usually RGB triplets for textures with alpha added for sprites) in IDAT chunks using fixed or dynamic trees. These days everything involving zips is done with libraries - including in Python - but fortunately there isn't a lot of code involved with it. It's well documented if complex.
What this lets ReLite do is use most images as light sources. In other words, it won't matter if an image is a PNG or LMP inside or outside a WAD format. (I don't know if other image formats are used.) An image can be analyzed for color, etc. Bitmaps stored as a PNG can also be read to determine how "bright" they are and thus excluded as a true light source. This routine removes limitations around images and image formats.
Release "soon."

-
- Posts: 367
- Joined: Mon Mar 25, 2013 11:47 am
Re: ReLite Progress 0.6.2a
I hope you know that all the hard work and hours you've sunk into this fantastic MOD is going to put you in the history books as one of the few responsible for transforming DOOM forever going forward! I hope to see this integrated into gzdoom permanently at some point!Hey Doomer_ wrote: ↑Fri Oct 20, 2023 2:58 am Progress 0.6.2a
I am making good progress in decompressing PNG zipped data as part of a general image routine. This is described for Python in some detail here. It's pretty straightforward if one understands Python moderately well. I should be done with this conversion and testing in a few days.Code: Select all
0.6.2 10/13 - fixed truncated double in shadow code 10/14 - added sprite color to decorative light routine 10/14 - exclude self as light source in shadow code
This routine is needed because a PNG file, which consists of "chunks," zips image pixel data (usually RGB triplets for textures with alpha added for sprites) in IDAT chunks using fixed or dynamic trees. These days everything involving zips is done with libraries - including in Python - but fortunately there isn't a lot of code involved with it. It's well documented if complex.
What this lets ReLite do is use most images as light sources. In other words, it won't matter if an image is a PNG or LMP inside or outside a WAD format. (I don't know if other image formats are used.) An image can be analyzed for color, etc. Bitmaps stored as a PNG can also be read to determine how "bright" they are and thus excluded as a true light source. This routine removes limitations around images and image formats.
Release "soon."![]()
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
ReLite Progress 0.6.2a
Progress 0.6.2a
Python & ZScript code now work the same.
Brutal Doom PNGs created with Macromedia Fireworks 8 (now Adobe) are more or less unreadable with an additional corrupted IDAT chunk at the end (I only tried two images). SLADE "optimization" fixes this and removes corrupted/useless chunks. For now I should be able to catch these kinds of errors to report in the console. All other images tried read (mind you only a handful) without error. It's also fast.
I have added color routines for RGB and RGBA images but as of now not those indexed to a palette chunk. For 0.6.2a I'll optimize light placement and significantly jack performance by analyzing brightmaps. These grayscale PNGs are quite interesting. For example:
"Color" is an average from my default routine and always grayscale. "Percent" is of pixels that are averaged. These numbers suggest criteria.
Check out the brightmaps to see the idea. For example "compute2" has some extremely bright spots (#b1b1b1 is a higher than medium shade of gray) but almost the entire image is black and not a light source.
"Soon."
Code: Select all
0.6.2
10/13 - fixed truncated double in shadow code
10/14 - added sprite color to decorative light routine
10/14 - exclude self as light source in shadow code
10/17 - added hd_png class to identify PNG images
10/20 - added converted Python zlib.decompress() for PNG pixel data (https://pyokagan.name/blog/2019-10-18-zlibinflate/)

I have added color routines for RGB and RGBA images but as of now not those indexed to a palette chunk. For 0.6.2a I'll optimize light placement and significantly jack performance by analyzing brightmaps. These grayscale PNGs are quite interesting. For example:
Code: Select all
compute2 width 256 height 56 color_type 0 bit_depth 8 filter_method 0 interlace method 0
compute2 color 171 171 171 percent 0.194959
lite2 width 64 height 128 color_type 0 bit_depth 8 filter_method 0 interlace method 0
lite2 color 214 214 214 percent 12.260722
lite3 width 32 height 128 color_type 0 bit_depth 8 filter_method 0 interlace method 0
lite3 color 162 162 162 percent 38.383838
doorblu width 8 height 128 color_type 0 bit_depth 8 filter_method 0 interlace method 0
doorblu color 138 138 138 percent 2.767528

"Soon."

-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
ReLite Progress 0.6.2a
Progress 0.6.2a
0.6.1a places texture lights according to brightmaps and adds exclusions based on geometry and brightness of the color. This causes a lot of areas, such as the secret room to the right at the start of E1M2, to look bizarrely bright. Because this included all colors I also added an exclusion for texture colorization.
0.6.2a adds reading a brightmap before accepting flat or texture as a light source as described above. I've added criteria based on percentage brightened and/or how bright. I've removed all exclusions for placement and added bottom side tier placement. I've removed all colorization exclusions. So far this has improved visuals and significantly improved performance. Since this lowers the number of light sources, it makes those remaining cast greater shadows in some cases. Here are screenshots:
e1m7
e1m7
e2m5
e3m5
Still testing.
Code: Select all
0.6.2
10/13 - fixed truncated double in shadow code
10/14 - added sprite color to decorative light routine
10/14 - exclude self as light source in shadow code
10/17 - added hd_png class to identify PNG images
10/20 - added converted Python zlib.decompress() for PNG pixel data (https://pyokagan.name/blog/2019-10-18-zlibinflate/)
10/22 - added brightmap exclusion criteria
10/22 - removed placement and colorizing exclusions
0.6.2a adds reading a brightmap before accepting flat or texture as a light source as described above. I've added criteria based on percentage brightened and/or how bright. I've removed all exclusions for placement and added bottom side tier placement. I've removed all colorization exclusions. So far this has improved visuals and significantly improved performance. Since this lowers the number of light sources, it makes those remaining cast greater shadows in some cases. Here are screenshots:
e1m7
e1m7
e2m5
e3m5
Still testing.

-
- Posts: 19
- Joined: Sun Nov 27, 2022 9:35 am
Re: ReLite
The screenshots look wonderful, your work on this mod is truly impressive. Looking forward to the next update!
-
- Posts: 455
- Joined: Tue Oct 18, 2022 1:59 am
- Operating System Version (Optional): Windows 11
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
ReLite Progress 0.6.2a
More Progress 0.6.2a
Still working on this. Removing restrictions such as where lights are placed and what walls are colorized, for example, exposed several interesting problems. For now I've trashed 90% of the menu in favor of hard coded numbers for color interpretation, removed recursion to always find a color, and other color tweaks. Most if not all restrictions have been removed. I've corrected the shade function to always return the same hue (a significant error from the first Relighting).
One thing I've done for shadows is corrected lighting for those actors cast in their own shadow. This can be seen in these two gifs:
e3m5
map01
Rather than dynamic lighting brilliantly lighting sprites from any angle, sprite lighting now depends on how light hits it. This simple effect - no performance hit! - is far from perfect, as the shadow algorithm doesn't manage opposing light sources; for performance reasons shadows use the closest light source. I'll have a look at that. But you can see the effect very clearly in MAP01.
The darkness is just biased lighting. The only adjustment to sector lighting now is to brighten sectors where a ceiling light source exists. It's surprising that bias lighting has this impact, but many areas of the game are quite dark. I'll have a look at that as well. Haven't decided what to expose on the menu, but it will be minimal.
Many many thanks for your interest and comments! I appreciate it!!
Release "soon."
Code: Select all
0.6.2
10/13 - fixed truncated double in shadow code
10/14 - added sprite color to decorative light routine
10/14 - exclude self as light source in shadow code
10/17 - added hd_png class to identify PNG images
10/20 - added converted Python zlib.decompress() for PNG pixel data (https://pyokagan.name/blog/2019-10-18-zlibinflate/)
10/22 - added brightmap exclusion criteria
10/22 - removed placement and colorizing exclusions
10/22 - corrected casting sprites in shadow
10/23 - corrected shade() function to keep same hue
10/23 - excluded light source textures from colorization
One thing I've done for shadows is corrected lighting for those actors cast in their own shadow. This can be seen in these two gifs:
e3m5
map01
Rather than dynamic lighting brilliantly lighting sprites from any angle, sprite lighting now depends on how light hits it. This simple effect - no performance hit! - is far from perfect, as the shadow algorithm doesn't manage opposing light sources; for performance reasons shadows use the closest light source. I'll have a look at that. But you can see the effect very clearly in MAP01.
The darkness is just biased lighting. The only adjustment to sector lighting now is to brighten sectors where a ceiling light source exists. It's surprising that bias lighting has this impact, but many areas of the game are quite dark. I'll have a look at that as well. Haven't decided what to expose on the menu, but it will be minimal.
Many many thanks for your interest and comments! I appreciate it!!
Release "soon."

-
- Posts: 20
- Joined: Sat Nov 12, 2022 11:12 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: nVidia with Vulkan support
Re: ReLite
A ReLite Enjoyer be like: I'm waiting for 0.6.2a relite! 

-
- Posts: 43
- Joined: Mon May 15, 2023 12:13 am
- Preferred Pronouns: He/Him
- Operating System Version (Optional): Windows 10
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: ReLite Progress 0.6.2a
Wooooowwww!!!!
