Loading jni/Android.mk +2 −2 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) LOCAL_CFLAGS += -DEGL_EGLEXT_PROTOTYPES LOCAL_CFLAGS += -DEGL_EGLEXT_PROTOTYPES -Wno-unused-parameter LOCAL_SRC_FILES := jni_egl_fence.cpp Loading Loading @@ -44,7 +44,7 @@ LOCAL_SRC_FILES := filters/gradient.c \ filters/tinyplanet.cc \ filters/kmeans.cc LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops -Wno-unused-parameter LOCAL_LDLIBS := -llog -ljnigraphics LOCAL_ARM_MODE := arm Loading jni/filters/filters.h +2 −2 Original line number Diff line number Diff line Loading @@ -43,8 +43,8 @@ typedef unsigned int Color; #define ALPHA (i+3) #define CLAMP(c) (MAX(0, MIN(255, c))) __inline__ unsigned char clamp(int c); __inline__ int clampMax(int c,int max); extern unsigned char clamp(int c); extern int clampMax(int c,int max); extern void rgb2hsv( unsigned char *rgb,int rgbOff,unsigned short *hsv,int hsvOff); extern void hsv2rgb(unsigned short *hsv,int hsvOff,unsigned char *rgb,int rgbOff); Loading jni/filters/geometry.c +2 −4 Original line number Diff line number Diff line Loading @@ -75,10 +75,8 @@ static __inline__ void rotate90(char * source, int srcWidth, int srcHeight, char int width = cpy_bytes * srcWidth; int length = srcHeight; int total = length * width; int i = 0; int j = 0; for (j = 0; j < length * cpy_bytes; j+= cpy_bytes){ for (i = 0; i < width; i+=cpy_bytes){ for (size_t j = 0; j < length * cpy_bytes; j+= cpy_bytes){ for (int i = 0; i < width; i+=cpy_bytes){ int column_disp = (width - cpy_bytes - i) * length; int row_disp = j; memcpy(destination + column_disp + row_disp , source + j * srcWidth + i, cpy_bytes); Loading jni/filters/wbalance.c +4 −4 Original line number Diff line number Diff line Loading @@ -99,10 +99,10 @@ void estmateWhite(unsigned char *src, int len, int *wr, int *wb, int *wg){ } void estmateWhiteBox(unsigned char *src, int iw, int ih, int x,int y, int *wr, int *wb, int *wg){ int r; int g; int b; int sum; int r = 0; int g = 0; int b = 0; int sum = 0; int xp,yp; int bounds = 5; if (x<0) x = bounds; Loading Loading
jni/Android.mk +2 −2 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) LOCAL_CFLAGS += -DEGL_EGLEXT_PROTOTYPES LOCAL_CFLAGS += -DEGL_EGLEXT_PROTOTYPES -Wno-unused-parameter LOCAL_SRC_FILES := jni_egl_fence.cpp Loading Loading @@ -44,7 +44,7 @@ LOCAL_SRC_FILES := filters/gradient.c \ filters/tinyplanet.cc \ filters/kmeans.cc LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops LOCAL_CFLAGS += -ffast-math -O3 -funroll-loops -Wno-unused-parameter LOCAL_LDLIBS := -llog -ljnigraphics LOCAL_ARM_MODE := arm Loading
jni/filters/filters.h +2 −2 Original line number Diff line number Diff line Loading @@ -43,8 +43,8 @@ typedef unsigned int Color; #define ALPHA (i+3) #define CLAMP(c) (MAX(0, MIN(255, c))) __inline__ unsigned char clamp(int c); __inline__ int clampMax(int c,int max); extern unsigned char clamp(int c); extern int clampMax(int c,int max); extern void rgb2hsv( unsigned char *rgb,int rgbOff,unsigned short *hsv,int hsvOff); extern void hsv2rgb(unsigned short *hsv,int hsvOff,unsigned char *rgb,int rgbOff); Loading
jni/filters/geometry.c +2 −4 Original line number Diff line number Diff line Loading @@ -75,10 +75,8 @@ static __inline__ void rotate90(char * source, int srcWidth, int srcHeight, char int width = cpy_bytes * srcWidth; int length = srcHeight; int total = length * width; int i = 0; int j = 0; for (j = 0; j < length * cpy_bytes; j+= cpy_bytes){ for (i = 0; i < width; i+=cpy_bytes){ for (size_t j = 0; j < length * cpy_bytes; j+= cpy_bytes){ for (int i = 0; i < width; i+=cpy_bytes){ int column_disp = (width - cpy_bytes - i) * length; int row_disp = j; memcpy(destination + column_disp + row_disp , source + j * srcWidth + i, cpy_bytes); Loading
jni/filters/wbalance.c +4 −4 Original line number Diff line number Diff line Loading @@ -99,10 +99,10 @@ void estmateWhite(unsigned char *src, int len, int *wr, int *wb, int *wg){ } void estmateWhiteBox(unsigned char *src, int iw, int ih, int x,int y, int *wr, int *wb, int *wg){ int r; int g; int b; int sum; int r = 0; int g = 0; int b = 0; int sum = 0; int xp,yp; int bounds = 5; if (x<0) x = bounds; Loading