From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 2B7284527C for ; Thu, 16 Feb 2023 01:36:36 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 85C0368BEE9; Thu, 16 Feb 2023 03:35:37 +0200 (EET) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id A986268BEB9 for ; Thu, 16 Feb 2023 03:35:32 +0200 (EET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1676511334; x=1708047334; h=from:to:subject:date:message-id:in-reply-to:references: mime-version:content-transfer-encoding; bh=dCehz39XW/LltSLxS3as6ORj4GttedgPDB3WbxMjABk=; b=avlBXA0k68T0BUxNsYz748C3im+kYQmKWZephxJcXCNPCSHY01oAOJVw +XtJsLtYD1Zy60VoKMZsUYLxRl9zDcS6+AkxEJ08y8s4dRy6Yb88UlHR8 XunvulI7evA2svIduOzgHKy/3tBVBFcIOeO3gYeXNBnEIuJ7+Yk0NJ7Kq zkoRESnubIoKsyRHCOYX+jhTxWQT1LqVJ1k4hodylyRPhO27SjHt+DHQ0 07+y25MRGoEES7Ka14cUMdrSnAiNlJ1wq1BZk9eENOTspOP6jxJL27QDn KU+UULDkK9FklV2vDnbvx9DM6Nm1wdw6JiAhenudCYnzqWLuwiuwSNOM8 g==; X-IronPort-AV: E=McAfee;i="6500,9779,10622"; a="311223810" X-IronPort-AV: E=Sophos;i="5.97,301,1669104000"; d="scan'208";a="311223810" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Feb 2023 17:35:20 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10622"; a="779168812" X-IronPort-AV: E=Sophos;i="5.97,301,1669104000"; d="scan'208";a="779168812" Received: from t.sh.intel.com ([10.239.159.159]) by fmsmga002.fm.intel.com with ESMTP; 15 Feb 2023 17:35:19 -0800 From: Fei Wang To: ffmpeg-devel@ffmpeg.org Date: Thu, 16 Feb 2023 09:32:47 +0800 Message-Id: <20230216013248.23044-9-fei.w.wang@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230216013248.23044-1-fei.w.wang@intel.com> References: <20230216013248.23044-1-fei.w.wang@intel.com> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v6 09/10] lavc/vaapi_hevc: Set correct rps type for scc X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: From: Linjie Fu According to 8.1.3 and 8.3.2. Signed-off-by: Linjie Fu Signed-off-by: Fei Wang --- libavcodec/vaapi_hevc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavcodec/vaapi_hevc.c b/libavcodec/vaapi_hevc.c index 1cf43bd4dc..a06785f7a6 100644 --- a/libavcodec/vaapi_hevc.c +++ b/libavcodec/vaapi_hevc.c @@ -71,6 +71,7 @@ static void fill_vaapi_pic(VAPictureHEVC *va_pic, const HEVCFrame *pic, int rps_ static int find_frame_rps_type(const HEVCContext *h, const HEVCFrame *pic) { VASurfaceID pic_surf = ff_vaapi_get_surface_id(pic->frame); + const HEVCFrame *current_picture = h->ref; int i; for (i = 0; i < h->rps[ST_CURR_BEF].nb_refs; i++) { @@ -88,6 +89,9 @@ static int find_frame_rps_type(const HEVCContext *h, const HEVCFrame *pic) return VA_PICTURE_HEVC_RPS_LT_CURR; } + if (h->ps.pps->pps_curr_pic_ref_enabled_flag && current_picture->poc == pic->poc) + return VA_PICTURE_HEVC_LONG_TERM_REFERENCE; + return 0; } -- 2.25.1 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".