 // 1 : Voxel Ambient Occlusion
 uniform int AmbientOcclusionMode;
 uniform vec3 CameraPosition;
+uniform float OcclusionFactor = 0.4;
 
 in vec4 ScreenPos;
 

  accum += 0.707 * VoxelConeTrace(origin.xyz, normalize(TBN[2] + TBN[1]), 1.0, maxDist);
  accum += 0.707 * VoxelConeTrace(origin.xyz, normalize(TBN[2] - TBN[1]), 1.0, maxDist);

  return 1.0 - accum.a;
}

float AmbientOcclusion(in Surface surface, in sampler3D SceneVoxelRep, in mat4 WorldToVoxelSpace)

  origin.xyz = (origin.xyz + 1) / 2.0;
  mat3 TBN = fakeTangentSpace(surface.Normal);

  const float coneRatio = 1.0;
  const float maxDist = 0.3;
  vec4 accum = vec4(0);
  accum += VoxelConeTrace(origin.xyz, TBN[2], coneRatio, maxDist);
