[test]: Move some function to utils

Move yuv read function and yuv create function to utils.

Change-Id: I79a861ce869c182a27ed51a976eeb08f1f230d6e
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
This commit is contained in:
Herman Chen
2018-04-08 17:00:19 +08:00
parent 68e49f835c
commit 4e030fa170
6 changed files with 172 additions and 457 deletions

View File

@@ -18,6 +18,7 @@
#define __UTILS_H__
#include <stdio.h>
#include "mpp_err.h"
#include "mpp_frame.h"
typedef struct OptionInfo_t {
@@ -58,9 +59,15 @@ void calc_frm_crc(MppFrame frame, FrmCrc *crc);
void write_frm_crc(FILE *fp, FrmCrc *crc);
void read_frm_crc(FILE *fp, FrmCrc *crc);
MPP_RET read_yuv_image(RK_U8 *buf, FILE *fp, RK_U32 width, RK_U32 height,
RK_U32 hor_stride, RK_U32 ver_stride,
MppFrameFormat fmt);
MPP_RET fill_yuv_image(RK_U8 *buf, RK_U32 width, RK_U32 height,
RK_U32 hor_stride, RK_U32 ver_stride, MppFrameFormat fmt,
RK_U32 frame_count);
#ifdef __cplusplus
}
#endif
#endif /*__UTILS_H__*/