Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
4764daf3
Commit
4764daf3
authored
Feb 03, 2012
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
decoder/ffmpeg: pass tag_type and name to _copy_metadata()
Allow using this function without the ffmpeg_tag_map struct.
parent
6357496d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
ffmpeg_decoder_plugin.c
src/decoder/ffmpeg_decoder_plugin.c
+6
-5
No files found.
src/decoder/ffmpeg_decoder_plugin.c
View file @
4764daf3
...
...
@@ -614,20 +614,21 @@ static const ffmpeg_tag_map ffmpeg_tag_maps[] = {
#endif
static
void
ffmpeg_copy_metadata
(
struct
tag
*
tag
,
AVDictionary
*
m
,
const
ffmpeg_tag_map
tag_map
)
ffmpeg_copy_metadata
(
struct
tag
*
tag
,
enum
tag_type
type
,
AVDictionary
*
m
,
const
char
*
name
)
{
AVDictionaryEntry
*
mt
=
NULL
;
while
((
mt
=
av_dict_get
(
m
,
tag_map
.
name
,
mt
,
0
))
!=
NULL
)
tag_add_item
(
tag
,
t
ag_map
.
t
ype
,
mt
->
value
);
while
((
mt
=
av_dict_get
(
m
,
name
,
mt
,
0
))
!=
NULL
)
tag_add_item
(
tag
,
type
,
mt
->
value
);
}
static
void
ffmpeg_copy_dictionary
(
struct
tag
*
tag
,
AVDictionary
*
dict
)
{
for
(
unsigned
i
=
0
;
i
<
G_N_ELEMENTS
(
ffmpeg_tag_maps
);
i
++
)
ffmpeg_copy_metadata
(
tag
,
dict
,
ffmpeg_tag_maps
[
i
]);
ffmpeg_copy_metadata
(
tag
,
ffmpeg_tag_maps
[
i
].
type
,
dict
,
ffmpeg_tag_maps
[
i
].
name
);
}
#endif
...
...
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