Revision a6080be7

View differences:

libavcodec/libvorbis.c
145 145
        int samples = OGGVORBIS_FRAME_SIZE;
146 146
        float **buffer ;
147 147

  
148
    buffer = vorbis_analysis_buffer(&context->vd, samples) ;
149

  
150
    if(context->vi.channels == 1) {
151
        for(l = 0 ; l < samples ; l++)
152
            buffer[0][l]=audio[l]/32768.f;
153
    } else {
154
        for(l = 0 ; l < samples ; l++){
155
            buffer[0][l]=audio[l*2]/32768.f;
156
            buffer[1][l]=audio[l*2+1]/32768.f;
148
        buffer = vorbis_analysis_buffer(&context->vd, samples) ;
149
        if(context->vi.channels == 1) {
150
            for(l = 0 ; l < samples ; l++)
151
                buffer[0][l]=audio[l]/32768.f;
152
        } else {
153
            for(l = 0 ; l < samples ; l++){
154
                buffer[0][l]=audio[l*2]/32768.f;
155
                buffer[1][l]=audio[l*2+1]/32768.f;
156
            }
157 157
        }
158
    }
159

  
160
    vorbis_analysis_wrote(&context->vd, samples) ;
158
        vorbis_analysis_wrote(&context->vd, samples) ;
161 159
    } else {
162 160
        if(!context->eof)
163 161
            vorbis_analysis_wrote(&context->vd, 0) ;

Also available in: Unified diff