-
-
Save lu-zero/345107b2167368bd2d3a to your computer and use it in GitHub Desktop.
bitstream.h debugging
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define bistream_read_count(bb) ({\ | |
int _ret = bitstream_read_count(bb); \ | |
printf("%s:%d %s, read_count %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_read_bit(bb) ({\ | |
int _ret = bitstream_read_bit(bb); \ | |
printf("%s:%d %s, read_bit %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_read_32(bb, n) ({\ | |
int _ret = bitstream_read_32(bb, n); \ | |
printf("%s:%d %s, read_32 %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_show_32(bb, n) ({\ | |
int _ret = bitstream_show_32(bb, n); \ | |
printf("%s:%d %s, show_32 %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_read_xbits(bb, n) ({\ | |
int _ret = bitstream_read_xbits(bb, n); \ | |
printf("%s:%d %s, read_xbits %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_read_s32(bb, n) ({\ | |
int _ret = bitstream_read_s32(bb, n); \ | |
printf("%s:%d %s, read_s32 %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bistream_read_s(bb, n) ({\ | |
int _ret = bitstream_read_s(bb, n); \ | |
printf("%s:%d %s, read_s %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bitstream_show_left(bb) ({\ | |
int _ret = bitstream_show_left(bb); \ | |
printf("%s:%d %s, show_left %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) | |
#define bitstream_read_vlc(bb, table, bits, max) ({\ | |
int _ret = bitstream_read_vlc(bb, table, bits, max); \ | |
printf("%s:%d %s, show_left %d\n", __FILE__, __LINE__, __func__, _ret); \ | |
_ret; \ | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment