summaryrefslogtreecommitdiff
authorqidi.huang <qidi.huang@amlogic.com>2017-10-31 09:20:18 (GMT)
committer qidi.huang <qidi.huang@amlogic.com>2017-11-22 03:01:03 (GMT)
commit6f5cb25955819dcb1d8e984fe28dda03618cce75 (patch)
tree1caa988a601f2bcc58b933121c384ee78061a837
parent75ce6eeb68d579bd42a2e84078827d15fa00ed26 (diff)
downloadLibAudio-6f5cb25955819dcb1d8e984fe28dda03618cce75.zip
LibAudio-6f5cb25955819dcb1d8e984fe28dda03618cce75.tar.gz
LibAudio-6f5cb25955819dcb1d8e984fe28dda03618cce75.tar.bz2
Audio: add support for LibAudio. [1/1]
PD# 153477 Add support for LibAudio. Change-Id: I5823fb89b00176a9840ffa810d3b05a736aba3ab Signed-off-by: Qidi Huang <qidi.huang@amlogic.com>
Diffstat
-rw-r--r--Android.mk1
-rw-r--r--amadec/Android.mk284
-rw-r--r--[-rwxr-xr-x]amadec/acodec_lib_mx/libstagefright_soft_ddpdec.so0
-rw-r--r--[-rwxr-xr-x]amadec/acodec_lib_mx/libstagefright_soft_dtshd.so0
-rw-r--r--[-rwxr-xr-x]amadec/adec-pts-mgt.c0
-rw-r--r--[-rwxr-xr-x]amadec/audio_out/android-out.cpp2
-rw-r--r--amadec/include/MetaData.h345
-rw-r--r--[-rwxr-xr-x]amadec/include/adec-macros.h0
-rw-r--r--[-rwxr-xr-x]amadec/include/alsa-out.h0
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/ALAC_mediasource.cpp0
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/ASF_mediasource.cpp0
-rw-r--r--amadec/omx_audio/Android.mk31
-rw-r--r--amadec/omx_audio/Android.mk.bak31
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/DDP_mediasource.cpp0
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/MP3_mediasource.cpp0
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/Vorbis_mediasource.cpp0
-rw-r--r--amadec/omx_audio/adec_omx.cpp1
-rw-r--r--[-rwxr-xr-x]amadec/omx_audio/audio_mediasource.cpp0
-rw-r--r--audio_codec/Android.mk1
-rw-r--r--audio_codec/libadpcm/Android.mk12
-rw-r--r--audio_codec/libamr/Android.mk25
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/Makefile0
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/dec.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/dec_acelp.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/dec_if.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/if_rom.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libamr/typedef.h0
-rw-r--r--audio_codec/libape/Android.mk28
-rw-r--r--audio_codec/libcook/Android.mk28
-rw-r--r--audio_codec/libfaad/Android.mk101
-rw-r--r--[-rwxr-xr-x]audio_codec/libfaad/Makefile0
-rw-r--r--[-rwxr-xr-x]audio_codec/libfaad/audio.d0
-rw-r--r--[-rwxr-xr-x]audio_codec/libfaad/bits.d0
-rw-r--r--audio_codec/libfaad/decoder.c1
-rw-r--r--[-rwxr-xr-x]audio_codec/libfaad/libfaad2.def0
-rw-r--r--audio_codec/libflac/Android.mk22
-rw-r--r--audio_codec/liblpcm/Android.mk13
-rw-r--r--audio_codec/libmad/Android.mk13
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/D.dat0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/imdct_l_arm.S0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/imdct_s.dat0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/layer12.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/layer3.h0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/qc_table.dat0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/rq_table.dat0
-rw-r--r--[-rwxr-xr-x]audio_codec/libmad/sf_table.dat0
-rw-r--r--audio_codec/libpcm/Android.mk11
-rw-r--r--audio_codec/libraac/Android.mk51
-rw-r--r--[-rwxr-xr-x]audio_codec/libraac/sbrcov.s0
-rw-r--r--[-rwxr-xr-x]audio_codec/libraac/sbrqmfak.s0
-rw-r--r--[-rwxr-xr-x]audio_codec/libraac/sbrqmfsk.s0
-rw-r--r--audio_codec/wfd_aac_decoder/Android.mk23
-rw-r--r--audio_codec/wfd_aac_decoder/helix_aac_decode.c2
53 files changed, 1024 insertions, 2 deletions
diff --git a/Android.mk b/Android.mk
new file mode 100644
index 0000000..5053e7d
--- a/dev/null
+++ b/Android.mk
@@ -0,0 +1 @@
+include $(call all-subdir-makefiles)
diff --git a/amadec/Android.mk b/amadec/Android.mk
new file mode 100644
index 0000000..61919ce
--- a/dev/null
+++ b/amadec/Android.mk
@@ -0,0 +1,284 @@
+LOCAL_PATH:= $(call my-dir)
+include $(TOP)/hardware/amlogic/media/media_base_config.mk
+AMAVUTILS_INCLUDE=$(AMAVUTILS_PATH)/include/
+ifeq ($(BUILD_WITH_BOOT_PLAYER),true)
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE
+
+
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \>= 5.0))
+ALSA_LIB_DIR=vendor/amlogic/external/alsa-lib/
+else
+ALSA_LIB_DIR=external/alsa-lib/
+endif
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/include \
+ $(AMAVUTILS_INCLUDE) \
+ $(TOP)/$(ALSA_LIB_DIR)/include
+
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.1.0))
+ LOCAL_CFLAGS += -D_VERSION_JB
+else
+ ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.0.0))
+ LOCAL_CFLAGS += -D_VERSION_ICS
+ endif
+endif
+
+LOCAL_CFLAGS += -DALSA_OUT
+#ifdef DOLBY_UDC
+LOCAL_CFLAGS+=-DDOLBY_USE_ARMDEC
+#endif
+LOCAL_SHARED_LIBRARIES += libasound
+
+LOCAL_SRC_FILES := \
+ adec-external-ctrl.c adec-internal-mgt.c adec-ffmpeg-mgt.c adec-message.c adec-pts-mgt.c feeder.c adec_write.c adec_read.c\
+ dsp/audiodsp-ctl.c audio_out/alsa-out.c audio_out/aml_resample.c audiodsp_update_format.c spdif_api.c pcmenc_api.c \
+ dts_transenc_api.c dts_enc.c adec_omx_brige.c adec-wfd.c
+
+LOCAL_MODULE := libamadec_alsa
+
+LOCAL_ARM_MODE := arm
+
+include $(BUILD_STATIC_LIBRARY)
+
+endif
+
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE
+#ifdef DOLBY_UDC
+ LOCAL_CFLAGS+=-DDOLBY_USE_ARMDEC
+#endif
+
+ifdef DOLBY_DS1_UDC
+ LOCAL_CFLAGS += -DDOLBY_DS1_UDC
+endif
+
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/include \
+ $(AMAVUTILS_INCLUDE) \
+ system/core/base/include
+
+# PLATFORM_SDK_VERSION:
+# 4.4 = 19
+# 4.3 = 18
+# 4.2 = 17
+LOCAL_CFLAGS += -DANDROID_PLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION)
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \>= 4.3))
+ LOCAL_CFLAGS += -DANDROID_VERSION_JBMR2_UP=1
+ ifneq ($(TARGET_BOARD_PLATFORM),meson6)
+ LOCAL_CFLAGS += -DUSE_ARM_AUDIO_DEC
+ endif
+endif
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.1.0))
+ LOCAL_CFLAGS += -D_VERSION_JB
+else
+ ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.0.0))
+ LOCAL_CFLAGS += -D_VERSION_ICS
+ endif
+endif
+
+LOCAL_SRC_FILES := \
+ adec-external-ctrl.c adec-internal-mgt.c adec-ffmpeg-mgt.c adec-message.c adec-pts-mgt.c feeder.c adec_write.c adec_read.c\
+ dsp/audiodsp-ctl.c audio_out/android-out.cpp audio_out/aml_resample.c audiodsp_update_format.c spdif_api.c pcmenc_api.c \
+ dts_transenc_api.c dts_enc.c adec_omx_brige.c adec-wfd.c
+
+LOCAL_MODULE := libamadec
+
+LOCAL_ARM_MODE := arm
+
+
+include $(BUILD_STATIC_LIBRARY)
+
+
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE
+#ifdef DOLBY_UDC
+ LOCAL_CFLAGS+=-DDOLBY_USE_ARMDEC
+#endif
+
+
+
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/include \
+ $(AMAVUTILS_INCLUDE)
+
+
+LOCAL_CFLAGS += -DANDROID_PLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION)
+LOCAL_CFLAGS += -DUSE_ARM_AUDIO_DEC
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \>= 4.3))
+ LOCAL_CFLAGS += -DANDROID_VERSION_JBMR2_UP=1
+endif
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.1.0))
+ LOCAL_CFLAGS += -D_VERSION_JB
+else
+ ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.0.0))
+ LOCAL_CFLAGS += -D_VERSION_ICS
+ endif
+endif
+
+LOCAL_SRC_FILES := \
+ adec-external-ctrl.c adec-internal-mgt.c adec-ffmpeg-mgt.c adec-message.c adec-pts-mgt.c feeder.c adec_write.c adec_read.c\
+ dsp/audiodsp-ctl.c audio_out/android-out.cpp audio_out/aml_resample.c audiodsp_update_format.c \
+ spdif_api.c pcmenc_api.c dts_transenc_api.c dts_enc.c adec_omx_brige.c adec-wfd.c
+
+LOCAL_MODULE := libamadec
+
+LOCAL_ARM_MODE := arm
+##################################################
+#$(shell cp $(LOCAL_PATH)/acodec_lib/*.so $(TARGET_OUT)/lib)
+###################################################
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc libamadec_omx_api libamavutils liblog libaudioclient
+
+LOCAL_PRELINK_MODULE := false
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_SHARED_LIBRARY)
+
+
+###################module make file for libamadec_omx_api ######################################
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE -DDOLBY_DDPDEC51_MULTICHANNEL_ENDPOINT
+LOCAL_CFLAGS += -DANDROID_PLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION)
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/omx_audio/include \
+ $(LOCAL_PATH)/omx_audio/../ \
+ $(LOCAL_PATH)/omx_audio/../include \
+ $(AMAVUTILS_INCLUDE) \
+ frameworks/native/include/media/openmax \
+ frameworks/av/include/media/stagefright \
+ frameworks/native/include/utils
+
+LOCAL_SRC_FILES := \
+ /omx_audio/adec_omx.cpp \
+ /omx_audio/audio_mediasource.cpp \
+ /omx_audio/DDP_mediasource.cpp \
+ /omx_audio/ALAC_mediasource.cpp \
+ /omx_audio/MP3_mediasource.cpp \
+ /omx_audio/ASF_mediasource.cpp \
+ /omx_audio/DTSHD_mediasource.cpp \
+ /omx_audio/Vorbis_mediasource.cpp \
+ /omx_audio/THD_mediasource.cpp
+
+LOCAL_MODULE := libamadec_omx_api
+LOCAL_MODULE_TAGS := optional
+LOCAL_ARM_MODE := arm
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc libstagefright \
+ libstagefright_omx liblog libamavutils libstagefright_foundation
+LOCAL_PRELINK_MODULE := false
+LOCAL_MODULE_TAGS := optional
+
+include $(BUILD_SHARED_LIBRARY)
+#########################################################
+
+
+###################module make wfd audioout api ######################################
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE -DDOLBY_DDPDEC51_MULTICHANNEL_ENDPOINT
+
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \>= 4.3))
+ LOCAL_CFLAGS += -DANDROID_VERSION_JBMR2_UP=1
+endif
+ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.1.0))
+ LOCAL_CFLAGS += -D_VERSION_JB
+else
+ ifneq (0, $(shell expr $(PLATFORM_VERSION) \> 4.0.0))
+ LOCAL_CFLAGS += -D_VERSION_ICS
+ endif
+endif
+LOCAL_CFLAGS += -DANDROID_PLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION)
+LOCAL_C_INCLUDES:= \
+ external/tinyalsa/include
+
+LOCAL_SRC_FILES := \
+ adec-wfd-out.cpp
+
+LOCAL_MODULE := libamadec_wfd_out
+LOCAL_MODULE_TAGS := optional
+LOCAL_ARM_MODE := arm
+
+LOCAL_SHARED_LIBRARIES += libutils libtinyalsa liblog libmedia libcutils libc \
+ libmedia_helper libaudioclient libbinder libdl
+
+LOCAL_PRELINK_MODULE := false
+LOCAL_MODULE_TAGS := optional
+
+include $(BUILD_SHARED_LIBRARY)
+#########################################################
+
+
+#
+# audio_firmware module
+# includes all audio firmware files, which are modules themselves.
+#
+ifeq (0, $(shell expr $(PLATFORM_VERSION) \>= 6.0))
+include $(CLEAR_VARS)
+
+ifeq ($(TARGET_BOARD_PLATFORM),meson6)
+ audio_firmware_dir := firmware-m6
+else ifeq ($(TARGET_BOARD_PLATFORM),meson8)
+ audio_firmware_dir := firmware-m8
+else
+ audio_firmware_dir := firmware
+endif
+
+# generate md5 checksum files
+$(shell cd $(LOCAL_PATH)/$(audio_firmware_dir) && { \
+for f in *.bin; do \
+ md5sum "$$f" > "$$f".checksum; \
+done;})
+
+# gather list of relative filenames
+audio_firmware_files := $(wildcard $(LOCAL_PATH)/$(audio_firmware_dir)/*.bin)
+audio_firmware_files += $(wildcard $(LOCAL_PATH)/$(audio_firmware_dir)/*.checksum)
+audio_firmware_files := $(patsubst $(LOCAL_PATH)/%,%,$(audio_firmware_files))
+
+# define function to create a module for each file
+# $(1): filename
+define _add-audio-firmware-module
+ include $$(CLEAR_VARS)
+ LOCAL_MODULE := audio-firmware_$(notdir $(1))
+ LOCAL_MODULE_STEM := $(notdir $(1))
+ _audio_firmware_modules += $$(LOCAL_MODULE)
+ LOCAL_SRC_FILES := $1
+ LOCAL_MODULE_TAGS := optional
+ LOCAL_MODULE_CLASS := ETC
+ LOCAL_MODULE_PATH := $$(TARGET_OUT_ETC)/firmware
+ include $$(BUILD_PREBUILT)
+endef
+
+# create modules, one for each file
+_audio_firmware_modules :=
+_audio_firmware :=
+$(foreach _firmware, $(audio_firmware_files), \
+ $(eval $(call _add-audio-firmware-module,$(_firmware))))
+
+#LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_MODULE := audio_firmware
+LOCAL_MODULE_CLASS := ETC
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_REQUIRED_MODULES := $(_audio_firmware_modules)
+
+include $(BUILD_PHONY_PACKAGE)
+
+_audio_firmware_modules :=
+_audio_firmware :=
+endif
diff --git a/amadec/acodec_lib_mx/libstagefright_soft_ddpdec.so b/amadec/acodec_lib_mx/libstagefright_soft_ddpdec.so
index 556f9ef..556f9ef 100755..100644
--- a/amadec/acodec_lib_mx/libstagefright_soft_ddpdec.so
+++ b/amadec/acodec_lib_mx/libstagefright_soft_ddpdec.so
diff --git a/amadec/acodec_lib_mx/libstagefright_soft_dtshd.so b/amadec/acodec_lib_mx/libstagefright_soft_dtshd.so
index 67e1409..67e1409 100755..100644
--- a/amadec/acodec_lib_mx/libstagefright_soft_dtshd.so
+++ b/amadec/acodec_lib_mx/libstagefright_soft_dtshd.so
diff --git a/amadec/adec-pts-mgt.c b/amadec/adec-pts-mgt.c
index fd627f7..fd627f7 100755..100644
--- a/amadec/adec-pts-mgt.c
+++ b/amadec/adec-pts-mgt.c
diff --git a/amadec/audio_out/android-out.cpp b/amadec/audio_out/android-out.cpp
index d380ca3..222727d 100755..100644
--- a/amadec/audio_out/android-out.cpp
+++ b/amadec/audio_out/android-out.cpp
@@ -734,7 +734,7 @@ extern "C" int android_init_raw(struct aml_audio_dec* audec)
else if(audec->format == ACODEC_FMT_EAC3)
aformat = AUDIO_FORMAT_EAC3;
else if(audec->format == ACODEC_FMT_TRUEHD)
- aformat = AUDIO_FORMAT_TRUEHD;
+ aformat = AUDIO_FORMAT_DOLBY_TRUEHD;
if(audec->format == ACODEC_FMT_TRUEHD){
audec->codec_type=16;
diff --git a/amadec/include/MetaData.h b/amadec/include/MetaData.h
new file mode 100644
index 0000000..f1e6921
--- a/dev/null
+++ b/amadec/include/MetaData.h
@@ -0,0 +1,345 @@
+/*
+ * Copyright (C) 2009 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef META_DATA_H_
+
+#define META_DATA_H_
+
+#include <sys/types.h>
+
+#include <stdint.h>
+
+#include <binder/Parcel.h>
+#include <utils/RefBase.h>
+#include <utils/KeyedVector.h>
+#include <utils/String8.h>
+
+namespace android {
+
+// The following keys map to int32_t data unless indicated otherwise.
+enum {
+ kKeyMIMEType = 'mime', // cstring
+ kKeyWidth = 'widt', // int32_t, image pixel
+ kKeyHeight = 'heig', // int32_t, image pixel
+ kKeyDisplayWidth = 'dWid', // int32_t, display/presentation
+ kKeyDisplayHeight = 'dHgt', // int32_t, display/presentation
+ kKeySARWidth = 'sarW', // int32_t, sampleAspectRatio width
+ kKeySARHeight = 'sarH', // int32_t, sampleAspectRatio height
+
+ // a rectangle, if absent assumed to be (0, 0, width - 1, height - 1)
+ kKeyCropRect = 'crop',
+
+ kKeyRotation = 'rotA', // int32_t (angle in degrees)
+ kKeyIFramesInterval = 'ifiv', // int32_t
+ kKeyStride = 'strd', // int32_t
+ kKeySliceHeight = 'slht', // int32_t
+ kKeyChannelCount = '#chn', // int32_t
+ kKeyChannelMask = 'chnm', // int32_t
+ kKeySampleRate = 'srte', // int32_t (audio sampling rate Hz)
+ kKeyPcmEncoding = 'PCMe', // int32_t (audio encoding enum)
+ kKeyFrameRate = 'frmR', // int32_t (video frame rate fps)
+ kKeyBitRate = 'brte', // int32_t (bps)
+ kKeyMaxBitRate = 'mxBr', // int32_t (bps)
+ kKeyStreamHeader = 'stHd', // raw data
+ kKeyESDS = 'esds', // raw data
+ kKeyAACProfile = 'aacp', // int32_t
+ kKeyAVCC = 'avcc', // raw data
+ kKeyHVCC = 'hvcc', // raw data
+ kKeyD263 = 'd263', // raw data
+ kKeyVorbisInfo = 'vinf', // raw data
+ kKeyVorbisBooks = 'vboo', // raw data
+ kKeyOpusHeader = 'ohdr', // raw data
+ kKeyOpusCodecDelay = 'ocod', // uint64_t (codec delay in ns)
+ kKeyOpusSeekPreRoll = 'ospr', // uint64_t (seek preroll in ns)
+ kKeyVp9CodecPrivate = 'vp9p', // raw data (vp9 csd information)
+ kKeyWantsNALFragments = 'NALf',
+ kKeyIsSyncFrame = 'sync', // int32_t (bool)
+ kKeyIsCodecConfig = 'conf', // int32_t (bool)
+ kKeyTime = 'time', // int64_t (usecs)
+ kKeyDecodingTime = 'decT', // int64_t (decoding timestamp in usecs)
+ kKeyNTPTime = 'ntpT', // uint64_t (ntp-timestamp)
+ kKeyTargetTime = 'tarT', // int64_t (usecs)
+ kKeyDriftTime = 'dftT', // int64_t (usecs)
+ kKeyAnchorTime = 'ancT', // int64_t (usecs)
+ kKeyDuration = 'dura', // int64_t (usecs)
+ kKeyPixelFormat = 'pixf', // int32_t
+ kKeyColorFormat = 'colf', // int32_t
+ kKeyColorSpace = 'cols', // int32_t
+ kKeyPlatformPrivate = 'priv', // pointer
+ kKeyDecoderComponent = 'decC', // cstring
+ kKeyBufferID = 'bfID',
+ kKeyMaxInputSize = 'inpS',
+ kKeyMaxWidth = 'maxW',
+ kKeyMaxHeight = 'maxH',
+ kKeyThumbnailTime = 'thbT', // int64_t (usecs)
+ kKeyTrackID = 'trID',
+ kKeyIsDRM = 'idrm', // int32_t (bool)
+ kKeyEncoderDelay = 'encd', // int32_t (frames)
+ kKeyEncoderPadding = 'encp', // int32_t (frames)
+
+ kKeyAlbum = 'albu', // cstring
+ kKeyArtist = 'arti', // cstring
+ kKeyAlbumArtist = 'aart', // cstring
+ kKeyComposer = 'comp', // cstring
+ kKeyGenre = 'genr', // cstring
+ kKeyTitle = 'titl', // cstring
+ kKeyYear = 'year', // cstring
+ kKeyAlbumArt = 'albA', // compressed image data
+ kKeyAlbumArtMIME = 'alAM', // cstring
+ kKeyAuthor = 'auth', // cstring
+ kKeyCDTrackNumber = 'cdtr', // cstring
+ kKeyDiscNumber = 'dnum', // cstring
+ kKeyDate = 'date', // cstring
+ kKeyWriter = 'writ', // cstring
+ kKeyCompilation = 'cpil', // cstring
+ kKeyLocation = 'loc ', // cstring
+ kKeyTimeScale = 'tmsl', // int32_t
+ kKeyCaptureFramerate = 'capF', // float (capture fps)
+
+ // video profile and level
+ kKeyVideoProfile = 'vprf', // int32_t
+ kKeyVideoLevel = 'vlev', // int32_t
+
+ // Set this key to enable authoring files in 64-bit offset
+ kKey64BitFileOffset = 'fobt', // int32_t (bool)
+ kKey2ByteNalLength = '2NAL', // int32_t (bool)
+
+ // Identify the file output format for authoring
+ // Please see <media/mediarecorder.h> for the supported
+ // file output formats.
+ kKeyFileType = 'ftyp', // int32_t
+
+ // Track authoring progress status
+ // kKeyTrackTimeStatus is used to track progress in elapsed time
+ kKeyTrackTimeStatus = 'tktm', // int64_t
+
+ kKeyRealTimeRecording = 'rtrc', // bool (int32_t)
+ kKeyNumBuffers = 'nbbf', // int32_t
+
+ // Ogg files can be tagged to be automatically looping...
+ kKeyAutoLoop = 'autL', // bool (int32_t)
+
+ kKeyValidSamples = 'valD', // int32_t
+
+ kKeyIsUnreadable = 'unre', // bool (int32_t)
+
+ // An indication that a video buffer has been rendered.
+ kKeyRendered = 'rend', // bool (int32_t)
+
+ // The language code for this media
+ kKeyMediaLanguage = 'lang', // cstring
+
+ // To store the timed text format data
+ kKeyTextFormatData = 'text', // raw data
+
+ kKeyRequiresSecureBuffers = 'secu', // bool (int32_t)
+
+ kKeyIsADTS = 'adts', // bool (int32_t)
+ kKeyAACAOT = 'aaot', // int32_t
+
+ // If a MediaBuffer's data represents (at least partially) encrypted
+ // data, the following fields aid in decryption.
+ // The data can be thought of as pairs of plain and encrypted data
+ // fragments, i.e. plain and encrypted data alternate.
+ // The first fragment is by convention plain data (if that's not the
+ // case, simply specify plain fragment size of 0).
+ // kKeyEncryptedSizes and kKeyPlainSizes each map to an array of
+ // size_t values. The sum total of all size_t values of both arrays
+ // must equal the amount of data (i.e. MediaBuffer's range_length()).
+ // If both arrays are present, they must be of the same size.
+ // If only encrypted sizes are present it is assumed that all
+ // plain sizes are 0, i.e. all fragments are encrypted.
+ // To programmatically set these array, use the MetaData::setData API, i.e.
+ // const size_t encSizes[];
+ // meta->setData(
+ // kKeyEncryptedSizes, 0 /* type */, encSizes, sizeof(encSizes));
+ // A plain sizes array by itself makes no sense.
+ kKeyEncryptedSizes = 'encr', // size_t[]
+ kKeyPlainSizes = 'plai', // size_t[]
+ kKeyCryptoKey = 'cryK', // uint8_t[16]
+ kKeyCryptoIV = 'cryI', // uint8_t[16]
+ kKeyCryptoMode = 'cryM', // int32_t
+
+ kKeyCryptoDefaultIVSize = 'cryS', // int32_t
+
+ kKeyPssh = 'pssh', // raw data
+
+ // Please see MediaFormat.KEY_IS_AUTOSELECT.
+ kKeyTrackIsAutoselect = 'auto', // bool (int32_t)
+ // Please see MediaFormat.KEY_IS_DEFAULT.
+ kKeyTrackIsDefault = 'dflt', // bool (int32_t)
+ // Similar to MediaFormat.KEY_IS_FORCED_SUBTITLE but pertains to av tracks as well.
+ kKeyTrackIsForced = 'frcd', // bool (int32_t)
+
+ // H264 supplemental enhancement information offsets/sizes
+ kKeySEI = 'sei ', // raw data
+
+ // MPEG user data offsets
+ kKeyMpegUserData = 'mpud', // size_t[]
+
+ // Size of NALU length in mkv/mp4
+ kKeyNalLengthSize = 'nals', // int32_t
+
+ // HDR related
+ kKeyHdrStaticInfo = 'hdrS', // HDRStaticInfo
+
+ // color aspects
+ kKeyColorRange = 'cRng', // int32_t, color range, value defined by ColorAspects.Range
+ kKeyColorPrimaries = 'cPrm', // int32_t,
+ // color Primaries, value defined by ColorAspects.Primaries
+ kKeyTransferFunction = 'tFun', // int32_t,
+ // transfer Function, value defined by ColorAspects.Transfer.
+ kKeyColorMatrix = 'cMtx', // int32_t,
+ // color Matrix, value defined by ColorAspects.MatrixCoeffs.
+ // audio profile
+ kKeyAudioProfile = 'aprf', // int32_t
+ kKeyExtraData = 'exda',
+ kKeyExtraDataSize = 'edsz',
+ kKeyCodecID = 'cdid',
+
+ //amffmpeg extended types
+ kKeyProgramName = 'proN', // cstring
+ kKeyProgramNum = 'PrgN', // int32_t
+ kKeyIsMVC = 'mvc ', // bool (int32_t)
+ kKey4kOSD = '4OSD', // bool (int32_t)
+ KKeyIsDV = 'isDV', // bool (int32_t)
+
+ kKeyBlockAlign = 'bagn',
+ kKeyAudioFlag ='aufg', // audio info reported from decoder to indicate special info
+ kKeyDtsDecoderVer ='dtsV',
+ kKeyDts958Fs ='dtsF',
+ kKeyDts958PktSize ='dtsP',
+ kKeyDts958PktType ='dtsT',
+ kKeyDtsPcmSampsInFrmMaxFs='dtsS',
+ kKeyTemporalLayerId = 'iLyr', // int32_t, temporal layer-id. 0-based (0 => base layer)
+ kKeyTemporalLayerCount = 'cLyr', // int32_t, number of temporal layers encoded
+};
+
+enum {
+ kTypeESDS = 'esds',
+ kTypeAVCC = 'avcc',
+ kTypeHVCC = 'hvcc',
+ kTypeD263 = 'd263',
+};
+
+class MetaData : public RefBase {
+public:
+ MetaData();
+ MetaData(const MetaData &from);
+
+ enum Type {
+ TYPE_NONE = 'none',
+ TYPE_C_STRING = 'cstr',
+ TYPE_INT32 = 'in32',
+ TYPE_INT64 = 'in64',
+ TYPE_FLOAT = 'floa',
+ TYPE_POINTER = 'ptr ',
+ TYPE_RECT = 'rect',
+ };
+
+ void clear();
+ bool remove(uint32_t key);
+
+ bool setCString(uint32_t key, const char *value);
+ bool setInt32(uint32_t key, int32_t value);
+ bool setInt64(uint32_t key, int64_t value);
+ bool setFloat(uint32_t key, float value);
+ bool setPointer(uint32_t key, void *value);
+
+ bool setRect(
+ uint32_t key,
+ int32_t left, int32_t top,
+ int32_t right, int32_t bottom);
+
+ bool findCString(uint32_t key, const char **value);
+ bool findInt32(uint32_t key, int32_t *value);
+ bool findInt64(uint32_t key, int64_t *value);
+ bool findFloat(uint32_t key, float *value);
+ bool findPointer(uint32_t key, void **value);
+
+ bool findRect(
+ uint32_t key,
+ int32_t *left, int32_t *top,
+ int32_t *right, int32_t *bottom);
+
+ bool setData(uint32_t key, uint32_t type, const void *data, size_t size);
+
+ bool findData(uint32_t key, uint32_t *type,
+ const void **data, size_t *size) const;
+
+ bool hasData(uint32_t key) const;
+
+ String8 toString() const;
+ void dumpToLog() const;
+
+ status_t writeToParcel(Parcel &parcel);
+ status_t updateFromParcel(const Parcel &parcel);
+ static sp<MetaData> createFromParcel(const Parcel &parcel);
+
+protected:
+ virtual ~MetaData();
+
+private:
+ struct typed_data {
+ typed_data();
+ ~typed_data();
+
+ typed_data(const MetaData::typed_data &);
+ typed_data &operator=(const MetaData::typed_data &);
+
+ void clear();
+ void setData(uint32_t type, const void *data, size_t size);
+ void getData(uint32_t *type, const void **data, size_t *size) const;
+ // may include hexdump of binary data if verbose=true
+ String8 asString(bool verbose) const;
+
+ private:
+ uint32_t mType;
+ size_t mSize;
+
+ union {
+ void *ext_data;
+ float reservoir;
+ } u;
+
+ bool usesReservoir() const {
+ return mSize <= sizeof(u.reservoir);
+ }
+
+ void *allocateStorage(size_t size);
+ void freeStorage();
+
+ void *storage() {
+ return usesReservoir() ? &u.reservoir : u.ext_data;
+ }
+
+ const void *storage() const {
+ return usesReservoir() ? &u.reservoir : u.ext_data;
+ }
+ };
+
+ struct Rect {
+ int32_t mLeft, mTop, mRight, mBottom;
+ };
+
+ KeyedVector<uint32_t, typed_data> mItems;
+
+ // MetaData &operator=(const MetaData &);
+};
+
+} // namespace android
+
+#endif // META_DATA_H_
diff --git a/amadec/include/adec-macros.h b/amadec/include/adec-macros.h
index e9a5197..e9a5197 100755..100644
--- a/amadec/include/adec-macros.h
+++ b/amadec/include/adec-macros.h
diff --git a/amadec/include/alsa-out.h b/amadec/include/alsa-out.h
index 1be9dd1..1be9dd1 100755..100644
--- a/amadec/include/alsa-out.h
+++ b/amadec/include/alsa-out.h
diff --git a/amadec/omx_audio/ALAC_mediasource.cpp b/amadec/omx_audio/ALAC_mediasource.cpp
index c8e6f42..c8e6f42 100755..100644
--- a/amadec/omx_audio/ALAC_mediasource.cpp
+++ b/amadec/omx_audio/ALAC_mediasource.cpp
diff --git a/amadec/omx_audio/ASF_mediasource.cpp b/amadec/omx_audio/ASF_mediasource.cpp
index a78226f..a78226f 100755..100644
--- a/amadec/omx_audio/ASF_mediasource.cpp
+++ b/amadec/omx_audio/ASF_mediasource.cpp
diff --git a/amadec/omx_audio/Android.mk b/amadec/omx_audio/Android.mk
new file mode 100644
index 0000000..3ccb664
--- a/dev/null
+++ b/amadec/omx_audio/Android.mk
@@ -0,0 +1,31 @@
+LOCAL_PATH:= $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE -DDOLBY_DDPDEC51_MULTICHANNEL_ENDPOINT
+
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/include \
+ $(LOCAL_PATH)/../ \
+ $(LOCAL_PATH)/../include \
+ frameworks/native/include/media/openmax \
+ frameworks/av/include/media/stagefright \
+ frameworks/native/include/utils
+
+LOCAL_SRC_FILES := \
+ adec_omx.cpp audio_mediasource.cpp
+ #../adec_read.c
+
+LOCAL_MODULE := libamadec_omx_api
+
+LOCAL_ARM_MODE := arm
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc libstagefright \
+ libstagefright_omx libmedia_native liblog \
+ libstagefright_foundation
+
+LOCAL_PRELINK_MODULE := false
+LOCAL_MODULE_TAGS := optional
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/amadec/omx_audio/Android.mk.bak b/amadec/omx_audio/Android.mk.bak
new file mode 100644
index 0000000..458961b
--- a/dev/null
+++ b/amadec/omx_audio/Android.mk.bak
@@ -0,0 +1,31 @@
+LOCAL_PATH:= $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_CFLAGS := \
+ -fPIC -D_POSIX_SOURCE -DDOLBY_DDPDEC51_MULTICHANNEL_ENDPOINT
+
+LOCAL_C_INCLUDES:= \
+ $(LOCAL_PATH)/include \
+ $(LOCAL_PATH)/../ \
+ $(LOCAL_PATH)/../include \
+ frameworks/native/include/media/openmax \
+ frameworks/av/include/media/stagefright \
+ frameworks/native/include/utils
+
+LOCAL_SRC_FILES := \
+ adec_omx.cpp audio_mediasource.cpp
+ #../adec_read.c
+
+LOCAL_MODULE := libamadec_omx_api
+
+LOCAL_ARM_MODE := arm
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc libstagefright \
+ libstagefright_omx libstagefright_yuv libmedia_native liblog \
+ libstagefright_foundation
+
+LOCAL_PRELINK_MODULE := false
+LOCAL_MODULE_TAGS := optional
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/amadec/omx_audio/DDP_mediasource.cpp b/amadec/omx_audio/DDP_mediasource.cpp
index ef2bfd9..ef2bfd9 100755..100644
--- a/amadec/omx_audio/DDP_mediasource.cpp
+++ b/amadec/omx_audio/DDP_mediasource.cpp
diff --git a/amadec/omx_audio/MP3_mediasource.cpp b/amadec/omx_audio/MP3_mediasource.cpp
index adf2799..adf2799 100755..100644
--- a/amadec/omx_audio/MP3_mediasource.cpp
+++ b/amadec/omx_audio/MP3_mediasource.cpp
diff --git a/amadec/omx_audio/Vorbis_mediasource.cpp b/amadec/omx_audio/Vorbis_mediasource.cpp
index f74bc15..f74bc15 100755..100644
--- a/amadec/omx_audio/Vorbis_mediasource.cpp
+++ b/amadec/omx_audio/Vorbis_mediasource.cpp
diff --git a/amadec/omx_audio/adec_omx.cpp b/amadec/omx_audio/adec_omx.cpp
index ccde626..952ba6d 100644
--- a/amadec/omx_audio/adec_omx.cpp
+++ b/amadec/omx_audio/adec_omx.cpp
@@ -20,6 +20,7 @@ interface to call OMX codec
#include <string.h>
#include <cutils/properties.h>
#include <Amsysfsutils.h>
+#include <media/IOMX.h>
#define LOG_TAG "Adec_OMX"
#define LOGI(...) __android_log_print(ANDROID_LOG_INFO,LOG_TAG,__VA_ARGS__)
#define LOGE(...) __android_log_print(ANDROID_LOG_ERROR,LOG_TAG,__VA_ARGS__)
diff --git a/amadec/omx_audio/audio_mediasource.cpp b/amadec/omx_audio/audio_mediasource.cpp
index 16333ac..16333ac 100755..100644
--- a/amadec/omx_audio/audio_mediasource.cpp
+++ b/amadec/omx_audio/audio_mediasource.cpp
diff --git a/audio_codec/Android.mk b/audio_codec/Android.mk
new file mode 100644
index 0000000..5053e7d
--- a/dev/null
+++ b/audio_codec/Android.mk
@@ -0,0 +1 @@
+include $(call all-subdir-makefiles)
diff --git a/audio_codec/libadpcm/Android.mk b/audio_codec/libadpcm/Android.mk
new file mode 100644
index 0000000..32cf969
--- a/dev/null
+++ b/audio_codec/libadpcm/Android.mk
@@ -0,0 +1,12 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+LOCAL_MODULE := libadpcm
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+include $(LOCAL_PATH)/../config.mk
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libamr/Android.mk b/audio_codec/libamr/Android.mk
new file mode 100644
index 0000000..acfba97
--- a/dev/null
+++ b/audio_codec/libamr/Android.mk
@@ -0,0 +1,25 @@
+LOCAL_PATH := $(call my-dir)
+
+################################################################################
+include $(CLEAR_VARS)
+LOCAL_MODULE := libamr
+
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH)/
+
+
+include $(BUILD_STATIC_LIBRARY)
+
+#################################################################################
+include $(CLEAR_VARS)
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+LOCAL_MODULE := libamr
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH)/
+
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libamr/Makefile b/audio_codec/libamr/Makefile
index d6c3786..d6c3786 100755..100644
--- a/audio_codec/libamr/Makefile
+++ b/audio_codec/libamr/Makefile
diff --git a/audio_codec/libamr/dec.h b/audio_codec/libamr/dec.h
index e25e711..e25e711 100755..100644
--- a/audio_codec/libamr/dec.h
+++ b/audio_codec/libamr/dec.h
diff --git a/audio_codec/libamr/dec_acelp.h b/audio_codec/libamr/dec_acelp.h
index ac39c57..ac39c57 100755..100644
--- a/audio_codec/libamr/dec_acelp.h
+++ b/audio_codec/libamr/dec_acelp.h
diff --git a/audio_codec/libamr/dec_if.h b/audio_codec/libamr/dec_if.h
index b914218..b914218 100755..100644
--- a/audio_codec/libamr/dec_if.h
+++ b/audio_codec/libamr/dec_if.h
diff --git a/audio_codec/libamr/if_rom.h b/audio_codec/libamr/if_rom.h
index c0fa70c..c0fa70c 100755..100644
--- a/audio_codec/libamr/if_rom.h
+++ b/audio_codec/libamr/if_rom.h
diff --git a/audio_codec/libamr/typedef.h b/audio_codec/libamr/typedef.h
index 6cea8a4..6cea8a4 100755..100644
--- a/audio_codec/libamr/typedef.h
+++ b/audio_codec/libamr/typedef.h
diff --git a/audio_codec/libape/Android.mk b/audio_codec/libape/Android.mk
new file mode 100644
index 0000000..25f0b2a
--- a/dev/null
+++ b/audio_codec/libape/Android.mk
@@ -0,0 +1,28 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libape
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+
+ifeq ($(ARCH_ARM_HAVE_NEON),true)
+ LOCAL_CFLAGS += -D__ARM_HAVE_NEON -DOPT_NEON
+endif
+include $(BUILD_STATIC_LIBRARY)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+
+LOCAL_MODULE := libape
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+LOCAL_PRELINK_MODULE := false
+
+ifeq ($(ARCH_ARM_HAVE_NEON),true)
+ LOCAL_CFLAGS += -D__ARM_HAVE_NEON -DOPT_NEON
+endif
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libcook/Android.mk b/audio_codec/libcook/Android.mk
new file mode 100644
index 0000000..55beb42
--- a/dev/null
+++ b/audio_codec/libcook/Android.mk
@@ -0,0 +1,28 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libcook
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH)
+
+ifeq ($(ARCH_ARM_HAVE_NEON),true)
+ LOCAL_CFLAGS += -D__ARM_HAVE_NEON -DOPT_NEON
+endif
+include $(BUILD_STATIC_LIBRARY)
+
+
+
+include $(CLEAR_VARS)
+
+LOCAL_MODULE := libcook
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libfaad/Android.mk b/audio_codec/libfaad/Android.mk
new file mode 100644
index 0000000..8cf44d0
--- a/dev/null
+++ b/audio_codec/libfaad/Android.mk
@@ -0,0 +1,101 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libfaad
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+
+#helix aac decoder enabled
+#ENABLE_HELIX_AAC_DECODER := true
+ifdef ENABLE_HELIX_AAC_DECODER
+LOCAL_SRC_FILES += \
+ helixaac/aacdec.c \
+ helixaac/aactabs.c \
+ helixaac/bitstream.c \
+ helixaac/buffers.c \
+ helixaac/dct4.c \
+ helixaac/decelmnt.c \
+ helixaac/dequant.c \
+ helixaac/fft.c \
+ helixaac/filefmt.c \
+ helixaac/huffman_helix.c \
+ helixaac/hufftabs.c \
+ helixaac/imdct.c \
+ helixaac/noiseless.c \
+ helixaac/pns_helix.c \
+ helixaac/sbr.c \
+ helixaac/sbrfft.c \
+ helixaac/sbrfreq.c \
+ helixaac/sbrhfadj.c \
+ helixaac/sbrhfgen.c \
+ helixaac/sbrhuff.c \
+ helixaac/sbrimdct.c \
+ helixaac/sbrmath.c \
+ helixaac/sbrqmf.c \
+ helixaac/sbrside.c \
+ helixaac/sbrtabs.c \
+ helixaac/stproc.c \
+ helixaac/tns_helix.c \
+ helixaac/trigtabs.c \
+ helixaac/trigtabs_fltgen.c
+LOCAL_CFLAGS += -DUSE_DEFAULT_STDLIB -DUSE_HELIX_AAC_DECODER
+endif
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+ $(LOCAL_PATH)/codebook
+#aac helix include file
+LOCAL_C_INCLUDES += $(LOCAL_PATH)/helixaac
+
+include $(BUILD_STATIC_LIBRARY)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libz libbinder libdl libcutils libc liblog
+
+LOCAL_MODULE := libfaad
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+ifdef ENABLE_HELIX_AAC_DECODER
+#helix aac files
+LOCAL_SRC_FILES += \
+ helixaac/aacdec.c \
+ helixaac/aactabs.c \
+ helixaac/bitstream.c \
+ helixaac/buffers.c \
+ helixaac/dct4.c \
+ helixaac/decelmnt.c \
+ helixaac/dequant.c \
+ helixaac/fft.c \
+ helixaac/filefmt.c \
+ helixaac/huffman_helix.c \
+ helixaac/hufftabs.c \
+ helixaac/imdct.c \
+ helixaac/noiseless.c \
+ helixaac/pns_helix.c \
+ helixaac/sbr.c \
+ helixaac/sbrfft.c \
+ helixaac/sbrfreq.c \
+ helixaac/sbrhfadj.c \
+ helixaac/sbrhfgen.c \
+ helixaac/sbrhuff.c \
+ helixaac/sbrimdct.c \
+ helixaac/sbrmath.c \
+ helixaac/sbrqmf.c \
+ helixaac/sbrside.c \
+ helixaac/sbrtabs.c \
+ helixaac/stproc.c \
+ helixaac/tns_helix.c \
+ helixaac/trigtabs.c \
+ helixaac/trigtabs_fltgen.c
+LOCAL_CFLAGS += -DUSE_DEFAULT_STDLIB -DUSE_HELIX_AAC_DECODER
+endif
+
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+ $(LOCAL_PATH)/codebook
+
+#aac helix include file
+LOCAL_C_INCLUDES += $(LOCAL_PATH)/helixaac
+
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libfaad/Makefile b/audio_codec/libfaad/Makefile
index 551d047..551d047 100755..100644
--- a/audio_codec/libfaad/Makefile
+++ b/audio_codec/libfaad/Makefile
diff --git a/audio_codec/libfaad/audio.d b/audio_codec/libfaad/audio.d
index 2504225..2504225 100755..100644
--- a/audio_codec/libfaad/audio.d
+++ b/audio_codec/libfaad/audio.d
diff --git a/audio_codec/libfaad/bits.d b/audio_codec/libfaad/bits.d
index 1a23624..1a23624 100755..100644
--- a/audio_codec/libfaad/bits.d
+++ b/audio_codec/libfaad/bits.d
diff --git a/audio_codec/libfaad/decoder.c b/audio_codec/libfaad/decoder.c
index 88edad5..6d4490f 100644
--- a/audio_codec/libfaad/decoder.c
+++ b/audio_codec/libfaad/decoder.c
@@ -35,6 +35,7 @@
#include <stdlib.h>
#include <string.h>
#include <fcntl.h>
+#include <android/log.h>
#include "mp4.h"
#include "syntax.h"
diff --git a/audio_codec/libfaad/libfaad2.def b/audio_codec/libfaad/libfaad2.def
index 6ae934d..6ae934d 100755..100644
--- a/audio_codec/libfaad/libfaad2.def
+++ b/audio_codec/libfaad/libfaad2.def
diff --git a/audio_codec/libflac/Android.mk b/audio_codec/libflac/Android.mk
new file mode 100644
index 0000000..bad1265
--- a/dev/null
+++ b/audio_codec/libflac/Android.mk
@@ -0,0 +1,22 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libflac
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+
+include $(BUILD_STATIC_LIBRARY)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+
+LOCAL_MODULE := libflac
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/liblpcm/Android.mk b/audio_codec/liblpcm/Android.mk
new file mode 100644
index 0000000..047b182
--- a/dev/null
+++ b/audio_codec/liblpcm/Android.mk
@@ -0,0 +1,13 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libcutils libc liblog
+LOCAL_MODULE := libpcm_wfd
+LOCAL_SRC_FILES := lpcm_decode.c
+#$(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) $(LOCAL_PATH)/../../amadec/include $(LOCAL_PATH)/../../amadec/
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libmad/Android.mk b/audio_codec/libmad/Android.mk
new file mode 100644
index 0000000..f169151
--- a/dev/null
+++ b/audio_codec/libmad/Android.mk
@@ -0,0 +1,13 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+
+LOCAL_MODULE := libmad
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+LOCAL_PRELINK_MODULE := false
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libmad/D.dat b/audio_codec/libmad/D.dat
index 4a7fa4f..4a7fa4f 100755..100644
--- a/audio_codec/libmad/D.dat
+++ b/audio_codec/libmad/D.dat
diff --git a/audio_codec/libmad/imdct_l_arm.S b/audio_codec/libmad/imdct_l_arm.S
index badec5b..badec5b 100755..100644
--- a/audio_codec/libmad/imdct_l_arm.S
+++ b/audio_codec/libmad/imdct_l_arm.S
diff --git a/audio_codec/libmad/imdct_s.dat b/audio_codec/libmad/imdct_s.dat
index 476710e..476710e 100755..100644
--- a/audio_codec/libmad/imdct_s.dat
+++ b/audio_codec/libmad/imdct_s.dat
diff --git a/audio_codec/libmad/layer12.h b/audio_codec/libmad/layer12.h
index e1c4996..e1c4996 100755..100644
--- a/audio_codec/libmad/layer12.h
+++ b/audio_codec/libmad/layer12.h
diff --git a/audio_codec/libmad/layer3.h b/audio_codec/libmad/layer3.h
index 2504d46..2504d46 100755..100644
--- a/audio_codec/libmad/layer3.h
+++ b/audio_codec/libmad/layer3.h
diff --git a/audio_codec/libmad/qc_table.dat b/audio_codec/libmad/qc_table.dat
index 35a2223..35a2223 100755..100644
--- a/audio_codec/libmad/qc_table.dat
+++ b/audio_codec/libmad/qc_table.dat
diff --git a/audio_codec/libmad/rq_table.dat b/audio_codec/libmad/rq_table.dat
index 059c4f3..059c4f3 100755..100644
--- a/audio_codec/libmad/rq_table.dat
+++ b/audio_codec/libmad/rq_table.dat
diff --git a/audio_codec/libmad/sf_table.dat b/audio_codec/libmad/sf_table.dat
index db1484a..db1484a 100755..100644
--- a/audio_codec/libmad/sf_table.dat
+++ b/audio_codec/libmad/sf_table.dat
diff --git a/audio_codec/libpcm/Android.mk b/audio_codec/libpcm/Android.mk
new file mode 100644
index 0000000..ea40534
--- a/dev/null
+++ b/audio_codec/libpcm/Android.mk
@@ -0,0 +1,11 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+LOCAL_MODULE := libpcm
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+include $(LOCAL_PATH)/../config.mk
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libraac/Android.mk b/audio_codec/libraac/Android.mk
new file mode 100644
index 0000000..83389cb
--- a/dev/null
+++ b/audio_codec/libraac/Android.mk
@@ -0,0 +1,51 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libraac
+
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+#ifeq ($(TARGET_ARCH),arm)
+#LOCAL_SRC_FILES += sbrcov.s\
+# sbrqmfak.s\
+# sbrqmfsk.s
+#endif
+LOCAL_CFLAGS := -DHAVE_NEON=1 -DHAVE_CONFIG -DOPT_NEON -DREAL_IS_FLOAT -DAAC_ENABLE_SBR
+
+ifeq ($(TARGET_ARCH),arm)
+LOCAL_CFLAGS += -mfloat-abi=softfp -mfpu=neon
+endif
+
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH)\
+ $(LOCAL_PATH)/include
+
+include $(BUILD_STATIC_LIBRARY)
+
+
+#########################################################################
+include $(CLEAR_VARS)
+
+LOCAL_MODULE := libraac
+
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+#ifeq ($(TARGET_ARCH),arm)
+#LOCAL_SRC_FILES += sbrcov.s\
+# sbrqmfak.s\
+# sbrqmfsk.s
+#endif
+LOCAL_CFLAGS := -DHAVE_NEON=1 -DHAVE_CONFIG -DOPT_NEON -DREAL_IS_FLOAT -DAAC_ENABLE_SBR
+
+ifeq ($(TARGET_ARCH),arm)
+LOCAL_CFLAGS += -mfloat-abi=softfp -mfpu=neon
+endif
+
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH)\
+ $(LOCAL_PATH)/include
+
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/libraac/sbrcov.s b/audio_codec/libraac/sbrcov.s
index 0239712..0239712 100755..100644
--- a/audio_codec/libraac/sbrcov.s
+++ b/audio_codec/libraac/sbrcov.s
diff --git a/audio_codec/libraac/sbrqmfak.s b/audio_codec/libraac/sbrqmfak.s
index ceb3e2b..ceb3e2b 100755..100644
--- a/audio_codec/libraac/sbrqmfak.s
+++ b/audio_codec/libraac/sbrqmfak.s
diff --git a/audio_codec/libraac/sbrqmfsk.s b/audio_codec/libraac/sbrqmfsk.s
index ea93f7a..ea93f7a 100755..100644
--- a/audio_codec/libraac/sbrqmfsk.s
+++ b/audio_codec/libraac/sbrqmfsk.s
diff --git a/audio_codec/wfd_aac_decoder/Android.mk b/audio_codec/wfd_aac_decoder/Android.mk
new file mode 100644
index 0000000..19b5395
--- a/dev/null
+++ b/audio_codec/wfd_aac_decoder/Android.mk
@@ -0,0 +1,23 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libaac_helix
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+ $(LOCAL_PATH)/codebook
+LOCAL_CFLAGS += -DUSE_DEFAULT_STDLIB
+include $(BUILD_STATIC_LIBRARY)
+
+include $(CLEAR_VARS)
+LOCAL_SHARED_LIBRARIES += libutils libmedia libz libbinder libdl libcutils libc liblog
+LOCAL_CFLAGS += -DUSE_DEFAULT_STDLIB
+LOCAL_MODULE := libaac_helix
+LOCAL_SRC_FILES := $(notdir $(wildcard $(LOCAL_PATH)/*.c))
+LOCAL_ARM_MODE := arm
+LOCAL_MODULE_TAGS := optional
+LOCAL_C_INCLUDES := $(LOCAL_PATH) \
+ $(LOCAL_PATH)/codebook
+LOCAL_PRELINK_MODULE := false
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/audio_codec/wfd_aac_decoder/helix_aac_decode.c b/audio_codec/wfd_aac_decoder/helix_aac_decode.c
index ae32386..020db9e 100644
--- a/audio_codec/wfd_aac_decoder/helix_aac_decode.c
+++ b/audio_codec/wfd_aac_decoder/helix_aac_decode.c
@@ -8,7 +8,7 @@
#include <dlfcn.h>
#include <sys/mman.h>
#include <cutils/properties.h>
-
+#include <android/log.h>
#include "aaccommon.h"