ogl_beamforming

Ultrasound Beamforming Implemented with OpenGL
git clone anongit@rnpnr.xyz:ogl_beamforming.git
Log | Files | Refs | Feed | Submodules | LICENSE

Commit: abd9e92b9fc0964561f1dffc30964431c29bbe0c
Parent: d6e1c420bb9429c530ba9d57f53c54e3374696f1
Author: Randy Palamar
Date:   Wed, 26 Jun 2024 13:31:28 -0600

increase local size of min max shader

This improves the speed of the lower mip map levels at the expense
of some (possibly) useless computation for the higher levels.

Diffstat:
Mbeamformer.c | 2+-
Mshaders/min_max.glsl | 2+-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/beamformer.c b/beamformer.c @@ -40,7 +40,7 @@ do_compute_shader(BeamformerCtx *ctx, u32 rf_ssbo_idx, enum compute_shaders shad u32 width = ctx->out_data_dim.w >> i; u32 height = ctx->out_data_dim.h >> i; u32 depth = ctx->out_data_dim.d >> i; - glDispatchCompute(ORONE(width), ORONE(height), ORONE(depth)); + glDispatchCompute(ORONE(width / 32), ORONE(height / 32), ORONE(depth)); glMemoryBarrier(GL_SHADER_IMAGE_ACCESS_BARRIER_BIT); } break; diff --git a/shaders/min_max.glsl b/shaders/min_max.glsl @@ -3,7 +3,7 @@ /* NOTE: Does a binary search in 3D for smallest and largest output values */ #version 460 core -layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in; +layout(local_size_x = 32, local_size_y = 32, local_size_z = 1) in; layout(rg32f, location = 1) uniform image3D u_out_data_tex; layout(rg32f, location = 2) uniform image3D u_mip_view_tex;