summaryrefslogtreecommitdiffstats
path: root/Src/Plugins/Input/in_vorbis/decoder.h
blob: aa2b8c0115b3396ebf6d8a40f75ae023582a80cf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
class Shaper;

class Decoder
{
private:
	void process_rg();
	void setup_mc();
	float* bptr;
	float** pcmbuf;
	Shaper * shaper;
	UINT data,pos;
	float scale;
	int cur_link;
	int cur_preamp;
	int clipmin,clipmax;
public:
	VorbisFile * file;

	UINT nch,sr,kbps,bps,src_nch;

	Decoder()
	{
		memset(this,0,sizeof(*this));
	}

	~Decoder();
	
	int Seek(double p);
	int Read(UINT bytes,void * buf);
	void Flush();
	void Init(VorbisFile * f, UINT _bits=0, UINT _nch=0, bool _useFloat=false, bool allowRG=true);
	void wa2_setinfo(UINT cur_bitrate);

	UINT DataAvailable();
	int DoFrame();
	bool need_reopen;
	int play_init();
	bool play_inited;
	bool dither;
	bool useFloat;
};