[x265] [PATCH] Cleanup

pooja at multicorewareinc.com pooja at multicorewareinc.com
Tue Sep 17 10:34:31 CEST 2019


# HG changeset patch
# User Pooja Venkatesan <pooja at multicorewareinc.com>
# Date 1568702243 -19800
#      Tue Sep 17 12:07:23 2019 +0530
# Node ID 3d43f2f11af916cc206656e8c5774165e49b0273
# Parent  c4b098f973e6b0ee4aee3bf0d7b54da4e2734d42
Cleanup

This patch does the following:
1) Fix spacing issues and indentations.
2) Disable SAO by --no-sao option.

diff -r c4b098f973e6 -r 3d43f2f11af9 source/common/param.cpp
--- a/source/common/param.cpp	Tue Aug 13 10:51:21 2019 +0530
+++ b/source/common/param.cpp	Tue Sep 17 12:07:23 2019 +0530
@@ -185,12 +185,12 @@
     param->searchMethod = X265_HEX_SEARCH;
     param->subpelRefine = 2;
     param->searchRange = 57;
-	param->maxNumMergeCand = 3;
-	param->limitReferences = 1;
+    param->maxNumMergeCand = 3;
+    param->limitReferences = 1;
     param->limitModes = 0;
     param->bEnableWeightedPred = 1;
     param->bEnableWeightedBiPred = 0;
-	param->bEnableEarlySkip = 1;
+    param->bEnableEarlySkip = 1;
     param->bEnableRecursionSkip = 1;
     param->bEnableAMP = 0;
     param->bEnableRectInter = 0;
@@ -215,7 +215,7 @@
     param->bEnableSAO = 1;
     param->bSaoNonDeblocked = 0;
     param->bLimitSAO = 0;
-    param->selectiveSAO = 4;
+    param->selectiveSAO = 0;
 
     /* Coding Quality */
     param->cbQpOffset = 0;
@@ -229,7 +229,7 @@
     param->analysisReuseFileName = NULL;
     param->analysisSave = NULL;
     param->analysisLoad = NULL;
-	param->bIntraInBFrames = 1;
+    param->bIntraInBFrames = 1;
     param->bLossless = 0;
     param->bCULossless = 0;
     param->bEnableTemporalSubLayers = 0;
@@ -376,7 +376,6 @@
             param->subpelRefine = 0;
             param->searchMethod = X265_DIA_SEARCH;
             param->bEnableSAO = 0;
-            param->selectiveSAO = 0;
             param->bEnableSignHiding = 0;
             param->bEnableWeightedPred = 0;
             param->rdLevel = 2;
@@ -406,7 +405,6 @@
             param->rc.hevcAq = 0;
             param->rc.qgSize = 32;
             param->bEnableSAO = 0;
-            param->selectiveSAO = 0;
             param->bEnableFastIntra = 1;
         }
         else if (!strcmp(preset, "veryfast"))
@@ -554,7 +552,6 @@
         {
             param->bEnableLoopFilter = 0;
             param->bEnableSAO = 0;
-            param->selectiveSAO = 0;
             param->bEnableWeightedPred = 0;
             param->bEnableWeightedBiPred = 0;
             param->bIntraInBFrames = 0;
@@ -582,7 +579,6 @@
             param->psyRd = 4.0;
             param->psyRdoq = 10.0;
             param->bEnableSAO = 0;
-            param->selectiveSAO = 0;
             param->rc.bEnableConstVbv = 1;
         }
         else if (!strcmp(tune, "animation"))
@@ -1873,7 +1869,7 @@
     }
     TOOLOPT(param->bSaoNonDeblocked, "sao-non-deblock");
     TOOLOPT(!param->bSaoNonDeblocked && param->bEnableSAO, "sao");
-    if (param->selectiveSAO != 4)
+    if (param->selectiveSAO && param->selectiveSAO != 4)
         TOOLOPT(param->selectiveSAO, "selective-sao");
     TOOLOPT(param->rc.bStatWrite, "stats-write");
     TOOLOPT(param->rc.bStatRead,  "stats-read");
@@ -1984,7 +1980,7 @@
     BOOL(p->bEnableSAO, "sao");
     BOOL(p->bSaoNonDeblocked, "sao-non-deblock");
     s += sprintf(s, " rd=%d", p->rdLevel);
-    s += sprintf(s, "selective-sao=%d", p->selectiveSAO);
+    s += sprintf(s, " selective-sao=%d", p->selectiveSAO);
     BOOL(p->bEnableEarlySkip, "early-skip");
     BOOL(p->bEnableRecursionSkip, "rskip");
     BOOL(p->bEnableFastIntra, "fast-intra");
@@ -2078,7 +2074,7 @@
     if (p->masteringDisplayColorVolume)
         s += sprintf(s, " master-display=%s", p->masteringDisplayColorVolume);
     if (p->bEmitCLL)
-        s += sprintf(s, "cll=%hu,%hu", p->maxCLL, p->maxFALL);
+        s += sprintf(s, " cll=%hu,%hu", p->maxCLL, p->maxFALL);
     s += sprintf(s, " min-luma=%hu", p->minLuma);
     s += sprintf(s, " max-luma=%hu", p->maxLuma);
     s += sprintf(s, " log2-max-poc-lsb=%d", p->log2MaxPocLsb);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: x265.patch
Type: text/x-patch
Size: 3959 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20190917/82356fc5/attachment.bin>


More information about the x265-devel mailing list