Ticket #1194: sao.patch

File sao.patch, 2.2 KB (added by gregory, 8 years ago)

Fix for CTB availability calculation

  • source/Lib/TLibCommon/TComPicSym.cpp

     
    377377      //above-right
    378378      if(ctuAboveRigtht != NULL)
    379379      {
    380         Int curSliceStartTS  = getCUOrderMap(ctuCurr->getSlice()->getSliceCurStartCUAddr()/m_uiNumPartitions);
    381         Int aboveRigthtSliceStartTS = getCUOrderMap(ctuAboveRigtht->getSlice()->getSliceCurStartCUAddr()/m_uiNumPartitions);
     380        Int curSliceStartEncOrder  = ctuCurr->getSlice()->getSliceCurStartCUAddr();
     381        Int aboveRigthtSliceStartEncOrder = ctuAboveRigtht->getSlice()->getSliceCurStartCUAddr();
    382382
    383         isAboveRightAvail = (curSliceStartTS == aboveRigthtSliceStartTS)?(true):
     383        isAboveRightAvail = (curSliceStartEncOrder == aboveRigthtSliceStartEncOrder)?(true):
    384384          (
    385           (curSliceStartTS > aboveRigthtSliceStartTS)?(ctuCurr->getSlice()->getLFCrossSliceBoundaryFlag())
     385          (curSliceStartEncOrder > aboveRigthtSliceStartEncOrder)?(ctuCurr->getSlice()->getLFCrossSliceBoundaryFlag())
    386386          :(ctuAboveRigtht->getSlice()->getLFCrossSliceBoundaryFlag())
    387387          );         
    388388      }
    389389      //below-left
    390390      if(ctuBelowLeft != NULL)
    391391      {
    392         Int curSliceStartTS       = getCUOrderMap(ctuCurr->getSlice()->getSliceCurStartCUAddr()/m_uiNumPartitions);
    393         Int belowLeftSliceStartTS = getCUOrderMap(ctuBelowLeft->getSlice()->getSliceCurStartCUAddr()/m_uiNumPartitions);
     392        Int curSliceStartEncOrder  = ctuCurr->getSlice()->getSliceCurStartCUAddr();
     393        Int belowLeftSliceStartEncOrder = ctuBelowLeft->getSlice()->getSliceCurStartCUAddr();
    394394
    395         isBelowLeftAvail = (curSliceStartTS == belowLeftSliceStartTS)?(true):
     395        isBelowLeftAvail = (curSliceStartEncOrder == belowLeftSliceStartEncOrder)?(true):
    396396          (
    397           (curSliceStartTS > belowLeftSliceStartTS)?(ctuCurr->getSlice()->getLFCrossSliceBoundaryFlag())
     397          (curSliceStartEncOrder > belowLeftSliceStartEncOrder)?(ctuCurr->getSlice()->getLFCrossSliceBoundaryFlag())
    398398          :(ctuBelowLeft->getSlice()->getLFCrossSliceBoundaryFlag())
    399399          );
    400400      }