jdolan / quetoo

Quetoo ("Q2") is a free first person shooter based on id Tech2. GPL v2 license.
http://quetoo.org
204 stars 28 forks source link

Terrain and dirtmap stages do not blend correctly #637

Closed jdolan closed 2 years ago

jdolan commented 3 years ago

I have temporarily disabled material blending for dirtmap and terrain stages with 0469f5ba5955d3ae12155e4c584a54a787e29cac. So dirtmap and terrain stages are instead just using simple, single-texture blending. It'd be nice if we had proper lighting (per pixel + dynamic) on them. However, this doesn't work as-is. It seems like blend is not enabled, or the correct blend function is not set, or the shader is not expecting blend in STAGE_MATERIAL passes (tho that works for alpha blended draw elements...).

The rockies on Edge are a good test bed for this. The material file specifies dirtmapping, and can take a terrain blend as well.

jdolan-chwy commented 2 years ago

@SpineyPete or @Paril this might be a layup for you. I'm not as smrt at teh maths.

jdolan commented 2 years ago

Whatever was broken here has been fixed. Tested both dirtmap and terrain on Edge's mossy rocks and they both look 👌