diff --git a/.gitmodules b/.gitmodules
index d05d4ab10..bfd0edac3 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -25,3 +25,9 @@
[submodule "submodules/externals/libswscale"]
path = submodules/externals/libswscale
url = git://git.ffmpeg.org/libswscale
+[submodule "submodules/externals/x264"]
+ path = submodules/externals/x264
+ url = git://git.videolan.org/x264.git
+[submodule "submodules/msx264"]
+ path = submodules/msx264
+ url = git://git.linphone.org/msx264.git
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index e14f2d402..b2279146a 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -68,8 +68,7 @@
-
+
@@ -115,8 +114,8 @@
-
+
diff --git a/jni/Android.mk b/jni/Android.mk
index 22bd02fdf..477bb04af 100644
--- a/jni/Android.mk
+++ b/jni/Android.mk
@@ -18,7 +18,10 @@ include $(root-dir)/submodules/linphone/mediastreamer2/build/android/Android.mk
ifeq ($(TARGET_ARCH_ABI),armeabi-v7a)
include $(root-dir)/submodules/msilbc/Android.mk
+include $(root-dir)/submodules/msx264/Android.mk
include $(root-dir)/submodules/externals/build/ffmpeg/Android.mk
+include $(root-dir)/submodules/externals/build/x264/Android.mk
+
endif
include $(root-dir)/submodules/linphone/build/android/Android.mk
diff --git a/jni/Application.mk b/jni/Application.mk
index ad5a65625..0b1d358e1 100644
--- a/jni/Application.mk
+++ b/jni/Application.mk
@@ -3,7 +3,7 @@ APP_MODULES :=libspeex libgsm libortp libosip2 libeXosip2 libmediastreamer2
ifeq ($(TARGET_ARCH_ABI),armeabi-v7a)
-APP_MODULES +=libmsilbc libavutil libavcore libavcodec libswscale
+APP_MODULES +=libmsilbc libavutil libavcore libavcodec libswscale libx264 libmsx264
endif
APP_BUILD_SCRIPT:=$(call my-dir)/Android.mk
APP_PLATFORM := android-8
diff --git a/libs/armeabi-v7a/liblinphone.so b/libs/armeabi-v7a/liblinphone.so
index a2f4deded..cff6679ef 100755
Binary files a/libs/armeabi-v7a/liblinphone.so and b/libs/armeabi-v7a/liblinphone.so differ
diff --git a/libs/armeabi/liblinphone.so b/libs/armeabi/liblinphone.so
index 620b944a9..a535ad95b 100755
Binary files a/libs/armeabi/liblinphone.so and b/libs/armeabi/liblinphone.so differ
diff --git a/res/layout/videocall.xml b/res/layout/videocall.xml
index df869cb3a..33da7f149 100644
--- a/res/layout/videocall.xml
+++ b/res/layout/videocall.xml
@@ -1,7 +1,7 @@
diff --git a/src/org/linphone/core/AndroidVideoWindowImpl.java b/src/org/linphone/core/AndroidVideoWindowImpl.java
index 9f6281bec..ec7eb2cbb 100644
--- a/src/org/linphone/core/AndroidVideoWindowImpl.java
+++ b/src/org/linphone/core/AndroidVideoWindowImpl.java
@@ -48,10 +48,16 @@ public class AndroidVideoWindowImpl {
}
if (mListener!=null)
mListener.onSurfaceDestroyed(AndroidVideoWindowImpl.this);
- Log.w("Linphone", "Video display surface destroyed");
+ Log.d("Linphone", "Video display surface destroyed");
}
});
}
+ static final int LANDSCAPE=0;
+ static final int PORTRAIT=1;
+ public void requestOrientation(int orientation){
+ //Surface.setOrientation(0, orientation==LANDSCAPE ? 1 : 0);
+ //Log.d("Linphone", "Orientation changed.");
+ }
public void setListener(VideoWindowListener l){
mListener=l;
}
diff --git a/submodules/externals/build/x264/Android.mk b/submodules/externals/build/x264/Android.mk
new file mode 100644
index 000000000..2943c71b1
--- /dev/null
+++ b/submodules/externals/build/x264/Android.mk
@@ -0,0 +1,61 @@
+#
+# List of compiled files and related options obtained using
+# ./configure --cross-prefix=arm-none-linux-gnueabi- --host=arm-none-linux-gnueabi --disable-pthread --enable-pic
+# && make
+#
+
+LOCAL_PATH:= $(call my-dir)/../../x264
+include $(CLEAR_VARS)
+
+LOCAL_MODULE := libx264
+
+LOCAL_SRC_FILES = \
+ common/mc.c \
+ common/predict.c \
+ common/pixel.c \
+ common/macroblock.c \
+ common/frame.c \
+ common/dct.c \
+ common/cpu.c \
+ common/cabac.c \
+ common/common.c \
+ common/mdate.c \
+ common/rectangle.c \
+ common/set.c \
+ common/quant.c \
+ common/deblock.c \
+ common/vlc.c \
+ common/mvpred.c \
+ common/bitstream.c \
+ encoder/analyse.c \
+ encoder/me.c \
+ encoder/ratecontrol.c \
+ encoder/set.c \
+ encoder/macroblock.c \
+ encoder/cabac.c \
+ encoder/cavlc.c \
+ encoder/encoder.c \
+ encoder/lookahead.c \
+ common/arm/mc-c.c \
+ common/arm/predict-c.c \
+ common/arm/cpu-a.S \
+ common/arm/pixel-a.S \
+ common/arm/mc-a.S \
+ common/arm/dct-a.S \
+ common/arm/quant-a.S \
+ common/arm/deblock-a.S \
+ common/arm/predict-a.S
+
+
+LOCAL_ARM_MODE := arm
+
+
+LOCAL_CFLAGS += -DPIC -DBIT_DEPTH=8 -std=gnu99
+
+#for including config.h:
+LOCAL_C_INCLUDES += \
+ $(LOCAL_PATH)/../build/x264 \
+ $(LOCAL_PATH)/
+
+include $(BUILD_STATIC_LIBRARY)
+
diff --git a/submodules/externals/build/x264/config.h b/submodules/externals/build/x264/config.h
new file mode 100644
index 000000000..9e532298c
--- /dev/null
+++ b/submodules/externals/build/x264/config.h
@@ -0,0 +1,24 @@
+#define HAVE_MALLOC_H 1
+#define HAVE_ARMV6 1
+#define HAVE_ARMV6T2 1
+#define HAVE_NEON 1
+#define ARCH_ARM 1
+#define SYS_LINUX 1
+#define HAVE_LOG2F 0
+#define fseek fseeko
+#define ftell ftello
+#define BIT_DEPTH 8
+#define HAVE_GPL 1
+#define HAVE_ALTIVEC 0
+#define HAVE_ALTIVEC_H 0
+#define HAVE_MMX 0
+#define HAVE_PTHREAD 0
+#define HAVE_VISUALIZE 0
+#define HAVE_SWSCALE 0
+#define HAVE_LAVF 0
+#define HAVE_FFMS 0
+#define HAVE_GPAC 0
+#define HAVE_GF_MALLOC 0
+#define HAVE_AVS 0
+#define X264_VERSION " r1804 e89c4cf"
+#define X264_POINTVER "0.110.1804 e89c4cf"
diff --git a/submodules/externals/x264 b/submodules/externals/x264
new file mode 160000
index 000000000..e89c4cfc9
--- /dev/null
+++ b/submodules/externals/x264
@@ -0,0 +1 @@
+Subproject commit e89c4cfc9f37d0b7684507974b333545b5bcc37a
diff --git a/submodules/linphone b/submodules/linphone
index a5d821c32..5cdf29100 160000
--- a/submodules/linphone
+++ b/submodules/linphone
@@ -1 +1 @@
-Subproject commit a5d821c32ea57fa44d8cec86ca0d9b805a3b3f4a
+Subproject commit 5cdf291009aa0481259b99ff15c62d0c178d5e36
diff --git a/submodules/msx264 b/submodules/msx264
new file mode 160000
index 000000000..e9852e6e8
--- /dev/null
+++ b/submodules/msx264
@@ -0,0 +1 @@
+Subproject commit e9852e6e87809242ad126fc776fa1373673ab7f2