Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
26e0454c
Commit
26e0454c
authored
Mar 09, 2024
by
Marton Balint
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avformat/mov_chan: simplify channel layout canonicalization
Signed-off-by:
Marton Balint
<
cus@passwd.hu
>
parent
ed620727
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
mov_chan.c
libavformat/mov_chan.c
+4
-8
No files found.
libavformat/mov_chan.c
View file @
26e0454c
...
...
@@ -543,10 +543,8 @@ int ff_mov_read_chan(AVFormatContext *s, AVIOContext *pb, AVStream *st,
ch_layout
->
u
.
map
[
i
].
id
=
mov_get_channel_id
(
label
);
}
ret
=
av_channel_layout_retype
(
ch_layout
,
AV_CHANNEL_ORDER_NATIVE
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_LOSSLESS
);
if
(
ret
==
AVERROR
(
ENOSYS
))
ret
=
av_channel_layout_retype
(
ch_layout
,
AV_CHANNEL_ORDER_UNSPEC
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_LOSSLESS
);
if
(
ret
<
0
&&
ret
!=
AVERROR
(
ENOSYS
))
ret
=
av_channel_layout_retype
(
ch_layout
,
0
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_CANONICAL
);
if
(
ret
<
0
)
goto
out
;
}
else
{
uint64_t
mask
=
mov_get_channel_layout
(
layout_tag
,
bitmap
);
...
...
@@ -843,10 +841,8 @@ int ff_mov_read_chnl(AVFormatContext *s, AVIOContext *pb, AVStream *st)
ch_layout
->
u
.
map
[
i
].
id
=
channel
;
}
ret
=
av_channel_layout_retype
(
ch_layout
,
AV_CHANNEL_ORDER_NATIVE
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_LOSSLESS
);
if
(
ret
==
AVERROR
(
ENOSYS
))
ret
=
av_channel_layout_retype
(
ch_layout
,
AV_CHANNEL_ORDER_UNSPEC
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_LOSSLESS
);
if
(
ret
<
0
&&
ret
!=
AVERROR
(
ENOSYS
))
ret
=
av_channel_layout_retype
(
ch_layout
,
0
,
AV_CHANNEL_LAYOUT_RETYPE_FLAG_CANONICAL
);
if
(
ret
<
0
)
return
ret
;
}
else
{
uint64_t
omitted_channel_map
=
avio_rb64
(
pb
);
...
...
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