Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
3813108b
Commit
3813108b
authored
Jun 29, 2004
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/codec/ffmpeg/video.c: force the very 1st frame (for still pictures).
parent
bbcddc3e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletion
+13
-1
modules/codec/ffmpeg/video.c
modules/codec/ffmpeg/video.c
+13
-1
No files found.
modules/codec/ffmpeg/video.c
View file @
3813108b
...
...
@@ -71,6 +71,9 @@ struct decoder_sys_t
vlc_bool_t
b_has_b_frames
;
/* Hack to force display of still pictures */
vlc_bool_t
b_first_frame
;
int
i_buffer_orig
,
i_buffer
;
char
*
p_buffer_orig
,
*
p_buffer
;
...
...
@@ -365,6 +368,7 @@ int E_(InitVideoDec)( decoder_t *p_dec, AVCodecContext *p_context,
p_sys
->
input_pts
=
p_sys
->
input_dts
=
0
;
p_sys
->
i_pts
=
0
;
p_sys
->
b_has_b_frames
=
VLC_FALSE
;
p_sys
->
b_first_frame
=
VLC_TRUE
;
p_sys
->
i_late_frames
=
0
;
p_sys
->
i_buffer
=
0
;
p_sys
->
i_buffer_orig
=
1
;
...
...
@@ -518,7 +522,8 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
i_used
=
avcodec_decode_video
(
p_sys
->
p_context
,
p_sys
->
p_ff_pic
,
&
b_gotpicture
,
p_sys
->
p_buffer
,
p_sys
->
i_buffer
);
if
(
b_null_size
&&
p_sys
->
p_context
->
width
>
0
&&
p_sys
->
p_context
->
height
>
0
)
if
(
b_null_size
&&
p_sys
->
p_context
->
width
>
0
&&
p_sys
->
p_context
->
height
>
0
)
{
/* Reparse it to not drop the I frame */
b_null_size
=
VLC_FALSE
;
...
...
@@ -610,6 +615,13 @@ picture_t *E_(DecodeVideo)( decoder_t *p_dec, block_t **pp_block )
p_sys
->
p_context
->
frame_rate_base
/
(
2
*
p_sys
->
p_context
->
frame_rate
);
}
if
(
p_sys
->
b_first_frame
)
{
/* Hack to force display of still pictures */
p_sys
->
b_first_frame
=
VLC_FALSE
;
p_pic
->
b_force
=
VLC_TRUE
;
}
return
p_pic
;
}
else
...
...
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