private UInt32 GetRepPrice(UInt32 repIndex, UInt32 len, Base.State state, UInt32 posState) { UInt32 price = _repMatchLenEncoder.GetPrice(len - Base.kMatchMinLen, posState); return price + GetPureRepPrice(repIndex, state, posState); }
private UInt32 GetPureRepPrice(UInt32 repIndex, Base.State state, UInt32 posState) { UInt32 price; if (repIndex == 0) { price = _isRepG0[state.Index].GetPrice0(); price += _isRep0Long[(state.Index << Base.kNumPosStatesBitsMax) + posState].GetPrice1(); } else { price = _isRepG0[state.Index].GetPrice1(); if (repIndex == 1) price += _isRepG1[state.Index].GetPrice0(); else { price += _isRepG1[state.Index].GetPrice1(); price += _isRepG2[state.Index].GetPrice(repIndex - 2); } } return price; }
private UInt32 GetRepLen1Price(Base.State state, UInt32 posState) { return _isRepG0[state.Index].GetPrice0() + _isRep0Long[(state.Index << Base.kNumPosStatesBitsMax) + posState].GetPrice0(); }
private uint GetRepPrice(uint repIndex, uint len, Base.State state, uint posState) { return (this._repMatchLenEncoder.GetPrice(len - 2, posState) + this.GetPureRepPrice(repIndex, state, posState)); }
private uint GetRepLen1Price(Base.State state, uint posState) { return (this._isRepG0[state.Index].GetPrice0() + this._isRep0Long[(state.Index << 4) + posState].GetPrice0()); }
private uint GetPureRepPrice(uint repIndex, Base.State state, uint posState) { if (repIndex == 0) { return (this._isRepG0[state.Index].GetPrice0() + this._isRep0Long[(state.Index << 4) + posState].GetPrice1()); } uint num = this._isRepG0[state.Index].GetPrice1(); if (repIndex == 1) { return (num + this._isRepG1[state.Index].GetPrice0()); } num += this._isRepG1[state.Index].GetPrice1(); return (num + this._isRepG2[state.Index].GetPrice(repIndex - 2)); }