diff options
author | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-24 06:41:39 +0000 |
---|---|---|
committer | sergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-24 06:41:39 +0000 |
commit | cd2770ad8e2fda03e60861177a4d3236ab555c89 (patch) | |
tree | 55e48778a9712f07e58e275e279dad4e7544fd12 /media/ffmpeg/ffmpeg_common.cc | |
parent | b9766fa4460f8183332636710ca6aaf3c955e3f5 (diff) | |
download | chromium_src-cd2770ad8e2fda03e60861177a4d3236ab555c89.zip chromium_src-cd2770ad8e2fda03e60861177a4d3236ab555c89.tar.gz chromium_src-cd2770ad8e2fda03e60861177a4d3236ab555c89.tar.bz2 |
Fix VP9 playback for videos with odd width/height.
Fixed two issues:
1. VPX decoder uses VideoFrame::WrapExternalYuvData() which was
returning NULL for odd-sized frames and the decoded wasn't handling
this correctly. Fixed WrapExternalYuvData() methods to ensure that
result is never NULL, except the cases when it's necessary and
callers check result.
2. FFMpeg demuxer was using incorrect size for VP9 streams (this bug
didn't affect MediaSource).
Also fixed VideoFrame::CreateFrame() to never return NULL to avoid
problems like (1), because most callers don't expect NULL.
Test video for the new test has been landed in r279187.
BUG=387272
Review URL: https://codereview.chromium.org/347143006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@279342 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/ffmpeg/ffmpeg_common.cc')
-rw-r--r-- | media/ffmpeg/ffmpeg_common.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/media/ffmpeg/ffmpeg_common.cc b/media/ffmpeg/ffmpeg_common.cc index d87aa82..42642fb 100644 --- a/media/ffmpeg/ffmpeg_common.cc +++ b/media/ffmpeg/ffmpeg_common.cc @@ -396,7 +396,7 @@ void AVStreamToVideoDecoderConfig( if (codec == kCodecVP9) { // TODO(tomfinegan): libavcodec doesn't know about VP9. format = VideoFrame::YV12; - coded_size = natural_size; + coded_size = visible_rect.size(); } // Pad out |coded_size| for subsampled YUV formats. |