1. 13 Jan, 2016 11 commits
    • Kieran Kunhya's avatar
      bfc8a4da
    • Claudio Freire's avatar
      AAC encoder: encode out-of-phase I/S efficiently · 699c2ee5
      Claudio Freire authored
      Use the ability to invert phase with ms_mask instead of changing
      the codebook when possible, to avoid having to switch codebooks
      if some bands are INTENSTY_BT and others are INTENSITY_BT2, since
      usually a set ms_mask uses less bits that a codebook change. While
      it may not always be a win (ie: if it causes an ms_mask bitmap
      to be sent when it wouldn't have been otherwise), it's unlikely
      since the ms_mask bitmap will almost always be there already for
      M/S itself.
      699c2ee5
    • Claudio Freire's avatar
      AAC encoder: fix I/S relative error evaluation · aa64a483
      Claudio Freire authored
      The relative error between two encoding strategies is the simple
      difference of rate-distortion values, and not the absolute
      difference. An absolute measure would allow worsening of the
      quantization error as well as improving.
      aa64a483
    • Claudio Freire's avatar
      AAC encoder: various fixes in M/S coding · 6711aa21
      Claudio Freire authored
      1. Fix sf_idx and band_type addressing to address only the first
      subwindow in the group (others could hold garbage values)
      
      2. Don't step on ms_mask when is_mask is set. I/S selection
      already sets the ms_mask properly and shouldn't be overridden.
      
      3. Use mid/sid cb/sf when computing coding error, as should be
      since those are the cb/sfs that will eventually be set.
      
      4. Fix distortion computation on multi-subwindow groups (was
      subtracting the bits terms multiple times)
      
      5. Clear ms_mask when one side uses PNS and the other doesn't.
      When using PNS, ms_mask signals correlated noise, which can be
      detected just like regular M/S detection, so we don't skip
      noise bands, but when only one side uses PNS setting the flag
      can confuse some encoders, so avoid that.
      6711aa21
    • Claudio Freire's avatar
      AAC encoder: in IS, fix index of sf_idx, band_type · 4dcb69cc
      Claudio Freire authored
      Correct addressing of sf_idx and band_type arrays in I/S code.
      
      Both arrays don't guarantee valid values for subwindows at all
      times, depending on which coder is being used, which could result
      in reading of garbage values. Instead, only the first subwindow
      in the window group has to be used, ie: use w*16+g instead of
      (w+w2)*16+g
      4dcb69cc
    • Claudio Freire's avatar
      AAC encoder: don't apply MS on special bands · 509f1680
      Claudio Freire authored
      Change the condition for application of the M/S transform to match
      that of the decoder. Namely, that no special coding books must be
      in use in either channel. While the condition ought to be
      equivalent to the current one when the invariant of is_mask is
      kept, matching the decoder's condition is safer and easier to
      maintain.
      509f1680
    • Claudio Freire's avatar
      AAC encoder: avoid assertion failure on PNS · 00d481b2
      Claudio Freire authored
      In rare corner cases it could still fail an assert on sf_diff due
      to failure to update prev_sf in some code paths. Fix that case.
      00d481b2
    • Claudio Freire's avatar
      AAC encoder: fix assertion error with prediction · 2a31b076
      Claudio Freire authored
      Fixes an assertion error reported in #2686 that happens when
      using prediction (either explicitly or implicitly by setting
      the AAC main profile), since prediction code would allow
      creating new zeroes or removing existing ones, without
      properly checking for SF delta violations.
      
      This patch forbids creating/removing zeroes, perhaps an
      overly conservative approach, but a safe one. More permissive
      and sophisticated approaches may be attempted in the future.
      2a31b076
    • Carl Eugen Hoyos's avatar
      lavc/mjpeg2jpeg: Accept more mjpeg streams as input. · d3fe2e0d
      Carl Eugen Hoyos authored
      Fixes ticket #5151.
      d3fe2e0d
    • Michael Niedermayer's avatar
    • Michael Niedermayer's avatar
      avformat/aviobuf: Fix end check in put_str16() · 115fb6d0
      Michael Niedermayer authored
      Fixes out of array read
      Fixes: 03c406ec9530e594a074ce2979f8a1f0/asan_heap-oob_7dec26_4664_37c52495b2870a2eaac65f53958e76c1.flac
      
      Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
      Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
      115fb6d0
  2. 12 Jan, 2016 12 commits
  3. 11 Jan, 2016 10 commits
  4. 10 Jan, 2016 7 commits