Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
9951907f
Commit
9951907f
authored
Jan 17, 2015
by
Anton Khirnov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h264: move redundant_pic_count into the per-slice context
parent
a9b201ca
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
6 deletions
+6
-6
dxva2_h264.c
libavcodec/dxva2_h264.c
+1
-1
h264.c
libavcodec/h264.c
+1
-1
h264.h
libavcodec/h264.h
+2
-2
h264_slice.c
libavcodec/h264_slice.c
+2
-2
No files found.
libavcodec/dxva2_h264.c
View file @
9951907f
...
...
@@ -277,7 +277,7 @@ static void fill_slice_long(AVCodecContext *avctx, DXVA_Slice_H264_Long *slice,
}
slice
->
slice_qs_delta
=
0
;
/* XXX not implemented by Libav */
slice
->
slice_qp_delta
=
sl
->
qscale
-
h
->
pps
.
init_qp
;
slice
->
redundant_pic_cnt
=
h
->
redundant_pic_count
;
slice
->
redundant_pic_cnt
=
sl
->
redundant_pic_count
;
if
(
sl
->
slice_type
==
AV_PICTURE_TYPE_B
)
slice
->
direct_spatial_mv_pred_flag
=
sl
->
direct_spatial_mv_pred
;
slice
->
cabac_init_idc
=
h
->
pps
.
cabac
?
sl
->
cabac_init_idc
:
0
;
...
...
libavcodec/h264.c
View file @
9951907f
...
...
@@ -1570,7 +1570,7 @@ again:
return
ret
;
}
if
(
hx
->
redundant_pic_count
==
0
&&
if
(
sl
->
redundant_pic_count
==
0
&&
(
avctx
->
skip_frame
<
AVDISCARD_NONREF
||
hx
->
nal_ref_idc
)
&&
(
avctx
->
skip_frame
<
AVDISCARD_BIDIR
||
...
...
libavcodec/h264.h
View file @
9951907f
...
...
@@ -356,6 +356,8 @@ typedef struct H264SliceContext {
ptrdiff_t
mb_linesize
;
///< may be equal to s->linesize or s->linesize * 2, for mbaff
ptrdiff_t
mb_uvlinesize
;
int
redundant_pic_count
;
/**
* number of neighbors (top and/or left) that used 8x8 dct
*/
...
...
@@ -577,8 +579,6 @@ typedef struct H264Context {
*/
int
max_pic_num
;
int
redundant_pic_count
;
H264Picture
default_ref_list
[
2
][
32
];
///< base reference list for all slices of a coded picture
H264Picture
*
short_ref
[
32
];
H264Picture
*
long_ref
[
32
];
...
...
libavcodec/h264_slice.c
View file @
9951907f
...
...
@@ -605,7 +605,7 @@ int ff_h264_update_thread_context(AVCodecContext *dst,
h
->
dequant_coeff_pps
=
h1
->
dequant_coeff_pps
;
// POC timing
copy_fields
(
h
,
h1
,
poc_lsb
,
redundant_pic_coun
t
);
copy_fields
(
h
,
h1
,
poc_lsb
,
default_ref_lis
t
);
// reference lists
copy_fields
(
h
,
h1
,
short_ref
,
thread_context
);
...
...
@@ -1591,7 +1591,7 @@ int ff_h264_decode_slice_header(H264Context *h, H264SliceContext *sl, H264Contex
ff_init_poc
(
h
,
h
->
cur_pic_ptr
->
field_poc
,
&
h
->
cur_pic_ptr
->
poc
);
if
(
h
->
pps
.
redundant_pic_cnt_present
)
h
->
redundant_pic_count
=
get_ue_golomb
(
&
h
->
gb
);
sl
->
redundant_pic_count
=
get_ue_golomb
(
&
h
->
gb
);
ret
=
ff_set_ref_count
(
h
,
sl
);
if
(
ret
<
0
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment