Hi,
In development of high visibility config for q3a i came across this thread http://esreality.com/post/1950022/high-visibility-config-post-yours/ and inspired particularly by this screenshoot: http://esreality.com/post/1950022/high-visibility-config-post-yours/#pid2093767 i came with idea of implementing such a feature into ioq3 engine. There is already ability to apply grayscale for whole screen, but what if we could apply it only to map layer? (lights/textures/shaders). All layers except hud, models and map entities. It would imho greatly improve visibility and decrease amount of distractions caused by colourfull chaos on some bight maps. Especially for those, who don’t want to (uglyfy) blur textures with picmip (i hate that) and plays with little white dot as crosshair.
I did some resarch and was able to implement grayscale conversion, basing on implementation of mapOverBrightBits. So i would like to add new cvar r_mapGrayScaleLevel with float value between 0-1. 0 (default) means no transformation applied, 1 means full grayscale conversion computed as: RED_WEIGHT * r + GREEN_WEIGTH * g + BLUE_WEIGHT * b (RED_WEIGHT = 0.299; GREEN_WEIGTH = 0.587; BLUE_WEIGHT = 0.114;). Value between 0 and 1 - higher the value is, closer the channels to common gray are. Conversion would be applied just after mapOverBrightBits in R_ColorShiftLightingBytes/R_ColorShiftLightingFloats in renderergl2/tr_bsp.c and R_ColorShiftLightingBytes in renderergl1/tr_bsp.c.
Diffrence is already significant on most maps, as you can see on screenshots.
If this discussion goes well, i would like to contribute and make a pull request on github.
Take a look:
(value of 2 gives only red channel, so i can show, what map areas are actually affected. It’s for testing purposes and won’t be available in final patch.)
I would like to know opinions on that feature and possible implementation.