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

Side by Side Diff: media/cast/cast_receiver_impl.cc

Issue 306783002: [Cast] Clean-up: Merge AudioReceiverConfig+VideoReceiverConfig-->FrameReceiverConfig. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix typo Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "media/cast/cast_receiver_impl.h" 5 #include "media/cast/cast_receiver_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 private: 66 private:
67 friend class base::RefCountedThreadSafe<LocalFrameReceiver>; 67 friend class base::RefCountedThreadSafe<LocalFrameReceiver>;
68 68
69 scoped_refptr<CastEnvironment> cast_environment_; 69 scoped_refptr<CastEnvironment> cast_environment_;
70 AudioReceiver* audio_receiver_; 70 AudioReceiver* audio_receiver_;
71 VideoReceiver* video_receiver_; 71 VideoReceiver* video_receiver_;
72 }; 72 };
73 73
74 scoped_ptr<CastReceiver> CastReceiver::Create( 74 scoped_ptr<CastReceiver> CastReceiver::Create(
75 scoped_refptr<CastEnvironment> cast_environment, 75 scoped_refptr<CastEnvironment> cast_environment,
76 const AudioReceiverConfig& audio_config, 76 const FrameReceiverConfig& audio_config,
77 const VideoReceiverConfig& video_config, 77 const FrameReceiverConfig& video_config,
78 transport::PacketSender* const packet_sender) { 78 transport::PacketSender* const packet_sender) {
79 return scoped_ptr<CastReceiver>(new CastReceiverImpl( 79 return scoped_ptr<CastReceiver>(new CastReceiverImpl(
80 cast_environment, audio_config, video_config, packet_sender)); 80 cast_environment, audio_config, video_config, packet_sender));
81 } 81 }
82 82
83 CastReceiverImpl::CastReceiverImpl( 83 CastReceiverImpl::CastReceiverImpl(
84 scoped_refptr<CastEnvironment> cast_environment, 84 scoped_refptr<CastEnvironment> cast_environment,
85 const AudioReceiverConfig& audio_config, 85 const FrameReceiverConfig& audio_config,
86 const VideoReceiverConfig& video_config, 86 const FrameReceiverConfig& video_config,
87 transport::PacketSender* const packet_sender) 87 transport::PacketSender* const packet_sender)
88 : pacer_(cast_environment->Clock(), 88 : pacer_(cast_environment->Clock(),
89 cast_environment->Logging(), 89 cast_environment->Logging(),
90 packet_sender, 90 packet_sender,
91 cast_environment->GetTaskRunner(CastEnvironment::MAIN)), 91 cast_environment->GetTaskRunner(CastEnvironment::MAIN)),
92 audio_receiver_(cast_environment, audio_config, &pacer_), 92 audio_receiver_(cast_environment, audio_config, &pacer_),
93 video_receiver_(cast_environment, 93 video_receiver_(cast_environment,
94 video_config, 94 video_config,
95 &pacer_), 95 &pacer_),
96 frame_receiver_(new LocalFrameReceiver(cast_environment, 96 frame_receiver_(new LocalFrameReceiver(cast_environment,
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 transport::PacketReceiverCallback CastReceiverImpl::packet_receiver() { 141 transport::PacketReceiverCallback CastReceiverImpl::packet_receiver() {
142 return base::Bind(&CastReceiverImpl::ReceivedPacket, base::Unretained(this)); 142 return base::Bind(&CastReceiverImpl::ReceivedPacket, base::Unretained(this));
143 } 143 }
144 144
145 scoped_refptr<FrameReceiver> CastReceiverImpl::frame_receiver() { 145 scoped_refptr<FrameReceiver> CastReceiverImpl::frame_receiver() {
146 return frame_receiver_; 146 return frame_receiver_;
147 } 147 }
148 148
149 } // namespace cast 149 } // namespace cast
150 } // namespace media 150 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698