[vulkan] Add light count display

Enabled by 'developer lighting'. It was good for confirming that the
lights in ad_e1m1 (Doom Hangar 16) were actually being output (over 600
of them sometimes, ouch). Turned out to be the color scale ambiguity.
This commit is contained in:
Bill Currie 2022-05-27 10:19:15 +09:00
parent fb4bb22048
commit c6d73eaf64

View file

@ -52,7 +52,9 @@
#include "QF/va.h"
#include "QF/scene/scene.h"
#include "QF/ui/view.h"
#include "QF/Vulkan/qf_draw.h"
#include "QF/Vulkan/qf_lighting.h"
#include "QF/Vulkan/qf_texture.h"
#include "QF/Vulkan/barrier.h"
@ -118,6 +120,11 @@ update_lights (vulkan_ctx_t *ctx)
light->color[3] *= style_intensities[ldata->lightstyles.a[i]];
}
}
if (developer & SYS_lighting) {
Vulkan_Draw_String (vid.conview->xlen - 32, 8,
va (ctx->va_ctx, "%3d", light_data->lightCount),
ctx);
}
qfv_bufferbarrier_t bb = bufferBarriers[qfv_BB_Unknown_to_TransferWrite];
bb.barrier.buffer = lframe->light_buffer;