Changeset 12697ee7e4ab5e106afc9338b0b94e22330726c2

Show
Ignore:
Timestamp:
22/09/06 11:41:50 (2 years ago)
Author:
Damien Fouilleul <damienf@videolan.org>
git-committer:
Damien Fouilleul <damienf@videolan.org> 1158918110 +0000
git-parent:

[2d6ae8b8910dbecf245cfc7af63b05caf51495cb]

git-author:
Damien Fouilleul <damienf@videolan.org> 1158918110 +0000
Message:

input.c: fixed the playback rate (0.5 is half the speed, not twice)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • src/control/input.c

    rf485214 r12697ee  
    172172    input_thread_t *p_input_thread; 
    173173    vlc_value_t val; 
    174     val.i_int = rate*1000.0f; 
     174 
     175    if( rate <= 0 ) 
     176        RAISEVOID( "Rate value is invalid" ); 
     177 
     178    val.i_int = 1000.0f/rate; 
    175179     
    176180    p_input_thread = libvlc_get_input_thread ( p_input, p_e); 
     
    193197    vlc_object_release( p_input_thread ); 
    194198 
    195     return (float)val.i_int/1000.0f
     199    return (float)1000.0f/val.i_int
    196200} 
    197201