#ifndef _IFX_H
#define _IFX_H

#include "TimTypes.h"
#include "Channel.h"
#include "NoteHandler.h"
#include "TimLib:Seq.h"

#define ifx_max_channels 64

#define ifx_status_paused          0x00000001
#define ifx_status_scalevolume     0x00000002
#define ifx_status_altermask       0x00000001
#define ifx_status_readmask        0x00000001

struct IFX
{
	GlobHdr*       pGlb;
	uint32_t       Flags;
	uint32_t       Tempo;
	SeqHandler     Seq;
	uint32_t       Status;
	uint32_t       TempoTime;   // duration of one frame in 1/256 us (256000000/tempo)
	uint32_t       FrameTime;   // time spend in current frame
	uint32_t       PreAmp;      // Pre amplification cf. polyphony
	NoteHandler    Notes;
	Channel        Channels[ifx_max_channels];
	uint32_t       Handles[ifx_max_channels];
};

#endif
