• Rupert Swarbrick's avatar
    striped-loop-restoration: Respect tile experiments · 921b334f
    Rupert Swarbrick authored
    As of patch https://aomedia-review.googlesource.com/c/aom/+/28821 ,
    loop-restoration units cannot cross tile borders. But the context
    around each processing unit was still allowed to cross tile borders.
    This is fine in the usual case - but, when loop filtering across tiles
    is switched off, we're supposed to be able to decode each tile completely
    independently (each tile column, if dependent-horztiles is on).
    
    Roughly, the change we need to make is:
    When loop filtering across tiles is switched off, we treat each tile
    as if it were a full frame, and extend the CDEF output for that tile
    to form a 3-pixel border around the tile. We only use deblocked
    above/below pixels for processing unit boundaries which lie inside
    a tile.
    
    In terms of the code, this is implemented in two parts. This only
    applies when the loop_filter_across_tiles_flag is false; otherwise,
    we keep the old behaviour.
    
    * For processing units at the top edge of a tile, fill the above context
      with copies of the topmost line of CDEF output *from the same tile*,
      rather than using deblocked pixels from the tile above.
      The below context of processing units at the bottom edge of a tile
      is treated analogously.
    
    * When setting up the boundary for a processing stripe at the left edge
      of a tile, fill the stripe's left boundary with copies of the
      leftmost column of CDEF output from the same tile. Again, processing
      stripes at the right edge of a tile are treated analogously.
    
      Similarly to the above/below boundaries, we store the overwritten
      pixels into a pair of left/right context buffers, and restore them
      to their original values once we've dealt with that processing stripe.
    
    Change-Id: I53a0932793c1c56dc037683c6a4353a3f5dc4539
    921b334f
decodeframe.c 145 KB