summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/codecs/m4v_h263/dec
diff options
context:
space:
mode:
authorRonghua Wu <ronghuawu@google.com>2015-01-07 09:55:41 -0800
committerRonghua Wu <ronghuawu@google.com>2015-01-07 09:55:41 -0800
commit55dfeeb53fdd2e940d0b7c7e3661152ca51ed85e (patch)
tree96233cb1de67ca9ca000c9e0fbc720febe902f91 /media/libstagefright/codecs/m4v_h263/dec
parent0d19abb440c7e62e944efbeadf02299990f9a589 (diff)
downloadframeworks_av-55dfeeb53fdd2e940d0b7c7e3661152ca51ed85e.zip
frameworks_av-55dfeeb53fdd2e940d0b7c7e3661152ca51ed85e.tar.gz
frameworks_av-55dfeeb53fdd2e940d0b7c7e3661152ca51ed85e.tar.bz2
Use aligned width and height to compute size.
Bug: 18528130 Change-Id: I4d2304d8c8919c1cde60676848cfe2e4f2061a87
Diffstat (limited to 'media/libstagefright/codecs/m4v_h263/dec')
-rw-r--r--media/libstagefright/codecs/m4v_h263/dec/src/pvdec_api.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/media/libstagefright/codecs/m4v_h263/dec/src/pvdec_api.cpp b/media/libstagefright/codecs/m4v_h263/dec/src/pvdec_api.cpp
index 844bd14..b783222 100644
--- a/media/libstagefright/codecs/m4v_h263/dec/src/pvdec_api.cpp
+++ b/media/libstagefright/codecs/m4v_h263/dec/src/pvdec_api.cpp
@@ -247,10 +247,13 @@ OSCL_EXPORT_REF Bool PVInitVideoDecoder(VideoDecControls *decCtrl, uint8 *volbuf
video->vol[idx]->useReverseVLC = 0;
video->intra_acdcPredDisable = 1;
video->vol[idx]->scalability = 0;
- video->size = (int32)width * height;
- video->displayWidth = video->width = width;
- video->displayHeight = video->height = height;
+ video->displayWidth = width;
+ video->displayHeight = height;
+ video->width = (width + 15) & -16;
+ video->height = (height + 15) & -16;
+ video->size = (int32)video->width * video->height;
+
#ifdef PV_ANNEX_IJKT_SUPPORT
video->modified_quant = 0;
video->advanced_INTRA = 0;