Newer
Older
m_PPSMvdL1ZeroIdc = 2;
m_PPSCollocatedFromL0Idc = 1;
m_PPSSixMinusMaxNumMergeCandPlus1 = 6 - m_maxNumMergeCand + 1;
#if !JVET_P0152_REMOVE_PPS_NUM_SUBBLOCK_MERGE_CAND
m_PPSFiveMinusMaxNumSubblockMergeCandPlus1 = 5 - m_maxNumAffineMergeCand + 1;
m_PPSMaxNumMergeCandMinusMaxNumTriangleCandPlus1 = m_maxNumMergeCand - m_maxNumTriangleCand + 1;
break;
case 3: // LDP setting
m_constantSliceHeaderParamsEnabledFlag = 1;
m_PPSDepQuantEnabledIdc = (m_depQuantEnabledFlag ? 1 : 0) + 1;
m_PPSRefPicListSPSIdc0 = 2;
m_PPSRefPicListSPSIdc1 = 2;
Martin Pettersson
committed
m_PPSTemporalMVPEnabledIdc = m_TMVPModeId == 2 ? 0: ( int(m_TMVPModeId == 1 ? 1: 0) + 1);
m_PPSMvdL1ZeroIdc = 0;
m_PPSCollocatedFromL0Idc = 0;
m_PPSSixMinusMaxNumMergeCandPlus1 = 6 - m_maxNumMergeCand + 1;
#if !JVET_P0152_REMOVE_PPS_NUM_SUBBLOCK_MERGE_CAND
m_PPSFiveMinusMaxNumSubblockMergeCandPlus1 = 5 - m_maxNumAffineMergeCand + 1;
m_PPSMaxNumMergeCandMinusMaxNumTriangleCandPlus1 = 0;
break;
default:
THROW("Invalid value for PPSorSliceMode");
}
xConfirmPara(m_drapPeriod > 0 && m_PPSRefPicListSPSIdc0 > 0, "PPSRefPicListSPSIdc0 shall be 0 when DRAP is used. This can be fixed by setting PPSorSliceMode=0.");
xConfirmPara(m_drapPeriod > 0 && m_PPSRefPicListSPSIdc1 > 0, "PPSRefPicListSPSIdc1 shall be 0 when DRAP is used. This can be fixed by setting PPSorSliceMode=0.");
#if HEVC_SEI

Karsten Suehring
committed
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
if (m_toneMappingInfoSEIEnabled)
{
xConfirmPara( m_toneMapCodedDataBitDepth < 8 || m_toneMapCodedDataBitDepth > 14 , "SEIToneMapCodedDataBitDepth must be in rage 8 to 14");
xConfirmPara( m_toneMapTargetBitDepth < 1 || (m_toneMapTargetBitDepth > 16 && m_toneMapTargetBitDepth < 255) , "SEIToneMapTargetBitDepth must be in rage 1 to 16 or equal to 255");
xConfirmPara( m_toneMapModelId < 0 || m_toneMapModelId > 4 , "SEIToneMapModelId must be in rage 0 to 4");
xConfirmPara( m_cameraIsoSpeedValue == 0, "SEIToneMapCameraIsoSpeedValue shall not be equal to 0");
xConfirmPara( m_exposureIndexValue == 0, "SEIToneMapExposureIndexValue shall not be equal to 0");
xConfirmPara( m_extendedRangeWhiteLevel < 100, "SEIToneMapExtendedRangeWhiteLevel should be greater than or equal to 100");
xConfirmPara( m_nominalBlackLevelLumaCodeValue >= m_nominalWhiteLevelLumaCodeValue, "SEIToneMapNominalWhiteLevelLumaCodeValue shall be greater than SEIToneMapNominalBlackLevelLumaCodeValue");
xConfirmPara( m_extendedWhiteLevelLumaCodeValue < m_nominalWhiteLevelLumaCodeValue, "SEIToneMapExtendedWhiteLevelLumaCodeValue shall be greater than or equal to SEIToneMapNominalWhiteLevelLumaCodeValue");
}
if (m_kneeSEIEnabled && !m_kneeSEICancelFlag)
{
xConfirmPara( m_kneeSEINumKneePointsMinus1 < 0 || m_kneeSEINumKneePointsMinus1 > 998, "SEIKneeFunctionNumKneePointsMinus1 must be in the range of 0 to 998");
for ( uint32_t i=0; i<=m_kneeSEINumKneePointsMinus1; i++ )
{
xConfirmPara( m_kneeSEIInputKneePoint[i] < 1 || m_kneeSEIInputKneePoint[i] > 999, "SEIKneeFunctionInputKneePointValue must be in the range of 1 to 999");
xConfirmPara( m_kneeSEIOutputKneePoint[i] < 0 || m_kneeSEIOutputKneePoint[i] > 1000, "SEIKneeFunctionInputKneePointValue must be in the range of 0 to 1000");
if ( i > 0 )
{
xConfirmPara( m_kneeSEIInputKneePoint[i-1] >= m_kneeSEIInputKneePoint[i], "The i-th SEIKneeFunctionInputKneePointValue must be greater than the (i-1)-th value");
xConfirmPara( m_kneeSEIOutputKneePoint[i-1] > m_kneeSEIOutputKneePoint[i], "The i-th SEIKneeFunctionOutputKneePointValue must be greater than or equal to the (i-1)-th value");
}
}
}
if (m_chromaResamplingFilterSEIenabled)
{
xConfirmPara( (m_chromaFormatIDC == CHROMA_400 ), "chromaResamplingFilterSEI is not allowed to be present when ChromaFormatIDC is equal to zero (4:0:0)" );
xConfirmPara(m_vuiParametersPresentFlag && m_chromaLocInfoPresentFlag && (m_chromaSampleLocTypeTopField != m_chromaSampleLocTypeBottomField ), "When chromaResamplingFilterSEI is enabled, ChromaSampleLocTypeTopField has to be equal to ChromaSampleLocTypeBottomField" );
}
#endif

Karsten Suehring
committed
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
if ( m_RCEnableRateControl )
{
if ( m_RCForceIntraQP )
{
if ( m_RCInitialQP == 0 )
{
msg( WARNING, "\nInitial QP for rate control is not specified. Reset not to use force intra QP!" );
m_RCForceIntraQP = false;
}
}
xConfirmPara( m_uiDeltaQpRD > 0, "Rate control cannot be used together with slice level multiple-QP optimization!\n" );
#if U0132_TARGET_BITS_SATURATION
if ((m_RCCpbSaturationEnabled) && (m_level!=Level::NONE) && (m_profile!=Profile::NONE))
{
uint32_t uiLevelIdx = (m_level / 10) + (uint32_t)((m_level % 10) / 3); // (m_level / 30)*3 + ((m_level % 10) / 3);
xConfirmPara(m_RCCpbSize > g_uiMaxCpbSize[m_levelTier][uiLevelIdx], "RCCpbSize should be smaller than or equal to Max CPB size according to tier and level");
xConfirmPara(m_RCInitialCpbFullness > 1, "RCInitialCpbFullness should be smaller than or equal to 1");
}
#endif
}
#if U0132_TARGET_BITS_SATURATION
else
{
xConfirmPara( m_RCCpbSaturationEnabled != 0, "Target bits saturation cannot be processed without Rate control" );
}
#endif
xConfirmPara(!m_TransquantBypassEnabledFlag && m_CUTransquantBypassFlagForce, "CUTransquantBypassFlagForce cannot be 1 when TransquantBypassEnableFlag is 0");
#if HEVC_SEI

Karsten Suehring
committed
if (m_framePackingSEIEnabled)
{
xConfirmPara(m_framePackingSEIType < 3 || m_framePackingSEIType > 5 , "SEIFramePackingType must be in rage 3 to 5");
}
if (m_segmentedRectFramePackingSEIEnabled)
{
xConfirmPara(m_framePackingSEIEnabled , "SEISegmentedRectFramePacking must be 0 when SEIFramePacking is 1");
}
if((m_numTileColumnsMinus1 <= 0) && (m_numTileRowsMinus1 <= 0) && m_tmctsSEIEnabled)
{
msg( WARNING, "Warning: SEITempMotionConstrainedTileSets is set to false to disable temporal motion-constrained tile sets SEI message because there are no tiles enabled.\n");
m_tmctsSEIEnabled = false;
}
if(m_timeCodeSEIEnabled)
{
xConfirmPara(m_timeCodeSEINumTs > MAX_TIMECODE_SEI_SETS, "Number of time sets cannot exceed 3");
}
#endif
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
#if JVET_P0462_SEI360
if( m_erpSEIEnabled && !m_erpSEICancelFlag )
{
xConfirmPara( m_erpSEIGuardBandType < 0 || m_erpSEIGuardBandType > 8, "SEIEquirectangularprojectionGuardBandType must be in the range of 0 to 7");
xConfirmPara( (m_chromaFormatIDC == CHROMA_420 || m_chromaFormatIDC == CHROMA_422) && (m_erpSEILeftGuardBandWidth%2 == 1), "SEIEquirectangularprojectionLeftGuardBandWidth must be an even number for 4:2:0 or 4:2:2 chroma format");
xConfirmPara( (m_chromaFormatIDC == CHROMA_420 || m_chromaFormatIDC == CHROMA_422) && (m_erpSEIRightGuardBandWidth%2 == 1), "SEIEquirectangularprojectionRightGuardBandWidth must be an even number for 4:2:0 or 4:2:2 chroma format");
}
if( m_sphereRotationSEIEnabled && !m_sphereRotationSEICancelFlag )
{
xConfirmPara( m_sphereRotationSEIYaw < -(180<<16) || m_sphereRotationSEIYaw > (180<<16)-1, "SEISphereRotationYaw must be in the range of -11 796 480 to 11 796 479");
xConfirmPara( m_sphereRotationSEIPitch < -(90<<16) || m_sphereRotationSEIYaw > (90<<16), "SEISphereRotationPitch must be in the range of -5 898 240 to 5 898 240");
xConfirmPara( m_sphereRotationSEIRoll < -(180<<16) || m_sphereRotationSEIYaw > (180<<16)-1, "SEISphereRotationRoll must be in the range of -11 796 480 to 11 796 479");
}
if ( m_omniViewportSEIEnabled && !m_omniViewportSEICancelFlag )
{
xConfirmPara( m_omniViewportSEIId < 0 || m_omniViewportSEIId > 1023, "SEIomniViewportId must be in the range of 0 to 1023");
xConfirmPara( m_omniViewportSEICntMinus1 < 0 || m_omniViewportSEICntMinus1 > 15, "SEIomniViewportCntMinus1 must be in the range of 0 to 15");
for ( uint32_t i=0; i<=m_omniViewportSEICntMinus1; i++ )
{
xConfirmPara( m_omniViewportSEIAzimuthCentre[i] < -(180<<16) || m_omniViewportSEIAzimuthCentre[i] > (180<<16)-1, "SEIOmniViewportAzimuthCentre must be in the range of -11 796 480 to 11 796 479");
xConfirmPara( m_omniViewportSEIElevationCentre[i] < -(90<<16) || m_omniViewportSEIElevationCentre[i] > (90<<16), "SEIOmniViewportSEIElevationCentre must be in the range of -5 898 240 to 5 898 240");
xConfirmPara( m_omniViewportSEITiltCentre[i] < -(180<<16) || m_omniViewportSEITiltCentre[i] > (180<<16)-1, "SEIOmniViewportTiltCentre must be in the range of -11 796 480 to 11 796 479");
xConfirmPara( m_omniViewportSEIHorRange[i] < 1 || m_omniViewportSEIHorRange[i] > (360<<16), "SEIOmniViewportHorRange must be in the range of 1 to 360*2^16");
xConfirmPara( m_omniViewportSEIVerRange[i] < 1 || m_omniViewportSEIVerRange[i] > (180<<16), "SEIOmniViewportVerRange must be in the range of 1 to 180*2^16");
}
}
#endif
#if HEVC_SEI

Karsten Suehring
committed
#if U0033_ALTERNATIVE_TRANSFER_CHARACTERISTICS_SEI
xConfirmPara(m_preferredTransferCharacteristics > 255, "transfer_characteristics_idc should not be greater than 255.");
#endif

Karsten Suehring
committed
#endif
xConfirmPara( unsigned(m_ImvMode) > 1, "ImvMode exceeds range (0 to 1)" );

Karsten Suehring
committed
xConfirmPara( m_decodeBitstreams[0] == m_bitstreamFileName, "Debug bitstream and the output bitstream cannot be equal.\n" );
xConfirmPara( m_decodeBitstreams[1] == m_bitstreamFileName, "Decode2 bitstream and the output bitstream cannot be equal.\n" );
xConfirmPara(unsigned(m_LMChroma) > 1, "LMMode exceeds range (0 to 1)");
Rickard Sjöberg
committed
#if JVET_O0549_ENCODER_ONLY_FILTER
if (m_gopBasedTemporalFilterEnabled)
{
xConfirmPara(m_temporalSubsampleRatio != 1, "GOP Based Temporal Filter only support Temporal sub-sample ratio 1");
}
#endif

Karsten Suehring
committed
#if EXTENSION_360_VIDEO
check_failed |= m_ext360.verifyParameters();
#endif
#if JVET_P0059_CHROMA_BDPCM
xConfirmPara(m_useBDPCM < 0 || m_useBDPCM > 2, "BDPCM must be in range 0..2");
#endif

Karsten Suehring
committed
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
#undef xConfirmPara
return check_failed;
}
const char *profileToString(const Profile::Name profile)
{
static const uint32_t numberOfProfiles = sizeof(strToProfile)/sizeof(*strToProfile);
for (uint32_t profileIndex = 0; profileIndex < numberOfProfiles; profileIndex++)
{
if (strToProfile[profileIndex].value == profile)
{
return strToProfile[profileIndex].str;
}
}
//if we get here, we didn't find this profile in the list - so there is an error
EXIT( "ERROR: Unknown profile \"" << profile << "\" in profileToString" );
return "";
}
void EncAppCfg::xPrintParameter()
{
//msg( DETAILS, "\n" );
msg( DETAILS, "Input File : %s\n", m_inputFileName.c_str() );
msg( DETAILS, "Bitstream File : %s\n", m_bitstreamFileName.c_str() );
msg( DETAILS, "Reconstruction File : %s\n", m_reconFileName.c_str() );
msg( DETAILS, "Real Format : %dx%d %gHz\n", m_iSourceWidth - m_confWinLeft - m_confWinRight, m_iSourceHeight - m_confWinTop - m_confWinBottom, (double)m_iFrameRate / m_temporalSubsampleRatio );
msg( DETAILS, "Internal Format : %dx%d %gHz\n", m_iSourceWidth, m_iSourceHeight, (double)m_iFrameRate / m_temporalSubsampleRatio );
msg( DETAILS, "Sequence PSNR output : %s\n", ( m_printMSEBasedSequencePSNR ? "Linear average, MSE-based" : "Linear average only" ) );
msg( DETAILS, "Hexadecimal PSNR output : %s\n", ( m_printHexPsnr ? "Enabled" : "Disabled" ) );

Karsten Suehring
committed
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
msg( DETAILS, "Sequence MSE output : %s\n", ( m_printSequenceMSE ? "Enabled" : "Disabled" ) );
msg( DETAILS, "Frame MSE output : %s\n", ( m_printFrameMSE ? "Enabled" : "Disabled" ) );
msg( DETAILS, "Cabac-zero-word-padding : %s\n", ( m_cabacZeroWordPaddingEnabled ? "Enabled" : "Disabled" ) );
if (m_isField)
{
msg( DETAILS, "Frame/Field : Field based coding\n" );
msg( DETAILS, "Field index : %u - %d (%d fields)\n", m_FrameSkip, m_FrameSkip + m_framesToBeEncoded - 1, m_framesToBeEncoded );
msg( DETAILS, "Field Order : %s field first\n", m_isTopFieldFirst ? "Top" : "Bottom" );
}
else
{
msg( DETAILS, "Frame/Field : Frame based coding\n" );
msg( DETAILS, "Frame index : %u - %d (%d frames)\n", m_FrameSkip, m_FrameSkip + m_framesToBeEncoded - 1, m_framesToBeEncoded );
}
if (m_profile == Profile::MAINREXT)
{
ExtendedProfileName validProfileName;
if (m_onePictureOnlyConstraintFlag)
{
validProfileName = m_bitDepthConstraint == 8 ? MAIN_444_STILL_PICTURE : (m_bitDepthConstraint == 16 ? MAIN_444_16_STILL_PICTURE : NONE);
}
else
{
const uint32_t intraIdx = m_intraConstraintFlag ? 1:0;
const uint32_t bitDepthIdx = (m_bitDepthConstraint == 8 ? 0 : (m_bitDepthConstraint ==10 ? 1 : (m_bitDepthConstraint == 12 ? 2 : (m_bitDepthConstraint == 16 ? 3 : 4 ))));
const uint32_t chromaFormatIdx = uint32_t(m_chromaFormatConstraint);
validProfileName = (bitDepthIdx > 3 || chromaFormatIdx>3) ? NONE : validRExtProfileNames[intraIdx][bitDepthIdx][chromaFormatIdx];
}
std::string rextSubProfile;
if (validProfileName!=NONE)
{
rextSubProfile=enumToString(strToExtendedProfile, sizeof(strToExtendedProfile)/sizeof(*strToExtendedProfile), validProfileName);
}
if (rextSubProfile == "main_444_16")
{
rextSubProfile="main_444_16 [NON STANDARD]";
}
msg( DETAILS, "Profile : %s (%s)\n", profileToString(m_profile), (rextSubProfile.empty())?"INVALID REXT PROFILE":rextSubProfile.c_str() );
}
else
{
msg( DETAILS, "Profile : %s\n", profileToString(m_profile) );
}
msg( DETAILS, "CU size / depth / total-depth : %d / %d / %d\n", m_uiMaxCUWidth, m_uiMaxCUDepth, m_uiMaxCodingDepth );
msg( DETAILS, "Max TB size : %d \n", 1 << m_log2MaxTbSize );

Karsten Suehring
committed
msg( DETAILS, "Motion search range : %d\n", m_iSearchRange );
msg( DETAILS, "Intra period : %d\n", m_iIntraPeriod );
msg( DETAILS, "Decoding refresh type : %d\n", m_iDecodingRefreshType );
msg( DETAILS, "DRAP period : %d\n", m_drapPeriod );

Karsten Suehring
committed
#if QP_SWITCHING_FOR_PARALLEL
if (m_qpIncrementAtSourceFrame.bPresent)
{
msg( DETAILS, "QP : %d (incrementing internal QP at source frame %d)\n", m_iQP, m_qpIncrementAtSourceFrame.value);
}
else
{
msg( DETAILS, "QP : %d\n", m_iQP);
}
#else
msg( DETAILS, "QP : %5.2f\n", m_fQP );
#endif
msg( DETAILS, "Max dQP signaling subdiv : %d\n", m_cuQpDeltaSubdiv);

Karsten Suehring
committed
msg( DETAILS, "Cb QP Offset (dual tree) : %d (%d)\n", m_cbQpOffset, m_cbQpOffsetDualTree);
msg( DETAILS, "Cr QP Offset (dual tree) : %d (%d)\n", m_crQpOffset, m_crQpOffsetDualTree);
msg( DETAILS, "QP adaptation : %d (range=%d)\n", m_bUseAdaptiveQP, (m_bUseAdaptiveQP ? m_iQPAdaptationRange : 0) );
msg( DETAILS, "GOP size : %d\n", m_iGOPSize );
msg( DETAILS, "Input bit depth : (Y:%d, C:%d)\n", m_inputBitDepth[CHANNEL_TYPE_LUMA], m_inputBitDepth[CHANNEL_TYPE_CHROMA] );
msg( DETAILS, "MSB-extended bit depth : (Y:%d, C:%d)\n", m_MSBExtendedBitDepth[CHANNEL_TYPE_LUMA], m_MSBExtendedBitDepth[CHANNEL_TYPE_CHROMA] );
msg( DETAILS, "Internal bit depth : (Y:%d, C:%d)\n", m_internalBitDepth[CHANNEL_TYPE_LUMA], m_internalBitDepth[CHANNEL_TYPE_CHROMA] );
msg( DETAILS, "Intra reference smoothing : %s\n", (m_enableIntraReferenceSmoothing ? "Enabled" : "Disabled") );
msg( DETAILS, "cu_chroma_qp_offset_subdiv : %d\n", m_cuChromaQpOffsetSubdiv);

Karsten Suehring
committed
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
msg( DETAILS, "extended_precision_processing_flag : %s\n", (m_extendedPrecisionProcessingFlag ? "Enabled" : "Disabled") );
msg( DETAILS, "implicit_rdpcm_enabled_flag : %s\n", (m_rdpcmEnabledFlag[RDPCM_SIGNAL_IMPLICIT] ? "Enabled" : "Disabled") );
msg( DETAILS, "explicit_rdpcm_enabled_flag : %s\n", (m_rdpcmEnabledFlag[RDPCM_SIGNAL_EXPLICIT] ? "Enabled" : "Disabled") );
msg( DETAILS, "transform_skip_rotation_enabled_flag : %s\n", (m_transformSkipRotationEnabledFlag ? "Enabled" : "Disabled") );
msg( DETAILS, "transform_skip_context_enabled_flag : %s\n", (m_transformSkipContextEnabledFlag ? "Enabled" : "Disabled") );
msg( DETAILS, "cross_component_prediction_enabled_flag: %s\n", (m_crossComponentPredictionEnabledFlag ? (m_reconBasedCrossCPredictionEstimate ? "Enabled (reconstructed-residual-based estimate)" : "Enabled (encoder-side-residual-based estimate)") : "Disabled") );
msg( DETAILS, "high_precision_offsets_enabled_flag : %s\n", (m_highPrecisionOffsetsEnabledFlag ? "Enabled" : "Disabled") );
msg( DETAILS, "persistent_rice_adaptation_enabled_flag: %s\n", (m_persistentRiceAdaptationEnabledFlag ? "Enabled" : "Disabled") );
msg( DETAILS, "cabac_bypass_alignment_enabled_flag : %s\n", (m_cabacBypassAlignmentEnabledFlag ? "Enabled" : "Disabled") );
if (m_bUseSAO)
{
msg( DETAILS, "log2_sao_offset_scale_luma : %d\n", m_log2SaoOffsetScale[CHANNEL_TYPE_LUMA] );
msg( DETAILS, "log2_sao_offset_scale_chroma : %d\n", m_log2SaoOffsetScale[CHANNEL_TYPE_CHROMA] );
}
switch (m_costMode)
{
case COST_STANDARD_LOSSY: msg( DETAILS, "Cost function: : Lossy coding (default)\n"); break;
case COST_SEQUENCE_LEVEL_LOSSLESS: msg( DETAILS, "Cost function: : Sequence_level_lossless coding\n"); break;
case COST_LOSSLESS_CODING: msg( DETAILS, "Cost function: : Lossless coding with fixed QP of %d\n", LOSSLESS_AND_MIXED_LOSSLESS_RD_COST_TEST_QP); break;
case COST_MIXED_LOSSLESS_LOSSY_CODING: msg( DETAILS, "Cost function: : Mixed_lossless_lossy coding with QP'=%d for lossless evaluation\n", LOSSLESS_AND_MIXED_LOSSLESS_RD_COST_TEST_QP_PRIME); break;
default: msg( DETAILS, "Cost function: : Unknown\n"); break;
}
msg( DETAILS, "RateControl : %d\n", m_RCEnableRateControl );
msg( DETAILS, "WPMethod : %d\n", int(m_weightedPredictionMethod));
if(m_RCEnableRateControl)
{
msg( DETAILS, "TargetBitrate : %d\n", m_RCTargetBitrate );
msg( DETAILS, "KeepHierarchicalBit : %d\n", m_RCKeepHierarchicalBit );
msg( DETAILS, "LCULevelRC : %d\n", m_RCLCULevelRC );
msg( DETAILS, "UseLCUSeparateModel : %d\n", m_RCUseLCUSeparateModel );
msg( DETAILS, "InitialQP : %d\n", m_RCInitialQP );
msg( DETAILS, "ForceIntraQP : %d\n", m_RCForceIntraQP );
#if U0132_TARGET_BITS_SATURATION
msg( DETAILS, "CpbSaturation : %d\n", m_RCCpbSaturationEnabled );
if (m_RCCpbSaturationEnabled)
{
msg( DETAILS, "CpbSize : %d\n", m_RCCpbSize);
msg( DETAILS, "InitalCpbFullness : %.2f\n", m_RCInitialCpbFullness);
}
#endif
}
msg( DETAILS, "Max Num Merge Candidates : %d\n", m_maxNumMergeCand );
msg( DETAILS, "Max Num Affine Merge Candidates : %d\n", m_maxNumAffineMergeCand );
msg( DETAILS, "Max Num Triangle Merge Candidates : %d\n", m_maxNumTriangleCand );
msg( DETAILS, "Max Num IBC Merge Candidates : %d\n", m_maxNumIBCMergeCand );

Karsten Suehring
committed
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
msg( DETAILS, "\n");
msg( VERBOSE, "TOOL CFG: ");
msg( VERBOSE, "IBD:%d ", ((m_internalBitDepth[CHANNEL_TYPE_LUMA] > m_MSBExtendedBitDepth[CHANNEL_TYPE_LUMA]) || (m_internalBitDepth[CHANNEL_TYPE_CHROMA] > m_MSBExtendedBitDepth[CHANNEL_TYPE_CHROMA])));
msg( VERBOSE, "HAD:%d ", m_bUseHADME );
msg( VERBOSE, "RDQ:%d ", m_useRDOQ );
msg( VERBOSE, "RDQTS:%d ", m_useRDOQTS );
msg( VERBOSE, "RDpenalty:%d ", m_rdPenalty );
#if SHARP_LUMA_DELTA_QP
msg( VERBOSE, "LQP:%d ", m_lumaLevelToDeltaQPMapping.mode );
#endif
msg( VERBOSE, "SQP:%d ", m_uiDeltaQpRD );
msg( VERBOSE, "ASR:%d ", m_bUseASR );
msg( VERBOSE, "MinSearchWindow:%d ", m_minSearchWindow );
msg( VERBOSE, "RestrictMESampling:%d ", m_bRestrictMESampling );
msg( VERBOSE, "FEN:%d ", int(m_fastInterSearchMode) );
msg( VERBOSE, "ECU:%d ", m_bUseEarlyCU );
msg( VERBOSE, "FDM:%d ", m_useFastDecisionForMerge );
msg( VERBOSE, "CFM:%d ", m_bUseCbfFastMode );
msg( VERBOSE, "ESD:%d ", m_useEarlySkipDetection );
msg( VERBOSE, "TransformSkip:%d ", m_useTransformSkip );
msg( VERBOSE, "TransformSkipFast:%d ", m_useTransformSkipFast );
msg( VERBOSE, "TransformSkipLog2MaxSize:%d ", m_log2MaxTransformSkipBlockSize);
#if JVET_P0058_CHROMA_TS
msg(VERBOSE, "ChromaTS:%d ", m_useChromaTS);
#endif
msg( VERBOSE, "BDPCM:%d ", m_useBDPCM );
#if JVET_P1004_REMOVE_BRICKS
msg( VERBOSE, "Tiles: %dx%d ", m_numTileCols, m_numTileRows );
msg( VERBOSE, "Slices: %d ", m_numSlicesInPic);
#else

Karsten Suehring
committed
msg( VERBOSE, "Slice: M=%d ", int(m_sliceMode));
if (m_sliceMode!=NO_SLICES)
{
msg( VERBOSE, "A=%d ", m_sliceArgument);
}
msg( VERBOSE, "Tiles:%dx%d ", m_numTileColumnsMinus1 + 1, m_numTileRowsMinus1 + 1 );
msg( VERBOSE, "MCTS:%d ", m_MCTSEncConstraint );

Karsten Suehring
committed
msg( VERBOSE, "SAO:%d ", (m_bUseSAO)?(1):(0));
msg( VERBOSE, "ALF:%d ", m_alf ? 1 : 0 );
if (m_TransquantBypassEnabledFlag && m_CUTransquantBypassFlagForce)
{
msg( VERBOSE, "TransQuantBypassEnabled: =1");
}
else
{
msg( VERBOSE, "TransQuantBypassEnabled:%d ", (m_TransquantBypassEnabledFlag)? 1:0 );
}
msg( VERBOSE, "WPP:%d ", (int)m_useWeightedPred);
msg( VERBOSE, "WPB:%d ", (int)m_useWeightedBiPred);
const int iWaveFrontSubstreams = m_entropyCodingSyncEnabledFlag ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1;
msg( VERBOSE, " WaveFrontSynchro:%d WaveFrontSubstreams:%d", m_entropyCodingSyncEnabledFlag?1:0, iWaveFrontSubstreams);
msg( VERBOSE, " ScalingList:%d ", m_useScalingListId );
Martin Pettersson
committed
msg( VERBOSE, "TMVPMode:%d ", m_TMVPModeId );

Karsten Suehring
committed
msg( VERBOSE, " DQ:%d ", m_depQuantEnabledFlag);
msg( VERBOSE, " SignBitHidingFlag:%d ", m_signDataHidingEnabledFlag);
msg( VERBOSE, "RecalQP:%d ", m_recalculateQPAccordingToLambda ? 1 : 0 );
if( m_profile == Profile::NEXT )
{
msg( VERBOSE, "\nNEXT TOOL CFG: " );
msg( VERBOSE, "LFNST:%d ", m_LFNST );

Karsten Suehring
committed
msg( VERBOSE, "Affine:%d ", m_Affine );
if ( m_Affine )
{
msg( VERBOSE, "AffineType:%d ", m_AffineType );
}
msg(VERBOSE, "PROF:%d ", m_PROF);

Karsten Suehring
committed
msg(VERBOSE, "SubPuMvp:%d+%d ", m_SubPuMvpMode & 1, (m_SubPuMvpMode & 2) == 2);

Karsten Suehring
committed
msg( VERBOSE, "IMV:%d ", m_ImvMode );
msg( VERBOSE, "BIO:%d ", m_BIO );

Karsten Suehring
committed
msg( VERBOSE, "LMChroma:%d ", m_LMChroma );
#if JVET_P0592_CHROMA_PHASE
msg( VERBOSE, "HorCollocatedChroma:%d ", m_horCollocatedChromaFlag );
msg( VERBOSE, "VerCollocatedChroma:%d ", m_verCollocatedChromaFlag );
#else
if( m_LMChroma && m_chromaFormatIDC == CHROMA_420 )
{
msg( VERBOSE, "CclmCollocatedChroma:%d ", m_cclmCollocatedChromaFlag );
}
#endif
msg( VERBOSE, "MTS: %1d(intra) %1d(inter) ", m_MTS & 1, ( m_MTS >> 1 ) & 1 );
msg( VERBOSE, "SBT:%d ", m_SBT );
msg( VERBOSE, "ISP:%d ", m_ISP );
msg( VERBOSE, "CompositeLTReference:%d ", m_compositeRefEnabled);
msg( VERBOSE, "GBi:%d ", m_GBi );
msg( VERBOSE, "GBiFast:%d ", m_GBiFast );
Shunsuke Iwamura
committed
#if LUMA_ADAPTIVE_DEBLOCKING_FILTER_QP_OFFSET
msg( VERBOSE, "LADF:%d ", m_LadfEnabed );
#endif
msg(VERBOSE, "MHIntra:%d ", m_MHIntra);
msg( VERBOSE, "Triangle:%d ", m_Triangle );
m_allowDisFracMMVD = m_MMVD ? m_allowDisFracMMVD : false;
if ( m_MMVD )
msg(VERBOSE, "AllowDisFracMMVD:%d ", m_allowDisFracMMVD);
msg( VERBOSE, "AffineAmvr:%d ", m_AffineAmvr );
Hongbin Liu
committed
m_AffineAmvrEncOpt = m_AffineAmvr ? m_AffineAmvrEncOpt : false;
msg( VERBOSE, "AffineAmvrEncOpt:%d ", m_AffineAmvrEncOpt );
msg(VERBOSE, "DMVR:%d ", m_DMVR);
msg(VERBOSE, "MmvdDisNum:%d ", m_MmvdDisNum);
msg(VERBOSE, "JointCbCr:%d ", m_JointCbCrMode);

Karsten Suehring
committed
}
#if JVET_P0517_ADAPTIVE_COLOR_TRANSFORM
m_useColorTrans = (m_chromaFormatIDC == CHROMA_444 && m_costMode != COST_LOSSLESS_CODING) ? m_useColorTrans : 0u;
msg(VERBOSE, "ACT:%d ", m_useColorTrans);
#endif
Yung-Hsuan Chao (Jessie)
committed
m_PLTMode = ( m_chromaFormatIDC == CHROMA_444) ? m_PLTMode : 0u;
msg(VERBOSE, "PLT:%d ", m_PLTMode);
msg( VERBOSE, "HashME:%d ", m_HashME );
msg( VERBOSE, "WrapAround:%d ", m_wrapAround);
if( m_wrapAround )
msg( VERBOSE, "WrapAroundOffset:%d ", m_wrapAroundOffset );

Karsten Suehring
committed
// ADD_NEW_TOOL (add some output indicating the usage of tools)
Sheng-Yen Lin
committed
msg(VERBOSE, "LoopFilterAcrossVirtualBoundaries:%d ", m_loopFilterAcrossVirtualBoundariesDisabledFlag);
if ( m_loopFilterAcrossVirtualBoundariesDisabledFlag )
{
msg(VERBOSE, "vertical virtual boundaries:[");
for (unsigned i = 0; i < m_numVerVirtualBoundaries; i++)
{
msg(VERBOSE, " %d", m_virtualBoundariesPosX[i]);
}
msg(VERBOSE, " ] horizontal virtual boundaries:[");
for (unsigned i = 0; i < m_numHorVirtualBoundaries; i++)
{
msg(VERBOSE, " %d", m_virtualBoundariesPosY[i]);
}
msg(VERBOSE, " ] ");
}
msg(VERBOSE, "Reshape:%d ", m_lumaReshapeEnable);
if (m_lumaReshapeEnable)
msg(VERBOSE, "(Signal:%s ", m_reshapeSignalType == 0 ? "SDR" : (m_reshapeSignalType == 2 ? "HDR-HLG" : "HDR-PQ"));
msg(VERBOSE, "Opt:%d", m_adpOption);
if (m_adpOption > 0) { msg(VERBOSE, " CW:%d", m_initialCW); }
#if JVET_P0371_CHROMA_SCALING_OFFSET
msg(VERBOSE, " CSoffset:%d", m_CSoffset);
#endif
msg(VERBOSE, "MIP:%d ", m_MIP);

Karsten Suehring
committed
msg( VERBOSE, "\nFAST TOOL CFG: " );
msg( VERBOSE, "LCTUFast:%d ", m_useFastLCTU );

Karsten Suehring
committed
msg( VERBOSE, "FastMrg:%d ", m_useFastMrg );
msg( VERBOSE, "PBIntraFast:%d ", m_usePbIntraFast );
if( m_ImvMode ) msg( VERBOSE, "IMV4PelFast:%d ", m_Imv4PelFast );
if( m_MTS ) msg( VERBOSE, "MTSMaxCand: %1d(intra) %1d(inter) ", m_MTSIntraMaxCand, m_MTSInterMaxCand );
if( m_ISP ) msg( VERBOSE, "ISPFast:%d ", m_useFastISP );
if( m_LFNST ) msg( VERBOSE, "FastLFNST:%d ", m_useFastLFNST );
msg( VERBOSE, "AMaxBT:%d ", m_useAMaxBT );
msg( VERBOSE, "E0023FastEnc:%d ", m_e0023FastEnc );
msg( VERBOSE, "ContentBasedFastQtbt:%d ", m_contentBasedFastQtbt );
msg( VERBOSE, "UseNonLinearAlfLuma:%d ", m_useNonLinearAlfLuma );
msg( VERBOSE, "UseNonLinearAlfChroma:%d ", m_useNonLinearAlfChroma );
msg( VERBOSE, "MaxNumAlfAlternativesChroma:%d ", m_maxNumAlfAlternativesChroma );
Philipp Merkle
committed
if( m_MIP ) msg(VERBOSE, "FastMIP:%d ", m_useFastMIP);
msg( VERBOSE, "FastLocalDualTree:%d ", m_fastLocalDualTreeMode );

Karsten Suehring
committed
msg( VERBOSE, "NumSplitThreads:%d ", m_numSplitThreads );
if( m_numSplitThreads > 1 )
{
msg( VERBOSE, "ForceSingleSplitThread:%d ", m_forceSplitSequential );
}
msg( VERBOSE, "NumWppThreads:%d+%d ", m_numWppThreads, m_numWppExtraLines );
msg( VERBOSE, "EnsureWppBitEqual:%d ", m_ensureWppBitEqual );
if( m_rprEnabled )
{
msg( VERBOSE, "RPR:(%1.2lfx, %1.2lfx)|%d ", m_scalingRatioHor, m_scalingRatioVer, m_switchPocPeriod );
}
else
{
msg( VERBOSE, "RPR:%d ", 0 );
Rickard Sjöberg
committed
#if JVET_O0549_ENCODER_ONLY_FILTER
msg(VERBOSE, "TemporalFilter:%d ", m_gopBasedTemporalFilterEnabled);
#endif
Rickard Sjöberg
committed
#if EXTENSION_360_VIDEO
m_ext360.outputConfigurationSummary();
#endif

Karsten Suehring
committed
msg( VERBOSE, "\n\n");
msg( NOTICE, "\n");
fflush( stdout );
}
Martin Pettersson
committed
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
#if JVET_P0366_NUT_CONSTRAINT_FLAGS
bool EncAppCfg::xHasNonZeroTemporalID ()
{
for (unsigned int i = 0; i < m_iGOPSize; i++)
{
if ( m_GOPList[i].m_temporalId != 0 )
{
return true;
}
}
return false;
}
bool EncAppCfg::xHasLeadingPicture ()
{
for (unsigned int i = 0; i < m_iGOPSize; i++)
{
for ( unsigned int j = 0; j < m_GOPList[i].m_numRefPics0; j++)
{
if ( m_GOPList[i].m_deltaRefPics0[j] < 0 )
{
return true;
}
}
for ( unsigned int j = 0; j < m_GOPList[i].m_numRefPics1; j++)
{
if ( m_GOPList[i].m_deltaRefPics1[j] < 0 )
{
return true;
}
}
}
return false;
}
#endif

Karsten Suehring
committed
bool confirmPara(bool bflag, const char* message)
{
if (!bflag)
{
return false;
}
msg( ERROR, "Error: %s\n",message);
return true;
}
Martin Pettersson
committed