Ignore:
Timestamp:
13 May 2015, 15:16:14 (10 years ago)
Author:
hhi
Message:

Alignment and reactivation of DMM and depth encoder optimizations:

  • new macro NH_3D_DMM for DMM functionality, including several clean-ups.
  • new macro NH_3D_SDC for SDC functionality, currently only used for covering common SDC and DMM parts.
  • new macro NH_3D_ENC_DEPTH for encoder optimizations related to depth.
  • temporary macro TEMP_SDC_CLEANUP for covering several proposed cleanups related to SDC and DMM.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-14.1-update-dev1-HHI/source/Lib/TLibCommon/TComRom.cpp

    r1200 r1209  
    253253    }
    254254  }
    255 #if H_3D_DIM_DMM
     255
     256#if NH_3D_DMM
    256257  if( !g_dmmWedgeLists.empty() )
    257258  {
    258     for( UInt ui = 0; ui < g_dmmWedgeLists.size(); ui++ )
    259     {
    260       g_dmmWedgeLists[ui].clear();
    261     }
     259    for( UInt ui = 0; ui < g_dmmWedgeLists.size(); ui++ ) { g_dmmWedgeLists[ui].clear(); }
    262260    g_dmmWedgeLists.clear();
    263261  }
    264   if( !g_dmmWedgeRefLists.empty() )
    265   {
    266     for( UInt ui = 0; ui < g_dmmWedgeRefLists.size(); ui++ )
    267     {
    268       g_dmmWedgeRefLists[ui].clear();
    269     }
    270     g_dmmWedgeRefLists.clear();
    271   }
    272262  if( !g_dmmWedgeNodeLists.empty() )
    273263  {
    274     for( UInt ui = 0; ui < g_dmmWedgeNodeLists.size(); ui++ )
    275     {
    276       g_dmmWedgeNodeLists[ui].clear();
    277     }
     264    for( UInt ui = 0; ui < g_dmmWedgeNodeLists.size(); ui++ ) { g_dmmWedgeNodeLists[ui].clear(); }
    278265    g_dmmWedgeNodeLists.clear();
    279266  }
     
    523510  //0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, DM
    524511  { 0, 1, 2, 2, 2, 2, 3, 5, 7, 8, 10, 12, 13, 15, 17, 18, 19, 20, 21, 22, 23, 23, 24, 24, 25, 25, 26, 27, 27, 28, 28, 29, 29, 30, 31, DM_CHROMA_IDX};
    525 #if H_3D_DIM_DMM
     512#if NH_3D_DMM
    526513// ====================================================================================================================
    527514// Depth coding modes
     
    539526{ //2x2   4x4   8x8 16x16 32x32 64x64
    540527     0,    7,   10,   9,    9,   13 };
    541 const UChar g_dmm3IntraTabIdxBits[6] =
    542 { //2x2   4x4   8x8 16x16 32x32 64x64
    543      0,    4,    7,    8,    8,    0 };
     528
    544529Bool g_wedgePattern[32*32];
    545530extern std::vector< std::vector<TComWedgelet> >   g_dmmWedgeLists;
    546 extern std::vector< std::vector<TComWedgeRef> >   g_dmmWedgeRefLists;
    547531extern std::vector< std::vector<TComWedgeNode> >  g_dmmWedgeNodeLists;
    548532#endif
     
    753737#endif
    754738#endif
    755 #if H_3D_DIM_DMM
     739#if NH_3D_DMM
    756740std::vector< std::vector<TComWedgelet>  > g_dmmWedgeLists;
    757 std::vector< std::vector<TComWedgeRef>  > g_dmmWedgeRefLists;
    758741std::vector< std::vector<TComWedgeNode> > g_dmmWedgeNodeLists;
     742
    759743Void initWedgeLists( Bool initNodeList )
    760744{
    761745  if( !g_dmmWedgeLists.empty() ) return;
    762   for( UInt ui = g_aucConvertToBit[DIM_MIN_SIZE]; ui < (g_aucConvertToBit[DIM_MAX_SIZE]); ui++ )
    763   {
    764     UInt uiWedgeBlockSize = ((UInt)DIM_MIN_SIZE)<<ui;
     746  for( UInt ui = g_aucConvertToBit[DMM_MIN_SIZE]; ui < (g_aucConvertToBit[DMM_MAX_SIZE]); ui++ )
     747  {
     748    UInt uiWedgeBlockSize = ((UInt)DMM_MIN_SIZE)<<ui;
    765749    std::vector<TComWedgelet> acWedgeList;
    766750    std::vector<TComWedgeRef> acWedgeRefList;
    767751    createWedgeList( uiWedgeBlockSize, uiWedgeBlockSize, acWedgeList, acWedgeRefList, g_dmmWedgeResolution[ui] );
    768752    g_dmmWedgeLists.push_back( acWedgeList );
    769     g_dmmWedgeRefLists.push_back( acWedgeRefList );
     753
    770754    if( initNodeList )
    771755    {
     
    827811  }
    828812}
     813
    829814Void createWedgeList( UInt uiWidth, UInt uiHeight, std::vector<TComWedgelet> &racWedgeList, std::vector<TComWedgeRef> &racWedgeRefList, WedgeResolution eWedgeRes )
    830815{
     
    867852  }
    868853}
     854
    869855Void addWedgeletToList( TComWedgelet cWedgelet, std::vector<TComWedgelet> &racWedgeList, std::vector<TComWedgeRef> &racWedgeRefList )
    870856{
     
    900886  if( bValid )
    901887  {
    902     cWedgelet.findClosestAngle();
    903888    racWedgeList.push_back( cWedgelet );
    904889    TComWedgeRef cWedgeRef;
     
    907892  }
    908893}
    909 #endif //H_3D_DIM_DMM
     894WedgeList* getWedgeListScaled( UInt blkSize )
     895{
     896  return &g_dmmWedgeLists[ g_aucConvertToBit[( 16 >= blkSize ) ? blkSize : 16] ];
     897}
     898WedgeNodeList* getWedgeNodeListScaled( UInt blkSize )
     899{
     900  return &g_dmmWedgeNodeLists[ g_aucConvertToBit[( 16 >= blkSize ) ? blkSize : 16] ];
     901}
     902#endif //NH_3D_DMM
    910903//! \}
Note: See TracChangeset for help on using the changeset viewer.