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/VVCSoftware_VTM
  • chenhuanbang/VVCSoftware_VTM
  • ezhizng/VVCSoftware_VTM
  • XZheng/VVCSoftware_VTM
  • YanZhang/VVCSoftware_VTM
  • xiaozhongxu/VVCSoftware_VTM
  • bossen/VVCSoftware_VTM
  • XiangLi/VVCSoftware_VTM
  • s.iwamura/VVCSoftware_VTM
  • yuling.hsiao/VVCSoftware_VTM
  • ccc2384823/VVCSoftware_VTM
  • yuchisu/VVCSoftware_VTM
  • schwarz/VVCSoftware_VTM
  • philippe.hanhart/VVCSoftware_VTM
  • nanh/VVCSoftware_VTM
  • guillaume.laroche/VVCSoftware_VTM
  • Kenneth/VVCSoftware_VTM
  • jonatan/VVCSoftware_VTM
  • Alexey/VVCSoftware_VTM
  • saintspear/VVCSoftware_VTM
  • xinzhao/VVCSoftware_VTM
  • Seungsoo/VVCSoftware_VTM
  • jamesxxiu/VVCSoftware_VTM
  • leolzhao/VVCSoftware_VTM
  • ywchen/VVCSoftware_VTM
  • kevin625/VVCSoftware_VTM
  • Zhang/VVCSoftware_VTM
  • zhangkai/VVCSoftware_VTM
  • YCSun/VVCSoftware_VTM
  • ksuehring/VVCSoftware_VTM
  • AbeKiyo/VVCSoftware_VTM
  • naeri.park/VVCSoftware_VTM
  • ling/VVCSoftware_VTM
  • aikiho/VVCSoftware_VTM
  • JangwonChoi/VVCSoftware_VTM
  • Shelly/VVCSoftware_VTM
  • blaeser/VVCSoftware_VTM
  • crhelmrich/VVCSoftware_VTM
  • keydel/VVCSoftware_VTM
  • adam_wieckowski/VVCSoftware_VTM
  • hashimry/VVCSoftware_VTM
  • yimingli/VVCSoftware_VTM
  • zhipin/VVCSoftware_VTM
  • chernyak/VVCSoftware_VTM
  • jvet-l-ahg-14/VVCSoftware_VTM
  • sauer/VVCSoftware_VTM
  • fbarbier/VVCSoftware_VTM
  • misrak/VVCSoftware_VTM
  • ikai/VVCSoftware_VTM
  • tlu/VVCSoftware_VTM
  • Yasugi/VVCSoftware_VTM
  • peterchuang/VVCSoftware_VTM
  • wanght99/VVCSoftware_VTM
  • yuhan/VVCSoftware_VTM
  • hongbin/VVCSoftware_VTM
  • jiahaoli/VVCSoftware_VTM
  • cfd/VVCSoftware_VTM
  • ruoyangyu/VVCSoftware_VTM
  • chujoh/VVCSoftware_VTM
  • lijingya/VVCSoftware_VTM
  • hinz/VVCSoftware_VTM
  • tamse.anish/VVCSoftware_VTM
  • mcoban/VVCSoftware_VTM
  • george/VVCSoftware_VTM
  • jeeva.raj/VVCSoftware_VTM
  • antoine/VVCSoftware_VTM
  • moonmo.koo/VVCSoftware_VTM
  • deluxan/VVCSoftware_VTM
  • bheng/VVCSoftware_VTM
  • lzz8246/VVCSoftware_VTM
  • delagrangep/VVCSoftware_VTM
  • jiechen/VVCSoftware_VTM
  • hendry197/VVCSoftware_VTM
  • LGE_VCC/VVCSoftware_VTM
  • asegall/VVCSoftware_VTM
  • pbcowan/VVCSoftware_VTM
  • forayr/VVCSoftware_VTM
  • JT/VVCSoftware_VTM
  • Zhou/VVCSoftware_VTM
  • yjpiao/VVCSoftware_VTM
  • fabrice.leleannec/VVCSoftware_VTM
  • tpoirier/VVCSoftware_VTM
  • PoHan.Lin/VVCSoftware_VTM
  • jzxu/VVCSoftware_VTM
  • junghak.nam/VVCSoftware_VTM
  • guichunli/VVCSoftware_VTM
  • xianglinwang/VVCSoftware_VTM
  • chunchic/VVCSoftware_VTM
  • chrisr12/VVCSoftware_VTM
  • ks_kashyap/VVCSoftware_VTM
  • minhua/VVCSoftware_VTM
  • Sheng-Yen.Lin/VVCSoftware_VTM
  • hegilmez/VVCSoftware_VTM
  • swongah/VVCSoftware_VTM
  • merkle/VVCSoftware_VTM
  • sunyucheng/VVCSoftware_VTM
  • kirchhoffer/VVCSoftware_VTM
  • vdrugeon/VVCSoftware_VTM
  • jennylai/VVCSoftware_VTM
  • rickxu/VVCSoftware_VTM
  • seuhong/VVCSoftware_VTM
  • chollmann/VVCSoftware_VTM
  • jvet-n-ce8-public/VVCSoftware_VTM
  • martin.m.pettersson/VVCSoftware_VTM
  • siekmann/VVCSoftware_VTM
  • aramasub/VVCSoftware_VTM
  • zhiyilin/VVCSoftware_VTM
  • EricLin/VVCSoftware_VTM
  • mengwang/VVCSoftware_VTM
  • m.sarwer/VVCSoftware_VTM
  • agnesedong/VVCSoftware_VTM
  • geonjungko/VVCSoftware_VTM
  • bray/VVCSoftware_VTM
  • yhchao/VVCSoftware_VTM
  • Zhu/VVCSoftware_VTM
  • ykato/VVCSoftware_VTM
  • ZhipinDeng/VVCSoftware_VTM
  • jasonjung/VVCSoftware_VTM
  • hanhuang/VVCSoftware_VTM
  • seregin/VVCSoftware_VTM
  • wchen1014/VVCSoftware_VTM
  • Auyeung/VVCSoftware_VTM
  • Morris/VVCSoftware_VTM
  • lphamvan/VVCSoftware_VTM
  • dmehlem/VVCSoftware_VTM
  • shih-ta.hsiang/VVCSoftware_VTM
  • ysanchez/VVCSoftware_VTM
  • baegn74/VVCSoftware_VTM
  • kazui/VVCSoftware_VTM
  • yuwenhe_vvc/VVCSoftware_VTM
  • rickard/VVCSoftware_VTM
  • wangyang.cs/VVCSoftware_VTM
  • xwmeng/VVCSoftware_VTM
  • takeshi.tsukuba/VVCSoftware_VTM
  • yixindu/VVCSoftware_VTM
  • baixiu.wz/VVCSoftware_VTM
  • hm.jang/VVCSoftware_VTM
  • Ted/VVCSoftware_VTM
  • nguyen/VVCSoftware_VTM
  • chaohsiu/VVCSoftware_VTM
  • francoise/VVCSoftware_VTM
  • Yin/VVCSoftware_VTM
  • Morigami/VVCSoftware_VTM
  • sagar.kotecha/VVCSoftware_VTM
  • hwsun/VVCSoftware_VTM
  • pierrick.bouvier/VVCSoftware_VTM
  • XiangMa/VVCSoftware_VTM
  • LouiseLee/VVCSoftware_VTM
  • chenps/VVCSoftware_VTM
  • karls/VVCSoftware_VTM
  • biaowang/VVCSoftware_VTM
  • hangao/VVCSoftware_VTM
  • Jin/VVCSoftware_VTM
  • analci/VVCSoftware_VTM
  • KuiFan/VVCSoftware_VTM
  • hobingzhang/VVCSoftware_VTM
  • audrey.turquin/VVCSoftware_VTM
  • rlliao/VVCSoftware_VTM
  • winken/VVCSoftware_VTM
  • hallapur/VVCSoftware_VTM
  • T.Hashimoto/VVCSoftware_VTM
  • AnandMeher/VVCSoftware_VTM
  • semihese/VVCSoftware_VTM
  • ouedraogo/VVCSoftware_VTM
  • arthurcerveira/VVCSoftware_VTM
  • sunmi.yoo/VVCSoftware_VTM
  • Cynthia/VVCSoftware_VTM
  • yang/VVCSoftware_VTM
  • yuyoon/VVCSoftware_VTM
  • jslee/VVCSoftware_VTM
  • weimin.zeng/VVCSoftware_VTM
  • edrthomas/VVCSoftware_VTM
  • Mitsuru.Katsumata/VVCSoftware_VTM
  • adybrowne/VVCSoftware_VTM
  • jack.enhorn/VVCSoftware_VTM
  • Palanivel/VVCSoftware_VTM
  • olena.chubach/VVCSoftware_VTM
  • juvenalluo/VVCSoftware_VTM
  • yylee/VVCSoftware_VTM
  • bross/VVCSoftware_VTM
  • jvet-ahg-nnvc/VVCSoftware_VTM
  • jacob/VVCSoftware_VTM
  • dmytro.rusanovskyy/VVCSoftware_VTM
  • karamnaser/VVCSoftware_VTM
  • milos.radosavljevic/VVCSoftware_VTM
  • Keming/VVCSoftware_VTM
  • pj/VVCSoftware_VTM
  • cwkuo/VVCSoftware_VTM
  • BD/VVCSoftware_VTM
  • bartnik/VVCSoftware_VTM
  • Fangjun.Pu/VVCSoftware_VTM
  • nikolay.shostak/VVCSoftware_VTM
  • kirill.suverov/VVCSoftware_VTM
  • Xile_Zhou/VVCSoftware_VTM
  • ksuehring/vvc-software-vtm-nnvc
  • guether/VVCSoftware_VTM
  • salmonc/VVCSoftware_VTM
  • eeehey/VVCSoftware_VTM
  • marie-pierre.gallasso/VVCSoftware_VTM
  • jvet-ahg-fgt/VTM
  • liaojq/VVCSoftware_VTM
  • axel.ricard/VVCSoftware_VTM
  • XiangLi/nnvc
  • sw.xie/VVCSoftware_VTM
  • jeeva.raj/vvc-software-vtm-tu-c
  • XiangLi/tu-c
  • msantamaria/nnvc
  • cjj490168650/VVCSoftware_VTM
  • Yun_li/VVCSoftware_VTM
  • Zhengang/vvc-software-vtm
  • lvzhuoyi/vvc-software-vtm-nnvc
  • Kenneth/vvc-software-vtm-nn
  • biatekt/vvc-software-vtm
  • jvet-ahg-gcc/VVCSoftware_VTM
  • JINGYING/VVCSoftware_VTM
  • furban/VVCSoftware_VTM
  • yanning/VVCSoftware_VTM
  • zhuochen/VVCSoftware_VTM
  • Kaifa/VVCSoftware_VTM_AJ0048
  • yueli/VVCSoftware_VTM
  • tokumo/VVCSoftware_VTM
221 results
Show changes
Commits on Source (16)
......@@ -2711,7 +2711,11 @@ PPS::PPS()
, m_picHeightInLumaSamples( 288 )
#if JVET_Q0764_WRAP_AROUND_WITH_RPR
, m_wrapAroundEnabledFlag (false)
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
, m_picWidthMinusWrapAroundOffset (0)
#else
, m_wrapAroundOffsetMinusCtbSize (0)
#endif
, m_wrapAroundOffset (0)
#endif
, pcv (NULL)
......
......@@ -1959,7 +1959,11 @@ private:
#if JVET_Q0764_WRAP_AROUND_WITH_RPR
bool m_wrapAroundEnabledFlag; //< reference wrap around enabled or not
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
unsigned m_picWidthMinusWrapAroundOffset; // <pic_width_in_minCbSizeY - wraparound_offset_in_minCbSizeY
#else
unsigned m_wrapAroundOffsetMinusCtbSize; //< reference wrap around offset minus ( CtbSizeY / MinCbSizeY ) + 2 in units of MinCbSizeY luma samples
#endif
unsigned m_wrapAroundOffset; //< reference wrap around offset in luma samples
#endif
......@@ -2052,8 +2056,13 @@ public:
#if JVET_Q0764_WRAP_AROUND_WITH_RPR
void setWrapAroundEnabledFlag(bool b) { m_wrapAroundEnabledFlag = b; }
bool getWrapAroundEnabledFlag() const { return m_wrapAroundEnabledFlag; }
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
void setPicWidthMinusWrapAroundOffset(unsigned offset) { m_picWidthMinusWrapAroundOffset = offset; }
unsigned getPicWidthMinusWrapAroundOffset() const { return m_picWidthMinusWrapAroundOffset; }
#else
void setWrapAroundOffsetMinusCtbSize(unsigned offset) { m_wrapAroundOffsetMinusCtbSize = offset; }
unsigned getWrapAroundOffsetMinusCtbSize() const { return m_wrapAroundOffsetMinusCtbSize; }
#endif
void setWrapAroundOffset(unsigned offset) { m_wrapAroundOffset = offset; }
unsigned getWrapAroundOffset() const { return m_wrapAroundOffset; }
#endif
......
......@@ -51,6 +51,11 @@
#include <cassert>
//########### place macros to be removed in next cycle below this line ###############
#define JVET_R0162_WRAPAROUND_OFFSET_SIGNALING 1 // JVET-R0162 proposal 1 : signal "picture width minus wraparound offset" instead of "wraparound offset"
#define JVET_R0188 1 // JVET-R0188: Signalling slice_width_in_tiles_minus1[i] and slice_height_in_tiles_minus1[i]
#define JVET_R0203_IRAP_LEADING_CONSTRAINT 1 // JVET-R0203: Constraint that IRAP NAL unit type cannot be mixed with RASL_NUT / RADL_NUT
#define JVET_Q0488_SEI_REPETITION_CONSTRAINT 1 // JVET-Q0488: SEI repetition constraint
......@@ -172,8 +177,14 @@
#define JVET_R0214_MMVD_SYNTAX_MODIFICATION 1 // JVET-R0214: MMVD syntax modifications
#define JVET_R0101_SEI_INFERENCE_RULES 1 // JVET-R0101: SEI alternative timing information inference rules (including those from JVET-R0413)
#define JVET_R0108_DCI_SIGNALING 1 // JVET-R0108 Proposal 1 DCI signaling changes
#define JVET_R0112_SEMANTICS_CLEANUP 1 // JVET-R0112: Picture header semantics cleanup for gdr_or_irap_flag
#define JVET_R0107_VPS_SIGNALING 1 // JVET-R017: Proposal 2 VPS signaling change and updated inference rule
//########### place macros to be be kept below this line ###############
#define JVET_R0164_MEAN_SCALED_SATD 1 // JVET-R0164: Use a mean scaled version of SATD in encoder decisions
......
......@@ -2071,8 +2071,12 @@ bool DecLib::xDecodeSlice(InputNALUnit &nalu, int &iSkipFrame, int iPOCLastDispl
{
for( int refIdx = 0; refIdx < pcSlice->getNumRefIdx( RefPicList( refPicList ) ); refIdx++ )
{
CHECK( currentSubPicIdx >= pcSlice->getRefPic( RefPicList( refPicList ), refIdx )->subPicIDs.size(), "Number of sub-pictures in a reference picture is less then the current slice sub-picture index" );
CHECK( pcSlice->getRefPic( RefPicList( refPicList ), refIdx )->subPicIDs[currentSubPicIdx] != pcSlice->getSliceSubPicId(), "A picture with different sub-picture ID of the collocated sub-picture cannot be used as an active reference picture" );
Picture* refPic = pcSlice->getRefPic( RefPicList( refPicList ), refIdx );
if( refPic->layerId == nalu.m_nuhLayerId )
{
CHECK( currentSubPicIdx >= refPic->subPicIDs.size(), "Number of sub-pictures in a reference picture is less then the current slice sub-picture index" );
CHECK( refPic->subPicIDs[currentSubPicIdx] != pcSlice->getSliceSubPicId(), "A picture with different sub-picture ID of the collocated sub-picture cannot be used as an active reference picture" );
}
}
}
}
......
......@@ -717,13 +717,25 @@ void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, uint32_t payloadSi
{
sei.m_nalCpbAltInitialRemovalDelayDelta.resize(bp.m_bpMaxSubLayers);
sei.m_nalCpbAltInitialRemovalOffsetDelta.resize(bp.m_bpMaxSubLayers);
#if JVET_R0101_SEI_INFERENCE_RULES
for (int i = 0; i <= bp.m_bpMaxSubLayers - 1; ++i)
{
sei.m_nalCpbAltInitialRemovalDelayDelta[i].resize(bp.m_bpCpbCnt, 0);
sei.m_nalCpbAltInitialRemovalOffsetDelta[i].resize(bp.m_bpCpbCnt, 0);
}
sei.m_nalCpbDelayOffset.resize(bp.m_bpMaxSubLayers, 0);
sei.m_nalDpbDelayOffset.resize(bp.m_bpMaxSubLayers, 0);
#else
sei.m_nalCpbDelayOffset.resize(bp.m_bpMaxSubLayers);
sei.m_nalDpbDelayOffset.resize(bp.m_bpMaxSubLayers);
#endif
for (int i = (bp.m_sublayerInitialCpbRemovalDelayPresentFlag ? 0 : bp.m_bpMaxSubLayers - 1);
i <= bp.m_bpMaxSubLayers - 1; ++i)
{
#if !JVET_R0101_SEI_INFERENCE_RULES
sei.m_nalCpbAltInitialRemovalDelayDelta[i].resize(bp.m_bpCpbCnt);
sei.m_nalCpbAltInitialRemovalOffsetDelta[i].resize(bp.m_bpCpbCnt);
#endif
for (int j = 0; j < bp.m_bpCpbCnt; j++)
{
sei_read_code(pDecodedMessageOutputStream, bp.m_initialCpbRemovalDelayLength, symbol,
......@@ -744,13 +756,25 @@ void SEIReader::xParseSEIPictureTiming(SEIPictureTiming& sei, uint32_t payloadSi
{
sei.m_vclCpbAltInitialRemovalDelayDelta.resize(bp.m_bpMaxSubLayers);
sei.m_vclCpbAltInitialRemovalOffsetDelta.resize(bp.m_bpMaxSubLayers);
#if JVET_R0101_SEI_INFERENCE_RULES
for (int i = 0; i <= bp.m_bpMaxSubLayers - 1; ++i)
{
sei.m_vclCpbAltInitialRemovalDelayDelta[i].resize(bp.m_bpCpbCnt, 0);
sei.m_vclCpbAltInitialRemovalOffsetDelta[i].resize(bp.m_bpCpbCnt, 0);
}
sei.m_vclCpbDelayOffset.resize(bp.m_bpMaxSubLayers, 0);
sei.m_vclDpbDelayOffset.resize(bp.m_bpMaxSubLayers, 0);
#else
sei.m_vclCpbDelayOffset.resize(bp.m_bpMaxSubLayers);
sei.m_vclDpbDelayOffset.resize(bp.m_bpMaxSubLayers);
#endif
for (int i = (bp.m_sublayerInitialCpbRemovalDelayPresentFlag ? 0 : bp.m_bpMaxSubLayers - 1);
i <= bp.m_bpMaxSubLayers - 1; ++i)
{
#if !JVET_R0101_SEI_INFERENCE_RULES
sei.m_vclCpbAltInitialRemovalDelayDelta[i].resize(bp.m_bpCpbCnt);
sei.m_vclCpbAltInitialRemovalOffsetDelta[i].resize(bp.m_bpCpbCnt);
#endif
for (int j = 0; j < bp.m_bpCpbCnt; j++)
{
sei_read_code(pDecodedMessageOutputStream, bp.m_initialCpbRemovalDelayLength, symbol,
......
......@@ -586,12 +586,44 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS )
pcPPS->setSliceTileIdx( i, tileIdx );
// complete tiles within a single slice
#if JVET_R0188
if( ( tileIdx % pcPPS->getNumTileColumns() ) != pcPPS->getNumTileColumns() - 1 )
{
READ_UVLC( uiCode, "slice_width_in_tiles_minus1[i]" );
pcPPS->setSliceWidthInTiles ( i, uiCode + 1 );
}
else
{
pcPPS->setSliceWidthInTiles( i, 1 );
}
#else
uiCode = 0;
if( pcPPS->getNumTileColumns() > 1 )
{
READ_UVLC( uiCode, "slice_width_in_tiles_minus1[i]" );
}
pcPPS->setSliceWidthInTiles ( i, uiCode + 1 );
#endif
#if JVET_R0188
if( tileIdx / pcPPS->getNumTileColumns() != pcPPS->getNumTileRows() - 1 &&
( pcPPS->getTileIdxDeltaPresentFlag() || tileIdx % pcPPS->getNumTileColumns() == 0 ) )
{
READ_UVLC( uiCode, "slice_height_in_tiles_minus1[i]" );
pcPPS->setSliceHeightInTiles( i, uiCode + 1 );
}
else
{
if( ( tileIdx / pcPPS->getNumTileColumns() ) == pcPPS->getNumTileRows() - 1 )
{
pcPPS->setSliceHeightInTiles( i, 1 );
}
else
{
pcPPS->setSliceHeightInTiles( i, pcPPS->getSliceHeightInTiles( i - 1 ) );
}
}
#else
if( pcPPS->getTileIdxDeltaPresentFlag() || ( (tileIdx % pcPPS->getNumTileColumns()) == 0 ) )
{
uiCode = 0;
......@@ -605,6 +637,7 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS )
{
pcPPS->setSliceHeightInTiles( i, pcPPS->getSliceHeightInTiles(i-1) );
}
#endif
// multiple slices within a single tile special case
if( pcPPS->getSliceWidthInTiles(i) == 1 && pcPPS->getSliceHeightInTiles(i) == 1 )
......@@ -905,11 +938,20 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS )
READ_FLAG(uiCode, "pps_ref_wraparound_enabled_flag"); pcPPS->setWrapAroundEnabledFlag( uiCode ? true : false );
if (pcPPS->getWrapAroundEnabledFlag())
{
READ_UVLC(uiCode, "pps_ref_wraparound_offset"); pcPPS->setWrapAroundOffsetMinusCtbSize( uiCode );
READ_UVLC(uiCode, "pps_ref_wraparound_offset");
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pcPPS->setPicWidthMinusWrapAroundOffset(uiCode);
#else
pcPPS->setWrapAroundOffsetMinusCtbSize( uiCode );
#endif
}
else
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pcPPS->setPicWidthMinusWrapAroundOffset(0);
#else
pcPPS->setWrapAroundOffsetMinusCtbSize( 0 );
#endif
}
#endif
......@@ -2249,15 +2291,26 @@ void HLSyntaxReader::parseVPS(VPS* pcVPS)
}
else
pcVPS->setPtPresentFlag(0, 1);
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
#else
if(pcVPS->getMaxSubLayers() > 1 && !pcVPS->getAllLayersSameNumSublayersFlag())
#endif
{
READ_CODE(3, uiCode, "ptl_max_temporal_id");
pcVPS->setPtlMaxTemporalId(i, uiCode);
}
#if JVET_R0107_VPS_SIGNALING
else
{
pcVPS->setPtlMaxTemporalId(i, pcVPS->getMaxSubLayers() - 1);
}
#else
else if(pcVPS->getMaxSubLayers() > 1)
pcVPS->setPtlMaxTemporalId(i, pcVPS->getMaxSubLayers() - 1);
else
pcVPS->setPtlMaxTemporalId(i, 0);
#endif
}
int cnt = 0;
while (m_pcBitstream->getNumBitsUntilByteAligned())
......@@ -2323,6 +2376,17 @@ void HLSyntaxReader::parseVPS(VPS* pcVPS)
for( int i = 0; i < pcVPS->m_numDpbParams; i++ )
{
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
{
READ_CODE(3, uiCode, "dpb_max_temporal_id[i]");
pcVPS->m_dpbMaxTemporalId.push_back(uiCode);
}
else
{
pcVPS->m_dpbMaxTemporalId.push_back(pcVPS->getMaxSubLayers() - 1);
}
#else
if( pcVPS->getMaxSubLayers() == 1 )
{
// When vps_max_sublayers_minus1 is equal to 0, the value of dpb_max_temporal_id[ i ] is inferred to be equal to 0.
......@@ -2340,6 +2404,7 @@ void HLSyntaxReader::parseVPS(VPS* pcVPS)
READ_CODE( 3, uiCode, "dpb_max_temporal_id[i]" ); pcVPS->m_dpbMaxTemporalId.push_back( uiCode );
}
}
#endif
for( int j = ( pcVPS->m_sublayerDpbParamsPresentFlag ? 0 : pcVPS->m_dpbMaxTemporalId[i] ); j <= pcVPS->m_dpbMaxTemporalId[i]; j++ )
{
......@@ -2414,12 +2479,19 @@ void HLSyntaxReader::parseVPS(VPS* pcVPS)
pcVPS->m_olsHrdParams.resize(pcVPS->getNumOlsHrdParamsMinus1(), std::vector<OlsHrdParams>(pcVPS->getMaxSubLayers()));
for (int i = 0; i <= pcVPS->getNumOlsHrdParamsMinus1(); i++)
{
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
#else
if (((pcVPS->getMaxSubLayers() - 1) > 0) && (!pcVPS->getAllLayersSameNumSublayersFlag()))
#endif
{
READ_CODE(3, uiCode, "hrd_max_tid[i]"); pcVPS->setHrdMaxTid(i, uiCode);
}
else
{
#if JVET_R0107_VPS_SIGNALING
pcVPS->setHrdMaxTid(i, pcVPS->getMaxSubLayers() - 1);
#else
if (pcVPS->getMaxSubLayers() == 1)
{
pcVPS->setHrdMaxTid(i, 0);
......@@ -2428,6 +2500,7 @@ void HLSyntaxReader::parseVPS(VPS* pcVPS)
{
pcVPS->setHrdMaxTid(i, pcVPS->getMaxSubLayers()- 1);
}
#endif
}
uint32_t firstSublayer = pcVPS->getVPSSublayerCpbParamsPresentFlag() ? 0 : pcVPS->getHrdMaxTid(i);
......@@ -2491,6 +2564,12 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
{
READ_FLAG(uiCode, "gdr_pic_flag"); picHeader->setGdrPicFlag(uiCode != 0);
}
#if JVET_R0112_SEMANTICS_CLEANUP
else
{
picHeader->setGdrPicFlag(false);
}
#endif
READ_FLAG(uiCode, "ph_inter_slice_allowed_flag"); picHeader->setPicInterSliceAllowedFlag(uiCode != 0);
if (picHeader->getPicInterSliceAllowedFlag())
{
......@@ -2734,7 +2813,12 @@ void HLSyntaxReader::parsePictureHeader( PicHeader* picHeader, ParameterSetManag
CHECK( (((sps->getCTUSize() / minCbSizeY) + 1) > ((pps->getPicWidthInLumaSamples() / minCbSizeY) - 1)) && pps->getWrapAroundEnabledFlag(), "When the value of CtbSizeY / MinCbSizeY + 1 is greater than pic_width_in_luma_samples / MinCbSizeY - 1, the value of pps_ref_wraparound_enabled_flag shall be equal to 0.");
if( pps->getWrapAroundEnabledFlag() )
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
CHECK((pps->getPicWidthMinusWrapAroundOffset() > (pps->getPicWidthInLumaSamples() / minCbSizeY - sps->getCTUSize() / minCbSizeY - 2)), "pps_pic_width_minus_wraparound_ofsfet shall be less than or equal to pps_pic_width_in_luma_samples/MinCbSizeY - CtbSizeY/MinCbSizeY-2");
pps->setWrapAroundOffset(minCbSizeY * (pps->getPicWidthInLumaSamples()/minCbSizeY- pps->getPicWidthMinusWrapAroundOffset()));
#else
pps->setWrapAroundOffset( minCbSizeY * (pps->getWrapAroundOffsetMinusCtbSize() + 2 + sps->getCTUSize() / minCbSizeY) );
#endif
}
else
{
......
......@@ -316,12 +316,22 @@ void EncLib::init( bool isFieldCoding, AUWriterIf* auWriterIf )
if( pps.getWrapAroundEnabledFlag() )
{
int minCbSizeY = (1 << sps0.getLog2MinCodingBlockSize());
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pps.setPicWidthMinusWrapAroundOffset ((pps.getPicWidthInLumaSamples()/minCbSizeY) - (m_wrapAroundOffset * pps.getPicWidthInLumaSamples() / pps0.getPicWidthInLumaSamples() / minCbSizeY) );
pps.setWrapAroundOffset (minCbSizeY * (pps.getPicWidthInLumaSamples() / minCbSizeY - pps.getPicWidthMinusWrapAroundOffset()));
#else
pps.setWrapAroundOffsetMinusCtbSize ( ((m_wrapAroundOffset * pps.getPicWidthInLumaSamples() / pps0.getPicWidthInLumaSamples()) / minCbSizeY) - 2 - (sps0.getCTUSize() / minCbSizeY) );
pps.setWrapAroundOffset ( minCbSizeY * (pps.getWrapAroundOffsetMinusCtbSize() + 2 + sps0.getCTUSize() / minCbSizeY) );
#endif
}
else
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pps.setPicWidthMinusWrapAroundOffset (0);
#else
pps.setWrapAroundOffsetMinusCtbSize ( 0 );
#endif
pps.setWrapAroundOffset ( 0 );
}
#endif
......@@ -1597,12 +1607,21 @@ void EncLib::xInitPPS(PPS &pps, const SPS &sps)
pps.setWrapAroundEnabledFlag ( m_wrapAround );
if( m_wrapAround )
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pps.setPicWidthMinusWrapAroundOffset ((pps.getPicWidthInLumaSamples()/minCbSizeY) - (m_wrapAroundOffset / minCbSizeY));
pps.setWrapAroundOffset (minCbSizeY *(pps.getPicWidthInLumaSamples() / minCbSizeY- pps.getPicWidthMinusWrapAroundOffset()));
#else
pps.setWrapAroundOffsetMinusCtbSize ( (m_wrapAroundOffset / minCbSizeY) - 2 - (sps.getCTUSize() / minCbSizeY) );
pps.setWrapAroundOffset ( minCbSizeY * (pps.getWrapAroundOffsetMinusCtbSize() + 2 + sps.getCTUSize() / minCbSizeY) );
#endif
}
else
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
pps.setPicWidthMinusWrapAroundOffset ( 0 );
#else
pps.setWrapAroundOffsetMinusCtbSize ( 0 );
#endif
pps.setWrapAroundOffset ( 0 );
}
CHECK( !sps.getWrapAroundEnabledFlag() && pps.getWrapAroundEnabledFlag(), "When sps_ref_wraparound_enabled_flag is equal to 0, the value of pps_ref_wraparound_enabled_flag shall be equal to 0.");
......
......@@ -366,10 +366,25 @@ void HLSWriter::codePPS( const PPS* pcPPS )
for( int i = 0; i < pcPPS->getNumSlicesInPic()-1; i++ )
{
// complete tiles within a single slice
#if JVET_R0188
if( ( pcPPS->getSliceTileIdx( i ) % pcPPS->getNumTileColumns() ) != pcPPS->getNumTileColumns() - 1 )
{
WRITE_UVLC( pcPPS->getSliceWidthInTiles( i ) - 1, "slice_width_in_tiles_minus1[i]" );
}
#else
if( pcPPS->getNumTileColumns() > 1 )
{
WRITE_UVLC( pcPPS->getSliceWidthInTiles( i ) - 1, "slice_width_in_tiles_minus1[i]" );
WRITE_UVLC( pcPPS->getSliceWidthInTiles( i ) - 1, "slice_width_in_tiles_minus1[i]" );
}
#endif
#if JVET_R0188
if( pcPPS->getSliceTileIdx( i ) / pcPPS->getNumTileColumns() != pcPPS->getNumTileRows() - 1 &&
( pcPPS->getTileIdxDeltaPresentFlag() || pcPPS->getSliceTileIdx( i ) % pcPPS->getNumTileColumns() == 0 ) )
{
WRITE_UVLC( pcPPS->getSliceHeightInTiles( i ) - 1, "slice_height_in_tiles_minus1[i]" );
}
#else
if( pcPPS->getTileIdxDeltaPresentFlag() || ( (pcPPS->getSliceTileIdx( i ) % pcPPS->getNumTileColumns()) == 0 ) )
{
if( pcPPS->getNumTileRows() > 1 )
......@@ -377,6 +392,7 @@ void HLSWriter::codePPS( const PPS* pcPPS )
WRITE_UVLC( pcPPS->getSliceHeightInTiles( i ) - 1, "slice_height_in_tiles_minus1[i]" );
}
}
#endif
// multiple slices within a single tile special case
if( pcPPS->getSliceWidthInTiles(i) == 1 && pcPPS->getSliceHeightInTiles(i) == 1 && pcPPS->getTileRowHeight(pcPPS->getSliceTileIdx(i) / pcPPS->getNumTileColumns()) > 1 )
......@@ -519,7 +535,11 @@ void HLSWriter::codePPS( const PPS* pcPPS )
WRITE_FLAG( pcPPS->getWrapAroundEnabledFlag() ? 1 : 0, "pps_ref_wraparound_enabled_flag" );
if( pcPPS->getWrapAroundEnabledFlag() )
{
#if JVET_R0162_WRAPAROUND_OFFSET_SIGNALING
WRITE_UVLC(pcPPS->getPicWidthMinusWrapAroundOffset(), "pps_pic_width_minus_wraparound_offset");
#else
WRITE_UVLC( pcPPS->getWrapAroundOffsetMinusCtbSize(), "pps_ref_wraparound_offset");
#endif
}
#endif
......@@ -1429,7 +1449,11 @@ void HLSWriter::codeVPS(const VPS* pcVPS)
{
if(i > 0)
WRITE_FLAG(pcVPS->getPtPresentFlag(i), "pt_present_flag");
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
#else
if(pcVPS->getMaxSubLayers() > 1 && !pcVPS->getAllLayersSameNumSublayersFlag())
#endif
WRITE_CODE(pcVPS->getPtlMaxTemporalId(i) ,3, "ptl_max_temporal_id");
}
int cnt = 0;
......@@ -1465,6 +1489,16 @@ void HLSWriter::codeVPS(const VPS* pcVPS)
for( int i = 0; i < pcVPS->m_numDpbParams; i++ )
{
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
{
WRITE_CODE(pcVPS->m_dpbMaxTemporalId[i], 3, "dpb_max_temporal_id[i]");
}
else
{
CHECK(pcVPS->m_dpbMaxTemporalId[i] != pcVPS->getMaxSubLayers() - 1, "When vps_all_layers_same_num_sublayers_flag is equal to 1, the value of dpb_max_temporal_id[ i ] is inferred to be equal to vps_max_sublayers_minus1");
}
#else
if( pcVPS->getMaxSubLayers() == 1 )
{
CHECK( pcVPS->m_dpbMaxTemporalId[i] != 0, "When vps_max_sublayers_minus1 is equal to 0, the value of dpb_max_temporal_id[ i ] is inferred to be equal to 0" );
......@@ -1480,6 +1514,7 @@ void HLSWriter::codeVPS(const VPS* pcVPS)
WRITE_CODE( pcVPS->m_dpbMaxTemporalId[i], 3, "dpb_max_temporal_id[i]" );
}
}
#endif
for( int j = ( pcVPS->m_sublayerDpbParamsPresentFlag ? 0 : pcVPS->m_dpbMaxTemporalId[i] ); j <= pcVPS->m_dpbMaxTemporalId[i]; j++ )
{
......@@ -1515,7 +1550,11 @@ void HLSWriter::codeVPS(const VPS* pcVPS)
WRITE_UVLC(pcVPS->getNumOlsHrdParamsMinus1(), "num_ols_hrd_params_minus1");
for (int i = 0; i <= pcVPS->getNumOlsHrdParamsMinus1(); i++)
{
#if JVET_R0107_VPS_SIGNALING
if (!pcVPS->getAllLayersSameNumSublayersFlag())
#else
if (((pcVPS->getMaxSubLayers()-1) > 0) && (!pcVPS->getAllLayersSameNumSublayersFlag()))
#endif
{
WRITE_CODE(pcVPS->getHrdMaxTid(i), 3, "hrd_max_tid[i]");
}
......