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
a58858d6
Commit
a58858d6
authored
Jul 12, 2011
by
Alex Converse
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavf: Cleanup try_decode_frame() logic.
This fixes AAC playback in ffplay.
parent
71a1d111
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
9 deletions
+3
-9
aacdec.c
libavcodec/aacdec.c
+0
-3
utils.c
libavformat/utils.c
+3
-6
No files found.
libavcodec/aacdec.c
View file @
a58858d6
...
...
@@ -568,9 +568,6 @@ static av_cold int aac_decode_init(AVCodecContext *avctx)
ac
->
m4ac
.
sample_rate
=
avctx
->
sample_rate
;
if
(
avctx
->
extradata_size
>
0
)
{
avctx
->
channels
=
0
;
avctx
->
frame_size
=
0
;
avctx
->
sample_rate
=
0
;
if
(
decode_audio_specific_config
(
ac
,
ac
->
avctx
,
&
ac
->
m4ac
,
avctx
->
extradata
,
avctx
->
extradata_size
)
<
0
)
...
...
libavformat/utils.c
View file @
a58858d6
...
...
@@ -2090,7 +2090,8 @@ static int try_decode_frame(AVStream *st, AVPacket *avpkt, AVDictionary **option
return
ret
;
}
if
(
!
has_codec_parameters
(
st
->
codec
)
||
!
has_decode_delay_been_guessed
(
st
)){
if
(
!
has_codec_parameters
(
st
->
codec
)
||
!
has_decode_delay_been_guessed
(
st
)
||
(
!
st
->
codec_info_nb_frames
&&
st
->
codec
->
codec
->
capabilities
&
CODEC_CAP_CHANNEL_CONF
))
{
switch
(
st
->
codec
->
codec_type
)
{
case
AVMEDIA_TYPE_VIDEO
:
avcodec_get_frame_defaults
(
&
picture
);
...
...
@@ -2387,11 +2388,7 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
least one frame of codec data, this makes sure the codec initializes
the channel configuration and does not only trust the values from the container.
*/
if
(
!
has_codec_parameters
(
st
->
codec
)
||
!
has_decode_delay_been_guessed
(
st
)
||
(
st
->
codec
->
codec
&&
st
->
codec
->
codec
->
capabilities
&
CODEC_CAP_CHANNEL_CONF
))
try_decode_frame
(
st
,
pkt
,
(
options
&&
i
<=
orig_nb_streams
)
?
&
options
[
i
]
:
NULL
);
try_decode_frame
(
st
,
pkt
,
(
options
&&
i
<=
orig_nb_streams
)
?
&
options
[
i
]
:
NULL
);
st
->
codec_info_nb_frames
++
;
count
++
;
...
...
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