Changeset 659 in SHVCSoftware for branches/SHM-6-dev
- Timestamp:
- 9 Apr 2014, 21:42:54 (11 years ago)
- Location:
- branches/SHM-6-dev/source/Lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-6-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
r652 r659 1623 1623 #endif 1624 1624 #if REPN_FORMAT_IN_VPS 1625 Void TDecCavlc::parseRepFormat 1625 Void TDecCavlc::parseRepFormat( RepFormat *repFormat ) 1626 1626 { 1627 1627 UInt uiCode; 1628 #if REPN_FORMAT_CONTROL_FLAG 1629 READ_ FLAG ( uiCode, "chroma_and_bit_depth_vps_present_flag"); repFormat->setChromaAndBitDepthVpsPresentFlag(uiCode ? true : false);1630 READ_CODE ( 16, uiCode, "pic_width_in_luma_samples" ); repFormat->setPicWidthVpsInLumaSamples( uiCode );1631 READ_ CODE ( 16, uiCode, "pic_height_in_luma_samples" ); repFormat->setPicHeightVpsInLumaSamples( uiCode );1628 #if REPN_FORMAT_CONTROL_FLAG 1629 READ_CODE( 16, uiCode, "pic_width_vps_in_luma_samples" ); repFormat->setPicWidthVpsInLumaSamples ( uiCode ); 1630 READ_CODE( 16, uiCode, "pic_height_vps_in_luma_samples" ); repFormat->setPicHeightVpsInLumaSamples( uiCode ); 1631 READ_FLAG( uiCode, "chroma_and_bit_depth_vps_present_flag" ); repFormat->setChromaAndBitDepthVpsPresentFlag( uiCode ? true : false ); 1632 1632 1633 1633 if( repFormat->getChromaAndBitDepthVpsPresentFlag() ) 1634 1634 { 1635 READ_CODE( 2, uiCode, "chroma_format_vps_idc" ); 1635 1636 #if AUXILIARY_PICTURES 1636 READ_CODE( 2, uiCode, "chroma_format_idc" );repFormat->setChromaFormatVpsIdc( ChromaFormat(uiCode) );1637 #else 1638 READ_CODE( 2, uiCode, "chroma_format_idc" );repFormat->setChromaFormatVpsIdc( uiCode );1637 repFormat->setChromaFormatVpsIdc( ChromaFormat(uiCode) ); 1638 #else 1639 repFormat->setChromaFormatVpsIdc( uiCode ); 1639 1640 #endif 1640 1641 1641 1642 if( repFormat->getChromaFormatVpsIdc() == 3 ) 1642 1643 { 1643 READ_FLAG( uiCode, "separate_colour_plane_flag"); repFormat->setSeparateColourPlaneVpsFlag(uiCode ? true : false); 1644 } 1645 1646 1647 READ_CODE( 4, uiCode, "bit_depth_luma_minus8" ); repFormat->setBitDepthVpsLuma ( uiCode + 8 ); 1648 READ_CODE( 4, uiCode, "bit_depth_chroma_minus8" ); repFormat->setBitDepthVpsChroma( uiCode + 8 ); 1644 READ_FLAG( uiCode, "separate_colour_plane_vps_flag" ); repFormat->setSeparateColourPlaneVpsFlag( uiCode ? true : false ); 1645 } 1646 1647 READ_CODE( 4, uiCode, "bit_depth_vps_luma_minus8" ); repFormat->setBitDepthVpsLuma ( uiCode + 8 ); 1648 READ_CODE( 4, uiCode, "bit_depth_vps_chroma_minus8" ); repFormat->setBitDepthVpsChroma( uiCode + 8 ); 1649 1649 } 1650 1650 #else -
branches/SHM-6-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
r653 r659 1238 1238 #endif 1239 1239 #if REPN_FORMAT_IN_VPS 1240 Void TEncCavlc::codeRepFormat 1240 Void TEncCavlc::codeRepFormat( RepFormat *repFormat ) 1241 1241 { 1242 1242 #if REPN_FORMAT_CONTROL_FLAG 1243 WRITE_FLAG ( repFormat->getChromaAndBitDepthVpsPresentFlag(), "chroma_and_bit_depth_vps_presenet_flag"); 1244 1245 WRITE_CODE ( repFormat->getPicWidthVpsInLumaSamples (), 16, "pic_width_in_luma_samples" ); 1246 WRITE_CODE ( repFormat->getPicHeightVpsInLumaSamples(), 16, "pic_height_in_luma_samples" ); 1247 1248 if ( repFormat->getChromaAndBitDepthVpsPresentFlag() ) 1249 { 1250 WRITE_CODE( repFormat->getChromaFormatVpsIdc(), 2, "chroma_format_idc" ); 1251 1252 if( repFormat->getChromaFormatVpsIdc() == 3 ) 1253 { 1254 WRITE_FLAG( repFormat->getSeparateColourPlaneVpsFlag(), "separate_colour_plane_flag"); 1255 } 1256 1257 assert( repFormat->getBitDepthVpsLuma() >= 8 ); 1258 assert( repFormat->getBitDepthVpsChroma() >= 8 ); 1259 WRITE_CODE( repFormat->getBitDepthVpsLuma() - 8, 4, "bit_depth_luma_minus8" ); 1260 WRITE_CODE( repFormat->getBitDepthVpsChroma() - 8, 4, "bit_depth_chroma_minus8" ); 1261 } 1243 WRITE_CODE( repFormat->getPicWidthVpsInLumaSamples (), 16, "pic_width_vps_in_luma_samples" ); 1244 WRITE_CODE( repFormat->getPicHeightVpsInLumaSamples(), 16, "pic_height_vps_in_luma_samples" ); 1245 WRITE_FLAG( repFormat->getChromaAndBitDepthVpsPresentFlag(), "chroma_and_bit_depth_vps_present_flag" ); 1246 1247 if( repFormat->getChromaAndBitDepthVpsPresentFlag() ) 1248 { 1249 WRITE_CODE( repFormat->getChromaFormatVpsIdc(), 2, "chroma_format_vps_idc" ); 1250 1251 if( repFormat->getChromaFormatVpsIdc() == 3 ) 1252 { 1253 WRITE_FLAG( repFormat->getSeparateColourPlaneVpsFlag(), "separate_colour_plane_vps_flag" ); 1254 } 1255 1256 assert( repFormat->getBitDepthVpsLuma() >= 8 ); 1257 assert( repFormat->getBitDepthVpsChroma() >= 8 ); 1258 WRITE_CODE( repFormat->getBitDepthVpsLuma() - 8, 4, "bit_depth_vps_luma_minus8" ); 1259 WRITE_CODE( repFormat->getBitDepthVpsChroma() - 8, 4, "bit_depth_vps_chroma_minus8" ); 1260 } 1262 1261 #else 1263 1262 WRITE_CODE( repFormat->getChromaFormatVpsIdc(), 2, "chroma_format_idc" ); … … 1275 1274 WRITE_CODE( repFormat->getBitDepthVpsLuma() - 8, 4, "bit_depth_luma_minus8" ); 1276 1275 WRITE_CODE( repFormat->getBitDepthVpsChroma() - 8, 4, "bit_depth_chroma_minus8" ); 1277 #endif 1278 1276 #endif 1279 1277 } 1280 1278 #endif
Note: See TracChangeset for help on using the changeset viewer.