From 7a7df34c91e16ea8936f59524145a2cdd6b790f9 Mon Sep 17 00:00:00 2001 From: James Almer Date: Tue, 28 Jul 2015 16:57:46 -0300 Subject: blowfish: add av_blowfish_alloc() Signed-off-by: James Almer Signed-off-by: Anton Khirnov --- libavutil/blowfish.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'libavutil/blowfish.h') diff --git a/libavutil/blowfish.h b/libavutil/blowfish.h index 8c29536cfe..4f86bf7cfb 100644 --- a/libavutil/blowfish.h +++ b/libavutil/blowfish.h @@ -22,6 +22,7 @@ #define AVUTIL_BLOWFISH_H #include +#include "version.h" /** * @defgroup lavu_blowfish Blowfish @@ -29,12 +30,21 @@ * @{ */ +#if FF_API_CRYPTO_CONTEXT #define AV_BF_ROUNDS 16 typedef struct AVBlowfish { uint32_t p[AV_BF_ROUNDS + 2]; uint32_t s[4][256]; } AVBlowfish; +#else +typedef struct AVBlowfish AVBlowfish; +#endif + +/** + * Allocate an AVBlowfish context. + */ +AVBlowfish *av_blowfish_alloc(void); /** * Initialize an AVBlowfish context. -- cgit v1.2.3