File:  [RetroPC.NET] / np2 / sound / vermouth / midinst.h
Revision 1.5: download - view: text, annotated - select for diffs
Sun Dec 10 20:14:31 2006 JST (18 years, 10 months ago) by yui
Branches: MAIN
CVS tags: HEAD
update vermoth ver1.15


typedef SINT16	_SAMPLE;
typedef SINT16	*SAMPLE;

enum {
	MODE_16BIT		= 0x01,
	MODE_UNSIGNED	= 0x02,
	MODE_LOOPING	= 0x04,
	MODE_PINGPONG	= 0x08,
	MODE_REVERSE	= 0x10,
	MODE_SUSTAIN	= 0x20,
	MODE_ENVELOPE	= 0x40
};

typedef struct {
	int		sweep;
	int		step;
} INSTTRE;

typedef struct {
	int		sweep;
	int		rate;
} INSTVIB;

typedef struct {
	SAMPLE	data;
	int		loopstart;
	int		loopend;
	int		datasize;
	int		samprate;
	int		freqlow;
	int		freqhigh;
	int		freqroot;
	int		envratetbl[6];
	int		envpostbl[6];
	int		volume;
	int		tremolo_sweep;
	int		tremolo_step;
	int		vibrate_sweep;
	int		vibrate_rate;
	UINT8	tremolo_depth;
	UINT8	vibrate_depth;
	UINT8	mode;
	UINT8	panpot;
} _INSTLAYER, *INSTLAYER;

typedef struct {
	int			layers;
	int			freq;
} _INSTRUMENT, *INSTRUMENT;

struct _miditoneloadparam;

#ifdef __cplusplus
extern "C" {
#endif

int inst_singleload(MIDIMOD mod, UINT bank, UINT num);
int inst_bankload(MIDIMOD mod, UINT bank);
int inst_bankloadex(MIDIMOD mod, UINT bank, int (*cb)(struct _miditoneloadparam *param), struct _miditoneloadparam *param);
void inst_bankfree(MIDIMOD mod, UINT bank);
UINT inst_gettones(MIDIMOD mod, UINT bank);

#ifdef __cplusplus
}
#endif


RetroPC.NET-CVS <cvs@retropc.net>