3dphotoshoot

changeset 23:a94af102872f

minor mistake
author John Tsiombikas <nuclear@member.fsf.org>
date Sat, 13 Jun 2015 05:35:43 +0300
parents d7fe157c402d
children 2712c5da2e00
files android/Makefile src/android/amain.c
diffstat 2 files changed, 9 insertions(+), 7 deletions(-) [+]
line diff
     1.1 --- a/android/Makefile	Sat Jun 13 05:32:07 2015 +0300
     1.2 +++ b/android/Makefile	Sat Jun 13 05:35:43 2015 +0300
     1.3 @@ -65,6 +65,8 @@
     1.4  clean:
     1.5  	rm -f $(obj) $(lib) $(apk-release) $(apk-debug) $(ant_files)
     1.6  	rm -rf $(ant_dirs)
     1.7 +	rm -f assets/data assets/sdr
     1.8 +	rmdir assets
     1.9  
    1.10  .PHONY: install
    1.11  install: install-debug
     2.1 --- a/src/android/amain.c	Sat Jun 13 05:32:07 2015 +0300
     2.2 +++ b/src/android/amain.c	Sat Jun 13 05:35:43 2015 +0300
     2.3 @@ -21,7 +21,7 @@
     2.4  static EGLSurface surf;
     2.5  static EGLContext ctx;
     2.6  
     2.7 -static int win_width, win_height;
     2.8 +static int width, height;
     2.9  static int init_done;
    2.10  
    2.11  static JavaVM *jvm;
    2.12 @@ -128,10 +128,10 @@
    2.13  		{
    2.14  			int nx = ANativeWindow_getWidth(app->window);
    2.15  			int ny = ANativeWindow_getHeight(app->window);
    2.16 -			if(nx != win_width || ny != win_height) {
    2.17 +			if(nx != width || ny != height) {
    2.18  				game_reshape(nx, ny);
    2.19 -				win_width = nx;
    2.20 -				win_height = ny;
    2.21 +				width = nx;
    2.22 +				height = ny;
    2.23  			}
    2.24  		}
    2.25  		break;
    2.26 @@ -259,9 +259,9 @@
    2.27  	}
    2.28  	eglMakeCurrent(dpy, surf, surf, ctx);
    2.29  
    2.30 -	eglQuerySurface(dpy, surf, EGL_WIDTH, &win_width);
    2.31 -	eglQuerySurface(dpy, surf, EGL_HEIGHT, &win_height);
    2.32 -	game_reshape(win_width, win_height);
    2.33 +	eglQuerySurface(dpy, surf, EGL_WIDTH, &width);
    2.34 +	eglQuerySurface(dpy, surf, EGL_HEIGHT, &height);
    2.35 +	game_reshape(width, height);
    2.36  
    2.37  	return 0;
    2.38  }