1LOCAL_PATH := $(call my-dir)
2include $(CLEAR_VARS)
3
4ifeq ($(ENABLE_IMG_GRAPHICS),)
5LOCAL_CFLAGS += \
6    -DBX_RC \
7    -DOSCL_IMPORT_REF= \
8    -DOSCL_UNUSED_ARG= \
9    -DOSCL_EXPORT_REF=
10
11LOCAL_STATIC_LIBRARIES := \
12    libstagefright_m4vh263enc
13endif
14
15LOCAL_SRC_FILES := \
16    VideoEncoderBase.cpp \
17    VideoEncoderAVC.cpp \
18    VideoEncoderH263.cpp \
19    VideoEncoderMP4.cpp \
20    VideoEncoderVP8.cpp \
21    VideoEncoderUtils.cpp \
22    VideoEncoderHost.cpp
23
24# VideoEncoderAVC.cpp has extraneous parentheses and
25# uses va_enc_h264.h with empty union.
26LOCAL_CLANG_CFLAGS += \
27    -Wno-parentheses-equality \
28    -Wno-extern-c-compat
29
30ifeq ($(ENABLE_IMG_GRAPHICS),)
31    LOCAL_SRC_FILES += PVSoftMPEG4Encoder.cpp
32endif
33
34LOCAL_C_INCLUDES := \
35    $(TARGET_OUT_HEADERS)/libva \
36    $(call include-path-for, frameworks-native) \
37    $(TARGET_OUT_HEADERS)/pvr
38
39ifeq ($(ENABLE_IMG_GRAPHICS),)
40LOCAL_C_INCLUDES += \
41    frameworks/av/media/libstagefright/codecs/m4v_h263/enc/include \
42    frameworks/av/media/libstagefright/codecs/m4v_h263/enc/src \
43    frameworks/av/media/libstagefright/codecs/common/include \
44    frameworks/native/include/media/openmax \
45    frameworks/native/include/media/hardware \
46    frameworks/av/media/libstagefright/include
47endif
48
49LOCAL_SHARED_LIBRARIES := \
50    libcutils \
51    libutils \
52    libva \
53    libva-android \
54    libva-tpi \
55    libhardware \
56    libintelmetadatabuffer \
57    libsync
58
59LOCAL_COPY_HEADERS_TO  := libmix_videoencoder
60
61LOCAL_COPY_HEADERS := \
62    VideoEncoderHost.h \
63    VideoEncoderInterface.h \
64    VideoEncoderDef.h
65
66ifeq ($(VIDEO_ENC_LOG_ENABLE),true)
67LOCAL_CPPFLAGS += -DVIDEO_ENC_LOG_ENABLE
68endif
69
70ifeq ($(NO_BUFFER_SHARE),true)
71LOCAL_CPPFLAGS += -DNO_BUFFER_SHARE
72endif
73
74ifeq ($(VIDEO_ENC_STATISTICS_ENABLE),true)
75LOCAL_CPPFLAGS += -DVIDEO_ENC_STATISTICS_ENABLE
76endif
77
78ifeq ($(ENABLE_IMG_GRAPHICS),true)
79    LOCAL_CFLAGS += -DIMG_GFX
80
81    ifeq ($(ENABLE_MRFL_GRAPHICS),true)
82        LOCAL_CFLAGS += -DMRFLD_GFX
83    endif
84endif
85
86LOCAL_CFLAGS += -Werror
87LOCAL_MODULE_TAGS := optional
88LOCAL_MODULE := libva_videoencoder
89
90include $(BUILD_SHARED_LIBRARY)
91
92# For libintelmetadatabuffer
93# =====================================================
94
95include $(CLEAR_VARS)
96
97VIDEO_ENC_LOG_ENABLE := true
98
99LOCAL_SRC_FILES := \
100    IntelMetadataBuffer.cpp
101
102LOCAL_COPY_HEADERS_TO  := libmix_videoencoder
103
104LOCAL_COPY_HEADERS := \
105    IntelMetadataBuffer.h
106
107ifeq ($(INTEL_VIDEO_XPROC_SHARING),true)
108LOCAL_SHARED_LIBRARIES := liblog libutils libbinder libgui \
109                          libui libcutils libhardware
110endif
111LOCAL_CFLAGS += -Werror
112LOCAL_MODULE_TAGS := optional
113LOCAL_MODULE := libintelmetadatabuffer
114
115include $(BUILD_SHARED_LIBRARY)
116