ref: a422180695b1c16d897210e10bccd0ac1dd43660
parent: 3dccfabce38447862af35ec2d40179c3d96d7adb
parent: ab7eb1535dfb55984c43e021dfa676158f2d0d3c
author: HaiboZhu <[email protected]>
date: Wed Nov 25 10:05:12 EST 2015
Merge pull request #2277 from ruil2/qp_trace add minqp and maxqp parameters in console
--- a/codec/console/enc/src/welsenc.cpp
+++ b/codec/console/enc/src/welsenc.cpp
@@ -312,6 +312,10 @@
fprintf (stderr, "Invalid max overall bitrate setting due to RC enabled. Check MaxOverallBitrate field please!\n");
return 1;
}
+ } else if (strTag[0].compare ("MaxQp") == 0) {
+ pSvcParam.iMaxQp = atoi (strTag[1].c_str());
+ } else if (strTag[0].compare ("MinQp") == 0) {
+ pSvcParam.iMinQp = atoi (strTag[1].c_str());
} else if (strTag[0].compare ("EnableDenoise") == 0) {
pSvcParam.bEnableDenoise = atoi (strTag[1].c_str()) ? true : false;
} else if (strTag[0].compare ("EnableSceneChangeDetection") == 0) {
@@ -403,6 +407,8 @@
printf (" -rc rate control mode: 0-quality mode; 1-bitrate mode; 2-bitrate limited mode; -1-rc off \n");
printf (" -tarb Overall target bitrate\n");
printf (" -maxbrTotal Overall max bitrate\n");
+ printf (" -maxqp Maximum Qp\n");
+ printf (" -minqp Minimum Qp\n");
printf (" -numl Number Of Layers: Must exist with layer_cfg file and the number of input layer_cfg file must equal to the value set by this command\n");
printf (" The options below are layer-based: (need to be set with layer id)\n");
printf (" -lconfig (Layer) (spatial layer configure file)\n");
@@ -529,6 +535,12 @@
else if (!strcmp (pCommand, "-maxbrTotal") && (n < argc))
pSvcParam.iMaxBitrate = 1000 * atoi (argv[n++]);
+
+ else if (!strcmp (pCommand, "-maxqp") && (n < argc))
+ pSvcParam.iMaxQp = atoi (argv[n++]);
+
+ else if (!strcmp (pCommand, "-minqp") && (n < argc))
+ pSvcParam.iMinQp = atoi (argv[n++]);
else if (!strcmp (pCommand, "-numl") && (n < argc)) {
pSvcParam.iSpatialLayerNum = atoi (argv[n++]);
--- a/testbin/welsenc.cfg
+++ b/testbin/welsenc.cfg
@@ -34,7 +34,8 @@
TargetBitrate 5000 # Unit: kbps, controled by EnableRC also
MaxOverallBitrate 0 # Unit: kbps, max bitrate overall, 0 - unspecified
EnableFrameSkip 1 #Enable Frame Skip
-
+MaxQp 51 # maximum quant
+MinQp 0 # minimum quant
#============================== DENOISE CONTROL ==============================
EnableDenoise 0 # Enable Denoise (1: enable, 0: disable)
--- a/testbin/welsenc_arbitrary_res.cfg
+++ b/testbin/welsenc_arbitrary_res.cfg
@@ -33,7 +33,8 @@
RCMode 0 # 0: quality mode; 1: bitrate mode; # 2: buffer based mode,can't control bitrate; -1: rc off mode;
TargetBitrate 5000 # Unit: kbps, controled by EnableRC also
MaxOverallBitrate 6000 # Unit: kbps, max bitrate overall
-
+MaxQp 51 # maximum quant
+MinQp 0 # minimum quant
#============================== DENOISE CONTROL ==============================
EnableDenoise 0 # Enable Denoise (1: enable, 0: disable)
--- a/testbin/welsenc_ios.cfg
+++ b/testbin/welsenc_ios.cfg
@@ -34,7 +34,8 @@
TargetBitrate 5000 # Unit: kbps, controled by EnableRC also
MaxOverallBitrate 6000 # Unit: kbps, max bitrate overall
EnableFrameSkip 1 #Enable Frame Skip
-
+MaxQp 51 # maximum quant
+MinQp 0 # minimum quant
#============================== DENOISE CONTROL ==============================
EnableDenoise 0 # Enable Denoise (1: enable, 0: disable)
--- a/testbin/welsenc_vd_1d.cfg
+++ b/testbin/welsenc_vd_1d.cfg
@@ -33,7 +33,8 @@
RCMode 0 # 0: quality mode; 1: bitrate mode; # 2: buffer based mode,can't control bitrate; -1: rc off mode;
TargetBitrate 5000 # Unit: kbps, controled by EnableRC also
MaxOverallBitrate 6000 # Unit: kbps, max bitrate overall
-
+MaxQp 51 # maximum quant
+MinQp 0 # minimum quant
#============================== DENOISE CONTROL ==============================
EnableDenoise 0 # Enable Denoise (1: enable, 0: disable)
--- a/testbin/welsenc_vd_rc.cfg
+++ b/testbin/welsenc_vd_rc.cfg
@@ -33,7 +33,8 @@
RCMode 0 # 0: quality mode; 1: bitrate mode; # 2: buffer based mode,can't control bitrate; -1: rc off mode;
TargetBitrate 600 # Unit: kbps, controled by EnableRC also
MaxOverallBitrate 800 # Unit: kbps, max bitrate overall
-
+MaxQp 51 # maximum quant
+MinQp 0 # minimum quant
#============================== DENOISE CONTROL ==============================
EnableDenoise 1 # Enable Denoise (1: enable, 0: disable)