2001-04-07 01:20:46 +02:00
|
|
|
#ifndef __CODEC_CFG_H
|
|
|
|
#define __CODEC_CFG_H
|
|
|
|
|
2002-01-17 10:20:29 +01:00
|
|
|
#define CODECS_MAX_FOURCC 32
|
|
|
|
#define CODECS_MAX_OUTFMT 32
|
2001-04-07 01:20:46 +02:00
|
|
|
|
2001-04-07 23:27:57 +02:00
|
|
|
// Global flags:
|
2001-04-10 22:09:23 +02:00
|
|
|
#define CODECS_FLAG_SEEKABLE (1<<0)
|
2001-04-07 01:20:46 +02:00
|
|
|
|
2001-04-07 23:27:57 +02:00
|
|
|
// Outfmt flags:
|
2001-04-07 01:56:42 +02:00
|
|
|
#define CODECS_FLAG_FLIP (1<<0)
|
|
|
|
#define CODECS_FLAG_NOFLIP (1<<1)
|
|
|
|
#define CODECS_FLAG_YUVHACK (1<<2)
|
|
|
|
|
2001-04-09 01:42:25 +02:00
|
|
|
#define CODECS_STATUS_NOT_WORKING 0
|
|
|
|
#define CODECS_STATUS_UNTESTED -1
|
|
|
|
#define CODECS_STATUS_PROBLEMS 1
|
|
|
|
#define CODECS_STATUS_WORKING 2
|
|
|
|
|
2001-07-29 04:08:27 +02:00
|
|
|
// Codec family/driver:
|
|
|
|
#define AFM_MPEG 1
|
|
|
|
#define AFM_PCM 2
|
|
|
|
#define AFM_AC3 3
|
|
|
|
#define AFM_ACM 4
|
|
|
|
#define AFM_ALAW 5
|
|
|
|
#define AFM_GSM 6
|
|
|
|
#define AFM_DSHOW 7
|
|
|
|
#define AFM_DVDPCM 8
|
2001-08-15 13:50:55 +02:00
|
|
|
#define AFM_HWAC3 9
|
2001-09-01 21:44:49 +02:00
|
|
|
#define AFM_VORBIS 10
|
2001-09-21 23:40:16 +02:00
|
|
|
#define AFM_FFMPEG 11
|
2001-10-23 14:03:41 +02:00
|
|
|
#define AFM_MAD 12
|
2001-12-27 06:09:43 +01:00
|
|
|
#define AFM_MSADPCM 13
|
2001-12-09 17:20:03 +01:00
|
|
|
#define AFM_A52 14
|
|
|
|
#define AFM_G72X 15
|
2001-12-27 06:09:43 +01:00
|
|
|
#define AFM_IMAADPCM 16
|
2002-01-01 21:04:54 +01:00
|
|
|
#define AFM_FOX61ADPCM 17
|
|
|
|
#define AFM_FOX62ADPCM 18
|
2001-07-29 04:08:27 +02:00
|
|
|
|
|
|
|
#define VFM_MPEG 1
|
|
|
|
#define VFM_VFW 2
|
|
|
|
#define VFM_ODIVX 3
|
|
|
|
#define VFM_DSHOW 4
|
|
|
|
#define VFM_FFMPEG 5
|
|
|
|
#define VFM_VFWEX 6
|
|
|
|
#define VFM_DIVX4 7
|
2001-08-12 01:11:16 +02:00
|
|
|
#define VFM_RAW 8
|
2001-09-24 22:21:53 +02:00
|
|
|
#define VFM_RLE 9
|
2001-10-22 21:04:09 +02:00
|
|
|
#define VFM_XANIM 10
|
2001-11-11 14:35:00 +01:00
|
|
|
#define VFM_MSVIDC 11
|
2001-11-28 02:35:55 +01:00
|
|
|
#define VFM_FLI 12
|
2001-12-21 17:39:54 +01:00
|
|
|
#define VFM_CINEPAK 13
|
2001-12-23 23:20:46 +01:00
|
|
|
#define VFM_QTRLE 14
|
2001-12-27 22:32:17 +01:00
|
|
|
#define VFM_NUV 15
|
2002-01-04 06:57:00 +01:00
|
|
|
#define VFM_CYUV 16
|
2002-01-18 06:43:48 +01:00
|
|
|
#define VFM_QTSMC 17
|
2002-01-22 06:39:34 +01:00
|
|
|
#define VFM_DUCKTM1 18
|
2001-04-07 01:56:42 +02:00
|
|
|
|
2001-09-02 19:21:22 +02:00
|
|
|
#ifndef GUID_TYPE
|
|
|
|
#define GUID_TYPE
|
2001-04-07 01:20:46 +02:00
|
|
|
typedef struct {
|
2001-04-07 02:51:38 +02:00
|
|
|
unsigned long f1;
|
|
|
|
unsigned short f2;
|
|
|
|
unsigned short f3;
|
|
|
|
unsigned char f4[8];
|
2001-04-07 01:20:46 +02:00
|
|
|
} GUID;
|
2001-09-02 19:21:22 +02:00
|
|
|
#endif
|
|
|
|
|
2001-04-07 01:20:46 +02:00
|
|
|
|
2001-10-20 20:49:08 +02:00
|
|
|
typedef struct codecs_st {
|
2001-04-09 01:42:25 +02:00
|
|
|
unsigned int fourcc[CODECS_MAX_FOURCC];
|
|
|
|
unsigned int fourccmap[CODECS_MAX_FOURCC];
|
|
|
|
unsigned int outfmt[CODECS_MAX_OUTFMT];
|
|
|
|
unsigned char outflags[CODECS_MAX_OUTFMT];
|
2001-04-07 01:20:46 +02:00
|
|
|
char *name;
|
|
|
|
char *info;
|
|
|
|
char *comment;
|
|
|
|
char *dll;
|
|
|
|
GUID guid;
|
2001-04-09 01:42:25 +02:00
|
|
|
short driver;
|
|
|
|
short flags;
|
|
|
|
short status;
|
2001-04-11 22:55:14 +02:00
|
|
|
short cpuflags;
|
2001-12-23 12:58:57 +01:00
|
|
|
short priority;
|
2001-04-07 01:20:46 +02:00
|
|
|
} codecs_t;
|
|
|
|
|
2001-12-27 19:38:10 +01:00
|
|
|
int parse_codec_cfg(char *cfgfile);
|
2001-04-11 01:18:01 +02:00
|
|
|
codecs_t* find_video_codec(unsigned int fourcc, unsigned int *fourccmap, codecs_t *start);
|
|
|
|
codecs_t* find_audio_codec(unsigned int fourcc, unsigned int *fourccmap, codecs_t *start);
|
|
|
|
codecs_t* find_codec(unsigned int fourcc,unsigned int *fourccmap,codecs_t *start,int audioflag);
|
2001-09-27 14:59:35 +02:00
|
|
|
void list_codecs(int audioflag);
|
2001-04-07 01:20:46 +02:00
|
|
|
|
|
|
|
#endif
|