Changeset 3d90c11d8e9c238cd594a52f3dd026dea7f5cd57

Show
Ignore:
Timestamp:
05/30/08 15:07:30 (3 months ago)
Author:
Antoine Cellerier <dionoea@videolan.org>
git-committer:
Antoine Cellerier <dionoea@videolan.org> 1212152850 +0200
git-parent:

[af5aece7d5356daadacec2e260df961be78d3b6c]

git-author:
Antoine Cellerier <dionoea@videolan.org> 1212152845 +0200
Message:

Fix off by 1 errors (CID 42 and 43).

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • modules/visualization/visual/effects.c

    r1b72149 r3d90c11  
    178178    fft_perform( p_buffer1, p_output, p_state); 
    179179    for(i= 0; i< FFT_BUFFER_SIZE ; i++ ) 
    180         p_dest[i] = ( (int) sqrt( p_output [ i + 1 ] ) ) >> 8; 
     180        p_dest[i] = ( (int) sqrt( p_output [ i ] ) ) >> 8; 
    181181 
    182182    for ( i = 0 ; i< i_nb_bands ;i++) 
     
    478478    fft_perform( p_buffer1, p_output, p_state); 
    479479    for(i= 0; i< FFT_BUFFER_SIZE ; i++ ) 
    480         p_dest[i] = ( (int) sqrt( p_output [ i + 1 ] ) ) >> 8; 
     480        p_dest[i] = ( (int) sqrt( p_output [ i ] ) ) >> 8; 
    481481 
    482482    i_nb_bands *= i_sections;