From 0560a8fce4c9d005655fce5025bc0fda8c58bff8 Mon Sep 17 00:00:00 2001 From: zhangmeng <775834166@qq.com> Date: 星期一, 02 十二月 2019 16:15:47 +0800 Subject: [PATCH] update --- libcffmpeg.h | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/libcffmpeg.h b/libcffmpeg.h index 8a6d7f7..dea90ba 100644 --- a/libcffmpeg.h +++ b/libcffmpeg.h @@ -23,6 +23,7 @@ typedef void (*lib_cffmpeg_info_recorder)(const cffmpeg, int*, char**, int*, char**, int*); typedef void (*lib_cffmpeg_decoder)(const cffmpeg); typedef void*(*lib_cffmpeg_pic)(const cffmpeg, int*, int*, int*, int*, int64_t*); +typedef void (*lib_cffmpeg_close_stream)(const cffmpeg); typedef void*(*lib_cffmpeg_avpacket)(const cffmpeg, int*, int*); static lib_cffmpeg_create fn_create = NULL; @@ -38,6 +39,7 @@ static lib_cffmpeg_info_recorder fn_info_recorder = NULL; static lib_cffmpeg_decoder fn_decoder = NULL; static lib_cffmpeg_pic fn_decoder_pic = NULL; +static lib_cffmpeg_close_stream fn_close_stream = NULL; static lib_cffmpeg_avpacket fn_get_avpacket = NULL; typedef void* libcffmpeg; @@ -57,10 +59,11 @@ void wrap_fn_info_recorder(void *lib, const cffmpeg, int* index, char** recid, int* recidLen, char** fpath, int* pathLen); void wrap_fn_decoder(void *lib, const cffmpeg h); void* wrap_fn_decoder_pic(void *lib, const cffmpeg h, int *wid, int *hei, int *format, int *length, int64_t *id); +void wrap_fn_close_stream(void *lib, const cffmpeg h); void* wrap_fn_get_avpacket(void *lib, const cffmpeg h, int* size, int* key); // for encoder typedef void* cencoder; -typedef cencoder (*lib_cffmpeg_create_encoder)(const int w, const int h, const int fps, const int br, const int scale_flag, const int gi); +typedef cencoder (*lib_cffmpeg_create_encoder)(const int w, const int h, const int fps, const int br, const int pix_fmt, const int scale_flag, const int gi); typedef void (*lib_cffmpeg_destroy_encoder)(cencoder h); typedef int (*lib_cffmpeg_encode)(cencoder hdl, uint8_t *in, const int w, const int h, uint8_t **out, int *size, int *key); @@ -68,7 +71,7 @@ static lib_cffmpeg_destroy_encoder fn_destroy_encoder = NULL; static lib_cffmpeg_encode fn_encode = NULL; -cencoder wrap_fn_create_encoder(void *lib, const int w, const int h, const int fps, const int br, const int scale_flag, const int gi); +cencoder wrap_fn_create_encoder(void *lib, const int w, const int h, const int fps, const int br, const int pix_fmt, const int scale_flag, const int gi); void wrap_fn_destroy_encoder(void *lib, const cencoder h); void* wrap_fn_encode(void *lib, cencoder hdl, void *in, const int w, const int h, int *out_size, int *key); -- Gitblit v1.8.0