1 /* 2 * Copyright 2021 Rockchip Electronics Co. LTD 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 #ifndef SRC_TESTS_RT_MPI_COMMON_TEST_COMM_VGS_H_ 18 #define SRC_TESTS_RT_MPI_COMMON_TEST_COMM_VGS_H_ 19 20 #include "rk_common.h" 21 #include "rk_comm_vgs.h" 22 23 #ifdef __cplusplus 24 #if __cplusplus 25 extern "C" { 26 #endif 27 #endif /* End of #ifdef __cplusplus */ 28 29 typedef enum TEST_VGS_OP_TYPE_E { 30 VGS_OP_QUICK_COPY = 0, 31 VGS_OP_QUICK_RESIZE, 32 VGS_OP_QUICK_FILL, 33 VGS_OP_ROTATION, 34 VGS_OP_MIRROR, 35 VGS_OP_COLOR_KEY 36 } TEST_VGS_OP_TYPE_E; 37 38 typedef struct _TEST_VGS_PROC_CTX { 39 const char *srcFileName; 40 const char *dstFileName; 41 VIDEO_FRAME_INFO_S stImgIn; 42 VIDEO_FRAME_INFO_S stImgOut; 43 TEST_VGS_OP_TYPE_E stOpt; 44 RK_S32 fillData; 45 ROTATION_E rotateAngle; 46 TEST_VGS_OP_TYPE_E opType; 47 RK_S32 s32JobNum; 48 RK_S32 s32TaskNum; 49 RK_S32 s32ProcessTimes; 50 RK_S64 s32ProcessTotalTime; 51 RK_DOUBLE s32fps; 52 } TEST_VGS_PROC_CTX_S; 53 54 RK_S32 TEST_VGS_BeginJob(VGS_HANDLE *jobHandle); 55 RK_S32 TEST_VGS_AddTask(TEST_VGS_PROC_CTX_S *pstCtx, VGS_HANDLE jobHandle); 56 RK_S32 TEST_VGS_EndJob(VGS_HANDLE jobHandle); 57 58 RK_S32 TEST_VGS_LoadSrcFrame(TEST_VGS_PROC_CTX_S *pstCtx); 59 RK_S32 TEST_VGS_CreateDstFrame(TEST_VGS_PROC_CTX_S *pstCtx); 60 RK_S32 TEST_VGS_CreateDstCMAFrame(TEST_VGS_PROC_CTX_S *pstCtx); 61 RK_S32 TEST_VGS_ProcessJob(TEST_VGS_PROC_CTX_S *pstCtx, VIDEO_FRAME_INFO_S *pstFrames); 62 RK_S32 TEST_VGS_MultiTest(TEST_VGS_PROC_CTX_S *ctx); 63 64 #ifdef __cplusplus 65 #if __cplusplus 66 } 67 #endif 68 #endif /* End of #ifdef __cplusplus */ 69 70 #endif // SRC_TESTS_RT_MPI_COMMON_TEST_COMM_VGS_H_ 71