annotate libmpcodecs/ad.h @ 6110:7bea806b9c5f

Improvment for spu subtitles. Removed the integreted spudec in vobsub. Various cleanup/bugfix in vobsub (no more auto palette when a true one is here) HW spu rendering moved in spudec because we first need to reassable the packet before sending them to the hw. Spudec is now created only if nedded.
author albeu
date Fri, 17 May 2002 23:47:27 +0000
parents e72d8e3955ea
children 6ac1ece1f9fe
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5324
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
1
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
2 #include "mpc_info.h"
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
3 typedef mp_codec_info_t ad_info_t;
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
4
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
5 /* interface of video decoder drivers */
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
6 typedef struct ad_functions_s
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
7 {
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
8 ad_info_t *info;
5339
e72d8e3955ea changed to be more-or-less compatible with Nick's stuff
arpi
parents: 5324
diff changeset
9 int (*preinit)(sh_audio_t *sh);
5324
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
10 int (*init)(sh_audio_t *sh);
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
11 void (*uninit)(sh_audio_t *sh);
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
12 int (*control)(sh_audio_t *sh,int cmd,void* arg, ...);
5339
e72d8e3955ea changed to be more-or-less compatible with Nick's stuff
arpi
parents: 5324
diff changeset
13 int (*decode_audio)(sh_audio_t *sh,unsigned char* buffer,int minlen,int maxlen);
5324
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
14 } ad_functions_t;
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
15
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
16 // NULL terminated array of all drivers
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
17 extern ad_functions_t* mpcodecs_ad_drivers[];
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
18
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
19 // fallback if ADCTRL_RESYNC not implemented: sh_audio->a_in_buffer_len=0;
5339
e72d8e3955ea changed to be more-or-less compatible with Nick's stuff
arpi
parents: 5324
diff changeset
20 #define ADCTRL_RESYNC_STREAM 1 /* resync, called after seeking! */
5324
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
21
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
22 // fallback if ADCTRL_SKIP not implemented: ds_fill_buffer(sh_audio->ds);
5339
e72d8e3955ea changed to be more-or-less compatible with Nick's stuff
arpi
parents: 5324
diff changeset
23 #define ADCTRL_SKIP_FRAME 2 /* skip block/frame, called while seeking! */
5324
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
24
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
25 // fallback if ADCTRL_QUERY_FORMAT not implemented: sh_audio->sample_format
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
26 #define ADCTRL_QUERY_FORMAT 3 /* test for availabilty of a format */
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
27
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
28 // fallback: use hw mixer in libao
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
29 #define ADCTRL_SET_VOLUME 4 /* set volume (used for mp3lib and liba52) */
f9845598022f proposal for audio decoders
arpi
parents:
diff changeset
30