00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00024 #ifndef AVUTIL_ERROR_H
00025 #define AVUTIL_ERROR_H
00026
00027 #include <errno.h>
00028 #include "avutil.h"
00029
00030
00031 #if EDOM > 0
00032 #define AVERROR(e) (-(e))
00033 #define AVUNERROR(e) (-(e))
00034 #else
00035
00036 #define AVERROR(e) (e)
00037 #define AVUNERROR(e) (e)
00038 #endif
00039
00040 #if LIBAVUTIL_VERSION_MAJOR < 51
00041 #define AVERROR_INVALIDDATA AVERROR(EINVAL)
00042 #define AVERROR_IO AVERROR(EIO)
00043 #define AVERROR_NOENT AVERROR(ENOENT)
00044 #define AVERROR_NOFMT AVERROR(EILSEQ)
00045 #define AVERROR_NOMEM AVERROR(ENOMEM)
00046 #define AVERROR_NOTSUPP AVERROR(ENOSYS)
00047 #define AVERROR_NUMEXPECTED AVERROR(EDOM)
00048 #define AVERROR_UNKNOWN AVERROR(EINVAL)
00049 #endif
00050
00051 #define AVERROR_EOF AVERROR(EPIPE)
00052
00053 #define AVERROR_PATCHWELCOME (-MKTAG('P','A','W','E'))
00054
00055 #if LIBAVUTIL_VERSION_MAJOR > 50
00056 #define AVERROR_INVALIDDATA (-MKTAG('I','N','D','A'))
00057 #define AVERROR_NUMEXPECTED (-MKTAG('N','U','E','X'))
00058 #endif
00059
00060 #define AVERROR_DEMUXER_NOT_FOUND (-MKTAG(0xF8,'D','E','M'))
00061 #define AVERROR_MUXER_NOT_FOUND (-MKTAG(0xF8,'M','U','X'))
00062
00063 #define AVERROR_BSF_NOT_FOUND (-MKTAG(0xF8,'B','S','F'))
00064 #define AVERROR_DECODER_NOT_FOUND (-MKTAG(0xF8,'D','E','C'))
00065 #define AVERROR_DEMUXER_NOT_FOUND (-MKTAG(0xF8,'D','E','M'))
00066 #define AVERROR_ENCODER_NOT_FOUND (-MKTAG(0xF8,'E','N','C'))
00067 #define AVERROR_EXIT (-MKTAG( 'E','X','I','T'))
00068 #define AVERROR_FILTER_NOT_FOUND (-MKTAG(0xF8,'F','I','L'))
00069 #define AVERROR_MUXER_NOT_FOUND (-MKTAG(0xF8,'M','U','X'))
00070 #define AVERROR_OPTION_NOT_FOUND (-MKTAG(0xF8,'O','P','T'))
00071 #define AVERROR_PROTOCOL_NOT_FOUND (-MKTAG(0xF8,'P','R','O'))
00072 #define AVERROR_STREAM_NOT_FOUND (-MKTAG(0xF8,'S','T','R'))
00073
00074
00086 int av_strerror(int errnum, char *errbuf, size_t errbuf_size);
00087
00088 #endif