- Timestamp:
- 12 Nov 2013, 16:01:31 (11 years ago)
- Location:
- branches/SHM-4.0-dev/source
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-4.0-dev/source/App/TAppEncoder/TAppEncTop.cpp
r458 r461 1133 1133 vps->setSingleLayerForNonIrapFlag(m_adaptiveResolutionChange > 0 ? true : false); 1134 1134 #endif 1135 #if !VPS_EXTN_OFFSET_CALC 1135 1136 #if VPS_EXTN_OFFSET 1136 1137 // to be updated according to the current semantics 1137 1138 vps->setExtensionOffset( 0xffff ); 1139 #endif 1138 1140 #endif 1139 1141 #else //SVC_EXTENSION -
branches/SHM-4.0-dev/source/Lib/TLibCommon/TypeDef.h
r459 r461 92 92 93 93 #define VPS_EXTN_OFFSET 1 ///< implementation of vps_extension_offset syntax element 94 #define VPS_EXTN_OFFSET_CALC 1 ///< Calculation of VPS extension offset 94 95 #define SPS_PTL_FIX 1 ///< remove profile_tier_level from enhancement layer SPS 95 96 -
branches/SHM-4.0-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
r458 r461 700 700 Void TEncCavlc::codeVPS( TComVPS* pcVPS ) 701 701 { 702 #if VPS_EXTN_OFFSET_CALC 703 UInt numBytesInVps = this->m_pcBitIf->getNumberOfWrittenBits(); 704 #endif 702 705 WRITE_CODE( pcVPS->getVPSId(), 4, "vps_video_parameter_set_id" ); 703 706 WRITE_CODE( 3, 2, "vps_reserved_three_2bits" ); … … 803 806 WRITE_FLAG(1, "vps_extension_alignment_bit_equal_to_one"); 804 807 } 808 #if VPS_EXTN_OFFSET_CALC 809 Int vpsExntOffsetValueInBits = this->m_pcBitIf->getNumberOfWrittenBits() - numBytesInVps + 16; // 2 bytes for NUH 810 assert( vpsExntOffsetValueInBits % 8 == 0 ); 811 pcVPS->setExtensionOffset( vpsExntOffsetValueInBits >> 3 ); 812 #endif 805 813 codeVPSExtension(pcVPS); 806 814 WRITE_FLAG( 0, "vps_extension2_flag" ); // Flag value of 1 reserved -
branches/SHM-4.0-dev/source/Lib/TLibEncoder/TEncGOP.cpp
r460 r461 1683 1683 OutputNALUnit nalu(NAL_UNIT_VPS); 1684 1684 #endif 1685 #if VPS_EXTN_OFFSET_CALC 1686 OutputNALUnit tempNalu(NAL_UNIT_VPS, 0, 0 ); // The value of nuh_layer_id of VPS NAL unit shall be equal to 0. 1687 m_pcEntropyCoder->setBitstream(&tempNalu.m_Bitstream); 1688 m_pcEntropyCoder->encodeVPS(m_pcEncTop->getVPS()); // Use to calculate the VPS extension offset 1689 #endif 1685 1690 m_pcEntropyCoder->setBitstream(&nalu.m_Bitstream); 1686 1691 m_pcEntropyCoder->encodeVPS(m_pcEncTop->getVPS());
Note: See TracChangeset for help on using the changeset viewer.