Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 876efb2e8f | |||
| 3b09077e4c | |||
| b57095ead6 | |||
| b57f03f963 |
16
aur/PKGBUILD
16
aur/PKGBUILD
@@ -1,12 +1,12 @@
|
||||
# Maintainer: wirlaburla <wirlaburla@worlio.com>
|
||||
# Maintainer: Nick G. <wirlaburla@worlio.com>
|
||||
|
||||
pkgname=trakker-git
|
||||
pkgver=0.3.0.r1.ge275e29
|
||||
pkgver=0.5.1
|
||||
pkgrel=1
|
||||
pkgdesc=''
|
||||
arch=('x86_64' 'aarch64')
|
||||
url='https://codeberg.org/Wirlaburla/trakker'
|
||||
license=(GPL3)
|
||||
pkgdesc='A terminal-based tracker interface for libxmp.'
|
||||
arch=('x86_64')
|
||||
url='https://git.worlio.com/Wirlaburla/trakker'
|
||||
license=('GPL3')
|
||||
depends=('alsa-lib' 'libxmp' 'ncurses')
|
||||
makedepends=('git' 'cmake')
|
||||
provides=('trakker')
|
||||
@@ -15,8 +15,8 @@ source=("$pkgname::git+$url.git#branch=master")
|
||||
sha256sums=('SKIP')
|
||||
|
||||
pkgver() {
|
||||
cd $pkgname
|
||||
git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
|
||||
cd "$pkgname"
|
||||
git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
|
||||
}
|
||||
|
||||
prepare() {
|
||||
|
||||
44
src/main.cpp
44
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);
|
||||
|
||||
@@ -621,12 +621,24 @@ void displayVolumes(xmp_module_info *mi, xmp_frame_info *fi) {
|
||||
void displayNoteRoll(xmp_module_info *mi, xmp_frame_info *fi) {
|
||||
int ins = mi->mod->ins;
|
||||
chtype no_pair = COLOR_PAIR(5);
|
||||
if (dynamicRoll) {
|
||||
for (int l = 0; l < (96/12); l++) {
|
||||
int cnote = (l*12);
|
||||
if (cnote < prMin && l == (prMin / 12)) {
|
||||
wmove(dis, 0, 0);
|
||||
wprintw(dis, "<%i", l);
|
||||
} else if (cnote <= prMax && cnote >= prMin) {
|
||||
wmove(dis, 0, (((cnote - prMin) * (COLS - 5)) / (prMax - prMin))+3);
|
||||
wprintw(dis, "%i", l);
|
||||
}
|
||||
}
|
||||
}
|
||||
for (int y = vOffset; y < ins; y++) {
|
||||
if (!dynamicRoll) { prMin = 0; prMax = 144; }
|
||||
if (y > (LINES - 5)+vOffset || y < 0) continue;
|
||||
wmove(dis, y-vOffset, 0);
|
||||
wmove(dis, (y-vOffset)+1, 0);
|
||||
wattron(dis, no_pair);
|
||||
wprintw(dis, "%02X", y);
|
||||
wprintw(dis, "%02X", y+1);
|
||||
wattroff(dis, no_pair);
|
||||
wclrtoeol(dis);
|
||||
for (int c = 0; c < mi->mod->chn; c++) {
|
||||
@@ -642,12 +654,12 @@ void displayNoteRoll(xmp_module_info *mi, xmp_frame_info *fi) {
|
||||
int note = ((cinfo.note - prMin) * (COLS - 5)) / (dynamicRoll?(prMax - prMin):96);
|
||||
if (cinfo.instrument != y) continue;
|
||||
|
||||
wmove(dis, y-vOffset, note+3);
|
||||
wmove(dis, (y-vOffset)+1, note+3);
|
||||
if (cinfo.volume >= 32)
|
||||
waddstr(dis, "#");
|
||||
else if (cinfo.volume >= 16 && (char)mvwinch(dis, y-vOffset, note+3) != '#')
|
||||
else if (cinfo.volume >= 16 && (char)mvwinch(dis, (y-vOffset)+1, note+3) != '#')
|
||||
waddstr(dis, "=");
|
||||
else if (cinfo.volume > 0 && ((char)mvwinch(dis, y-vOffset, note+3) != '-' || (char)mvwinch(dis, y-vOffset, note+3) != '#'))
|
||||
else if (cinfo.volume > 0 && ((char)mvwinch(dis, (y-vOffset)+1, note+3) != '-' || (char)mvwinch(dis, (y-vOffset)+1, note+3) != '#'))
|
||||
waddstr(dis, "-");
|
||||
}
|
||||
wmove(dis, y, COLS-4);
|
||||
|
||||
Reference in New Issue
Block a user