Opened 12 years ago

Closed 12 years ago

#563 closed defect (fixed)

GolombDecode for ALF params does not match text ge(v)

Reported by: pieterkapsenberg Owned by: bbross
Priority: minor Milestone: D7
Component: Text Version: D7 (I1003) d4
Keywords: golomb decode Cc: fbossen, ksuehring, davidf, jct-vc@…

Description

TDecCAVLC.cpp, line 922 is the signed Golomb decode function which calls the unsigned decode function xReadEpExGolomb on line 2197.
This function does not match the text, or the CABAC counterpart in TDecSbac.ccp on line 285:

Void TDecCavlc::xReadEpExGolomb( UInt& ruiSymbol, UInt uiCount )
{
  UInt uiSymbol = 0;
  UInt uiBit = 1;
  
  
  while( uiBit )
  {
    xReadFlag( uiBit );
    uiSymbol += uiBit << uiCount++;
  }
  
  uiCount--;
  while( uiCount-- )
  {
    xReadFlag( uiBit );
    uiSymbol += uiBit << uiCount; // This shift is wrong
  }
  
  ruiSymbol = uiSymbol;
  
  return;
}

Text:

q = −1
codeNum = 0
bit = 1
while( bit ){

bit = read_bits( 1 )
q++

}
for(a = 0; a < k; ++a){

bit = read_bits( 1 )
if( bit )

codeNum += (1 << a)

}
codeNum += q << k

---- Below not part of the function ----

if( codeNum != 0 ) {

bit = read_bits( 1 )
codeNum = ( bit ) ? codeNum : ( −codeNum )

}

The function xGolombDecode on line 922 should just be re-written to match the text, and not call xReadEpExGolomb (which can just be removed all together).

Change History (3)

comment:1 Changed 12 years ago by DefaultCC Plugin

  • Cc fbossen ksuehring davidf jct-vc@… added

comment:2 Changed 12 years ago by bbross

  • Component changed from HM to Text
  • Milestone changed from HM-7.1 to D7
  • Owner set to bbross
  • Version changed from HM-7.0 to D7 (I1003) d4

Actually this is a text issue but the text is fixed in JCTVC-I0603_CDText, so HM and CD text are matched.

comment:3 Changed 12 years ago by bbross

  • Resolution set to fixed
  • Status changed from new to closed

This is fixed in JCTVC-I1003 d5 (v6).

Note: See TracTickets for help on using tickets.

This list contains all users that will be notified about changes made to this ticket.

These roles will be notified: Reporter, Owner, Subscriber, Participant

  • Benjamin Bross(Owner, Participant)
  • David Flynn(Subscriber)
  • Frank Bossen(Subscriber)
  • jct-vc@…(Subscriber)
  • karl.sharman@…(Always)
  • Karsten Suehring(Subscriber, Always)
  • Pieter Kapsenberg(Reporter)