The osd_plt_cks need to be clear when configuring OSD palette and should
be set true when encoding.
Change-Id: I2601a06116b984b532bfd0c8ae4cba779bf316d8
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Try enc_v2 on HEVC and AVC case. When it failed just fallback to normal
case.
Change-Id: Iaed522d79b87bef63a8dea3585bb926f8cedb4f8
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
NOTE: This change may effect some existed program.
MPP caller should always follow the rule that the resouce creator must
be the resource destoryer. So caller of encode_put_frame should release
the input MppFrame structure and MPP should not release the input frame.
Change-Id: I36897dbbf1697002ae64868f2385961472eeb7c5
Signed-off-by: Francis Fan <francis.fan@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. Add offset set / get function to MppBuffer
2. Add U32 register address converstion function.
Change-Id: Id297b7a05e47d4e249f5e33c1924a0539729c808
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. When fast_mode is enabled, send_reg process and wait_reg process in
different thread asynchronously. If a wait_reg process hasn't finished
and another send_reg process is processing at the same time, these two
thread may access the same stack which stores content of a ioctl
request. In this case, MPP_HW_POLL_HW_FINISH cmd will be sent twice.
This leads to hardware decoder timeout in waiting and reset.
2. In fast_mode enbaled case, the three element of reg struct in array
should be accessed in FIFO order.
Change-Id: I8c9b028a3a4569c07b17cdc3916be36e89e9374c
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
1. Add mpp_rc_api and mpp_rc_defs for open rc module to external users.
2. Add RcImplApi registration and setup function.
3. Separate RC module from the encoder implement.
4. Use EncFrmStatus and EncRcTaskInfo to control work flow.
5. proc_rc and update_rc function in enc_impl are removed.
6. Use rc_frm_start and rc_hal_start to process rate control.
7. Add more RcCfg setup in mpp_enc_v2.cpp.
8. Use rc_task to replace all the frame status and rc config transmit.
EncFrmStatus is for encoder flow control.
EncRcTaskInfo is for communication between rc / hal / hardware
Change-Id: Ia72b0e0804bfca13963c2b2a5887983fd9b5bcbf
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
When user does not use GET_EXTRA_INFO to get encoded header stream the
encoder should add the header stream before the hardware output stream.
NOTE: Only vepu2 is fixed.
Change-Id: Idf5c07127ef68bb6553f9fb6550f993f3a29ea63
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
User can define its own rate control stategy function and can use them
in MPP encoder flow.
Change-Id: I9573ab8cb5a63c543e17faf07e89f64f5d7013ef
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
hal_task will be separated to dec / enc / vproc hal_tasks.
Change-Id: I67c45772ca998a25ec116d6f08f0584f62408ad1
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Currently, this patch only works well on jpege.
Signed-off-by: Chen Jinsen <kevin.chen@rock-chips.com>
Change-Id: I77026c1975f4937b5bc042e490a2230708b3e715
Move all control process code to a new function.
Change-Id: I7b536cc52fcc695ecdfbccd925b881db28acb4cf
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Include <stddef.h> and add container_of macro.
Change-Id: Ie439b7683e026be9336e618c605b3b934e4fde38
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
NOTE: s32 and s64 value can not be cleared to zero for it may have
initialized invalid value.
Change-Id: Iea9f36600b051584de34d8ac1782a897c64dcd2f
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Slice split has two modes: split by byte and split by CTU number.
Change-Id: Id5a07f8a8cae612b6b913e9cb747dacec5b8e5a2
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. When ROI is enabled the qp_area_en should be always true to avoid
bug.
2. Use meta data to transmit ROI and OSD infomation to HAL.
3. Fix crash when roi is not set.
Change-Id: Ia40c139fcec5b334634c871cf12d7bb250d93b56
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. Remove SVN version record.
2. CMakeLists will record max 10 git version.
3. Use mpp_show_history to control the history display.
4. Use strings libmpp.so | grep author to get history log from binary.
Change-Id: I5231ced4031d868fe1329488c914730dc91a3531
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. OSD plt config will be sent to device directly.
2. OSD data config will be set by registers.
Change-Id: Ia38bc79ee1fa4d9f6bfafe65d9b2a8c8ff6d6c8c
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. Used mppclip instead of if else case
2. Cbr case increase fluc_l level to get more precise bps
3. Fix error on max_i_bit_prop is not set
Change-Id: I81ada0c7f66bac45f1093b3e0d8bec6ebf738231
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
1. Set input format to non-AFBC mode.
2. Fix QP mode.
3. Add stride setup for YUV420P
4. Change ME setting to match C model.
5. Fix L2 AQ parameter error.
6. Set constraint_set0 to zero.
7. Align recn/refr fbc body to 8K.
Change-Id: If91ca22123420661be0941428b8bf145b7babef8
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
When last stream packet is send with eos flag but without valid task or
not output is set just output an empty eos frame.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I18a4ea004479820d4dcfe30aa75d935b15a188cf
1. fbc body must 4k align so set header len align 8k
2. fix tmvp me_cnst colmv load & store cfg
3. fix pp reg stride set err && add rgb2yuv param cfg
4. slice split in mbnum must minus 1
5. fix sao flag syntax no set
Change-Id: Ic2f73b5c18c2d41de50984df11334110724ecf5a
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
merge xx_SET_REG_xx to XX_SET_REG_WRITE
change MPP_CMD_GET_REG to MPP_CMD_SET_REG_READ
NOTE: extra info is different on new ioctl case.
1. Move all extra info process into mpp_device_patch function.
2. Old ioctl should send regs with max size of vepu and vdpu. But new
ioctl need only the correct size of register file.
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I8164fc8d4c85f493c52cc7cd12d8717ca5d35637