fgsfdsfgs / perfect_dark

work in progress port of n64decomp/perfect_dark to modern platforms
MIT License
1.2k stars 74 forks source link

Always enable texture filtering for reflection maps #362

Open tunbridgep opened 8 months ago

tunbridgep commented 8 months ago

General reflections (like the reflective floors in the Carrington Institute) look fine, but "window reflections" look absolutely horrible.

Sorry I don't really know how to describe it, see the attached screenshot for an example image

When texture filtering is disabled, textures that are used for reflections like this should still be filtered, so that the reflections don't look blocky with huge white splodges and instead give blurred reflections as desired.

tunbridgep commented 8 months ago

Even worse example here: image image

fgsfdsfgs commented 8 months ago

I feel obligated to point out that you yourself made the decision to disable texture filtering in a game where almost all textures are meant to be filtered, reflections probably above all. This can be "fixed", but to force filtering on specifically the reflection maps would require me to rework how the filtering toggle works a bit.

tunbridgep commented 8 months ago

I understand that it was my decision.

However, I would also like to point out that it's an option offered by the port, I didn't have to go modifying any config files or using hacky workarounds, so it would be nice for it to work "as expected" out of the box. I understand this behaviour is technically correct, I just feel it could maybe benefit from this modification to make it look nicer overall.

It's kind of a shame that so many games of the era were designed around blurry textures. The pixelated/unfiltered look actually looks really crisp and nice in my opinion, not just in PD but in many other games of that era. It's just a shame that it often comes with side-effects.

I just checked, Half-Life also seems to filter some textures regardless of the texture filtering setting, like the sky, so I guess other games that support unfiltered textures also make some exceptions.

I would recommend not filtering reflection textures and sky textures.

image

tunbridgep commented 8 months ago

Just one more thing that came to mind. The gas texture that covers the screen in Area 51 also needs to be filtered.

fgsfdsfgs commented 8 months ago

This doesn't really matter, but skyboxes are likely not affected by gl_texturemode in HL because either of an oversight or a technical limitation. Note that the reflection map on the gloves is not filtered, for example.

tunbridgep commented 8 months ago

Fair enough. I guess the effect textures in PD aren't really high enough quality to really work unfiltered, unlike Half-Life where they seem to render a bit better. I guess if it's not directly used on a wall or floor or model, it's an effect (reflections, light blooms, etc), and would probably look better filtered, just because of how low-res they end up being otherwise.