summaryrefslogtreecommitdiff
path: root/src/powerlist.h
diff options
context:
space:
mode:
authorChristian Glöckner <cgloeckner@freenet.de>2016-03-29 17:30:15 +0200
committerAndré Nusser <andre.nusser@googlemail.com>2016-03-31 17:48:37 +0200
commit852b31481189d6ff9e490533a598ee5154a044f5 (patch)
treecb950ce71f9c5ae35460d7c6d96ad622d7a61e21 /src/powerlist.h
parente03a52fe134e386c543bc1a83e21114ecedb7561 (diff)
Reformatted class PowerList
Diffstat (limited to 'src/powerlist.h')
-rw-r--r--src/powerlist.h39
1 files changed, 19 insertions, 20 deletions
diff --git a/src/powerlist.h b/src/powerlist.h
index 1077d8c..a3af475 100644
--- a/src/powerlist.h
+++ b/src/powerlist.h
@@ -24,38 +24,37 @@
* along with DrumGizmo; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#ifndef __DRUMGIZMO_POWERLIST_H__
-#define __DRUMGIZMO_POWERLIST_H__
+#pragma once
#include <vector>
#include "sample.h"
#include "random.h"
-class PowerList {
+class PowerList
+{
public:
- PowerList();
+ PowerList();
- void add(Sample *s);
- void finalise(); ///< Call this when no more samples will be added.
+ void add(Sample* s);
+ void finalise(); ///< Call this when no more samples will be added.
- Sample *get(level_t velocity);
+ Sample* get(level_t velocity);
private:
- class PowerListItem {
- public:
- Sample *sample;
- float power;
- };
+ class PowerListItem
+ {
+ public:
+ Sample* sample;
+ float power;
+ };
- Random rand;
+ Random rand;
- std::vector<PowerListItem> samples;
- float power_max;
- float power_min;
+ std::vector<PowerListItem> samples;
+ float power_max;
+ float power_min;
- Channel *getMasterChannel();
- Sample *lastsample;
+ Channel* getMasterChannel();
+ Sample* lastsample;
};
-
-#endif/*__DRUMGIZMO_POWERLIST_H__*/