Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
b59b5633
Commit
b59b5633
authored
Sep 24, 2006
by
Clément Stenac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Detect embedded images
parent
be82b7ae
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
1 deletion
+20
-1
modules/meta_engine/taglib.cpp
modules/meta_engine/taglib.cpp
+20
-1
No files found.
modules/meta_engine/taglib.cpp
View file @
b59b5633
...
...
@@ -26,6 +26,8 @@
#include <fileref.h>
#include <tag.h>
#include <id3v2tag.h>
#include <mpegfile.h>
static
int
ReadMeta
(
vlc_object_t
*
);
...
...
@@ -33,7 +35,14 @@ vlc_module_begin();
set_capability
(
"meta reader"
,
1000
);
set_callbacks
(
ReadMeta
,
NULL
);
vlc_module_end
();
bool
checkID3Image
(
const
TagLib
::
ID3v2
::
Tag
*
tag
)
{
TagLib
::
ID3v2
::
FrameList
l
=
tag
->
frameListMap
()[
"APIC"
];
return
!
l
.
isEmpty
();
}
static
int
ReadMeta
(
vlc_object_t
*
p_this
)
{
demux_t
*
p_demux
=
(
demux_t
*
)
p_this
;
...
...
@@ -50,6 +59,16 @@ static int ReadMeta( vlc_object_t *p_this )
vlc_meta_SetTitle
(
p_meta
,
tag
->
title
().
toCString
(
true
)
);
vlc_meta_SetArtist
(
p_meta
,
tag
->
artist
().
toCString
(
true
)
);
if
(
TagLib
::
MPEG
::
File
*
mpeg
=
dynamic_cast
<
TagLib
::
MPEG
::
File
*>
(
f
.
file
()
)
)
{
if
(
mpeg
->
ID3v2Tag
()
&&
checkID3Image
(
mpeg
->
ID3v2Tag
()
)
)
{
fprintf
(
stderr
,
"%s has APIC
\n
"
,
p_meta
->
psz_title
);
vlc_meta_SetArtURL
(
p_meta
,
"APIC"
);
/// Means that the interface will use us to actually fetch it
}
}
return
VLC_SUCCESS
;
}
}
...
...
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