path: root/apps/recorder/peakmeter.h
diff options
authorJens Arnold <>2005-08-29 20:07:17 +0000
committerJens Arnold <>2005-08-29 20:07:17 +0000
commit99a0598c284471342fcda1fdcba90d4b666bfbb3 (patch)
tree83cc502095e87277de770456498d2de6cf8f473b /apps/recorder/peakmeter.h
parent89a8ca4408c3ea34464898b0ce52a0d8351fa323 (diff)
Major peakmeter rework: * Changed set/get functions for dbfs mode to bool type. * Removed performance setting, leaving (slightly adapted) high performance mode only. * Refresh rate is always 20 Hz now. * Readout doesn't do an extra (hidden) peek, should allow for slightly better clip detection. * Brought back high performance peakmeter for recording. Peakmeter stops hogging the CPU when the disk is spinning; this is enough to avoid the performance problem when saving data. * Optimisations, code cleanup and code policeing. * (iriver) Reduced CPU load of peakmeter by not calculating excessive overlaps. ** Bumped config block version, so save your settings before upgrading.
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/recorder/peakmeter.h')
1 files changed, 4 insertions, 3 deletions
diff --git a/apps/recorder/peakmeter.h b/apps/recorder/peakmeter.h
index 3c0a28bf3b..5513dfacf1 100644
--- a/apps/recorder/peakmeter.h
+++ b/apps/recorder/peakmeter.h
@@ -19,13 +19,14 @@
#ifndef __PEAKMETER_H__
#define __PEAKMETER_H__
+#define PEAK_METER_FPS 20
/*#define PM_DEBUG */
#ifdef PM_DEBUG
extern bool peak_meter_histogram(void);
extern bool peak_meter_enabled;
-extern int peak_meter_fps;
extern void peak_meter_playback(bool playback);
extern void peak_meter_draw(int x, int y, int width, int height);
@@ -39,8 +40,8 @@ extern void peak_meter_set_min(int newmin);
extern int peak_meter_get_min(void);
extern void peak_meter_set_max(int newmax);
extern int peak_meter_get_max(void);
-extern void peak_meter_set_use_dbfs(int use);
-extern int peak_meter_get_use_dbfs(void);
+extern void peak_meter_set_use_dbfs(bool use);
+extern bool peak_meter_get_use_dbfs(void);
extern int calc_db (int isample);
extern int peak_meter_db2sample(int db);
extern unsigned short peak_meter_scale_value(unsigned short val, int meterwidth);