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

Side by Side Diff: webkit/glue/webmediaplayer_impl.cc

Issue 7932005: Reland r101418: Fix aspect ratio and clarify video frame dimensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « webkit/glue/media/video_renderer_impl.cc ('k') | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "webkit/glue/webmediaplayer_impl.h" 5 #include "webkit/glue/webmediaplayer_impl.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 392
393 bool WebMediaPlayerImpl::hasAudio() const { 393 bool WebMediaPlayerImpl::hasAudio() const {
394 DCHECK(MessageLoop::current() == main_loop_); 394 DCHECK(MessageLoop::current() == main_loop_);
395 395
396 return pipeline_->HasAudio(); 396 return pipeline_->HasAudio();
397 } 397 }
398 398
399 WebKit::WebSize WebMediaPlayerImpl::naturalSize() const { 399 WebKit::WebSize WebMediaPlayerImpl::naturalSize() const {
400 DCHECK(MessageLoop::current() == main_loop_); 400 DCHECK(MessageLoop::current() == main_loop_);
401 401
402 size_t width, height; 402 gfx::Size size;
403 pipeline_->GetVideoSize(&width, &height); 403 pipeline_->GetNaturalVideoSize(&size);
404 return WebKit::WebSize(width, height); 404 return WebKit::WebSize(size);
405 } 405 }
406 406
407 bool WebMediaPlayerImpl::paused() const { 407 bool WebMediaPlayerImpl::paused() const {
408 DCHECK(MessageLoop::current() == main_loop_); 408 DCHECK(MessageLoop::current() == main_loop_);
409 409
410 return pipeline_->GetPlaybackRate() == 0.0f; 410 return pipeline_->GetPlaybackRate() == 0.0f;
411 } 411 }
412 412
413 bool WebMediaPlayerImpl::seeking() const { 413 bool WebMediaPlayerImpl::seeking() const {
414 DCHECK(MessageLoop::current() == main_loop_); 414 DCHECK(MessageLoop::current() == main_loop_);
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 } 828 }
829 } 829 }
830 830
831 WebKit::WebMediaPlayerClient* WebMediaPlayerImpl::GetClient() { 831 WebKit::WebMediaPlayerClient* WebMediaPlayerImpl::GetClient() {
832 DCHECK(MessageLoop::current() == main_loop_); 832 DCHECK(MessageLoop::current() == main_loop_);
833 DCHECK(client_); 833 DCHECK(client_);
834 return client_; 834 return client_;
835 } 835 }
836 836
837 } // namespace webkit_glue 837 } // namespace webkit_glue
OLDNEW
« no previous file with comments | « webkit/glue/media/video_renderer_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698