[FFmpeg-cvslog] dxva2_vc1: set bfraction in slice info according to spec
Hendrik Leppkes
git at videolan.org
Wed Jan 1 03:05:12 CET 2014
ffmpeg | branch: master | Hendrik Leppkes <h.leppkes at gmail.com> | Thu Dec 12 21:12:49 2013 +0100| [3021d1be9ef1f863f880b5c667025936b45da065] | committer: Michael Niedermayer
dxva2_vc1: set bfraction in slice info according to spec
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3021d1be9ef1f863f880b5c667025936b45da065
---
libavcodec/dxva2_vc1.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/dxva2_vc1.c b/libavcodec/dxva2_vc1.c
index 6ff5765..33309b1 100644
--- a/libavcodec/dxva2_vc1.c
+++ b/libavcodec/dxva2_vc1.c
@@ -148,7 +148,7 @@ static void fill_slice(AVCodecContext *avctx, DXVA_SliceInfo *slice,
slice->dwSliceBitsInBuffer = 8 * size;
slice->dwSliceDataLocation = position;
slice->bStartCodeBitOffset = 0;
- slice->bReservedBits = 0;
+ slice->bReservedBits = (s->pict_type == AV_PICTURE_TYPE_B && !v->bi_type) ? v->bfraction_lut_index + 9 : 0;
slice->wMBbitOffset = get_bits_count(&s->gb);
slice->wNumberMBsInSlice = s->mb_width * s->mb_height; /* XXX We assume 1 slice */
slice->wQuantizerScaleCode = v->pq;
More information about the ffmpeg-cvslog
mailing list