[x265] [PATCH 3 of 5] add reference list in analysis structure
Aruna Matheswaran
aruna at multicorewareinc.com
Fri Oct 25 16:00:06 CEST 2019
# HG changeset patch
# User Santhoshini Sekar <santhoshini at multicorewareinc.com>
# Date 1566985098 -19800
# Wed Aug 28 15:08:18 2019 +0530
# Node ID 623af2a8123230c06c942baf614e86b5550148a6
# Parent 9fee87536f7c7e0ab5af89a65a026e24783d1567
add reference list in analysis structure
diff -r 9fee87536f7c -r 623af2a81232 source/encoder/encoder.cpp
--- a/source/encoder/encoder.cpp Wed Aug 28 13:32:12 2019 +0530
+++ b/source/encoder/encoder.cpp Wed Aug 28 15:08:18 2019 +0530
@@ -1810,6 +1810,17 @@
if (m_param->analysisSave)
{
pic_out->analysisData.frameBits = frameData->bits;
+ if (!slice->isIntra())
+ {
+ for (int ref = 0; ref < MAX_NUM_REF; ref++)
+ pic_out->analysisData.list0POC[ref] = frameData->list0POC[ref];
+
+ if (!slice->isInterP())
+ {
+ for (int ref = 0; ref < MAX_NUM_REF; ref++)
+ pic_out->analysisData.list1POC[ref] = frameData->list1POC[ref];
+ }
+ }
}
/* Write RateControl Frame level stats in multipass encodes */
@@ -2696,12 +2707,12 @@
frameStats->ssim = ssim;
if (!slice->isIntra())
{
- for (int ref = 0; ref < 16; ref++)
+ for (int ref = 0; ref < MAX_NUM_REF; ref++)
frameStats->list0POC[ref] = ref < slice->m_numRefIdx[0] ? slice->m_refPOCList[0][ref] - slice->m_lastIDR : -1;
if (!slice->isInterP())
{
- for (int ref = 0; ref < 16; ref++)
+ for (int ref = 0; ref < MAX_NUM_REF; ref++)
frameStats->list1POC[ref] = ref < slice->m_numRefIdx[1] ? slice->m_refPOCList[1][ref] - slice->m_lastIDR : -1;
}
}
diff -r 9fee87536f7c -r 623af2a81232 source/x265.h
--- a/source/x265.h Wed Aug 28 13:32:12 2019 +0530
+++ b/source/x265.h Wed Aug 28 15:08:18 2019 +0530
@@ -200,6 +200,7 @@
}x265_analysis_distortion_data;
+#define MAX_NUM_REF 16
/* Stores all analysis data for a single frame */
typedef struct x265_analysis_data
{
@@ -220,6 +221,8 @@
x265_analysis_validate saveParam;
x265_analysis_distortion_data* distortionData;
uint64_t frameBits;
+ int list0POC[MAX_NUM_REF];
+ int list1POC[MAX_NUM_REF];
} x265_analysis_data;
/* cu statistics */
@@ -275,8 +278,8 @@
int encoderOrder;
int poc;
int countRowBlocks;
- int list0POC[16];
- int list1POC[16];
+ int list0POC[MAX_NUM_REF];
+ int list1POC[MAX_NUM_REF];
uint16_t maxLumaLevel;
uint16_t minLumaLevel;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: x265_push-3.patch
Type: text/x-patch
Size: 2890 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20191025/62db93aa/attachment.bin>
More information about the x265-devel
mailing list