1. 04 Apr, 2013 1 commit
  2. 02 Apr, 2013 1 commit
    • Dmitry Kovalev's avatar
      Code cleanup. · 50e54c11
      Dmitry Kovalev authored
      Adding multiple16 function, removing redundant code, better formatting.
      
      Change-Id: I50195b78ac8ab803e3d05c8fb05a7ca134fab386
      50e54c11
  3. 28 Mar, 2013 1 commit
    • Deb Mukherjee's avatar
      Framework changes in nzc to allow more flexibility · fe9b5143
      Deb Mukherjee authored
      The patch adds the flexibility to use standard EOB based coding
      on smaller block sizes and nzc based coding on larger blocksizes.
      The tx-sizes that use nzc based coding and those that use EOB based
      coding are controlled by a function get_nzc_used().
      By default, this function uses nzc based coding for 16x16 and 32x32
      transform blocks, which seem to bridge the performance gap
      substantially.
      
      All sets are now lower by 0.5% to 0.7%, as opposed to ~1.8% before.
      
      Change-Id: I06abed3df57b52d241ea1f51b0d571c71e38fd0b
      fe9b5143
  4. 26 Mar, 2013 1 commit
    • Deb Mukherjee's avatar
      Implicit weighted prediction experiment · 23144d23
      Deb Mukherjee authored
      Adds an experiment to use a weighted prediction of two INTER
      predictors, where the weight is one of (1/4, 3/4), (3/8, 5/8),
      (1/2, 1/2), (5/8, 3/8) or (3/4, 1/4), and is chosen implicitly
      based on consistency of the predictors to the already
      reconstructed pixels to the top and left of the current macroblock
      or superblock.
      
      Currently the weighting is not applied to SPLITMV modes, which
      default to the usual (1/2, 1/2) weighting. However the code is in
      place controlled by a macro. The same weighting is used for Y and
      UV components, where the weight is derived from analyzing the Y
      component only.
      
      Results (over compound inter-intra experiment)
      derf: +0.18%
      yt: +0.34%
      hd: +0.49%
      stdhd: +0.23%
      
      The experiment suggests bigger benefit for explicitly signaled weights.
      
      Change-Id: I5438539ff4485c5752874cd1eb078ff14bf5235a
      23144d23
  5. 19 Mar, 2013 1 commit
  6. 07 Mar, 2013 3 commits
    • Ronald S. Bultje's avatar
      Update ADST selection if tx_size < block_size. · 89e4ce20
      Ronald S. Bultje authored
      Change-Id: Ic9b336486774c95ffbb92adcb110cc0fc2a83cc5
      89e4ce20
    • Ronald S. Bultje's avatar
      Re-add support for ADST in superblocks. · d3724abe
      Ronald S. Bultje authored
      This also changes the RD search to take account of the correct block
      index when searching (this is required for ADST positioning to work
      correctly in combination with tx_select).
      
      Change-Id: Ie50d05b3a024a64ecd0b376887aa38ac5f7b6af6
      d3724abe
    • Deb Mukherjee's avatar
      Coding con-zero count rather than EOB for coeffs · eb6ef241
      Deb Mukherjee authored
      This patch revamps the entropy coding of coefficients to code first
      a non-zero count per coded block and correspondingly remove the EOB
      token from the token set.
      
      STATUS:
      Main encode/decode code achieving encode/decode sync - done.
      Forward and backward probability updates to the nzcs - done.
      Rd costing updates for nzcs - done.
      Note: The dynamic progrmaming apporach used in trellis quantization
      is not exactly compatible with nzcs. A suboptimal approach has been
      used instead where branch costs are updated to account for changes
      in the nzcs.
      
      TODO:
      Training the default probs/counts for nzcs
      
      Change-Id: I951bc1e22f47885077a7453a09b0493daa77883d
      eb6ef241
  7. 05 Mar, 2013 1 commit
    • Ronald S. Bultje's avatar
      Make superblocks independent of macroblock code and data. · 111ca421
      Ronald S. Bultje authored
      Split macroblock and superblock tokenization and detokenization
      functions and coefficient-related data structs so that the bitstream
      layout and related code of superblock coefficients looks less like it's
      a hack to fit macroblocks in superblocks.
      
      In addition, unify chroma transform size selection from luma transform
      size (i.e. always use the same size, as long as it fits the predictor);
      in practice, this means 32x32 and 64x64 superblocks using the 16x16 luma
      transform will now use the 16x16 (instead of the 8x8) chroma transform,
      and 64x64 superblocks using the 32x32 luma transform will now use the
      32x32 (instead of the 16x16) chroma transform.
      
      Lastly, add a trellis optimize function for 32x32 transform blocks.
      
      HD gains about 0.3%, STDHD about 0.15% and derf about 0.1%. There's
      a few negative points here and there that I might want to analyze
      a little closer.
      
      Change-Id: Ibad7c3ddfe1acfc52771dfc27c03e9783e054430
      111ca421
  8. 28 Feb, 2013 1 commit
  9. 27 Feb, 2013 3 commits
    • Dmitry Kovalev's avatar
      Code cleanup. · 347f3a0a
      Dmitry Kovalev authored
      Fixing code style, using array lookup instead of switch statements for
      forward hybrid transforms (in the same way as for their inverses).
      Consistent usage of ROUND_POWER_OF_TWO macro in appropriate places.
      
      Change-Id: I0d3822ae11f928905fdbfbe4158f91d97c71015f
      347f3a0a
    • Ronald S. Bultje's avatar
      Move eob from BLOCKD to MACROBLOCKD. · e8c74e2b
      Ronald S. Bultje authored
      Consistent with VP8.
      
      Change-Id: I8c316ee49f072e15abbb033a80e9c36617891f07
      e8c74e2b
    • John Koleszar's avatar
      Spatial resamping of ZEROMV predictors · eb939f45
      John Koleszar authored
      This patch allows coding frames using references of different
      resolution, in ZEROMV mode. For compound prediction, either
      reference may be scaled.
      
      To test, I use the resize_test and enable WRITE_RECON_BUFFER
      in vp9_onyxd_if.c. It's also useful to apply this patch to
      test/i420_video_source.h:
      
        --- a/test/i420_video_source.h
        +++ b/test/i420_video_source.h
        @@ -93,6 +93,7 @@ class I420VideoSource : public VideoSource {
      
           virtual void FillFrame() {
             // Read a frame from input_file.
        +    if (frame_ != 3)
             if (fread(img_->img_data, raw_sz_, 1, input_file_) == 0) {
               limit_ = frame_;
             }
      
      This forces the frame that the resolution changes on to be coded
      with no motion, only scaling, and improves the quality of the
      result.
      
      Change-Id: I1ee75d19a437ff801192f767fd02a36bcbd1d496
      eb939f45
  10. 26 Feb, 2013 1 commit
    • John Koleszar's avatar
      Refactor inter recon functions to support scaling · 6a4f708c
      John Koleszar authored
      Ensure that all inter prediction goes through a common code path
      that takes scaling into account. Removes a bunch of duplicate
      1st/2nd predictor code. Also introduces a 16x8 mode for 8x8
      MVs, similar to the 8x4 trick we were doing before. This has an
      unexpected effect with EIGHTTAP_SMOOTH, so it's disabled in that
      case for now.
      
      Change-Id: Ia053e823a8bc616a988a0af30452e1e75a739cba
      6a4f708c
  11. 21 Feb, 2013 1 commit
  12. 20 Feb, 2013 2 commits
  13. 19 Feb, 2013 2 commits
    • Jingning Han's avatar
      16x16 butterfly inverse ADST/DCT hybrid transform · cd907b16
      Jingning Han authored
      rebased.
      
      This patch includes 16x16 butterfly inverse ADST/DCT hybrid
      transform. It uses the variant ADST of kernel
          sin((2k+1)*(2n+1)/4N),
      which allows a butterfly implementation.
      
      The coding gains as compared to DCT 16x16 are about 0.1% for
      both derf and std-hd. It is noteworthy that for std-hd sets
      many sequences gains about 0.5%, some 0.2%. There are also few
      points that provides -1% to -3% performance. Hence the average
      goes to about 0.1%.
      
      Change-Id: Ie80ac84cf403390f6e5d282caa58723739e5ec17
      cd907b16
    • Yaowu Xu's avatar
      Use lossless for Q0 · 93d6b86c
      Yaowu Xu authored
      The commit changes the coding mode to lossless whenever the lowest
      quantizer is choosen.
      
      As expected, test results showed no difference for cif and std-hd
      set where Q0 is rarely used. For yt and yt-hd set, Q0 is used for
      a number of clips, where this commit helped a lot in the high end.
      
      Average over all clips in the sets:
      yt: 2.391% 1.017% 1.066%
      hd: 1.937%  .764%  .787%
      
      Change-Id: I9fa9df8646fd70cb09ffe9e4202b86b67da16765
      93d6b86c
  14. 15 Feb, 2013 2 commits
  15. 13 Feb, 2013 4 commits
    • Ronald S. Bultje's avatar
      Remove 2nd-order transform for first-order DC coefficients. · 42d6be80
      Ronald S. Bultje authored
      Since addition of the larger-scale transforms (16x16, 32x32), these
      don't give a benefit at macroblock-sizes anymore. At superblock-sizes,
      2nd-order transform was never used over the larger transforms. Future
      work should test whether there is a benefit for that use case.
      
      Change-Id: I90cadfc42befaf201de3eb0c4f7330c56e33330a
      42d6be80
    • Yaowu Xu's avatar
      enable bitstream lossless support · 17db5d00
      Yaowu Xu authored
      1. Added a bit in frame header to  to indicate if a frame is encoded
      in lossless mode, so decoder does not make the decision based on Q0
      2. Minor changes to make sure that lossy coding works same as when
      the lossless experiment is not enabled.
      3. Renamed function pointers for transforms to be consistent, using
      prefix fwd_txm and inv_txm for forward and inverse respectively
      
      To encode in lossless mode, using "--lossless=1 --min-q=0 --max-q=0"
      with vpxenc.
      
      Change-Id: Ifae53b26d2ffbe378d707e29d96817b8a5e6c068
      17db5d00
    • Yaowu Xu's avatar
      fix the lossless experiment · 16f25f9d
      Yaowu Xu authored
      Change-Id: I95acfc1417634b52d344586ab97f0abaa9a4b256
      16f25f9d
    • Paul Wilkins's avatar
      Removal of Hybrid DWT/DCT experiment. · 649be94c
      Paul Wilkins authored
      Removal of experiment to simplify code base for other
      changes.
      
      Change-Id: If0a33952504558511926ad212bc311fc2bffb19a
      649be94c
  16. 11 Feb, 2013 1 commit
    • Jingning Han's avatar
      butterfly inverse 4x4 ADST · 57e995ff
      Jingning Han authored
      fixed format issues.
      
      Implement the inverse 4x4 ADST using 9 multiplications. For this
      particular dimension, the original ADST transform can be
      factorized into simpler operations, hence is retained.
      
      Change-Id: Ie5d9749942468df299ab74e90d92cd899569e960
      57e995ff
  17. 09 Feb, 2013 1 commit
    • John Koleszar's avatar
      Replace as_mv struct with array · 7ca517f7
      John Koleszar authored
      Replace as_mv.{first, second} with a two element array, so that they
      can easily be processed with an index variable.
      
      Change-Id: I1e429155544d2a94a5b72a5b467c53d8b8728190
      7ca517f7
  18. 08 Feb, 2013 1 commit
    • John Koleszar's avatar
      Pass macroblock index to pick inter functions · 6125a1ed
      John Koleszar authored
      Pass the current mb row and column around rather than the
      recon_yoffset and recon_uvoffset, since those offsets will
      change from predictor to predictor, based on the reference
      frame selection.
      
      Change-Id: If3f9df059e00f5048ca729d3d083ff428e1859c1
      6125a1ed
  19. 07 Feb, 2013 1 commit
    • Jingning Han's avatar
      Butterfly ADST based hybrid transform · d15e1da4
      Jingning Han authored
      Refactor the 8x8 inverse hybrid transform. It is now consistent
      with the new inverse DCT. Overall performance loss (due to the
      use of this variant ADST, and the rounding errors in the butterfly
      implementation) for std-hd is -0.02.
      
      Fixed BUILD warning.
      
      Devise a variant of the original ADST, which allows butterfly
      computation structure. This new transform has kernel of the
      form: sin((2k+1)*(2n+1) / (4N)). One of its butterfly structures
      using floating-point multiplications was reported in Z. Wang,
      "Fast algorithms for the discrete W transform and for the discrete
      Fourier transform", IEEE Trans. on ASSP, 1984.
      
      This patch includes the butterfly implementation of the inverse
      ADST/DCT hybrid transform of dimension 8x8.
      
      Change-Id: I3533cb715f749343a80b9087ce34b3e776d1581d
      d15e1da4
  20. 05 Feb, 2013 2 commits
    • Ronald S. Bultje's avatar
      [WIP] Add column-based tiling. · 1407bdc2
      Ronald S. Bultje authored
      This patch adds column-based tiling. The idea is to make each tile
      independently decodable (after reading the common frame header) and
      also independendly encodable (minus within-frame cost adjustments in
      the RD loop) to speed-up hardware & software en/decoders if they used
      multi-threading. Column-based tiling has the added advantage (over
      other tiling methods) that it minimizes realtime use-case latency,
      since all threads can start encoding data as soon as the first SB-row
      worth of data is available to the encoder.
      
      There is some test code that does random tile ordering in the decoder,
      to confirm that each tile is indeed independently decodable from other
      tiles in the same frame. At tile edges, all contexts assume default
      values (i.e. 0, 0 motion vector, no coefficients, DC intra4x4 mode),
      and motion vector search and ordering do not cross tiles in the same
      frame.
      t log
      
      Tile independence is not maintained between frames ATM, i.e. tile 0 of
      frame 1 is free to use motion vectors that point into any tile of frame
      0. We support 1 (i.e. no tiling), 2 or 4 column-tiles.
      
      The loopfilter crosses tile boundaries. I discussed this briefly with Aki
      and he says that's OK. An in-loop loopfilter would need to do some sync
      between tile threads, but that shouldn't be a big issue.
      
      Resuls: with tiling disabled, we go up slightly because of improved edge
      use in the intra4x4 prediction. With 2 tiles, we lose about ~1% on derf,
      ~0.35% on HD and ~0.55% on STD/HD. With 4 tiles, we lose another ~1.5%
      on derf ~0.77% on HD and ~0.85% on STD/HD. Most of this loss is
      concentrated in the low-bitrate end of clips, and most of it is because
      of the loss of edges at tile boundaries and the resulting loss of intra
      predictors.
      
      TODO:
      - more tiles (perhaps allow row-based tiling also, and max. 8 tiles)?
      - maybe optionally (for EC purposes), motion vectors themselves
        should not cross tile edges, or we should emulate such borders as
        if they were off-frame, to limit error propagation to within one
        tile only. This doesn't have to be the default behaviour but could
        be an optional bitstream flag.
      
      Change-Id: I5951c3a0742a767b20bc9fb5af685d9892c2c96f
      1407bdc2
    • John Koleszar's avatar
      Convert subpixel filters to use convolve framework · 7a07eea1
      John Koleszar authored
      Update the code to call the new convolution functions to do subpixel
      prediction rather than the existing functions. Remove the old C and
      assembly code, since it is unused. This causes a 50% performance
      reduction on the decoder, but that will be resolved when the asm for
      the new functions is available.
      
      There is no consensus for whether 6-tap or 2-tap predictors will be
      supported in the final codec, so these filters are implemented in
      terms of the 8-tap code, so that quality testing of these modes
      can continue. Implementing the lower complexity algorithms is a
      simple exercise, should it be necessary.
      
      This code produces slightly better results in the EIGHTTAP_SMOOTH
      case, since the filter is now applied in only one direction when
      the subpel motion is only in one direction. Like the previous code,
      the filtering is skipped entirely on full-pel MVs. This combination
      seems to give the best quality gains, but this may be indicative of a
      bug in the encoder's filter selection, since the encoder could
      achieve the result of skipping the filtering on full-pel by selecting
      one of the other filters. This should be revisited.
      
      Quality gains on derf positive on almost all clips. The only clip
      that seemed to be hurt at all datarates was football
      (-0.115% PSNR average, -0.587% min). Overall averages 0.375% PSNR,
      0.347% SSIM.
      
      Change-Id: I7d469716091b1d89b4b08adde5863999319d69ff
      7a07eea1
  21. 30 Jan, 2013 1 commit
  22. 28 Jan, 2013 1 commit
    • Paul Wilkins's avatar
      Segment Skip Flag · 0ff9b033
      Paul Wilkins authored
      First step in simplifying the segment mode and
      segment EOB flags into a simpler segment skip
      flag that implies 0,0 mv and EOB at position 0.
      
      Change-Id: Ib750cac31a7a02dc21082580498efd9f7d8d72a5
      0ff9b033
  23. 14 Jan, 2013 1 commit
    • Ronald S. Bultje's avatar
      Remove compound intra-intra experiment. · c9071601
      Ronald S. Bultje authored
      This experiment gives little gains and adds relatively much code
      complexity (and it hinders other experiments), so let's get rid of
      it.
      
      Change-Id: Id25e79a137a1b8a01138aa27a1fa0ba4a2df274a
      c9071601
  24. 13 Jan, 2013 1 commit
    • Deb Mukherjee's avatar
      Further enhancements/fixes on dct/dwt hybrid txfm · 516db21c
      Deb Mukherjee authored
      Fixes some scaling issues. Adds an option to only compute the
      dct on the low-low subband for 32x32 and 64x64 blocks using
      only a single 16x16 dct after 1 and 2 wavelet decomposition
      levels respectively. Also adds an option to use a 8x8 dct
      as building block.
      
      Currenlty with the 2/6 filter and with a single 16x16 dct on
      the low low band, the reuslts compared to full 32x32 dct is
      as follows:
      derf: -0.15%
      yt: -0.29%
      std-hd: -0.18%
      hd: -0.6%
      These are my current recommended settings, since the 2/6 filter
      is very simple.
      
      Results with 8x8 dct are about 0.3% worse.
      
      Change-Id: I00100cdc96e32deced591985785ef0d06f325e44
      516db21c
  25. 10 Jan, 2013 2 commits
  26. 09 Jan, 2013 1 commit
    • Adrian Grange's avatar
      New prediction filter · 7d6b5425
      Adrian Grange authored
      This patch removes the old pred-filter experiment and replaces it
      with one that is implemented using the switchable filter framework.
      
      If the pred-filter experiment is enabled, three interopolation
      filters are tested during mode selection; the standard 8-tap
      interpolation filter, a sharp 8-tap filter and a (new) 8-tap
      smoothing filter.
      
      The 6-tap filter code has been preserved for now and if the
      enable-6tap experiment is enabled (in addition to the pred-filter
      experiment) the original 6-tap filter replaces the new 8-tap smooth
      filter in the switchable mode.
      
      The new experiment applies the prediction filter in cases of a
      fractional-pel motion vector. Future patches will apply the filter
      where the mv is pel-aligned and also to intra predicted blocks.
      
      Change-Id: I08e8cba978f2bbf3019f8413f376b8e2cd85eba4
      7d6b5425
  27. 08 Jan, 2013 1 commit
  28. 06 Jan, 2013 1 commit