X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fbytestream.h;h=b316f2d3f3b94220e8bc9d5c0bcc9e243b21c178;hb=255eccab6e75acc16db788f2ed33da53ee018928;hp=136e5842e3247badc5186d9f70f55385d02bab1f;hpb=895c2c005e1ac27a0685060205372e854dc1e622;p=ffmpeg diff --git a/libavcodec/bytestream.h b/libavcodec/bytestream.h index 136e5842e32..b316f2d3f3b 100644 --- a/libavcodec/bytestream.h +++ b/libavcodec/bytestream.h @@ -22,6 +22,8 @@ #ifndef FFMPEG_BYTESTREAM_H #define FFMPEG_BYTESTREAM_H +#include "common.h" + #define DEF(name, bytes, read, write)\ static av_always_inline unsigned int bytestream_get_ ## name(uint8_t **b){\ (*b) += bytes;\ @@ -30,9 +32,10 @@ static av_always_inline unsigned int bytestream_get_ ## name(uint8_t **b){\ static av_always_inline void bytestream_put_ ##name(uint8_t **b, const unsigned int value){\ write(*b, value);\ (*b) += bytes;\ -}; +} DEF(le32, 4, AV_RL32, AV_WL32) +DEF(le24, 3, AV_RL24, AV_WL24) DEF(le16, 2, AV_RL16, AV_WL16) DEF(be32, 4, AV_RB32, AV_WB32) DEF(be24, 3, AV_RB24, AV_WB24)