Changeset 1475 in SHVCSoftware
- Timestamp:
- 22 Sep 2015, 20:18:26 (9 years ago)
- Location:
- branches/SHM-dev/source
- Files:
-
- 19 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-dev/source/App/TAppDecoder/TAppDecCfg.cpp
r1472 r1475 128 128 ("TarDecLayerIdSetFile,l", cfg_TargetDecLayerIdSetFile, string(""), "targetDecLayerIdSet file name. The file should include white space separated LayerId values to be decoded. Omitting the option or a value of -1 in the file decodes all layers.") 129 129 ("RespectDefDispWindow,w", m_respectDefDispWindow, 0, "Only output content inside the default display window\n") 130 #if Q0074_COLOUR_REMAPPING_SEI131 130 ("SEIColourRemappingInfoFilename", m_colourRemapSEIFileName, string(""), "Colour Remapping YUV output file name. If empty, no remapping is applied (ignore SEI message)\n") 132 #endif133 131 #if O0043_BEST_EFFORT_DECODING 134 132 ("ForceDecodeBitDepth", m_forceDecodeBitDepth, 0U, "Force the decoder to operate at a particular bit-depth (best effort decoding)") -
branches/SHM-dev/source/App/TAppDecoder/TAppDecCfg.h
r1472 r1475 74 74 Int m_decodedPictureHashSEIEnabled; ///< Checksum(3)/CRC(2)/MD5(1)/disable(0) acting on decoded picture hash SEI message 75 75 Bool m_decodedNoDisplaySEIEnabled; ///< Enable(true)/disable(false) writing only pictures that get displayed based on the no display SEI message 76 #if Q0074_COLOUR_REMAPPING_SEI77 76 std::string m_colourRemapSEIFileName; ///< output Colour Remapping file name 78 #endif79 77 std::vector<Int> m_targetDecLayerIdSet; ///< set of LayerIds to be included in the sub-bitstream extraction process. 80 78 Int m_respectDefDispWindow; ///< Only output content inside the default display window … … 112 110 , m_decodedPictureHashSEIEnabled(0) 113 111 , m_decodedNoDisplaySEIEnabled(false) 114 #if Q0074_COLOUR_REMAPPING_SEI115 112 , m_colourRemapSEIFileName() 116 #endif117 113 , m_targetDecLayerIdSet() 118 114 , m_respectDefDispWindow(0) -
branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.cpp
r1472 r1475 62 62 #if SVC_EXTENSION 63 63 TAppDecTop::TAppDecTop() 64 #if Q0074_COLOUR_REMAPPING_SEI65 64 : m_pcSeiColourRemappingInfoPrevious(NULL) 66 #endif67 65 { 68 66 memset( m_apcTDecTop, 0, sizeof(m_apcTDecTop) ); … … 77 75 TAppDecTop::TAppDecTop() 78 76 : m_iPOCLastDisplay(-MAX_INT) 79 #if Q0074_COLOUR_REMAPPING_SEI80 77 ,m_pcSeiColourRemappingInfoPrevious(NULL) 81 #endif82 78 { 83 79 } … … 163 159 #endif 164 160 165 #if Q0074_COLOUR_REMAPPING_SEI166 161 // clear contents of colour-remap-information-SEI output file 167 162 if (!m_colourRemapSEIFileName.empty()) … … 174 169 } 175 170 } 176 #endif177 171 178 172 // main decoder loop … … 629 623 m_cTDecTop.destroy(); 630 624 #endif 631 #if Q0074_COLOUR_REMAPPING_SEI632 625 if (m_pcSeiColourRemappingInfoPrevious != NULL) 633 626 { … … 635 628 m_pcSeiColourRemappingInfoPrevious = NULL; 636 629 } 637 #endif638 630 } 639 631 … … 656 648 m_cTDecTop.setForceDecodeBitDepth(m_forceDecodeBitDepth); 657 649 #endif 658 659 650 if (!m_outputDecodedSEIMessagesFilename.empty()) 660 651 { … … 674 665 #endif 675 666 676 #if Q0074_COLOUR_REMAPPING_SEI677 667 if (m_pcSeiColourRemappingInfoPrevious != NULL) 678 668 { … … 680 670 m_pcSeiColourRemappingInfoPrevious = NULL; 681 671 } 682 #endif683 672 } 684 673 … … 911 900 } 912 901 913 #if Q0074_COLOUR_REMAPPING_SEI914 902 if (!m_colourRemapSEIFileName.empty()) 915 903 { 916 904 xOutputColourRemapPic(pcPic); 917 905 } 918 #endif919 906 920 907 // update POC of display order … … 1083 1070 } 1084 1071 1085 #if Q0074_COLOUR_REMAPPING_SEI1086 1072 if (!m_colourRemapSEIFileName.empty()) 1087 1073 { 1088 1074 xOutputColourRemapPic(pcPic); 1089 1075 } 1090 #endif1091 1076 1092 1077 // update POC of display order … … 1146 1131 return false; 1147 1132 } 1148 1149 #if Q0074_COLOUR_REMAPPING_SEI1150 1133 1151 1134 Void TAppDecTop::xOutputColourRemapPic(TComPic* pcPic) … … 1468 1451 } 1469 1452 } 1470 #endif1471 1453 1472 1454 #if ALIGNED_BUMPING … … 1491 1473 conf.getWindowBottomOffset()* yScal + defDisp.getWindowBottomOffset() ); 1492 1474 1493 #if Q0074_COLOUR_REMAPPING_SEI1494 1475 if( !m_colourRemapSEIFileName.empty() ) 1495 1476 { 1496 1477 xOutputColourRemapPic(pic); 1497 1478 } 1498 #endif1499 1479 } 1500 1480 // update POC of display order -
branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.h
r1470 r1475 81 81 std::ofstream m_seiMessageFileStream; ///< Used for outputing SEI messages. 82 82 83 #if Q0074_COLOUR_REMAPPING_SEI84 83 SEIColourRemappingInfo* m_pcSeiColourRemappingInfoPrevious; 85 #endif86 84 87 85 public: … … 125 123 Bool isNaluWithinTargetDecLayerIdSet ( InputNALUnit* nalu ); ///< check whether given Nalu is within targetDecLayerIdSet 126 124 127 #if Q0074_COLOUR_REMAPPING_SEI128 125 private: 129 126 Void applyColourRemapping(const TComPicYuv& pic, SEIColourRemappingInfo& pCriSEI, const TComSPS &activeSPS); 130 127 Void xOutputColourRemapPic(TComPic* pcPic); 131 #endif 128 132 129 #if ALIGNED_BUMPING 133 130 Void checkOutputBeforeDecoding(Int layerIdx); -
branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp
r1463 r1475 773 773 774 774 Int* cfg_maxTidIlRefPicsPlus1[MAX_LAYERS]; 775 #if Q0074_COLOUR_REMAPPING_SEI776 775 string* cfg_colourRemapSEIFileRoot[MAX_LAYERS]; 777 #endif778 776 Bool* cfg_entropyCodingSyncEnabledFlag[MAX_LAYERS]; 779 777 Int* cfg_layerSwitchOffBegin[MAX_LAYERS]; … … 792 790 cfg_dQPFileName[layer] = &m_apcLayerCfg[layer]->m_dQPFileName; 793 791 cfg_fQP[layer] = &m_apcLayerCfg[layer]->m_fQP; 794 #if Q0074_COLOUR_REMAPPING_SEI795 792 cfg_colourRemapSEIFileRoot[layer] = &m_apcLayerCfg[layer]->m_colourRemapSEIFileRoot; 796 #endif797 793 cfg_repFormatIdx[layer] = &m_apcLayerCfg[layer]->m_repFormatIdx; 798 794 cfg_layerId[layer] = &m_apcLayerCfg[layer]->m_layerId; … … 1072 1068 ("PhaseHorChroma%d", cfg_phaseHorChromaPtr, string(""), m_numLayers, "chroma shift in the horizontal direction used in resampling proces") 1073 1069 ("PhaseVerChroma%d", cfg_phaseVerChromaPtr, string(""), m_numLayers, "chroma shift in the vertical direction used in resampling proces") 1074 #if Q0074_COLOUR_REMAPPING_SEI1075 1070 ("SEIColourRemappingInfoFileRoot%d,-cri", cfg_colourRemapSEIFileRoot, string(""), m_numLayers, "Colour Remapping Information SEI parameters root file name (wo num ext)") 1076 #endif1077 1071 ("InputBitDepth%d", cfg_InputBitDepth[CHANNEL_TYPE_LUMA], 8, m_numLayers, "Bit-depth of input file for layer %d") 1078 1072 ("InternalBitDepth%d", cfg_InternalBitDepth[CHANNEL_TYPE_LUMA], 0, m_numLayers, "Bit-depth the codec operates at. (default:InputBitDepth) for layer %d " … … 1460 1454 ("Log2MaxMvLengthVertical", m_log2MaxMvLengthVertical, 15, "Indicate the maximum absolute value of a decoded vertical MV component in quarter-pel luma units") 1461 1455 #if !SVC_EXTENSION 1462 #if Q0074_COLOUR_REMAPPING_SEI1463 1456 ("SEIColourRemappingInfoFileRoot,-cri", m_colourRemapSEIFileRoot, string(""), "Colour Remapping Information SEI parameters root file name (wo num ext)") 1464 #endif1465 1457 #endif 1466 1458 ("SEIRecoveryPoint", m_recoveryPointSEIEnabled, false, "Control generation of recovery point SEI messages") -
branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h
r1460 r1475 458 458 Int m_log2MaxMvLengthVertical; ///< Indicate the maximum absolute value of a decoded vertical MV component in quarter-pel luma units 459 459 #if !SVC_EXTENSION 460 #if Q0074_COLOUR_REMAPPING_SEI461 460 std::string m_colourRemapSEIFileRoot; 462 #endif463 461 #endif 464 462 -
branches/SHM-dev/source/App/TAppEncoder/TAppEncLayerCfg.h
r1460 r1475 134 134 135 135 Int m_repFormatIdx; 136 #if Q0074_COLOUR_REMAPPING_SEI137 136 string m_colourRemapSEIFileRoot; 138 #endif139 137 140 138 Int m_layerSwitchOffBegin; -
branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp
r1460 r1475 509 509 Int& m_maxTempLayer = m_apcLayerCfg[layer]->m_maxTempLayer; 510 510 511 #if Q0074_COLOUR_REMAPPING_SEI512 511 string& m_colourRemapSEIFileRoot = m_apcLayerCfg[layer]->m_colourRemapSEIFileRoot; 513 #endif514 512 #endif 515 513 … … 766 764 m_cTEncTop.setKneeSEIInputKneePoint ( m_kneeSEIInputKneePoint ); 767 765 m_cTEncTop.setKneeSEIOutputKneePoint ( m_kneeSEIOutputKneePoint ); 768 #if Q0074_COLOUR_REMAPPING_SEI769 766 m_cTEncTop.setColourRemapInfoSEIFileRoot ( m_colourRemapSEIFileRoot ); 770 #endif771 767 m_cTEncTop.setMasteringDisplaySEI ( m_masteringDisplay ); 772 768 -
branches/SHM-dev/source/Lib/TLibCommon/SEI.cpp
r1460 r1475 149 149 case SEI::TEMP_MOTION_CONSTRAINED_TILE_SETS: return "Temporal motion constrained tile sets"; 150 150 case SEI::CHROMA_RESAMPLING_FILTER_HINT: return "Chroma sampling filter hint"; 151 #if Q0074_COLOUR_REMAPPING_SEI152 151 case SEI::COLOUR_REMAPPING_INFO: return "Colour remapping info"; 153 #endif154 152 #if SVC_EXTENSION 155 153 #if LAYERS_NOT_PRESENT_SEI … … 183 181 } 184 182 185 186 183 #if SUB_BITSTREAM_PROPERTY_SEI 187 184 SEISubBitstreamProperty::SEISubBitstreamProperty() -
branches/SHM-dev/source/Lib/TLibCommon/SEI.h
r1460 r1475 91 91 CHROMA_RESAMPLING_FILTER_HINT = 140, 92 92 KNEE_FUNCTION_INFO = 141, 93 #if Q0074_COLOUR_REMAPPING_SEI94 93 COLOUR_REMAPPING_INFO = 142, 95 #endif96 94 #if LAYERS_NOT_PRESENT_SEI 97 95 LAYERS_NOT_PRESENT = 160, … … 459 457 }; 460 458 461 #if Q0074_COLOUR_REMAPPING_SEI462 459 class SEIColourRemappingInfo : public SEI 463 460 { … … 501 498 std::vector<CRIlut> m_postLut[3]; 502 499 }; 503 #endif504 500 505 501 class SEIChromaResamplingFilterHint : public SEI -
branches/SHM-dev/source/Lib/TLibCommon/TypeDef.h
r1460 r1475 165 165 #define T0196_SELECTIVE_RDOQ 1 ///< selective RDOQ 166 166 #define U0040_MODIFIED_WEIGHTEDPREDICTION_WITH_BIPRED_AND_CLIPPING 1 167 #define Q0074_COLOUR_REMAPPING_SEI 1 ///< JCTVC-Q0074, JCTVC-R0344: SEI Colour Remapping Information168 167 169 168 // ==================================================================================================================== … … 378 377 }; 379 378 380 #if Q0074_COLOUR_REMAPPING_SEI381 379 enum MATRIX_COEFFICIENTS // Table E.5 (Matrix coefficients) 382 380 { … … 393 391 MATRIX_COEFFICIENTS_BT2020_CONSTANT_LUMINANCE = 10, 394 392 }; 395 #endif396 393 397 394 enum DeblockEdgeDir -
branches/SHM-dev/source/Lib/TLibDecoder/SEIread.cpp
r1460 r1475 308 308 xParseSEIKneeFunctionInfo((SEIKneeFunctionInfo&) *sei, payloadSize, pDecodedMessageOutputStream); 309 309 break; 310 #if Q0074_COLOUR_REMAPPING_SEI311 310 case SEI::COLOUR_REMAPPING_INFO: 312 311 sei = new SEIColourRemappingInfo; 313 312 xParseSEIColourRemappingInfo((SEIColourRemappingInfo&) *sei, payloadSize, pDecodedMessageOutputStream); 314 313 break; 315 #endif316 314 case SEI::MASTERING_DISPLAY_COLOUR_VOLUME: 317 315 sei = new SEIMasteringDisplayColourVolume; … … 1335 1333 } 1336 1334 1337 #if Q0074_COLOUR_REMAPPING_SEI1338 1335 Void SEIReader::xParseSEIColourRemappingInfo(SEIColourRemappingInfo& sei, UInt payloadSize, std::ostream *pDecodedMessageOutputStream) 1339 1336 { … … 1424 1421 } 1425 1422 } 1426 #endif1427 1423 1428 1424 Void SEIReader::xParseSEIMasteringDisplayColourVolume(SEIMasteringDisplayColourVolume& sei, UInt payloadSize, std::ostream *pDecodedMessageOutputStream) -
branches/SHM-dev/source/Lib/TLibDecoder/SEIread.h
r1460 r1475 108 108 Void xParseSEIKneeFunctionInfo (SEIKneeFunctionInfo& sei, UInt payloadSize, std::ostream *pDecodedMessageOutputStream); 109 109 Void xParseSEIMasteringDisplayColourVolume (SEIMasteringDisplayColourVolume& sei, UInt payloadSize, std::ostream *pDecodedMessageOutputStream); 110 #if Q0074_COLOUR_REMAPPING_SEI111 110 Void xParseSEIColourRemappingInfo (SEIColourRemappingInfo& sei, UInt payloadSize, std::ostream *pDecodedMessageOutputStream); 112 #endif113 111 114 112 Void sei_read_code(std::ostream *pOS, UInt uiLength, UInt& ruiCode, const TChar *pSymbolName); -
branches/SHM-dev/source/Lib/TLibEncoder/SEIEncoder.cpp
r1460 r1475 421 421 } 422 422 423 #if Q0074_COLOUR_REMAPPING_SEI424 423 template <typename T> 425 424 static Void readTokenValue(T &returnedValue, /// value returned … … 593 592 return true; 594 593 } 595 #endif596 594 597 595 Void SEIEncoder::initSEIChromaResamplingFilterHint(SEIChromaResamplingFilterHint *seiChromaResamplingFilterHint, Int iHorFilterIndex, Int iVerFilterIndex) -
branches/SHM-dev/source/Lib/TLibEncoder/SEIEncoder.h
r1460 r1475 81 81 Void initSEIChromaResamplingFilterHint(SEIChromaResamplingFilterHint *sei, Int iHorFilterIndex, Int iVerFilterIndex); 82 82 Void initSEITimeCode(SEITimeCode *sei); 83 #if Q0074_COLOUR_REMAPPING_SEI84 83 Bool initSEIColourRemappingInfo(SEIColourRemappingInfo *sei, Int currPOC); // returns true on success, false on failure. 85 #endif86 84 87 85 #if LAYERS_NOT_PRESENT_SEI -
branches/SHM-dev/source/Lib/TLibEncoder/SEIwrite.cpp
r1460 r1475 152 152 xWriteSEIKneeFunctionInfo(*static_cast<const SEIKneeFunctionInfo*>(&sei)); 153 153 break; 154 #if Q0074_COLOUR_REMAPPING_SEI155 154 case SEI::COLOUR_REMAPPING_INFO: 156 155 xWriteSEIColourRemappingInfo(*static_cast<const SEIColourRemappingInfo*>(&sei)); 157 156 break; 158 #endif159 157 case SEI::MASTERING_DISPLAY_COLOUR_VOLUME: 160 158 xWriteSEIMasteringDisplayColourVolume(*static_cast<const SEIMasteringDisplayColourVolume*>(&sei)); … … 987 985 } 988 986 989 #if Q0074_COLOUR_REMAPPING_SEI990 987 Void SEIWriter::xWriteSEIColourRemappingInfo(const SEIColourRemappingInfo& sei) 991 988 { … … 1044 1041 } 1045 1042 } 1046 #endif1047 1043 1048 1044 Void SEIWriter::xWriteSEIMasteringDisplayColourVolume(const SEIMasteringDisplayColourVolume& sei) -
branches/SHM-dev/source/Lib/TLibEncoder/SEIwrite.h
r1460 r1475 89 89 Void xWriteSEIChromaResamplingFilterHint(const SEIChromaResamplingFilterHint& sei); 90 90 Void xWriteSEIKneeFunctionInfo(const SEIKneeFunctionInfo &sei); 91 #if Q0074_COLOUR_REMAPPING_SEI92 91 Void xWriteSEIColourRemappingInfo(const SEIColourRemappingInfo& sei); 93 #endif94 92 Void xWriteSEIMasteringDisplayColourVolume( const SEIMasteringDisplayColourVolume& sei); 95 93 -
branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h
r1460 r1475 321 321 Int* m_kneeSEIInputKneePoint; 322 322 Int* m_kneeSEIOutputKneePoint; 323 #if Q0074_COLOUR_REMAPPING_SEI324 323 std::string m_colourRemapSEIFileRoot; ///< SEI Colour Remapping File (initialized from external file) 325 #endif326 324 TComSEIMasteringDisplay m_masteringDisplay; 327 325 //====== Weighted Prediction ======== … … 486 484 #endif 487 485 #endif //SVC_EXTENSION 488 #if Q0074_COLOUR_REMAPPING_SEI489 string m_colourRemapSEIFileName; ///< SEI Colour Remapping File (initialized from external file)490 #endif491 486 492 487 public: … … 494 489 : m_tileColumnWidth() 495 490 , m_tileRowHeight() 496 #if Q0074_COLOUR_REMAPPING_SEI497 , m_colourRemapSEIFileName()498 #endif499 491 { 500 492 m_PCMBitDepth[CHANNEL_TYPE_LUMA]=8; … … 910 902 Void setKneeSEIOutputKneePoint(Int *p) { m_kneeSEIOutputKneePoint = p; } 911 903 Int* getKneeSEIOutputKneePoint() { return m_kneeSEIOutputKneePoint; } 912 #if Q0074_COLOUR_REMAPPING_SEI913 904 Void setColourRemapInfoSEIFileRoot( const std::string &s ) { m_colourRemapSEIFileRoot = s; } 914 905 const std::string &getColourRemapInfoSEIFileRoot() const { return m_colourRemapSEIFileRoot; } 915 #endif916 906 Void setMasteringDisplaySEI(const TComSEIMasteringDisplay &src) { m_masteringDisplay = src; } 917 907 const TComSEIMasteringDisplay &getMasteringDisplaySEI() const { return m_masteringDisplay; } -
branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp
r1460 r1475 750 750 } 751 751 752 #if Q0074_COLOUR_REMAPPING_SEI753 752 // insert one Colour Remapping Info SEI for the picture (if the file exists) 754 753 if (!m_pcCfg->getColourRemapInfoSEIFileRoot().empty()) … … 766 765 } 767 766 } 768 #endif769 767 770 768 #if Q0189_TMVP_CONSTRAINTS
Note: See TracChangeset for help on using the changeset viewer.