// Copyright 2022 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef MEDIA_CAST_OPENSCREEN_DECODER_BUFFER_READER_H_ #define MEDIA_CAST_OPENSCREEN_DECODER_BUFFER_READER_H_ #include "base/containers/circular_deque.h" #include "base/functional/callback.h" #include "base/memory/scoped_refptr.h" #include "base/memory/weak_ptr.h" #include "base/sequence_checker.h" #include "media/base/decoder_buffer.h" #include "media/mojo/common/mojo_decoder_buffer_converter.h" #include "mojo/public/cpp/system/data_pipe.h" namespace media::cast { // This class wraps functionality around reading a media::DecoderBuffer from // a mojo pipe, while providing synchronization around the following three // operations: // - Providing the media::mojom::DecoderBufferPtr for a pending DecoderBuffer // read. // - Reading the data for a DecoderBuffer from a |data_pipe| provided to the // ctor. // - Requesting a new buffer callback by the embedding class. class DecoderBufferReader { … }; } // namespace media::cast #endif // MEDIA_CAST_OPENSCREEN_DECODER_BUFFER_READER_H_