1 /* SPDX-License-Identifier: Apache-2.0 OR MIT */ 2 /* 3 * Copyright (c) 2024 Rockchip Electronics Co., Ltd. 4 */ 5 6 #ifndef __MPP_SYS_CFG_ST_H__ 7 #define __MPP_SYS_CFG_ST_H__ 8 9 #include "rk_type.h" 10 #include "mpp_err.h" 11 12 #include "mpp_frame.h" 13 14 typedef struct MppSysCfgStHStrd_t { 15 /* input args start */ 16 MppCodingType type; 17 RK_U32 fmt_fbc; 18 RK_U32 width; 19 RK_U32 h_stride_by_byte; 20 21 /* output args start */ 22 RK_U32 h_stride_by_pixel; 23 } MppSysCfgStHStrd; 24 25 typedef struct MppSysCfgStHByteStrd_t { 26 /* input args start */ 27 MppCodingType type; 28 MppFrameFormat fmt_codec; 29 RK_U32 fmt_fbc; 30 RK_U32 width; 31 32 /* in/output args start */ 33 RK_U32 h_stride_by_byte; 34 } MppSysCfgStHByteStrd; 35 36 typedef struct MppSysCfgStVStrd_t { 37 /* input args start */ 38 MppCodingType type; 39 RK_U32 fmt_fbc; 40 RK_U32 height; 41 42 /* in/output args start */ 43 RK_U32 v_stride; 44 } MppSysCfgStVStrd; 45 46 typedef struct MppSysCfgStSize_t { 47 /* input args start */ 48 MppCodingType type; 49 MppFrameFormat fmt_codec; 50 RK_U32 fmt_fbc; 51 RK_U32 width; 52 RK_U32 height; 53 54 /* in/output args start */ 55 RK_U32 h_stride_by_byte; 56 RK_U32 v_stride; 57 58 /* output args start */ 59 RK_U32 h_stride_by_pixel; 60 RK_U32 size_total; 61 RK_U32 size_fbc_hdr; 62 RK_U32 size_fbc_bdy; 63 } MppSysCfgStSize; 64 65 #ifdef __cplusplus 66 extern "C" { 67 #endif 68 69 MPP_RET mpp_sys_cfg_st_get_h_stride(MppSysCfgStHStrd *h_stride_cfg); 70 MPP_RET mpp_sys_cfg_st_get_byte_stride(MppSysCfgStHByteStrd *byte_stride_cfg); 71 MPP_RET mpp_sys_cfg_st_get_v_stride(MppSysCfgStVStrd *v_stride_cfg); 72 MPP_RET mpp_sys_cfg_st_get_size(MppSysCfgStSize *size_cfg); 73 74 #ifdef __cplusplus 75 } 76 #endif 77 78 #endif /* MPP_SYS_CFGI_H__ */ 79