diff options
author | vrk@google.com <vrk@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-19 20:18:33 +0000 |
---|---|---|
committer | vrk@google.com <vrk@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-19 20:18:33 +0000 |
commit | 2975fa5391dfd5c57def10929408d814c4acaf6d (patch) | |
tree | 32e17ca77ac82b2adf3e36b23f3f7b7918b6b509 /media/tools | |
parent | ef03e1ded45fe5dff2b3a783b1be554b5064dfea (diff) | |
download | chromium_src-2975fa5391dfd5c57def10929408d814c4acaf6d.zip chromium_src-2975fa5391dfd5c57def10929408d814c4acaf6d.tar.gz chromium_src-2975fa5391dfd5c57def10929408d814c4acaf6d.tar.bz2 |
Reland r101418: Fix aspect ratio and clarify video frame dimensions
Fixes shared build errors for windows and linux.
BUG=18941,94861
TEST=shared builds compile
TBR=acolwell
Review URL: http://codereview.chromium.org/7932005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@101808 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/tools')
-rw-r--r-- | media/tools/player_wtl/wtl_renderer.cc | 3 | ||||
-rw-r--r-- | media/tools/player_x11/gl_video_renderer.cc | 3 | ||||
-rw-r--r-- | media/tools/player_x11/x11_video_renderer.cc | 4 |
3 files changed, 6 insertions, 4 deletions
diff --git a/media/tools/player_wtl/wtl_renderer.cc b/media/tools/player_wtl/wtl_renderer.cc index baec88e..c5d9fd3 100644 --- a/media/tools/player_wtl/wtl_renderer.cc +++ b/media/tools/player_wtl/wtl_renderer.cc @@ -13,7 +13,8 @@ WtlVideoRenderer::WtlVideoRenderer(WtlVideoWindow* window) WtlVideoRenderer::~WtlVideoRenderer() {} bool WtlVideoRenderer::OnInitialize(media::VideoDecoder* decoder) { - window_->SetSize(decoder->width(), decoder->height()); + window_->SetSize( + decoder->natural_size().width(), decoder->natural_size().height()); return true; } diff --git a/media/tools/player_x11/gl_video_renderer.cc b/media/tools/player_x11/gl_video_renderer.cc index b58b4df..6c6cda4 100644 --- a/media/tools/player_x11/gl_video_renderer.cc +++ b/media/tools/player_x11/gl_video_renderer.cc @@ -128,7 +128,8 @@ bool GlVideoRenderer::OnInitialize(media::VideoDecoder* decoder) { LOG(INFO) << "Initializing GL Renderer..."; // Resize the window to fit that of the video. - XResizeWindow(display_, window_, decoder->width(), decoder->height()); + XResizeWindow(display_, window_, decoder->natural_size().width(), + decoder->natural_size().height()); gl_context_ = InitGLContext(display_, window_); if (!gl_context_) diff --git a/media/tools/player_x11/x11_video_renderer.cc b/media/tools/player_x11/x11_video_renderer.cc index 055e54b..a06f6b8 100644 --- a/media/tools/player_x11/x11_video_renderer.cc +++ b/media/tools/player_x11/x11_video_renderer.cc @@ -94,8 +94,8 @@ bool X11VideoRenderer::OnInitialize(media::VideoDecoder* decoder) { LOG(INFO) << "Initializing X11 Renderer..."; // Resize the window to fit that of the video. - int width = decoder->width(); - int height = decoder->height(); + int width = decoder->natural_size().width(); + int height = decoder->natural_size().height(); XResizeWindow(display_, window_, width, height); // Allocate an XImage for caching RGB result. |