Changeset 1010 in SHVCSoftware


Ignore:
Timestamp:
3 Feb 2015, 23:23:47 (10 years ago)
Author:
seregin
Message:

port the fix for the ticket #56 (rev 1009)

Location:
branches/SHM-upgrade/source
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-upgrade/source/App/TAppEncoder/TAppEncTop.cpp

    r1003 r1010  
    12911291#endif
    12921292    m_acTEncTop[layer].init(isFieldCoding);
    1293 #if P0182_VPS_VUI_PS_FLAG
    1294     m_acTEncTop[layer].getVPS()->setSPSId(layer, m_acTEncTop[layer].getSPS()->getSPSId());
    1295     m_acTEncTop[layer].getVPS()->setPPSId(layer, m_acTEncTop[layer].getPPS()->getPPSId());
    1296 #endif
    12971293  }
    12981294
  • branches/SHM-upgrade/source/Lib/TLibCommon/TComSlice.h

    r1006 r1010  
    903903
    904904#if P0182_VPS_VUI_PS_FLAG
    905   UInt       m_SPSId[MAX_LAYERS];
    906   UInt       m_PPSId[MAX_LAYERS];
    907905  UInt       m_baseLayerPSCompatibilityFlag[MAX_LAYERS];
    908906#endif
     
    13551353#endif
    13561354#if P0182_VPS_VUI_PS_FLAG
    1357   Int    getSPSId       (Int layer)                   { return m_SPSId[layer];       }
    1358   Void   setSPSId       (Int layer, Int val)          { m_SPSId[layer] = val;        }
    1359   Int    getPPSId       (Int layer)                   { return m_PPSId[layer];       }
    1360   Void   setPPSId       (Int layer, Int val)          { m_PPSId[layer] = val;        }
    13611355  Void   setBaseLayerPSCompatibilityFlag (Int layer, int val)        { m_baseLayerPSCompatibilityFlag[layer] = val; }
    13621356  Int    getBaseLayerPSCompatibilityFlag (Int layer)   { return m_baseLayerPSCompatibilityFlag[layer];}
  • branches/SHM-upgrade/source/Lib/TLibDecoder/TDecTop.cpp

    r1008 r1010  
    763763#endif
    764764    }
     765
     766#if P0182_VPS_VUI_PS_FLAG
     767    UInt layerIdx = activeVPS->getLayerIdInVps( m_layerId );
     768
     769    if( activeVPS->getBaseLayerPSCompatibilityFlag(layerIdx) )
     770    {
     771      RepFormat* repFormat = activeVPS->getVpsRepFormat(activeVPS->getVpsRepFormatIdx(layerIdx));
     772
     773      assert( pps->getLayerId() == 0 );
     774      assert( sps->getLayerId() == 0 );
     775      assert( repFormat->getChromaFormatVpsIdc() == sps->getChromaFormatIdc() );
     776      assert( repFormat->getSeparateColourPlaneVpsFlag() == 0 );
     777      assert( repFormat->getPicHeightVpsInLumaSamples() == sps->getPicHeightInLumaSamples() );
     778      assert( repFormat->getPicWidthVpsInLumaSamples()  == sps->getPicWidthInLumaSamples() );
     779      assert( repFormat->getBitDepthVpsLuma()   == sps->getBitDepth(CHANNEL_TYPE_LUMA) );
     780      assert( repFormat->getBitDepthVpsChroma() == sps->getBitDepth(CHANNEL_TYPE_CHROMA) );
     781      assert( repFormat->getConformanceWindowVps().getWindowLeftOffset()   == sps->getConformanceWindow().getWindowLeftOffset() );
     782      assert( repFormat->getConformanceWindowVps().getWindowRightOffset()  == sps->getConformanceWindow().getWindowRightOffset() );
     783      assert( repFormat->getConformanceWindowVps().getWindowTopOffset()    == sps->getConformanceWindow().getWindowTopOffset() );
     784      assert( repFormat->getConformanceWindowVps().getWindowBottomOffset() == sps->getConformanceWindow().getWindowBottomOffset() );
     785    }   
     786#endif
    765787  }
    766788#endif
  • branches/SHM-upgrade/source/Lib/TLibEncoder/TEncCavlc.cpp

    r981 r1010  
    31093109      if( vps->getNumRefLayers(vps->getLayerIdInNuh(i)) == 0 )
    31103110      {
    3111         if( (vps->getSPSId(i) == 0) && (vps->getPPSId(i) == 0) )
    3112         {
    3113           vps->setBaseLayerPSCompatibilityFlag(i, 1);
    3114         }
    3115         else
    3116         {
    3117           vps->setBaseLayerPSCompatibilityFlag(i, 0);
    3118         }
    31193111        WRITE_FLAG(vps->getBaseLayerPSCompatibilityFlag(i), "base_layer_parameter_set_compatibility_flag" );
    31203112      }
  • branches/SHM-upgrade/source/Lib/TLibEncoder/TEncTop.cpp

    r1000 r1010  
    16391639      }
    16401640    }
     1641
     1642#if P0182_VPS_VUI_PS_FLAG
     1643    if( m_cVPS.getNumRefLayers( m_layerId ) == 0 )
     1644    {
     1645      UInt layerIdx = m_cVPS.getLayerIdInVps( m_layerId );
     1646      RepFormat* repFormat = m_cVPS.getVpsRepFormat(m_cVPS.getVpsRepFormatIdx(layerIdx));
     1647     
     1648      if( m_cPPS.getLayerId() == 0 &&
     1649          m_cSPS.getLayerId() == 0 &&
     1650          repFormat->getChromaFormatVpsIdc() == m_cSPS.getChromaFormatIdc() &&
     1651          repFormat->getSeparateColourPlaneVpsFlag() == 0 &&
     1652          repFormat->getPicHeightVpsInLumaSamples() == m_cSPS.getPicHeightInLumaSamples() &&
     1653          repFormat->getPicWidthVpsInLumaSamples()  == m_cSPS.getPicWidthInLumaSamples() &&
     1654          repFormat->getBitDepthVpsLuma()   == m_cSPS.getBitDepth(CHANNEL_TYPE_LUMA) &&
     1655          repFormat->getBitDepthVpsChroma() == m_cSPS.getBitDepth(CHANNEL_TYPE_CHROMA) &&
     1656          repFormat->getConformanceWindowVps().getWindowLeftOffset()   == m_cSPS.getConformanceWindow().getWindowLeftOffset() &&
     1657          repFormat->getConformanceWindowVps().getWindowRightOffset()  == m_cSPS.getConformanceWindow().getWindowRightOffset() &&
     1658          repFormat->getConformanceWindowVps().getWindowTopOffset()    == m_cSPS.getConformanceWindow().getWindowTopOffset() &&
     1659          repFormat->getConformanceWindowVps().getWindowBottomOffset() == m_cSPS.getConformanceWindow().getWindowBottomOffset() )
     1660      {
     1661        m_cVPS.setBaseLayerPSCompatibilityFlag(layerIdx, 1);
     1662      }
     1663      else
     1664      {
     1665        m_cVPS.setBaseLayerPSCompatibilityFlag(layerIdx, 0);
     1666      }
     1667    }
     1668#endif
    16411669  }
    16421670}
Note: See TracChangeset for help on using the changeset viewer.