Ticket #1017: checkMaxTbSize.patch

File checkMaxTbSize.patch, 1.9 KB (added by chiaming, 4 years ago)
  • source/App/EncoderApp/EncAppCfg.cpp

    diff --git a/source/App/EncoderApp/EncAppCfg.cpp b/source/App/EncoderApp/EncAppCfg.cpp
    index 087269d5..6cbd1f1c 100644
    a b bool EncAppCfg::xCheckParameter() 
    28292829  }
    28302830  xConfirmPara( m_log2MaxTbSize > 6, "Log2MaxTbSize must be 6 or smaller." );
    28312831  xConfirmPara( m_log2MaxTbSize < 5,  "Log2MaxTbSize must be 5 or greater." );
     2832  xConfirmPara( m_log2MaxTbSize > 5 && m_uiCTUSize < 64, "When CTUSize is 32, Log2MaxTbSize shall be 5." );
    28322833  xConfirmPara( m_maxNumMergeCand < 1,  "MaxNumMergeCand must be 1 or greater.");
    28332834  xConfirmPara( m_maxNumMergeCand > MRG_MAX_NUM_CANDS, "MaxNumMergeCand must be no more than MRG_MAX_NUM_CANDS." );
    28342835#if !JVET_Q0806
  • source/Lib/DecoderLib/VLCReader.cpp

    diff --git a/source/Lib/DecoderLib/VLCReader.cpp b/source/Lib/DecoderLib/VLCReader.cpp
    index 519c336b..027a0580 100644
    a b void HLSyntaxReader::parseSPS(SPS* pcSPS) 
    20462046
    20472047
    20482048  READ_FLAG( uiCode, "sps_max_luma_transform_size_64_flag");        pcSPS->setLog2MaxTbSize( (uiCode ? 1 : 0) + 5 );
     2049  CHECK(pcSPS->getCTUSize() < 64 && uiCode != 0, "When CtbSizeY is less than 64, the value of sps_max_luma_transform_size_64_flag shall be equal to 0");
    20492050
    20502051#if JVET_Q0147_JCCR_SIGNALLING
    20512052#if JVET_Q0265
  • source/Lib/EncoderLib/VLCWriter.cpp

    diff --git a/source/Lib/EncoderLib/VLCWriter.cpp b/source/Lib/EncoderLib/VLCWriter.cpp
    index 303455d5..9b046211 100644
    a b void HLSWriter::codeSPS( const SPS* pcSPS ) 
    13021302    }
    13031303  }
    13041304
     1305  CHECK(pcSPS->getCTUSize() < 64 && pcSPS->getLog2MaxTbSize() > 5, "When CtbSizeY is less than 64, the value of sps_max_luma_transform_size_64_flag shall be equal to 0");
    13051306  WRITE_FLAG( (pcSPS->getLog2MaxTbSize() - 5) ? 1 : 0,                       "sps_max_luma_transform_size_64_flag" );
    13061307
    13071308#if JVET_Q0147_JCCR_SIGNALLING