diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2024-03-04 21:56:21 +0000 |
---|---|---|
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2024-03-04 21:56:21 +0000 |
commit | 1c50bad75237fe62efaca0363dd6e48dc4a37128 (patch) | |
tree | 436ec7738d33f042b406d1b586e7f73d0b00f81f | |
parent | ef677016cf3a7effb8aef67eb07e8dc1a3cdcd5e (diff) | |
parent | 7b34ebcc8e6f91d045dde0aad56a675743a47ffe (diff) | |
download | cuttlefish-simpleperf-release.tar.gz |
Snap for 11526323 from 7b34ebcc8e6f91d045dde0aad56a675743a47ffe to simpleperf-releasesimpleperf-release
Change-Id: Ia082f6e268a3b81df2bb261ca6cb0ff9606120c5
-rw-r--r-- | build/cvd-host-package.go | 7 | ||||
-rw-r--r-- | host/commands/assemble_cvd/graphics_flags.cc | 5 | ||||
-rw-r--r-- | host/commands/process_sandboxer/main.cpp | 1 | ||||
-rw-r--r-- | host/frontend/webrtc/audio_handler.cpp | 8 | ||||
-rw-r--r-- | host/frontend/webrtc/libdevice/audio_sink.h | 2 | ||||
-rw-r--r-- | host/frontend/webrtc/libdevice/audio_track_source_impl.cpp | 6 | ||||
-rw-r--r-- | host/frontend/webrtc/libdevice/audio_track_source_impl.h | 4 |
7 files changed, 21 insertions, 12 deletions
diff --git a/build/cvd-host-package.go b/build/cvd-host-package.go index cf66c0e99..596ce41d0 100644 --- a/build/cvd-host-package.go +++ b/build/cvd-host-package.go @@ -68,6 +68,13 @@ func (c *cvdHostPackage) DepsMutator(ctx android.BottomUpMutatorContext) { } } + for _, dep := range strings.Split( + ctx.Config().VendorConfig("cvd").String("binary"), " ") { + if ctx.OtherModuleExists(dep) { + ctx.AddVariationDependencies(ctx.Target().Variations(), cvdHostPackageDependencyTag, dep) + } + } + // If cvd_custom_action_config is set, include custom action servers in the // host package as specified by cvd_custom_action_servers. customActionConfig := ctx.Config().VendorConfig("cvd").String("custom_action_config") diff --git a/host/commands/assemble_cvd/graphics_flags.cc b/host/commands/assemble_cvd/graphics_flags.cc index 2a0f7c78d..19aebc519 100644 --- a/host/commands/assemble_cvd/graphics_flags.cc +++ b/host/commands/assemble_cvd/graphics_flags.cc @@ -71,8 +71,9 @@ Result<RenderingMode> GetRenderingMode(const std::string& mode) { struct AngleFeatures { // Prefer linear filtering for YUV AHBs to pass - // android.media.decoder.cts.DecodeAccuracyTest. - bool prefer_linear_filtering_for_yuv = true; + // android.media.decoder.cts.DecodeAccuracyTest on older branches. + // Generally not needed after b/315387961. + bool prefer_linear_filtering_for_yuv = false; // Map unspecified color spaces to PASS_THROUGH to pass // android.media.codec.cts.DecodeEditEncodeTest and diff --git a/host/commands/process_sandboxer/main.cpp b/host/commands/process_sandboxer/main.cpp index 3c5af47d5..2ddcfb5f3 100644 --- a/host/commands/process_sandboxer/main.cpp +++ b/host/commands/process_sandboxer/main.cpp @@ -24,6 +24,7 @@ #include "absl/flags/parse.h" #include "absl/log/check.h" #include "absl/log/initialize.h" +#include "absl/strings/numbers.h" #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wunused-parameter" #include "sandboxed_api/sandbox2/executor.h" diff --git a/host/frontend/webrtc/audio_handler.cpp b/host/frontend/webrtc/audio_handler.cpp index 52a2294d7..be15ed7c2 100644 --- a/host/frontend/webrtc/audio_handler.cpp +++ b/host/frontend/webrtc/audio_handler.cpp @@ -443,7 +443,7 @@ void AudioHandler::OnPlaybackBuffer(TxBuffer buffer) { // webrtc api doesn't expect volatile memory. This should be safe though // because webrtc will use the contents of the buffer before returning // and only then we release it. - auto audio_frame_buffer = std::make_shared<CvdAudioFrameBuffer>( + CvdAudioFrameBuffer audio_frame_buffer( const_cast<const uint8_t*>(&buffer.get()[pos]), stream_desc.bits_per_sample, stream_desc.sample_rate, stream_desc.channels, frames); @@ -453,9 +453,9 @@ void AudioHandler::OnPlaybackBuffer(TxBuffer buffer) { pos += holding_buffer.Add(buffer.get() + pos, buffer.len() - pos); if (holding_buffer.full()) { auto buffer_ptr = const_cast<const uint8_t*>(holding_buffer.data()); - auto audio_frame_buffer = std::make_shared<CvdAudioFrameBuffer>( - buffer_ptr, stream_desc.bits_per_sample, - stream_desc.sample_rate, stream_desc.channels, frames); + CvdAudioFrameBuffer audio_frame_buffer( + buffer_ptr, stream_desc.bits_per_sample, stream_desc.sample_rate, + stream_desc.channels, frames); audio_sink_->OnFrame(audio_frame_buffer, base_time); holding_buffer.count = 0; } diff --git a/host/frontend/webrtc/libdevice/audio_sink.h b/host/frontend/webrtc/libdevice/audio_sink.h index 1baa88115..614aada91 100644 --- a/host/frontend/webrtc/libdevice/audio_sink.h +++ b/host/frontend/webrtc/libdevice/audio_sink.h @@ -26,7 +26,7 @@ namespace webrtc_streaming { class AudioSink { public: virtual ~AudioSink() = default; - virtual void OnFrame(std::shared_ptr<AudioFrameBuffer> frame, + virtual void OnFrame(const AudioFrameBuffer& frame, int64_t timestamp_us) = 0; }; diff --git a/host/frontend/webrtc/libdevice/audio_track_source_impl.cpp b/host/frontend/webrtc/libdevice/audio_track_source_impl.cpp index 72756e195..c10e2630b 100644 --- a/host/frontend/webrtc/libdevice/audio_track_source_impl.cpp +++ b/host/frontend/webrtc/libdevice/audio_track_source_impl.cpp @@ -51,12 +51,12 @@ const cricket::AudioOptions AudioTrackSourceImpl::options() const { return cricket::AudioOptions(); } -void AudioTrackSourceImpl::OnFrame(std::shared_ptr<AudioFrameBuffer> frame, +void AudioTrackSourceImpl::OnFrame(const AudioFrameBuffer& frame, int64_t timestamp_ms) { std::lock_guard<std::mutex> lock(sinks_mutex_); for (auto sink : sinks_) { - sink->OnData(frame->data(), frame->bits_per_sample(), - frame->sample_rate(), frame->channels(), frame->frames(), + sink->OnData(frame.data(), frame.bits_per_sample(), + frame.sample_rate(), frame.channels(), frame.frames(), timestamp_ms); } } diff --git a/host/frontend/webrtc/libdevice/audio_track_source_impl.h b/host/frontend/webrtc/libdevice/audio_track_source_impl.h index 53dffeacf..61f01cff4 100644 --- a/host/frontend/webrtc/libdevice/audio_track_source_impl.h +++ b/host/frontend/webrtc/libdevice/audio_track_source_impl.h @@ -44,7 +44,7 @@ class AudioTrackSourceImpl : public webrtc::AudioSourceInterface { // audio network adaptation on the source is the wrong layer of abstraction). virtual const cricket::AudioOptions options() const; - void OnFrame(std::shared_ptr<AudioFrameBuffer> frame, int64_t timestamp_ms); + void OnFrame(const AudioFrameBuffer& frame, int64_t timestamp_ms); // MediaSourceInterface implementation SourceState state() const override; @@ -74,7 +74,7 @@ class AudioTrackSourceImplSinkWrapper : public AudioSink { AudioTrackSourceImplSinkWrapper(rtc::scoped_refptr<AudioTrackSourceImpl> obj) : track_source_impl_(obj) {} - void OnFrame(std::shared_ptr<AudioFrameBuffer> frame, + void OnFrame(const AudioFrameBuffer& frame, int64_t timestamp_ms) override { track_source_impl_->OnFrame(frame, timestamp_ms); } |