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

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

Issue 506683002: Remove implicit conversions from scoped_refptr to T* in media/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/receiver/cast_receiver_impl.h" 5 #include "media/cast/receiver/cast_receiver_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 // static 204 // static
205 void CastReceiverImpl::EmitDecodedVideoFrame( 205 void CastReceiverImpl::EmitDecodedVideoFrame(
206 const scoped_refptr<CastEnvironment>& cast_environment, 206 const scoped_refptr<CastEnvironment>& cast_environment,
207 const VideoFrameDecodedCallback& callback, 207 const VideoFrameDecodedCallback& callback,
208 uint32 frame_id, 208 uint32 frame_id,
209 uint32 rtp_timestamp, 209 uint32 rtp_timestamp,
210 const base::TimeTicks& playout_time, 210 const base::TimeTicks& playout_time,
211 const scoped_refptr<VideoFrame>& video_frame, 211 const scoped_refptr<VideoFrame>& video_frame,
212 bool is_continuous) { 212 bool is_continuous) {
213 DCHECK(cast_environment->CurrentlyOn(CastEnvironment::MAIN)); 213 DCHECK(cast_environment->CurrentlyOn(CastEnvironment::MAIN));
214 if (video_frame) { 214 if (video_frame.get()) {
215 const base::TimeTicks now = cast_environment->Clock()->NowTicks(); 215 const base::TimeTicks now = cast_environment->Clock()->NowTicks();
216 cast_environment->Logging()->InsertFrameEvent( 216 cast_environment->Logging()->InsertFrameEvent(
217 now, FRAME_DECODED, VIDEO_EVENT, rtp_timestamp, frame_id); 217 now, FRAME_DECODED, VIDEO_EVENT, rtp_timestamp, frame_id);
218 cast_environment->Logging()->InsertFrameEventWithDelay( 218 cast_environment->Logging()->InsertFrameEventWithDelay(
219 now, FRAME_PLAYOUT, VIDEO_EVENT, rtp_timestamp, frame_id, 219 now, FRAME_PLAYOUT, VIDEO_EVENT, rtp_timestamp, frame_id,
220 playout_time - now); 220 playout_time - now);
221 221
222 // Used by chrome/browser/extension/api/cast_streaming/performance_test.cc 222 // Used by chrome/browser/extension/api/cast_streaming/performance_test.cc
223 TRACE_EVENT_INSTANT1( 223 TRACE_EVENT_INSTANT1(
224 "cast_perf_test", "FrameDecoded", 224 "cast_perf_test", "FrameDecoded",
225 TRACE_EVENT_SCOPE_THREAD, 225 TRACE_EVENT_SCOPE_THREAD,
226 "rtp_timestamp", rtp_timestamp); 226 "rtp_timestamp", rtp_timestamp);
227 } 227 }
228 callback.Run(video_frame, playout_time, is_continuous); 228 callback.Run(video_frame, playout_time, is_continuous);
229 } 229 }
230 230
231 } // namespace cast 231 } // namespace cast
232 } // namespace media 232 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698