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

Side by Side Diff: media/base/video_frame.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, 3 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 (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 #include "media/base/video_frame.h" 5 #include "media/base/video_frame.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback_helpers.h" 10 #include "base/callback_helpers.h"
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 374
375 // static 375 // static
376 scoped_refptr<VideoFrame> VideoFrame::CreateTransparentFrame( 376 scoped_refptr<VideoFrame> VideoFrame::CreateTransparentFrame(
377 const gfx::Size& size) { 377 const gfx::Size& size) {
378 const uint8 kBlackY = 0x00; 378 const uint8 kBlackY = 0x00;
379 const uint8 kBlackUV = 0x00; 379 const uint8 kBlackUV = 0x00;
380 const uint8 kTransparentA = 0x00; 380 const uint8 kTransparentA = 0x00;
381 const base::TimeDelta kZero; 381 const base::TimeDelta kZero;
382 scoped_refptr<VideoFrame> frame = VideoFrame::CreateFrame( 382 scoped_refptr<VideoFrame> frame = VideoFrame::CreateFrame(
383 VideoFrame::YV12A, size, gfx::Rect(size), size, kZero); 383 VideoFrame::YV12A, size, gfx::Rect(size), size, kZero);
384 FillYUVA(frame, kBlackY, kBlackUV, kBlackUV, kTransparentA); 384 FillYUVA(frame.get(), kBlackY, kBlackUV, kBlackUV, kTransparentA);
385 return frame; 385 return frame;
386 } 386 }
387 387
388 #if defined(VIDEO_HOLE) 388 #if defined(VIDEO_HOLE)
389 // This block and other blocks wrapped around #if defined(VIDEO_HOLE) is not 389 // This block and other blocks wrapped around #if defined(VIDEO_HOLE) is not
390 // maintained by the general compositor team. Please contact the following 390 // maintained by the general compositor team. Please contact the following
391 // people instead: 391 // people instead:
392 // 392 //
393 // wonsik@chromium.org 393 // wonsik@chromium.org
394 // ycheo@chromium.org 394 // ycheo@chromium.org
(...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after
863 break; 863 break;
864 for (int row = 0; row < rows(plane); ++row) { 864 for (int row = 0; row < rows(plane); ++row) {
865 base::MD5Update(context, base::StringPiece( 865 base::MD5Update(context, base::StringPiece(
866 reinterpret_cast<char*>(data(plane) + stride(plane) * row), 866 reinterpret_cast<char*>(data(plane) + stride(plane) * row),
867 row_bytes(plane))); 867 row_bytes(plane)));
868 } 868 }
869 } 869 }
870 } 870 }
871 871
872 } // namespace media 872 } // namespace media
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698