From: Andre Noll Date: Sat, 17 Nov 2007 17:15:11 +0000 (+0100) Subject: Introduce vss_stopped(). X-Git-Tag: v0.3.0~113^2~8 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=77d2f77d29e7653bdf5659962782f80e8a643166;p=paraslash.git Introduce vss_stopped(). --- diff --git a/vss.c b/vss.c index e470a737..46fb3196 100644 --- a/vss.c +++ b/vss.c @@ -84,6 +84,18 @@ unsigned int vss_paused(void) && !(mmd->new_vss_status_flags & VSS_PLAYING); } +/** + * Check if the vss is currently stopped. + * + * \return Greater than zero if paused, zero otherwise. + * + */ +unsigned int vss_stopped(void) +{ + return (mmd->new_vss_status_flags & VSS_NEXT) + && !(mmd->new_vss_status_flags & VSS_PLAYING); +} + /** * Initialize the virtual streaming system. * diff --git a/vss.h b/vss.h index c521e0dd..eb3685fe 100644 --- a/vss.h +++ b/vss.h @@ -13,6 +13,7 @@ unsigned int vss_playing(void); unsigned int vss_next(void); unsigned int vss_repos(void); unsigned int vss_paused(void); +unsigned int vss_stopped(void); char *vss_get_header(size_t *header_len); struct timeval *vss_chunk_time(void); const char *supported_audio_formats(void);