]> git.sesse.net Git - ffmpeg/commitdiff
libavformat/crypto - encourage reads of 4096 bytes
authorSimon Hailes <btsimonh@googlemail.com>
Tue, 30 Aug 2016 07:47:02 +0000 (08:47 +0100)
committerMichael Niedermayer <michael@niedermayer.cc>
Tue, 30 Aug 2016 15:10:11 +0000 (17:10 +0200)
the current implementation reads in chunks of 149x16=2384 bytes.
Seems more logical for it to read in chunks of 4096

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavformat/crypto.c

index 2999f50046cf7caff09d76e1fc9a092d617f4a61..31a438c94ca3d4740d7193baeac486c2135dcacb 100644 (file)
@@ -26,7 +26,8 @@
 #include "internal.h"
 #include "url.h"
 
-#define MAX_BUFFER_BLOCKS 150
+// encourage reads of 4096 bytes - 1 block is always retained.
+#define MAX_BUFFER_BLOCKS 257
 #define BLOCKSIZE 16
 
 typedef struct CryptoContext {