Ignore:
Timestamp:
11 Jul 2018, 15:19:49 (6 years ago)
Author:
tech
Message:

Merged HTM-16.2-dev@1412

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/Lib/TLibCommon/TComMotionInfo.cpp

    r1405 r1413  
    44 * granted under this license.
    55 *
    6  * Copyright (c) 2010-2016, ITU/ISO/IEC
     6 * Copyright (c) 2010-2017, ITU/ISO/IEC
    77 * All rights reserved.
    88 *
     
    4040#include "assert.h"
    4141#include <stdlib.h>
    42 #if NH_3D_SPIVMP
     42#if NH_3D
    4343#include "TComDataCU.h"
    4444#include "TComPic.h"
     
    330330}
    331331
    332 #if NH_3D_SPIVMP
     332#if NH_3D
    333333Void TComCUMvField::setMvFieldSP( TComDataCU* pcCU, UInt uiAbsPartIdx, TComMvField cMvField, Int iWidth, Int iHeight  )
    334334{
     
    358358 * \param scale      Factor by which to subsample motion information
    359359 */
     360#if REDUCED_ENCODER_MEMORY
     361Void TComCUMvField::compress(SChar *pePredMode, const SChar* pePredModeSource, const Int scale, const TComCUMvField &source)
     362{
     363  const Int numSubpartsWithIdenticalMotion = scale * scale;
     364  assert( numSubpartsWithIdenticalMotion > 0 && numSubpartsWithIdenticalMotion <= m_uiNumPartition);
     365  assert(source.m_uiNumPartition == m_uiNumPartition);
     366
     367  for ( Int partIdx = 0; partIdx < m_uiNumPartition; partIdx += numSubpartsWithIdenticalMotion )
     368  {
     369    TComMv cMv(0,0);
     370    Int iRefIdx = 0;
     371
     372    cMv = source.m_pcMv[ partIdx ];
     373    PredMode predMode = static_cast<PredMode>( pePredModeSource[ partIdx ] );
     374    iRefIdx = source.m_piRefIdx[ partIdx ];
     375    for ( Int i = 0; i < numSubpartsWithIdenticalMotion; i++ )
     376    {
     377      m_pcMv[ partIdx + i ] = cMv;
     378      pePredMode[ partIdx + i ] = predMode;
     379      m_piRefIdx[ partIdx + i ] = iRefIdx;
     380    }
     381  }
     382}
     383#else
     384
    360385Void TComCUMvField::compress(SChar* pePredMode, Int scale)
    361386{
     
    379404  }
    380405}
     406#endif
    381407
    382408#if NH_MV
     
    405431}
    406432
    407 #if NH_3D_MLC
     433#if NH_3D
    408434Void TComMotionCand::print( Int i )
    409435{
Note: See TracChangeset for help on using the changeset viewer.