Commit 5bf5e6b1 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/h264: Use named identifier for single thread fall-back return from...

avcodec/h264: Use named identifier for single thread fall-back return from ff_h264_decode_slice_header()
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 891307b4
...@@ -1727,7 +1727,7 @@ again: ...@@ -1727,7 +1727,7 @@ again:
if (err < 0) if (err < 0)
av_log(h->avctx, AV_LOG_ERROR, "decode_slice_header error\n"); av_log(h->avctx, AV_LOG_ERROR, "decode_slice_header error\n");
h->ref_count[0] = h->ref_count[1] = h->list_count = 0; h->ref_count[0] = h->ref_count[1] = h->list_count = 0;
} else if (err == 1) { } else if (err == SLICE_SINGLETHREAD) {
/* Slice could not be decoded in parallel mode, copy down /* Slice could not be decoded in parallel mode, copy down
* NAL unit stuff to context 0 and restart. Note that * NAL unit stuff to context 0 and restart. Note that
* rbsp_buffer is not transferred, but since we no longer * rbsp_buffer is not transferred, but since we no longer
......
...@@ -1098,6 +1098,7 @@ int ff_pred_weight_table(H264Context *h); ...@@ -1098,6 +1098,7 @@ int ff_pred_weight_table(H264Context *h);
int ff_set_ref_count(H264Context *h); int ff_set_ref_count(H264Context *h);
int ff_h264_decode_slice_header(H264Context *h, H264Context *h0); int ff_h264_decode_slice_header(H264Context *h, H264Context *h0);
#define SLICE_SINGLETHREAD 1
#define SLICE_SKIPED 2 #define SLICE_SKIPED 2
int ff_h264_execute_decode_slices(H264Context *h, unsigned context_count); int ff_h264_execute_decode_slices(H264Context *h, unsigned context_count);
......
...@@ -1890,7 +1890,7 @@ int ff_h264_decode_slice_header(H264Context *h, H264Context *h0) ...@@ -1890,7 +1890,7 @@ int ff_h264_decode_slice_header(H264Context *h, H264Context *h0)
if (h != h0) { if (h != h0) {
av_log(h->avctx, AV_LOG_ERROR, av_log(h->avctx, AV_LOG_ERROR,
"Deblocking switched inside frame.\n"); "Deblocking switched inside frame.\n");
return 1; return SLICE_SINGLETHREAD;
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment