summaryrefslogtreecommitdiffstats
path: root/opengl/tests/angeles
diff options
context:
space:
mode:
Diffstat (limited to 'opengl/tests/angeles')
-rw-r--r--opengl/tests/angeles/Android.mk3
-rw-r--r--opengl/tests/angeles/app-linux.cpp11
2 files changed, 8 insertions, 6 deletions
diff --git a/opengl/tests/angeles/Android.mk b/opengl/tests/angeles/Android.mk
index ae4f76d..c78224e 100644
--- a/opengl/tests/angeles/Android.mk
+++ b/opengl/tests/angeles/Android.mk
@@ -3,7 +3,8 @@
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
LOCAL_SRC_FILES:= app-linux.cpp demo.c.arm
-LOCAL_SHARED_LIBRARIES := libEGL libGLESv1_CM libui
+LOCAL_SHARED_LIBRARIES := libEGL libGLESv1_CM libui libgui libutils
+LOCAL_STATIC_LIBRARIES += libglTest
LOCAL_C_INCLUDES += $(call include-path-for, opengl-tests-includes)
LOCAL_MODULE:= angeles
LOCAL_MODULE_TAGS := optional
diff --git a/opengl/tests/angeles/app-linux.cpp b/opengl/tests/angeles/app-linux.cpp
index 6ac68a2..e490351 100644
--- a/opengl/tests/angeles/app-linux.cpp
+++ b/opengl/tests/angeles/app-linux.cpp
@@ -52,8 +52,8 @@
#include <EGL/egl.h>
#include <GLES/gl.h>
-#include <ui/FramebufferNativeWindow.h>
-#include "EGLUtils.h"
+#include <EGLUtils.h>
+#include <WindowSurface.h>
using namespace android;
@@ -118,7 +118,7 @@ static void checkEGLErrors()
fprintf(stderr, "EGL Error: 0x%04x\n", (int)error);
}
-static int initGraphics(unsigned samples)
+static int initGraphics(unsigned samples, const WindowSurface& windowSurface)
{
EGLint configAttribs[] = {
EGL_DEPTH_SIZE, 16,
@@ -135,7 +135,7 @@ static int initGraphics(unsigned samples)
EGLint w, h;
EGLDisplay dpy;
- EGLNativeWindowType window = android_createDisplaySurface();
+ EGLNativeWindowType window = windowSurface.getSurface();
dpy = eglGetDisplay(EGL_DEFAULT_DISPLAY);
eglInitialize(dpy, &majorVersion, &minorVersion);
@@ -193,7 +193,8 @@ int main(int argc, char *argv[])
printf("Multisample enabled: GL_SAMPLES = %u\n", samples);
}
- if (!initGraphics(samples))
+ WindowSurface windowSurface;
+ if (!initGraphics(samples, windowSurface))
{
fprintf(stderr, "Graphics initialization failed.\n");
return EXIT_FAILURE;