From efe7768e5b65022b2dd418feff017b97012a6b24 Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 13 Jul 2020 09:33:38 +0800 Subject: *misc --- src/shaders/pbr.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/shaders/pbr.c') diff --git a/src/shaders/pbr.c b/src/shaders/pbr.c index bbf1c2b..b8ee4be 100644 --- a/src/shaders/pbr.c +++ b/src/shaders/pbr.c @@ -43,11 +43,12 @@ static bool frag(UniformCollection* uniforms, FragmentShaderIn* in, Vec4* color) //float rough = 1- internal_vec3_dot(&in->normal, light); float depth = _clip_pos->x / _clip_pos->y; depth = (depth + 1) / 2; - depth = linear01depth(depth); + depth = linear01Depth(depth); Vec4 c = tex2d(_albedo_tex, _texcoord); //Color32 nc = tex2d(noramltex, in->texcoord); //internal_vec3_scale(&c, roughness, &c); *color = vec4_saturate(c); + //*color = vec4(depth, depth, depth, 1); //internal_vec3_scale(color, 1 - depth, color); return 1; } -- cgit v1.1-26-g67d0