commit | ac74ec7e7e30e2219bd69308a4f6742bf8370830 | [log] [tgz] |
---|---|---|
author | Dale Sather <dalesat@google.com> | Tue Apr 28 01:42:44 2020 +0000 |
committer | CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org> | Tue Apr 28 01:42:44 2020 +0000 |
tree | f7295c0135cdedfb8d03bd83a53085268f0d8bc2 | |
parent | 39e93b04ca74a453be18757d39065390c3251979 [diff] |
[mediaplayer] fix issues preventing opus playback This CL addresses the following issues, which otherwise prevent opus playback from working: 1) The opus decoder produces interleaved output (in constrast to most ffmpeg audio decoders), but it allocates buffers 6 times as large as the generated packet (AVFrame, in ffmpeg terminology). This creates a situation in which the VMO used by the audio renderer is quickly exhausted. The ffmpeg audio decoder wrapper was modified to allocate system memory for the decoder and then copy only the relevant part of the payload buffer into a buffer allocated from the provided allocator (the one managing the renderer's VMO, in this case). 2) ffmpeg was complaining that the codec context's pkt_timebase field was not set. Though this had no audible effect, this CL fixes that anyway. 3) The AudioConsumer test UnsupportedCodec was using the opus codec designation, which is now supported. That designation was replaced with a nonsense string. TEST: added an end-to-end test for opus $ fx test mediaplayer_tests The new test will fail until opus integration into the ffmpeg prebuilt is complete. Bug: 50035 Change-Id: I9d854253222224490a48e497082ae24510bd4eb7 Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/380304 Commit-Queue: Dale Sather <dalesat@google.com> Reviewed-by: Austin Foxley <afoxley@google.com> Testability-Review: Austin Foxley <afoxley@google.com>
Pink + Purple == Fuchsia (a new operating system)
Fuchsia is a modular, capability-based operating system. Fuchsia runs on modern 64-bit Intel and ARM processors.
Fuchsia is an open source project with a code of conduct that we expect everyone who interacts with the project to respect.
See Getting Started.
See fuchsia.dev.