Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
1ba7797b
Commit
1ba7797b
authored
May 26, 2009
by
Rémi Duraffort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wpl/zpl: really compile the modules and fixe some issues.
(still some issues that I will fixe later on)
parent
c790b667
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
103 additions
and
129 deletions
+103
-129
modules/demux/playlist/Modules.am
modules/demux/playlist/Modules.am
+14
-12
modules/demux/playlist/playlist.c
modules/demux/playlist/playlist.c
+12
-0
modules/demux/playlist/playlist.h
modules/demux/playlist/playlist.h
+6
-0
modules/demux/playlist/wpl.c
modules/demux/playlist/wpl.c
+15
-21
modules/demux/playlist/zpl.c
modules/demux/playlist/zpl.c
+56
-96
No files found.
modules/demux/playlist/Modules.am
View file @
1ba7797b
SOURCES_playlist = \
playlist.c \
playlist.h \
m3u.c \
ram.c \
asx.c \
b4s.c \
pls.c \
dvb.c \
podcast.c \
xspf.c \
xspf.h \
shoutcast.c \
asx.c \
sgimb.c \
qtl.c \
gvp.c \
ifo.c \
itml.c \
itml.h \
m3u.c \
playlist.c \
playlist.h \
pls.c \
podcast.c \
qtl.c \
ram.c \
sgimb.c \
shoutcast.c \
wpl.c \
xspf.c \
xspf.h \
zpl.c \
$(NULL)
libvlc_LTLIBRARIES += libplaylist_plugin.la
modules/demux/playlist/playlist.c
View file @
1ba7797b
...
...
@@ -151,6 +151,18 @@ vlc_module_begin ()
add_shortcut
(
"itml"
)
set_capability
(
"demux"
,
10
)
set_callbacks
(
Import_iTML
,
Close_iTML
)
add_submodule
()
set_description
(
N_
(
"WPL playlist"
)
)
add_shortcut
(
"playlist"
)
add_shortcut
(
"wpl"
)
set_capability
(
"demux"
,
10
)
set_callbacks
(
Import_WPL
,
Close_WPL
)
add_submodule
()
set_description
(
N_
(
"ZPL playlist"
)
)
add_shortcut
(
"playlist"
)
add_shortcut
(
"zpl"
)
set_capability
(
"demux"
,
10
)
set_callbacks
(
Import_ZPL
,
Close_ZPL
)
vlc_module_end
()
...
...
modules/demux/playlist/playlist.h
View file @
1ba7797b
...
...
@@ -76,6 +76,12 @@ void Close_VideoPortal ( vlc_object_t * );
int
Import_iTML
(
vlc_object_t
*
);
void
Close_iTML
(
vlc_object_t
*
);
int
Import_WPL
(
vlc_object_t
*
);
void
Close_WPL
(
vlc_object_t
*
);
int
Import_ZPL
(
vlc_object_t
*
);
void
Close_ZPL
(
vlc_object_t
*
);
#define INIT_PLAYLIST_STUFF \
input_thread_t *p_input_thread = (input_thread_t *)vlc_object_find( p_demux, VLC_OBJECT_INPUT, FIND_PARENT ); \
input_item_t *p_current_input = input_GetItem( p_input_thread );
...
...
modules/demux/playlist/wpl.c
View file @
1ba7797b
...
...
@@ -101,31 +101,28 @@ static int Demux( demux_t *p_demux )
while
(
psz_line
)
{
psz_parse
=
psz_line
;
/* Skip leading tabs and spaces */
while
(
*
psz_parse
==
' '
||
*
psz_parse
==
'\t'
||
*
psz_parse
==
'\n'
||
*
psz_parse
==
'\r'
)
psz_parse
++
;
while
(
*
psz_parse
==
' '
||
*
psz_parse
==
'\t'
||
*
psz_parse
==
'\n'
||
*
psz_parse
==
'\r'
)
psz_parse
++
;
if
(
!
strncasecmp
(
psz_parse
,
"<media src=
\"
"
,
sizeof
(
"<media src=
\"
"
)
-
1
)
)
/*if the line is uri of media item*/
/* if the line is the uri of the media item */
if
(
!
strncasecmp
(
psz_parse
,
"<media src=
\"
"
,
strlen
(
"<media src=
\"
"
)
)
)
{
psz_uri
=
ParseUriValue
(
psz_parse
);
if
(
psz_uri
&&
*
psz_uri
)
if
(
!
EMPTY_STR
(
psz_uri
)
)
{
psz_uri
=
ProcessMRL
(
psz_uri
,
p_demux
->
p_sys
->
psz_prefix
);
MaybeFromLocaleRep
(
&
psz_uri
);
p_input
=
input_item_NewExt
(
p_demux
,
psz_uri
,
psz_uri
,
0
,
NULL
,
0
,
-
1
);
input_item_AddSubItem
(
p_current_input
,
p_input
);
p_input
=
NULL
;
free
(
psz_uri
);
}
free
(
psz_uri
);
}
free
(
psz_line
);
psz_line
=
NULL
;
/* Fetch another line */
free
(
psz_line
);
psz_line
=
stream_ReadLine
(
p_demux
->
s
);
}
...
...
@@ -140,21 +137,18 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
return
VLC_EGENERIC
;
}
static
char
*
ParseUriValue
(
char
*
psz_string
)
static
char
*
ParseUriValue
(
char
*
psz_string
)
{
int
i_len
=
strlen
(
psz_string
);
if
(
i_len
<=
3
)
if
(
i_len
<=
3
)
return
NULL
;
char
*
psz_value
=
(
char
*
)
malloc
(
i_len
);
if
(
!
psz_value
)
char
*
psz_value
=
calloc
(
i_len
,
1
);
if
(
!
psz_value
)
return
NULL
;
memset
(
psz_value
,
0
,
i_len
);
sscanf
(
psz_string
,
"%*[^=]=
\"
%[^
\0\r\t\n\"
]"
,
psz_value
);
if
(
strlen
(
psz_value
)
)
return
psz_value
;
free
(
psz_value
);
return
NULL
;
sscanf
(
psz_string
,
"%*[^=]=
\"
%[^
\r\t\n\"
]"
,
psz_value
);
return
psz_value
;
}
modules/demux/playlist/zpl.c
View file @
1ba7797b
This diff is collapsed.
Click to expand it.
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