Changeset 769 in 3DVCSoftware for branches/HTM-9.2-dev0/source/Lib/TLibDecoder
- Timestamp:
- 13 Jan 2014, 08:05:57 (11 years ago)
- Location:
- branches/HTM-9.2-dev0/source/Lib/TLibDecoder
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-9.2-dev0/source/Lib/TLibDecoder/TDecCAVLC.cpp
r768 r769 937 937 938 938 READ_FLAG( uiCode, "sps_extension_flag"); 939 #if H_MV 939 940 pcSPS->setSpsExtensionFlag( uiCode ); 940 941 if (pcSPS->getSpsExtensionFlag( ) ) 941 { 942 #else 943 if (uiCode) 944 #endif 945 { 946 #if H_MV 942 947 for (Int i = 0; i < PS_EX_T_MAX_NUM; i++) 943 948 { … … 964 969 if ( pcSPS->getSpsExtensionTypeFlag( PS_EX_T_ESC )) 965 970 { 971 #endif 966 972 while ( xMoreRbspData() ) 967 973 { 968 974 READ_FLAG( uiCode, "sps_extension_data_flag"); 969 975 } 970 } 976 #if H_MV 977 } 978 #endif 971 979 } 972 980 } … … 1073 1081 } 1074 1082 } 1083 #if H_MV 1075 1084 pcVPS->deriveLayerSetLayerIdList(); 1085 #endif 1076 1086 TimingInfo *timingInfo = pcVPS->getTimingInfo(); 1077 1087 READ_FLAG( uiCode, "vps_timing_info_present_flag"); timingInfo->setTimingInfoPresentFlag (uiCode ? true : false); … … 1890 1900 1891 1901 1902 #if H_MV 1892 1903 UInt slicePicOrderCntLsb = 0; 1893 1904 Int iPOClsb = slicePicOrderCntLsb; // Needed later … … 1936 1947 rpcSlice->setPOC ( 0 ); 1937 1948 } 1949 #endif 1938 1950 1939 1951 if( rpcSlice->getIdrPicFlag() ) 1940 1952 { 1953 #if !H_MV 1954 rpcSlice->setPOC(0); 1955 #endif 1941 1956 TComReferencePictureSet* rps = rpcSlice->getLocalRPS(); 1942 1957 rps->setNumberOfNegativePictures(0); … … 1951 1966 else 1952 1967 { 1968 #if !H_MV 1969 READ_CODE(sps->getBitsForPOC(), uiCode, "pic_order_cnt_lsb"); 1970 Int iPOClsb = uiCode; 1971 Int iPrevPOC = rpcSlice->getPrevTid0POC(); 1972 Int iMaxPOClsb = 1<< sps->getBitsForPOC(); 1973 Int iPrevPOClsb = iPrevPOC & (iMaxPOClsb - 1); 1974 Int iPrevPOCmsb = iPrevPOC-iPrevPOClsb; 1975 Int iPOCmsb; 1976 if( ( iPOClsb < iPrevPOClsb ) && ( ( iPrevPOClsb - iPOClsb ) >= ( iMaxPOClsb / 2 ) ) ) 1977 { 1978 iPOCmsb = iPrevPOCmsb + iMaxPOClsb; 1979 } 1980 else if( (iPOClsb > iPrevPOClsb ) && ( (iPOClsb - iPrevPOClsb ) > ( iMaxPOClsb / 2 ) ) ) 1981 { 1982 iPOCmsb = iPrevPOCmsb - iMaxPOClsb; 1983 } 1984 else 1985 { 1986 iPOCmsb = iPrevPOCmsb; 1987 } 1988 if ( rpcSlice->getNalUnitType() == NAL_UNIT_CODED_SLICE_BLA_W_LP 1989 || rpcSlice->getNalUnitType() == NAL_UNIT_CODED_SLICE_BLA_W_RADL 1990 || rpcSlice->getNalUnitType() == NAL_UNIT_CODED_SLICE_BLA_N_LP ) 1991 { 1992 // For BLA picture types, POCmsb is set to 0. 1993 iPOCmsb = 0; 1994 } 1995 rpcSlice->setPOC (iPOCmsb+iPOClsb); 1996 #endif 1953 1997 TComReferencePictureSet* rps; 1954 1998 rps = rpcSlice->getLocalRPS(); -
branches/HTM-9.2-dev0/source/Lib/TLibDecoder/TDecTop.cpp
r767 r769 725 725 #endif 726 726 727 #if H_MV 727 728 xCeckNoClrasOutput(); 729 #endif 728 730 // Skip pictures due to random access 729 731 if (isRandomAccessSkipPicture(iSkipFrame, iPOCLastDisplay)) … … 731 733 m_prevSliceSkipped = true; 732 734 m_skippedPOC = m_apcSlicePilot->getPOC(); 733 sliceSkippedFlag = true; 735 #if H_MV 736 sliceSkippedFlag = true; 737 #endif 734 738 return false; 735 739 } … … 739 743 m_prevSliceSkipped = true; 740 744 m_skippedPOC = m_apcSlicePilot->getPOC(); 741 sliceSkippedFlag = true; 745 #if H_MV 746 sliceSkippedFlag = true; 747 #endif 742 748 return false; 743 749 } … … 1273 1279 return true; 1274 1280 } 1281 #if H_MV 1275 1282 else if ( !m_layerInitilizedFlag[ m_layerId ] ) // start of random access point, m_pocRandomAccess has not been set yet. 1283 #else 1284 else if (m_pocRandomAccess == MAX_INT) // start of random access point, m_pocRandomAccess has not been set yet. 1285 #endif 1276 1286 { 1277 1287 if ( m_apcSlicePilot->getNalUnitType() == NAL_UNIT_CODED_SLICE_CRA … … 1281 1291 { 1282 1292 1293 #if H_MV 1283 1294 if ( xAllRefLayersInitilized() ) 1284 1295 { … … 1290 1301 return true; 1291 1302 } 1303 #else 1304 // set the POC random access since we need to skip the reordered pictures in the case of CRA/CRANT/BLA/BLANT. 1305 m_pocRandomAccess = m_apcSlicePilot->getPOC(); 1306 #endif 1292 1307 } 1293 1308 else if ( m_apcSlicePilot->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_W_RADL || m_apcSlicePilot->getNalUnitType() == NAL_UNIT_CODED_SLICE_IDR_N_LP ) 1294 1309 { 1310 #if H_MV 1295 1311 if ( xAllRefLayersInitilized() ) 1296 1312 { 1297 1313 m_layerInitilizedFlag[ m_layerId ] = true; 1314 m_pocRandomAccess = -MAX_INT; // no need to skip the reordered pictures in IDR, they are decodable. 1315 } 1316 else 1317 { 1318 return true; 1319 } 1320 #else 1298 1321 m_pocRandomAccess = -MAX_INT; // no need to skip the reordered pictures in IDR, they are decodable. 1322 #endif 1299 1323 } 1300 1324 else 1301 1325 { 1302 return true; 1303 } 1304 } 1305 else 1306 { 1326 #if H_MV_FIX_SKIP_PICTURES 1307 1327 static Bool warningMessage[MAX_NUM_LAYERS]; 1308 1328 static Bool warningInitFlag = false; … … 1322 1342 warningMessage[m_layerId] = false; 1323 1343 } 1344 #else 1345 static Bool warningMessage = false; 1346 if(!warningMessage) 1347 { 1348 printf("\nWarning: this is not a valid random access point and the data is discarded until the first CRA picture"); 1349 warningMessage = true; 1350 } 1351 #endif 1324 1352 return true; 1325 1353 } … … 1331 1359 return true; 1332 1360 } 1361 #if H_MV 1333 1362 return !m_layerInitilizedFlag[ getLayerId() ]; 1363 #else 1364 // if we reach here, then the picture is not skipped. 1365 return false; 1366 #endif 1334 1367 } 1335 1368 … … 1373 1406 } 1374 1407 1408 #if H_MV 1375 1409 Void TDecTop::xCeckNoClrasOutput() 1376 1410 { … … 1407 1441 } 1408 1442 #endif 1443 #endif 1409 1444 //! \}
Note: See TracChangeset for help on using the changeset viewer.