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

Side by Side Diff: media/filters/vpx_video_decoder.h

Issue 2643733002: Allow to use {FFmpeg/Vpx}VideoDecoder from a UtilityProcess (Closed)
Patch Set: Rebase Created 3 years, 10 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 unified diff | Download patch
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/filters/vpx_video_decoder.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_FILTERS_VPX_VIDEO_DECODER_H_ 5 #ifndef MEDIA_FILTERS_VPX_VIDEO_DECODER_H_
6 #define MEDIA_FILTERS_VPX_VIDEO_DECODER_H_ 6 #define MEDIA_FILTERS_VPX_VIDEO_DECODER_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/threading/thread_checker.h" 10 #include "base/threading/thread_checker.h"
(...skipping 15 matching lines...) Expand all
26 // Libvpx video decoder wrapper. 26 // Libvpx video decoder wrapper.
27 // Note: VpxVideoDecoder accepts only YV12A VP8 content or VP9 content. This is 27 // Note: VpxVideoDecoder accepts only YV12A VP8 content or VP9 content. This is
28 // done to avoid usurping FFmpeg for all VP8 decoding, because the FFmpeg VP8 28 // done to avoid usurping FFmpeg for all VP8 decoding, because the FFmpeg VP8
29 // decoder is faster than the libvpx VP8 decoder. 29 // decoder is faster than the libvpx VP8 decoder.
30 // Alpha channel, if any, is sent in the DecoderBuffer's side_data() as a frame 30 // Alpha channel, if any, is sent in the DecoderBuffer's side_data() as a frame
31 // on its own of which the Y channel is taken [1]. 31 // on its own of which the Y channel is taken [1].
32 // [1] http://wiki.webmproject.org/alpha-channel 32 // [1] http://wiki.webmproject.org/alpha-channel
33 class MEDIA_EXPORT VpxVideoDecoder : public VideoDecoder { 33 class MEDIA_EXPORT VpxVideoDecoder : public VideoDecoder {
34 public: 34 public:
35 VpxVideoDecoder(); 35 VpxVideoDecoder();
36 explicit VpxVideoDecoder(
37 std::unique_ptr<VideoFrameProvider> video_frame_provider);
36 ~VpxVideoDecoder() override; 38 ~VpxVideoDecoder() override;
37 39
38 // VideoDecoder implementation. 40 // VideoDecoder implementation.
39 std::string GetDisplayName() const override; 41 std::string GetDisplayName() const override;
40 void Initialize(const VideoDecoderConfig& config, 42 void Initialize(const VideoDecoderConfig& config,
41 bool low_delay, 43 bool low_delay,
42 CdmContext* cdm_context, 44 CdmContext* cdm_context,
43 const InitCB& init_cb, 45 const InitCB& init_cb,
44 const OutputCB& output_cb) override; 46 const OutputCB& output_cb) override;
45 void Decode(const scoped_refptr<DecoderBuffer>& buffer, 47 void Decode(const scoped_refptr<DecoderBuffer>& buffer,
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 scoped_refptr<base::SingleThreadTaskRunner> offload_task_runner_; 115 scoped_refptr<base::SingleThreadTaskRunner> offload_task_runner_;
114 116
115 VideoFramePool frame_pool_; 117 VideoFramePool frame_pool_;
116 118
117 DISALLOW_COPY_AND_ASSIGN(VpxVideoDecoder); 119 DISALLOW_COPY_AND_ASSIGN(VpxVideoDecoder);
118 }; 120 };
119 121
120 } // namespace media 122 } // namespace media
121 123
122 #endif // MEDIA_FILTERS_VPX_VIDEO_DECODER_H_ 124 #endif // MEDIA_FILTERS_VPX_VIDEO_DECODER_H_
OLDNEW
« no previous file with comments | « media/filters/ffmpeg_video_decoder.cc ('k') | media/filters/vpx_video_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698