File: Sustainer.h

package info (click to toggle)
rakarrack 0.6.1-5
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster
  • size: 10,136 kB
  • sloc: cpp: 27,705; sh: 794; makefile: 377
file content (58 lines) | stat: -rw-r--r-- 1,498 bytes parent folder | download | duplicates (4)
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/*
  Rakarrack Guitar FX
 
  Sustainer.h - Simple compressor/sustainer effect with easy interface, minimal controls
  Copyright (C) 2010 Ryan Billing
  Author: Ryan Billing
  
  This program is free software; you can redistribute it and/or modify
  it under the terms of version 3 of the GNU General Public License 
  as published by the Free Software Foundation.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License (version 2) for more details.

  You should have received a copy of the GNU General Public License (version 2)
  along with this program; if not, write to the Free Software Foundation,
  Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA

*/

#ifndef SUSTAINER_H
#define SUSTAINER_H

#include "global.h"

class Sustainer
{
public:
  Sustainer (float * efxoutl_, float * efxoutr_);
  ~Sustainer ();
   void cleanup (); 
   
  void out (float * smpsl, float * smpr);
  void changepar (int npar, int value);
  int getpar (int npar);
  void setpreset (int npreset);

  int Ppreset;
  
  float *efxoutl;
  float *efxoutr;

private:
  //Parametrii
  int Pvolume;	//Output Level
  int Psustain;	//Compression amount

  int timer, hold;
  float level, fsustain, input,tmpgain;
  float prls, compeak, compg, compenv, oldcompenv, calpha, cbeta, cthresh, cratio, cpthresh;

  class FPreset *Fpre; 
};


#endif