From cd3976c9e9cd0e463c69384598e114c2bee4701b Mon Sep 17 00:00:00 2001 From: divverent Date: Sat, 26 Jan 2008 15:06:01 +0000 Subject: [PATCH] update docs for dp_reflect, dp_refract, dp_water git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8015 d7cf8633-e32d-0410-b094-e92efae38249 --- darkplaces.txt | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/darkplaces.txt b/darkplaces.txt index 6ba53506..57e2dfda 100644 --- a/darkplaces.txt +++ b/darkplaces.txt @@ -1320,16 +1320,20 @@ Ludwig Nussel for the ~/.games/darkplaces/ user directory support on non-Windows Shader parameters for DP's own features: -- dp_reflect - Makes surfaces of this shader reflective with r_glsl_water. The reflection is - additive. When the color isn't specified, it defaults to white (full - reflection). If only one color component is specified, it counts as a grey - value. -- dp_refract - Marks a surface as "water" for r_glsl_water, that is, add a refraction - component too. The refraction amount (see dp_reflect) is at most refractmax - (when looking straight into it) and at least refractmin (when looking parallel - to the surface). The default distort is multiplied by distort. The color - modulates the refraction component. refractmin defaults to 0 when unspecified, - all others default to 1. If only one color component is specified, it counts - as a grey value. +- dp_reflect + Makes surfaces of this shader reflective with r_water. The reflection is + alpha blended on the texture with the given alpha, and modulated by the given + color. distort is used in conjunction with the normalmap to simulate a + nonplanar water surface. +- dp_refract + Makes surfaces of this shader refractive with r_water. The refraction + replaces the transparency of the texture. distort is used in conjunction with + the normalmap to simulate a nonplanar water surface. +- dp_water + This combines the effects of dp_reflect and dp_refract to simulate a water + surface. However, the refraction and the reflection are mixed using a Fresnel + equation that makes the amount of reflection slide from reflectmin when + looking parallel to the water to reflectmax when looking directly into the + water. The result of this reflection/refraction mix is then layered BELOW the + texture of the shader, so basically, it "fills up" the alpha values of the + water. -- 2.39.2