mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-11 15:21:51 +00:00
- some finetuning of subtractive effect.
This commit is contained in:
parent
8d08624f97
commit
d46315c44b
2 changed files with 2 additions and 1 deletions
|
@ -310,6 +310,7 @@ void GLSprite::Draw(int pass)
|
|||
gl_SetFog(foglevel, rel, &Colormap, additivefog);
|
||||
gl_RenderState.SetFixedColormap(CM_FOGLAYER);
|
||||
gl_RenderState.BlendEquation(GL_FUNC_ADD);
|
||||
gl_RenderState.BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||
gl_RenderState.Apply();
|
||||
|
||||
glBegin(GL_TRIANGLE_STRIP);
|
||||
|
|
|
@ -54,6 +54,6 @@ void main()
|
|||
fogfactor = exp2 (fogparm.z * fogdist);
|
||||
|
||||
vec4 frag = Process(vec4(1.0,1.0,1.0,1.0));
|
||||
gl_FragColor = vec4(fogcolor.rgb, (1.0 - fogfactor) * frag.a * 0.75);
|
||||
gl_FragColor = vec4(fogcolor.rgb, (1.0 - fogfactor) * frag.a * 0.75 * glColor.a);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue