Browse Source

* use larger buffer - the size should be calculcated from the bitstream

data rate and outgoing samples (i.e. WMA could generate a lot of samples
  from 4096KB chunks)
  FIXME

Originally committed as revision 1169 to svn://svn.ffmpeg.org/ffmpeg/trunk
tags/v0.5
Zdenek Kabelac 23 years ago
parent
commit
ff29712a3d
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      ffmpeg.c

+ 2
- 2
ffmpeg.c View File

@@ -301,7 +301,7 @@ static void do_audio_out(AVFormatContext *s,
{
UINT8 *buftmp;
UINT8 audio_buf[2*MAX_AUDIO_PACKET_SIZE]; /* XXX: allocate it */
UINT8 audio_out[MAX_AUDIO_PACKET_SIZE]; /* XXX: allocate it */
UINT8 audio_out[4*MAX_AUDIO_PACKET_SIZE]; /* XXX: allocate it - yep really WMA */
int size_out, frame_bytes, ret;
AVCodecContext *enc;

@@ -346,7 +346,7 @@ static void do_audio_out(AVFormatContext *s,
break;
}
ret = avcodec_encode_audio(enc, audio_out, size_out,
(short *)buftmp);
(short *)buftmp);
av_write_frame(s, ost->index, audio_out, ret);
}
}


Loading…
Cancel
Save