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
77477266
Commit
77477266
authored
Jan 17, 2015
by
Anton Khirnov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h264: move map_col_to_list0[_field] into the per-slice context
parent
ee0d774d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
9 deletions
+8
-9
h264.h
libavcodec/h264.h
+2
-3
h264_direct.c
libavcodec/h264_direct.c
+6
-6
No files found.
libavcodec/h264.h
View file @
77477266
...
...
@@ -361,6 +361,8 @@ typedef struct H264SliceContext {
int
dist_scale_factor
[
32
];
int
dist_scale_factor_field
[
2
][
32
];
int
map_col_to_list0
[
2
][
16
+
32
];
int
map_col_to_list0_field
[
2
][
2
][
16
+
32
];
/**
* non zero coeff count cache.
...
...
@@ -447,9 +449,6 @@ typedef struct H264Context {
int
picture_structure
;
int
first_field
;
int
map_col_to_list0
[
2
][
16
+
32
];
int
map_col_to_list0_field
[
2
][
2
][
16
+
32
];
/**
* num_ref_idx_l0/1_active_minus1 + 1
*/
...
...
libavcodec/h264_direct.c
View file @
77477266
...
...
@@ -145,10 +145,10 @@ void ff_h264_direct_ref_list_init(H264Context *const h, H264SliceContext *sl)
return
;
for
(
list
=
0
;
list
<
2
;
list
++
)
{
fill_colmap
(
h
,
h
->
map_col_to_list0
,
list
,
sidx
,
ref1sidx
,
0
);
fill_colmap
(
h
,
sl
->
map_col_to_list0
,
list
,
sidx
,
ref1sidx
,
0
);
if
(
FRAME_MBAFF
(
h
))
for
(
field
=
0
;
field
<
2
;
field
++
)
fill_colmap
(
h
,
h
->
map_col_to_list0_field
[
field
],
list
,
field
,
fill_colmap
(
h
,
sl
->
map_col_to_list0_field
[
field
],
list
,
field
,
field
,
1
);
}
}
...
...
@@ -554,14 +554,14 @@ single_col:
}
{
const
int
*
map_col_to_list0
[
2
]
=
{
h
->
map_col_to_list0
[
0
],
h
->
map_col_to_list0
[
1
]
};
const
int
*
map_col_to_list0
[
2
]
=
{
sl
->
map_col_to_list0
[
0
],
sl
->
map_col_to_list0
[
1
]
};
const
int
*
dist_scale_factor
=
sl
->
dist_scale_factor
;
int
ref_offset
;
if
(
FRAME_MBAFF
(
h
)
&&
IS_INTERLACED
(
*
mb_type
))
{
map_col_to_list0
[
0
]
=
h
->
map_col_to_list0_field
[
h
->
mb_y
&
1
][
0
];
map_col_to_list0
[
1
]
=
h
->
map_col_to_list0_field
[
h
->
mb_y
&
1
][
1
];
map_col_to_list0
[
0
]
=
sl
->
map_col_to_list0_field
[
h
->
mb_y
&
1
][
0
];
map_col_to_list0
[
1
]
=
sl
->
map_col_to_list0_field
[
h
->
mb_y
&
1
][
1
];
dist_scale_factor
=
sl
->
dist_scale_factor_field
[
h
->
mb_y
&
1
];
}
ref_offset
=
(
h
->
ref_list
[
1
][
0
].
mbaff
<<
4
)
&
(
mb_type_col
[
0
]
>>
3
);
...
...
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