Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(461)

Unified Diff: media/mojo/clients/mojo_audio_decoder.h

Issue 2096063003: media: Add MojoDecoderBuffer{Reader|Writer} (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments addressed Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/mojo/BUILD.gn ('k') | media/mojo/clients/mojo_audio_decoder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/mojo/clients/mojo_audio_decoder.h
diff --git a/media/mojo/clients/mojo_audio_decoder.h b/media/mojo/clients/mojo_audio_decoder.h
index 44a0fcdcba58fbc7899b8496e9ca7071b9e4aea7..546b8e7fcbf91a0263508eef48bd731d0ea3091f 100644
--- a/media/mojo/clients/mojo_audio_decoder.h
+++ b/media/mojo/clients/mojo_audio_decoder.h
@@ -5,13 +5,14 @@
#ifndef MEDIA_MOJO_CLIENTS_MOJO_AUDIO_DECODER_H_
#define MEDIA_MOJO_CLIENTS_MOJO_AUDIO_DECODER_H_
+#include <memory>
+
#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "media/base/audio_decoder.h"
#include "media/mojo/interfaces/audio_decoder.mojom.h"
#include "media/mojo/interfaces/media_types.mojom.h"
#include "mojo/public/cpp/bindings/binding.h"
-#include "mojo/public/cpp/system/data_pipe.h"
namespace base {
class SingleThreadTaskRunner;
@@ -19,6 +20,8 @@ class SingleThreadTaskRunner;
namespace media {
+class MojoDecoderBufferWriter;
+
// An AudioDecoder that proxies to a mojom::AudioDecoder.
class MojoAudioDecoder : public AudioDecoder, public mojom::AudioDecoderClient {
public:
@@ -53,14 +56,6 @@ class MojoAudioDecoder : public AudioDecoder, public mojom::AudioDecoderClient {
// called when |remote_decoder_| finished Reset() sequence.
void OnResetDone();
- // A helper method that creates data pipe and sets the data connection to
- // the service.
- void CreateDataPipe();
-
- // A helper method to serialize the data section of DecoderBuffer into pipe.
- mojom::DecoderBufferPtr TransferDecoderBuffer(
- const scoped_refptr<DecoderBuffer>& media_buffer);
-
scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
// This class is constructed on one thread and used exclusively on another
@@ -71,8 +66,7 @@ class MojoAudioDecoder : public AudioDecoder, public mojom::AudioDecoderClient {
mojom::AudioDecoderPtr remote_decoder_;
- // DataPipe for serializing the data section of DecoderBuffer.
- mojo::ScopedDataPipeProducerHandle producer_handle_;
+ std::unique_ptr<MojoDecoderBufferWriter> mojo_decoder_buffer_writer_;
// Binding for AudioDecoderClient, bound to the |task_runner_|.
mojo::Binding<AudioDecoderClient> binding_;
« no previous file with comments | « media/mojo/BUILD.gn ('k') | media/mojo/clients/mojo_audio_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698