Skip to content

Commit

Permalink
clean up sigmund_tilde
Browse files Browse the repository at this point in the history
  • Loading branch information
v7b1 committed Jan 27, 2022
1 parent 7d68794 commit d9f6d5f
Showing 1 changed file with 5 additions and 25 deletions.
30 changes: 5 additions & 25 deletions source/projects/sigmund_tilde/sigmund_tilde.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,28 +25,9 @@ using namespace c74::max;

static t_class* sigmund_class = nullptr;


//#define MSP // compile a 64 bit version for MaxMSP

//
//#ifdef PD
//#include "m_pd.h"
//#endif
//#ifdef MSP
//#include "ext.h"
//#include "z_dsp.h"
//#include "ext_support.h"
//#include "ext_proto.h"
//#include "ext_obex.h"
typedef double t_samplearg;
typedef double t_sample;
#define PI M_PI
#define t_resizebytes(a, b, c) t_resizebytes((char *)(a), (b), (c))
//#endif

#ifdef _MSC_VER /* this is only needed with Microsoft's compiler */
__declspec(dllimport) extern
#endif

void mayer_realfft(int npoints, t_sample *buf);

/* this routine is passed a buffer of npoints values, and returns the
Expand Down Expand Up @@ -266,7 +247,7 @@ static void sigmund_remask(int maxbin, int bestindex, t_sample powmask,
#define PEAKTHRESHFACTOR 0.6


#pragma mark GET RAW PEAKS -------------
// GET RAW PEAKS -------------

static void sigmund_getrawpeaks(int npts, t_sample *insamps,
int npeak, t_peak *peakv, int *nfound, t_sample *power, t_sample srate, int loud,
Expand Down Expand Up @@ -809,7 +790,7 @@ static void notefinder_doit(t_notefinder *x, t_sample freq, t_sample power,


/**************** object structure for Pd and Max. *********************/
#pragma mark MSP+ Pd Object structure ---------

/* From here onward, the code is specific to eithr Pd, Max, or both. If
neither "PD 'nor "MSP" is defined, none of this is compiled, so that the
whole file can be included in other, non-PD and non-Max projects. */
Expand Down Expand Up @@ -997,7 +978,8 @@ static void sigmund_minpower(t_sigmund *x, t_samplearg f)
x->x_minpower = f;
}

#pragma mark DO THE WORK + OUTPUT -------
// DO THE WORK + OUTPUT -------

static void sigmund_doit(t_sigmund *x, int npts, t_sample *arraypoints,
int loud, float srate)
{
Expand Down Expand Up @@ -1063,7 +1045,6 @@ static void sigmund_doit(t_sigmund *x, int npts, t_sample *arraypoints,
}


#pragma mark DSP SETUP -------

// vb, 64-bit dsp method
void sigmund_perform64(t_sigmund *x, t_object *dsp64, double **ins, long numins,
Expand Down Expand Up @@ -1125,7 +1106,6 @@ static void sigmund_free(t_sigmund *x)


/************************ Max/MSP glue **********************************/
#pragma mark MSP GLUE --------------------

//static void *sigmund_class;

Expand Down

0 comments on commit d9f6d5f

Please sign in to comment.