git-svn-id: svn://db.shs.com.ru/libs@65 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2015-12-09 15:44:03 +00:00
parent 64f21dc682
commit 458a516317
31 changed files with 1486 additions and 870 deletions

View File

@@ -5,7 +5,7 @@
in vec3 src_normal, normal, binormal;//, et;
in vec4 pos, ppos;
in float fogCoord, logz;
in float fogCoord, FC, C;
in mat3 TBN;
uniform bool acc_fog;
@@ -16,6 +16,7 @@ const vec3 luma = vec3(0.299, 0.587, 0.114);
void main(void) {
//float z = pos.w;//((z_near / (z_near-z_far)) * z_far) / (pos.w - (z_far / (z_far-z_near)));
float logz = log(pos.w * C + 1.) * FC;
vec4 dc = qgl_FragColor;
vec2 tc = qgl_FragTexture.xy;
float hei = dot(texture(qgl_Material.map_relief.map, tc).rgb, luma) * qgl_Material.map_relief.amount + qgl_Material.map_relief.offset;