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

Side by Side Diff: content/renderer/media/webmediaplayer_ms.cc

Issue 1134663005: cc: Video layers without a frame should not occlude (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add HasCurrentFrame Created 5 years, 7 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 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 "content/renderer/media/webmediaplayer_ms.h" 5 #include "content/renderer/media/webmediaplayer_ms.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after
457 } 457 }
458 458
459 bool WebMediaPlayerMS::UpdateCurrentFrame(base::TimeTicks deadline_min, 459 bool WebMediaPlayerMS::UpdateCurrentFrame(base::TimeTicks deadline_min,
460 base::TimeTicks deadline_max) { 460 base::TimeTicks deadline_max) {
461 // TODO(dalecurtis): This should make use of the deadline interval to ensure 461 // TODO(dalecurtis): This should make use of the deadline interval to ensure
462 // the painted frame is correct for the given interval. 462 // the painted frame is correct for the given interval.
463 NOTREACHED(); 463 NOTREACHED();
464 return false; 464 return false;
465 } 465 }
466 466
467 bool WebMediaPlayerMS::HasCurrentFrame() const {
468 return current_frame_;
danakj 2015/05/18 18:15:45 and here?
469 }
470
467 scoped_refptr<media::VideoFrame> WebMediaPlayerMS::GetCurrentFrame() { 471 scoped_refptr<media::VideoFrame> WebMediaPlayerMS::GetCurrentFrame() {
468 DVLOG(3) << "WebMediaPlayerMS::GetCurrentFrame"; 472 DVLOG(3) << "WebMediaPlayerMS::GetCurrentFrame";
469 base::AutoLock auto_lock(current_frame_lock_); 473 base::AutoLock auto_lock(current_frame_lock_);
470 DCHECK(!pending_repaint_); 474 DCHECK(!pending_repaint_);
471 if (!current_frame_.get()) 475 if (!current_frame_.get())
472 return NULL; 476 return NULL;
473 pending_repaint_ = true; 477 pending_repaint_ = true;
474 current_frame_used_ = true; 478 current_frame_used_ = true;
475 return current_frame_; 479 return current_frame_;
476 } 480 }
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
554 GetClient()->readyStateChanged(); 558 GetClient()->readyStateChanged();
555 } 559 }
556 560
557 blink::WebMediaPlayerClient* WebMediaPlayerMS::GetClient() { 561 blink::WebMediaPlayerClient* WebMediaPlayerMS::GetClient() {
558 DCHECK(thread_checker_.CalledOnValidThread()); 562 DCHECK(thread_checker_.CalledOnValidThread());
559 DCHECK(client_); 563 DCHECK(client_);
560 return client_; 564 return client_;
561 } 565 }
562 566
563 } // namespace content 567 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698