#ifndef LIBRARIES_ID3TAG_H
#define LIBRARIES_ID3TAG_H


#include <exec/libraries.h>
#include <exec/types.h>



struct ID3TagBase
{
	struct Library base;
	STRPTR *genre;
};


/* Type for ID3Tag_RemoveType() */
 
#define ID3Tag_Remove_T1 0
/* entspricht ID3Tag_Remove() */
#define ID3Tag_Remove_T2 1
/* id3tag
	V1 wird mir Leerzeichen überschrieben
	V2 wird mit NullBytes überschrieben
*/
 

#define ID3TagMPEGA_VERSION_1 1
#define ID3TagMPEGA_VERSION_2 2
#define ID3TagMPEGA_VERSION_2_5 4

#define ID3TagMPEGA_MODE_STEREO 0
#define ID3TagMPEGA_MODE_JOINSTEREO 1
#define ID3TagMPEGA_MODE_DUALCHANNEL 2
#define ID3TagMPEGA_MODE_SINGLECHANNEL 3

	
#define ID3Tag_Dummy (TAG_USER)
  
#define ID3Tag_Title    (ID3Tag_Dummy+1)
/* STRPTR */
#define ID3Tag_Artist   (ID3Tag_Dummy+2)
/* STRPTR */
#define ID3Tag_Album    (ID3Tag_Dummy+3)
/* STRPTR */
#define ID3Tag_Year     (ID3Tag_Dummy+4)
/* STRPTR */
#define ID3Tag_Comment  (ID3Tag_Dummy+5)
/* STRPTR */
#define ID3Tag_Genre    (ID3Tag_Dummy+6)
/* STRPTR */
#define ID3Tag_Track    (ID3Tag_Dummy+7)
/* LONG */
#define ID3Tag_Comment2 (ID3Tag_Dummy+8)
/* STRPTR  (mehrzeilig) */
#define ID3Tag_Track2   (ID3Tag_Dummy+9)
/* LONG */
 


struct ID3Tag
{
/* ID3Tag */
	UWORD version;
	UWORD revision;
	UWORD revision2;
	
   void *tagdata;

/* Mpeg Audio Info */
	WORD norm;         /* ID3TagMPEGA_VERSION_xxx */
	WORD layer;        /* 1..3 */
	WORD mode;         /* ID3TagMPEGA_MODE_xxx */
	LONG bitrate;      /* in bps */
	WORD vbr;          /* 0 or 1 */
	LONG frequency;    /* in Hz */
	ULONG ms_duration; /* stream duration in second */
	WORD crc;          /* 0 or 1 */
	WORD copyright;    /* 0 or 1 */
	WORD original;     /* 0 or 1 */
	WORD private_bit;  /* 0 or 1 */
	WORD emphasis;     /* 0..3 */
	LONG filesize;     /* in Byte */
};

/*
	ErrorID's
*/

 
#define ID3TagErr_NoMpegaFile    1
#define ID3TagErr_NoMemory       2
#define ID3TagErr_ObjectNotFound 3
#define ID3TagErr_ObjectInUse    4
#define ID3TagErr_ReadWrite      5
#define ID3TagErr_WriteProtected 6
#define ID3TagErr_ReadProtected  7
#define ID3TagErr_UnknownTagArg  8
#define ID3TagErr_UnknownRemType 9

#define ID3TagErr_DiskFull           10
#define ID3TagErr_DiskNotValidated   11
#define ID3TagErr_DiskWriteProtected 12
#define ID3TagErr_DeleteProtected    13



 
#endif /* LIBRARIES_ID3TAG_H */

