Ignore:
Timestamp:
26 Jan 2013, 19:36:53 (12 years ago)
Author:
mitsubishi-htm
Message:

-Integration of JCT3V-C0152 & JCT3V-C0131
-This check-in enable C0131 only

Location:
branches/HTM-5.1-dev3-MERL/source/App/TAppEncoder
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-5.1-dev3-MERL/source/App/TAppEncoder/TAppEncCfg.cpp

    r210 r231  
    220220 
    221221  /* File, I/O and source parameters */
    222   ("InputFile_%d,i_%d",       m_pchInputFileList,       (char *) 0 , MAX_VIEW_NUM , "original Yuv input file name %d")
    223   ("DepthInputFile_%d,di_%d", m_pchDepthInputFileList,  (char *) 0 , MAX_VIEW_NUM , "original Yuv depth input file name %d")
    224   ("ReconFile_%d,o_%d",       m_pchReconFileList,       (char *) 0 , MAX_VIEW_NUM , "reconstructed Yuv output file name %d")
    225   ("DepthReconFile_%d,do_%d", m_pchDepthReconFileList,  (char *) 0 , MAX_VIEW_NUM , "reconstructed Yuv depth output file name %d")
    226   ("BitstreamFile,b", cfg_BitstreamFile, string(""), "bitstream output file name")
    227   ("CodeDepthMaps",         m_bUsingDepthMaps, false, "Encode depth maps" )
    228   ("CodedCamParsPrecision", m_iCodedCamParPrecision, STD_CAM_PARAMETERS_PRECISION, "precision for coding of camera parameters (in units of 2^(-x) luma samples)" )
    229   ("LambdaModifier0,-LM0", m_adLambdaModifier[ 0 ], ( double )1.0, "Lambda modifier for temporal layer 0")
    230   ("LambdaModifier1,-LM1", m_adLambdaModifier[ 1 ], ( double )1.0, "Lambda modifier for temporal layer 1")
    231   ("LambdaModifier2,-LM2", m_adLambdaModifier[ 2 ], ( double )1.0, "Lambda modifier for temporal layer 2")
    232   ("LambdaModifier3,-LM3", m_adLambdaModifier[ 3 ], ( double )1.0, "Lambda modifier for temporal layer 3")
    233   ("SourceWidth,-wdt",      m_iSourceWidth,  0, "Source picture width")
    234   ("SourceHeight,-hgt",     m_iSourceHeight, 0, "Source picture height")
     222  ("InputFile_%d,i_%d",       m_pchInputFileList,       (char *) 0 , MAX_VIEW_NUM ,   "original Yuv input file name %d")
     223  ("DepthInputFile_%d,di_%d", m_pchDepthInputFileList,  (char *) 0 , MAX_VIEW_NUM ,   "original Yuv depth input file name %d")
     224  ("ReconFile_%d,o_%d",       m_pchReconFileList,       (char *) 0 , MAX_VIEW_NUM ,   "reconstructed Yuv output file name %d")
     225  ("DepthReconFile_%d,do_%d", m_pchDepthReconFileList,  (char *) 0 , MAX_VIEW_NUM ,   "reconstructed Yuv depth output file name %d")
     226  ("BitstreamFile,b",         cfg_BitstreamFile,        string(""),                  "bitstream output file name")
     227  ("CodeDepthMaps",           m_bUsingDepthMaps,        false,                        "Encode depth maps" )
     228  ("CodedCamParsPrecision",   m_iCodedCamParPrecision, STD_CAM_PARAMETERS_PRECISION, "precision for coding of camera parameters (in units of 2^(-x) luma samples)" )
     229  ("LambdaModifier0,-LM0",    m_adLambdaModifier[ 0 ],  ( double )1.0,                "Lambda modifier for temporal layer 0")
     230  ("LambdaModifier1,-LM1",    m_adLambdaModifier[ 1 ],  ( double )1.0,                "Lambda modifier for temporal layer 1")
     231  ("LambdaModifier2,-LM2",    m_adLambdaModifier[ 2 ],  ( double )1.0,                "Lambda modifier for temporal layer 2")
     232  ("LambdaModifier3,-LM3",    m_adLambdaModifier[ 3 ],  ( double )1.0,                "Lambda modifier for temporal layer 3")
     233  ("SourceWidth,-wdt",        m_iSourceWidth,           0,                            "Source picture width")
     234  ("SourceHeight,-hgt",       m_iSourceHeight,          0,                            "Source picture height")
    235235#if PIC_CROPPING
    236   ("CroppingMode",          m_croppingMode,  0, "Cropping mode (0: no cropping, 1:automatic padding, 2: padding, 3:cropping")
    237   ("CropLeft",              m_cropLeft,      0, "Left cropping/padding for cropping mode 3")
    238   ("CropRight",             m_cropRight,     0, "Right cropping/padding for cropping mode 3")
    239   ("CropTop",               m_cropTop,       0, "Top cropping/padding for cropping mode 3")
    240   ("CropBottom",            m_cropBottom,    0, "Bottom cropping/padding for cropping mode 3")
    241   ("HorizontalPadding,-pdx",m_aiPad[0],      0, "horizontal source padding for cropping mode 2")
    242   ("VerticalPadding,-pdy",  m_aiPad[1],      0, "vertical source padding for cropping mode 2")
     236  ("CroppingMode",            m_croppingMode,           0,                            "Cropping mode (0: no cropping, 1:automatic padding, 2: padding, 3:cropping")
     237  ("CropLeft",                m_cropLeft,               0,                            "Left cropping/padding for cropping mode 3")
     238  ("CropRight",               m_cropRight,              0,                            "Right cropping/padding for cropping mode 3")
     239  ("CropTop",                 m_cropTop,                0,                            "Top cropping/padding for cropping mode 3")
     240  ("CropBottom",              m_cropBottom,             0,                            "Bottom cropping/padding for cropping mode 3")
     241  ("HorizontalPadding,-pdx",  m_aiPad[0],               0,                            "horizontal source padding for cropping mode 2")
     242  ("VerticalPadding,-pdy",    m_aiPad[1],               0,                            "vertical source padding for cropping mode 2")
    243243#endif
    244244  ("InputBitDepth",         m_uiInputBitDepth, 8u, "bit-depth of input file")
     
    254254  ("FrameSkip,-fs",         m_FrameSkip,         0u, "Number of frames to skip at start of input YUV")
    255255  ("FramesToBeEncoded,f",   m_iFrameToBeEncoded, 0, "number of frames to be encoded (default=all)")
    256   ("FrameToBeEncoded",        m_iFrameToBeEncoded, 0, "deprecated alias of FramesToBeEncoded")
     256  ("FrameToBeEncoded",      m_iFrameToBeEncoded, 0, "deprecated alias of FramesToBeEncoded")
    257257 
    258258  ("NumberOfViews",         m_iNumberOfViews,    0, "Number of views")
  • branches/HTM-5.1-dev3-MERL/source/App/TAppEncoder/TAppEncTop.cpp

    r210 r231  
    793793  m_cUsedPelsRenderer.init(m_iSourceWidth, m_iSourceHeight, true, 0, LOG2_DISP_PREC_LUT, true, 0, 0, 0, 0, 0, 6, 4, 1, 0, 6 );
    794794#endif
    795 
    796795}
    797796
     
    931930  TComPicYuv*       pcPicYuvRec = NULL;
    932931  TComPicYuv*       pcDepthPicYuvRec = NULL;
    933  
     932
    934933  // initialize internal class & member variables
    935934  xInitLibCfg();
     
    10331032      if ( iNextPoc < m_iFrameToBeEncoded )
    10341033      {
    1035       m_cCameraData.update( iNextPoc );
     1034        m_cCameraData.update( iNextPoc );
    10361035      }
    10371036#endif
     
    10961095#endif
    10971096        iNumEncoded = 0;
     1097
     1098#if MERL_VSP_C0152
     1099        Int iCurPoc = m_acTEncDepthTopList[iViewIdx]->getFrameId(gopId);
     1100        if( iCurPoc < m_acTEncDepthTopList[iViewIdx]->getFrameToBeEncoded() && iViewIdx!=0 )
     1101        {
     1102          TComPic* pcBaseTxtPic   = getPicFromView(  0, m_acTEncDepthTopList[iViewIdx]->getFrameId(gopId), false ); //get base view reconstructed texture
     1103          TComPic* pcBaseDepthPic = getPicFromView(  0, m_acTEncDepthTopList[iViewIdx]->getFrameId(gopId), true );  //get base view reconstructed depth
     1104          TEncSlice* pEncSlice = m_acTEncTopList[iViewIdx]->getSliceEncoder();
     1105          pEncSlice->setRefPicBaseTxt(pcBaseTxtPic);
     1106          pEncSlice->setRefPicBaseDepth(pcBaseDepthPic);
     1107        }
     1108        setBWVSPLUT( iViewIdx, gopId, false);
     1109#endif
    10981110        // call encoding function for one frame
    10991111        m_acTEncTopList[iViewIdx]->encode( eos[iViewIdx], pcPicYuvOrg, *m_picYuvRec[iViewIdx], outputAccessUnits, iNumEncoded, gopId );
     
    11031115        {
    11041116          Int  iNumDepthEncoded = 0;
     1117#if MERL_VSP_C0152
     1118        Int iCurPocDepth = m_acTEncDepthTopList[iViewIdx]->getFrameId(gopId);
     1119        if( iCurPocDepth < m_acTEncDepthTopList[iViewIdx]->getFrameToBeEncoded() && iViewIdx!=0 )
     1120        {
     1121          TComPic* pcBaseDepthPic = getPicFromView(  0, m_acTEncDepthTopList[iViewIdx]->getFrameId(gopId), true );
     1122          TEncSlice* pcSlice = (TEncSlice*) m_acTEncDepthTopList[iViewIdx]->getSliceEncoder();
     1123          pcSlice->setRefPicBaseDepth(pcBaseDepthPic);
     1124        }
     1125        setBWVSPLUT( iViewIdx, gopId, true);
     1126#endif
     1127
    11051128          // call encoding function for one depth frame
    11061129          m_acTEncDepthTopList[iViewIdx]->encode( depthEos[iViewIdx], pcDepthPicYuvOrg, *m_picYuvDepthRec[iViewIdx], outputAccessUnits, iNumDepthEncoded, gopId );
     
    16341657#endif
    16351658
     1659#if MERL_VSP_C0152
     1660Void TAppEncTop::setBWVSPLUT(Int iCodedViewIdx, Int gopId, Bool isDepth)
     1661{
     1662  //first view does not have VSP
     1663  if((iCodedViewIdx == 0)) return;
     1664
     1665  AOT( iCodedViewIdx <= 0);
     1666  AOT( iCodedViewIdx >= m_iNumberOfViews );
     1667
     1668  Int iNeighborViewId = 0;
     1669  //setting look-up table
     1670  Int* piShiftLUT = m_cCameraData.getBaseViewShiftLUTI()[iNeighborViewId][iCodedViewIdx][0];
     1671
     1672  if(isDepth)
     1673  {
     1674    TEncSlice* pcEncSlice = (TEncSlice*) m_acTEncDepthTopList[iCodedViewIdx]->getSliceEncoder();
     1675    pcEncSlice->setBWVSPLUTParam(  piShiftLUT, LOG2_DISP_PREC_LUT );
     1676  }
     1677  else
     1678  {
     1679    TEncSlice* pcEncSlice = (TEncSlice*) m_acTEncTopList[iCodedViewIdx]->getSliceEncoder();
     1680    pcEncSlice->setBWVSPLUTParam(  piShiftLUT, LOG2_DISP_PREC_LUT );
     1681  }
     1682
     1683}
     1684#endif
     1685
    16361686//! \}
  • branches/HTM-5.1-dev3-MERL/source/App/TAppEncoder/TAppEncTop.h

    r210 r231  
    9999  TRenTop  m_cUsedPelsRenderer;                               ///< renderer for used pels map
    100100#endif
     101
    101102protected:
    102103  // initialization
     
    165166#endif
    166167
     168#if MERL_VSP_C0152
     169  Void setBWVSPLUT( Int iCodedViewIdx, Int gopId, Bool isDepth);
     170#endif
    167171};// END CLASS DEFINITION TAppEncTop
    168172
Note: See TracChangeset for help on using the changeset viewer.