mirror of
https://github.com/nyanmisaka/mpp.git
synced 2025-10-14 05:13:44 +08:00
[h265d]: output all frame when reset avoid frame buffer no free
[codec_thread]:add hal lock when put processing task to task list avoid hal thread can't wake up at wait signal git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@445 6e48237b-75ef-9749-8fc9-41990f28c85a
This commit is contained in:
@@ -1857,6 +1857,10 @@ MPP_RET h265d_reset(void *ctx)
|
||||
{
|
||||
H265dContext_t *h265dctx = (H265dContext_t *)ctx;
|
||||
HEVCContext *s = (HEVCContext *)h265dctx->priv_data;
|
||||
RK_S32 ret = 0;
|
||||
do {
|
||||
ret = mpp_hevc_output_frame(ctx, 1);
|
||||
} while (ret);
|
||||
mpp_hevc_flush_dpb(s);
|
||||
h265d_split_reset(h265dctx->split_cxt);
|
||||
s->max_ra = INT_MAX;
|
||||
|
@@ -352,7 +352,9 @@ static MPP_RET try_proc_dec_task(Mpp *mpp, DecTask *task)
|
||||
if (!task->status.info_task_gen_rdy) {
|
||||
task_dec->flags.info_change = 1;
|
||||
hal_task_hnd_set_info(task->hnd, &task->info);
|
||||
mpp->mThreadHal->lock();
|
||||
hal_task_hnd_set_status(task->hnd, TASK_PROCESSING);
|
||||
mpp->mThreadHal->unlock();
|
||||
mpp->mThreadHal->signal();
|
||||
mpp->mTaskPutCount++;
|
||||
task->hnd = NULL;
|
||||
@@ -445,7 +447,9 @@ static MPP_RET try_proc_dec_task(Mpp *mpp, DecTask *task)
|
||||
* combinate video codec dxva output and buffer information
|
||||
*/
|
||||
hal_task_hnd_set_info(task->hnd, &task->info);
|
||||
mpp->mThreadHal->lock();
|
||||
hal_task_hnd_set_status(task->hnd, TASK_PROCESSING);
|
||||
mpp->mThreadHal->unlock();
|
||||
mpp->mThreadHal->signal();
|
||||
|
||||
mpp->mTaskPutCount++;
|
||||
|
Reference in New Issue
Block a user