1. 07 Mar, 2013 2 commits
    • 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
  2. 06 Mar, 2013 1 commit
    • Paul Wilkins's avatar
      Added stricter Q control flag. · db6ad013
      Paul Wilkins authored
      Added a variant of the one shot maxQ flag
      for two pass that forces a fixed Q for the
      normal inter frames. Disabled by default.
      Also small adjustment to the Bits per MB
      estimation.
      Change-Id: I87efdfb2d094fe1340ca9ddae37470d7b278c8b8
      db6ad013
  3. 05 Mar, 2013 2 commits
    • Dmitry Kovalev's avatar
      Code cleanup. · 7f99c3c5
      Dmitry Kovalev authored
      Removing redundant 'extern' keywords, fixing formatting and #include order,
      code simplification.
      
      Change-Id: I0e5fdc8009010f3f885f13b5d76859b9da511758
      7f99c3c5
    • 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
  4. 04 Mar, 2013 1 commit
    • Jingning Han's avatar
      Support 16K sequence coding · 5957b2b5
      Jingning Han authored
      Fixed a couple of variable/function definitions, as well as header
      handling to support 16K sequence coding at high bit-rates.
      
      The width and height are each specified by two bytes in the header.
      Use an extra byte to explicitly indicate the scaling factors in
      both directions, each ranging from 0 to 15.
      
      Tested coding up to 16400x16400 dimension.
      
      Change-Id: Ibc2225c6036620270f2c0cf5172d1760aaec10ec
      5957b2b5
  5. 02 Mar, 2013 2 commits
    • John Koleszar's avatar
      Add unit test for x4 multi-SAD functions · 1cfc86eb
      John Koleszar authored
      Update the function prototypes to match between VP9 and VP8.
      
      Change-Id: If58965073989e87df3b62b67a030ec6ce23ca04f
      1cfc86eb
    • Dmitry Kovalev's avatar
      Code cleanup. · 135428e9
      Dmitry Kovalev authored
      Removing redundant 'extern' keyword, lowercase variable names.
      
      Change-Id: I608e8d8579aba8981f5fac3493f77b4481b13808
      135428e9
  6. 01 Mar, 2013 1 commit
    • Yaowu Xu's avatar
      Adjust the max_gf_interval initialization · cea8cd08
      Yaowu Xu authored
      to be a fixed value of 15.
      
      Test results:
      cif:  .124%, .068%, .081%
      std-hd: 2.809%, 3.174%, 2.705%
      
      Change-Id: I380c8152c973506094da15eab59e3aa22b75a983
      cea8cd08
  7. 28 Feb, 2013 8 commits
  8. 27 Feb, 2013 8 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
      Remove unused vp9_copy32xn · 7ad8dbe4
      John Koleszar authored
      This function was part of an optimization used in VP8 that required
      caching two macroblocks. This is unused in VP9, and might not
      survive refactoring to support superblocks, so removing it for now.
      
      Change-Id: I744e585206ccc1ef9a402665c33863fc9fb46f0d
      7ad8dbe4
    • Jan Kratochvil's avatar
      Fix --as=nasm compatibility for new asm code. · 82ed3f9a
      Jan Kratochvil authored
      s/movd/movq/
      
      Change-Id: Id1a56de91551f8dc796f14f1056c565dfc1ba626
      82ed3f9a
    • John Koleszar's avatar
      Use ref_frame_map vice active_ref_idx on the encoder · 800ad0b8
      John Koleszar authored
      This patch makes the encoder's use of ref_frame_map and active_ref_idx
      consistent with the decoder. ref_frame_map[] maps a reference buffer
      index to its actual location in the yv12_fb array, since many
      references may share an underlying buffer. active_ref_idx[] mirrors
      cpi->{lst,gld,alt}_fb_idx, holding the active references in each
      slot.
      
      This also fixes a bug in setup_buffer_inter() where the incorrect
      reference was used to populate the scaling factors.
      
      Change-Id: Id3728f6d77cffcd27c248903bf51f9c3e594287e
      800ad0b8
    • John Koleszar's avatar
      Test upscaling as well as downscaling · b683eecf
      John Koleszar authored
      Fixes a bug in vp9_set_internal_size() that prevented returning to
      the unscaled state. Updated the ResizeInternalTest to scale both
      down and up. Added a check that all frames are within 2.5% of the
      quality of the initial keyframe.
      
      Change-Id: I3b7ef17cdac144ed05b9148dce6badfa75cff5c8
      b683eecf
    • John Koleszar's avatar
      Combined motion compensation with scaled predictors · 77f88e97
      John Koleszar authored
      This patch extends the previous support for using references of a
      different resolution in ZEROMV mode to all inter prediction modes.
      Subpixel based best-mv scoring is disabled when the reference frame
      differs in resolution from the current frame.
      
      Change-Id: Id4dc3e5e6692de98d9857fd56bfad3ac57e944ac
      77f88e97
    • 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
  9. 26 Feb, 2013 7 commits
  10. 25 Feb, 2013 5 commits
    • James Zern's avatar
      vp9: promote gf_group_bits calculation to 64-bit · b2fc3ca0
      James Zern authored
      avoids signed integer overflow
      
      Change-Id: I9ffcdba90b21edb324d1b173fd11d613e0592931
      b2fc3ca0
    • Jingning Han's avatar
      Improving the forward 16x16 ADST/DCT accuracy · 65821d66
      Jingning Han authored
      Increase the first stage dynamic range by 4 times, and reduce it
      back with proper rounding before applying the second stage. Hence
      it still fits in the given dynamic range and slightly improves
      the key frame coding performance.
      
      Change-Id: Ia4c5907446f20a95dc3de079c314b3ad1221d8aa
      65821d66
    • Jingning Han's avatar
      clean up forward and inverse hybrid transform · 77a3becf
      Jingning Han authored
      Rebased.
      
      Remove the old matrix multiplication transform computation. The 16x16
      ADST/DCT can be switched on/off and evaluated by setting ACTIVE_HT16
      300/0 in vp9/common/vp9_blockd.h.
      
      Change-Id: Icab2dbd18538987e1dc4e88c45abfc4cfc6e133f
      77a3becf
    • Paul Wilkins's avatar
      Minor rate control refactoring and experiments. · 97da8b8c
      Paul Wilkins authored
      Some minor refactoring code relating to estimates of
      bits per MB at a given Q and estimating the allowed Q range.
      
      Most of the changes here were included in a previous commit.
      This commit seeks to separate out the refactoring from more
      the material changes.
      
      Two #define control flags have been added for experimentation.
      
      ONE_SHOT_Q_ESTIMATE force the two pass encoder to
      use its initial Q range estimate for the whole clip even if this results
      in a miss on the target data rate. In effect this tightens the Q range
      seen at the expense of rate control accuracy.
      
      DISABLE_RC_LONG_TERM_MEM is a related flag that disables the
      long term memory in the rate control. Local adjustments are still
      made to try and better hit the rate target on a per frame basis but
      the impact of rate control misses is not propagated to the remainder
      of the clip. This means that for example an overshoot early on will not
      cause frames later in the clip to be starved of bits. Again the result
      of this relaxation amy be less rate control accuracy especially on short
      clips.
      
      The flags are disabled by default for now.
      
      Change-Id: I7482f980146d8ea033b5d50cc689f772e4bd119e
      97da8b8c
    • Yaowu Xu's avatar
      optimize forward 16x16 DCT for accuracy · 499fe05d
      Yaowu Xu authored
      This commit added pre/post scaling for first half of fDCT16x16 to
      reduce error, by simulation of 100,000 blocks for random inputs,
      the average sse reduced from 2.1/block to 0.0498/block.
      
      also enabled tests for 16x16 fDCT and iDCT
      
      Change-Id: Id2a95f0464c6dd4118797d456237ae90274c0f02
      499fe05d
  11. 23 Feb, 2013 3 commits
    • Ronald S. Bultje's avatar
      Split coefficient token tables intra vs. inter. · 0c9e2e9a
      Ronald S. Bultje authored
      Change-Id: I5416455f8f129ca0f450d00e48358d2012605072
      0c9e2e9a
    • Paul Wilkins's avatar
      Further changes to coefficient contexts. · c17672a3
      Paul Wilkins authored
      This patch alters the balance of context between the
      coefficient bands (reflecting the position of coefficients
      within a transform blocks) and the energy of the previous
      token (or tokens) within a block.
      
      In this case the number of coefficient bands is reduced
      but more previous token energy bands are supported.
      
      Some initial rebalancing of the default tables has been
      by running multiple derf clips at multiple data rates using
      the ENTOPY_STATS macro. Further balancing needs to be
      done using larger image formatsd especially in regard to
      the bigger transform sizes which are not as well represented
      in encodings of smaller image formats.
      
      Change-Id: If9736e95c391e711b04aef6393d26f60f36e1f8a
      c17672a3
    • Yaowu Xu's avatar
      optimize 8x8 fdct rounding for accuracy · 22012ee9
      Yaowu Xu authored
      The commit added a final rounding choice for 8x8 forward dct to get
      rid of a sign bias at DC position and improve the accuracry in term
      of round trip error for 8x8 fDCT/iDCT.
      
      This commit also enabled forward 8x8 dct test.
      
      Change-Id: Ib67f99b0a24d513e230c7812bc04569d472fdc50
      22012ee9