diff options
author | Steve Kondik <shade@chemlab.org> | 2010-08-26 03:26:39 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit2@cyanogenmod.teamdouche.net> | 2010-08-26 03:26:39 +0000 |
commit | 36d936d73ed61b346f197ad59fa0ca606ce372eb (patch) | |
tree | 0cfe6e4b0ea30ed547a1b7f9269bf223c702c548 | |
parent | 768292c796c63667c9f7e6f9e0c1af4541b382af (diff) | |
parent | 1f0716e6a8b122d8a7339d3f1508a4414ff1e751 (diff) | |
download | frameworks_base-36d936d73ed61b346f197ad59fa0ca606ce372eb.zip frameworks_base-36d936d73ed61b346f197ad59fa0ca606ce372eb.tar.gz frameworks_base-36d936d73ed61b346f197ad59fa0ca606ce372eb.tar.bz2 |
Merge "stagefright: Only use stride/slice height for decode on MSM/QSD" into froyo
-rw-r--r-- | media/libstagefright/Android.mk | 7 | ||||
-rw-r--r-- | media/libstagefright/OMXCodec.cpp | 6 |
2 files changed, 13 insertions, 0 deletions
diff --git a/media/libstagefright/Android.mk b/media/libstagefright/Android.mk index c4b88cc..5fefc87 100644 --- a/media/libstagefright/Android.mk +++ b/media/libstagefright/Android.mk @@ -103,6 +103,13 @@ endif endif +ifeq ($(TARGET_BOARD_PLATFORM),qsd8k) + LOCAL_CFLAGS += -DUSE_QCOM_OMX_FIX +endif +ifeq ($(TARGET_BOARD_PLATFORM),msm7k) + LOCAL_CFLAGS += -DUSE_QCOM_OMX_FIX +endif + ifeq ($(TARGET_OS)-$(TARGET_SIMULATOR),linux-true) LOCAL_LDLIBS += -lpthread endif diff --git a/media/libstagefright/OMXCodec.cpp b/media/libstagefright/OMXCodec.cpp index 6f0654d..40bc2c5 100644 --- a/media/libstagefright/OMXCodec.cpp +++ b/media/libstagefright/OMXCodec.cpp @@ -2999,10 +2999,16 @@ void OMXCodec::initOutputFormat(const sp<MetaData> &inputFormat) { mOutputFormat->setInt32( kKeyHeight, (video_def->nFrameHeight + 15) & -16); } else { +#ifdef USE_QCOM_OMX_FIX //Update the Stride and Slice Height //Allows creation of Renderer with correct height and width mOutputFormat->setInt32(kKeyWidth, video_def->nStride); mOutputFormat->setInt32(kKeyHeight, video_def->nSliceHeight); +#else + //Some hardware expects the old behavior + mOutputFormat->setInt32(kKeyWidth, video_def->nFrameWidth); + mOutputFormat->setInt32(kKeyHeight, video_def->nFrameHeight); +#endif } mOutputFormat->setInt32(kKeyColorFormat, video_def->eColorFormat); |