summaryrefslogtreecommitdiff
path: root/libavcodec/dxva2_mpeg2.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-03-07 00:03:40 +0100
committerMichael Niedermayer <michaelni@gmx.at>2014-03-07 00:06:43 +0100
commitb7c1f6f9cc752d3a29f7a14c09c15c884bf5f4e4 (patch)
treefc9ffc8e36fcab8d6b4b5406353a6435ce4ea007 /libavcodec/dxva2_mpeg2.c
parent39f5003a07db14c3a98617c052570383c6c0fd35 (diff)
parentb66382101cff33e2ce66500327a90d0a105eedeb (diff)
Merge commit 'b66382101cff33e2ce66500327a90d0a105eedeb'
* commit 'b66382101cff33e2ce66500327a90d0a105eedeb': dxva2: Increase maximum number of slices for mpeg2 See: bceeccc648baf94a02b7b2c53e44bf77a47773ef Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/dxva2_mpeg2.c')
-rw-r--r--libavcodec/dxva2_mpeg2.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/dxva2_mpeg2.c b/libavcodec/dxva2_mpeg2.c
index e2f6b709aa..153ff64828 100644
--- a/libavcodec/dxva2_mpeg2.c
+++ b/libavcodec/dxva2_mpeg2.c
@@ -20,6 +20,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#include "libavutil/log.h"
#include "dxva2_internal.h"
#define MAX_SLICES 1024
@@ -232,9 +233,11 @@ static int dxva2_mpeg2_decode_slice(AVCodecContext *avctx,
s->current_picture_ptr->hwaccel_picture_private;
unsigned position;
- if (ctx_pic->slice_count >= MAX_SLICES)
+ if (ctx_pic->slice_count >= MAX_SLICES) {
+ avpriv_request_sample(avctx, "%d slices in dxva2",
+ ctx_pic->slice_count);
return -1;
-
+ }
if (!ctx_pic->bitstream)
ctx_pic->bitstream = buffer;
ctx_pic->bitstream_size += size;