View Issue Details

IDProjectCategoryView StatusLast Update
0006306The Dark ModCodingpublic05.12.2023 02:08
Reporterstgatilov Assigned Tostgatilov  
PrioritynormalSeveritynormalReproducibilityN/A
Status resolvedResolutionfixed 
Product VersionTDM 2.11 
Target VersionTDM 2.12Fixed in VersionTDM 2.12 
Summary0006306: Deprecate parallel lights
DescriptionParallel lights from Doom 3 are broken garbage regarding its behavior with areas and portals.
It is used in 40 missions, so we cannot fix it now.
And people still use it in new missions, while parallelSky was supposed to become alternative.

We should deprecate old parallel lights and print dmap warnings for them.
Mappers should be informed that they should use parallelSky lights for more-or-less defines behavior.

Aside from that, parallelSky light should be updated to work properly for local parallel lights.
Right now it only works with global lights like moonlight, because light volume/boundaries are ignored.
Additional Informationhttps://forums.thedarkmod.com/index.php?/topic/22149-parallel-lights-usage/
https://forums.thedarkmod.com/index.php?/topic/22148-ugly-scissoring-with-parallel-lights/&do=findComment&comment=486548
TagsNo tags attached.

Relationships

related to 0005172 resolvedstgatilov Improve interaction culling: case when player-visible object is not visible from light 
related to 0005121 resolvedstgatilov Convenient parallel light for moon or sun 

Activities

stgatilov

stgatilov

24.06.2023 17:58

administrator   ~0016030

Found one more major bug in portal-area code for parallel lights.
To workaround it, the light origin can be placed into a void/wall (i.e. outside playable areas).
Now it should make no harm even if light origin is in area.
  r10430 Disabled connectivity check for parallelSky lights in idRenderWorldLocal::AddAreaLightRefs (controlled by r_useLightAreaCulling).

And some minor changes:
  r10428 Optimized CheckAreaForPortalSky method slightly.
  r10432 Improved logic for getting start areas for light portal flow in case of parallelSky light.
The latest commit should improve situation for local shadowing lights, but in practice they are doomed anyway.
stgatilov

stgatilov

22.07.2023 14:13

administrator   ~0016042

Added deprecation warning in dmap in svn rev 10438.

For anyone coming here due to the warning, this video briefly shows why local shadow-casting parallel lights is a very bad idea:
  https://youtu.be/q3VLMUCbXx4

You should also read the whole thread:
  https://forums.thedarkmod.com/index.php?/topic/22149-parallel-lights-usage/

As of now, the wiki article about parallelSky lights is here:
  https://wiki.thedarkmod.com/index.php?title=Light_Properties#Parallel-sky_light

Note that using parallelSky light has some specific requirements.
You should make sure every outdoors area has portalsky-textured surfaces on its boundary.
Note that parallelSky light respects visportals, so it does not magically pierce caulk to get from one visarea to another.

Issue History

Date Modified Username Field Change
22.06.2023 06:33 stgatilov New Issue
22.06.2023 06:33 stgatilov Status new => assigned
22.06.2023 06:33 stgatilov Assigned To => stgatilov
22.06.2023 06:33 stgatilov Relationship added related to 0005172
22.06.2023 06:34 stgatilov Relationship added related to 0005121
24.06.2023 17:58 stgatilov Note Added: 0016030
24.06.2023 18:07 stgatilov Additional Information Updated
22.07.2023 14:13 stgatilov Note Added: 0016042
22.07.2023 14:13 stgatilov Status assigned => feedback
05.12.2023 02:08 nbohr1more Status feedback => resolved
05.12.2023 02:08 nbohr1more Resolution open => fixed
05.12.2023 02:08 nbohr1more Fixed in Version => TDM 2.12