Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
V
VVCSoftware_VTM
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
jvet
VVCSoftware_VTM
Commits
81e541b2
Commit
81e541b2
authored
5 years ago
by
Kui Fan
Browse files
Options
Downloads
Patches
Plain Diff
add more checks
parent
c19ca597
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1282
JVET-Q0114: AHG9: A few more general constraints flags
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
source/Lib/DecoderLib/VLCReader.cpp
+28
-0
28 additions, 0 deletions
source/Lib/DecoderLib/VLCReader.cpp
with
28 additions
and
0 deletions
source/Lib/DecoderLib/VLCReader.cpp
+
28
−
0
View file @
81e541b2
...
...
@@ -481,6 +481,13 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS, ParameterSetManager *parameterSetMana
#endif
}
#if JVET_Q0114_CONSTRAINT_FLAGS
SPS
*
sps
=
parameterSetManager
->
getSPS
(
pcPPS
->
getSPSId
());
if
(
sps
->
getProfileTierLevel
()
->
getConstraintInfo
()
->
getOneTilePerPicConstraintFlag
())
{
CHECK
(
pcPPS
->
getNumTiles
()
!=
1
,
"invalid number of tiles"
);
}
#endif
READ_FLAG
(
uiCode
,
"no_pic_partition_flag"
);
pcPPS
->
setNoPicPartitionFlag
(
uiCode
==
1
);
if
(
!
pcPPS
->
getNoPicPartitionFlag
())
...
...
@@ -520,6 +527,13 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS, ParameterSetManager *parameterSetMana
int32_t
tileIdx
=
0
;
READ_UVLC
(
uiCode
,
"num_slices_in_pic_minus1"
);
pcPPS
->
setNumSlicesInPic
(
uiCode
+
1
);
#if JVET_Q0114_CONSTRAINT_FLAGS
SPS
*
sps
=
parameterSetManager
->
getSPS
(
pcPPS
->
getSPSId
());
if
(
sps
->
getProfileTierLevel
()
->
getConstraintInfo
()
->
getOneSlicePerPicConstraintFlag
())
{
CHECK
(
uiCode
!=
0
,
"invalid num_slices_in_pic_minus1 value"
);
}
#endif
CHECK
(
pcPPS
->
getNumSlicesInPic
()
>
MAX_SLICES
,
"Number of slices in picture exceeds valid range"
);
READ_CODE
(
1
,
uiCode
,
"tile_idx_delta_present_flag"
);
pcPPS
->
setTileIdxDeltaPresentFlag
(
uiCode
==
1
);
pcPPS
->
initRectSlices
();
...
...
@@ -585,8 +599,10 @@ void HLSyntaxReader::parsePPS( PPS* pcPPS, ParameterSetManager *parameterSetMana
// initialize mapping between rectangular slices and CTUs
pcPPS
->
initRectSliceMap
();
#if JVET_O1143_SUBPIC_BOUNDARY
#if !JVET_Q0114_CONSTRAINT_FLAGS
SPS
*
sps
=
parameterSetManager
->
getSPS
(
pcPPS
->
getSPSId
());
CHECK
(
sps
==
0
,
"Invalid SPS"
);
#endif
pcPPS
->
initSubPic
(
*
sps
);
#endif
}
...
...
@@ -1329,6 +1345,12 @@ void HLSyntaxReader::parseSPS(SPS* pcSPS)
#else
READ_CODE
(
8
,
uiCode
,
"sps_num_subpics_minus1"
);
pcSPS
->
setNumSubPics
(
uiCode
+
1
);
#endif
#if JVET_Q0114_CONSTRAINT_FLAGS
if
(
pcSPS
->
getProfileTierLevel
()
->
getConstraintInfo
()
->
getOneSubpicPerPicConstraintFlag
())
{
CHECK
(
uiCode
!=
0
,
"invalid sps_num_subpics_minus1 value"
);
}
#endif
#if JVET_Q0816
if
(
pcSPS
->
getNumSubPics
()
==
1
)
...
...
@@ -3215,6 +3237,12 @@ void HLSyntaxReader::parseSliceHeader (Slice* pcSlice, PicHeader* picHeader, Par
int
bitsSliceAddress
=
ceilLog2
(
pps
->
getNumTiles
());
READ_CODE
(
bitsSliceAddress
,
uiCode
,
"slice_address"
);
sliceAddr
=
uiCode
;
READ_UVLC
(
uiCode
,
"num_tiles_in_slice_minus1"
);
numTilesInSlice
=
uiCode
+
1
;
#if JVET_Q0114_CONSTRAINT_FLAGS
if
(
!
pps
->
getRectSliceFlag
()
&&
sps
->
getProfileTierLevel
()
->
getConstraintInfo
()
->
getOneSlicePerPicConstraintFlag
())
{
CHECK
(
pps
->
getNumTiles
()
!=
uiCode
+
1
,
"invalid num_tiles_in_slice_minus1 value"
);
}
#endif
}
else
{
sliceAddr
=
0
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment