[x265-commits] [x265] tcomdatacu: Removed Un-used NDBFBlockInfo - Non-deblockin...

Gopu Govindaswamy gopu at multicorewareinc.com
Tue Oct 8 06:07:31 CEST 2013


details:   http://hg.videolan.org/x265/rev/d71078917df0
branches:  
changeset: 4273:d71078917df0
user:      Gopu Govindaswamy <gopu at multicorewareinc.com>
date:      Mon Oct 07 12:48:32 2013 +0530
description:
tcomdatacu: Removed Un-used NDBFBlockInfo - Non-deblocking filter processing block information

1.setNDBFilterBlockBorderAvailability()
2.createNonDBFilterInfo()
3.createNonDBFilterInfoLCU()
4.destroyNonDBFilterInfo()

All the above methods are used to set and destroy the NDBFBlockInformation, but NDBFBlockInfo m_vNDFBlock is not getting
used encoding process

diffstat:

 source/Lib/TLibCommon/TComDataCU.cpp |  203 -----------------------------------
 source/Lib/TLibCommon/TComDataCU.h   |   27 ----
 source/Lib/TLibCommon/TComPic.cpp    |  187 --------------------------------
 source/Lib/TLibCommon/TComPic.h      |    3 -
 source/encoder/frameencoder.cpp      |    6 -
 5 files changed, 0 insertions(+), 426 deletions(-)

diffs (truncated from 500 to 300 lines):

diff -r 41e5e72e2a46 -r d71078917df0 source/Lib/TLibCommon/TComDataCU.cpp
--- a/source/Lib/TLibCommon/TComDataCU.cpp	Mon Oct 07 16:51:18 2013 -0500
+++ b/source/Lib/TLibCommon/TComDataCU.cpp	Mon Oct 07 12:48:32 2013 +0530
@@ -210,23 +210,6 @@ void TComDataCU::destroy()
     m_cuMvField[1].destroy();
 }
 
-const NDBFBlockInfo& NDBFBlockInfo::operator =(const NDBFBlockInfo& src)
-{
-    this->sliceID = src.sliceID;
-    this->startSU = src.startSU;
-    this->endSU  = src.endSU;
-    this->widthSU = src.widthSU;
-    this->heightSU = src.heightSU;
-    this->posX   = src.posX;
-    this->posY   = src.posY;
-    this->width  = src.width;
-    this->height = src.height;
-    ::memcpy(this->isBorderAvailable, src.isBorderAvailable, sizeof(bool) * ((int)NUM_SGU_BORDER));
-    this->allBordersAvailable = src.allBordersAvailable;
-
-    return *this;
-}
-
 // ====================================================================================================================
 // Public member functions
 // ====================================================================================================================
@@ -3181,190 +3164,4 @@ UInt TComDataCU::getSCUAddr()
     return (m_cuAddr) * (1 << (m_slice->getSPS()->getMaxCUDepth() << 1)) + m_absIdxInLCU;
 }
 
-/** Set neighboring blocks availabilities for non-deblocked filtering
- * \param numLCUInPicWidth number of LCUs in picture width
- * \param numLCUInPicHeight number of LCUs in picture height
- * \param numSUInLCUWidth number of SUs in LCU width
- * \param numSUInLCUHeight number of SUs in LCU height
- * \param picWidth picture width
- * \param picHeight picture height
- * \param bIndependentSliceBoundaryEnabled true for independent slice boundary enabled
- * \param bTopTileBoundary true means that top boundary coincides tile boundary
- * \param bDownTileBoundary true means that bottom boundary coincides tile boundary
- * \param bLeftTileBoundary true means that left boundary coincides tile boundary
- * \param bRightTileBoundary true means that right boundary coincides tile boundary
- * \param bIndependentTileBoundaryEnabled true for independent tile boundary enabled
- */
-void TComDataCU::setNDBFilterBlockBorderAvailability(UInt /*numLCUInPicWidth*/, UInt /*numLCUInPicHeight*/, UInt numSUInLCUWidth, UInt numSUInLCUHeight,
-                                                     UInt picWidth, UInt picHeight, bool bTopTileBoundary, bool bDownTileBoundary, bool bLeftTileBoundary,
-                                                     bool bRightTileBoundary, bool bIndependentTileBoundaryEnabled)
-{
-    UInt lpelx, tpely;
-    UInt width, height;
-    bool bPicRBoundary, bPicBBoundary, bPicTBoundary, bPicLBoundary;
-    bool bLCURBoundary = false, bLCUBBoundary = false, bLCUTBoundary = false, bLCULBoundary = false;
-    bool* bAvailBorder;
-    bool* bAvail;
-    UInt rTLSU, rBRSU, widthSU;
-    UInt numSGU = (UInt)m_vNDFBlock.size();
-
-    for (int i = 0; i < numSGU; i++)
-    {
-        NDBFBlockInfo& rSGU = m_vNDFBlock[i];
-
-        lpelx = rSGU.posX;
-        tpely = rSGU.posY;
-        width   = rSGU.width;
-        height  = rSGU.height;
-        rTLSU     = g_zscanToRaster[rSGU.startSU];
-        rBRSU     = g_zscanToRaster[rSGU.endSU];
-        widthSU   = rSGU.widthSU;
-
-        bAvailBorder = rSGU.isBorderAvailable;
-
-        bPicTBoundary = (tpely == 0) ? (true) : (false);
-        bPicLBoundary = (lpelx == 0) ? (true) : (false);
-        bPicRBoundary = (!(lpelx + width < picWidth)) ? (true) : (false);
-        bPicBBoundary = (!(tpely + height < picHeight)) ? (true) : (false);
-
-        bLCULBoundary = (rTLSU % numSUInLCUWidth == 0) ? (true) : (false);
-        bLCURBoundary = ((rTLSU + widthSU) % numSUInLCUWidth == 0) ? (true) : (false);
-        bLCUTBoundary = ((UInt)(rTLSU / numSUInLCUWidth) == 0) ? (true) : (false);
-        bLCUBBoundary = ((UInt)(rBRSU / numSUInLCUWidth) == (numSUInLCUHeight - 1)) ? (true) : (false);
-
-        //       SGU_L
-        bAvail = &(bAvailBorder[SGU_L]);
-        if (bPicLBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_R
-        bAvail = &(bAvailBorder[SGU_R]);
-        if (bPicRBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_T
-        bAvail = &(bAvailBorder[SGU_T]);
-        if (bPicTBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_B
-        bAvail = &(bAvailBorder[SGU_B]);
-        if (bPicBBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_TL
-        bAvail = &(bAvailBorder[SGU_TL]);
-        if (bPicTBoundary || bPicLBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_TR
-        bAvail = &(bAvailBorder[SGU_TR]);
-        if (bPicTBoundary || bPicRBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_BL
-        bAvail = &(bAvailBorder[SGU_BL]);
-        if (bPicBBoundary || bPicLBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        //       SGU_BR
-        bAvail = &(bAvailBorder[SGU_BR]);
-        if (bPicBBoundary || bPicRBoundary)
-        {
-            *bAvail = false;
-        }
-        else
-        {
-            *bAvail = true;
-        }
-
-        if (bIndependentTileBoundaryEnabled)
-        {
-            //left LCU boundary
-            if (!bPicLBoundary && bLCULBoundary)
-            {
-                if (bLeftTileBoundary)
-                {
-                    bAvailBorder[SGU_L] = bAvailBorder[SGU_TL] = bAvailBorder[SGU_BL] = false;
-                }
-            }
-            //right LCU boundary
-            if (!bPicRBoundary && bLCURBoundary)
-            {
-                if (bRightTileBoundary)
-                {
-                    bAvailBorder[SGU_R] = bAvailBorder[SGU_TR] = bAvailBorder[SGU_BR] = false;
-                }
-            }
-            //top LCU boundary
-            if (!bPicTBoundary && bLCUTBoundary)
-            {
-                if (bTopTileBoundary)
-                {
-                    bAvailBorder[SGU_T] = bAvailBorder[SGU_TL] = bAvailBorder[SGU_TR] = false;
-                }
-            }
-            //down LCU boundary
-            if (!bPicBBoundary && bLCUBBoundary)
-            {
-                if (bDownTileBoundary)
-                {
-                    bAvailBorder[SGU_B] = bAvailBorder[SGU_BL] = bAvailBorder[SGU_BR] = false;
-                }
-            }
-        }
-        rSGU.allBordersAvailable = true;
-        for (int b = 0; b < NUM_SGU_BORDER; b++)
-        {
-            if (bAvailBorder[b] == false)
-            {
-                rSGU.allBordersAvailable = false;
-                break;
-            }
-        }
-    }
-}
-
 //! \}
diff -r 41e5e72e2a46 -r d71078917df0 source/Lib/TLibCommon/TComDataCU.h
--- a/source/Lib/TLibCommon/TComDataCU.h	Mon Oct 07 16:51:18 2013 -0500
+++ b/source/Lib/TLibCommon/TComDataCU.h	Mon Oct 07 12:48:32 2013 +0530
@@ -76,26 +76,6 @@ enum NDBFBlockBorderTag
     NUM_SGU_BORDER
 };
 
-/// Non-deblocking filter processing block information
-struct NDBFBlockInfo
-{
-    int   sliceID; //!< slice ID
-    UInt  startSU; //!< starting SU z-scan address in LCU
-    UInt  endSU;  //!< ending SU z-scan address in LCU
-    UInt  widthSU; //!< number of SUs in width
-    UInt  heightSU; //!< number of SUs in height
-    UInt  posX;   //!< top-left X coordinate in picture
-    UInt  posY;   //!< top-left Y coordinate in picture
-    UInt  width;  //!< number of pixels in width
-    UInt  height; //!< number of pixels in height
-    bool  isBorderAvailable[NUM_SGU_BORDER]; //!< the border availabilities
-    bool  allBordersAvailable;
-
-    NDBFBlockInfo() : sliceID(0), startSU(0), endSU(0) {} //!< constructor
-
-    const NDBFBlockInfo& operator =(const NDBFBlockInfo& src); //!< "=" operator
-};
-
 // ====================================================================================================================
 // Class definition
 // ====================================================================================================================
@@ -148,8 +128,6 @@ private:
     Pel*          m_iPCMSampleCb;   ///< PCM sample buffer (Cb)
     Pel*          m_iPCMSampleCr;   ///< PCM sample buffer (Cr)
 
-    std::vector<NDBFBlockInfo> m_vNDFBlock;
-
     // -------------------------------------------------------------------------------------------------------------------
     // neighbor access variables
     // -------------------------------------------------------------------------------------------------------------------
@@ -416,11 +394,6 @@ public:
 
     void          setIPCMFlagSubParts(bool bIpcmFlag, UInt absPartIdx, UInt depth);
 
-    std::vector<NDBFBlockInfo>* getNDBFilterBlocks()      { return &m_vNDFBlock; }
-
-    void setNDBFilterBlockBorderAvailability(UInt numLCUInPicWidth, UInt numLCUInPicHeight, UInt numSUInLCUWidth, UInt numSUInLCUHeight, UInt picWidth, UInt picHeight
-                                             , bool bTopTileBoundary, bool bDownTileBoundary, bool bLeftTileBoundary, bool bRightTileBoundary
-                                             , bool bIndependentTileBoundaryEnabled);
     // -------------------------------------------------------------------------------------------------------------------
     // member functions for accessing partition information
     // -------------------------------------------------------------------------------------------------------------------
diff -r 41e5e72e2a46 -r d71078917df0 source/Lib/TLibCommon/TComPic.cpp
--- a/source/Lib/TLibCommon/TComPic.cpp	Mon Oct 07 16:51:18 2013 -0500
+++ b/source/Lib/TLibCommon/TComPic.cpp	Mon Oct 07 12:48:32 2013 +0530
@@ -111,191 +111,4 @@ void TComPic::destroy(int bframes)
     m_lowres.destroy(bframes);
 }
 
-/** Create non-deblocked filter information
- * \param pSliceStartAddress array for storing slice start addresses
- * \param numSlices number of slices in picture
- * \param sliceGranularityDepth slice granularity
- * \param bNDBFilterCrossSliceBoundary cross-slice-boundary in-loop filtering; true for "cross".
- * \param numTiles number of tiles in picture
- */
-void TComPic::createNonDBFilterInfo(int lastSlicecuAddr, int sliceGranularityDepth)
-{
-    UInt maxNumSUInLCU = getNumPartInCU();
-    UInt numLCUInPic   = getNumCUsInFrame();
-    UInt picWidth      = getSlice()->getSPS()->getPicWidthInLumaSamples();
-    UInt picHeight     = getSlice()->getSPS()->getPicHeightInLumaSamples();
-    int  numLCUsInPicWidth = getFrameWidthInCU();
-    int  numLCUsInPicHeight = getFrameHeightInCU();
-    UInt maxNumSUInLCUWidth = getNumPartInWidth();
-    UInt maxNumSUInLCUHeight = getNumPartInHeight();
-
-    for (UInt cuAddr = 0; cuAddr < numLCUInPic; cuAddr++)
-    {
-        TComDataCU* cu = getCU(cuAddr);
-        cu->getNDBFilterBlocks()->clear();
-    }
-


More information about the x265-commits mailing list