Commit Graph

1737 Commits

Author SHA1 Message Date
Johnson Ding
4ef69884a6 [jpegd]: remove tailing 0xff patch from parser
Tailing 0xff will always be done in hal thread. There is not need to
doing this twice.

Change-Id: Ide4fcc4a2e252be04067c6990fc6a8e9ba8ee824
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
2019-10-29 09:43:26 +08:00
Wenjie Yang
ba6c612544 [h264d]: Errorinfo is marked incorrectly
When frame_num_value_allowed_flag is equal to 1,
If frame_num is not continuous,
errorinfo does not need to be marked

Change-Id: Icf68d4186dccdb1d647fbf69c767034dcb7088ac
Signed-off-by: Wenjie Yang <ywj@rock-chips.com>
2019-10-28 09:57:45 +08:00
Herman Chen
c2a781d05d [hal_h264e_vpu_tbl]: Do not copy multiple tables
Change-Id: Ie8bb5b11fec6a0604f8566bb8696a54dea40fe8f
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-23 20:30:22 +08:00
Herman Chen
a961ef5534 [venc_cmd]: Change gop ref cmd definition
1. Remove Hisilicon interface.
2. Add LTR configure.
3. Add temporal layer rate control interface.

Change-Id: I5172e69e828bdbe8e7f0cfc8ab0ca5a6b00d022a
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-22 20:36:32 +08:00
Herman Chen
f59caf70fc [h264e]: Add debug function for h264e
Change-Id: I3a42c0aecbba61e7ae6dd5fc720c863f221e2398
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-22 20:36:24 +08:00
Herman Chen
c712b71f2f [mpp_rc]: Fix log error
Change-Id: I68b3234a68cc0c5f373bae141187638217ee7ab3
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-16 18:01:20 +08:00
Herman Chen
db234e2d21 [mpp_packet]: Fix reset function
1. Reset function will not reset buffer pointer and buffer size.
2. Make mpp_packet_reset into a C function.

Change-Id: I1d9041e9732f249ef4a7753a4aac5c0795c34b17
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-16 16:27:41 +08:00
sayon.chen
53997e5cd8 [mpp_base] Add base bit writer function
This bitwrite function is for H.264/H.265 bit writing.

Change-Id: I98c0e50f51b8ab29ec630474a2bdf25d0553b7b5
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2019-10-15 19:41:23 +08:00
sayon.chen
042696c255 [h265d] move enc&dec common define to h265_syntax
Change-Id: I3e5b285b956d58d5e64dc5db71e32e3a150b976e
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2019-10-15 15:40:05 +08:00
Herman Chen
ea476ad4d1 [misc]: Change internal API interface
1. Change internal api RK_S32 cmd to MpiCmd.
2. Remove external MppEncCfgSet in MPI and move it internal data.

Change-Id: I0b93429f3b9f92712a57d0df54a1c76b3e08bf9d
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-14 20:21:41 +08:00
Herman Chen
585b187b18 [misc]: Use MppDeviceId to replace HalDeviceId
Change-Id: I3fd2f6a673f4f8d05420bfccb78e8b103f2ca26d
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-14 17:18:13 +08:00
Herman Chen
05ccab453b [h264]: Unify H264d and H264e common defines
Change-Id: Id77fa58ad44348d6e3c36fc5b0a732de85a92021
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-14 16:36:25 +08:00
Herman Chen
3a3e110de6 [mpp_platform]: Add device id definition
Change-Id: I108cfa3f4639517eed7ebaaaacf5f482002ea806
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-14 16:36:25 +08:00
sayon.chen
76d22d6ac0 [h264e] split common define from h264_rkv_enc
Change-Id: Ie8f95f085ae37a9804c98b31e3acd69f5752308e
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2019-10-14 15:16:17 +08:00
Herman Chen
208f0004a5 [build]: Add path detection for different ndk
Support r10d and r16b first.

Change-Id: I289813c26b79ad4a1b038fc07f8375832fe78162
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-10 18:04:21 +08:00
Herman Chen
37602b5bb9 [test]: Skip error opt on parsing parameter
Change-Id: Ia5935b55bf0a09158b4ebd40656de6e813e880c4
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-10 16:29:43 +08:00
sayon.chen
cd5b1ccde6 [h265e_vepu22]: mov rkvenc/h265e to vpu/h265e
Change-Id: Iccedbc561902a0132492ceb3ac2c2223d7031e9d
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
2019-10-10 16:23:37 +08:00
Herman Chen
2310eaac1a [h264e] Remove src directory of h264 encoder
Change-Id: I130448c9736ff80d8b2057099ea770cc212728b2
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-10-08 09:43:29 +08:00
Xingwen Fang
3195b3de91 [avsd]: modify the cmake include of avsd hal
Change-Id: I8d7f994894d887f211d5a7b141c66d0a51259f68
Signed-off-by: Xingwen Fang <fxw@rock-chips.com>
2019-09-27 17:10:01 +08:00
Herman Chen
dd3f0ee71b [enc_impl]: Rename and new enc_impl function
Change-Id: Ie0acfc1e66256db6acfba09e3c62b04ceda5e2a5
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-20 17:18:37 +08:00
Herman Chen
7782c8ea11 [enc_impl]: Add new interface for work flow change
Change-Id: Ic110aaf53964f532b59bbb0fbd6347c95accf324
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-20 16:59:15 +08:00
Herman Chen
e4b0d68fa5 [mpp_enc]: Change controller to EncImplApi
The controller should be separated into more parts for better reuse
between different hardware.

Change-Id: I050b8534360cf4afdf15c933def88e00c87d1de6
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-20 16:27:16 +08:00
Herman Chen
6cf33e998b [mpp]: Remove extra signal and thread in mpp
1. Only use notify to communicated between mpp and codec.
2. Remove mpp_enc_impl.h

Change-Id: Ia62757240efa7d245b5215ad79539fa9bbbd1550
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-20 15:57:17 +08:00
Herman Chen
5271f581cd [mpp_dec]: Change mjpeg decoder loop flow
Change-Id: Ifa8577f2490df3eb31e410caaada1eb333119819
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 18:07:54 +08:00
Herman Chen
c7d9e7565d [mpp_enc]: Move thread into MppEnc
Change-Id: Idf50d9530dd5372e44d1ac54bf3c75fcfc933a57
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 18:07:54 +08:00
Herman Chen
205ba6dc31 [mpp_dec]: Move thread into MppDec
Change-Id: Ifab2773a1aa5405ffeb155ce8fd8e5f21e5a6b45
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 17:46:58 +08:00
Herman Chen
498a43aa2e [mpp_enc]: Add MppEncImpl layer
Change-Id: If9a63606c2ec4a1f96e422a06681cf8a11ec4c7b
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 17:46:58 +08:00
Herman Chen
14076644ea [mpp_dec]: Add MppDecImpl layer
Add MppDecImpl layer for separate encoder and decoder.

Change-Id: I02e04acddf617ae5188572af89312ab20fbf21b6
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 14:54:24 +08:00
Herman Chen
9ee20c594a [mpp]: Clean up header
Remove extra mpp_dec.h and mpp_enc.h for later modification.

Change-Id: I43c0e1c4ca0cf36070887556b1cd9d428f167090
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-19 11:40:59 +08:00
Ding Wei
5526523736 h264d: add svc and prefix nal parse
Change-Id: If04c3a506e54130f257ac507c15eadc1182d8f0d
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-09-18 15:03:24 +08:00
Herman Chen
dc79923e1d [mpp_frame]: Add set meta function to mpp_frame
Change-Id: I8b61b29d534d6d77f8be0bb2f033d7ba5e2a2496
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-17 09:07:29 +08:00
Herman Chen
359881f819 [base]: increase meta data ref_count on copy
When copy MppFrame or MppPacket increase its meta data reference count.

Change-Id: I72879edbc4e20fbf831e9a013b6c012f4bb1c2dd
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-12 15:17:40 +08:00
Herman Chen
9afb1d2e04 [meta]: Add reference counter to MppMeta
For the requirement of transporting MppMeta between different thread add
reference counter and inc_ref interface to MppMeta functions.

Change-Id: I9e355b66b6de933c2499713e1a2406149fa7e0e8
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-12 15:17:17 +08:00
Herman Chen
16d69714d7 [hal_task]: Add frame and packet to HalEncTask
Add frame and packet to HalEncTask for meta data transaction.

Change-Id: Ife81442d472baee6d50e2c5f1c602e96db3beb4b
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-12 08:52:15 +08:00
Herman Chen
2dfcb96976 [meta]: Add long-term reference index to meta data
This meta data is used for SVC/TSVC encoding / decoding.

Cases and meaning when using KEY_LONG_REF_IDX:

1. On decoder output frame
Represents the long-term reference frame index of the output frame.

2. On encoder input frame
Represents the long-term reference frame which should be used as
reference frame for current encoding frame.

3. On encoder output packet
Represetns the long-term reference frame index of the output packet.

Change-Id: I41dd2eb754b84cc0d8873f7dfbb695e31bc866ae
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-12 08:52:15 +08:00
syzby
451ae59386 [cmake]: Fix aarch linux cmake compile error
Change CMAKE_SYSTEM_PROCESSOR from armv8 to armv8-a

Change-Id: I4e0021a44b933813d336383b5363170ecf2b7027
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-05 17:17:49 +08:00
Ding Wei
8ca9d3cec7 [m2vd]: fix bug: correct interlace paramters.
Change-Id: Iea9f99747fe4a117f6b3f28f503287947aa65f9f
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-09-04 10:33:12 +08:00
Herman Chen
b165fcd4b0 [mpp_enc]: Change encoder work thread flow
1. Add wait and status flag for encoder
2. Add notify for encoder
3. Use wait and notify for encoder task handling.

Change-Id: I6ce0f676084f7c27cc95d6abc56557bfa286ef87
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-09-03 09:08:17 +08:00
Ding Wei
60c82d6d7b [mpp]: add dump function for nv12 10bit to 8bit
tips: when dump 10bit yuv, change it to 8bit, and write out.

Change-Id: I710399d61056e32d68c3f6f9d6ff209d73f6b904
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-08-29 16:10:50 +08:00
Ding Wei
11f4844482 [h265d]: fix bug: hor_stride mismatch
tips: hor_stride value sett mismatch between parser and hal.

Change-Id: Ia8b9ab660c1a5f29ad71ccba418bb629f1487ef2
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-08-29 11:09:45 +08:00
Ding Wei
d499d95128 [h264d]: add svc extension syntax
Change-Id: Ia2ed3553802e62b507809db15a593bd072d1aece
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-08-27 16:02:07 +08:00
Ding Wei
5fa1da887d [h264d]: when level_idc missing, use max_num_ref instead
Change-Id: I5652f0b2ea3be010aab26be057d7c09b2c44aa8e
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-08-27 10:30:51 +08:00
Herman Chen
0a7e306cd1 [cmake]: Add make path detection
Higher cmaker version require CMAKE_MAKE_PROGRAM parameter.

Change-Id: I4ed9f4ef1592f5683ec0f9a3679840bf6dfb0d2d
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-21 09:35:28 +08:00
Herman Chen
796bfb0a97 [tools]: Update pre-commit hook
Set pre-commit hook to detect changes on staged file.

Change-Id: I041a82577263abcdfffc146b5aaba1d0a51def76
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-20 11:23:27 +08:00
Herman Chen
bbbc9afd5e [test]: Fix error on mpp_thread_test
Change-Id: Id9f0bc58e72256f27cab6bc7fb39d441803a2bfb
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-20 10:58:59 +08:00
Herman Chen
666782b834 [mpp_list]: Add fifo function to mpp_list
Add fifo access function to mpp_list class.
NOTE: The interface is different and node contain RK_S32 size data
before real data.

Change-Id: I8875312a7a6247b71be7df71044d2b779c228b0a
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-19 15:02:13 +08:00
Herman Chen
003f8806af [vproc]: Pass HalTask between hal and vproc
Use HalTask to communicate between hal thread and vproc thread.

Change-Id: I4e87b7ca63bdf86e46045e31296ffa69958ae719
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-19 15:02:13 +08:00
Herman Chen
05bba59fa9 [hal_task]: Change hal task to a general task
Hal task will be changed to a more general task between mpp components.

Change-Id: I8ed46da8d02f530cddcdc785f6f6b3778afac5b9
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-08-19 14:56:13 +08:00
Rimon Xu
454f065572 [h264d]: fix cts security patch: cve_2017_0765
When nal buf len is 0, nal buf shouldn't be read.

Change-Id: Id8326081d40bbf5c2109c2ff0fa9c2636583f9ac
Signed-off-by: Rimon Xu <rimon.xu@rock-chips.com>
2019-08-14 18:06:43 +08:00
Ding Wei
a57fd68ccc [vdpu2]: fix bug: set ref list
tips: listp list0 list1 should reoder by paired when field mode.

Change-Id: Ia1177c95e9d8fdc90293ddf8b16058592d2e0b15
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-08-12 11:05:00 +08:00