Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZane van Iperen <zane@zanevaniperen.com>2020-10-17 06:55:51 +0300
committerZane van Iperen <zane@zanevaniperen.com>2020-10-21 04:26:39 +0300
commit4919b3c1c42377e17add834b8bf064d0dd8ae298 (patch)
tree151f55850ee5356f9d91311b5822c8970d738895 /libavcodec/adpcmenc.c
parent0547fa572bd88a20637508bd7dcf36e2953dc64d (diff)
avcodec/adpcm_swf: support custom block size for encoding
Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
Diffstat (limited to 'libavcodec/adpcmenc.c')
-rw-r--r--libavcodec/adpcmenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/adpcmenc.c b/libavcodec/adpcmenc.c
index 9e0bb831e8..6ecdab96d6 100644
--- a/libavcodec/adpcmenc.c
+++ b/libavcodec/adpcmenc.c
@@ -153,7 +153,7 @@ static av_cold int adpcm_encode_init(AVCodecContext *avctx)
"22050 or 44100\n");
return AVERROR(EINVAL);
}
- avctx->frame_size = 512 * (avctx->sample_rate / 11025);
+ avctx->frame_size = (s->block_size / 2) * (avctx->sample_rate / 11025);
avctx->block_align = (2 + avctx->channels * (22 + 4 * (avctx->frame_size - 1)) + 7) / 8;
break;
case AV_CODEC_ID_ADPCM_IMA_SSI: