Open kai-li-wop opened 1 month ago
I looked into this a month ago and I don't know what's going on with the shadows. Rotating the player left/right rotates the shadows in front of you like a clock. Wrong shadow projection/axis maybe? I don't really know how the shadow mapping works.
However it seems like all the glass shaders have a lightmap stage and surfaceParm nolightmaps
. I think nolightmaps forces lightmapIndex to LIGHTMAP_BY_VERTEX which uses white image for lightmap? The opengl2 renderer could probably disable sun shadows on shaders with surfaceParm nolightmaps
(or possibly negative lightmapIndex) to fix the issue. I haven't got round to specifically testing and committing a solution to ioquake3 though.
One very strange thing is that the skybox gets shadows, but only when looking through a glass shader. Since WoP works a lot with glass shaders, I think this affects the user experience a lot when using the OpenGL2 renderer. Screenshots are take from PadShip but it also occurs in many other maps like CybJourney. Maybe @zturtleman could have a look because this should also appear with ioquake3. See example shader how it is used in PadShip to create the glass effect.