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
bc133f33
Commit
bc133f33
authored
Jul 26, 2006
by
Filippo Carone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More vlm functions added in libvlc (to play, pause and stop a broadcast)
parent
0e977f2f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
83 additions
and
0 deletions
+83
-0
include/vlc/libvlc.h
include/vlc/libvlc.h
+26
-0
src/control/vlm.c
src/control/vlm.c
+57
-0
No files found.
include/vlc/libvlc.h
View file @
bc133f33
...
...
@@ -467,6 +467,32 @@ void libvlc_vlm_set_loop( libvlc_instance_t *, char *, int,
void
libvlc_vlm_change_media
(
libvlc_instance_t
*
,
char
*
,
char
*
,
char
*
,
int
,
char
**
,
int
,
int
,
libvlc_exception_t
*
);
/**
* Plays the named broadcast.
* \param p_instance the instance
* \param psz_name the name of the broadcast
* \param p_exception an initialized exception
*/
void
libvlc_vlm_play_media
(
libvlc_instance_t
*
,
char
*
,
libvlc_exception_t
*
);
/**
* Stops the named broadcast.
* \param p_instance the instance
* \param psz_name the name of the broadcast
* \param p_exception an initialized exception
*/
void
libvlc_vlm_stop_media
(
libvlc_instance_t
*
,
char
*
,
libvlc_exception_t
*
);
/**
* Pauses the named broadcast.
* \param p_instance the instance
* \param psz_name the name of the broadcast
* \param p_exception an initialized exception
*/
void
libvlc_vlm_pause_media
(
libvlc_instance_t
*
,
char
*
,
libvlc_exception_t
*
);
/** @} */
/** @} */
...
...
src/control/vlm.c
View file @
bc133f33
...
...
@@ -236,3 +236,60 @@ void libvlc_vlm_change_media( libvlc_instance_t *p_instance, char *psz_name,
vlc_mutex_unlock
(
&
p_instance
->
p_vlm
->
lock
);
#endif
}
void
libvlc_vlm_play_media
(
libvlc_instance_t
*
p_instance
,
char
*
psz_name
,
libvlc_exception_t
*
p_exception
)
{
char
*
psz_message
;
vlm_message_t
*
answer
;
CHECK_VLM
;
#ifdef ENABLE_VLM
asprintf
(
&
psz_message
,
"control %s play"
,
psz_name
);
vlm_ExecuteCommand
(
p_instance
->
p_vlm
,
psz_message
,
&
answer
);
if
(
answer
->
psz_value
)
{
libvlc_exception_raise
(
p_exception
,
"Unable to play %s"
,
psz_name
);
}
free
(
psz_message
);
#endif
}
void
libvlc_vlm_stop_media
(
libvlc_instance_t
*
p_instance
,
char
*
psz_name
,
libvlc_exception_t
*
p_exception
)
{
char
*
psz_message
;
vlm_message_t
*
answer
;
CHECK_VLM
;
#ifdef ENABLE_VLM
asprintf
(
&
psz_message
,
"control %s stop"
,
psz_name
);
vlm_ExecuteCommand
(
p_instance
->
p_vlm
,
psz_message
,
&
answer
);
if
(
answer
->
psz_value
)
{
libvlc_exception_raise
(
p_exception
,
"Unable to stop %s"
,
psz_name
);
}
free
(
psz_message
);
#endif
}
void
libvlc_vlm_pause_media
(
libvlc_instance_t
*
p_instance
,
char
*
psz_name
,
libvlc_exception_t
*
p_exception
)
{
char
*
psz_message
;
vlm_message_t
*
answer
;
CHECK_VLM
;
#ifdef ENABLE_VLM
asprintf
(
&
psz_message
,
"control %s pause"
,
psz_name
);
vlm_ExecuteCommand
(
p_instance
->
p_vlm
,
psz_message
,
&
answer
);
if
(
answer
->
psz_value
)
{
libvlc_exception_raise
(
p_exception
,
"Unable to pause %s"
,
psz_name
);
}
free
(
psz_message
);
#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