mirror shader is too transparent with vertexlight
Posted: Sat Nov 25, 2006 12:32 am
Hi. Been a while since i played with radiant, but i have some free time and have been doodling. Here is a shader I modified using default textures.
textures/test2/sq_portal_sfx
{
surfaceparm nolightmap
portal
{
map textures/common/mirror1.tga
blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA
depthWrite
}
{
map textures/sfx/mirror.tga
blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA
depthfunc lequal
alphagen portal 1024
}
}
It works fine so long as r_vertexlight is set to 0. If set to 1, you can no longer tell there is a mirror there except from what you see in it. Any way of making this blendFunc show up regardless of the lighting method? Thanks in advance
textures/test2/sq_portal_sfx
{
surfaceparm nolightmap
portal
{
map textures/common/mirror1.tga
blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA
depthWrite
}
{
map textures/sfx/mirror.tga
blendFunc GL_SRC_ALPHA GL_ONE_MINUS_SRC_ALPHA
depthfunc lequal
alphagen portal 1024
}
}
It works fine so long as r_vertexlight is set to 0. If set to 1, you can no longer tell there is a mirror there except from what you see in it. Any way of making this blendFunc show up regardless of the lighting method? Thanks in advance