Changeset 100 in 3DVCSoftware for trunk/source/Lib/TLibEncoder/TEncSlice.cpp


Ignore:
Timestamp:
9 Aug 2012, 12:53:16 (12 years ago)
Author:
tech
Message:

Adopted modifications:

  • disparity vector generation (A0097)
  • inter-view motion prediction modification (A0049)
  • simplification of disparity vector derivation (A0126)
  • region boundary chain coding (A0070)
  • residual skip intra (A0087)
  • VSO modification (A0033/A0093)

+ Clean ups + Bug fixes

Update of cfg files (A0033 modification 2)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/Lib/TLibEncoder/TEncSlice.cpp

    r77 r100  
    3838#include "TEncTop.h"
    3939#include "TEncSlice.h"
     40#if HHI_VSO_SPEEDUP_A033
     41#include "../../App/TAppEncoder/TAppEncTop.h"
     42#endif
    4043#include <math.h>
     44#if SAIT_VSO_EST_A0033
     45extern Double g_dDispCoeff;
     46#endif
    4147
    4248//! \ingroup TLibEncoder
     
    627633  TComSlice* pcSlice            = rpcPic->getSlice(getSliceIdx());
    628634  xDetermineStartAndBoundingCUAddr ( uiStartCUAddr, uiBoundingCUAddr, rpcPic, false );
     635#if LG_ZEROINTRADEPTHRESI_M26039
     636  rpcPic->setIntraPeriod(this->m_pcCfg->getIntraPeriod());
     637#endif
    629638 
    630639  // initialize cost values
     
    702711  m_pcEntropyCoder->setMaxAlfCtrlDepth(0); //unnecessary
    703712 
     713#if SAIT_VSO_EST_A0033
     714 if( m_pcCfg->getUseVSO() )
     715 {
     716   m_pcRdCost->setDisparityCoeff( g_dDispCoeff );  // Temp. code!!!
     717   //printf( "Disp Coeff : %3.4f \n", m_pcRdCost->getDisparityCoeff() );
     718
     719   Int frameWidth = m_pcCfg->getSourceWidth();
     720   Pel* pVideoRec = m_pcRdCost->getVideoRecPicYuv()->getLumaAddr();
     721   Int iVideoRecStride = m_pcRdCost->getVideoRecPicYuv()->getStride();
     722
     723   Pel* pDepthOrg = m_pcRdCost->getDepthPicYuv()->getLumaAddr();
     724   Int iDepthOrgStride = m_pcRdCost->getDepthPicYuv()->getStride();
     725
     726   for( Int y = 0 ; y < m_pcCfg->getSourceHeight() ; y++ )
     727   {
     728     pVideoRec[-4] = pVideoRec[-3] = pVideoRec[-2] = pVideoRec[-1] = pVideoRec[0];
     729     pVideoRec[frameWidth+3] = pVideoRec[frameWidth+2] = pVideoRec[frameWidth+1] = pVideoRec[frameWidth] = pVideoRec[frameWidth-1];
     730     pDepthOrg[-4] = pDepthOrg[-3] = pDepthOrg[-2] = pDepthOrg[-1] = pDepthOrg[0];
     731     pDepthOrg[frameWidth+3] = pDepthOrg[frameWidth+2] = pDepthOrg[frameWidth+1] = pDepthOrg[frameWidth] = pDepthOrg[frameWidth-1];
     732
     733     pVideoRec += iVideoRecStride;
     734     pDepthOrg += iDepthOrgStride;
     735   }
     736 }
     737#endif
    704738  TEncTop* pcEncTop = (TEncTop*) m_pcCfg;
    705739  TEncSbac**** ppppcRDSbacCoders    = pcEncTop->getRDSbacCoders();
     
    753787  UInt uiTileLCUX     = 0;
    754788
     789#if HHI_VSO_SPEEDUP_A033
     790  Int iLastPosY = -1;
     791#endif
     792
    755793  // for every CU in slice
    756794  UInt uiEncCUOrder;
     
    763801    TComDataCU*& pcCU = rpcPic->getCU( uiCUAddr );
    764802    pcCU->initCU( rpcPic, uiCUAddr );
     803
     804#if HHI_VSO_SPEEDUP_A033
     805    if ( m_pcRdCost->getUseRenModel() )
     806    {
     807      // updated renderer model if necessary
     808      Int iCurPosX;
     809      Int iCurPosY;
     810      pcCU->getPosInPic(0, iCurPosX, iCurPosY );
     811      if ( iCurPosY != iLastPosY )
     812      {
     813        iLastPosY = iCurPosY;
     814       
     815        m_pcGOPEncoder->getEncTop()->getEncTop()->setupRenModel( rpcPic->getCurrSlice()->getPOC() , rpcPic->getCurrSlice()->getSPS()->getViewId(), rpcPic->getCurrSlice()->getSPS()->isDepth() ? 1 : 0, iCurPosY );
     816      }
     817    }   
     818#endif
     819
    765820
    766821    // inherit from TR if necessary, select substream to use.
Note: See TracChangeset for help on using the changeset viewer.