diff mbox series

[FFmpeg-devel,5/7] avcodec/adpcm_yamaha: support variable block size for encoding

Message ID 20201014130915.25948-5-zane@zanevaniperen.com
State Accepted
Commit ed1cfb8e318e052aa1b096c48a12c656b3df9521
Headers show
Series [FFmpeg-devel,1/7] avcodec/adpcmenc: add "block_size" option | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished

Commit Message

Zane van Iperen Oct. 14, 2020, 1:10 p.m. UTC
Signed-off-by: Zane van Iperen <zane@zanevaniperen.com>
---
 libavcodec/adpcmenc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/adpcmenc.c b/libavcodec/adpcmenc.c
index d234d3dbf2..800a9b0b00 100644
--- a/libavcodec/adpcmenc.c
+++ b/libavcodec/adpcmenc.c
@@ -142,8 +142,8 @@  static av_cold int adpcm_encode_init(AVCodecContext *avctx)
         }
         break;
     case AV_CODEC_ID_ADPCM_YAMAHA:
-        avctx->frame_size  = BLKSIZE * 2 / avctx->channels;
-        avctx->block_align = BLKSIZE;
+        avctx->frame_size  = s->block_size * 2 / avctx->channels;
+        avctx->block_align = s->block_size;
         break;
     case AV_CODEC_ID_ADPCM_SWF:
         if (avctx->sample_rate != 11025 &&