diff --git a/source/App/DecoderApp/DecApp.cpp b/source/App/DecoderApp/DecApp.cpp index 42ba28b8ec29108271a7d44bab3956dc84cdd522..59e04ddc1ab28f12e4fe1360a7e07c4ff7399347 100644 --- a/source/App/DecoderApp/DecApp.cpp +++ b/source/App/DecoderApp/DecApp.cpp @@ -410,7 +410,6 @@ uint32_t DecApp::decode() m_cVideoIOYuvReconFile[nalu.m_nuhLayerId].setBitdepthShift(channelType, reconBitdepth - fileBitdepth); } } -#if JVET_V0108 if (!m_SEICTIFileName.empty() && !m_cVideoIOYuvSEICTIFile[nalu.m_nuhLayerId].isOpen()) { const BitDepths& bitDepths = pcListPic->front()->cs->sps->getBitDepths(); // use bit depths of first reconstructed picture. @@ -445,7 +444,6 @@ uint32_t DecApp::decode() m_cVideoIOYuvSEICTIFile[nalu.m_nuhLayerId].open(SEICTIFileName, true, m_outputBitDepth, m_outputBitDepth, bitDepths.recon); // write mode } } -#endif if (!m_annotatedRegionsSEIFileName.empty()) { xOutputAnnotatedRegions(pcListPic); @@ -606,7 +604,6 @@ void DecApp::xDestroyDecLib() recFile.second.close(); } } -#if JVET_V0108 if (!m_SEICTIFileName.empty()) { for (auto& recFile : m_cVideoIOYuvSEICTIFile) @@ -614,7 +611,6 @@ void DecApp::xDestroyDecLib() recFile.second.close(); } } -#endif // destroy decoder class m_cDecLib.destroy(); @@ -773,7 +769,6 @@ void DecApp::xWriteOutput( PicList* pcListPic, uint32_t tId ) NUM_CHROMA_FORMAT, m_bClipOutputVideoToRec709Range ); } } -#if JVET_V0108 // Perform CTI on decoded frame and write to output CTI file if (!m_SEICTIFileName.empty()) { @@ -795,7 +790,6 @@ void DecApp::xWriteOutput( PicList* pcListPic, uint32_t tId ) NUM_CHROMA_FORMAT, m_bClipOutputVideoToRec709Range); } } -#endif writeLineToOutputLog(pcPic); // update POC of display order @@ -928,7 +922,6 @@ void DecApp::xFlushOutput( PicList* pcListPic, const int layerId ) NUM_CHROMA_FORMAT, m_bClipOutputVideoToRec709Range ); } } -#if JVET_V0108 // Perform CTI on decoded frame and write to output CTI file if (!m_SEICTIFileName.empty()) { @@ -950,7 +943,6 @@ void DecApp::xFlushOutput( PicList* pcListPic, const int layerId ) NUM_CHROMA_FORMAT, m_bClipOutputVideoToRec709Range); } } -#endif writeLineToOutputLog(pcPic); // update POC of display order m_iPOCLastDisplay = pcPic->getPOC(); diff --git a/source/App/DecoderApp/DecApp.h b/source/App/DecoderApp/DecApp.h index f8b8b87817fc8aa0382fd8c7032e916e103a5188..33ffaa51912863ce9b30fa3ff00b92e4059cd3f9 100644 --- a/source/App/DecoderApp/DecApp.h +++ b/source/App/DecoderApp/DecApp.h @@ -61,9 +61,7 @@ private: // class interface DecLib m_cDecLib; ///< decoder class std::unordered_map<int, VideoIOYuv> m_cVideoIOYuvReconFile; ///< reconstruction YUV class -#if JVET_V0108 std::unordered_map<int, VideoIOYuv> m_cVideoIOYuvSEICTIFile; ///< reconstruction YUV with CTI class -#endif // for output control int m_iPOCLastDisplay; ///< last POC in display order diff --git a/source/App/DecoderApp/DecAppCfg.cpp b/source/App/DecoderApp/DecAppCfg.cpp index c4ad90ebf6e0f622a4910c6c241af4d4c7ff7a79..616d65fd10938aa22e5b7812c90f78455f6f01ca 100644 --- a/source/App/DecoderApp/DecAppCfg.cpp +++ b/source/App/DecoderApp/DecAppCfg.cpp @@ -96,9 +96,7 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] ) ("SEINoDisplay", m_decodedNoDisplaySEIEnabled, true, "Control handling of decoded no display SEI messages") ("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.") ("SEIColourRemappingInfoFilename", m_colourRemapSEIFileName, string(""), "Colour Remapping YUV output file name. If empty, no remapping is applied (ignore SEI message)\n") -#if JVET_V0108 ("SEICTIFilename", m_SEICTIFileName, string(""), "CTI YUV output file name. If empty, no Colour Transform is applied (ignore SEI message)\n") -#endif ("SEIAnnotatedRegionsInfoFilename", m_annotatedRegionsSEIFileName, string(""), "Annotated regions output file name. If empty, no object information will be saved (ignore SEI message)\n") ("OutputDecodedSEIMessagesFilename", m_outputDecodedSEIMessagesFilename, string(""), "When non empty, output decoded SEI messages to the indicated file. If file is '-', then output to stdout\n") #if JVET_S0257_DUMP_360SEI_MESSAGE @@ -261,9 +259,7 @@ DecAppCfg::DecAppCfg() , m_decodedPictureHashSEIEnabled(0) , m_decodedNoDisplaySEIEnabled(false) , m_colourRemapSEIFileName() -#if JVET_V0108 , m_SEICTIFileName() -#endif , m_annotatedRegionsSEIFileName() , m_targetDecLayerIdSet() , m_outputDecodedSEIMessagesFilename() diff --git a/source/App/DecoderApp/DecAppCfg.h b/source/App/DecoderApp/DecAppCfg.h index 157c18cfccb11698d662b3e581ffba64c6f05683..c8a735ca5ee195f2dda4db70e3992cb0e458efc0 100644 --- a/source/App/DecoderApp/DecAppCfg.h +++ b/source/App/DecoderApp/DecAppCfg.h @@ -72,9 +72,7 @@ protected: int m_decodedPictureHashSEIEnabled; ///< Checksum(3)/CRC(2)/MD5(1)/disable(0) acting on decoded picture hash SEI message bool m_decodedNoDisplaySEIEnabled; ///< Enable(true)/disable(false) writing only pictures that get displayed based on the no display SEI message std::string m_colourRemapSEIFileName; ///< output Colour Remapping file name -#if JVET_V0108 std::string m_SEICTIFileName; ///< output Recon with CTI file name -#endif std::string m_annotatedRegionsSEIFileName; ///< annotated regions file name std::vector<int> m_targetDecLayerIdSet; ///< set of LayerIds to be included in the sub-bitstream extraction process. std::string m_outputDecodedSEIMessagesFilename; ///< filename to output decoded SEI messages to. If '-', then use stdout. If empty, do not output details. diff --git a/source/App/EncoderApp/EncApp.cpp b/source/App/EncoderApp/EncApp.cpp index 2c97d5808243bbd3f93b50cca2ce229fa0c78446..b3d1be536aea59ecedb9ed7a0e5b22f6347c64fa 100644 --- a/source/App/EncoderApp/EncApp.cpp +++ b/source/App/EncoderApp/EncApp.cpp @@ -970,7 +970,6 @@ void EncApp::xInitLibCfg() m_cEncLib.setAmbientViewingEnvironmentSEIIlluminance (m_aveSEIAmbientIlluminance); m_cEncLib.setAmbientViewingEnvironmentSEIAmbientLightX ((uint16_t)m_aveSEIAmbientLightX); m_cEncLib.setAmbientViewingEnvironmentSEIAmbientLightY ((uint16_t)m_aveSEIAmbientLightY); -#if JVET_V0108 // colour tranform information sei m_cEncLib.setCtiSEIEnabled(m_ctiSEIEnabled); m_cEncLib.setCtiSEIId(m_ctiSEIId); @@ -987,7 +986,6 @@ void EncApp::xInitLibCfg() { m_cEncLib.setCtiSEILut(m_ctiSEILut[i], i); } -#endif // content colour volume SEI m_cEncLib.setCcvSEIEnabled (m_ccvSEIEnabled); m_cEncLib.setCcvSEICancelFlag (m_ccvSEICancelFlag); diff --git a/source/App/EncoderApp/EncAppCfg.cpp b/source/App/EncoderApp/EncAppCfg.cpp index 034cb321516132cad24dc0be9a9be70b41a32b57..2cf1361921232e5132fcead7febd99c57263da4c 100644 --- a/source/App/EncoderApp/EncAppCfg.cpp +++ b/source/App/EncoderApp/EncAppCfg.cpp @@ -623,11 +623,9 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) SMultiValueInput<int> cfg_DisplayPrimariesCode (0, 50000, 6, 6, defaultPrimaryCodes, sizeof(defaultPrimaryCodes )/sizeof(int)); SMultiValueInput<int> cfg_DisplayWhitePointCode (0, 50000, 2, 2, defaultWhitePointCode, sizeof(defaultWhitePointCode)/sizeof(int)); -#if JVET_V0108 SMultiValueInput<int16_t> cfg_SEICTILut0(0, 128, 0, MAX_CTI_LUT_SIZE + 1); SMultiValueInput<int16_t> cfg_SEICTILut1(0, 128, 0, MAX_CTI_LUT_SIZE + 1); SMultiValueInput<int16_t> cfg_SEICTILut2(0, 128, 0, MAX_CTI_LUT_SIZE + 1); -#endif SMultiValueInput<bool> cfg_timeCodeSeiTimeStampFlag (0, 1, 0, MAX_TIMECODE_SEI_SETS); SMultiValueInput<bool> cfg_timeCodeSeiNumUnitFieldBasedFlag(0, 1, 0, MAX_TIMECODE_SEI_SETS); SMultiValueInput<int> cfg_timeCodeSeiCountingType (0, 6, 0, MAX_TIMECODE_SEI_SETS); @@ -1406,7 +1404,6 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) ("SEIAVEAmbientIlluminance", m_aveSEIAmbientIlluminance, 100000u, "Specifies the environmental illluminance of the ambient viewing environment in units of 1/10000 lux for the ambient viewing environment SEI message") ("SEIAVEAmbientLightX", m_aveSEIAmbientLightX, 15635u, "Specifies the normalized x chromaticity coordinate of the environmental ambient light in the nominal viewing enviornment according to the CIE 1931 definition in units of 1/50000 lux for the ambient viewing enviornment SEI message") ("SEIAVEAmbientLightY", m_aveSEIAmbientLightY, 16450u, "Specifies the normalized y chromaticity coordinate of the environmental ambient light in the nominal viewing enviornment according to the CIE 1931 definition in units of 1/50000 lux for the ambient viewing enviornment SEI message") -#if JVET_V0108 // colour tranform information SEI ("SEICTIEnabled", m_ctiSEIEnabled, false, "Control generation of the Colour transform information SEI message") ("SEICTIId", m_ctiSEIId, 0u, "Id of the Colour transform information SEI message") @@ -1422,7 +1419,6 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) ("SEICTILut0", cfg_SEICTILut0, cfg_SEICTILut0, "slope values for component 0 of SEI CTI") ("SEICTILut1", cfg_SEICTILut1, cfg_SEICTILut1, "slope values for component 1 of SEI CTI") ("SEICTILut2", cfg_SEICTILut2, cfg_SEICTILut2, "slope values for component 2 of SEI CTI") -#endif // content colour volume SEI ("SEICCVEnabled", m_ccvSEIEnabled, false, "Control generation of the Content Colour Volume SEI message") ("SEICCVCancelFlag", m_ccvSEICancelFlag, true, "Specifies the persistence of any previous content colour volume SEI message in output order.") @@ -2485,7 +2481,6 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) m_masteringDisplay.whitePoint[idx] = uint16_t((cfg_DisplayWhitePointCode.values.size() > idx) ? cfg_DisplayWhitePointCode.values[idx] : 0); } } -#if JVET_V0108 if (m_ctiSEIEnabled) { CHECK(!m_ctiSEICrossComponentFlag && m_ctiSEICrossComponentInferred, "CTI CrossComponentFlag is 0, but CTI CrossComponentInferred is 1 (must be 0 for CrossComponentFlag 0)"); @@ -2530,7 +2525,6 @@ bool EncAppCfg::parseCfg( int argc, char* argv[] ) CHECK(n > MAX_CTI_LUT_SIZE, "LUT size minus 1 is larger than MAX_CTI_LUT_SIZE (64)!"); } } -#endif if ( m_omniViewportSEIEnabled && !m_omniViewportSEICancelFlag ) { CHECK (!( m_omniViewportSEICntMinus1 >= 0 && m_omniViewportSEICntMinus1 < 16 ), "SEIOmniViewportCntMinus1 must be in the range of 0 to 16"); @@ -3075,12 +3069,10 @@ bool EncAppCfg::xCheckParameter() if (m_updateCtrl > 0 && m_adpOption > 2) { m_adpOption -= 2; } } -#if JVET_V0108 if (m_ctiSEIEnabled) { xConfirmPara(m_ctiSEINumberChromaLut < 0 || m_ctiSEINumberChromaLut > 2, "CTI number of chroma LUTs is out of range"); } -#endif xConfirmPara( m_cbQpOffset < -12, "Min. Chroma Cb QP Offset is -12" ); xConfirmPara( m_cbQpOffset > 12, "Max. Chroma Cb QP Offset is 12" ); xConfirmPara( m_crQpOffset < -12, "Min. Chroma Cr QP Offset is -12" ); @@ -4461,9 +4453,7 @@ void EncAppCfg::xPrintParameter() msg( VERBOSE, "RPR:%d ", 0 ); } msg(VERBOSE, "TemporalFilter:%d ", m_gopBasedTemporalFilterEnabled); -#if JVET_V0108 msg(VERBOSE, "SEI CTI:%d ", m_ctiSEIEnabled); -#endif #if EXTENSION_360_VIDEO m_ext360.outputConfigurationSummary(); #endif diff --git a/source/App/EncoderApp/EncAppCfg.h b/source/App/EncoderApp/EncAppCfg.h index 9c0582158cd0df2451892f8070a565bdf6a373e2..87e914eccd4e0420aeae93292ed8fca89376e191 100644 --- a/source/App/EncoderApp/EncAppCfg.h +++ b/source/App/EncoderApp/EncAppCfg.h @@ -536,7 +536,6 @@ protected: uint32_t m_aveSEIAmbientIlluminance; uint32_t m_aveSEIAmbientLightX; uint32_t m_aveSEIAmbientLightY; -#if JVET_V0108 // colour tranform information sei bool m_ctiSEIEnabled; uint32_t m_ctiSEIId; @@ -550,7 +549,6 @@ protected: uint32_t m_ctiSEINumberChromaLut; int m_ctiSEIChromaOffset; LutModel m_ctiSEILut[MAX_NUM_COMPONENT]; -#endif // content colour volume sei bool m_ccvSEIEnabled; bool m_ccvSEICancelFlag; diff --git a/source/App/Parcat/parcat.cpp b/source/App/Parcat/parcat.cpp index db9c5d5b9ab04a3ed37b396e987ee128bd7506d2..b7dfe8921d70d3c6f0c24011318961e9637ef917 100644 --- a/source/App/Parcat/parcat.cpp +++ b/source/App/Parcat/parcat.cpp @@ -214,9 +214,7 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int int off = 0; int cnt = 0; bool idr_found = false; -#if JVET_V0108 bool is_pre_sei_before_idr = true; -#endif std::vector<uint8_t> out; out.reserve(v.size()); @@ -272,12 +270,10 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int parameterSetManager.storePPS( pps, inp_nalu.getBitstream().getFifo() ); } -#if JVET_V0108 if (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP) { is_pre_sei_before_idr = false; } -#endif if(nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP) { poc = 0; @@ -338,16 +334,10 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int skip_next_sei = true; idr_found = true; } -#if JVET_V0108 if ((idx > 1 && (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP)) || ((idx > 1 && !idr_found) && (nalu_type == NAL_UNIT_OPI || nalu_type == NAL_UNIT_DCI || nalu_type == NAL_UNIT_VPS || nalu_type == NAL_UNIT_SPS || nalu_type == NAL_UNIT_PPS || nalu_type == NAL_UNIT_PREFIX_APS || nalu_type == NAL_UNIT_SUFFIX_APS || nalu_type == NAL_UNIT_PH || nalu_type == NAL_UNIT_ACCESS_UNIT_DELIMITER)) || (nalu_type == NAL_UNIT_SUFFIX_SEI && skip_next_sei) || (idx > 1 && nalu_type == NAL_UNIT_PREFIX_SEI && is_pre_sei_before_idr)) -#else - if ((idx > 1 && (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP)) - || ((idx > 1 && !idr_found) && (nalu_type == NAL_UNIT_OPI || nalu_type == NAL_UNIT_DCI || nalu_type == NAL_UNIT_VPS || nalu_type == NAL_UNIT_SPS || nalu_type == NAL_UNIT_PPS || nalu_type == NAL_UNIT_PREFIX_APS || nalu_type == NAL_UNIT_SUFFIX_APS || nalu_type == NAL_UNIT_PH || nalu_type == NAL_UNIT_ACCESS_UNIT_DELIMITER || nalu_type == NAL_UNIT_PREFIX_SEI)) - || (nalu_type == NAL_UNIT_SUFFIX_SEI && skip_next_sei)) -#endif { } else diff --git a/source/Lib/CommonLib/Buffer.cpp b/source/Lib/CommonLib/Buffer.cpp index ce468f30a3e6770af13411b84a528237f63377be..e3882dbf57cc6f8cf06c9f569f799ede925728c0 100644 --- a/source/Lib/CommonLib/Buffer.cpp +++ b/source/Lib/CommonLib/Buffer.cpp @@ -484,7 +484,6 @@ void AreaBuf<Pel>::scaleSignal(const int scale, const bool dir, const ClpRng& cl } } -#if JVET_V0108 template<> void AreaBuf<Pel>::applyLumaCTI(std::vector<Pel>& pLUTY) { @@ -549,7 +548,6 @@ void AreaBuf<Pel>::applyChromaCTI(Pel* bufY, int strideY, std::vector<Pel>& pLUT } } } -#endif template<> void AreaBuf<Pel>::addAvg( const AreaBuf<const Pel> &other1, const AreaBuf<const Pel> &other2, const ClpRng& clpRng) { diff --git a/source/Lib/CommonLib/Buffer.h b/source/Lib/CommonLib/Buffer.h index ae3d874fd59b1049a0d1ba10d73c2048427bbc5e..de50d3175a9e35a326c7aaaf8081ad536f7f669e 100644 --- a/source/Lib/CommonLib/Buffer.h +++ b/source/Lib/CommonLib/Buffer.h @@ -137,10 +137,8 @@ struct AreaBuf : public Size void rspSignal ( std::vector<Pel>& pLUT ); void scaleSignal ( const int scale, const bool dir , const ClpRng& clpRng); -#if JVET_V0108 void applyLumaCTI(std::vector<Pel>& pLUTY); void applyChromaCTI(Pel* bufY, int strideY, std::vector<Pel>& pLUTUV, int bitDepth, ChromaFormat chrFormat, bool fwdMap); -#endif T computeAvg ( ) const; T& at( const int &x, const int &y ) { return buf[y * stride + x]; } diff --git a/source/Lib/CommonLib/CommonDef.h b/source/Lib/CommonLib/CommonDef.h index dab18be7309202005fe748864beb6a4d138b2e8b..ffbca486194a9703ae47c34d682fb999289a6d33 100644 --- a/source/Lib/CommonLib/CommonDef.h +++ b/source/Lib/CommonLib/CommonDef.h @@ -472,9 +472,7 @@ static const std::pair<int, int> SCALE_1X = std::pair<int, int>( 1 << SCALE_RATI static const int DELTA_QP_ACT[4] = { -5, 1, 3, 1 }; static const int MAX_TSRC_RICE = 8; ///<Maximum supported TSRC Rice parameter static const int MIN_TSRC_RICE = 1; ///<Minimum supported TSRC Rice parameter -#if JVET_V0108 static const int MAX_CTI_LUT_SIZE = 64; ///<Maximum colour transform LUT size for CTI SEI -#endif // ==================================================================================================================== // Macro functions // ==================================================================================================================== diff --git a/source/Lib/CommonLib/Picture.cpp b/source/Lib/CommonLib/Picture.cpp index 03a6e3a6fcc7efc2eb897a5b6f79653d56891e32..40380cdf10fe9a71eeeb98051073d9d794109581 100644 --- a/source/Lib/CommonLib/Picture.cpp +++ b/source/Lib/CommonLib/Picture.cpp @@ -63,9 +63,7 @@ Picture::Picture() topField = false; precedingDRAP = false; edrapRapId = -1; -#if JVET_V0108 m_colourTranfParams = NULL; -#endif nonReferencePictureFlag = false; for( int i = 0; i < MAX_NUM_CHANNEL_TYPE; i++ ) @@ -134,9 +132,7 @@ void Picture::destroy() delete[] m_spliceIdx; m_spliceIdx = NULL; } -#if JVET_V0108 m_invColourTransfBuf = NULL; -#endif } void Picture::createTempBuffers( const unsigned _maxCUSize ) @@ -1215,7 +1211,6 @@ void Picture::addPictureToHashMapForInter() } } } -#if JVET_V0108 void Picture::createColourTransfProcessor(bool firstPictureInSequence, SEIColourTransformApply* ctiCharacteristics, PelStorage* ctiBuf, int width, int height, ChromaFormat fmt, int bitDepth) { m_colourTranfParams = ctiCharacteristics; @@ -1257,4 +1252,3 @@ PelUnitBuf Picture::getDisplayBuf() return *m_invColourTransfBuf; } -#endif \ No newline at end of file diff --git a/source/Lib/CommonLib/Picture.h b/source/Lib/CommonLib/Picture.h index 59f13d95f04ab4aa6c5e52ea3d95deadf977023c..2b6c9d732806bf978afa1839ee3a1584d81781fc 100644 --- a/source/Lib/CommonLib/Picture.h +++ b/source/Lib/CommonLib/Picture.h @@ -48,9 +48,7 @@ #include "CodingStructure.h" #include "Hash.h" #include "MCTS.h" -#if JVET_V0108 #include "SEIColourTransform.h" -#endif #include <deque> @@ -71,12 +69,10 @@ struct Picture : public UnitArea void createTempBuffers( const unsigned _maxCUSize ); void destroyTempBuffers(); -#if JVET_V0108 SEIColourTransformApply* m_colourTranfParams; PelStorage* m_invColourTransfBuf; void createColourTransfProcessor(bool firstPictureInSequence, SEIColourTransformApply* ctiCharacteristics, PelStorage* ctiBuf, int width, int height, ChromaFormat fmt, int bitDepth); PelUnitBuf getDisplayBuf(); -#endif PelBuf getOrigBuf(const CompArea &blk); const CPelBuf getOrigBuf(const CompArea &blk) const; diff --git a/source/Lib/CommonLib/SEI.cpp b/source/Lib/CommonLib/SEI.cpp index f762fe458aced33fbd8ad5ac300c3506d5c3790d..008c8748b1ccdd167dae30095ce33e35cedb8e45 100644 --- a/source/Lib/CommonLib/SEI.cpp +++ b/source/Lib/CommonLib/SEI.cpp @@ -439,9 +439,7 @@ const char *SEI::getSEIMessageString(SEI::PayloadType payloadType) case SEI::CONTENT_LIGHT_LEVEL_INFO: return "Content light level information"; case SEI::AMBIENT_VIEWING_ENVIRONMENT: return "Ambient viewing environment"; case SEI::CONTENT_COLOUR_VOLUME: return "Content colour volume"; -#if JVET_V0108 case SEI::COLOUR_TRANSFORM_INFO: return "Colour transform information"; -#endif case SEI::EQUIRECTANGULAR_PROJECTION: return "Equirectangular projection"; case SEI::SPHERE_ROTATION: return "Sphere rotation"; case SEI::REGION_WISE_PACKING: return "Region wise packing information"; diff --git a/source/Lib/CommonLib/SEI.h b/source/Lib/CommonLib/SEI.h index 7ee140c81ae6b907d27d88ffb44b3c7da4cec3b8..484f54313172542d3099b41e7b7f8eaee894631e 100644 --- a/source/Lib/CommonLib/SEI.h +++ b/source/Lib/CommonLib/SEI.h @@ -67,9 +67,7 @@ public: DECODED_PICTURE_HASH = 132, SCALABLE_NESTING = 133, MASTERING_DISPLAY_COLOUR_VOLUME = 137, -#if JVET_V0108 COLOUR_TRANSFORM_INFO = 142, -#endif DEPENDENT_RAP_INDICATION = 145, EQUIRECTANGULAR_PROJECTION = 150, SPHERE_ROTATION = 154, @@ -825,7 +823,6 @@ public: uint16_t m_ambientLightY; }; -#if JVET_V0108 class SEIColourTransformInfo : public SEI { public: @@ -848,7 +845,6 @@ public: uint16_t m_log2NumberOfPointsPerLut; LutModel m_lut[MAX_NUM_COMPONENT]; }; -#endif class SEIContentColourVolume : public SEI { public: diff --git a/source/Lib/CommonLib/SEIColourTransform.cpp b/source/Lib/CommonLib/SEIColourTransform.cpp index 1e463b4281a4bb2b9a390dfa622a0cea45b8c68d..280ea954aaca241085c76205f940ff4cd4be8697 100644 --- a/source/Lib/CommonLib/SEIColourTransform.cpp +++ b/source/Lib/CommonLib/SEIColourTransform.cpp @@ -37,7 +37,6 @@ #include "SEIColourTransform.h" -#if JVET_V0108 #include "SEI.h" #include "Unit.h" #include "Buffer.h" @@ -197,4 +196,3 @@ void SEIColourTransformApply::generateColourTransfLUTs() } } } -#endif diff --git a/source/Lib/CommonLib/SEIColourTransform.h b/source/Lib/CommonLib/SEIColourTransform.h index 83bf8190d5e4eaf1db93360152e9a608c3df114b..feebfe7ae9d71f754d2e614aea39a6ec3a883318 100644 --- a/source/Lib/CommonLib/SEIColourTransform.h +++ b/source/Lib/CommonLib/SEIColourTransform.h @@ -42,7 +42,6 @@ //! \ingroup CommonLib //! \{ -#if JVET_V0108 struct PelStorage; class SEIColourTransformInfo; @@ -68,6 +67,5 @@ public: void generateColourTransfLUTs (); };// END CLASS DEFINITION SEIColourTransformApply -#endif #endif \ No newline at end of file diff --git a/source/Lib/CommonLib/TypeDef.h b/source/Lib/CommonLib/TypeDef.h index 7fa59d2f418b6ebc7bf37831c407d916ae265c23..bed5579f1f4f04b38bdac7982e3e6f4a26d5a767 100644 --- a/source/Lib/CommonLib/TypeDef.h +++ b/source/Lib/CommonLib/TypeDef.h @@ -64,7 +64,6 @@ -#define JVET_V0108 1 // JVET_V0108: Colour Transform Information SEI #define JVET_V0111_DU 1 // JVET-V0111 Decoding Unit Information @@ -909,14 +908,12 @@ struct LFCUParam bool leftEdge; ///< indicates left edge bool topEdge; ///< indicates top edge }; -#if JVET_V0108 struct LutModel { bool presentFlag = false; int numLutValues = 0; std::vector<Pel> lutValues; }; -#endif struct PictureHash { diff --git a/source/Lib/DecoderLib/DecLib.cpp b/source/Lib/DecoderLib/DecLib.cpp index 6a938b2fb27afae152b2f514fff7241e584642b5..bedd149022bf202bb4392c279ef1dda329687e03 100644 --- a/source/Lib/DecoderLib/DecLib.cpp +++ b/source/Lib/DecoderLib/DecLib.cpp @@ -428,10 +428,8 @@ DecLib::DecLib() , m_prevPicPOC(MAX_INT) , m_prevTid0POC(0) , m_bFirstSliceInPicture(true) -#if JVET_V0108 , m_firstPictureInSequence(true) , m_colourTranfParams() -#endif , m_firstSliceInBitstream(true) , m_isFirstAuInCvs( true ) , m_prevSliceSkipped(false) @@ -1679,10 +1677,8 @@ void DecLib::xActivateParameterSets( const InputNALUnit nalu ) #else m_pcPic->finalInit( vps, *sps, *pps, &m_picHeader, apss, lmcsAPS, scalinglistAPS ); #endif -#if JVET_V0108 m_pcPic->createColourTransfProcessor(m_firstPictureInSequence, &m_colourTranfParams, &m_invColourTransfBuf, pps->getPicWidthInLumaSamples(), pps->getPicHeightInLumaSamples(), sps->getChromaFormatIdc(), sps->getBitDepth(CHANNEL_TYPE_LUMA)); m_firstPictureInSequence = false; -#endif m_pcPic->createTempBuffers( m_pcPic->cs->pps->pcv->maxCUWidth ); m_pcPic->cs->createCoeffs((bool)m_pcPic->cs->sps->getPLTMode()); diff --git a/source/Lib/DecoderLib/DecLib.h b/source/Lib/DecoderLib/DecLib.h index 97119938aa40033bf6c5f88d491271c9f4467861..05494d7bc87b0ce8d937882298636b5acce7d712 100644 --- a/source/Lib/DecoderLib/DecLib.h +++ b/source/Lib/DecoderLib/DecLib.h @@ -130,11 +130,9 @@ private: int m_prevPicPOC; int m_prevTid0POC; bool m_bFirstSliceInPicture; -#if JVET_V0108 bool m_firstPictureInSequence; SEIColourTransformApply m_colourTranfParams; PelStorage m_invColourTransfBuf; -#endif bool m_firstSliceInSequence[MAX_VPS_LAYERS]; bool m_firstSliceInBitstream; bool m_isFirstAuInCvs; diff --git a/source/Lib/DecoderLib/SEIread.cpp b/source/Lib/DecoderLib/SEIread.cpp index 38211035b65902ea73969814a28de43eb7ce37f3..e55c9a6fab579c3f3221a7114f7683b5b6e8e30c 100644 --- a/source/Lib/DecoderLib/SEIread.cpp +++ b/source/Lib/DecoderLib/SEIread.cpp @@ -324,12 +324,10 @@ void SEIReader::xReadSEImessage(SEIMessages& seis, const NalUnitType nalUnitType sei = new SEIContentColourVolume; xParseSEIContentColourVolume((SEIContentColourVolume&)*sei, payloadSize, pDecodedMessageOutputStream); break; -#if JVET_V0108 case SEI::COLOUR_TRANSFORM_INFO: sei = new SEIColourTransformInfo; xParseSEIColourTransformInfo((SEIColourTransformInfo&)*sei, payloadSize, pDecodedMessageOutputStream); break; -#endif default: for (uint32_t i = 0; i < payloadSize; i++) { @@ -1378,7 +1376,6 @@ void SEIReader::xParseSEIAmbientViewingEnvironment(SEIAmbientViewingEnvironment& sei_read_code(pDecodedMessageOutputStream, 16, code, "ambient_light_y"); sei.m_ambientLightY = (uint16_t)code; } -#if JVET_V0108 void SEIReader::xParseSEIColourTransformInfo(SEIColourTransformInfo& sei, uint32_t payloadSize, std::ostream* pDecodedMessageOutputStream) { uint32_t code; @@ -1457,7 +1454,6 @@ void SEIReader::xParseSEIColourTransformInfo(SEIColourTransformInfo& sei, uint32 } } } -#endif void SEIReader::xParseSEIContentColourVolume(SEIContentColourVolume& sei, uint32_t payloadSize, std::ostream *pDecodedMessageOutputStream) { int i; diff --git a/source/Lib/DecoderLib/SEIread.h b/source/Lib/DecoderLib/SEIread.h index 2be15557be07cfcb70bbf4d72d2627e11f4457c8..de75eb3d589cf2c0b087467b0d218521276bfbbc 100644 --- a/source/Lib/DecoderLib/SEIread.h +++ b/source/Lib/DecoderLib/SEIread.h @@ -94,9 +94,7 @@ protected: void xParseSEIAmbientViewingEnvironment (SEIAmbientViewingEnvironment& sei, uint32_t payloadSize, std::ostream *pDecodedMessageOutputStream); void xParseSEIContentColourVolume (SEIContentColourVolume& sei, uint32_t payloadSize, std::ostream *pDecodedMessageOutputStream); void xParseSEIExtendedDrapIndication (SEIExtendedDrapIndication& sei, uint32_t payloadSize, std::ostream *pDecodedMessageOutputStream); -#if JVET_V0108 void xParseSEIColourTransformInfo (SEIColourTransformInfo& sei, uint32_t payloadSize, std::ostream* pDecodedMessageOutputStream); -#endif void sei_read_scode(std::ostream *pOS, uint32_t length, int& code, const char *pSymbolName); void sei_read_code(std::ostream *pOS, uint32_t uiLength, uint32_t& ruiCode, const char *pSymbolName); diff --git a/source/Lib/EncoderLib/EncCfg.h b/source/Lib/EncoderLib/EncCfg.h index 1b9c10b2364b8da21b8e19c2aaa16e797603e58c..238d0cd006452dc6319ac443acc4e57672cb3994 100644 --- a/source/Lib/EncoderLib/EncCfg.h +++ b/source/Lib/EncoderLib/EncCfg.h @@ -648,7 +648,6 @@ protected: uint32_t m_aveSEIAmbientIlluminance; uint16_t m_aveSEIAmbientLightX; uint16_t m_aveSEIAmbientLightY; -#if JVET_V0108 // colour tranform information sei bool m_ctiSEIEnabled; uint32_t m_ctiSEIId; @@ -662,7 +661,6 @@ protected: uint32_t m_ctiSEINumberChromaLut; int m_ctiSEIChromaOffset; LutModel m_ctiSEILut[MAX_NUM_COMPONENT]; -#endif // ccv sei bool m_ccvSEIEnabled; bool m_ccvSEICancelFlag; @@ -1839,7 +1837,6 @@ public: uint16_t getAmbientViewingEnvironmentSEIAmbientLightX() { return m_aveSEIAmbientLightX; } void setAmbientViewingEnvironmentSEIAmbientLightY( uint16_t v ) { m_aveSEIAmbientLightY = v; } uint16_t getAmbientViewingEnvironmentSEIAmbientLightY() { return m_aveSEIAmbientLightY; } -#if JVET_V0108 // colour tranform information sei void setCtiSEIEnabled(bool b) { m_ctiSEIEnabled = b; } bool getCtiSEIEnabled() { return m_ctiSEIEnabled; } @@ -1866,7 +1863,6 @@ public: LutModel getCtiSEILut(int idx) { return m_ctiSEILut[idx]; } void setCtiSEILut(LutModel& cmp, int idx) { m_ctiSEILut[idx] = cmp; } LutModel* getCtiSEILuts() { return m_ctiSEILut; } -#endif // ccv SEI void setCcvSEIEnabled(bool b) { m_ccvSEIEnabled = b; } bool getCcvSEIEnabled() { return m_ccvSEIEnabled; } diff --git a/source/Lib/EncoderLib/EncGOP.cpp b/source/Lib/EncoderLib/EncGOP.cpp index bdfb3939032b5d45e85800f3804e052a696fdc25..691a93fa78b8a8f90b9b02285c5ff3e571868d28 100644 --- a/source/Lib/EncoderLib/EncGOP.cpp +++ b/source/Lib/EncoderLib/EncGOP.cpp @@ -800,7 +800,6 @@ void EncGOP::xCreateIRAPLeadingSEIMessages (SEIMessages& seiMessages, const SPS m_seiEncoder.initSEIDepthRepresentationInfo(seiDepthRepresentationInfo); seiMessages.push_back(seiDepthRepresentationInfo); } -#if JVET_V0108 // colour transform information if (m_pcCfg->getCtiSEIEnabled()) { @@ -808,7 +807,6 @@ void EncGOP::xCreateIRAPLeadingSEIMessages (SEIMessages& seiMessages, const SPS m_seiEncoder.initSEIColourTransformInfo(seiCTI); seiMessages.push_back(seiCTI); } -#endif } void EncGOP::xCreatePerPictureSEIMessages (int picInGOP, SEIMessages& seiMessages, SEIMessages& nestedSeiMessages, Slice *slice) diff --git a/source/Lib/EncoderLib/SEIEncoder.cpp b/source/Lib/EncoderLib/SEIEncoder.cpp index d886d28f16d3a34fa0c2cf92b8d4cb9d2a8f86f2..31a2795d4a724533b3ff2977ad138e1edc503adb 100644 --- a/source/Lib/EncoderLib/SEIEncoder.cpp +++ b/source/Lib/EncoderLib/SEIEncoder.cpp @@ -994,7 +994,6 @@ void SEIEncoder::initSEIDepthRepresentationInfo(SEIDepthRepresentationInfo *sei) } } -#if JVET_V0108 void SEIEncoder::initSEIColourTransformInfo(SEIColourTransformInfo* seiCTI) { CHECK(!(m_isInitialized), "Unspecified error"); @@ -1019,7 +1018,6 @@ void SEIEncoder::initSEIColourTransformInfo(SEIColourTransformInfo* seiCTI) } seiCTI->m_log2NumberOfPointsPerLut = floorLog2(seiCTI->m_lut[0].numLutValues - 1); } -#endif void SEIEncoder::initSEISubpictureLevelInfo(SEISubpicureLevelInfo *sei, const SPS *sps) { diff --git a/source/Lib/EncoderLib/SEIEncoder.h b/source/Lib/EncoderLib/SEIEncoder.h index 74d45d353e20add475d9c5105052d339711d2472..76232b8f5bc584043a75132405d0df999ea2f95d 100644 --- a/source/Lib/EncoderLib/SEIEncoder.h +++ b/source/Lib/EncoderLib/SEIEncoder.h @@ -92,9 +92,7 @@ public: void initSEIAlphaChannelInfo(SEIAlphaChannelInfo *sei); void initSEIDepthRepresentationInfo(SEIDepthRepresentationInfo *sei); bool initSEIAnnotatedRegions(SEIAnnotatedRegions *sei, int currPOC); -#if JVET_V0108 void initSEIColourTransformInfo(SEIColourTransformInfo* sei); -#endif void readAnnotatedRegionSEI(std::istream &fic, SEIAnnotatedRegions *seiAnnoRegion, bool &failed); private: EncCfg* m_pcCfg; diff --git a/source/Lib/EncoderLib/SEIwrite.cpp b/source/Lib/EncoderLib/SEIwrite.cpp index f213b3f9b43df4c299fd8774638715edbcb13e1c..f482bcfc485cf41baf7696f449300e3e38279071 100644 --- a/source/Lib/EncoderLib/SEIwrite.cpp +++ b/source/Lib/EncoderLib/SEIwrite.cpp @@ -139,11 +139,9 @@ void SEIWriter::xWriteSEIpayloadData(OutputBitstream &bs, const SEI& sei, HRD &h case SEI::CONTENT_COLOUR_VOLUME: xWriteSEIContentColourVolume(*static_cast<const SEIContentColourVolume*>(&sei)); break; -#if JVET_V0108 case SEI::COLOUR_TRANSFORM_INFO: xWriteSEIColourTransformInfo(*static_cast<const SEIColourTransformInfo*>(&sei)); break; -#endif case SEI::SUBPICTURE_LEVEL_INFO: xWriteSEISubpictureLevelInfo(*static_cast<const SEISubpicureLevelInfo*>(&sei)); break; @@ -1285,7 +1283,6 @@ void SEIWriter::xWriteSEIContentColourVolume(const SEIContentColourVolume &sei) } } -#if JVET_V0108 void SEIWriter::xWriteSEIColourTransformInfo(const SEIColourTransformInfo& sei) { bool colourTransformCancelFlag = 0; @@ -1340,5 +1337,4 @@ void SEIWriter::xWriteSEIColourTransformInfo(const SEIColourTransformInfo& sei) } } } -#endif //! \} diff --git a/source/Lib/EncoderLib/SEIwrite.h b/source/Lib/EncoderLib/SEIwrite.h index 7053cf1be0937e7fc73bcc265d458f5501317a31..55cff4a49dfb1d97bafda8eee30e8985a8941201 100644 --- a/source/Lib/EncoderLib/SEIwrite.h +++ b/source/Lib/EncoderLib/SEIwrite.h @@ -86,9 +86,7 @@ protected: void xWriteSEIContentLightLevelInfo(const SEIContentLightLevelInfo& sei); void xWriteSEIAmbientViewingEnvironment(const SEIAmbientViewingEnvironment& sei); void xWriteSEIContentColourVolume(const SEIContentColourVolume &sei); -#if JVET_V0108 void xWriteSEIColourTransformInfo(const SEIColourTransformInfo& sei); -#endif void xWriteSEIAnnotatedRegions (const SEIAnnotatedRegions& sei); void xWriteSEIpayloadData(OutputBitstream &bs, const SEI& sei, HRD &hrd, const uint32_t temporalId); void xWriteByteAlign();