Commit Graph

3047 Commits

Author SHA1 Message Date
Herman Chen
b7afc49a5b [h264e]: Fix error on gop larger than 65536
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Ia6c119adbbe1cd3c1a8a31689aacc2e8bd9de98a
2022-10-18 10:27:59 +08:00
Hongjin Li
8b61a64c07 [vp8]: Fix vp8 encode rgba stride limit
Change-Id: Ic7a57169863d09cbce041a813108089b4f958d7f
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-10-13 18:27:42 +08:00
Yandong Lin
3adde926e2 [avs]: Add avs module
NOTE: I frame header decoding should check stream version.

Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
Change-Id: I1c8276f4499d73e3b60d582890037dec376e136f
2022-10-13 15:16:13 +08:00
Johnson Ding
a9cb2cff35 [enc]: fix IDR not encoded problem
When GOP is set to 60 that is the same as the default GOP by
application, igop at reference module isn't set as expected, that leads
to CPB not be cleaned correctly and IDR frame won't be encoded.

see [issue](https://redmine.rock-chips.com/issues/374780)

Change-Id: I2f1030cab700aa560dea07284b820a73c637631e
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
2022-10-11 14:50:08 +08:00
sayon.chen
1f8ec3b78d [mpp_service]: Enlarge offset request buffer cnt
NOTE: realloc may change the buffer base. This will invalid the pointer
which point to the old buffer base.
This issue will make 4 tile H.265 encoding with multi osd generate
error stream.

Change-Id: I764ee9b2097687ae9d5f2bcc8d2ff5987a636844
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-10-10 18:06:47 +08:00
Xinhuang Li
9b860cd250 [mpp_soc]: Fix rv1109/rv1126 soc_info err
Signed-off-by: Xinhuang Li <buluess.li@rock-chips.com>
Change-Id: I5de57f4c414d65c0d768c77470cf95a68d6ee71d
2022-10-10 16:03:42 +08:00
Rimon Xu
79e4bda9fa [h264d]: fix afbc judging error when field mode
Change-Id: I71fbdb25f8eaed5ddc471fe5d1b73c4b4219a99a
Signed-off-by: Rimon Xu <rimon.xu@rock-chips.com>
2022-09-30 11:15:00 +08:00
sayon.chen
d7f0b0e9c4 [hal_h265]: Fix memset strmbuf align_offset maybe overflow
Change-Id: I1580ce6622ca3e4f4d9b418e5af22b10ebfe5433
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-27 16:40:39 +08:00
sayon.chen
3562557943 [vepu580_hevc]: Support enc max with up to 16384
Change-Id: If91add1c9220c7e3e6eff315be9165a18880d24b
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-27 16:32:34 +08:00
Herman Chen
27e4974b89 [hal_vepu580]: Adjusting default parameters
1. Raise H.265 aq step for lower bitrate.
2. Change H.265 skip and small mv tendency.

Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Signed-off-by: toby.zhang <toby.zhang@rock-chips.com>
Change-Id: I2f454d016aa1d227bb5321533a79e67b701c5e0f
2022-09-27 09:22:52 +08:00
Herman Chen
45739cd4e7 [mpp_enc]: Clear split arg and out when disabled
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Ibd94134cc2e25b9b076785a40fa39f7360878a43
2022-09-27 09:17:08 +08:00
Herman Chen
9b2c8f30ba [mpp_enc]: reduce extra log on IDR request
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I1ceb9072cee04d5bc4c17d67a23de4f4ea9d5897
2022-09-26 11:48:17 +08:00
sayon.chen
b0ae2b7122 [h265d_param]: DXVA slice param use dynamic malloc
Change-Id: Id362b642121502786497bf57223356723b9838f7
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-24 10:03:57 +08:00
toby.zhang
ba13512fbd [hal_h265e_vepu580]: Adjusting tuning parameters
Change tuning parameter to let ME choose small movement normally.

Signed-off-by: toby.zhang <toby.zhang@rock-chips.com>
Change-Id: Ib6a08f11fba53c247bbf2300d062508e9071461b
2022-09-24 09:02:42 +08:00
sayon.chen
d654d25ea9 [h265d_ref]: Add miss ref used by current check
Change-Id: I6c0974ed2ea33720d7aeec0f63d6e71f838e3cb5
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-23 14:03:45 +08:00
Yandong Lin
69127d4657 [h264d_parser]: fix last empty eos pkt send to hw issue in avcc case
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I92ef6211c9389870455ba4681183cbe3ea6ab3ca
2022-09-23 09:01:43 +08:00
sayon.chen
a2094ca30a [h265d]: Modify hw resolution capability check method
Change-Id: Ibb7d450d77812f203f5502579e9ed61468c63140
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-22 18:11:43 +08:00
sayon.chen
346c126ac2 [h264d]: Modify hw resolution capability check
Change-Id: I28d60b2fb4fb9244d041fa3f023d40323e622118
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-22 18:11:18 +08:00
sayon.chen
2bf30c6f32 [mpp_soc]: Add capability core num set
Change-Id: I76add0b060b2c94914e7b11e8fb42d29c1987384
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-22 17:32:31 +08:00
sayon.chen
038fecb3da [mpp_soc]: Add capability dec linebuf limit
Change-Id: I6b6d9f0728965ab4b73dc2ece7cd211b6fee190f
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-22 17:32:21 +08:00
sayon.chen
6b4846bebd [soc_info]: Add cap_down_scale set
Change-Id: Ic0921ce74aea0d71d1629c4d88b5e76b87f294e9
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-22 17:29:54 +08:00
xueman.ruan
09de35e9b5 [enc_cfg]: Update mirror transformation.
1. constraint the range of input argument.
2. add flip config, equal to vertical mirror transformation.
3. add mirroring_ext and rotation_ext to config set, for supporting
GET_CFG control.

Signed-off-by: xueman.ruan <xueman.ruan@rock-chips.com>
Change-Id: I01c0b9187a18851354e81b5f08afc6dcaaba8365
2022-09-21 15:21:40 +08:00
Yandong Lin
8d905fe82e [h265_vdpu34x]: fix rcb size cal err in multi-tile case
A ext 64 bytes are required for each col tile boundary

Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I3d6b64579b4f881354c015e556c69ea126d5976a
2022-09-21 11:38:42 +08:00
sayon.chen
536010f378 [roi_utils]: Fix cu_size set error
Change-Id: I47c2ec6ee17a37071c33468b52d306c193f6c6e8
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-20 15:25:24 +08:00
Herman Chen
1fd4733db4 [mpp_mem_pool]: Add finalized check
Add finalized flag to avoid double free error which happened on C++
static destruction function order error.

If ~MppMemPoolService is called first in __cxa_finalize then another C++
static destruction function call mpp_mem_pool function later it will
cause double free crash.

Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I14862e74d7987e30cccbcbaaee21170d92aa62d9
2022-09-19 17:17:53 +08:00
Herman Chen
d8fcd77685 [mpp_mem_pool]: Add lock protection on put_pool
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: If61a3d526f64c1f681bdf4e1281c7e05f4bf8499
2022-09-19 16:46:36 +08:00
sayon.chen
4386e9427c [vepu_580]: Add roi buf size check
Change-Id: Ib29be39356745de96a486112c12d7861bb01b89d
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-19 15:13:14 +08:00
sayon.chen
d1111e74ba [utils]: Support yuv420sp_tight_10bit to 16bit dump
Change-Id: Ic1143a7fe022d38ba8f6300b7e9e017a44bf802c
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-16 15:38:40 +08:00
Hongjin Li
f095476ab0 [vp9_parser]: Added log for yuv support
Change-Id: Ie2f9ca9370726e526cb2fdba578c96abc5c56dc8
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-09-16 15:14:47 +08:00
Yandong Lin
56a5a455fc [hal_av1_vdpu]: fix av1 dec err
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I3f1db1f53cd3b06ca5b27b38a8f7994f5eb8e80c
2022-09-15 18:11:14 +08:00
sayon.chen
37cc658ff3 [vdpu34x_h265]: Error_ref_base select used min poc distance
due to ref is bidirection if only select before, some case will
get fail when ref poc all after current poc, so select error ref
base used min(abs(cur_poc - ref_poc[i])) in current ref list

Change-Id: Ib6796d0e4313601ded245c6b41a4fa0c19668de7
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-15 16:11:17 +08:00
Hongjin Li
1e55b8395d [h264d]: Fix 264d decoding missing last frame
When the last packet sends empty data, h264d_prepare
returns in advance, causing the previous nalu to not
be saved normally, resulting in the loss of the last
frame of data.

Change-Id: Ic519b4326935d82b2534e7442c0ba5175885cef2
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-09-09 15:02:21 +08:00
Hongjin Li
da38e7c7d9 [h264d]: Fix missing frames in 264 decoding issue
After receiving the last packet of data, the program exits
without parsing, resulting in the frame loss of the last
packet of data.

Change-Id: I2effe7ae111402d8318095c016269f27467cb987
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-09-08 11:50:59 +08:00
Hongjin Li
516a02c4c4 [h265d_parser]: Fix I frame is marked with wrong flag issue
Fixed the problem that the I frame could not be judged correctly,
resulting in the wrong flag of the I frame to be set.

Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
Change-Id: Ieeeb7c70d440f720808fabc6918b04b20f63565c
2022-09-07 09:32:55 +08:00
Yandong Lin
24fea09634 [mpp_platform]: fix get_kernel_version failed on 5.10
Signed-off-by: Yandong Lin <yandong.lin@rock-chips.com>
Change-Id: I51fe2311641b4a7a64595e8fc8b4813c6a962303
2022-09-06 18:04:03 +08:00
sayon.chen
2fb572d291 [mpp_enc]: Clear rc info input before reenc
Before re-encode the bit_real and the quality_real should be be clear.

Change-Id: I724c93fa49feaef7194a0a10c6278527aa51598a
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-02 09:59:58 +08:00
sayon.chen
277ddfdcab [vdu34x_hevc]: Stop using error frame as refer
On yuv case skip frame decoding if it can't found right refer frame.

Change-Id: Ibd29bee262010bccb5e9fcebe94674eab9e62b6e
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-02 09:39:59 +08:00
sayon.chen
9cfb3df153 [roi_utils]: Optimize the roi set
Change-Id: Ia9085caeecf421c426e31c6d669f7f402cbac41d
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-02 09:34:40 +08:00
sayon.chen
33973ad0bb [h265d_paser]: Support decode order output
Change-Id: I5ac1cd12d4b835c9529e549c444d661fc9e21342
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-02 08:56:49 +08:00
sayon.chen
e3e79db585 [h265d]: Support fast_play
Change-Id: Iaf1ae34fa0317e09d75f934e7806faad06ac377d
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-02 08:51:14 +08:00
sayon.chen
273d2bdd92 [h265e_ps]: Add auto tile split cfg
Auto tile cfg will let encoder auto split picture into tiles
according to platform encoder core number.

When enabled on RK3588 all picture will be splited into two tiles.

Encoder cfg string: h265:auto_tile

Change-Id: I3bd91a7781fc2c7e0b43bf2e3be775a5b8098d78
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2022-09-01 10:56:23 +08:00
Herman Chen
09116fef5c [hal_jpege_vepu2]: Fix memory leak on multi-core
Change-Id: If98d9a01903d8907ad86a4a234c8e3bdac0e48d5
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-08-31 14:38:12 +08:00
Hongjin Li
3fea12e62d [vp9]: Fix vp9 64x64 crash issue
Fix the problem that the program crashes
when the source size is less than 65x65

Change-Id: I4519cb0d70c651845cd46a23bcb2243d365450c5
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-08-31 09:10:15 +08:00
Ding Wei
6cc173d1f4 [hal_avsd]: Fix crash on avsd ref err path
Change-Id: I71229e9ecff0d1976629f32db86e78f10518e307
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2022-08-29 14:42:34 +08:00
dawnming.huang
dea76b856d [avsd]: fix avsd eos no set and frame slot on enough
Change-Id: Ibf7a9f3575c800e1124a20004cf0857af4c7c50f
Signed-off-by: dawnming.huang <dawnming.huang@rock-chips.com>
2022-08-24 15:16:50 +08:00
xueman.ruan
c00f55111f [h263d]: Enable mpp split for h263.
Fix h263 split logic.

Signed-off-by: xueman.ruan <xueman.ruan@rock-chips.com>
Change-Id: Ifa52b9c1e905ba418aef7d95e9572467a2c83c14
2022-08-24 14:38:02 +08:00
Johnson Ding
b446025bf8 [hal_avs2d]: disable some error bistream check
Some stream encoded from xavs2 might not have `aec_lcu_stuffing_bit` set
correctly. Disable this check at CABAC module from hardware to make
decoder contiune to work instead of reseting.

Change-Id: If38624e1469debcdb1c8aecf356aa69f10521633
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
2022-08-23 19:46:16 +08:00
Rimon Xu
c737ecbf4e [jpegd_rkv] jpegd_rkv can't support fbc compress mode
So we need check the fbc by format and return error.

Change-Id: I634e4189866e8d01eede35f9573620f3ab75ce56
Signed-off-by: Rimon Xu <rimon.xu@rock-chips.com>
2022-08-23 10:56:41 +08:00
Hongjin Li
19e7edf048 [h264d_dpb]: Optimize fast play
For external control, fastplay is turned off by default.
For internal, judge whether to start fastplay according to
different poc modes.

External control has higher priority.

Change-Id: Ifd79267dbafa68b4f46699f3eff5b954d17a2e89
Signed-off-by: Hongjin Li <vic.hong@rock-chips.com>
2022-08-16 14:54:43 +08:00
xueman.ruan
82ae30f031 [h264e_sps]: Add parameters config for encoder
Encorder parameters: constraint_set0~5

Signed-off-by: xueman.ruan <xueman.ruan@rock-chips.com>
Change-Id: I7f90ff97881f875ffad77cf4125ee6623d179563
2022-08-16 12:16:57 +08:00