X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Funary.h;h=d57f9f70c5db545a5676f757fdeb18e25318aa79;hb=e83717e63eab1f1b78dc0990e5b8e927097fca29;hp=908dc9350786e56acc4166ec967ad7af20c34447;hpb=23ce57af3ad684363881cdd66d5724f40963a65c;p=ffmpeg diff --git a/libavcodec/unary.h b/libavcodec/unary.h index 908dc935078..d57f9f70c5d 100644 --- a/libavcodec/unary.h +++ b/libavcodec/unary.h @@ -28,7 +28,20 @@ * @param gb GetBitContext * @param[in] stop The bitstop value (unary code of 1's or 0's) * @param[in] len Maximum length - * @return Unary length/index + * @return unary 0 based code index. This is also the length in bits of the + * code excluding the stop bit. + * (in case len=1) + * 1 0 + * 0 1 + * (in case len=2) + * 1 0 + * 01 1 + * 00 2 + * (in case len=3) + * 1 0 + * 01 1 + * 001 2 + * 000 3 */ static inline int get_unary(GetBitContext *gb, int stop, int len) {