Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
de56dfd5
Commit
de56dfd5
authored
Jan 06, 2010
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tmp
parent
99017338
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
1 deletion
+40
-1
modules/misc/lua/Modules.am
modules/misc/lua/Modules.am
+1
-0
modules/misc/lua/vlc.c
modules/misc/lua/vlc.c
+6
-0
modules/misc/lua/vlc.h
modules/misc/lua/vlc.h
+2
-0
share/Makefile.am
share/Makefile.am
+1
-0
src/playlist/fetcher.c
src/playlist/fetcher.c
+30
-1
No files found.
modules/misc/lua/Modules.am
View file @
de56dfd5
SOURCES_lua = \
SOURCES_lua = \
intf.c \
intf.c \
meta.c \
meta.c \
decrapifier.c \
demux.c \
demux.c \
vlc.c \
vlc.c \
vlc.h \
vlc.h \
...
...
modules/misc/lua/vlc.c
View file @
de56dfd5
...
@@ -63,6 +63,12 @@ vlc_module_begin ()
...
@@ -63,6 +63,12 @@ vlc_module_begin ()
set_capability
(
"art finder"
,
10
)
set_capability
(
"art finder"
,
10
)
set_callbacks
(
FindArt
,
NULL
)
set_callbacks
(
FindArt
,
NULL
)
add_submodule
()
set_shortname
(
N_
(
"Lua Decrapifier"
)
)
set_description
(
N_
(
"Remove crappy part of the movie name"
)
)
set_capability
(
"movie name decrapifier"
,
10
)
set_callbacks
(
Decrapify
,
NULL
)
add_submodule
()
add_submodule
()
add_shortcut
(
"luaplaylist"
)
add_shortcut
(
"luaplaylist"
)
set_category
(
CAT_INPUT
)
set_category
(
CAT_INPUT
)
...
...
modules/misc/lua/vlc.h
View file @
de56dfd5
...
@@ -48,6 +48,8 @@
...
@@ -48,6 +48,8 @@
/*****************************************************************************
/*****************************************************************************
* Module entry points
* Module entry points
*****************************************************************************/
*****************************************************************************/
int
Decrapify
(
vlc_object_t
*
);
int
FindArt
(
vlc_object_t
*
);
int
FindArt
(
vlc_object_t
*
);
int
Import_LuaPlaylist
(
vlc_object_t
*
);
int
Import_LuaPlaylist
(
vlc_object_t
*
);
...
...
share/Makefile.am
View file @
de56dfd5
...
@@ -190,6 +190,7 @@ DIST_osdmenu_default = \
...
@@ -190,6 +190,7 @@ DIST_osdmenu_default = \
DIST_lua
=
\
DIST_lua
=
\
lua/README.txt
\
lua/README.txt
\
lua/decrapifier/standard.lua
\
lua/meta/README.txt
\
lua/meta/README.txt
\
lua/meta/01_musicbrainz.lua
\
lua/meta/01_musicbrainz.lua
\
lua/meta/10_googleimage.lua
\
lua/meta/10_googleimage.lua
\
...
...
src/playlist/fetcher.c
View file @
de56dfd5
...
@@ -33,6 +33,7 @@
...
@@ -33,6 +33,7 @@
#include <limits.h>
#include <limits.h>
#include <vlc_art_finder.h>
#include <vlc_art_finder.h>
#include <vlc_memory.h>
#include <vlc_memory.h>
#include <vlc_decrapifier.h>
#include "art.h"
#include "art.h"
#include "fetcher.h"
#include "fetcher.h"
...
@@ -122,10 +123,36 @@ void playlist_fetcher_Delete( playlist_fetcher_t *p_fetcher )
...
@@ -122,10 +123,36 @@ void playlist_fetcher_Delete( playlist_fetcher_t *p_fetcher )
free
(
p_fetcher
);
free
(
p_fetcher
);
}
}
/*****************************************************************************
/*****************************************************************************
* Privates functions
* Privates functions
*****************************************************************************/
*****************************************************************************/
/**
* This function's job is to call the movie name decrapifier
* Those plugins goal are to fill in information from the file itself.
* Without network connection.
*/
static
void
Decrapify
(
playlist_fetcher_t
*
p_fetcher
,
input_item_t
*
p_item
)
{
vlc_object_t
*
p_parent
=
VLC_OBJECT
(
p_fetcher
->
p_playlist
);
decrapifier_t
*
p_decrapifier
=
vlc_custom_create
(
p_parent
,
sizeof
(
*
p_decrapifier
),
VLC_OBJECT_GENERIC
,
"movie name decrapifier"
);
if
(
!
p_decrapifier
)
return
;
vlc_object_attach
(
p_decrapifier
,
p_parent
);
p_decrapifier
->
p_item
=
p_item
;
module_t
*
p_module
=
module_need
(
p_decrapifier
,
"movie name decrapifier"
,
NULL
,
false
);
if
(
p_module
)
module_unneed
(
p_decrapifier
,
p_module
);
vlc_object_release
(
p_decrapifier
);
}
/**
/**
* This function locates the art associated to an input item.
* This function locates the art associated to an input item.
* Return codes:
* Return codes:
...
@@ -411,6 +438,8 @@ static void *Thread( void *p_data )
...
@@ -411,6 +438,8 @@ static void *Thread( void *p_data )
/* Wait that the input item is preparsed if it is being played */
/* Wait that the input item is preparsed if it is being played */
WaitPreparsed
(
p_fetcher
,
p_item
);
WaitPreparsed
(
p_fetcher
,
p_item
);
Decrapify
(
p_fetcher
,
p_item
);
/* Find art, and download it if needed */
/* Find art, and download it if needed */
int
i_ret
=
FindArt
(
p_fetcher
,
p_item
);
int
i_ret
=
FindArt
(
p_fetcher
,
p_item
);
if
(
i_ret
==
1
)
if
(
i_ret
==
1
)
...
...
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