forked from ChrisVeigl/BrainBay
-
Notifications
You must be signed in to change notification settings - Fork 1
/
ob_filter.h
71 lines (49 loc) · 1.88 KB
/
ob_filter.h
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
59
60
61
62
63
64
65
66
67
68
69
70
71
/* -----------------------------------------------------------------------------
BrainBay Version 1.7, GPL 2003-2010, GPL, contact: chris@shifz.org
OB_FILTER.H: contains the FILTER-Object
Authors: Jim Peters, Chris Veigl
This module calls into the fid-lib filter library by Jim Peters to provide
filter functionalities. The Filter-Type and order can be selected.
A brief preview of the filter's frequency-response is shown in the
filter-toolbox-window. For a better display check out Jim Peters fiview-tool:
http://uazu.net/fiview
do_filt_design: Initialises a new filter using the init-String
(for exemple LpBe for a low-pass - bessel filter, see fiview-documentation)
and additional filter-parameters (like order, from-, to-freqeuncy)
update_filterdialog: enables/disables init-parameters according to the filter-type
FilterBoxDlgHandler: processes events for the filter-toolbox window.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; See the
GNU General Public License for more details.
-----------------------------------------------------------------------------*/
#include "brainBay.h"
// from OB_FILTER.CPP :
LRESULT CALLBACK FilterboxDlgHandler(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
class FILTEROBJ : public BASE_CL
{
protected:
DWORD dwRead,dwWritten;
public:
float input;
char name[25];
int filtertype;
int par0;
float par1;
float par2;
int dispfrom,dispto;
FidFilter *filt;
FidFunc *funcp;
FidRun *run;
void * fbuf;
FILTEROBJ(int num);
void make_dialog(void);
void session_start(void);
void session_reset(void);
void session_pos(long pos);
void load(HANDLE hFile);
void save(HANDLE hFile);
void incoming_data(int port, float value);
void work(void);
~FILTEROBJ();
};