Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • jvet-tuc/VVCSoftware_VTM
  • tlu/vvc-software-vtm-tuc
  • hendry197/vvc-software-vtm-tuc
  • jeeva.raj/vvc-software-vtm-tu-c-2
  • ksuehring/vvc-software-vtm-tuc
  • jiechen/vvc-software-vtm-tuc
  • sw.xie/adaptive-film-grain-models
  • Kaifa/vvc-software-vtm-tuc
  • hallapur/vvc-software-vtm-tuc
  • biatekt/vvc-software-vtm-tmuc
  • pbcowan/vvc-software-vtm-tuc
11 results
Show changes
Showing
with 3269 additions and 531 deletions
#======== SEI messages processing order ===============
SEIPOEnabled : 1 #Enabling SEI processing order flag
SEIPOPayLoadType : 4 19 142 211 4 #SEI PayloadTypes to be processed
SEIPOProcessingOrder : 3 2 1 0 4 #Processing order of SEI payload types
SEIPONumofPrefixByte : 6 0 0 0 5
SEIPOPrefixByte : 0 60 0 1 4 1 181 0 59 0 9
SEIPOEnabled : 1 #Enabling SEI processing order flag.
SEIPONumMinus2 : 2 #Number of SEIs minus2 in SEI PO SEI
SEIPOWrappingFlag : 0 1 1 0 #Wrapping flag, 1: SEI is carried inside SEI PO SEI (specify SEI parameters after SEIPOPrefixByte); 0: SEI is carried outside SEI PO SEI
SEIPOImportanceFlag : 1 0 0 0 #importance flag
SEIPOPrefixFlag : 0 0 0 1
SEIPOPayLoadType : 142 144 149 4 #SEI PayloadTypes to be processed: 142: CTI SEI, 144:CLL SEI, 149:CCV, 4:T35 user registered SEI
SEIPOProcessingOrder : 0 1 1 2 #Processing order of SEI payload types
SEIPONumofPrefixByte : 0 0 0 6
SEIPOPrefixByte : 0 60 0 1 4 1
SEICLLMaxContentLightLevel : 4000 #start SEI paramters related to 144 (wrapped), parameters are same as content_light_level.cfg
SEICLLMaxPicAvgLightLevel : 600 #end SEI parameters related to 144 (wrapped)
SEICCVCancelFlag : 0 #start SEI parameters related to 149 (wrapped), parameters are same as content_colour_volume.cfg
SEICCVPersistenceFlag : 1
SEICCVPrimariesPresent : 1
m_ccvSEIPrimariesX0 : 0.300
m_ccvSEIPrimariesY0 : 0.600
m_ccvSEIPrimariesX1 : 0.150
m_ccvSEIPrimariesY1 : 0.060
m_ccvSEIPrimariesX2 : 0.640
m_ccvSEIPrimariesY2 : 0.330
SEICCVMinLuminanceValuePresent : 1
SEICCVMinLuminanceValue : 0.0
SEICCVMaxLuminanceValuePresent : 1
SEICCVMaxLuminanceValue : 0.1
SEICCVAvgLuminanceValuePresent : 1
SEICCVAvgLuminanceValue : 0.01 #end SEI parameters related to 149 (wrapped)
#======== SEI messages processing order ===============
# SEIPOEnabled : 1 #Enabling SEI processing order flag
# SEIPONumMinus2 : 2 #Number of SEIs minus2 in SEI PO SEI
# SEIPOWrappingFlag : 0 0 0 0 #Wrapping flag
# SEIPOImportanceFlag : 1 1 0 0 #importance flag
# SEIPOPrefixFlag : 1 1 0 0
# SEIPOPayLoadType : 4 4 211 19 #SEI PayloadTypes to be processed
# SEIPOProcessingOrder : 0 0 1 2 #Processing order of SEI payload types
# SEIPONumofPrefixByte : 6 5 0 0
# SEIPOPrefixByte : 0 60 0 1 4 1 181 0 59 0 9
#add 2 more T35 SEIs to test prefix cases
# T35 (HDR10+): 0x00 0x3c 0x00 0x01 0x4 0x1
......
#======== Exif metadata SEI message =====================
SEIXmpEnabled : 1 # enable to use Xmp SEI message.
SEIXmpCancelFlag : 0 # to cancel an active Xmp SEI message
SEIXmpPersistenceFlag : 1 # to enable persistence beyond a single picture; otherwise 0 for per-picture persistence
SEIXmpData : 00 58 4D 50 46 00 4D 4D 00 2A 00 00 00 08 00 03 B0 00 00 07 00 00 00 04 30 31 30 30 B0 01 00 04 00 00 00 01 00 00 00 02 B0 02 00 07 00 00 00 20 00 00 00 32 00 00 00 00 00 03 00 00 00 23 77 50 00 00 00 00 00 00 00 00 00 00 00 00 00 01 5F 82 00 23 50 C1 00 00 00 00
No preview for this file type
This diff is collapsed.
......@@ -573,7 +573,6 @@ uint32_t BitstreamExtractorApp::decode()
bitstreamFileIn.clear();
bitstreamFileIn.seekg( 0, std::ios::beg );
int unitCnt = 0;
bool lastSliceWritten= false; // stores status of previous slice for associated filler data NAL units
VPS *vpsIdZero = new VPS();
......@@ -886,7 +885,6 @@ uint32_t BitstreamExtractorApp::decode()
{
m_prevPicPOC = slice.getPOC();
}
unitCnt++;
if( writeInpuNalUnitToStream )
{
......
......@@ -42,8 +42,7 @@
#include "CommonLib/dtrace_next.h"
#endif
namespace po = df::program_options_lite;
namespace po = ProgramOptionsLite;
// ====================================================================================================================
// Public member functions
......
......@@ -54,10 +54,10 @@ int main(int argc, char* argv[])
fprintf( stdout, NVM_BITS );
#if ENABLE_SIMD_OPT
std::string SIMD;
df::program_options_lite::Options optsSimd;
ProgramOptionsLite::Options optsSimd;
optsSimd.addOptions()( "SIMD", SIMD, std::string( "" ), "" );
df::program_options_lite::SilentReporter err;
df::program_options_lite::scanArgv( optsSimd, argc, ( const char** ) argv, err );
ProgramOptionsLite::SilentReporter err;
ProgramOptionsLite::scanArgv(optsSimd, argc, (const char**) argv, err);
fprintf( stdout, "[SIMD=%s] ", read_x86_extension( SIMD ) );
#endif
#if ENABLE_TRACING
......
This diff is collapsed.
......@@ -56,15 +56,31 @@
class DecApp : public DecAppCfg
{
private:
static constexpr auto DEFAULT_FRAME_RATE = Fraction{ 50, 1 };
// class interface
DecLib m_cDecLib; ///< decoder class
std::unordered_map<int, VideoIOYuv> m_cVideoIOYuvReconFile; ///< reconstruction YUV class
std::unordered_map<int, VideoIOYuv> m_videoIOYuvSEIFGSFile; ///< reconstruction YUV with FGS class
std::unordered_map<int, VideoIOYuv> m_cVideoIOYuvSEICTIFile; ///< reconstruction YUV with CTI class
#if JVET_AI0181
std::unordered_map<int, VideoIOYuv> m_videoIOYuvSEIDOIFile; ///< reconstruction YUV with DOI class
int m_idxSEIDOI; ///< Index of the SEI DOI to be processed
int m_doiSEILastProcessedOverlay; ///< Index of the SEI DOI to be processed
Pel* m_doiSEIPelY;
Pel* m_doiSEIPelU;
Pel* m_doiSEIPelV;
#endif
#if JVET_Z0120_SII_SEI_PROCESSING
bool m_ShutterFilterEnable; ///< enable Post-processing with Shutter Interval SEI
VideoIOYuv m_cTVideoIOYuvSIIPostFile; ///< post-filtered YUV class
#if JVET_AF0167_MULTI_PLANE_IMAGE_INFO_SEI
VideoIOYuv m_VideoIOTextureYuvReconFile; ///< Reconstructed MPII texture layered YUV
VideoIOYuv m_VideoIOOpacityYuvReconFile; ///< Reconstructed MPII opacity layered YUV
SEIMultiplaneImageInfo m_mpiiInfo;
bool m_textureOpacityToggle;
bool m_MultiPlaneImageInfoEnable;
#endif
int m_SII_BlendingRatio;
struct IdrSiiInfo
......@@ -76,7 +92,6 @@ private:
std::map<uint32_t, IdrSiiInfo> m_activeSiiInfo;
#endif
// for output control
int m_iPOCLastDisplay; ///< last POC in display order
......@@ -90,6 +105,10 @@ private:
std::map<uint32_t, SEIAnnotatedRegions::AnnotatedRegionObject> m_arObjects; ///< AR object pool
std::map<uint32_t, std::string> m_arLabels; ///< AR label pool
#if JVET_AF0088_OMI_SEI
SEIObjectMaskInfos::ObjectMaskInfoHeader m_omiHeader; ///< OMI header
#endif
private:
bool xIsNaluWithinTargetDecLayerIdSet( const InputNALUnit* nalu ) const; ///< check whether given Nalu is within targetDecLayerIdSet
bool xIsNaluWithinTargetOutputLayerIdSet( const InputNALUnit* nalu ) const; ///< check whether given Nalu is within targetOutputLayerIdSet
......@@ -99,11 +118,15 @@ public:
virtual ~DecApp () {}
uint32_t decode (); ///< main decoding function
#if JVET_Z0120_SII_SEI_PROCESSING
bool getShutterFilterFlag() const { return m_ShutterFilterEnable; }
void setShutterFilterFlag(bool value) { m_ShutterFilterEnable = value; }
int getBlendingRatio() const { return m_SII_BlendingRatio; }
void setBlendingRatio(int value) { m_SII_BlendingRatio = value; }
#if JVET_AF0167_MULTI_PLANE_IMAGE_INFO_SEI
void xUnpackTextureLayer(Picture* pcPic);
void xUnpackOpacityLayer(Picture* pcPic);
void setMultiPlaneImageInfoFlag(bool value) { m_MultiPlaneImageInfoEnable = value; }
bool getMultiPlaneImageInfoFlag() const { return m_MultiPlaneImageInfoEnable; }
#endif
private:
......@@ -120,6 +143,16 @@ private:
void writeLineToOutputLog(Picture * pcPic);
void xOutputAnnotatedRegions(PicList* pcListPic);
#if JVET_AF0088_OMI_SEI
void xOutputObjectMaskInfos(Picture* pcPic);
#endif
#if JVET_AH0161_REGION_PACKING_INFORMATION_SEI
void xOutputPackedRegionsInfo(Picture* pcPic);
void xOutputPackedRegionsInfoVector(FILE* fp, const char* paramName, const std::vector<uint32_t>& v);
#endif
#if JVET_AI0181
void xGenerateTargetPicture(Picture* pcPic);
#endif
};
//! \}
......
......@@ -44,7 +44,7 @@
#include "CommonLib/ChromaFormat.h"
#include "CommonLib/dtrace_next.h"
namespace po = df::program_options_lite;
namespace po = ProgramOptionsLite;
//! \ingroup DecoderApp
//! \{
......@@ -87,10 +87,11 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
("OutputBitDepth,d", m_outputBitDepth[ChannelType::LUMA], 0, "bit depth of YUV output luma component (default: use 0 for native depth)")
("OutputBitDepthC,d", m_outputBitDepth[ChannelType::CHROMA], 0, "bit depth of YUV output chroma component (default: use luma output bit-depth)")
("OutputColourSpaceConvert", outputColourSpaceConvert, std::string(""), "Colour space conversion to apply to input 444 video. Permitted values are (empty string=UNCHANGED) " + getListOfColourSpaceConverts(false))
("MaxTemporalLayer,t", m_iMaxTemporalLayer, 500, "Maximum Temporal Layer to be decoded. -1 to decode all layers")
("MaxTemporalLayer,t", m_maxTemporalLayer, TL_UNDEFINED, "Maximum Temporal Layer to be decoded. -1 to decode all layers")
("TargetOutputLayerSet,p", m_targetOlsIdx, 500, "Target output layer set index")
#if JVET_Z0120_SII_SEI_PROCESSING
("SEIShutterIntervalPostFilename,-sii", m_shutterIntervalPostFileName, std::string(""), "Post Filtering with Shutter Interval SEI. If empty, no filtering is applied (ignore SEI message)\n")
#if JVET_AF0167_MULTI_PLANE_IMAGE_INFO_SEI
("SEIMultiplaneImageInfoFilename,-mpii", m_multiplaneImageInfoFileName, std::string(""), "MPII output filename prefix. If empty, no MPI de packing is applied (ignore SEI message) \n")
#endif
("SEIDecodedPictureHash,-dph", m_decodedPictureHashSEIEnabled, 1, "Control handling of decoded picture hash SEI messages\n"
"\t1: check hash in SEI messages if available in the bitstream\n"
......@@ -101,12 +102,22 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
("SEICTIFilename", m_SEICTIFileName, std::string(""), "CTI YUV output file name. If empty, no Colour Transform is applied (ignore SEI message)\n")
("SEIFGSFilename", m_SEIFGSFileName, std::string(""), "FGS YUV output file name. If empty, no film grain is applied (ignore SEI message)\n")
("SEIAnnotatedRegionsInfoFilename", m_annotatedRegionsSEIFileName, std::string(""), "Annotated regions output file name. If empty, no object information will be saved (ignore SEI message)\n")
#if JVET_AF0088_OMI_SEI
("SEIObjectMaskInfosFilename", m_objectMaskInfoSEIFileName, std::string(""), "Object mask information output file name. If empty, no object mask information will be saved (ignore SEI message)\n")
#endif
("OutputDecodedSEIMessagesFilename", m_outputDecodedSEIMessagesFilename, std::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
("360DumpFile", m_outputDecoded360SEIMessagesFilename, std::string(""), "When non empty, output decoded 360 SEI messages to the indicated file.\n")
#endif
#if JVET_AH0161_REGION_PACKING_INFORMATION_SEI
("SEIPackedRegionsInfoFilename", m_packedRegionsInfoSEIFileName, std::string(""), "Packed regions info output file name. If empty, no object information will be saved\n")
#endif
("ClipOutputVideoToRec709Range", m_clipOutputVideoToRec709Range, false, "If true then clip output video to the Rec. 709 Range on saving")
("PYUV", m_packedYUVMode, false, "If true then output 10-bit and 12-bit YUV data as 5-byte and 3-byte (respectively) packed YUV data. Ignored for interlaced output.")
#if JVET_AI0181
("SEIDOIId", m_SEIDOIId, -1, "Specifies the DOI SEI id which should be used to generate output picture with overlay embedded.")
("SEIDOIFilename", m_SEIDOIFileName, std::string(""), "DOI YUV output file name. If empty, no overlay is applied (ignore SEI message).\n")
#endif
#if ENABLE_TRACING
("TraceChannelsList", bTracingChannelsList, false, "List all available tracing channels")
("TraceRule", sTracingRule, std::string(""), "Tracing rule (ex: \"D_CABAC:poc==8\" or \"D_REC_CB_LUMA:poc==8\")")
......@@ -129,7 +140,7 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
#endif
("MCTSCheck", m_mctsCheck, false, "If enabled, the decoder checks for violations of mc_exact_sample_value_match_flag in Temporal MCTS ")
("targetSubPicIdx", m_targetSubPicIdx, 0, "Specify which subpicture shall be written to output, using subpic index, 0: disabled, subpicIdx=m_targetSubPicIdx-1 \n" )
( "UpscaledOutput", m_upscaledOutput, 0, "Upscaled output for RPR" )
("UpscaledOutput", m_upscaledOutput, 0, "Output upscaled (2), decoded but in full resolution buffer (1) or decoded cropped (0, default) picture for RPR" )
("UpscaleFilterForDisplay", m_upscaleFilterForDisplay, 1, "Filters used for upscaling reconstruction to full resolution (2: ECM 12 - tap luma and 6 - tap chroma MC filters, 1 : Alternative 12 - tap luma and 6 - tap chroma filters, 0 : VVC 8 - tap luma and 4 - tap chroma MC filters)")
#if GDR_LEAK_TEST
("RandomAccessPos", m_gdrPocRandomAccess, 0, "POC of GDR Random access picture\n")
......@@ -235,14 +246,13 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
msg( ERROR, "File %s could not be opened. Using all LayerIds as default.\n", cfg_TargetDecLayerIdSetFile.c_str() );
}
}
if (m_iMaxTemporalLayer != 500)
{
m_mTidExternalSet = true;
}
else
m_mTidExternalSet = m_maxTemporalLayer != TL_UNDEFINED;
if (!m_mTidExternalSet)
{
m_iMaxTemporalLayer = -1;
m_maxTemporalLayer = TL_INFINITY;
}
if ( m_targetOlsIdx != 500)
{
m_tOlsIdxTidExternalSet = true;
......@@ -256,32 +266,37 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
}
DecAppCfg::DecAppCfg()
: m_bitstreamFileName()
, m_reconFileName()
, m_oplFilename()
: m_bitstreamFileName()
, m_reconFileName()
, m_oplFilename()
, m_iSkipFrame(0)
// m_outputBitDepth array initialised below
, m_outputColourSpaceConvert(IPCOLOURSPACE_UNCHANGED)
, m_targetOlsIdx(0)
, m_iMaxTemporalLayer(-1)
, m_mTidExternalSet(false)
, m_tOlsIdxTidExternalSet(false)
, m_decodedPictureHashSEIEnabled(0)
, m_decodedNoDisplaySEIEnabled(false)
, m_colourRemapSEIFileName()
, m_SEICTIFileName()
, m_SEIFGSFileName()
, m_annotatedRegionsSEIFileName()
, m_targetDecLayerIdSet()
, m_outputDecodedSEIMessagesFilename()
, m_iSkipFrame(0)
// m_outputBitDepth array initialised below
, m_outputColourSpaceConvert(IPCOLOURSPACE_UNCHANGED)
, m_targetOlsIdx(0)
, m_tOlsIdxTidExternalSet(false)
, m_decodedPictureHashSEIEnabled(0)
, m_decodedNoDisplaySEIEnabled(false)
, m_colourRemapSEIFileName()
, m_SEICTIFileName()
, m_SEIFGSFileName()
, m_annotatedRegionsSEIFileName()
#if JVET_AF0088_OMI_SEI
, m_objectMaskInfoSEIFileName()
#endif
, m_targetDecLayerIdSet()
, m_outputDecodedSEIMessagesFilename()
#if JVET_S0257_DUMP_360SEI_MESSAGE
, m_outputDecoded360SEIMessagesFilename()
, m_outputDecoded360SEIMessagesFilename()
#endif
, m_clipOutputVideoToRec709Range(false)
, m_packedYUVMode(false)
, m_statMode(0)
, m_mctsCheck(false)
#if JVET_AI0181
, m_SEIDOIId(-1)
, m_SEIDOIFileName()
#endif
, m_clipOutputVideoToRec709Range(false)
, m_packedYUVMode(false)
, m_statMode(0)
, m_mctsCheck(false)
{
m_outputBitDepth.fill(0);
}
......
......@@ -54,6 +54,9 @@
class DecAppCfg
{
protected:
static constexpr int TL_INFINITY = -1; // All temporal layers
static constexpr int TL_UNDEFINED = MAX_INT;
std::string m_bitstreamFileName; ///< input bitstream file name
std::string m_reconFileName; ///< output reconstruction file name
......@@ -65,8 +68,9 @@ protected:
InputColourSpaceConversion m_outputColourSpaceConvert;
int m_targetOlsIdx; ///< target output layer set
std::vector<int> m_targetOutputLayerIdSet; ///< set of LayerIds to be outputted
int m_iMaxTemporalLayer; ///< maximum temporal layer to be decoded
bool m_mTidExternalSet; ///< maximum temporal layer set externally
int m_maxTemporalLayer = TL_INFINITY; // maximum temporal layer to be decoded
bool m_mTidExternalSet = false; // maximum temporal layer set externally
bool m_tOlsIdxTidExternalSet; ///< target output layer set index externally set
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
......@@ -74,21 +78,31 @@ protected:
std::string m_SEICTIFileName; ///< output Recon with CTI file name
std::string m_SEIFGSFileName; ///< output file name for reconstructed sequence with film grain
std::string m_annotatedRegionsSEIFileName; ///< annotated regions file name
#if JVET_AF0088_OMI_SEI
std::string m_objectMaskInfoSEIFileName; ///< object mask information file name
#endif
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.
#if JVET_S0257_DUMP_360SEI_MESSAGE
std::string m_outputDecoded360SEIMessagesFilename; ///< filename to output decoded 360 SEI messages to.
#endif
#if JVET_AH0161_REGION_PACKING_INFORMATION_SEI
std::string m_packedRegionsInfoSEIFileName; ///< packed regions file name
#endif
#if JVET_Z0120_SII_SEI_PROCESSING
std::string m_shutterIntervalPostFileName; ///< output Post Filtering file name
#if JVET_AF0167_MULTI_PLANE_IMAGE_INFO_SEI
std::string m_multiplaneImageInfoFileName; ///< Output MPII file name prefix
#endif
bool m_clipOutputVideoToRec709Range; ///< If true, clip the output video to the Rec 709 range on saving.
bool m_packedYUVMode; ///< If true, output 10-bit and 12-bit YUV data as 5-byte and 3-byte (respectively) packed YUV data
std::string m_cacheCfgFile; ///< Config file of cache model
int m_statMode; ///< Config statistic mode (0 - bit stat, 1 - tool stat, 3 - both)
bool m_mctsCheck;
#if JVET_AI0181
int m_SEIDOIId; // If != -1, specifies the DOI SEI id (doi_id) that should be targeted to reconstruct output layer
std::string m_SEIDOIFileName; ///< output file name for reconstructed sequence with display overlays
#endif
#if GREEN_METADATA_SEI_ENABLED
bool m_GMFA;
std::string m_GMFAFile;
......
......@@ -60,10 +60,10 @@ int main(int argc, char* argv[])
fprintf( stdout, NVM_BITS );
#if ENABLE_SIMD_OPT
std::string SIMD;
df::program_options_lite::Options optsSimd;
ProgramOptionsLite::Options optsSimd;
optsSimd.addOptions()("SIMD", SIMD, std::string(""), "");
df::program_options_lite::SilentReporter err;
df::program_options_lite::scanArgv( optsSimd, argc, ( const char** ) argv, err );
ProgramOptionsLite::SilentReporter err;
ProgramOptionsLite::scanArgv(optsSimd, argc, (const char**) argv, err);
fprintf( stdout, "[SIMD=%s] ", read_x86_extension( SIMD ) );
#endif
#if ENABLE_TRACING
......
This diff is collapsed.
......@@ -71,9 +71,7 @@ private:
EncLib m_cEncLib; ///< encoder class
VideoIOYuv m_cVideoIOYuvInputFile; ///< input YUV file
VideoIOYuv m_cVideoIOYuvReconFile; ///< output reconstruction file
#if JVET_Z0120_SII_SEI_PROCESSING
VideoIOYuv m_cTVideoIOYuvSIIPreFile; ///< output pre-filtered file
#endif
int m_frameRcvd; ///< number of received frames
uint32_t m_essentialBytes;
uint32_t m_totalBytes;
......@@ -101,14 +99,10 @@ private:
PelStorage* m_orgPic;
PelStorage* m_trueOrgPicBeforeScale;
PelStorage* m_orgPicBeforeScale;
PelStorage* m_filteredOrgPic;
PelStorage* m_rprPic[2];
#if EXTENSION_360_VIDEO
TExt360AppEncTop* m_ext360;
#endif
EncTemporalFilter m_temporalFilter;
PelStorage* m_filteredOrgPicForFG;
EncTemporalFilter m_temporalFilterForFG;
bool m_flush;
#if GREEN_METADATA_SEI_ENABLED
FeatureCounterStruct m_featureCounter;
......
This diff is collapsed.
......@@ -58,10 +58,12 @@ static inline std::istream& operator >> (std::istream &in, std::map<T1, T2> &map
#undef UNDEFINED
#endif
#endif
namespace po = df::program_options_lite;
namespace po = ProgramOptionsLite;
#include <sstream>
#include <vector>
#include <optional>
//! \ingroup EncoderApp
//! \{
......@@ -72,15 +74,6 @@ namespace po = df::program_options_lite;
/// encoder configuration class
class EncAppCfg
{
public:
template <class T>
struct OptionalValue
{
bool bPresent;
T value;
OptionalValue() : bPresent(false), value() { }
};
protected:
// file I/O
std::string m_inputFileName; ///< source file name
......@@ -118,6 +111,11 @@ protected:
int m_confWinRight;
int m_confWinTop;
int m_confWinBottom;
bool m_explicitScalingWindowEnabled;
int m_scalWinLeft;
int m_scalWinRight;
int m_scalWinTop;
int m_scalWinBottom;
int m_sourcePadding[2]; ///< number of padded pixels for width and height
int m_firstValidFrame;
int m_lastValidFrame;
......@@ -265,7 +263,8 @@ protected:
bool m_disableFastDecisionTT; ///< flag for disabling fast decision for TT from BT
// coding quality
OptionalValue<uint32_t> m_qpIncrementAtSourceFrame; ///< Optional source frame number at which all subsequent frames are to use an increased internal QP.
std::optional<uint32_t> m_qpIncrementAtSourceFrame; // Optional source frame number at which all subsequent frames
// are to use an increased internal QP.
int m_iQP; ///< QP value of key-picture (integer)
bool m_useIdentityTableForNon420Chroma;
ChromaQpMappingTableParams m_chromaQpMappingTableParams;
......@@ -354,8 +353,8 @@ protected:
bool m_PROF;
bool m_BIO;
int m_LMChroma;
bool m_horCollocatedChromaFlag;
bool m_verCollocatedChromaFlag;
int m_horCollocatedChromaFlag;
int m_verCollocatedChromaFlag;
int m_mtsMode; ///< XZ: Multiple Transform Set
int m_MTSIntraMaxCand; ///< XZ: Number of additional candidates to test
......@@ -395,6 +394,9 @@ protected:
unsigned m_IBCHashSearchMaxCand;
unsigned m_IBCHashSearchRange4SmallBlk;
unsigned m_IBCFastMethod;
bool m_dmvrEncSelect;
int m_dmvrEncSelectBaseQpTh;
bool m_dmvrEncSelectDisableHighestTemporalLayer;
bool m_wrapAround;
unsigned m_wrapAroundOffset;
......@@ -419,6 +421,7 @@ protected:
unsigned m_maxCuHeight; ///< max. CU height in pixel
unsigned m_log2MinCuSize; ///< min. CU size log2
bool m_useMttSkip;
bool m_useFastLCTU;
bool m_usePbIntraFast;
bool m_useAMaxBT;
......@@ -604,6 +607,9 @@ protected:
std::vector<uint32_t> m_sdiSEIViewIdVal;
std::vector<uint32_t> m_sdiSEIAuxId;
std::vector<uint32_t> m_sdiSEINumAssociatedPrimaryLayersMinus1;
#if JVET_AF0088_OMI_SEI
std::vector<uint32_t> m_sdiSEIAssociatedPrimaryLayerIdx;
#endif
// multiview acquisition information sei
bool m_maiSEIEnabled;
bool m_maiSEIIntrinsicParamFlag;
......@@ -685,6 +691,9 @@ protected:
std::vector<uint32_t> m_omniViewportSEIHorRange;
std::vector<uint32_t> m_omniViewportSEIVerRange;
std::string m_arSEIFileRoot; // Annotated region SEI - initialized from external file
#if JVET_AF0088_OMI_SEI
std::string m_omiSEIFileRoot; // Object mask information SEI - initialized from external file
#endif
bool m_rwpSEIEnabled;
bool m_rwpSEIRwpCancelFlag;
bool m_rwpSEIRwpPersistenceFlag;
......@@ -730,6 +739,7 @@ protected:
EncCfgParam::CfgSEISubpictureLevel m_cfgSubpictureLevelInfoSEI;
bool m_nnPostFilterSEICharacteristicsEnabled;
bool m_nnPostFilterSEICharacteristicsUseSuffixSEI;
int m_nnPostFilterSEICharacteristicsNumFilters;
uint32_t m_nnPostFilterSEICharacteristicsId[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsModeIdc[MAX_NUM_NN_POST_FILTERS];
......@@ -738,8 +748,10 @@ protected:
uint32_t m_nnPostFilterSEICharacteristicsPurpose[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsOutSubCFlag[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsOutColourFormatIdc[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicWidthInLumaSamples[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicHeightInLumaSamples[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicWidthNumerator[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicWidthDenominator[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicHeightNumerator[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPicHeightDenominator[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsInpTensorBitDepthLumaMinus8[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsInpTensorBitDepthChromaMinus8[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsOutTensorBitDepthLumaMinus8[MAX_NUM_NN_POST_FILTERS];
......@@ -748,6 +760,9 @@ protected:
uint32_t m_nnPostFilterSEICharacteristicsInpFormatIdc[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsAuxInpIdc[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsSepColDescriptionFlag[MAX_NUM_NN_POST_FILTERS];
#if JVET_AD0067_INCLUDE_SYNTAX
bool m_nnPostFilterSEICharacteristicsFullRangeFlag[MAX_NUM_NN_POST_FILTERS];
#endif
uint32_t m_nnPostFilterSEICharacteristicsColPrimaries[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsTransCharacteristics[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsMatrixCoeffs[MAX_NUM_NN_POST_FILTERS];
......@@ -755,6 +770,8 @@ protected:
uint32_t m_nnPostFilterSEICharacteristicsOutFormatIdc[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsOutOrderIdc[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsConstantPatchSizeFlag[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsChromaLocInfoPresentFlag[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsChromaSampleLocTypeFrame[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPatchWidthMinus1[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsPatchHeightMinus1[MAX_NUM_NN_POST_FILTERS];
uint32_t m_nnPostFilterSEICharacteristicsExtendedPatchWidthCdDeltaMinus1[MAX_NUM_NN_POST_FILTERS];
......@@ -775,17 +792,24 @@ protected:
uint32_t m_nnPostFilterSEICharacteristicsTotalKilobyteSize[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEIActivationEnabled;
bool m_nnPostFilterSEIActivationUseSuffixSEI;
uint32_t m_nnPostFilterSEIActivationTargetId;
uint32_t m_nnPostFilterSEICharacteristicsNumberInputDecodedPicturesMinus1[MAX_NUM_NN_POST_FILTERS];
std::vector<uint32_t> m_nnPostFilterSEICharacteristicsNumberInterpolatedPictures[MAX_NUM_NN_POST_FILTERS];
std::vector<bool> m_nnPostFilterSEICharacteristicsInputPicOutputFlag[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEICharacteristicsAbsentInputPicZeroFlag[MAX_NUM_NN_POST_FILTERS];
bool m_nnPostFilterSEIActivationCancelFlag;
bool m_nnPostFilterSEIActivationTargetBaseFlag;
bool m_nnPostFilterSEIActivationNoPrevCLVSFlag;
bool m_nnPostFilterSEIActivationNoFollCLVSFlag;
bool m_nnPostFilterSEIActivationPersistenceFlag;
std::vector<bool> m_nnPostFilterSEIActivationOutputFlag;
bool m_poSEIEnabled;
#if JVET_AD0386_SEI
uint32_t m_poSEINumMinus2;
std::vector<bool> m_poSEIWrappingFlag;
std::vector<bool> m_poSEIImportanceFlag;
std::vector<bool> m_poSEIPrefixFlag;
#endif
std::vector<uint16_t> m_poSEIPayloadType;
std::vector<uint16_t> m_poSEIProcessingOrder;
std::vector<std::vector<uint8_t>> m_poSEIPrefixByte;
......@@ -800,6 +824,59 @@ protected:
bool m_postFilterHintSEIChromaCoeffPresentFlag;
std::vector<int32_t> m_postFilterHintValues;
#if JVET_AH0162_CONSTITUENT_RECTANGLES
bool m_crSEIEnabled;
uint32_t m_crSEINumRectsMinus1;
bool m_crSEIRectIdPresentFlag;
uint32_t m_crSEIRectIdLen;
bool m_crSEIRectTypeEnabledFlag;
bool m_crSEIRectTypeDescriptionsEnabledFlag;
bool m_crSEISubpicsPartitioningFlag;
bool m_crSEIRectSameSizeFlag;
uint32_t m_crSEINumColsMinus1;
uint32_t m_crSEINumRowsMinus1;
uint32_t m_crSEILog2UnitSize;
uint32_t m_crSEIRectSizeLenMinus1;
std::vector<bool> m_crSEIRectTypePresentFlag;
std::vector<uint8_t> m_crSEIRectTypeIdc;
std::vector<uint32_t> m_crSEIRectId;
std::vector<bool> m_crSEIRectTypeDescriptionPresentFlag;
std::vector<uint32_t> m_crSEIRectTopLeftInUnitsX;
std::vector<uint32_t> m_crSEIRectTopLeftInUnitsY;
std::vector<uint32_t> m_crSEIRectWidthInUnitsMinus1;
std::vector<uint32_t> m_crSEIRectHeightInUnitsMinus1;
std::string m_crSEIRectTypeDescription[MAX_RECT_TYPE_DESCRIPTIONS];
#endif
#if JVET_AI0181
// Display overlays info
bool m_doiSEIEnabled;
uint32_t m_doiSEIId;
bool m_doiSEICancelFlag;
bool m_doiSEIPersistenceFlag;
uint32_t m_doiSEINumDisplayOverlaysMinus2;
bool m_doiSEINuhLayerIdPresentFlag;
bool m_doiSEITargetPicSizePresentFlag;
uint32_t m_doiSEITargetPicWidthMinus1;
uint32_t m_doiSEITargetPicHeightMinus1;
bool m_doiSEIPicPartitionFlag;
bool m_doiSEIPartitionTypeFlag;
uint32_t m_doiSEIPartitionIdLenMinus1;
bool m_doiSEIOffsetParamsPresentFlag;
uint32_t m_doiSEIOffsetParamsLengthMinus1;
bool m_doiSEIResamplingEnabledFlag;
uint32_t m_doiSEISizeParamLengthMinus1;
int m_doiSEINuhLayerId[MAX_DISPLAY_OVERLAYS];
int m_doiSEIPartitionId[MAX_DISPLAY_OVERLAYS];
int m_doiSEIAlphaPresentFlag[MAX_DISPLAY_OVERLAYS];
int m_doiSEIAlphaNuhLayerId[MAX_DISPLAY_OVERLAYS];
int m_doiSEIAlphaPartitionId[MAX_DISPLAY_OVERLAYS];
int m_doiSEITopLeftX[MAX_DISPLAY_OVERLAYS];
int m_doiSEITopLeftY[MAX_DISPLAY_OVERLAYS];
int m_doiSEIWidthMinus1[MAX_DISPLAY_OVERLAYS];
int m_doiSEIHeightMinus1[MAX_DISPLAY_OVERLAYS];
#endif
bool m_constrainedRaslEncoding;
bool m_sampleAspectRatioInfoSEIEnabled;
......@@ -845,16 +922,20 @@ protected:
int m_TMVPModeId;
bool m_depQuantEnabledFlag;
bool m_signDataHidingEnabledFlag;
bool m_RCEnableRateControl; ///< enable rate control or not
int m_RCTargetBitrate; ///< target bitrate when rate control is enabled
int m_RCKeepHierarchicalBit; ///< 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit allocation
bool m_RCLCULevelRC; ///< true: LCU level rate control; false: picture level rate control NOTE: code-tidy - rename to m_RCCtuLevelRC
bool m_RCUseLCUSeparateModel; ///< use separate R-lambda model at LCU level NOTE: code-tidy - rename to m_RCUseCtuSeparateModel
int m_RCInitialQP; ///< inital QP for rate control
bool m_RCForceIntraQP; ///< force all intra picture to use initial QP or not
bool m_RCCpbSaturationEnabled; ///< enable target bits saturation to avoid CPB overflow and underflow
uint32_t m_RCCpbSize; ///< CPB size
double m_RCInitialCpbFullness; ///< initial CPB fullness
// Rate control
bool m_rcEnableRateControl; // enable rate control or not
int m_rcTargetBitrate; // target bitrate when rate control is enabled
int m_rcKeepHierarchicalBit; // 0: equal bit allocation; 1: fixed ratio bit allocation; 2: adaptive ratio bit
// allocation
bool m_rcCtuLevelRateControl; // true: CTU level rate control; false: picture level rate control
bool m_rcUseCtuSeparateModel; // use separate R-lambda model at CTU level
int m_rcInitialQp; // inital QP for rate control
bool m_rcForceIntraQp; // force all intra picture to use initial QP or not
bool m_rcCpbSaturationEnabled; // enable target bits saturation to avoid CPB overflow and underflow
uint32_t m_rcCpbSize; // CPB size
double m_rcInitialCpbFullness; // initial CPB fullness
ScalingListMode m_useScalingListId; ///< using quantization matrix
std::string m_scalingListFileName; ///< quantization matrix file name
bool m_disableScalingMatrixForLfnstBlks;
......@@ -868,6 +949,7 @@ protected:
bool m_DCIEnabled; ///< enable Decoding Capability Information (DCI)
bool m_hrdParametersPresentFlag; ///< enable generation of HRD parameters
bool m_vuiParametersPresentFlag; ///< enable generation of VUI parameters
bool m_writeVuiHrdFromY4m; ///< allow writing VUI and HRD information from input Y4M file
bool m_samePicTimingInAllOLS; ///< same picture timing SEI message is used in all OLS
bool m_aspectRatioInfoPresentFlag; ///< Signals whether aspect_ratio_idc is present
int m_aspectRatioIdc; ///< aspect_ratio_idc
......@@ -880,9 +962,9 @@ protected:
bool m_progressiveSourceFlag; ///< Indicates if the content is progressive
bool m_interlacedSourceFlag; ///< Indicates if the content is interlaced
bool m_chromaLocInfoPresentFlag; ///< Signals whether chroma_sample_loc_type_top_field and chroma_sample_loc_type_bottom_field are present
int m_chromaSampleLocTypeTopField; ///< Specifies the location of chroma samples for top field
int m_chromaSampleLocTypeBottomField; ///< Specifies the location of chroma samples for bottom field
int m_chromaSampleLocType; ///< Specifies the location of chroma samples for progressive content
Chroma420LocType m_chromaSampleLocTypeTopField; // Specifies the location of chroma samples for top field
Chroma420LocType m_chromaSampleLocTypeBottomField; // Specifies the location of chroma samples for bottom field
Chroma420LocType m_chromaSampleLocType; // Specifies the location of chroma samples for progressive content
bool m_overscanInfoPresentFlag; ///< Signals whether overscan_appropriate_flag is present
bool m_overscanAppropriateFlag; ///< Indicates whether conformant decoded pictures are suitable for display using overscan
bool m_videoFullRangeFlag; ///< Indicates the black level and range of luma and chroma signals
......@@ -893,11 +975,18 @@ protected:
uint32_t m_siiSEINumUnitsInShutterInterval;
uint32_t m_siiSEITimeScale;
std::vector<uint32_t> m_siiSEISubLayerNumUnitsInSI;
#if JVET_Z0120_SII_SEI_PROCESSING
bool m_ShutterFilterEnable; ///< enable Pre-Filtering with Shutter Interval SEI
std::string m_shutterIntervalPreFileName; ///< output Pre-Filtering video
int m_SII_BlendingRatio;
void setBlendingRatioSII(int value) { m_SII_BlendingRatio = value; }
#if JVET_AF0167_MULTI_PLANE_IMAGE_INFO_SEI
bool m_mpiiSEIEnabled; ///< Enable multiplane image information
uint32_t m_mpiiNumLayers; ///< Number of mpi layers in a single frame
bool m_mpiiLayerDepthEqualDistanceFlag; ///< Indicates if all the mpi layers are at equal distance
std::vector<double> m_mpiiLayerDepthValues; ///< Layer depth values for each layer
bool m_mpiiTextureOpacityInterleaveFlag; ///< Indicates if texture and opacity are interleaved
bool m_mpiiTextureOpacityArrangementFlag; ///< Indicates if texture and opacity are arranged in 0 = TopBottom
uint32_t m_mpiiPictureNumLayersInHeight; ///< Number of layers in height
#endif
#if GREEN_METADATA_SEI_ENABLED
public:
......@@ -1041,6 +1130,103 @@ protected:
int m_cropOffsetBottom;
bool m_calculateHdrMetrics;
#endif
#if JVET_AF0141_IMAGE_METADATA_SEIS
bool m_exifSeiEnabled;
bool m_exifCancelFlag;
bool m_exifPersistenceFlag;
uint32_t m_exifMode;
std::string m_exifUri;
std::vector<uint8_t> m_exifData;
bool m_xmpSeiEnabled;
bool m_xmpCancelFlag;
bool m_xmpPersistenceFlag;
std::vector<uint8_t> m_xmpData;
bool m_jfifSeiEnabled;
bool m_jfifCancelFlag;
bool m_jfifPersistenceFlag;
uint32_t m_jfifType;
std::vector<uint8_t> m_jfifData;
#endif
#if JVET_AG0044_COPYRIGHT_SEI
bool m_copyrightSeiEnabled;
bool m_copyrightCancelFlag;
bool m_copyrightPersistenceFlag;
std::string m_copyrightInfoData;
#endif
#if JVET_AG0045_AI_MARKER_SEI
bool m_aiMarkerSeiEnabled;
bool m_aiMarkerCancelFlag;
bool m_aiMarkerPersistenceFlag;
std::string m_aiMarkerInfoData;
#endif
#if JVET_AH0161_REGION_PACKING_INFORMATION_SEI
bool m_priSEIEnabled;
bool m_priSEICancelFlag;
bool m_priSEIPersistenceFlag;
uint32_t m_priSEINumRegionsMinus1;
bool m_priSEIUseMaxDimensionsFlag;
uint32_t m_priSEILog2UnitSize;
uint32_t m_priSEIRegionSizeLenMinus1;
bool m_priSEIRegionIdPresentFlag;
bool m_priSEITargetPicParamsPresentFlag;
uint32_t m_priSEITargetPicWidthMinus1;
uint32_t m_priSEITargetPicHeightMinus1;
uint32_t m_priSEINumResamplingRatiosMinus1;
std::vector<uint32_t> m_priSEIResamplingWidthNumMinus1;
std::vector<uint32_t> m_priSEIResamplingWidthDenomMinus1;
std::vector<bool> m_priSEIFixedAspectRatioFlag;
std::vector<uint32_t> m_priSEIResamplingHeightNumMinus1;
std::vector<uint32_t> m_priSEIResamplingHeightDenomMinus1;
std::vector<uint32_t> m_priSEIRegionId;
std::vector<uint32_t> m_priSEIRegionTopLeftInUnitsX;
std::vector<uint32_t> m_priSEIRegionTopLeftInUnitsY;
std::vector<uint32_t> m_priSEIRegionWidthInUnitsMinus1;
std::vector<uint32_t> m_priSEIRegionHeightInUnitsMinus1;
std::vector<uint32_t> m_priSEIResamplingRatioIdx;
std::vector<uint32_t> m_priSEITargetRegionTopLeftX;
std::vector<uint32_t> m_priSEITargetRegionTopLeftY;
#endif
#if JVET_AH0164_QUALITY_METRIC_SEI
bool m_qmSEIEnabled;
bool m_qmSEIMetricDefinitionsPresentFlag;
bool m_qmSEIClvsValuesPresentFlag;
bool m_qmSEIPicValuesPresentFlag;
uint32_t m_qmSEINumMetricsMinus1;
bool m_qmSEIGainEnabledFlag;
std::vector<bool> m_qmSEIGainFlag;
std::vector<bool> m_qmSEIGainReferenceFlag;
std::vector<uint8_t> m_qmSEIMetricType;
std::vector<bool> m_qmSEIThreeComponentFlag;
std::vector<bool> m_qmSEIMetricIncreasingFlag;
std::vector<bool> m_qmSEIFullReferenceFlag;
std::vector<uint8_t> m_qmSEIValueLenMinus1InBytes;
std::vector<bool> m_qmSEIMetricDescriptionPresentFlag;
std::string m_qmSEIMetricDescription[MAX_NUM_QUALITY_METRICS];
std::vector<std::array<uint32_t, 3>> m_qmSEIClvsMetricValue;
std::vector<std::array<uint32_t, 3>> m_qmSEIPicMetricValue;
#endif
#if JVET_AI0182_BITDEPTH_RANGE_INFORMATION_SEI
bool m_briSEIEnabled;
uint32_t m_briSEIOrigBitDepthMinus1;
uint32_t m_briSEINumRangesMinus1;
bool m_briSEINuhLayerIdPresentFlag;
bool m_briSEIPicPartitionFlag;
bool m_briSEIPartitionTypeFlag;
uint32_t m_briSEIPartitionIdLenMinus1;
std::vector<uint32_t> m_briSEINuhLayerId;
std::vector<uint32_t> m_briSEIPartitionId;
std::vector<uint32_t> m_briSEINumBitsInRangeMinus1;
std::vector<uint32_t> m_briSEIBitOffset;
#endif
// internal member functions
bool xCheckParameter (); ///< check validity of configuration values
......@@ -1057,8 +1243,7 @@ public:
void create (); ///< create option handling class
void destroy (); ///< destroy option handling class
bool parseCfg ( int argc, char* argv[] ); ///< parse configuration file to fill member variables
};// END CLASS DEFINITION EncAppCfg
};
//! \}
......
......@@ -76,6 +76,31 @@ static void printMacroSettings()
}
}
#ifdef __linux
#include <cstdlib>
#include <cstdio>
#include <cstring>
int getProcStatusValue(const char* key)
{
FILE* file = fopen("/proc/self/status", "r");
int result = -1;
char line[128];
int len = strlen(key);
while (fgets(line, 128, file) != nullptr)
{
if (strncmp(line, key, len) == 0)
{
result = atoi(line+len);
break;
}
}
fclose(file);
return result;
}
#endif
// ====================================================================================================================
// Main function
// ====================================================================================================================
......@@ -90,10 +115,10 @@ int main(int argc, char* argv[])
fprintf( stdout, NVM_BITS );
#if ENABLE_SIMD_OPT
std::string SIMD;
df::program_options_lite::Options opts;
opts.addOptions()("SIMD", SIMD, std::string(""), "")("c", df::program_options_lite::parseConfigFile, "");
df::program_options_lite::SilentReporter err;
df::program_options_lite::scanArgv( opts, argc, ( const char** ) argv, err );
ProgramOptionsLite::Options opts;
opts.addOptions()("SIMD", SIMD, std::string(""), "")("c", ProgramOptionsLite::parseConfigFile, "");
ProgramOptionsLite::SilentReporter err;
ProgramOptionsLite::scanArgv(opts, argc, (const char**) argv, err);
fprintf( stdout, "[SIMD=%s] ", read_x86_extension( SIMD ) );
#endif
#if ENABLE_TRACING
......@@ -167,7 +192,7 @@ int main(int argc, char* argv[])
return 1;
}
}
catch( df::program_options_lite::ParseFailure &e )
catch (ProgramOptionsLite::ParseFailure& e)
{
std::cerr << "Error parsing option \"" << e.arg << "\" with argument \"" << e.val << "\"." << std::endl;
return 1;
......@@ -325,6 +350,13 @@ int main(int argc, char* argv[])
encApp->applyNnPostFilter();
}
}
#ifdef __linux
int vm = getProcStatusValue("VmPeak:");
int rm = getProcStatusValue("VmHWM:");
printf("\nMemory Usage: VmPeak= %d KB ( %.1f GiB ), VmHWM= %d KB ( %.1f GiB )\n", vm, (double)vm/(1024*1024), rm, (double)rm/(1024*1024));
#endif
// ending time
clock_t endClock = clock();
auto endTime = std::chrono::steady_clock::now();
......
This diff is collapsed.
......@@ -44,7 +44,7 @@
#include "CommonLib/dtrace_next.h"
#endif
namespace po = df::program_options_lite;
namespace po = ProgramOptionsLite;
//! \ingroup SEIFilmGrainApp
//! \{
......
......@@ -59,10 +59,10 @@ int main(int argc, char* argv[])
fprintf( stdout, NVM_BITS );
#if ENABLE_SIMD_OPT
std::string SIMD;
df::program_options_lite::Options optsSimd;
ProgramOptionsLite::Options optsSimd;
optsSimd.addOptions()("SIMD", SIMD, std::string(""), "");
df::program_options_lite::SilentReporter err;
df::program_options_lite::scanArgv( optsSimd, argc, ( const char** ) argv, err );
ProgramOptionsLite::SilentReporter err;
ProgramOptionsLite::scanArgv(optsSimd, argc, (const char**) argv, err);
fprintf( stdout, "[SIMD=%s] ", read_x86_extension( SIMD ) );
#endif
#if ENABLE_TRACING
......