Home
last modified time | relevance | path

Searched refs:hor_stride (Results 1 – 25 of 74) sorted by relevance

123

/rockchip-linux_mpp/mpp/hal/vpu/common/
H A Dvepu_common.c159 RK_S32 hor_stride, RK_S32 pixel_size) in check_stride_by_pixel() argument
161 if (!workaround && hor_stride < width * pixel_size) { in check_stride_by_pixel()
163 hor_stride, width, pixel_size); in check_stride_by_pixel()
165 hor_stride, pixel_size, hor_stride * pixel_size); in check_stride_by_pixel()
172 static RK_S32 check_8_pixel_aligned(RK_S32 workaround, RK_S32 hor_stride, in check_8_pixel_aligned() argument
176 if (!workaround && hor_stride != MPP_ALIGN_GEN(hor_stride, pixel_aign * pixel_size)) { in check_8_pixel_aligned()
180 MPP_ALIGN_GEN(hor_stride, pixel_aign * pixel_size)); in check_8_pixel_aligned()
189 RK_U32 hor_stride = stride; in get_vepu_pixel_stride() local
206 if (check_8_pixel_aligned(cfg->not_8_pixel, hor_stride, 8, 1, "YUV420SP")) { in get_vepu_pixel_stride()
207 hor_stride = MPP_ALIGN(hor_stride, 8); in get_vepu_pixel_stride()
[all …]
H A Dvepu_common.h63 RK_U32 hor_stride; member
/rockchip-linux_mpp/utils/
H A Dutils.c482 RK_S32 hor_stride, RK_S32 pix_w, FILE *fp) in read_with_pixel_width() argument
487 if (hor_stride < width * pix_w) { in read_with_pixel_width()
489 8 * pix_w, hor_stride, width, pix_w); in read_with_pixel_width()
493 hor_stride = width * pix_w; in read_with_pixel_width()
497 RK_S32 read_size = fread(buf + row * hor_stride, 1, width * pix_w, fp); in read_with_pixel_width()
513 RK_U32 hor_stride, RK_U32 ver_stride, MppFrameFormat fmt) in read_image() argument
519 RK_U8 *buf_u = buf_y + hor_stride * ver_stride; // NOTE: diff from gen_yuv_image in read_image()
520 RK_U8 *buf_v = buf_u + hor_stride * ver_stride / 4; // NOTE: diff from gen_yuv_image in read_image()
577 read_size = fread(buf_y + row * hor_stride, 1, width, fp); in read_image()
587 read_size = fread(buf_u + row * hor_stride, 1, width, fp); in read_image()
[all …]
H A Dutils.h69 RK_U32 hor_stride, RK_U32 ver_stride,
72 RK_U32 hor_stride, RK_U32 ver_stride, MppFrameFormat fmt,
/rockchip-linux_mpp/mpp/hal/rkenc/jpege/
H A Dhal_jpege_vpu720.c199 RK_U32 hor_stride = mpp_frame_get_hor_stride(task->frame); in jpege_vpu720_setup_format() local
210 fmt_cfg->y_stride = hor_stride * 4; in jpege_vpu720_setup_format()
216 fmt_cfg->y_stride = hor_stride * 4 * 3 / 2; in jpege_vpu720_setup_format()
221 fmt_cfg->y_stride = hor_stride * 4 * 2; in jpege_vpu720_setup_format()
226 fmt_cfg->y_stride = hor_stride * 4 * 3; in jpege_vpu720_setup_format()
237 fmt_cfg->y_stride = hor_stride; in jpege_vpu720_setup_format()
242 fmt_cfg->y_stride = hor_stride; in jpege_vpu720_setup_format()
243 fmt_cfg->uv_stride = hor_stride >> 1; in jpege_vpu720_setup_format()
244 fmt_cfg->u_offset = hor_stride * ver_stride; in jpege_vpu720_setup_format()
249 fmt_cfg->y_stride = hor_stride; in jpege_vpu720_setup_format()
[all …]
H A Dhal_jpege_vepu511.c130 RK_U32 hor_stride = syn->hor_stride; in vepu511_jpeg_set_patch_info() local
132 RK_U32 frame_size = hor_stride * ver_stride; in vepu511_jpeg_set_patch_info()
241 stridey = MPP_ALIGN(syn->hor_stride, 16) >> 2; in vepu511_set_jpeg_reg()
242 } else if (syn->hor_stride) { in vepu511_set_jpeg_reg()
243 stridey = syn->hor_stride; in vepu511_set_jpeg_reg()
/rockchip-linux_mpp/mpp/hal/vpu/jpege/
H A Dhal_jpege_vepu1_v2.c136 RK_U32 hor_stride = syntax->hor_stride; in hal_jpege_vepu1_set_extra_info() local
144 offset = 16 * start_mbrow * hor_stride; in hal_jpege_vepu1_set_extra_info()
149 offset = hor_stride * ver_stride + hor_stride * start_mbrow * 16 / 2; in hal_jpege_vepu1_set_extra_info()
151 offset = hor_stride * start_mbrow * 16 / 4 + hor_stride * ver_stride; in hal_jpege_vepu1_set_extra_info()
156 offset = hor_stride * start_mbrow * 16 / 4 + hor_stride * ver_stride * 5 / 4; in hal_jpege_vepu1_set_extra_info()
162 offset = start_mbrow * hor_stride; in hal_jpege_vepu1_set_extra_info()
182 RK_U32 hor_stride = 0; in hal_jpege_vepu1_gen_regs() local
213 hor_stride = get_vepu_pixel_stride(&ctx->stride_cfg, width, in hal_jpege_vepu1_gen_regs()
214 syntax->hor_stride, fmt); in hal_jpege_vepu1_gen_regs()
217 if ((hor_stride & 0x7) || (ver_stride & 0x1) || (hor_stride >= (1 << 15))) { in hal_jpege_vepu1_gen_regs()
[all …]
H A Dhal_jpege_vepu2_v2.c347 cfg.hor_stride = syntax->hor_stride; in hal_jpege_vepu2_set_extra_info()
376 RK_U32 hor_stride = 0; in hal_jpege_vepu2_gen_regs() local
407 hor_stride = get_vepu_pixel_stride(&ctx->stride_cfg, width, in hal_jpege_vepu2_gen_regs()
408 syntax->hor_stride, fmt); in hal_jpege_vepu2_gen_regs()
411 if ((hor_stride & 0x7) || (ver_stride & 0x1) || (hor_stride >= (1 << 15))) { in hal_jpege_vepu2_gen_regs()
413 syntax->hor_stride, syntax->ver_stride, in hal_jpege_vepu2_gen_regs()
464 regs[61] = hor_stride; in hal_jpege_vepu2_gen_regs()
659 cfg.hor_stride = syntax->hor_stride; in multi_core_start()
/rockchip-linux_mpp/mpp/
H A Dmpp_impl.c163 RK_U32 hor_stride = mpp_frame_get_hor_stride(frame); in dump_frame() local
172 if (hor_stride > w || ver_stride > h) { in dump_frame()
173 RK_U32 step = MPP_MAX((hor_stride + w - 1) / w, in dump_frame()
184 psrc += step * hor_stride; in dump_frame()
186 psrc = p_buf + hor_stride * ver_stride; in dump_frame()
194 psrc += step * hor_stride; in dump_frame()
203 psrc += hor_stride; in dump_frame()
205 psrc = p_buf + hor_stride * ver_stride; in dump_frame()
211 psrc += hor_stride; in dump_frame()
220 size = hor_stride * ver_stride * 3 / 2; in dump_frame()
[all …]
/rockchip-linux_mpp/mpp/hal/vpu/h264e/
H A Dhal_h264e_vepu_v2.c400 RK_S32 hor_stride = cfg->hor_stride; in h264e_vepu_prep_setup() local
406 get_vepu_pixel_stride(stride_cfg, prep->src_w, hor_stride, format); in h264e_vepu_prep_setup()
408 hor_stride = stride_cfg->pixel_stride * stride_cfg->pixel_size; in h264e_vepu_prep_setup()
412 prep->offset_cb = hor_stride * ver_stride; in h264e_vepu_prep_setup()
413 prep->size_y = hor_stride * MPP_ALIGN(prep->src_h, 16); in h264e_vepu_prep_setup()
414 prep->size_c = hor_stride / 2 * MPP_ALIGN(prep->src_h / 2, 8); in h264e_vepu_prep_setup()
417 prep->offset_cb = hor_stride * ver_stride; in h264e_vepu_prep_setup()
418 prep->offset_cr = prep->offset_cb + ((hor_stride * ver_stride) / 4); in h264e_vepu_prep_setup()
419 prep->size_y = hor_stride * MPP_ALIGN(prep->src_h, 16); in h264e_vepu_prep_setup()
420 prep->size_c = hor_stride / 2 * MPP_ALIGN(prep->src_h / 2, 8); in h264e_vepu_prep_setup()
[all …]
/rockchip-linux_mpp/mpp/legacy/
H A Dvpu_api_legacy.cpp242 RK_U32 hor_stride = MPP_ALIGN(width, 16); in copy_align_raw_buffer_to_dest() local
244 RK_U8 *dst_u = dst_buf + hor_stride * ver_stride; in copy_align_raw_buffer_to_dest()
245 RK_U8 *dst_v = dst_u + hor_stride * ver_stride / 4; in copy_align_raw_buffer_to_dest()
251 memcpy(dst_buf + row * hor_stride, src_buf + index, width); in copy_align_raw_buffer_to_dest()
255 memcpy(dst_u + row * hor_stride, src_buf + index, width); in copy_align_raw_buffer_to_dest()
261 memcpy(dst_buf + row * hor_stride, src_buf + index, width); in copy_align_raw_buffer_to_dest()
265 memcpy(dst_u + row * hor_stride / 2, src_buf + index, width / 2); in copy_align_raw_buffer_to_dest()
269 memcpy(dst_v + row * hor_stride / 2, src_buf + index, width / 2); in copy_align_raw_buffer_to_dest()
276 memcpy(dst_buf + row * hor_stride * 3, src_buf + row * width * 3, width * 3); in copy_align_raw_buffer_to_dest()
284 memcpy(dst_buf + row * hor_stride * 4, src_buf + row * width * 4, width * 4); in copy_align_raw_buffer_to_dest()
[all …]
/rockchip-linux_mpp/mpp/hal/vpu/jpegd/
H A Dhal_jpegd_common.c490 stride = s->hor_stride * 2; in jpegd_setup_output_fmt()
497 stride = s->hor_stride * 4; in jpegd_setup_output_fmt()
515 mpp_frame_set_hor_stride_pixel(frm, s->hor_stride); in jpegd_setup_output_fmt()
524 MPP_RET jpeg_image_check_size(RK_U32 hor_stride, RK_U32 ver_stride) in jpeg_image_check_size() argument
528 if (hor_stride > MAX_WIDTH || ver_stride > MAX_HEIGHT || in jpeg_image_check_size()
529 hor_stride < MIN_WIDTH || ver_stride < MIN_HEIGHT || in jpeg_image_check_size()
530 hor_stride * ver_stride > MAX_STREAM_LENGTH) { in jpeg_image_check_size()
531 mpp_err_f("unsupported resolution: %dx%d\n", hor_stride, ver_stride); in jpeg_image_check_size()
H A Dhal_jpegd_common.h81 MPP_RET jpeg_image_check_size(RK_U32 hor_stride, RK_U32 ver_stride);
H A Dhal_jpegd_vdpu1.c260 RK_U32 in_width = s->hor_stride; in jpegd_setup_pp()
262 RK_U32 out_width = s->hor_stride; in jpegd_setup_pp()
264 RK_U32 uv_offset = s->hor_stride * s->ver_stride; in jpegd_setup_pp()
661 reg->reg4.sw_pic_mb_w_ext = ((((s->hor_stride) >> (4)) & 0xE00) >> 9); in jpegd_gen_regs()
662 reg->reg4.sw_pic_mb_width = ((s->hor_stride) >> (4)) & 0x1FF; in jpegd_gen_regs()
853 ret = jpeg_image_check_size(syntax->hor_stride, syntax->ver_stride); in hal_jpegd_vdpu1_gen_regs()
1027 RK_U32 width = s->hor_stride; in hal_jpegd_vdpu1_wait()
H A Dhal_jpegd_vdpu2.c287 RK_U32 in_width = s->hor_stride; in jpegd_setup_pp()
289 RK_U32 out_width = s->hor_stride; in jpegd_setup_pp()
291 RK_U32 uv_offset = s->hor_stride * s->ver_stride; in jpegd_setup_pp()
651 reg->reg120.sw_pic_mb_w_ext = ((((s->hor_stride) >> (4)) & 0xE00) >> 9); in jpegd_gen_regs()
652 reg->reg120.sw_pic_mb_width = ((s->hor_stride) >> (4)) & 0x1FF; in jpegd_gen_regs()
838 ret = jpeg_image_check_size(syntax->hor_stride, syntax->ver_stride); in hal_jpegd_vdpu2_gen_regs()
995 RK_U32 width = syntax->hor_stride; in hal_jpegd_vdpu2_wait()
/rockchip-linux_mpp/mpp/hal/rkenc/common/
H A Dvepu540c_common.c101 RK_U32 hor_stride = syn->hor_stride; in vepu540c_jpeg_set_patch_info() local
103 RK_U32 frame_size = hor_stride * ver_stride; in vepu540c_jpeg_set_patch_info()
202 if (syn->hor_stride) { in vepu540c_set_jpeg_reg()
203 stridey = syn->hor_stride; in vepu540c_set_jpeg_reg()
/rockchip-linux_mpp/kmpp/base/inc/
H A Dkmpp_frame.h14 ENTRY(prefix, u32, rk_u32, hor_stride, FLAG_NONE, hor_stride) \
H A Dkmpp_frame_impl.h20 rk_u32 hor_stride; member
/rockchip-linux_mpp/test/
H A Dmpi_enc_mt_test.c71 RK_U32 hor_stride; member
153 p->hor_stride = (cmd->hor_stride) ? (cmd->hor_stride) : in mt_test_ctx_init()
215 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 3 / 2; in mt_test_ctx_init()
224 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 2; in mt_test_ctx_init()
241 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64); in mt_test_ctx_init()
245 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 4; in mt_test_ctx_init()
315 mpp_enc_cfg_set_s32(cfg, "prep:hor_stride", p->hor_stride); in test_mt_cfg_setup()
698 p->hor_stride, p->ver_stride, p->fmt); in enc_test_input()
719 ret = fill_image((RK_U8 *)buf, p->width, p->height, p->hor_stride, in enc_test_input()
746 mpp_frame_set_hor_stride(frame, p->hor_stride); in enc_test_input()
H A Dmpi_enc_test.c103 RK_U32 hor_stride; member
208 RK_U32 w = p->hor_stride, h = p->ver_stride; in get_mdinfo_size()
275 p->hor_stride = (cmd->hor_stride) ? (cmd->hor_stride) : in test_ctx_init()
346 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 3 / 2; in test_ctx_init()
355 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 2; in test_ctx_init()
372 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64); in test_ctx_init()
376 p->frame_size = MPP_ALIGN(p->hor_stride, 64) * MPP_ALIGN(p->ver_stride, 64) * 4; in test_ctx_init()
448 mpp_enc_cfg_set_s32(cfg, "prep:hor_stride", p->hor_stride); in test_mpp_enc_cfg_setup()
802 p->hor_stride, p->ver_stride, p->fmt); in test_mpp_run()
820 ret = fill_image(buf, p->width, p->height, p->hor_stride, in test_mpp_run()
[all …]
H A Dmpi_dec_multi_test.c141 RK_U32 hor_stride = mpp_frame_get_hor_stride(frame); in multi_dec_simple() local
148 width, height, hor_stride, ver_stride, buf_size); in multi_dec_simple()
431 RK_U32 hor_stride = MPP_ALIGN(width, 16); in multi_dec_decode() local
440 …dec_ctx->frm_grp = dec_buf_mgr_setup(dec_ctx->buf_mgr, hor_stride * ver_stride * 2, 4, cmd->buf_mo… in multi_dec_decode()
454 ret = mpp_buffer_get(dec_ctx->frm_grp, &frm_buf, hor_stride * ver_stride * 2); in multi_dec_decode()
H A Dmpi_dec_test.c129 RK_U32 hor_stride = mpp_frame_get_hor_stride(frame); in dec_simple() local
136 ctx, width, height, hor_stride, ver_stride, buf_size); in dec_simple()
468 RK_U32 hor_stride = MPP_ALIGN(width, 16); in dec_decode() local
477 … data.frm_grp = dec_buf_mgr_setup(data.buf_mgr, hor_stride * ver_stride * 4, 4, cmd->buf_mode); in dec_decode()
491 ret = mpp_buffer_get(data.frm_grp, &frm_buf, hor_stride * ver_stride * 4); in dec_decode()
/rockchip-linux_mpp/mpp/base/
H A Dmpp_frame.c279 (f0->hor_stride == f1->hor_stride) && in mpp_frame_info_cmp()
340 MPP_FRAME_ACCESSORS(RK_U32, hor_stride)
/rockchip-linux_mpp/mpp/hal/rkdec/
H A Dvdpu382_com.c228 RK_U32 hor_stride = mpp_frame_get_hor_stride(frame); in vdpu382_setup_down_scale() local
230 RK_U32 down_scale_hor = MPP_ALIGN(hor_stride >> 1, 16); in vdpu382_setup_down_scale()
239 down_scale_y_offset = ver_stride * hor_stride * 3 / 2; in vdpu382_setup_down_scale()
/rockchip-linux_mpp/mpp/vproc/iep2/
H A Diep2.c306 ctx->params.src_y_stride = param->com.hor_stride; in iep2_set_param()
310 (param->com.hor_stride / 2 + 15) / 16 * 16 : param->com.hor_stride; in iep2_set_param()
312 ctx->params.dst_y_stride = param->com.hor_stride; in iep2_set_param()

123