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
dc971acf
Commit
dc971acf
authored
Feb 14, 2014
by
Vittorio Giovara
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h264_parser: use enum values in h264_find_frame_end()
parent
ba7dfe5c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
h264_parser.c
libavcodec/h264_parser.c
+5
-3
No files found.
libavcodec/h264_parser.c
View file @
dc971acf
...
...
@@ -58,13 +58,15 @@ static int h264_find_frame_end(H264Context *h, const uint8_t *buf,
else
state
>>=
1
;
// 2->1, 1->0, 0->0
}
else
if
(
state
<=
5
)
{
int
v
=
buf
[
i
]
&
0x1F
;
if
(
v
==
6
||
v
==
7
||
v
==
8
||
v
==
9
)
{
int
nalu_type
=
buf
[
i
]
&
0x1F
;
if
(
nalu_type
==
NAL_SEI
||
nalu_type
==
NAL_SPS
||
nalu_type
==
NAL_PPS
||
nalu_type
==
NAL_AUD
)
{
if
(
pc
->
frame_start_found
)
{
i
++
;
goto
found
;
}
}
else
if
(
v
==
1
||
v
==
2
||
v
==
5
)
{
}
else
if
(
nalu_type
==
NAL_SLICE
||
nalu_type
==
NAL_DPA
||
nalu_type
==
NAL_IDR_SLICE
)
{
if
(
pc
->
frame_start_found
)
{
state
+=
8
;
continue
;
...
...
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