-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBlockDistortion.hpp
40 lines (35 loc) · 971 Bytes
/
BlockDistortion.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//
// BlockDistortion.hpp
// AudioComponents
//
// Created by Aaron Dawson on 9/20/16.
//
//
#ifndef BlockDistortion_hpp
#define BlockDistortion_hpp
#include <stdio.h>
#include "BlockEffect.hpp"
#include "Distortion.hpp"
#include "SymmetricalSoftClip.hpp"
typedef enum DistortionType {
DISTORTION,
SYMMETRICAL_SOFT_CLIP
} DistortionType;
class BlockDistortion : public BlockEffect {
public:
BlockDistortion(DistortionType distortionType) {
this->distortionType = distortionType;
distortionLeft = new Distortion(100.0);
distortionRight = new Distortion(100.0);
sscLeft = new SymmetricalSoftClip();
sscRight = new SymmetricalSoftClip();
}
double** process(double** outBlock, int blockSize);
private:
Distortion* distortionLeft;
Distortion* distortionRight;
SymmetricalSoftClip* sscLeft;
SymmetricalSoftClip* sscRight;
DistortionType distortionType;
};
#endif /* BlockDistortion_hpp */