2 * AdPlug - Replayer for many OPL2/OPL3 audio file formats.
3 * Copyright (C) 1999 - 2007 Simon Peter, <dn.tlp@gmx.net>, et al.
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 * d00.h - D00 Player by Simon Peter <dn.tlp@gmx.net>
27 class Cd00Player: public CPlayer
30 static CPlayer *factory(Copl *newopl);
32 Cd00Player(Copl *newopl)
33 : CPlayer(newopl), filedata(0)
36 { if(filedata) delete [] filedata; };
38 bool load(const std::string &filename, const CFileProvider &fp);
40 void rewind(int subsong);
43 std::string gettype();
44 std::string gettitle()
45 { if(version > 1) return std::string(header->songname); else return std::string(); };
46 std::string getauthor()
47 { if(version > 1) return std::string(header->author); else return std::string(); };
49 { if(*datainfo) return std::string(datainfo); else return std::string(); };
50 unsigned int getsubsongs();
56 unsigned char type,version,speed,subsongs,soundcard;
57 char songname[32],author[32],dummy[32];
58 unsigned short tpoin,seqptr,instptr,infoptr,spfxptr,endmark;
62 unsigned char version,speed,subsongs;
63 unsigned short tpoin,seqptr,instptr,infoptr,lpulptr,endmark;
68 unsigned short *order,ordpos,pattpos,del,speed,rhcnt,key,freq,inst,
70 signed short transpose,slide,slideval,vibspeed;
71 unsigned char seqend,vol,vibdepth,fxdel,modvol,cvol,levpuls,
72 frameskip,nextnote,note,ilevpuls,trigger,fxflag;
76 unsigned char data[11],tunelev,timer,sr,dummy[2];
80 unsigned short instnr;
83 signed char modlevadd;
84 unsigned char duration;
91 unsigned char duration,ptr;
94 unsigned char songend,version,cursubsong;
96 unsigned short *seqptr;
102 void setvolume(unsigned char chan);
103 void setfreq(unsigned char chan);
104 void setinst(unsigned char chan);
105 void playnote(unsigned char chan);
106 void vibrato(unsigned char chan);