Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
01c780ae
Commit
01c780ae
authored
Sep 14, 2014
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libmpeg2: reduce variable scope
parent
09b7f634
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
7 deletions
+8
-7
modules/codec/libmpeg2.c
modules/codec/libmpeg2.c
+8
-7
No files found.
modules/codec/libmpeg2.c
View file @
01c780ae
...
@@ -254,7 +254,6 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -254,7 +254,6 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
{
{
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
decoder_sys_t
*
p_sys
=
p_dec
->
p_sys
;
mpeg2_state_t
state
;
mpeg2_state_t
state
;
picture_t
*
p_pic
;
block_t
*
p_block
;
block_t
*
p_block
;
...
@@ -401,7 +400,7 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -401,7 +400,7 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
b_skip
=
true
;
b_skip
=
true
;
}
}
p_pic
=
NULL
;
p
icture_t
*
p
_pic
=
NULL
;
if
(
!
b_skip
)
if
(
!
b_skip
)
{
{
p_pic
=
DpbNewPicture
(
p_dec
);
p_pic
=
DpbNewPicture
(
p_dec
);
...
@@ -551,7 +550,9 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -551,7 +550,9 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
case
STATE_INVALID_END
:
case
STATE_INVALID_END
:
case
STATE_END
:
case
STATE_END
:
case
STATE_SLICE
:
case
STATE_SLICE
:
p_pic
=
NULL
;
{
picture_t
*
p_pic
=
NULL
;
if
(
p_sys
->
p_info
->
display_fbuf
&&
if
(
p_sys
->
p_info
->
display_fbuf
&&
p_sys
->
p_info
->
display_fbuf
->
id
)
p_sys
->
p_info
->
display_fbuf
->
id
)
{
{
...
@@ -578,12 +579,11 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -578,12 +579,11 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
DpbUnlinkPicture
(
p_dec
,
p_sys
->
p_info
->
discard_fbuf
->
id
);
DpbUnlinkPicture
(
p_dec
,
p_sys
->
p_info
->
discard_fbuf
->
id
);
}
}
/* For still frames */
if
(
state
==
STATE_END
&&
p_pic
)
p_pic
->
b_force
=
true
;
if
(
p_pic
)
if
(
p_pic
)
{
{
if
(
state
==
STATE_END
)
p_pic
->
b_force
=
true
;
/* For still frames */
/* Avoid frames with identical timestamps.
/* Avoid frames with identical timestamps.
* Especially needed for still frames in DVD menus. */
* Especially needed for still frames in DVD menus. */
if
(
p_sys
->
i_last_frame_pts
==
p_pic
->
date
)
if
(
p_sys
->
i_last_frame_pts
==
p_pic
->
date
)
...
@@ -592,6 +592,7 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
...
@@ -592,6 +592,7 @@ static picture_t *DecodeBlock( decoder_t *p_dec, block_t **pp_block )
return
p_pic
;
return
p_pic
;
}
}
break
;
break
;
}
case
STATE_INVALID
:
case
STATE_INVALID
:
{
{
...
...
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