From d09793afbd992eaeb571aa77a6ecbe558d6e66bb Mon Sep 17 00:00:00 2001 From: Jari Vetoniemi Date: Tue, 27 Feb 2018 13:42:36 +0200 Subject: app: Unity related work --- src/app.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/app.c b/src/app.c index 9b7fd14..0d171d3 100644 --- a/src/app.c +++ b/src/app.c @@ -60,12 +60,16 @@ main(int argc, const char *argv[]) native_file(&jvm.env, context, android_content_Context_getPackageCodePath(&jvm.env, context, 0)); native_init_www(&jvm.env, context, jvm.native.FindClass(&jvm.env, "com/unity3d/player/WWW")); native_init_web_request(&jvm.env, context, jvm.native.FindClass(&jvm.env, "com/unity3d/player/UnityWebRequest")); - native_recreate_gfx_state(&jvm.env, context, 0, context); native_file(&jvm.env, context, jvm.env->NewStringUTF(&jvm.env, "/mnt/media/dev/android2gnulinux/file.apk")); native_file(&jvm.env, context, jvm.env->NewStringUTF(&jvm.env, "/mnt/media/dev/android2gnulinux/local/obb/com.miHoYo.bh3oversea/main.81.com.miHoYo.bh3oversea.obb")); + native_recreate_gfx_state(&jvm.env, context, 0, context); native_focus_changed(&jvm.env, context, true); // native_done(&jvm.env, context); - native_render(&jvm.env, context); + + while (1) { + bool ret = native_render(&jvm.env, context); + fprintf(stderr, "%d\n", ret); + } printf("unloading module: %s\n", argv[1]); bionic_dlclose(handle); -- cgit v1.2.3-70-g09d2