Minor voxel fix

This commit is contained in:
Lubos Lenco 2017-08-05 11:55:51 +02:00
parent 33d7bd04e7
commit 63fb40936f
4 changed files with 2 additions and 0 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 14 KiB

BIN
Assets/brdf_orig.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

@ -80,6 +80,7 @@ void main() {
float dotNV = max(dot(n, v), 0.0);
vec3 f0 = surfaceF0(g1.rgb, metrough.x);
vec2 envBRDF = texture(senvmapBrdf, vec2(metrough.y, 1.0 - dotNV)).xy;
// vec2 envBRDF = texture(senvmapBrdf, vec2(dotNV, metrough.y)).xy;
#endif
#ifdef _VoxelGI

View File

@ -63,6 +63,7 @@ def make(context_id):
# frag.write('float opacity;') #
frag.write_pre = True
frag.write('mat3 TBN;') # TODO: discard, parse basecolor only
frag.write('vec3 n;')
frag.write_pre = False
frag.write('float dotNV = 0.0;')
frag.write('float dotNL = max(dot(wnormal, l), 0.0);')