media: mediatek: vcodec: Skip unsupported h264 encoder profile
Subsystems (3)
PATCH 1/1 media: mediatek: vcodec: Skip unsupported h264 encoder profile
The encoder driver support h264 baseline, main, high encoder profile, set mask for V4L2_CID_MPEG_VIDEO_H264_PROFILE to skip the unsupported profile.
get supported h264_profile by command: v4l2-ctl -d /dev/videoX -L h264_profile 0x00990a6b (menu) : min=0 max=4 default=4 value=4
0: Baseline
2: Main
4: High--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +4 -1
@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE);v4l2_ctrl_new_std_menu (handler, ops,V4L2_CID_MPEG_VIDEO_H264_PROFILE ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH , -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); + ~((1 <<V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE ) | + (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_HIGH )), +V4L2_MPEG_VIDEO_H264_PROFILE_HIGH );v4l2_ctrl_new_std_menu (handler, ops,V4L2_CID_MPEG_VIDEO_H264_LEVEL , h264_max_level,0 ,V4L2_MPEG_VIDEO_H264_LEVEL_4_0 );
Signature · 1 line
2.18.0
Hi Irui,
Tested for CTS cases on the mt8186 corsola board.
Thanks,
Allen
Quoted 36 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); + ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)|
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), + V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +0
-0h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);
Hi Irui,
Thanks
Yunfei Dong
Quoted 48 lines · Allen-KH Cheng (程冠勳)
Hi Irui,
Tested-by Allen-KH Cheng <[email protected]>Tested for CTS cases on the mt8186 corsola board.
Thanks,
AllenQuoted 38 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)diff --git
a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.cb/drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.cindexd810a78dde51..d65800a3b89d100644drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); + ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)Quoted 1 line
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), + V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +0
-0h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);
Il 26/09/22 11:35, Irui Wang ha scritto:
Quoted 11 lines
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>
Dear Hans,
Gently ping for this patch, could you help to review this patch?
Thanks
Best Regards
Quoted 36 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); + ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)|
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), + V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +0
-0h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);
Dear Hans,
Gently ping for this patch.
May I know this patch current status? It seems is under your reviewing state?
Thanks
Best Regards
Quoted 36 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); + ~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)|
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), + V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +0
-0h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);
Hi Irui,
Quoted 5 lines · Irui Wang (王瑞)
Dear Hans,
Gently ping for this patch.
May I know this patch current status? It seems is under your reviewing state?
Mauro was on vacation last week, but he said that he hopes to merge the pending PRs tomorrow. Fingers crossed...
Regards,
Hans
Quoted 56 lines
Thanks
Best RegardsQuoted 34 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); +~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)|
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), +V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,Quoted 2 lines
h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);************* MEDIATEK Confidentiality Notice
********************
The information contained in this e-mail message (including any attachments) may be confidential, proprietary, privileged, or otherwise exempt from disclosure under applicable laws. It is intended to be conveyed only to the designated recipient(s). Any use, dissemination, distribution, printing, retaining or copying of this e-mail (including its attachments) by unintended recipient(s) is strictly prohibited and may be unlawful. If you are not an intended recipient of this e-mail, or believethat you have received this e-mail in error, please notify the sender immediately (by replying to this e-mail), delete any and all copies of this e-mail (including any attachments) from your system, and do not disclose the content of this e-mail to any other person. Thank you!
Dear Hans,
Got it, thank you very much.
Best Regards
Quoted 86 lines · Hans Verkuil
Hi Irui,
Quoted 6 lines · Irui Wang (王瑞)
Dear Hans,
Gently ping for this patch.
May I know this patch current status? It seems is under your reviewing
state?Mauro was on vacation last week, but he said that he hopes to merge the pending PRs tomorrow. Fingers crossed...
Regards,
Hans
Quoted 67 lines
Thanks
Best RegardsQuoted 37 lines · Irui Wang
The encoder driver support h264 baseline, main, high encoder profile, set mask for
V4L2_CID_MPEG_VIDEO_H264_PROFILEto skip the unsupported profile.get supported
h264_profileby command: v4l2-ctl -d/dev/videoX-Lh264_profile0x00990a6b(menu) : min=0 max=4 default=4 value=40: Baseline 2: Main 4: HighSigned-off-by Irui Wang <[email protected]>--- drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)diff --git
a/drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.cb/drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.cindexd810a78dde51..d65800a3b89d100644drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +1
-1@@ -1397,7 +1397,10 @@ int mtk_vcodec_enc_ctrls_setup(struct mtk_vcodec_ctx *ctx) 0, V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE); v4l2_ctrl_new_std_menu(handler, ops, V4L2_CID_MPEG_VIDEO_H264_PROFILE, V4L2_MPEG_VIDEO_H264_PROFILE_HIGH, -0 ,V4L2_MPEG_VIDEO_H264_PROFILE_HIGH ); +~((1 << V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE)Quoted 1 line
drivers/media/platform/mediatek/vcodec/mtk_vcodec_enc.c +3
-0+ (1 <<V4L2_MPEG_VIDEO_H264_PROFILE_MAIN ) | + (1 << V4L2_MPEG_VIDEO_H264_PROFILE_HIGH)), +V4L2_MPEG_VIDEO_H264_PROFILE_HIGH); v4l2_ctrl_new_std_menu(handler, ops,
V4L2_CID_MPEG_VIDEO_H264_LEVEL,Quoted 2 lines
h264_max_level, 0, V4L2_MPEG_VIDEO_H264_LEVEL_4_0);************* MEDIATEK Confidentiality Notice
********************
The information contained in this e-mail message (including any attachments) may be confidential, proprietary, privileged, or otherwise
exempt from disclosure under applicable laws. It is intended to be conveyed only to the designated recipient(s). Any use, dissemination,
distribution, printing, retaining or copying of this e-mail (including its
attachments) by unintended recipient(s) is strictly prohibited and may
be unlawful. If you are not an intended recipient of this e-mail, or believethat you have received this e-mail in error, please notify the sender
immediately (by replying to this e-mail), delete any and all copies of
this e-mail (including any attachments) from your system, and do not
disclose the content of this e-mail to any other person. Thank you!