aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/bitstream.h
diff options
context:
space:
mode:
authorKostya Shishkov <kostya.shishkov@gmail.com>2008-01-03 09:16:56 +0000
committerKostya Shishkov <kostya.shishkov@gmail.com>2008-01-03 09:16:56 +0000
commitb44665c4e648cb04aa4328b80e178f1ef3d85ff5 (patch)
treebab93d47dd2695f4118b2dfc689c1aaf8d7b6b65 /libavcodec/bitstream.h
parentca32534337022b5902c78e44f5f234e2e61d1673 (diff)
downloadffmpeg-b44665c4e648cb04aa4328b80e178f1ef3d85ff5.tar.gz
Make decode210() common function.
Originally committed as revision 11382 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/bitstream.h')
-rw-r--r--libavcodec/bitstream.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/libavcodec/bitstream.h b/libavcodec/bitstream.h
index ef15f3abf5..854ba99bcc 100644
--- a/libavcodec/bitstream.h
+++ b/libavcodec/bitstream.h
@@ -950,4 +950,11 @@ static inline int decode012(GetBitContext *gb){
return get_bits1(gb) + 1;
}
+static inline int decode210(GetBitContext *gb){
+ if (get_bits1(gb))
+ return 0;
+ else
+ return 2 - get_bits1(gb);
+}
+
#endif /* FFMPEG_BITSTREAM_H */