Browse Source

video: driver: modify s_fmt for decoder

read input width and height and update
output resolution based on client set
color format.

Change-Id: I5605eb875ca679c671d083ca691b046769279ce5
Signed-off-by: Darshana Patil <[email protected]>
Darshana Patil 4 năm trước cách đây
mục cha
commit
b3ddb4f102
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      driver/vidc/src/msm_vdec.c

+ 2 - 2
driver/vidc/src/msm_vdec.c

@@ -1976,8 +1976,8 @@ int msm_vdec_s_fmt(struct msm_vidc_inst *inst, struct v4l2_format *f)
 		fmt = &inst->fmts[OUTPUT_PORT];
 		fmt->type = OUTPUT_MPLANE;
 		if (inst->vb2q[INPUT_PORT].streaming) {
-			f->fmt.pix_mp.height = fmt->fmt.pix_mp.height;
-			f->fmt.pix_mp.width = fmt->fmt.pix_mp.width;
+			f->fmt.pix_mp.height = inst->fmts[INPUT_PORT].fmt.pix_mp.height;
+			f->fmt.pix_mp.width = inst->fmts[INPUT_PORT].fmt.pix_mp.width;
 		}
 		fmt->fmt.pix_mp.pixelformat = f->fmt.pix_mp.pixelformat;
 		fmt->fmt.pix_mp.width = VIDEO_Y_STRIDE_PIX(