HEVC Test Model (HM)  HM-16.18
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TEncRateCtrl.h
Go to the documentation of this file.
1 /* The copyright in this software is being made available under the BSD
2  * License, included below. This software may be subject to other third party
3  * and contributor rights, including patent rights, and no such rights are
4  * granted under this license.
5  *
6  * Copyright (c) 2010-2017, ITU/ISO/IEC
7  * All rights reserved.
8  *
9  * Redistribution and use in source and binary forms, with or without
10  * modification, are permitted provided that the following conditions are met:
11  *
12  * * Redistributions of source code must retain the above copyright notice,
13  * this list of conditions and the following disclaimer.
14  * * Redistributions in binary form must reproduce the above copyright notice,
15  * this list of conditions and the following disclaimer in the documentation
16  * and/or other materials provided with the distribution.
17  * * Neither the name of the ITU/ISO/IEC nor the names of its contributors may
18  * be used to endorse or promote products derived from this software without
19  * specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
25  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
31  * THE POSSIBILITY OF SUCH DAMAGE.
32  */
33 
38 #ifndef __TENCRATECTRL__
39 #define __TENCRATECTRL__
40 
41 #if _MSC_VER > 1000
42 #pragma once
43 #endif // _MSC_VER > 1000
44 
45 
46 #include "../TLibCommon/CommonDef.h"
47 #include "../TLibCommon/TComDataCU.h"
48 
49 #include <vector>
50 #include <algorithm>
51 
52 using namespace std;
53 
56 
57 #include "../TLibEncoder/TEncCfg.h"
58 #include <list>
59 #include <cassert>
60 
61 const Int g_RCInvalidQPValue = -999;
66 const Int g_RCIterationNum = 20;
71 const Double g_RCAlphaMaxValue = 500.0;
72 const Double g_RCBetaMinValue = -3.0;
73 const Double g_RCBetaMaxValue = -0.1;
74 
75 #define ALPHA 6.7542;
76 #define BETA1 1.2517
77 #define BETA2 1.7860
78 
79 struct TRCLCU
80 {
82  Int m_QP; // QP of skip mode is set to g_RCInvalidQPValue
89 };
90 
92 {
95 };
96 
97 class TEncRCSeq
98 {
99 public:
100  TEncRCSeq();
101  ~TEncRCSeq();
102 
103 public:
104  Void create( Int totalFrames, Int targetBitrate, Int frameRate, Int GOPSize, Int picWidth, Int picHeight, Int LCUWidth, Int LCUHeight, Int numberOfLevel, Bool useLCUSeparateModel, Int adaptiveBit );
105  Void destroy();
106  Void initBitsRatio( Int bitsRatio[] );
107  Void initGOPID2Level( Int GOPID2Level[] );
108  Void initPicPara( TRCParameter* picPara = NULL ); // NULL to initial with default value
109  Void initLCUPara( TRCParameter** LCUPara = NULL ); // NULL to initial with default value
110  Void updateAfterPic ( Int bits );
111  Void setAllBitRatio( Double basicLambda, Double* equaCoeffA, Double* equaCoeffB );
112 
113 public:
114  Int getTotalFrames() { return m_totalFrames; }
115  Int getTargetRate() { return m_targetRate; }
116  Int getFrameRate() { return m_frameRate; }
117  Int getGOPSize() { return m_GOPSize; }
118  Int getPicWidth() { return m_picWidth; }
119  Int getPicHeight() { return m_picHeight; }
120  Int getLCUWidth() { return m_LCUWidth; }
121  Int getLCUHeight() { return m_LCUHeight; }
122  Int getNumberOfLevel() { return m_numberOfLevel; }
123  Int getAverageBits() { return m_averageBits; }
124  Int getLeftAverageBits() { assert( m_framesLeft > 0 ); return (Int)(m_bitsLeft / m_framesLeft); }
125  Bool getUseLCUSeparateModel() { return m_useLCUSeparateModel; }
126 
127  Int getNumPixel() { return m_numberOfPixel; }
128  Int64 getTargetBits() { return m_targetBits; }
129  Int getNumberOfLCU() { return m_numberOfLCU; }
130  Int* getBitRatio() { return m_bitsRatio; }
131  Int getBitRatio( Int idx ) { assert( idx<m_GOPSize); return m_bitsRatio[idx]; }
132  Int* getGOPID2Level() { return m_GOPID2Level; }
133  Int getGOPID2Level( Int ID ) { assert( ID < m_GOPSize ); return m_GOPID2Level[ID]; }
134  TRCParameter* getPicPara() { return m_picPara; }
135  TRCParameter getPicPara( Int level ) { assert( level < m_numberOfLevel ); return m_picPara[level]; }
136  Void setPicPara( Int level, TRCParameter para ) { assert( level < m_numberOfLevel ); m_picPara[level] = para; }
137  TRCParameter** getLCUPara() { return m_LCUPara; }
138  TRCParameter* getLCUPara( Int level ) { assert( level < m_numberOfLevel ); return m_LCUPara[level]; }
139  TRCParameter getLCUPara( Int level, Int LCUIdx ) { assert( LCUIdx < m_numberOfLCU ); return getLCUPara(level)[LCUIdx]; }
140  Void setLCUPara( Int level, Int LCUIdx, TRCParameter para ) { assert( level < m_numberOfLevel ); assert( LCUIdx < m_numberOfLCU ); m_LCUPara[level][LCUIdx] = para; }
141 
142  Int getFramesLeft() { return m_framesLeft; }
143  Int64 getBitsLeft() { return m_bitsLeft; }
144 
145  Double getSeqBpp() { return m_seqTargetBpp; }
146  Double getAlphaUpdate() { return m_alphaUpdate; }
147  Double getBetaUpdate() { return m_betaUpdate; }
148 
149  Int getAdaptiveBits() { return m_adaptiveBit; }
150  Double getLastLambda() { return m_lastLambda; }
151  Void setLastLambda( Double lamdba ) { m_lastLambda = lamdba; }
152 
153 private:
164 
172 
179 
182 };
183 
185 {
186 public:
187  TEncRCGOP();
188  ~TEncRCGOP();
189 
190 public:
191  Void create( TEncRCSeq* encRCSeq, Int numPic );
192  Void destroy();
193  Void updateAfterPicture( Int bitsCost );
194 
195 private:
196  Int xEstGOPTargetBits( TEncRCSeq* encRCSeq, Int GOPSize );
197  Void xCalEquaCoeff( TEncRCSeq* encRCSeq, Double* lambdaRatio, Double* equaCoeffA, Double* equaCoeffB, Int GOPSize );
198  Double xSolveEqua( Double targetBpp, Double* equaCoeffA, Double* equaCoeffB, Int GOPSize );
199 
200 public:
201  TEncRCSeq* getEncRCSeq() { return m_encRCSeq; }
202  Int getNumPic() { return m_numPic;}
203  Int getTargetBits() { return m_targetBits; }
204  Int getPicLeft() { return m_picLeft; }
205  Int getBitsLeft() { return m_bitsLeft; }
206  Int getTargetBitInGOP( Int i ) { return m_picTargetBitInGOP[i]; }
207 
208 private:
215 };
216 
218 {
219 public:
220  TEncRCPic();
221  ~TEncRCPic();
222 
223 public:
224  Void create( TEncRCSeq* encRCSeq, TEncRCGOP* encRCGOP, Int frameLevel, list<TEncRCPic*>& listPreviousPictures );
225  Void destroy();
226 
227  Int estimatePicQP ( Double lambda, list<TEncRCPic*>& listPreviousPictures );
228  Int getRefineBitsForIntra(Int orgBits);
229  Double calculateLambdaIntra(Double alpha, Double beta, Double MADPerPixel, Double bitsPerPixel);
230  Double estimatePicLambda( list<TEncRCPic*>& listPreviousPictures, SliceType eSliceType);
231 
232  Void updateAlphaBetaIntra(Double *alpha, Double *beta);
233 
234  Double getLCUTargetBpp(SliceType eSliceType);
235  Double getLCUEstLambdaAndQP(Double bpp, Int clipPicQP, Int *estQP);
236  Double getLCUEstLambda( Double bpp );
237  Int getLCUEstQP( Double lambda, Int clipPicQP );
238 
239  Void updateAfterCTU( Int LCUIdx, Int bits, Int QP, Double lambda, Bool updateLCUParameter = true );
240  Void updateAfterPicture( Int actualHeaderBits, Int actualTotalBits, Double averageQP, Double averageLambda, SliceType eSliceType);
241 
242  Void addToPictureLsit( list<TEncRCPic*>& listPreviousPictures );
243  Double calAverageQP();
244  Double calAverageLambda();
245 
246 private:
247  Int xEstPicTargetBits( TEncRCSeq* encRCSeq, TEncRCGOP* encRCGOP );
248  Int xEstPicHeaderBits( list<TEncRCPic*>& listPreviousPictures, Int frameLevel );
249  Int xEstPicLowerBound( TEncRCSeq* encRCSeq, TEncRCGOP* encRCGOP );
250 
251 public:
252  TEncRCSeq* getRCSequence() { return m_encRCSeq; }
253  TEncRCGOP* getRCGOP() { return m_encRCGOP; }
254 
255  Int getFrameLevel() { return m_frameLevel; }
256  Int getNumberOfPixel() { return m_numberOfPixel; }
257  Int getNumberOfLCU() { return m_numberOfLCU; }
258  Int getTargetBits() { return m_targetBits; }
259  Int getEstHeaderBits() { return m_estHeaderBits; }
260  Int getLCULeft() { return m_LCULeft; }
261  Int getBitsLeft() { return m_bitsLeft; }
262  Int getPixelsLeft() { return m_pixelsLeft; }
263  Int getBitsCoded() { return m_targetBits - m_estHeaderBits - m_bitsLeft; }
264  Int getLCUCoded() { return m_numberOfLCU - m_LCULeft; }
265  Int getLowerBound() { return m_lowerBound; }
266  TRCLCU* getLCU() { return m_LCUs; }
267  TRCLCU& getLCU( Int LCUIdx ) { return m_LCUs[LCUIdx]; }
268  Int getPicActualHeaderBits() { return m_picActualHeaderBits; }
269  Void setBitLeft(Int bits) { m_bitsLeft = bits; }
270  Void setTargetBits( Int bits ) { m_targetBits = bits; m_bitsLeft = bits;}
271  Void setTotalIntraCost(Double cost) { m_totalCostIntra = cost; }
272  Void getLCUInitTargetBits();
273 
274  Int getPicActualBits() { return m_picActualBits; }
275  Int getPicActualQP() { return m_picQP; }
276  Double getPicActualLambda() { return m_picLambda; }
277  Int getPicEstQP() { return m_estPicQP; }
278  Void setPicEstQP( Int QP ) { m_estPicQP = QP; }
279  Double getPicEstLambda() { return m_estPicLambda; }
280  Void setPicEstLambda( Double lambda ) { m_picLambda = lambda; }
281 
282 private:
285 
294 
298 
300  Int m_picActualHeaderBits; // only SH and potential APS
303  Int m_picActualBits; // the whole picture, including header
304  Int m_picQP; // in integer form
306 };
307 
309 {
310 public:
311  TEncRateCtrl();
312  ~TEncRateCtrl();
313 
314 public:
315  Void init( Int totalFrames, Int targetBitrate, Int frameRate, Int GOPSize, Int picWidth, Int picHeight, Int LCUWidth, Int LCUHeight, Int keepHierBits, Bool useLCUSeparateModel, GOPEntry GOPList[MAX_GOP] );
316  Void destroy();
317  Void initRCPic( Int frameLevel );
318  Void initRCGOP( Int numberOfPictures );
319  Void destroyRCGOP();
320 
321 public:
322  Void setRCQP ( Int QP ) { m_RCQP = QP; }
323  Int getRCQP () { return m_RCQP; }
324  TEncRCSeq* getRCSeq() { assert ( m_encRCSeq != NULL ); return m_encRCSeq; }
325  TEncRCGOP* getRCGOP() { assert ( m_encRCGOP != NULL ); return m_encRCGOP; }
326  TEncRCPic* getRCPic() { assert ( m_encRCPic != NULL ); return m_encRCPic; }
327  list<TEncRCPic*>& getPicList() { return m_listRCPictures; }
328  Bool getCpbSaturationEnabled() { return m_CpbSaturationEnabled; }
329  UInt getCpbState() { return m_cpbState; }
330  UInt getCpbSize() { return m_cpbSize; }
331  UInt getBufferingRate() { return m_bufferingRate; }
332  Int updateCpbState(Int actualBits);
333  Void initHrdParam(const TComHRD* pcHrd, Int iFrameRate, Double fInitialCpbFullness);
334 
335 private:
339  list<TEncRCPic*> m_listRCPictures;
341  Bool m_CpbSaturationEnabled; // Enable target bits saturation to avoid CPB overflow and underflow
342  Int m_cpbState; // CPB State
343  UInt m_cpbSize; // CPB size
344  UInt m_bufferingRate; // Buffering rate
345 };
346 
347 #endif
348 
349 
Int m_targetBits
Definition: TEncRateCtrl.h:289
Int m_totalFrames
Definition: TEncRateCtrl.h:154
Int m_numberOfPixel
Definition: TEncRateCtrl.h:86
Double m_betaUpdate
Definition: TEncRateCtrl.h:177
Int getPixelsLeft()
Definition: TEncRateCtrl.h:262
Int m_picHeight
Definition: TEncRateCtrl.h:159
const Double g_RCBetaMaxValue
Definition: TEncRateCtrl.h:73
Int getPicActualBits()
Definition: TEncRateCtrl.h:274
SliceType
supported slice type
Definition: TypeDef.h:283
Double m_bitWeight
Definition: TEncRateCtrl.h:85
Double m_beta
Definition: TEncRateCtrl.h:94
Int getGOPSize()
Definition: TEncRateCtrl.h:117
Int getNumberOfLevel()
Definition: TEncRateCtrl.h:122
TRCLCU * getLCU()
Definition: TEncRateCtrl.h:266
Int m_bitsLeft
Definition: TEncRateCtrl.h:214
Void setPicEstLambda(Double lambda)
Definition: TEncRateCtrl.h:280
Int getNumberOfPixel()
Definition: TEncRateCtrl.h:256
Int getLowerBound()
Definition: TEncRateCtrl.h:265
Double m_lambda
Definition: TEncRateCtrl.h:84
void Void
Definition: TypeDef.h:203
Int m_lowerBound
Definition: TEncRateCtrl.h:292
Int getPicLeft()
Definition: TEncRateCtrl.h:204
Int m_numberOfPixel
Definition: TEncRateCtrl.h:287
TEncRCSeq * m_encRCSeq
Definition: TEncRateCtrl.h:336
#define NULL
Definition: CommonDef.h:107
Void setBitLeft(Int bits)
Definition: TEncRateCtrl.h:269
Int getLCUHeight()
Definition: TEncRateCtrl.h:121
Void setPicEstQP(Int QP)
Definition: TEncRateCtrl.h:278
Double m_remainingCostIntra
Definition: TEncRateCtrl.h:302
Int m_pixelsLeft
Definition: TEncRateCtrl.h:297
Int m_LCUHeight
Definition: TEncRateCtrl.h:161
Double m_totalCostIntra
Definition: TEncRateCtrl.h:301
TEncRCGOP * m_encRCGOP
Definition: TEncRateCtrl.h:284
TEncRCGOP * getRCGOP()
Definition: TEncRateCtrl.h:325
UInt getBufferingRate()
Definition: TEncRateCtrl.h:331
const Double g_RCAlphaMaxValue
Definition: TEncRateCtrl.h:71
const Double g_RCAlphaMinValue
Definition: TEncRateCtrl.h:70
Double getPicActualLambda()
Definition: TEncRateCtrl.h:276
unsigned int UInt
Definition: TypeDef.h:212
Int getPicWidth()
Definition: TEncRateCtrl.h:118
Double getSeqBpp()
Definition: TEncRateCtrl.h:145
Int * getBitRatio()
Definition: TEncRateCtrl.h:130
Int getLCUCoded()
Definition: TEncRateCtrl.h:264
TEncRCSeq * m_encRCSeq
Definition: TEncRateCtrl.h:209
Int64 getBitsLeft()
Definition: TEncRateCtrl.h:143
TEncRCSeq * getRCSeq()
Definition: TEncRateCtrl.h:324
Definition: TEncCfg.h:49
Int m_picActualBits
Definition: TEncRateCtrl.h:303
Double m_lastLambda
Definition: TEncRateCtrl.h:181
Int m_targetBits
Definition: TEncRateCtrl.h:83
TRCParameter getLCUPara(Int level, Int LCUIdx)
Definition: TEncRateCtrl.h:139
const Int g_RCInvalidQPValue
Definition: TEncRateCtrl.h:61
Int getLeftAverageBits()
Definition: TEncRateCtrl.h:124
Int getGOPID2Level(Int ID)
Definition: TEncRateCtrl.h:133
TEncRCPic * getRCPic()
Definition: TEncRateCtrl.h:326
TRCLCU & getLCU(Int LCUIdx)
Definition: TEncRateCtrl.h:267
Int getTargetBits()
Definition: TEncRateCtrl.h:203
Int getNumberOfLCU()
Definition: TEncRateCtrl.h:129
Int * m_GOPID2Level
Definition: TEncRateCtrl.h:169
Double m_costIntra
Definition: TEncRateCtrl.h:87
Int getFramesLeft()
Definition: TEncRateCtrl.h:142
Int getFrameLevel()
Definition: TEncRateCtrl.h:255
const Double g_RCWeightPicTargetBitInGOP
Definition: TEncRateCtrl.h:64
Void setPicPara(Int level, TRCParameter para)
Definition: TEncRateCtrl.h:136
Int getBitsCoded()
Definition: TEncRateCtrl.h:263
Double getPicEstLambda()
Definition: TEncRateCtrl.h:279
Int getNumPic()
Definition: TEncRateCtrl.h:202
list< TEncRCPic * > m_listRCPictures
Definition: TEncRateCtrl.h:339
Int m_numberOfLCU
Definition: TEncRateCtrl.h:288
Void setTotalIntraCost(Double cost)
Definition: TEncRateCtrl.h:271
Bool getCpbSaturationEnabled()
Definition: TEncRateCtrl.h:328
Int m_estPicQP
Definition: TEncRateCtrl.h:291
Int * getGOPID2Level()
Definition: TEncRateCtrl.h:132
static const Int MAX_GOP
max. value of hierarchical GOP size
Definition: CommonDef.h:123
Int getBitsLeft()
Definition: TEncRateCtrl.h:205
const Int g_RCMaxPicListSize
Definition: TEncRateCtrl.h:63
TRCParameter * getPicPara()
Definition: TEncRateCtrl.h:134
Int m_frameLevel
Definition: TEncRateCtrl.h:286
bool Bool
Definition: TypeDef.h:204
Int * m_picTargetBitInGOP
Definition: TEncRateCtrl.h:210
long long Int64
Definition: TypeDef.h:232
const Int g_RCIterationNum
Definition: TEncRateCtrl.h:66
Int getLCULeft()
Definition: TEncRateCtrl.h:260
TEncRCSeq * m_encRCSeq
Definition: TEncRateCtrl.h:283
Int * m_bitsRatio
Definition: TEncRateCtrl.h:168
Int getNumPixel()
Definition: TEncRateCtrl.h:127
Int m_targetBits
Definition: TEncRateCtrl.h:212
Int getEstHeaderBits()
Definition: TEncRateCtrl.h:259
Int getPicHeight()
Definition: TEncRateCtrl.h:119
Int getBitsLeft()
Definition: TEncRateCtrl.h:261
TRCLCU * m_LCUs
Definition: TEncRateCtrl.h:299
Int getLCUWidth()
Definition: TEncRateCtrl.h:120
Bool m_useLCUSeparateModel
Definition: TEncRateCtrl.h:178
Double m_picLambda
Definition: TEncRateCtrl.h:305
const Double g_RCWeightPicRargetBitInBuffer
Definition: TEncRateCtrl.h:65
Int64 m_bitsLeft
Definition: TEncRateCtrl.h:174
TEncRCSeq * getRCSequence()
Definition: TEncRateCtrl.h:252
UInt getCpbState()
Definition: TEncRateCtrl.h:329
Double getAlphaUpdate()
Definition: TEncRateCtrl.h:146
const Int g_RCSmoothWindowSize
Definition: TEncRateCtrl.h:62
Double m_estPicLambda
Definition: TEncRateCtrl.h:293
Int64 m_targetBits
Definition: TEncRateCtrl.h:166
TEncRCGOP * getRCGOP()
Definition: TEncRateCtrl.h:253
Int m_estHeaderBits
Definition: TEncRateCtrl.h:290
Double getBetaUpdate()
Definition: TEncRateCtrl.h:147
TEncRCPic * m_encRCPic
Definition: TEncRateCtrl.h:338
Double getLastLambda()
Definition: TEncRateCtrl.h:150
Int m_picActualHeaderBits
Definition: TEncRateCtrl.h:300
Int m_numberOfLCU
Definition: TEncRateCtrl.h:167
TRCParameter ** m_LCUPara
Definition: TEncRateCtrl.h:171
Int getFrameRate()
Definition: TEncRateCtrl.h:116
Int m_bitsLeft
Definition: TEncRateCtrl.h:296
Int getNumberOfLCU()
Definition: TEncRateCtrl.h:257
Void setLCUPara(Int level, Int LCUIdx, TRCParameter para)
Definition: TEncRateCtrl.h:140
TRCParameter * getLCUPara(Int level)
Definition: TEncRateCtrl.h:138
Int getTargetRate()
Definition: TEncRateCtrl.h:115
const Double g_RCWeightHistoryLambda
Definition: TEncRateCtrl.h:67
Int m_frameRate
Definition: TEncRateCtrl.h:156
Int m_numberOfLevel
Definition: TEncRateCtrl.h:162
Int m_targetRate
Definition: TEncRateCtrl.h:155
const Double g_RCWeightCurrentLambda
Definition: TEncRateCtrl.h:68
Int m_picWidth
Definition: TEncRateCtrl.h:158
Bool m_CpbSaturationEnabled
Definition: TEncRateCtrl.h:341
Void setTargetBits(Int bits)
Definition: TEncRateCtrl.h:270
Bool getUseLCUSeparateModel()
Definition: TEncRateCtrl.h:125
Int m_LCUWidth
Definition: TEncRateCtrl.h:160
Void setRCQP(Int QP)
Definition: TEncRateCtrl.h:322
Int m_targetBitsLeft
Definition: TEncRateCtrl.h:88
Int m_QP
Definition: TEncRateCtrl.h:82
Int getTargetBitInGOP(Int i)
Definition: TEncRateCtrl.h:206
Int m_actualBits
Definition: TEncRateCtrl.h:81
Int64 getTargetBits()
Definition: TEncRateCtrl.h:128
Int m_numberOfPixel
Definition: TEncRateCtrl.h:165
Int m_framesLeft
Definition: TEncRateCtrl.h:173
int Int
Definition: TypeDef.h:211
Int getAdaptiveBits()
Definition: TEncRateCtrl.h:149
TRCParameter getPicPara(Int level)
Definition: TEncRateCtrl.h:135
Int m_averageBits
Definition: TEncRateCtrl.h:163
Void setLastLambda(Double lamdba)
Definition: TEncRateCtrl.h:151
TRCParameter * m_picPara
Definition: TEncRateCtrl.h:170
Int getPicActualHeaderBits()
Definition: TEncRateCtrl.h:268
list< TEncRCPic * > & getPicList()
Definition: TEncRateCtrl.h:327
Int getTargetBits()
Definition: TEncRateCtrl.h:258
UInt getCpbSize()
Definition: TEncRateCtrl.h:330
Int getAverageBits()
Definition: TEncRateCtrl.h:123
Double m_alphaUpdate
Definition: TEncRateCtrl.h:176
double Double
Definition: TypeDef.h:213
Double m_seqTargetBpp
Definition: TEncRateCtrl.h:175
const Int g_RCLCUSmoothWindowSize
Definition: TEncRateCtrl.h:69
Int m_adaptiveBit
Definition: TEncRateCtrl.h:180
UInt m_bufferingRate
Definition: TEncRateCtrl.h:344
Double m_alpha
Definition: TEncRateCtrl.h:93
Int getPicEstQP()
Definition: TEncRateCtrl.h:277
Int getTotalFrames()
Definition: TEncRateCtrl.h:114
const Double g_RCBetaMinValue
Definition: TEncRateCtrl.h:72
Int getBitRatio(Int idx)
Definition: TEncRateCtrl.h:131
Int getPicActualQP()
Definition: TEncRateCtrl.h:275
TEncRCSeq * getEncRCSeq()
Definition: TEncRateCtrl.h:201
TEncRCGOP * m_encRCGOP
Definition: TEncRateCtrl.h:337
TRCParameter ** getLCUPara()
Definition: TEncRateCtrl.h:137