1. 04 Jan, 2023 29 commits
  2. 21 Dec, 2022 11 commits
    • Ensure supported request only updates changes fields. · 59166cce
      The TransformationRequest passed to FallbackListener (and
      createSupportedTransformationRequest) can have null for values that
      are inferred from source. Within fallback, this can be height, width,
      video mime type and audio mime type (HDR mode is not linked to source).
      requestedFormat has these values populated from source, and
      supportedFormat then finds the closest supported values to the
      requested.
      
      If any of the values in supportedFormat do not match the
      requestedFormat, then this method would build upon the
      TransformationRequest and update ALL possible fallback fields. This is
      a problem because the fallback listener compares the original request
      to the fallback one and notifies about all the fields that have
      changed.
      
      This CL changes this so that only the values that are not the same as
      requested are changed in the supported request that is given to the
      fallback listener.
      
      PiperOrigin-RevId: 496908492
      samrobinson committed
    • Fix AS warnings and errors in FloatAudioMixingAlgorithmTest · cad713d0
      When trying to run the test on Android Studio, error "incompatible
      types: Buffer cannot be converted to ByteBuffer" is logged. This is
      because ByteBuffer.flip() returns a Buffer (and not a ByteBuffer).
      Annotation @CovariantReturnType on ByteBuffer.flip() should resolve this
      automatically but it doesn't seem supported at the moment.
      PiperOrigin-RevId: 496894723
      kimvde committed
    • Fix recursive loop when registering controller visibility listeners · 4087a011
      There are two overloads of this method due to a type 'rename' from
      `PlayerControlView.VisibilityListener` to
      `PlayerView.ControllerVisibilityListener`. Currently when you call one
      overload it passes `null` to the other one (to clear the other listener).
      Unfortunately this results in it clearing itself, because it receives
      a null call back!
      
      This change tweaks the documentation to clarify that the 'other'
      listener is only cleared if you pass a non-null listener in. This solves
      the recursive problem, and allows the 'legacy' visibility listener to be
      successfully registered.
      
      Issue: androidx/media#229
      
      #minor-release
      
      PiperOrigin-RevId: 496876397
      ibaker committed
    • Add error messages to correctness assertions in SimpleBasePlayer · 6c98f238
      Users of this class may run into these assertions when creating the
      State and they need to check the source code to understand why
      the State is invalid. Adding error messages to all our correctness
      assertions helps to understand the root cause more easily.
      
      PiperOrigin-RevId: 496875109
      tonihei committed
    • Simplify AssetLoader.Listener interface · a4c3038b
      Replace onTrackRegistered and onAllTracksRegistered with onTrackCount.
      
      PiperOrigin-RevId: 496853037
      kimvde committed
    • HDR: Use SDR settings for gamma 2.2 in createEglSurface · 06ccb6e8
      PiperOrigin-RevId: 496768072
      huangdarwin committed
    • HDR: Add Transformer GL tone mapping test. · 99b665ca
      PiperOrigin-RevId: 496727803
      huangdarwin committed
    • Simplify concurrency in FrameProcessingTaskExecutor · cb0bc28a
      This CL replaces concurrent collections and atomic primitives with a single
      lock, this way the code is easier to reason about.
      
      PiperOrigin-RevId: 496718057
      claincly committed
    • HDR: Implement Transformer HDR to SDR GL tone-mapping API · 84c81b85
      Note that we simply use GlEffectsFrameProcessor in-app / GL tone-mapping, so PQ->SDR tone-mapping isn't yet implemented.
      
      Tested manually using the demo on Pixel 7, to confirm that device and in-app tone
      mapping behave similarly.
      
      PiperOrigin-RevId: 496700231
      huangdarwin committed
    • Add low level audio mixing algorithms · 9465fe2f
      Adds the AudioMixerAlgorithm interface which allows for specialized
      implementations of audio mixing that also efficiently convert between
      source and mixing formats.
      
      Initial implementation has two algorithms:
      1. Float -> float (with channel mixing)
      2. S16 -> float (with channel mixing)
      
      PiperOrigin-RevId: 496686805
      steveanton committed
    • Document the relationship between Player methods and available commands · d8c964cf
      #minor-release
      
      PiperOrigin-RevId: 496668378
      ibaker committed