[vlc-devel] [PATCH] Allow negative rates

Edward Wang edward.c.wang at compdigitec.com
Sat Aug 31 11:28:11 CEST 2013


On Fri, Aug 30, 2013 at 2:59 PM, Paul Clark <paul at packetship.com> wrote:

> Some inputs (e.g. RTSP) can provide negative rates (rewind) just fine
> ---
>  lib/media_player.c |    6 ------
>  1 file changed, 6 deletions(-)
>
> diff --git a/lib/media_player.c b/lib/media_player.c
> index b4a7250..c23dd42 100644
> --- a/lib/media_player.c
> +++ b/lib/media_player.c
> @@ -1232,12 +1232,6 @@ int libvlc_media_player_will_play(
> libvlc_media_player_t *p_mi )
>
>  int libvlc_media_player_set_rate( libvlc_media_player_t *p_mi, float rate
> )
>  {
> -    if (rate < 0.)
> -    {
> -        libvlc_printerr ("Playing backward not supported");
> -        return -1;
> -    }
> -
>      var_SetFloat (p_mi, "rate", rate);
>
>      input_thread_t *p_input_thread = libvlc_get_input_thread ( p_mi );
>
>
> I don't know if such an API exists, but should you not check if the access
supports it before enabling negative rates?

Regards,
     Edward Wang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20130831/c7f79348/attachment.html>


More information about the vlc-devel mailing list