Commit Graph

3026 Commits

Author SHA1 Message Date
Herman Chen
fcb11d138a [mpp_cfg]: Add general MppCfgSet/Get function
1. Use flatten MppEncCfgInfo to replace MppCfgApi
2. Flatten the trie nodes and info nodes with string name together.
3. Refactor the encoder config setup process.

Change-Id: Ia08f59167b033c99167f37e78571d9d2e402854c
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-21 11:20:02 +08:00
Herman Chen
97a8caace3 [mpp_trie]: Add more trie function
Add function to get the named valid node and the node root.

Change-Id: Iccfe004d29e9c4405b49e23bdce62ba14832d3da
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-19 15:34:21 +08:00
Hongjin Li
33269e39e7 [mpp_dec]: Fix the problem of read data error
For data with sizes of 5120x7160 and 8000x8000, the required buffer size
was calculated incorrectly during the encoding process, which caused the
requested buffer to be too large, resulting in drm exceptions.
Therefore, the method of calculating data has been modified.

Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
Change-Id: I519a76687118d568cf57e7d3d54a150e9019285c
2022-01-17 20:41:06 +08:00
Jeffy Chen
0e15e96c9f [hal_jpegd]: Correct output format when PP not used
Otherwise the output format would always be the initial value(YUV420SP).

Change-Id: I6b792cb1010b96e136ce008250b2e1a4f90635e5
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
2022-01-17 18:27:13 +08:00
Jeffy Chen
d6c338d009 [mpp_buf_slot]: Support FBC buffer size calc for NV16
Add slot buffer size calculation for NV16(AFBC).

Change-Id: Ibac797fe695de0da7656ea0ff97f982d0f1e5e6b
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
2022-01-17 16:35:51 +08:00
Herman Chen
b25d0b475d [h264e_vepu580]: Update tinetune parameter
Fix tailing at low light scene.

Change-Id: I57df8b8d6ac48c1090076a586c07cd816c1e6dfb
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-14 17:30:10 +08:00
Herman Chen
b9ae7d8535 [vepu580]: encoder parameter fine tuning
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I28011fa75dd0e8c7bc17164515272ed3a6d1c6dd
2022-01-14 16:48:43 +08:00
Herman Chen
ee3b958d9c [mpp_meta]: Add metadata dump for taskqueue
Change-Id: I0c62a93c8ffd1cf9e243e18940fc2197221f99ec
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-12 15:58:56 +08:00
sayon.chen
33d6284f13 [test]: update rc2 testcase
rc2 test is a decode -> encode -> decode test case which can be used to
test the whole system codec capability.

1. Use new option module.
2. Add type for input file source stream.
3. Use decoder file reader to read input file.

Change-Id: Ia2334cd423e77a76c564478cc70c07a58954dd04
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-01-12 11:50:20 +08:00
sayon.chen
6d2b1ad200 [vp9d_parser]: Fix mpp_buffer refcnt non-positive issue
Change-Id: I92c0cdfcfb732585d06bdd9b11dd44045b097b1e
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-01-11 17:44:20 +08:00
Ding Wei
10381f5d12 [hal_h264d]: fix issue for interlace input
in rk3588 dual core mode, it need high bit for mark current whether
is bottom field.

Change-Id: I9adde8996617390b5c7186a108ccf01546eed5d1
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2022-01-11 10:14:24 +08:00
Herman Chen
96d1664cd1 [test]: Use new option module
1. Use new option module in dec/enc test
2. Delete mpi_enc_multi_test and mpi_rc_test

Change-Id: Ib00020247386ee06cca2f560ae41aee8e88f47cc
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-11 08:37:41 +08:00
Jeffy Chen
7865f7f81b [mpp_dec]: Change FBC buffer size calc rule
According to DRM FBC buffer size check rule change the slot buffer size
calculation.

Change-Id: I3bf2439d0d5229b2f014fc1b202b5343cb77f8fa
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
2022-01-07 14:09:33 +08:00
Herman Chen
693720fd19 [iep2]: Disable test log
Change-Id: I2d11bda157612472f000411bbe0dbf3452ceb34a
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-01-05 09:32:28 +08:00
Chen Jinsen
e85c28ab56 [vp9d]: Fix ref frame pointer not free issue
Signed-off-by: Chen Jinsen <kevin.chen@rock-chips.com>
Change-Id: Icec0cd494f067826be93f94e14fdcbde1c938cb1
2022-01-04 09:05:52 +08:00
Herman Chen
f94ae6d0a0 [vepu580]: Add YUV444 support for vepu580
Change-Id: I58859e59094fcecc13011b16f33b3810abbc7882
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-30 10:52:02 +08:00
sayon.chen
5dec7c0b44 [hal_h265e]: Format file from dos to unix
Change-Id: I065c1496eaed9acdb8c4d021a761fca014c52098
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-30 10:17:50 +08:00
sayon.chen
be46d78711 [hal_hevc580]: Add frame offset x y set
Change-Id: I489b7df830e8e44865a7b89c911282b3f7009eaf
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-29 18:05:57 +08:00
Xinhuang Li
25330128c7 [mpp_enc]: need resend hdr when color related parameters changed
Signed-off-by: Xinhuang Li <buluess.li@rock-chips.com>
Change-Id: I5436fedb8b5f4482d143e997bd6e78ce75c5ed84
2021-12-29 11:21:04 +08:00
Ding Wei
aa8cca56f8 [h264d]: fix error for parse vui period info
Change-Id: I6f2aa84720bde10ecba997f80af2ea652aacc048
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-27 10:25:51 +08:00
Yandong Lin
0c3ddf2703 [mpi_dec_utils]: Fix ivf reader problems
Change-Id: I377a88838202080e143c44577bd4e5d01e57f392
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-24 14:51:14 +08:00
Herman Chen
69dfccfd12 [osal]: Add log disable/enable function
Change-Id: Iddd02b7c3d102a65a4c34a8fba89b7a28719e0a9
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-23 15:53:14 +08:00
shine.liu
1f085a4493 [m2vd_parser]: Clear input_packet eos flag when reset
When decoder restart after reset and input_packet has eos flag, all the
frames got from the decoder will have eos flag, so we should clear the
eos flag of input_packet in reset.

Change-Id: Id220f66d32070316c05c7352ea986b29ffe7d3e5
Signed-off-by: shine.liu <shine.liu@rock-chips.com>
2021-12-22 16:32:25 +08:00
vic.hong
ee10b27c68 [mpp_dec]: Fix the problem of screen flutter when decoding mpeg4
Modify the processing of pts in the decoding process

Change-Id: I80b911c19eb345744333d3ec4d8e22e8c86fc857
Signed-off-by: vic.hong <vic.hong@rock-chips.com>
2021-12-22 14:29:23 +08:00
shine.liu
c356795741 [m2vd_parser]: Add coloraspect metadata to frame
Change-Id: Ibf0ae925fb35079c72992bad58d1a60ffbbf19f8
Signed-off-by: shine.liu <shine.liu@rock-chips.com>
2021-12-21 11:29:15 +08:00
sayon.chen
8aa2a1ed3d [iep2]: Fix width & height set issue
Change-Id: I40eb51dbb7a8f54746fb5d114d1ff961515bb47f
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-17 18:11:43 +08:00
sayon.chen
c06639a245 [vepu540]: Fix me regs param cfg issue
Change-Id: I88d32eeb4c3876d268c784d1baa789d7c34a6b50
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-17 08:43:36 +08:00
Herman Chen
94ab4c1e5f [utils]: Add new option module using trie
Change-Id: I9c4836d35366ff8ab2f16ac9c474b65471862bd2
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-16 10:59:48 +08:00
sayon.chen
fdd12d9fb6 [vepu54x_avc]: Fix madp val feedback issue
Change-Id: Ibe5ffb83a7538f0c408d1e26261dc4f58c30f776
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-16 10:07:31 +08:00
Ding Wei
af13bcf90d [vdpu34x]: re-set gating reference register
tips:
    In RK3588,the reg26 gating_e should set 0xffef, disable bufifd gating bit.

Change-Id: I25f329d386e1b16d8ffca49bef45804ab756fea5
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-14 11:44:05 +08:00
Ding Wei
8b0c4429e7 [vp9d]: fix issue for frame is NULL
when frame is null, it cannot get_frame_poc from frame.

Change-Id: If94488640b46eeb0faa800c1966c0d747ed9f396
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-13 16:16:18 +08:00
Ding Wei
3b0e3598bf [vp9d]: enable gating setting and timeout threshold
tips:
    re-define the block gating enable structure.

Change-Id: I8c2c92aa0671610bb30ba06d5d8769b371cae1f8
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-13 16:15:13 +08:00
Ding Wei
ad221ec604 [vp9d]: reset temp parameters when reset
Change-Id: Iee87b90f5753bfae4531413721ce1a5d7dca4d0a
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-13 10:39:20 +08:00
Ding Wei
e81d82173b [vp9d]: Support multi-core mode
tips:
    vp9 need poc mode for detect current core
refer regs:
    reg65 reg75 reg95 reg96 reg97 reg98 reg99 reg100

Change-Id: Ia42af0cfe018488990b1678665a703c34173f095
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-10 17:49:14 +08:00
vic.hong
eeda461154 [mpp_dump_yuv]: fix mpp dump yuv issue
Modify the judgment condition of dump data

Signed-off-by: vic.hong <vic.hong@rock-chips.com>
Change-Id: I8816b02ccad6e7dac82ba1e2723947a1aa165e3c
2021-12-07 20:27:46 +08:00
Ding Wei
aceeea09c9 [hal_vp9d]: Dual core: Add rcb_buf for fast mode
tips:
    echo register setting need one rcb_buf.

Change-Id: I61a1a44aec7182a911183facdcc8adc04d16c3fb
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-12-07 17:50:13 +08:00
Herman Chen
7bf0f1a54c [mpp_buf_slot]: Formating code
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: If48dbc3eb797495e4c62a8d8c30c5c0aee105c16
2021-12-07 17:07:40 +08:00
sayon.chen
0b670f2ec0 [h265e_ps]: Clear crop info before set
Change-Id: I7c1f88da6982e78fd113b1cd1e276fb4b33176d9
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-12-07 17:01:27 +08:00
Herman Chen
e3fcc11706 [hal_vepu580]: Enable watchdog
Change-Id: Ie522d027c9ed032734895c00cfc8e68715a3b77c
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-03 08:50:07 +08:00
Yandong Lin
f9a628752d [utils]: add MPP_FMT_YUV420SP_VU data dump
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I775ef33e760c9106a7e95fa98fd43185cfcd6195
2021-12-01 17:28:39 +08:00
Herman Chen
0159409673 [hal_vepu580]: Add hw auto reset on frame end
Change-Id: I08f395e2b402fcf8ad8ed2b3e05912647870a2c7
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-01 17:11:10 +08:00
vic.hong
c5a794515d [mpi_buf_slot]: Fix hor_stride_pixel calc issue
Align the pixel bit depth to 8bit

Signed-off-by: vic.hong <vic.hong@rock-chips.com>
Change-Id: I19c4f47d19dfb8eba9cb0b17f20ed4ed839c8a80
2021-12-01 15:03:10 +08:00
Herman Chen
ee7bae024d [hal_h264d_vdpu34x]: Disable buffer log on deinit
Change-Id: I475846b51d986f3c60b61375615e0e3c7701d51b
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-12-01 11:30:09 +08:00
Yandong Lin
26a2b1a6ba [jpege_api]: fix generate qtable err
Rootcause: The RK_U8 variable overflow
Solution: change RK_U8 to RK_U32

Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: Ia1eba83ef86590dcf2eeb07ced547714b428a145
2021-11-30 19:03:05 +08:00
sayon.chen
8c04e0d562 [mpp_enc_roi]: Add roi generation function
vepu58x roi cfg generation is depended on vepu54x roi cfg.

1. Use roi_enable to enable roi test.
2. Use roi_type to test different roi config mode.

Old region mode is set to legacy now for future roi cfg will be more and
more complicated.

Change-Id: Ib9e8976b732f05625e7589b64752d38fbd83584b
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2021-11-30 17:11:11 +08:00
Herman Chen
3d87869900 [hal_vepu541]: Add ROI_DATA2 support
Change-Id: Iadd0b8206197bba29dca21d1581b7394cea8f4be
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-11-30 15:07:19 +08:00
Herman Chen
dda6a4d723 [hal_vepu580]: Fix debug register definition error
Change-Id: Ia6e0c931ca1707027f5076e14a482a1f8099caad
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-11-29 16:50:25 +08:00
Herman Chen
dbd428d570 [mpp_service]: Allow zero size rcb info
rk3588 encoder needs buffer end address so zero size should be allowed.

Change-Id: Ie350f62c77d99f91b2ca1f02e7b4ff7afe0b0dd8
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-11-29 11:24:23 +08:00
Ding Wei
b0bfe6b090 [hal_vdpu34x]: Fix rcb_buf issue for dual core
At rk3588 vdpu38x (vdpu34x dual core we have multi-frame running on
different cores in one decoder session which enable fast mode.

Sharing rcb buffer between frames will introduce data conflict.

So we need to create rcb buffer for each frame register set.

Change-Id: I2ae3cb8f7f06b1b89bfafcd38e316f975ce72520
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2021-11-25 10:37:06 +08:00
Ding Wei
7e1a19a541 [hal_vdpu34x]: Add timeout register definition
rk3588 vdpu38x (vdpu34x) add timeout register.

Change-Id: I0517c14054b52eb7179f8ec691bcc5dea5deef5f
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2021-11-25 10:04:25 +08:00