From aad1e793acebb3f40aaea17a7febf323fc797373 Mon Sep 17 00:00:00 2001 From: Yu-Jie Lin Date: Tue, 5 May 2015 08:49:22 +0800 Subject: [PATCH] fix max bars when starting with -S then toggle with s key, use to mark keys. (#22) --- README.md | 4 ++-- cava.c | 8 +++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 8aadb9a..0b5dc96 100644 --- a/README.md +++ b/README.md @@ -217,5 +217,5 @@ If cava quits unexpectedly or is force killed, echo must be turned on manually w | Key | Description | | --- | ----------- | -| `s` | Toggle Scientific mode | -| `q` or `CTRL-C`| Quit C.A.V.A. | +| s | Toggle Scientific mode | +| q or CTRL-C| Quit C.A.V.A. | diff --git a/cava.c b/cava.c index 1e0f065..591c4ca 100644 --- a/cava.c +++ b/cava.c @@ -461,11 +461,9 @@ Options:\n\ #endif bw = width / bands; - if (!smode) - { - g = ((float)height / 1000) * pow((60 / (float)framerate), - 2.5); //calculating gravity - } + //calculating gravity + g = ((float)height / 1000) * pow((60 / (float)framerate), 2.5); + //if no bands are selected it tries to padd the default 20 if there is extra room if (autoband == 1) bands = bands + (((w.ws_col) - (bw * bands + bands - 1)) / (bw + 1));