summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/audioregion.h
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2016-07-24 20:28:56 +0200
committerRobin Gareus <robin@gareus.org>2016-07-24 20:30:23 +0200
commit23a2cc4b71845a61dcc01f5663dacd74f198f0c3 (patch)
tree53d0f0339617ef186f2bbd1966e61e63407decd3 /libs/ardour/ardour/audioregion.h
parent80bd3e7279626dfe3a65c4abbab93b68f1be99a7 (diff)
prepare region RMS (loudness) normalization
Diffstat (limited to 'libs/ardour/ardour/audioregion.h')
-rw-r--r--libs/ardour/ardour/audioregion.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/libs/ardour/ardour/audioregion.h b/libs/ardour/ardour/audioregion.h
index c3003e587b..d25cf0e421 100644
--- a/libs/ardour/ardour/audioregion.h
+++ b/libs/ardour/ardour/audioregion.h
@@ -82,8 +82,17 @@ class LIBARDOUR_API AudioRegion : public Region
gain_t scale_amplitude() const { return _scale_amplitude; }
void normalize (float, float target_in_dB = 0.0f);
+
+ /** @return the maximum (linear) amplitude of the region, or a -ve
+ * number if the Progress object reports that the process was cancelled.
+ */
double maximum_amplitude (Progress* p = 0) const;
+ /** @return the maximum (rms) signal power of the region, or a -1
+ * if the Progress object reports that the process was cancelled.
+ */
+ double rms (Progress* p = 0) const;
+
bool envelope_active () const { return _envelope_active; }
bool fade_in_active () const { return _fade_in_active; }
bool fade_out_active () const { return _fade_out_active; }