diff options
author | Mike Melanson <mike@multimedia.cx> | 2004-03-14 04:04:08 +0000 |
---|---|---|
committer | Mike Melanson <mike@multimedia.cx> | 2004-03-14 04:04:08 +0000 |
commit | 3a278992bdd8138eeefc9df06878703480f27b1b (patch) | |
tree | 6891b1a6c885f6c5dd68843695739c53c8741c9b /libavcodec/avcodec.h | |
parent | 9eef2b77b29189606148e1fdf5d6c8d7b52b08b0 (diff) | |
download | ffmpeg-3a278992bdd8138eeefc9df06878703480f27b1b.tar.gz |
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
MKTAG/MKBETAG
Originally committed as revision 2886 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r-- | libavcodec/avcodec.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index cbc65dfc6a..53307882e6 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -2118,6 +2118,18 @@ extern int av_log_get_level(void); extern void av_log_set_level(int); extern void av_log_set_callback(void (*)(void*, int, const char*, va_list)); +/* endian macros */ +#define BE_16(x) ((((uint8_t*)(x))[0] << 8) | ((uint8_t*)(x))[1]) +#define BE_32(x) ((((uint8_t*)(x))[0] << 24) | \ + (((uint8_t*)(x))[1] << 16) | \ + (((uint8_t*)(x))[2] << 8) | \ + ((uint8_t*)(x))[3]) +#define LE_16(x) ((((uint8_t*)(x))[1] << 8) | ((uint8_t*)(x))[0]) +#define LE_32(x) ((((uint8_t*)(x))[3] << 24) | \ + (((uint8_t*)(x))[2] << 16) | \ + (((uint8_t*)(x))[1] << 8) | \ + ((uint8_t*)(x))[0]) + #ifdef __cplusplus } #endif |