From 8fb24547e4d068cdcd491e59ddc451b3a252ea4b Mon Sep 17 00:00:00 2001
From: zhangmeng <775834166@qq.com>
Date: 星期二, 30 七月 2019 15:42:53 +0800
Subject: [PATCH] update rec frame id
---
goffmpeg.go | 2 +-
libcffmpeg.c | 4 ++--
libcffmpeg.h | 4 ++--
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/goffmpeg.go b/goffmpeg.go
index ca948ab..d79d0ba 100644
--- a/goffmpeg.go
+++ b/goffmpeg.go
@@ -183,7 +183,7 @@
func (h *GoFFMPEG) GetPicDecoder() ([]byte, int, int, int64) {
var width C.int
var height C.int
- var fid C.longlong
+ var fid C.long
p := C.wrap_fn_decoder_pic(h.ffmpeg, &width, &height, &fid)
if width == 0 && height == 0 {
diff --git a/libcffmpeg.c b/libcffmpeg.c
index a380de4..6cb7e5a 100644
--- a/libcffmpeg.c
+++ b/libcffmpeg.c
@@ -109,8 +109,8 @@
fn_decoder(h);
}
-void* wrap_fn_decoder_pic(const cffmpeg h, int* wid, int* hei){
- return fn_decoder_pic(h, wid, hei);
+void* wrap_fn_decoder_pic(const cffmpeg h, int* wid, int* hei, int64_t *id){
+ return fn_decoder_pic(h, wid, hei, id);
}
void* wrap_fn_get_avpacket(const cffmpeg h, int* size, int* key){
diff --git a/libcffmpeg.h b/libcffmpeg.h
index 7c31723..cbcf14c 100644
--- a/libcffmpeg.h
+++ b/libcffmpeg.h
@@ -21,7 +21,7 @@
typedef char*(*lib_cffmpeg_info_recorder)(const cffmpeg, int*, int*);
typedef char*(*lib_cffmpeg_rec_id)(const cffmpeg, const char*, int*);
typedef void (*lib_cffmpeg_decoder)(const cffmpeg);
-typedef void*(*lib_cffmpeg_pic)(const cffmpeg, int*, int*);
+typedef void*(*lib_cffmpeg_pic)(const cffmpeg, int*, int*, int64_t*);
typedef void*(*lib_cffmpeg_avpacket)(const cffmpeg, int*, int*);
typedef void*(*lib_cffmpeg_decode_jpeg)(const cffmpeg, const char*, int*, int*);
@@ -55,7 +55,7 @@
char* wrap_fn_info_recorder(const cffmpeg, int* index, int* length);
char* wrap_fn_rec_id(const cffmpeg h, const char* path, int*length);
void wrap_fn_decoder(const cffmpeg h);
-void* wrap_fn_decoder_pic(const cffmpeg h, int* wid, int* hei);
+void* wrap_fn_decoder_pic(const cffmpeg h, int* wid, int* hei, int64_t *id);
void* wrap_fn_get_avpacket(const cffmpeg h, int* size, int* key);
void* wrap_fn_decode_jpeg(const cffmpeg h, const char* file, int* wid, int* hei);
--
Gitblit v1.8.0