This commit is contained in:
mcrcortex
2024-09-24 10:40:51 +10:00
parent 00cf0c73e3
commit 10391c48c7
3 changed files with 6 additions and 6 deletions

View File

@@ -82,7 +82,7 @@ bool isCulledByHiz() {
if (minBB.z < 0) {//Minpoint is behind the camera, its always going to pass
return false;
}
vec2 ssize = size.xy * vec2(ivec2(screenW, screenH));
vec2 ssize = size.xy * vec2(screenW, screenH);
float miplevel = ceil(log2(max(max(ssize.x, ssize.y),1)));
vec2 midpoint = (maxBB.xy + minBB.xy)*0.5f;
// printf("HiZ sample point culled: (%f,%f)@%f against %f", midpoint.x, midpoint.y, miplevel, minBB.z);

View File

@@ -8,9 +8,9 @@ layout(local_size_x=LOCAL_SIZE) in;//, local_size_y=1
layout(binding = SCENE_UNIFORM_BINDING, std140) uniform SceneUniform {
mat4 VP;
ivec3 camSecPos;
uint screenW;
float screenW;
vec3 camSubSecPos;
uint screenH;
float screenH;
uint renderQueueMaxSize;
float minSSS;
};