Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
5adb89a3
Commit
5adb89a3
authored
Jun 16, 2003
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/codec/ffmpeg/video.c: fixed the last direct rendering bug.
parent
c4d9a444
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
3 deletions
+14
-3
modules/codec/ffmpeg/video.c
modules/codec/ffmpeg/video.c
+14
-3
No files found.
modules/codec/ffmpeg/video.c
View file @
5adb89a3
...
...
@@ -2,7 +2,7 @@
* video.c: video decoder using ffmpeg library
*****************************************************************************
* Copyright (C) 1999-2001 VideoLAN
* $Id: video.c,v 1.3
0 2003/06/16 20:23:41
gbazin Exp $
* $Id: video.c,v 1.3
1 2003/06/16 20:49:12
gbazin Exp $
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Gildas Bazin <gbazin@netcourrier.com>
...
...
@@ -267,6 +267,8 @@ int E_( InitThread_Video )( vdec_thread_t *p_vdec )
p_vdec
->
p_context
->
pix_fmt
!=
PIX_FMT_YUV422P
&&
!
(
p_vdec
->
p_context
->
width
%
16
)
&&
!
(
p_vdec
->
p_context
->
height
%
16
)
)
{
/* Some codecs set pix_fmt only after the 1st frame has been decoded,
* so we need to do another check in ffmpeg_GetFrameBuf() */
p_vdec
->
b_direct_rendering
=
1
;
}
...
...
@@ -314,8 +316,6 @@ int E_( InitThread_Video )( vdec_thread_t *p_vdec )
if
(
p_vdec
->
b_direct_rendering
)
{
/* FIXME: some codecs set pix_fmt only after a frame
* has been decoded. */
msg_Dbg
(
p_vdec
->
p_fifo
,
"using direct rendering"
);
p_vdec
->
p_context
->
flags
|=
CODEC_FLAG_EMU_EDGE
;
p_vdec
->
p_context
->
get_buffer
=
ffmpeg_GetFrameBuf
;
...
...
@@ -754,6 +754,17 @@ static int ffmpeg_GetFrameBuf( struct AVCodecContext *p_context,
vdec_thread_t
*
p_vdec
=
(
vdec_thread_t
*
)
p_context
->
opaque
;
picture_t
*
p_pic
;
/* Some codecs set pix_fmt only after the 1st frame has been decoded,
* so this check is necessary. */
if
(
!
ffmpeg_PixFmtToChroma
(
p_context
->
pix_fmt
)
)
{
p_context
->
get_buffer
=
avcodec_default_get_buffer
;
p_context
->
release_buffer
=
avcodec_default_release_buffer
;
p_vdec
->
b_direct_rendering
=
0
;
msg_Dbg
(
p_vdec
->
p_fifo
,
"disabling direct rendering"
);
return
p_context
->
get_buffer
(
p_context
,
p_ff_pic
);
}
/* Check and (re)create our vout if needed */
p_vdec
->
p_vout
=
ffmpeg_CreateVout
(
p_vdec
,
p_vdec
->
p_context
);
if
(
!
p_vdec
->
p_vout
)
...
...
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