summaryrefslogtreecommitdiff
path: root/src/vcr.c
diff options
context:
space:
mode:
authorVito Caputo <vcaputo@pengaru.com>2024-10-19 14:24:35 -0700
committerVito Caputo <vcaputo@pengaru.com>2024-10-19 14:24:35 -0700
commit2e99df641671941ab43823168a66e41c8d44aa36 (patch)
treec603e9c7b25d3c5fcdbf9bea20bfe22d0b74caf0 /src/vcr.c
parent585fd85cfb825e21112e1754a04d00999b3351b8 (diff)
charts/vcr: s/double/float/
Double precision is unnecessary for this, use floats throughout, at least for everything vmon related.
Diffstat (limited to 'src/vcr.c')
-rw-r--r--src/vcr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vcr.c b/src/vcr.c
index 6913a6a..9668d4d 100644
--- a/src/vcr.c
+++ b/src/vcr.c
@@ -1195,7 +1195,7 @@ void vcr_mark_finish_line(vcr_t *vcr, vcr_layer_t layer, int row)
*
* the only layers supported right now are grapha/graphb
*/
-void vcr_draw_bar(vcr_t *vcr, vcr_layer_t layer, int row, double t, int min_height)
+void vcr_draw_bar(vcr_t *vcr, vcr_layer_t layer, int row, float t, int min_height)
{
int height, y = row * VCR_ROW_HEIGHT;
@@ -1208,7 +1208,7 @@ void vcr_draw_bar(vcr_t *vcr, vcr_layer_t layer, int row, double t, int min_heig
if ((row + 1) * VCR_ROW_HEIGHT >= vcr->height)
return;
- height = fabs(t) * (double)(VCR_ROW_HEIGHT - 1);
+ height = fabsf(t) * (float)(VCR_ROW_HEIGHT - 1);
if (height < min_height)
height = min_height;
© All Rights Reserved