Commit bb3c8389 authored by Frank Bossen's avatar Frank Bossen

Merge branch 'fix-209' into 'master'

Fix ticket #209: condition to parse pcm_flag

See merge request !381
parents f09cb277 33b8bde5
Pipeline #1120 canceled with stage
......@@ -1185,8 +1185,8 @@ void CABACReader::pred_mode( CodingUnit& cu )
void CABACReader::pcm_flag( CodingUnit& cu, Partitioner &partitioner )
{
const SPS& sps = *cu.cs->sps;
if( !sps.getPCMEnabledFlag() || cu.lwidth() > (1 << sps.getPCMLog2MaxSize()) || cu.lwidth() < (1 << sps.getPCMLog2MinSize())
|| cu.lheight() > (1 << sps.getPCMLog2MaxSize()) || cu.lheight() < (1 << sps.getPCMLog2MinSize()) )
if( !sps.getPCMEnabledFlag() || partitioner.currArea().lwidth() > (1 << sps.getPCMLog2MaxSize()) || partitioner.currArea().lwidth() < (1 << sps.getPCMLog2MinSize())
|| partitioner.currArea().lheight() > (1 << sps.getPCMLog2MaxSize()) || partitioner.currArea().lheight() < (1 << sps.getPCMLog2MinSize()) )
{
cu.ipcm = false;
return;
......
......@@ -921,8 +921,8 @@ void CABACWriter::pcm_data( const CodingUnit& cu, Partitioner& partitioner )
void CABACWriter::pcm_flag( const CodingUnit& cu, Partitioner& partitioner )
{
const SPS& sps = *cu.cs->sps;
if( !sps.getPCMEnabledFlag() || cu.lwidth() > (1 << sps.getPCMLog2MaxSize()) || cu.lwidth() < (1 << sps.getPCMLog2MinSize())
|| cu.lheight() > (1 << sps.getPCMLog2MaxSize()) || cu.lheight() < (1 << sps.getPCMLog2MinSize()) )
if( !sps.getPCMEnabledFlag() || partitioner.currArea().lwidth() > (1 << sps.getPCMLog2MaxSize()) || partitioner.currArea().lwidth() < (1 << sps.getPCMLog2MinSize())
|| partitioner.currArea().lheight() > (1 << sps.getPCMLog2MaxSize()) || partitioner.currArea().lheight() < (1 << sps.getPCMLog2MinSize()) )
{
return;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment