Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Many light sources appear to be missing. #21

Open
AmphetamineRush opened this issue Jan 23, 2019 · 2 comments
Open

Many light sources appear to be missing. #21

AmphetamineRush opened this issue Jan 23, 2019 · 2 comments

Comments

@AmphetamineRush
Copy link

After playing back and forth between this and the original, it looks like there's a lot of texture lights that aren't appearing as raycast light sources. Specfically it may be ones that have a lightmap animation or trigger. Also ones that are attached to moving objects like switches and lifts. Net result is that the game is pitch black in places that it shouldn't be and especially in some places where a switch should be the bright focal point of the room.

Thank you for releasing this btw, it's an amazing project.

Also is it possible to implement some sort of dynamic resolution support tied to a framerate target?

@cschied
Copy link
Owner

cschied commented Jan 23, 2019

Hi,

yes the heuristics for detecting light sources are not complete, unfortunately. It looks for some info in the bsp to detect lights but that seems to be missing a lot of them.
I therefore additionally added a list of textures to mark as lights:

/* we match on radiance in the bsp, unfortunately this

You can add additional textures there.

As for the dynamic bsp lights: The indices in the instance buffer need to be added to the light list here but for that to work as expected the bsp entity meshes need to be separated into lights and non-lights here

@AmphetamineRush
Copy link
Author

I'm no coder, unfortunately, but I did remember enough about Q2 level building to be able to decompile the base maps and take a look at them in GTKRadiant. That is when I realised that I'm wrong and all the missing lights are entity point lights. They're everywhere, little cheats to try and fake the look of natural lighting :(

In terms of lighting up dark places that don't have a surface light present, maybe make a function in Q2VKPT to apply a small decal light to the surface under the reticule and save the location information to an external file that can be distributed with the port?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants