From b57f03f96302e53aaa8239f19fe11bd60fb31fde Mon Sep 17 00:00:00 2001 From: Wirlaburla Date: Mon, 26 Feb 2024 20:16:24 -0600 Subject: [PATCH] Alter Pattern VU meters --- src/main.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index 8188a2d..3fcdd79 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -493,17 +493,17 @@ void displayPatterns(xmp_module_info *mi, xmp_frame_info *fi) { wmove(dis, 0, cxpos); for (int i = 0; i < mi->mod->chn; i++) { struct xmp_channel_info cinfo = fi->channel_info[i]; - int voll = (cinfo.volume * (256-cinfo.pan)/256)*2; - if (voll >= 64) wattron(dis, volhi); + int voll = (cinfo.volume * (256-cinfo.pan)/256); + if (voll >= 48) wattron(dis, volhi); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, volhi); - if (voll >= 48) wattron(dis, volmd); + if (voll >= 32) wattron(dis, volmd); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, volmd); - if (voll >= 32) wattron(dis, vollo); + if (voll >= 16) wattron(dis, vollo); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, vollo); - if (voll >= 16) wattron(dis, vollo); + if (voll >= 8) wattron(dis, vollo); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, vollo); if (voll > 0) wattron(dis, vollo); @@ -520,20 +520,20 @@ void displayPatterns(xmp_module_info *mi, xmp_frame_info *fi) { mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, chnvw); - int volr = (cinfo.volume * cinfo.pan/256)*2; + int volr = (cinfo.volume * cinfo.pan/256); if (volr > 0) wattron(dis, vollo); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, vollo); + if (volr >= 8) wattron(dis, vollo); + mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); + wattroff(dis, vollo); if (volr >= 16) wattron(dis, vollo); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, vollo); - if (volr >= 32) wattron(dis, vollo); - mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); - wattroff(dis, vollo); - if (volr >= 48) wattron(dis, volmd); + if (volr >= 32) wattron(dis, volmd); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, volmd); - if (volr >= 64) wattron(dis, volhi); + if (volr >= 48) wattron(dis, volhi); mvwaddch(dis, 0, (cxpos++)-hOffset, ' '); wattroff(dis, volhi);