Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a40f5e28 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: vidc: Introducing CBR_VFR upto 480p@30fps"

parents e7b56d23 595d428a
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -925,8 +925,10 @@ int msm_vidc_set_internal_config(struct msm_vidc_inst *inst)
	if ((rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR ||
		 rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR_VFR) &&
		(codec != V4L2_PIX_FMT_VP8)) {
		if (rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR &&
		    mbps < CBR_MB_LIMIT)
		if ((rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR &&
		    mbps < CBR_MB_LIMIT) ||
		   (rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR_VFR &&
		    mbps < CBR_VFR_MB_LIMIT))
			hrd_buf_size.vbv_hdr_buf_size = 500;
		else
			hrd_buf_size.vbv_hdr_buf_size = 1000;
+3 −1
Original line number Diff line number Diff line
@@ -1198,7 +1198,9 @@ int msm_vidc_decide_work_route(struct msm_vidc_inst *inst)
		if (slice_mode ==
			V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES ||
			(rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR &&
			mbps < CBR_MB_LIMIT)) {
			mbps < CBR_MB_LIMIT) ||
			(rc_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_CBR_VFR &&
			mbps < CBR_VFR_MB_LIMIT)) {
			pdata.video_work_route = 1;
			dprintk(VIDC_DBG, "Configured work route = 1");
		}
+2 −1
Original line number Diff line number Diff line
@@ -24,7 +24,8 @@
#define DEFAULT_FRAME_QUALITY 80
#define FRAME_QUALITY_STEP 1
#define HEIC_GRID_DIMENSION 512
#define CBR_MB_LIMIT                           (1280*720/256*30)
#define CBR_MB_LIMIT                           (((1280+15)/16)*((720+15)/16)*30)
#define CBR_VFR_MB_LIMIT                       (((640+15)/16)*((480+15)/16)*30)

struct vb2_buf_entry {
	struct list_head list;