1. must define HW_RPS for support
2. defalut open hw_rps
Change-Id: Ic699fa2fba24217a082ee4ef62538e3f92d11e1c
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
1. Change statistic time to 3 seconds.
2. Change H.264 min qp from 16 to 8.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Ib0d20f2dcb8affb58bc5fdeea6d506fe28be68b1
1. Add length return when writing sps/pps/sei
2. After writing to packet update both packet length and task length.
3. Update rule of updating length and packet length.
4. Rate control use only hardware length to calculate.
5. Move update hal to the end of flow to reserve for adding extra data.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I9077747a34dc47079d6a1f90db7913c92aa448f5
Use MppMeta in MppPacket to carry flags and data instead of MppTask.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I274cf4163914938f22e983eca35c7fee8a9435dc
1. Default output mode is output header only on config changed.
2. Add new mode to output header on each intra frame.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Iea8dd1e6bb377318b88300d6a013f2c736b15afc
NOTE: copy will overwrite valid data from pos and update new length.
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Ied41cc3f13d24da3704335bbfed2c6b20664c8d1
1. Support video stride and bitrate config
2. Support mpp_enc_v2 h265 codec config
3. Support roi & osd config used meta path
4. Support tsvc config set
5. Support file format check according to file extension
Change-Id: Ib0cedf83867e3cda67159dc7ae5717a67495575c
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
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