Ignore:
Timestamp:
12 Nov 2014, 08:09:17 (10 years ago)
Author:
seregin
Message:

initial porting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-upgrade/source/Lib/TLibCommon/TComRdCostWeightPrediction.h

    r595 r916  
    22 * License, included below. This software may be subject to other third party
    33 * and contributor rights, including patent rights, and no such rights are
    4  * granted under this license. 
     4 * granted under this license.
    55 *
    66 * Copyright (c) 2010-2014, ITU/ISO/IEC
     
    3333
    3434/** \file     TComRdCostWeightPrediction.h
    35     \brief    RD cost computation classes (header)
     35    \brief    RD cost computation namespace (header)
    3636*/
    3737
     
    5050
    5151// ====================================================================================================================
    52 // Class definition
     52// Namespace definition
    5353// ====================================================================================================================
    5454
    55 /// RD cost computation class, with Weighted Prediction
    56 class TComRdCostWeightPrediction
     55/// RD cost computation namespace, with Weighted Prediction
     56namespace TComRdCostWeightPrediction
    5757{
    58 private:
    59   static  Int   m_w0, m_w1; // current wp scaling values
    60   static  Int   m_shift;
    61   static  Int   m_offset;
    62   static  Int   m_round;
    63   static  Bool  m_xSetDone;
    64 
    65 public:
    66   TComRdCostWeightPrediction();
    67   virtual ~TComRdCostWeightPrediction();
    68  
    69 protected:
    70    
    71   static inline Void  xSetWPscale(Int w0, Int w1, Int shift, Int offset, Int round);
    72 
    73   static UInt xGetSSEw          ( DistParam* pcDtParam );
    74   static UInt xGetSADw          ( DistParam* pcDtParam );
    75   static UInt xGetHADs4w        ( DistParam* pcDtParam );
    76   static UInt xGetHADs8w        ( DistParam* pcDtParam );
    77   static UInt xGetHADsw         ( DistParam* pcDtParam );
    78   static UInt xCalcHADs2x2w     ( Pel *piOrg, Pel *piCurr, Int iStrideOrg, Int iStrideCur, Int iStep );
    79   static UInt xCalcHADs4x4w     ( Pel *piOrg, Pel *piCurr, Int iStrideOrg, Int iStrideCur, Int iStep );
    80   static UInt xCalcHADs8x8w     ( Pel *piOrg, Pel *piCurr, Int iStrideOrg, Int iStrideCur, Int iStep );
    81  
    82 };// END CLASS DEFINITION TComRdCostWeightPrediction
    83 
    84 inline Void  TComRdCostWeightPrediction::xSetWPscale(Int w0, Int w1, Int shift, Int offset, Int round)
    85 {
    86   m_w0        = w0;
    87   m_w1        = w1;
    88   m_shift     = shift;
    89   m_offset    = offset;
    90   m_round     = round;
    91 
    92   m_xSetDone  = true;
    93 }
     58  Distortion xGetSSEw ( DistParam* pcDtParam );
     59  Distortion xGetSADw ( DistParam* pcDtParam );
     60  Distortion xGetHADsw( DistParam* pcDtParam );
     61}// END NAMESPACE DEFINITION TComRdCostWeightPrediction
    9462
    9563#endif // __TCOMRDCOSTWEIGHTPREDICTION__
Note: See TracChangeset for help on using the changeset viewer.