mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
lavc: move put_bits_left in put_bits.h
This commit is contained in:
parent
07c52e2c7c
commit
afe03092dd
@ -340,11 +340,6 @@ static av_cold int dvvideo_init_encoder(AVCodecContext *avctx)
|
|||||||
static const int vs_total_ac_bits = (100 * 4 + 68*2) * 5;
|
static const int vs_total_ac_bits = (100 * 4 + 68*2) * 5;
|
||||||
static const int mb_area_start[5] = { 1, 6, 21, 43, 64 };
|
static const int mb_area_start[5] = { 1, 6, 21, 43, 64 };
|
||||||
|
|
||||||
static inline int put_bits_left(PutBitContext* s)
|
|
||||||
{
|
|
||||||
return (s->buf_end - s->buf) * 8 - put_bits_count(s);
|
|
||||||
}
|
|
||||||
|
|
||||||
#if CONFIG_SMALL
|
#if CONFIG_SMALL
|
||||||
/* Converts run and level (where level != 0) pair into VLC, returning bit size */
|
/* Converts run and level (where level != 0) pair into VLC, returning bit size */
|
||||||
static av_always_inline int dv_rl2vlc(int run, int level, int sign, uint32_t* vlc)
|
static av_always_inline int dv_rl2vlc(int run, int level, int sign, uint32_t* vlc)
|
||||||
|
@ -74,6 +74,14 @@ static inline int put_bits_count(PutBitContext *s)
|
|||||||
return (s->buf_ptr - s->buf) * 8 + 32 - s->bit_left;
|
return (s->buf_ptr - s->buf) * 8 + 32 - s->bit_left;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return the number of bits available in the bitstream.
|
||||||
|
*/
|
||||||
|
static inline int put_bits_left(PutBitContext* s)
|
||||||
|
{
|
||||||
|
return (s->buf_end - s->buf_ptr) * 8 - 32 + s->bit_left;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Pad the end of the output stream with zeros.
|
* Pad the end of the output stream with zeros.
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user