View Issue Details

IDProjectCategoryView StatusLast Update
0000049JVT JM H.264/AVC reference softwaredecoderpublic2008-09-02 16:30
ReporterPeter Farkas Assigned ToKarsten Suehring  
PrioritynormalSeverityminorReproducibilityN/A
Status resolvedResolutionno change required 
Product VersionJM 12.2 
Summary0000049: sps->mb_adaptive_frame_field_flag should be initialized to 0
DescriptionIf I am not mistaken, the standard says:

When mb_adaptive_frame_field_flag is not present,
it shall be inferred to be equal to 0.

On the other hand, in parset.c I see

  if (!sps->frame_mbs_only_flag)
  {
    sps->mb_adaptive_frame_field_flag =
      u_1("SPS: mb_adaptive_frame_field_flag", s);
  }

(spacing changed for readability) as the only place
where sps->mb_adaptive_frame_field_flag is given a
value.

It seems to me that somewhere before this if block
sps->mb_adaptive_frame_field_flag should be set to
0, to make sure that if not present, it shall be
inferred to be equal to 0.

I confess that I did not follow through the use of
this variable in the reference code, so maybe it
is set to zero implicitely elsewhere, or maybe its
value is not used explicitely in the code when it
is not 0. If so, initializing it to 0 would not
be not necessary. However, it may not hurt, even
in these cases.
TagsNo tags attached.

Activities

Karsten Suehring

2008-09-02 16:30

administrator   ~0000229

We allocate SPS using calloc() which implicitly initializes all fields with zero. So we don't have to explicitly take care of the frame_mbs_only_flag.

Issue History

Date Modified Username Field Change
2007-05-19 01:03 Peter Farkas New Issue
2007-05-23 13:37 Karsten Suehring Assigned To => Karsten Suehring
2007-05-23 13:37 Karsten Suehring Status new => acknowledged
2008-09-02 16:30 Karsten Suehring Note Added: 0000229
2008-09-02 16:30 Karsten Suehring Status acknowledged => resolved
2008-09-02 16:30 Karsten Suehring Resolution open => no change required