diff options
| author | Sam Anthony <sam@samanthony.xyz> | 2025-05-02 20:54:00 -0230 |
|---|---|---|
| committer | Sam Anthony <sam@samanthony.xyz> | 2025-05-02 20:54:00 -0230 |
| commit | e977059a478178101eda2e6771d52f21b135248c (patch) | |
| tree | cfc1d592479cd4bc030041dcf106a224a65fa91c /main.c | |
| parent | 08ddaa509e254c335a13417b157d4da23ea9314b (diff) | |
| download | volute-e977059a478178101eda2e6771d52f21b135248c.zip | |
select compressor map
Diffstat (limited to 'main.c')
| -rw-r--r-- | main.c | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -12,6 +12,7 @@ #include "engine.h" #include "ui.h" #include "color.h" +#include "eprintf.h" /* Macros. */ @@ -386,8 +387,14 @@ mass_flow_rate_corrected_row(mu_Context *ctx, UI *ui) { static void comp_select(mu_Context *ctx, UI *ui) { + const Compressor *comp; + if (w_select_compressor(ctx, &ui->comp_select) & MU_RES_CHANGE) { - /* TODO */ + comp = &ui->comps[ui->comp_select.idx]; + if (w_canvas_set_bg(&ui->comp_img, comp->imgfile) != 0) { + weprintf("failed to set compressor image: %s", comp->imgfile); + } + compute_all(ui); } } |