You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
(38) |
Apr
(39) |
May
(1) |
Jun
|
Jul
|
Aug
(5) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(36) |
Feb
(3) |
Mar
(7) |
Apr
|
May
(1) |
Jun
(9) |
Jul
(23) |
Aug
(5) |
Sep
(2) |
Oct
(2) |
Nov
(11) |
Dec
|
2008 |
Jan
|
Feb
(4) |
Mar
(5) |
Apr
(5) |
May
|
Jun
|
Jul
(5) |
Aug
(16) |
Sep
(6) |
Oct
|
Nov
|
Dec
(10) |
2009 |
Jan
(4) |
Feb
(17) |
Mar
(6) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
From: <sen...@us...> - 2009-01-25 10:09:05
|
Revision: 351 http://open2x.svn.sourceforge.net/open2x/?rev=351&view=rev Author: senquack Date: 2009-01-25 10:08:59 +0000 (Sun, 25 Jan 2009) Log Message: ----------- Adjusted default Timidity paths per Pickle's suggestion, enabled trig lookup tables. Modified Paths: -------------- trunk/libs-new/sdl/sdl_mixer/SDL_mixer-1.2.8/timidity/config.h Modified: trunk/libs-new/sdl/sdl_mixer/SDL_mixer-1.2.8/timidity/config.h =================================================================== --- trunk/libs-new/sdl/sdl_mixer/SDL_mixer-1.2.8/timidity/config.h 2009-01-01 10:18:45 UTC (rev 350) +++ trunk/libs-new/sdl/sdl_mixer/SDL_mixer-1.2.8/timidity/config.h 2009-01-25 10:08:59 UTC (rev 351) @@ -111,7 +111,8 @@ /* On some machines (especially PCs without math coprocessors), looking up sine values in a table will be significantly faster than computing them on the fly. Uncomment this to use lookups. */ -/* #define LOOKUP_SINE */ +//senquack - enabling table lookups for GP2X +#define LOOKUP_SINE /* Shawn McHorse's resampling optimizations. These may not in fact be faster on your particular machine and compiler. You'll have to run @@ -170,13 +171,18 @@ /* You could specify a complete path, e.g. "/etc/timidity.cfg", and then specify the library directory in the configuration file. */ #define CONFIG_FILE "timidity.cfg" -#define CONFIG_FILE_ETC "/etc/timidity.cfg" -#define CONFIG_FILE_ETC_TIMIDITY "/etc/timidity/timidity.cfg" +//senquack - changed this per Pickle's suggestion +//#define CONFIG_FILE_ETC "/etc/timidity.cfg" +#define CONFIG_FILE_ETC "/mnt/sd/timidity.cfg" +//#define CONFIG_FILE_ETC_TIMIDITY "/etc/timidity/timidity.cfg" +#define CONFIG_FILE_ETC_TIMIDITY "/mnt/sd/timidity/timidity.cfg" #if defined(__WIN32__) || defined(__OS2__) #define DEFAULT_PATH "\\TIMIDITY" #else -#define DEFAULT_PATH "/usr/local/lib/timidity" +//senquack - changed this per Pickle's suggestion +//#define DEFAULT_PATH "/usr/local/lib/timidity" +#define DEFAULT_PATH "/mnt/sd/timidity" #endif /* These affect general volume */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2009-01-01 10:18:49
|
Revision: 350 http://open2x.svn.sourceforge.net/open2x/?rev=350&view=rev Author: senquack Date: 2009-01-01 10:18:45 +0000 (Thu, 01 Jan 2009) Log Message: ----------- Added option to disable raising of touchscreen mouse motion events Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h 2009-01-01 09:47:13 UTC (rev 349) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h 2009-01-01 10:18:45 UTC (rev 350) @@ -57,6 +57,12 @@ // the cursor with clicking done by joystick buttons. Default is enabled. void SDL_GP2X_TouchpadMouseButtonEvents(int enabled); +// Enable (1) or disable (0) the touchscreen stylus from causing mouse motion events or +// registering changes in cursor state. Sometimes a developer may wish to easily +// disable the touchscreen and not have to modify large sections of code in a porting +// project. Default is enabled. +void SDL_GP2X_TouchpadMouseMotionEvents(int enabled); + #ifdef __cplusplus } #endif Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2009-01-01 09:47:13 UTC (rev 349) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2009-01-01 10:18:45 UTC (rev 350) @@ -368,7 +368,8 @@ int i; Uint8 state; - if ( dx || dy ) { + //senquack - support for new option to disable mouse motion events from touchscreen + if (( dx || dy ) && current_video->hidden->mouse_motion_events_enabled) { posted += SDL_PrivateMouseMotion(0, relative, dx, dy); } Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c 2009-01-01 09:47:13 UTC (rev 349) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c 2009-01-01 10:18:45 UTC (rev 350) @@ -186,6 +186,8 @@ // senquack - new user-configurable option, see SDL_gp2xvideo.h for description device->hidden->mouse_button_events_enabled = 1; /* default is enabled */ + // senquack - new user-configurable option, see SDL_gp2xvideo.h for description + device->hidden->mouse_motion_events_enabled = 1; /* default is enabled */ // Set the function pointers device->VideoInit = GP2X_VideoInit; @@ -1624,3 +1626,15 @@ current_video->hidden->mouse_button_events_enabled = enabled ? 1:0; } } + +// Enable (1) or disable (0) the touchscreen stylus from causing mouse motion events or +// registering changes in cursor state. Sometimes a developer may wish to easily +// disable the touchscreen and not have to modify large sections of code in a porting +// project. Default is enabled. +void SDL_GP2X_TouchpadMouseMotionEvents(int enabled) +{ + if (current_video->hidden->mouse_type == 2) + { + current_video->hidden->mouse_motion_events_enabled = enabled ? 1:0; + } +} Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h 2009-01-01 09:47:13 UTC (rev 349) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h 2009-01-01 10:18:45 UTC (rev 350) @@ -137,10 +137,13 @@ int current_vt; int saved_vt; int mouse_type; - //senquack - new option + //senquack - new options int mouse_button_events_enabled; /* User-configurable option. default = 1: post mouse button events when stylus goes up or down. 0: don't post button events */ + int mouse_motion_events_enabled; /* User-configurable option. default = 1: post mouse + motion events when stylus is down + 0: don't post motion events */ struct tsdev *ts_dev; struct termios saved_kbd_termios; int touch_x, touch_y, touch_pressure; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2009-01-01 09:47:24
|
Revision: 349 http://open2x.svn.sourceforge.net/open2x/?rev=349&view=rev Author: senquack Date: 2009-01-01 09:47:13 +0000 (Thu, 01 Jan 2009) Log Message: ----------- Added workaround for touchscreen driver sometimes not returning valid samples until device file is closed and reopened. Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2008-12-24 16:44:53 UTC (rev 348) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2009-01-01 09:47:13 UTC (rev 349) @@ -66,6 +66,15 @@ //DKS - added for USB keyboard support #define tty_fd this->hidden->keyboard_fd +//DKS - this remains zero until a sample containing a non-zero pressure value has been +// read from the touchscreen. It is a work-around for a bug. The bug is that +// about 10% of the time the touchscreen device is opened, it returns nothing but +// zero values until closed and reopened. Once it starts returning true values, it +// never needs to be closed and reopened. Code uses this flag to see if it should +// try to close and reopen the touchscreen device several times a second or so until +// it does get good values. +unsigned int gotten_nonzero_sample = 0; + /*********** *** Mouse stuff **********/ @@ -406,6 +415,14 @@ this->hidden->touch_y = sample.y; this->hidden->touch_pressure = sample.pressure; + //DKS - once we have gotten a valid sample from the touchscreen, this flag tells + // handle_mouse to stop trying to reopen the mouse device every second or so + // so as a workaround fora non-responsive device file. + if ( sample.pressure > 0 ) + { + gotten_nonzero_sample = 1; + } + sample.x = ((sample.x * this->hidden->invxscale) >> 16) + this->hidden->x_offset; sample.y = ((sample.y * this->hidden->invyscale) >> 16) + @@ -589,6 +606,8 @@ //DKS for determining if we should read the touchscreen or wait some more static struct timeval lastread = { 0, 0 }; static struct timeval now = { 0, 0 }; + unsigned int sample_interval; + static unsigned int touchscreen_reopen_ctr = 0; /* Figure out the mouse packet size */ switch (mouse_drv) { @@ -616,15 +635,42 @@ #define TSLIB_INTERVAL 5000 // every 5 ms, which allows us to capture all events but // not waste cycles gettimeofday(&now, NULL); - if (((now.tv_sec * 1000000 + now.tv_usec) - - (lastread.tv_sec * 1000000 + lastread.tv_usec)) > TSLIB_INTERVAL) { + sample_interval = (now.tv_sec * 1000000 + now.tv_usec) - + (lastread.tv_sec * 1000000 + lastread.tv_usec); + + + if ( !gotten_nonzero_sample && touchscreen_reopen_ctr >= 100) + { + // We are running on a GP2X with touchscreen, but we have not gotten + // a sample with non-zero pressure yet. This workaround will continue + // to try to close and reopen the touchscreen device every second or so + // until we get a non-zero sample. Once we do, don't worry about it as + // the unit should be OK after that. Once a second or so should not cause + // too much overhead for games not using the touchscreen. + +#ifdef DEBUG_MOUSE + fprintf(stderr, "SDL_GP2X: Not gotten good F200 touchscreen sample yet.\n\t\tReopening device just in case.\n"); +#endif + ts_close(this->hidden->ts_dev); + this->hidden->ts_dev = ts_open("/dev/touchscreen/wm97xx", 1); + this->hidden->mouse_fd = this->hidden->ts_dev->fd; + touchscreen_reopen_ctr = 0; + } + + if (sample_interval > TSLIB_INTERVAL) + { // 5ms has passed, read a touchscreen sample handle_tslib(this); gettimeofday(&lastread, NULL); + if (!gotten_nonzero_sample) + { + touchscreen_reopen_ctr++; + } } else { dx = 0; dy = 0; } + // handle_tslib(this); return; /* nothing left to do */ case NUM_MOUSE_DRVS: Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c 2008-12-24 16:44:53 UTC (rev 348) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c 2009-01-01 09:47:13 UTC (rev 349) @@ -24,10 +24,6 @@ #include "tslib.h" -typedef struct tsdev { - int fd; -} TSDEV; - typedef struct ts_sample TS_SAMPLE; typedef struct tslib_vars { @@ -66,17 +62,24 @@ return ts; } + + int ts_close(TSDEV *ts) { - int ret; + if (ts) + { + if (ts->fd != -1) + { + close(ts->fd); + free(ts); + return 0; + } + } - ret = close(ts->fd); - free(ts); - - return ret; + return -1; } -int ts_fd(TSDEV *ts) +inline int ts_fd(TSDEV *ts) { return ts->fd; } @@ -86,14 +89,6 @@ * ucb1x100-raw ******************************/ -//DKS - I am having problems reading the device, it is only returning 8 bytes -//typedef struct ucb1x00_ts_event { -// unsigned short pressure; -// unsigned short x; -// unsigned short y; -// unsigned short pad; -// struct timeval stamp; -//} UCB1X00_TS_EVENT; typedef struct ucb1x00_ts_event { unsigned short pressure; unsigned short x; @@ -101,107 +96,6 @@ unsigned short pad; } UCB1X00_TS_EVENT; - -//DKS -//static int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp) -//{ -// UCB1X00_TS_EVENT ucb1x00_evt; -// int ret; -// -// ret = read(ts->fd, &ucb1x00_evt, sizeof(ucb1x00_evt)); -// if (ret > 0) { -// samp->x = ucb1x00_evt.x; -// samp->y = ucb1x00_evt.y; -// samp->pressure = ucb1x00_evt.pressure; -// samp->tv.tv_usec = ucb1x00_evt.stamp.tv_usec; -// samp->tv.tv_sec = ucb1x00_evt.stamp.tv_sec; -// ret = 1; -// } else -// ret = -1; -// -// return ret; -//} -//DKS - known working copy, latest one before change to read multiple samples: -//static int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp) -//{ -// UCB1X00_TS_EVENT ucb1x00_evt; -// int ret; -// -// ret = read(ts->fd, &ucb1x00_evt, sizeof(ucb1x00_evt)); -// if (ret > 0) { -// samp->x = ucb1x00_evt.x; -// samp->y = ucb1x00_evt.y; -// samp->pressure = ucb1x00_evt.pressure; -// -// //DKS -//#ifdef DKS_DEBUG -// if (samp->pressure > 0) { -// if (samp->pressure < tslib_minpressure) { -// tslib_minpressure = samp->pressure; -// } -// if (samp->pressure > tslib_maxpressure) { -// tslib_maxpressure = samp->pressure; -// } -// } -//#endif -// -// //DKS - we're never going to need this -//// samp->tv.tv_usec = ucb1x00_evt.stamp.tv_usec; -//// samp->tv.tv_sec = ucb1x00_evt.stamp.tv_sec; -// ret = 1; -// } else -// ret = -1; -// -// return ret; -//} -//DKS - OK, hours of work only to find you cannot read more than one sample at a time -// out of the touchscreen device -//DKS - I am gonna disable this code for now, change it to a for loop and read more at a time -//static inline int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp, int nr) -//{ -//// struct tsdev *ts = inf->dev; -//// struct ucb1x00_ts_event *ucb1x00_evt; -// UCB1X00_TS_EVENT *ucb1x00_evt; -// int ret; -//// int total = 0; -// ucb1x00_evt = alloca(sizeof(UCB1X00_TS_EVENT) * nr); -// -// tslib_debug5 = sizeof(UCB1X00_TS_EVENT) * nr; // DKS - got 16 here -// -// ret = read(ts->fd, ucb1x00_evt, sizeof(UCB1X00_TS_EVENT) * nr); -// -// //DKS - debugging -//// tslib_debug = ret; // this gave me 8 -// tslib_debug = sizeof(UCB1X00_TS_EVENT); // this gave me 16 -// tslib_debug4 = ret; // GOT 8 here -// -// int numread = 0; -// if(ret > 0) { -// numread = ret / sizeof(UCB1X00_TS_EVENT); -// -// tslib_debug2 = numread; -// -// while(ret >= (int)sizeof(UCB1X00_TS_EVENT)) { -// samp->x = ucb1x00_evt->x; -// samp->y = ucb1x00_evt->y; -// samp->pressure = ucb1x00_evt->pressure; -////#ifdef DEBUG -//// fprintf(stderr,"RAW---------------------------> %d %d %d\n",samp->x,samp->y,samp->pressure); -////#endif /*DEBUG*/ -// //DKS - won't need these -//// samp->tv.tv_usec = ucb1x00_evt->stamp.tv_usec; -//// samp->tv.tv_sec = ucb1x00_evt->stamp.tv_sec; -// samp++; -// ucb1x00_evt++; -// ret -= sizeof(UCB1X00_TS_EVENT); -// } -// } else { -// return -1; -// } -// -// ret = numread; -// return ret; -//} //DKS - Originially, I had made this read multiple samples but it turns out the driver //for the touchscreen is set up to give only one sample per read, so had to go back //to this optimized version. It should be noted that the device file only ever provides @@ -211,12 +105,16 @@ { UCB1X00_TS_EVENT ucb1x00_evt; - if (read(ts->fd, &ucb1x00_evt, sizeof(UCB1X00_TS_EVENT)) == sizeof(UCB1X00_TS_EVENT)) { - samp->x = ucb1x00_evt.x; - samp->y = ucb1x00_evt.y; - samp->pressure = ucb1x00_evt.pressure; - return 1; - } else { + // senquack -trying to solve touchscreen bug + if (read(ts->fd, &ucb1x00_evt, sizeof(UCB1X00_TS_EVENT)) == sizeof(UCB1X00_TS_EVENT)) + { + samp->x = ucb1x00_evt.x; + samp->y = ucb1x00_evt.y; + samp->pressure = ucb1x00_evt.pressure; + return 1; + } + else + { return -1; } @@ -227,101 +125,6 @@ * pthres ******************************/ -//DKS - don't need these -//typedef struct tslib_pthres { -// unsigned int pmin; -// unsigned int pmax; -//} TSLIB_PTHRES; -// -//TSLIB_PTHRES pthres_dev; -// -//int threshold_vars(char *str, void *data) -//{ -// unsigned long v; -// int err = errno; -// -// v = strtoul(str, NULL, 0); -// if (v == ULONG_MAX && errno == ERANGE) -// return -1; -// errno = err; -// switch ((int)data) { -// case 0: -// pthres_dev.pmin = v; -// break; -// case 1: -// pthres_dev.pmax = v; -// break; -// default: -// return -1; -// } -// return 0; -//} - -//DKS - don't need this -//static const TSLIB_VARS pthres_vars[] = { -// {"pmin", (void *)0, threshold_vars}, -// {"pmax", (void *)1, threshold_vars} -//}; - -//DKS - don't need this -//#define NR_PTHRES_VARS (sizeof(pthres_vars) / sizeof(pthres_vars[0])) - - -//DKS - no idea why we might still need this -//int pthres_init(const char *params) -//{ -// int ret = 0; -// -// pthres_dev.pmin = 1; -// pthres_dev.pmax = INT_MAX; -// if (tslib_parse_vars(pthres_vars, NR_PTHRES_VARS, params)) { -// ret = 1; -// } -// -// return ret; -//} - -//DKS ok, there is a bad pointer dereference in TS_SAMPLE below, gonna copy and fix it. -//int pthres_read(TSDEV *ts, TS_SAMPLE *samp) -//{ -//#ifdef DKS_DEBUG -// //DKS - continuously update this to current global variable value, so programs can -// // tweak it real-time -// pthres_dev.pmin = tslib_pmin; -//#endif -// -// int ret; -// static int xsave = 0, ysave = 0; -// static int press = 0; -// -// ret = ucb1x00_read(ts, samp); -// if (ret >= 0) { -// TS_SAMPLE *s; -// -// if (s->pressure < pthres_dev.pmin) { -// if (press != 0) { -// press = 0; -// s->pressure = 0; -// s->x = xsave; -// s->y = ysave; -// ret = 1; -// } else -// ret = 0; -// } else { -// if (s->pressure > pthres_dev.pmax) -// ret = 0; -// else { -// press = 1; -// xsave = s->x; -// ysave = s->y; -// ret = 1; -// } -// } -// } -// -// return ret; -//} -//int pthres_read(TSDEV *ts, TS_SAMPLE *samp) #define MINPRESSURE 35000 // Accepting pressures below this on the GP2X F200 leads to // cursor jumping on taps. static inline int pthres_read(TSDEV *ts, TS_SAMPLE *samp, int nr) @@ -354,76 +157,7 @@ return ret; } -//DKS - known working copy of multiple-sample version, but changing back to 1-sample for now -//#define MINPRESSURE 35000 //DKS - for the GP2X, reading values below this results in -// // tapping inaccuracies -////static int -//static inline int -////pthres_read(struct tslib_module_info *info, struct ts_sample *samp, int nr) -//pthres_read(TSDEV *ts, TS_SAMPLE *samp, int nr) -//{ -//// struct tslib_pthres *p = (struct tslib_pthres *)info; -// int ret; -// static int xsave = 0, ysave = 0; -// static int press = 0; -// -//// ret = info->next->ops->read(info->next, samp, nr); -// ret = ucb1x00_read(ts, samp, nr); -// if (ret >= 0) { -// int nr = 0, i; -// struct ts_sample *s; -// -// for (s = samp, i = 0; i < ret; i++, s++) { -//// if (s->pressure < p->pmin) { -// if (s->pressure < MINPRESSURE) { -// if (press != 0) { -// /* release */ -// press = 0; -// s->pressure = 0; -// s->x = xsave; -// s->y = ysave; -// } else { -// /* release with no press, outside bounds, dropping */ -// int left = ret - nr - 1; -// if (left > 0) { -// memmove(s, s + 1, left * sizeof(struct ts_sample)); -// s--; -// continue; -// } -// break; -// } -// } else { -////DKS - on the GP2X F200, we don't worry about pressure maximums -//// if (s->pressure > p->pmax) { -//// /* pressure outside bounds, dropping */ -//// int left = ret - nr - 1; -//// if (left > 0) { -//// memmove(s, s + 1, left * sizeof(struct ts_sample)); -//// s--; -//// continue; -//// } -//// break; -//// } -// /* press */ -// press = 1; -// xsave = s->x; -// ysave = s->y; -// } -// nr++; -// } -// return nr; -// } -// return ret; -//} -//DKS - no idea why we might need this still -//static int pthres_fini(struct tslib_module_info *info) -//{ -// free(info); -// return 0; -//} - - /****************************** * variance ******************************/ @@ -441,45 +175,11 @@ TSLIB_VARIANCE variance_dev; -static int variance_limit(char *str, void *data) +void variance_init() { - unsigned long v; - int err = errno; - - v = strtoul(str, NULL, 0); - if (v == ULONG_MAX && errno == ERANGE) - return -1; - errno = err; - switch ((int)data) { - case 1: - variance_dev.delta = v; - break; - default: - return -1; - } - return 0; -} - -static const TSLIB_VARS variance_vars[] = { - {"delta", (void *)1, variance_limit} -}; - -#define NR_VAR_VARS (sizeof(variance_vars) / sizeof(variance_vars[0])) - -int variance_init(const char *params) -{ - int ret = 0; - - bzero(&variance_dev, sizeof(variance_dev)); - variance_dev.delta = 30; + memset(&variance_dev, 0, sizeof(variance_dev)); variance_dev.flags = 0; - if (tslib_parse_vars(variance_vars, NR_VAR_VARS, params)) { - ret = 1; - } -// variance_dev.delta = sqr(variance_dev.delta); - variance_dev.delta = SQR(variance_dev.delta); - - return ret; + variance_dev.delta = 30 * 30; } //DKS - added parameter, flush_history, that gets assigned to 1 if a fast movement is @@ -558,165 +258,6 @@ return count; } - -/****************************** - * dejitter - ******************************/ - -//#define NR_SAMPHISTLEN 4 -//static const unsigned char weight[NR_SAMPHISTLEN - 1][NR_SAMPHISTLEN + 1] = -// { -// // DKS - experiment.. the last of each row is the number 2^x that we should divide by, -// // the first four numbers in each row should add up to 2^x -//// {5, 3, 0, 0, 3}, -//// {8, 5, 3, 0, 4}, -//// {6, 4, 3, 3, 4} -// {1, 3, 2, 2, 3}, -// {2, 6, 4, 4, 4}, -// {6, 4, 3, 3, 4} -// }; -// -//typedef struct ts_hist { -// int x; -// int y; -// unsigned int p; -//} TS_HIST; -// -//typedef struct tslib_dejitter { -// int delta; -// int x; -// int y; -// int down; -// int nr; -// int head; -// TS_HIST hist[NR_SAMPHISTLEN]; -//} TSLIB_DEJITTER; -// -//TSLIB_DEJITTER dejitter_dev; -// -//static int dejitter_limit(char *str, void *data) -//{ -// unsigned long v; -// int err = errno; -// -// v = strtoul(str, NULL, 0); -// if (v == ULONG_MAX && errno == ERANGE) -// return -1; -// errno = err; -// switch ((int)data) { -// case 1: -// dejitter_dev.delta = v; -// break; -// default: -// return -1; -// } -// return 0; -//} -// -//static const TSLIB_VARS dejitter_vars[] = { -// {"delta", (void *)1, dejitter_limit} -//}; -// -//#define NR_DEJITTER_VARS (sizeof(dejitter_vars) / sizeof(dejitter_vars[0])) - -//DKS - changing to use SQR macro, not that it matters here -//int dejitter_init(const char *params) -//{ -// int ret = 0; -// -// bzero(&dejitter_dev, sizeof(dejitter_dev)); -// dejitter_dev.delta = 100; -// dejitter_dev.head = 0; -// if (tslib_parse_vars(dejitter_vars, NR_DEJITTER_VARS, params)) { -// ret = 1; -// } -// dejitter_dev.delta = sqr(dejitter_dev.delta); -// -// return ret; -//} -//int dejitter_init(const char *params) -//{ -// int ret = 0; -// -// bzero(&dejitter_dev, sizeof(dejitter_dev)); -// dejitter_dev.delta = 100; -// dejitter_dev.head = 0; -// if (tslib_parse_vars(dejitter_vars, NR_DEJITTER_VARS, params)) { -// ret = 1; -// } -//// dejitter_dev.delta = sqr(dejitter_dev.delta); -// dejitter_dev.delta = SQR(dejitter_dev.delta); -// -// return ret; -//} - -//static void average(TS_SAMPLE *samp) -//{ -// const unsigned char *w; -// int sn = dejitter_dev.head; -// int i, x = 0, y = 0; -// unsigned int p = 0; -// -// w = weight[dejitter_dev.nr - 2]; -// -// for (i = 0; i < dejitter_dev.nr; i++) { -// x += dejitter_dev.hist[sn].x * w[i]; -// y += dejitter_dev.hist[sn].y * w[i]; -// p += dejitter_dev.hist[sn].p * w[i]; -// sn = (sn - 1) & (NR_SAMPHISTLEN - 1); -// } -// -// samp->x = x >> w[NR_SAMPHISTLEN]; -// samp->y = y >> w[NR_SAMPHISTLEN]; -// samp->pressure = p >> w[NR_SAMPHISTLEN]; -//} -// -//static int dejitter_read(TSDEV *ts, TS_SAMPLE *samp) -//{ -//#ifdef DKS_DEBUG -// dejitter_dev.delta = tslib_dejitter; -// if (tslib_skipdejitter) { -// return (variance_read(ts, samp)); -// } -//#endif -// TS_SAMPLE *s; -// int count = 0, ret; -// -// ret = variance_read(ts, samp); -// for (s = samp; ret > 0; s++, ret--) { -// if (s->pressure == 0) { -// dejitter_dev.nr = 0; -// samp[count++] = *s; -// continue; -// } -// -// if (dejitter_dev.nr) { -// int prev = (dejitter_dev.head - 1) & (NR_SAMPHISTLEN - 1); -// if (sqr(s->x - dejitter_dev.hist[prev].x) + -// sqr(s->y - dejitter_dev.hist[prev].y) > dejitter_dev.delta) -// dejitter_dev.nr = 0; -// } -// -// dejitter_dev.hist[dejitter_dev.head].x = s->x; -// dejitter_dev.hist[dejitter_dev.head].y = s->y; -// dejitter_dev.hist[dejitter_dev.head].p = s->pressure; -// if (dejitter_dev.nr < NR_SAMPHISTLEN) -// dejitter_dev.nr++; -// -// if (dejitter_dev.nr == 1) -// samp[count] = *s; -// else { -// average(samp + count); -// samp[count].tv = s->tv; -// } -// count++; -// dejitter_dev.head = (dejitter_dev.head + 1) & (NR_SAMPHISTLEN - 1); -// } -// -// return count; -//} - -//DKS - gonna do my own de-jitterer that can handle high noise level of the GP2X typedef struct { int x; int y; @@ -725,6 +266,7 @@ #define XYHISTLENGTH 15 XYHIST average_xyhist[XYHISTLENGTH]; +//DKS - De-jitterer that can handle high noise level of the GP2X: static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) { @@ -921,230 +463,18 @@ return ret; } -//DKS - non-pyramid form of the above, I cannot tell a real difference, will use pyramid for now. -//#define XYHISTLENGTH 15 -//XYHIST average_xyhist[XYHISTLENGTH]; -// -//static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) -//{ -// -// int ret = 0; -// int newx, newy; -// -// int flush_history = 0; // variance module will tell us if we are getting fast movements -// static int flush_count = 0; // when we get enough fast movements, flush the history -// static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 -// static int xyhist_counter = 0; // DKS - how many entires in history? -// static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array -// -// ret = variance_read(ts, samp, nr, &flush_history); -// flush_count += flush_history; -// struct ts_sample *s; -// s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x -// // touchscreen driver only ever provides 1 sample each read so -// // it's not really necessary but not really inefficient either way -// int i; -// -// for( i = ret; i > 0; i--, s--) { -// if ((s->pressure == 0) || (flush_count > 7)) { -// // when pen is lifted, or a fast movement is detected, flush stored history -// xyhist_full = 0; -// xyhist_counter = 0; -// xyhist_index = 0; -// flush_count = 0; -// } else { -// average_xyhist[xyhist_index].x = s->x; -// average_xyhist[xyhist_index].y = s->y; -// -// xyhist_counter++; -// if (xyhist_counter == XYHISTLENGTH) { -// xyhist_full = 1; -// } -// -// xyhist_index++; -// if (xyhist_index == XYHISTLENGTH) { -// xyhist_index = 0; // point back at beginning since array is full -// } -// -// if (xyhist_full) { -// //we have a full sample history, we can average this sample with the others -// -// int j = xyhist_index - 1; // point j to most recent entry in history -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // 15-sample weighted average, pyramid, provides great smoothing for precise -// // operations like menus and drawing -// -// // sample 1 has weight of * 15 -// newx = average_xyhist[j].x * 15; -// newy = average_xyhist[j].y * 15; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 2 has weight of * 14 -// newx += average_xyhist[j].x * 14; -// newy += average_xyhist[j].y * 14; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 3 has weight of * 13 -// newx += average_xyhist[j].x * 13; -// newy += average_xyhist[j].y * 13; -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 4 has weight of * 12 -// newx += average_xyhist[j].x * 12; -// newy += average_xyhist[j].y * 12; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 5 has weight of * 11 -// newx += average_xyhist[j].x * 11; -// newy += average_xyhist[j].y * 11; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 6 has weight of * 10 -// newx += average_xyhist[j].x * 10; -// newy += average_xyhist[j].y * 10; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 7 has weight of * 9 -// newx += average_xyhist[j].x * 9; -// newy += average_xyhist[j].y * 9; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 8, middle sample, has weight of * 8 -// newx += (average_xyhist[j].x << 3); -// newy += (average_xyhist[j].y << 3); -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 9 has weight of * 7 -// newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; -// newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 10 has weight of * 6 -// newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); -// newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 11 has weight of * 5 -// newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 12 has weight of * 4 -// newx += average_xyhist[j].x << 2; -// newy += average_xyhist[j].y << 2; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 13 has weight of * 3 -// newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 14 has weight of * 2 -// newx += average_xyhist[j].x << 1; -// newy += average_xyhist[j].y << 1; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// // sample 15 has weight of * 1 -// newx += average_xyhist[j].x; -// newy += average_xyhist[j].y; -// -// j--; -// if (j < 0) { -// j = XYHISTLENGTH - 1; -// } -// -// samp->x = newx / 120; -// samp->y = newy / 120; -// } -// } -// } -// -// return ret; -//} /****************************** * linear ******************************/ typedef struct tslib_linear { - int swap_xy; int a[7]; } TSLIB_LINEAR; TSLIB_LINEAR linear_dev; -//DKS - don't need this anymore -//static int linear_xyswap(char *str, void *data) -//{ -// linear_dev.swap_xy = 1; -// return 0; -//} - -//DKS - don't need this anymore -//static const TSLIB_VARS linear_vars[] = { -// {"xyswap", (void *)1, linear_xyswap} -//}; -//#define NR_LINEAR_VARS (sizeof(linear_vars) / sizeof(linear_vars[0])) - -int linear_init(const char *params) +void linear_init() { struct stat sbuf; int pcal_fd, ret = 0; @@ -1162,27 +492,7 @@ linear_dev.a[4] = -4200; linear_dev.a[5] = 16132680; linear_dev.a[6] = 65536; - // DKS -// linear_dev.swap_xy = 0; - - //DKS - new sanity checks for pointercal file having good values to fix segfault on empty /etc/pointercal -// if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; -// if (stat(calfile, &sbuf) == 0) { -// pcal_fd = open(calfile, O_RDONLY); -// read(pcal_fd, pcalbuf, 200); -// linear_dev.a[0] = atoi(strtok(pcalbuf, " ")); -// index = 1; -// while (index < 7) { -// tokptr = strtok(NULL, " "); -// if (*tokptr != '\0') { -// linear_dev.a[index] = atoi(tokptr); -// index++; -// } -// } -// close(pcal_fd); -// } - TSLIB_LINEAR tmp_linear_dev; memset(pcalbuf, 0, 200); int got_good_values = 1; // only when this remains 1 throughout reading of /etc/pointercal will values be accepted into driver @@ -1226,56 +536,12 @@ fprintf(stderr, "Error loading saved touchscreen calibration, using default values\n"); } } - // DKS -// if (tslib_parse_vars(linear_vars, NR_LINEAR_VARS, params)) -// ret = -1; - - return ret; } - -//DKS - last known working copy, before conversion to multi-sample -//int linear_read(TSDEV *ts, TS_SAMPLE *samp) -//{ -// int ret; -// int xtemp, ytemp; -// -// //DKS - experimenting with my own filter -//// ret = dejitter_read(ts, samp); -// ret = average_read(ts, samp); -// //DKS - why not try averaging after linear instead of before? -//// ret = variance_read(ts, samp); -// if (ret >= 0) { -// xtemp = samp->x; -// ytemp = samp->y; -// if (linear_dev.a[6] == 65536) { -// samp->x = (linear_dev.a[2] + -// linear_dev.a[0] * xtemp) >> 16; -// samp->y = (linear_dev.a[5] + -// linear_dev.a[4] * ytemp) >> 16; -// } else { -// samp->x = (linear_dev.a[2] + -// linear_dev.a[0] * xtemp) / linear_dev.a[6]; -// samp->y = (linear_dev.a[5] + -// linear_dev.a[4] * ytemp) / linear_dev.a[6]; -// } -// -// //DKS - why was this enabled? I hope this isn't related to the MK2 F200's swapping problem -// -//// if (linear_dev.swap_xy) { -//// int tmp = samp->x; -//// samp->x = samp->y; -//// samp->y = tmp; -//// } -// } -// -// return ret; -//} static inline int linear_read(TSDEV *ts, TS_SAMPLE *samp, int nr) { int ret; -//// ret = dejitter_read(ts, samp); ret = average_read(ts, samp, nr); if (ret > 0) { @@ -1301,150 +567,14 @@ int ts_read(TSDEV *ts, TS_SAMPLE *samp, int nr) { - // DKS - original line: -// ret = linear_read(ts, samp); return(linear_read(ts, samp, nr)); } -/* - * ts_config - */ - -#define BUF_SIZE 512 -static const char *DEFAULT_TSLIB_CONF[] = { - "module pthres pmin=1", - "module variance delta=30", - // //DKS -// "module dejitter delta=100", - "module linear", - NULL -}; -const char *sep = " \t"; - -char *ts_fgets(char *buf, int size, FILE *f, int line) -{ - char *ret; - - if (f) - ret = fgets(buf, size, f); - else { - if (DEFAULT_TSLIB_CONF[line] == NULL) - ret = NULL; - else - ret = strcpy(buf, DEFAULT_TSLIB_CONF[line]); - } - - return ret; -} - - int ts_config(TSDEV *ts) { - char buf[BUF_SIZE], *p; - FILE *f; - int line = 0; - int ret = 0; - - char *conffile; - - if ((conffile = getenv("TSLIB_CONFFILE")) == NULL) { - conffile = "/etc/ts.conf"; - } - - f = fopen(conffile, "r"); - - buf[BUF_SIZE - 2] = '\0'; - while ((p = ts_fgets(buf, BUF_SIZE, f, line)) != NULL) { - char *e; - char *tok; - char *module_name; - - line++; - e = strchr(p, '\n'); - if (e) - *e = '\0'; - - if (buf[BUF_SIZE - 2] != '\0') { - fprintf(stderr, "%s: line %d too long\n", conffile, line); - break; - } - - tok = strsep(&p, sep); - if (p == NULL || *tok == '#') - continue; - - if (strcasecmp(tok, "module") == 0) { - module_name = strsep(&p, sep); - ret = ts_load_module(ts, module_name, p); - } else if (strcasecmp(tok, "module_raw") == 0) { - module_name = strsep(&p, sep); - ret = 0; /* ignore */ - } else { - fprintf(stderr, "%s: Unrecognised option %s at line %d\n", - conffile, tok, line); - break; - } - if (ret != 0) { - fprintf(stderr, "Couldn't load module %s\n", module_name); - break; - } - } - - if (f) fclose(f); - - return ret; + linear_init(); // read in touchscreen calibration file for proper interpretation of samples + variance_init(); // initialize variance module + return 0; } - -int ts_load_module(TSDEV *ts, const char *module, const char *p) -{ - int ret; - - -// if (!strcmp(module, "pthres")) -//DKS - disabled this, no initialization needed -// ret = pthres_init(p); - if (!strcmp(module, "variance")) - ret = variance_init(p); -// else if (!strcmp(module, "dejitter")) -// DKS - dejitter module disabled -// ret = dejitter_init(p); - else if (!strcmp(module, "linear")) - ret = linear_init(p); - else - ret = 0; - - return ret; -} - -char s_holder[1024]; - -int tslib_parse_vars(const TSLIB_VARS *vars, int nr, const char *str) -{ - char *s, *p; - int ret = 0; - - if (!str) - return 0; - - bzero(s_holder, 1024); - strncpy(s_holder, str, strlen(str)); - s = s_holder; - while ((p = strsep(&s, sep)) != NULL && ret == 0) { - const TSLIB_VARS *v; - char *eq; - - eq = strchr(p, '='); - if (eq) - *eq++ = '\0'; - - for (v = vars; v < vars + nr; v++) - if (strcasecmp(v->name, p) == 0) { - ret = v->fn(eq, v->data); - break; - } - } - - return ret; -} Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h 2008-12-24 16:44:53 UTC (rev 348) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h 2009-01-01 09:47:13 UTC (rev 349) @@ -38,7 +38,9 @@ #define TSAPI TSIMPORT #endif // TSLIB_INTERNAL -struct tsdev; +typedef struct tsdev { + int fd; +} TSDEV; struct ts_sample { int x; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-24 16:44:56
|
Revision: 348 http://open2x.svn.sourceforge.net/open2x/?rev=348&view=rev Author: senquack Date: 2008-12-24 16:44:53 +0000 (Wed, 24 Dec 2008) Log Message: ----------- Added new volume-scaler icons to GMenu2X and one missing icon Added Paths: ----------- trunk/utils/gmenu2x/skins/Default/imgs/go-up.png trunk/utils/gmenu2x/skins/Default/imgs/mute.png trunk/utils/gmenu2x/skins/Default/imgs/phones.png Added: trunk/utils/gmenu2x/skins/Default/imgs/go-up.png =================================================================== (Binary files differ) Property changes on: trunk/utils/gmenu2x/skins/Default/imgs/go-up.png ___________________________________________________________________ Added: svn:executable + * Added: svn:mime-type + application/octet-stream Added: trunk/utils/gmenu2x/skins/Default/imgs/mute.png =================================================================== (Binary files differ) Property changes on: trunk/utils/gmenu2x/skins/Default/imgs/mute.png ___________________________________________________________________ Added: svn:executable + * Added: svn:mime-type + application/octet-stream Added: trunk/utils/gmenu2x/skins/Default/imgs/phones.png =================================================================== (Binary files differ) Property changes on: trunk/utils/gmenu2x/skins/Default/imgs/phones.png ___________________________________________________________________ Added: svn:executable + * Added: svn:mime-type + application/octet-stream This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-24 16:40:15
|
Revision: 347 http://open2x.svn.sourceforge.net/open2x/?rev=347&view=rev Author: senquack Date: 2008-12-24 16:40:09 +0000 (Wed, 24 Dec 2008) Log Message: ----------- Removed bad selection.png file, not needed. Removed Paths: ------------- trunk/utils/gmenu2x/skins/open2x/imgs/selection.png Deleted: trunk/utils/gmenu2x/skins/open2x/imgs/selection.png =================================================================== (Binary files differ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-24 16:34:22
|
Revision: 346 http://open2x.svn.sourceforge.net/open2x/?rev=346&view=rev Author: senquack Date: 2008-12-24 16:34:17 +0000 (Wed, 24 Dec 2008) Log Message: ----------- Brought GMenu2X completely up to date, now own private branch Modified Paths: -------------- trunk/utils/gmenu2x/source/button.cpp trunk/utils/gmenu2x/source/button.h trunk/utils/gmenu2x/source/dirdialog.cpp trunk/utils/gmenu2x/source/filedialog.cpp trunk/utils/gmenu2x/source/filedialog.h trunk/utils/gmenu2x/source/filelister.cpp trunk/utils/gmenu2x/source/filelister.h trunk/utils/gmenu2x/source/font.xcf trunk/utils/gmenu2x/source/gmenu2x.cpp trunk/utils/gmenu2x/source/gmenu2x.h trunk/utils/gmenu2x/source/gp2x.h trunk/utils/gmenu2x/source/iconbutton.cpp trunk/utils/gmenu2x/source/iconbutton.h trunk/utils/gmenu2x/source/imagedialog.cpp trunk/utils/gmenu2x/source/inputdialog.cpp trunk/utils/gmenu2x/source/inputdialog.h trunk/utils/gmenu2x/source/link.cpp trunk/utils/gmenu2x/source/linkapp.cpp trunk/utils/gmenu2x/source/menu.cpp trunk/utils/gmenu2x/source/menusetting.cpp trunk/utils/gmenu2x/source/menusetting.h trunk/utils/gmenu2x/source/menusettingbool.cpp trunk/utils/gmenu2x/source/menusettingbool.h trunk/utils/gmenu2x/source/menusettingdir.cpp trunk/utils/gmenu2x/source/menusettingdir.h trunk/utils/gmenu2x/source/menusettingfile.cpp trunk/utils/gmenu2x/source/menusettingfile.h trunk/utils/gmenu2x/source/menusettingimage.cpp trunk/utils/gmenu2x/source/menusettingint.cpp trunk/utils/gmenu2x/source/menusettingint.h trunk/utils/gmenu2x/source/menusettingmultistring.cpp trunk/utils/gmenu2x/source/menusettingmultistring.h trunk/utils/gmenu2x/source/menusettingrgba.cpp trunk/utils/gmenu2x/source/menusettingrgba.h trunk/utils/gmenu2x/source/menusettingstring.cpp trunk/utils/gmenu2x/source/menusettingstring.h trunk/utils/gmenu2x/source/messagebox.cpp trunk/utils/gmenu2x/source/selector.cpp trunk/utils/gmenu2x/source/settingsdialog.cpp trunk/utils/gmenu2x/source/settingsdialog.h trunk/utils/gmenu2x/source/sfontplus.h trunk/utils/gmenu2x/source/surface.cpp trunk/utils/gmenu2x/source/surface.h trunk/utils/gmenu2x/source/surfacecollection.cpp trunk/utils/gmenu2x/source/textdialog.cpp trunk/utils/gmenu2x/source/textmanualdialog.cpp trunk/utils/gmenu2x/source/touchscreen.cpp trunk/utils/gmenu2x/source/touchscreen.h trunk/utils/gmenu2x/source/wallpaperdialog.cpp Added Paths: ----------- trunk/utils/gmenu2x/source/inputmanager.cpp trunk/utils/gmenu2x/source/inputmanager.h trunk/utils/gmenu2x/source/listview.cpp trunk/utils/gmenu2x/source/listview.h trunk/utils/gmenu2x/source/listviewitem.cpp trunk/utils/gmenu2x/source/listviewitem.h trunk/utils/gmenu2x/source/lr.xcf Removed Paths: ------------- trunk/utils/gmenu2x/source/joystick.cpp trunk/utils/gmenu2x/source/joystick.h Modified: trunk/utils/gmenu2x/source/button.cpp =================================================================== --- trunk/utils/gmenu2x/source/button.cpp 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/button.cpp 2008-12-24 16:34:17 UTC (rev 346) @@ -1,14 +1,18 @@ #include "button.h" +#include "gmenu2x.h" using namespace std; using namespace fastdelegate; -Button::Button(GMenu2X * gmenu2x) { +Button::Button(GMenu2X * gmenu2x, bool doubleClick) { this->gmenu2x = gmenu2x; + this->doubleClick = doubleClick; + lastTick = 0; action = MakeDelegate(this, &Button::voidAction); - setPosition(0,0); - setSize(0,0); - pressed = false; + rect.x = 0; + rect.y = 0; + rect.w = 0; + rect.h = 0; } void Button::paint() { @@ -20,27 +24,38 @@ return false; } +bool Button::isPressed() { + return gmenu2x->ts.pressed() && gmenu2x->ts.inRect(rect); +} + +bool Button::isReleased() { + return gmenu2x->ts.released() && gmenu2x->ts.inRect(rect); +} + bool Button::handleTS() { - if (!gmenu2x->ts.pressed()) { - if (pressed) { + if (isReleased()) { + if (doubleClick) { + int tickNow = SDL_GetTicks(); + if (tickNow - lastTick < 400) + exec(); + lastTick = tickNow; + } else { exec(); - return true; } - pressed = false; - return false; - } else if (gmenu2x->ts.inRect(rect)) { - pressed = true; - return false; - } else { - pressed = false; - return false; + return true; } + return false; } void Button::exec() { + gmenu2x->ts.setHandled(); action(); } +SDL_Rect Button::getRect() { + return rect; +} + void Button::setSize(int w, int h) { rect.w = w; rect.h = h; Modified: trunk/utils/gmenu2x/source/button.h =================================================================== --- trunk/utils/gmenu2x/source/button.h 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/button.h 2008-12-24 16:34:17 UTC (rev 346) @@ -22,32 +22,37 @@ #define BUTTON_H_ #include <string> -#include "gmenu2x.h" +#include <SDL.h> #include "FastDelegate.h" using std::string; using fastdelegate::FastDelegate0; typedef FastDelegate0<> ButtonAction; +class GMenu2X; class Button { protected: GMenu2X *gmenu2x; ButtonAction action; SDL_Rect rect; - bool pressed; + bool doubleClick; + int lastTick; public: string path; - Button(GMenu2X *gmenu2x); + Button(GMenu2X *gmenu2x, bool doubleClick = false); virtual ~Button() {}; + SDL_Rect getRect(); void setSize(int w, int h); void setPosition(int x, int y); virtual void paint(); virtual bool paintHover(); + bool isPressed(); + bool isReleased(); bool handleTS(); void exec(); void voidAction() {}; Modified: trunk/utils/gmenu2x/source/dirdialog.cpp =================================================================== --- trunk/utils/gmenu2x/source/dirdialog.cpp 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/dirdialog.cpp 2008-12-24 16:34:17 UTC (rev 346) @@ -26,9 +26,6 @@ #include <sys/types.h> #include <dirent.h> -#ifdef TARGET_GP2X -#include "gp2x.h" -#endif #include "dirdialog.h" #include "filelister.h" @@ -84,36 +81,35 @@ gmenu2x->s->flip(); -#ifdef TARGET_GP2X gmenu2x->joy.update(); - if ( gmenu2x->joy[GP2X_BUTTON_SELECT] ) { close = true; result = false; } - if ( gmenu2x->joy[GP2X_BUTTON_UP ] ) { + if ( gmenu2x->joy[ACTION_SELECT] ) { close = true; result = false; } + if ( gmenu2x->joy[ACTION_UP ] ) { if (selected==0) selected = fl.size()-1; else selected -= 1; } - if ( gmenu2x->joy[GP2X_BUTTON_L ] ) { + if ( gmenu2x->joy[ACTION_L ] ) { if ((int)(selected-9)<0) { selected = 0; } else { selected -= 9; } } - if ( gmenu2x->joy[GP2X_BUTTON_DOWN ] ) { + if ( gmenu2x->joy[ACTION_DOWN ] ) { if (selected+1>=fl.size()) selected = 0; else selected += 1; } - if ( gmenu2x->joy[GP2X_BUTTON_R ] ) { + if ( gmenu2x->joy[ACTION_R ] ) { if (selected+9>=fl.size()) { selected = fl.size()-1; } else { selected += 9; } } - if ( gmenu2x->joy[GP2X_BUTTON_X] || gmenu2x->joy[GP2X_BUTTON_LEFT] ) { + if ( gmenu2x->joy[ACTION_X] || gmenu2x->joy[ACTION_LEFT] ) { string::size_type p = path.rfind("/"); if (p==string::npos || path.substr(0,4)!="/mnt" || p<4) return false; @@ -122,47 +118,12 @@ selected = 0; fl.setPath(path); } - if ( (gmenu2x->joy[GP2X_BUTTON_B] || gmenu2x->joy[GP2X_BUTTON_CLICK]) && selected<fl.size() ) { + if ( gmenu2x->joy[ACTION_B] && selected<fl.size() ) { path += "/"+fl[selected]; selected = 0; fl.setPath(path); } - if ( gmenu2x->joy[GP2X_BUTTON_START] ) close = true; -#else - while (SDL_PollEvent(&gmenu2x->event)) { - if ( gmenu2x->event.type == SDL_QUIT ) { close = true; result = false; } - if ( gmenu2x->event.type==SDL_KEYDOWN ) { - if ( gmenu2x->event.key.keysym.sym==SDLK_ESCAPE ) { close = true; result = false; } - if ( gmenu2x->event.key.keysym.sym==SDLK_UP ) { - if (selected==0) { - selected = fl.size()-1; - } else - selected -= 1; - } - if ( gmenu2x->event.key.keysym.sym==SDLK_DOWN ) { - if (selected+1>=fl.size()) - selected = 0; - else - selected += 1; - } - if ( gmenu2x->event.key.keysym.sym==SDLK_BACKSPACE ) { - string::size_type p = path.rfind("/"); - if (p==string::npos || path.substr(0,4)!="/mnt" || p<4) - return false; - else - path = path.substr(0,p); - selected = 0; - fl.setPath(path); - } - if ( gmenu2x->event.key.keysym.sym==SDLK_RETURN && selected<fl.size()) { - path += "/"+fl[selected]; - selected = 0; - fl.setPath(path); - } - if ( gmenu2x->event.key.keysym.sym==SDLK_s ) close = true; - } - } -#endif + if ( gmenu2x->joy[ACTION_START] ) close = true; } return result; Modified: trunk/utils/gmenu2x/source/filedialog.cpp =================================================================== --- trunk/utils/gmenu2x/source/filedialog.cpp 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/filedialog.cpp 2008-12-24 16:34:17 UTC (rev 346) @@ -26,9 +26,6 @@ #include <sys/types.h> #include <dirent.h> -#ifdef TARGET_GP2X -#include "gp2x.h" -#endif #include "filedialog.h" using namespace std; @@ -51,16 +48,19 @@ } bool FileDialog::exec() { - bool close = false, result = true; + bool close = false, result = true, ts_pressed = false; if (!fileExists(path())) setPath("/mnt"); fl.setFilter(filter); fl.browse(); - uint i, firstElement = 0, iY; + uint i, firstElement = 0, iY, action; selected = 0; while (!close) { + action = FD_NO_ACTION; + if (gmenu2x->f200) gmenu2x->ts.poll(); + gmenu2x->bg->blit(gmenu2x->s,0,0); gmenu2x->drawTitleIcon("icons/explorer.png",true); gmenu2x->writeTitle(title); @@ -81,103 +81,91 @@ //Files & Directories gmenu2x->s->setClipRect(0,41,311,179); + if (ts_pressed && !gmenu2x->ts.pressed()) { + action = FD_ACTION_SELECT; + ts_pressed = false; + } + if (gmenu2x->f200 && gmenu2x->ts.pressed() && !gmenu2x->ts.inRect(2,44,308,179)) ts_pressed = false; for (i=firstElement; i<fl.size() && i<firstElement+10; i++) { iY = i-firstElement; - if (fl.isDirectory(i)) - gmenu2x->sc.skinRes("imgs/folder.png")->blit(gmenu2x->s, 5, 45+(iY*17)); - else + if (fl.isDirectory(i)) { + if (fl[i]=="..") + gmenu2x->sc.skinRes("imgs/go-up.png")->blit(gmenu2x->s, 5, 45+(iY*17)); + else + gmenu2x->sc.skinRes("imgs/folder.png")->blit(gmenu2x->s, 5, 45+(iY*17)); + } else { gmenu2x->sc.skinRes("imgs/file.png")->blit(gmenu2x->s, 5, 45+(iY*17)); + } gmenu2x->s->write(gmenu2x->font, fl[i], 24, 52+(iY*17), SFontHAlignLeft, SFontVAlignMiddle); + if (gmenu2x->f200 && gmenu2x->ts.pressed() && gmenu2x->ts.inRect(2, 44+(iY*17), 308, 16)) { + ts_pressed = true; + selected = i; + } } gmenu2x->s->clearClipRect(); gmenu2x->drawScrollBar(10,fl.size(),firstElement,44,170); gmenu2x->s->flip(); - -#ifdef TARGET_GP2X gmenu2x->joy.update(); - if ( gmenu2x->joy[GP2X_BUTTON_SELECT] ) { close = true; result = false; } - if ( gmenu2x->joy[GP2X_BUTTON_UP ] ) { - if (selected==0) - selected = fl.size()-1; - else - selected -= 1; - } - if ( gmenu2x->joy[GP2X_BUTTON_L ] ) { - if ((int)(selected-9)<0) { - selected = 0; - } else { - selected -= 9; - } - } - if ( gmenu2x->joy[GP2X_BUTTON_DOWN ] ) { - if (selected+1>=fl.size()) - selected = 0; - else - selected += 1; - } - if ( gmenu2x->joy[GP2X_BUTTON_R ] ) { - if (selected+9>=fl.size()) { - selected = fl.size()-1; - } else { - selected += 9; - } - } - if ( gmenu2x->joy[GP2X_BUTTON_X] || gmenu2x->joy[GP2X_BUTTON_LEFT] ) { - string::size_type p = path().rfind("/"); - if (p==string::npos || path().substr(0,4)!="/mnt" || p<4) - return false; - else - setPath( path().substr(0,p) ); - } - if ( gmenu2x->joy[GP2X_BUTTON_B] || gmenu2x->joy[GP2X_BUTTON_CLICK] ) { - if (fl.isDirectory(selected)) { - setPath( path()+"/"+fl[selected] ); - } else { - if (fl.isFile(selected)) { - file = fl[selected]; - close = true; + if ( gmenu2x->joy[ACTION_SELECT] ) action = FD_ACTION_CLOSE; + if ( gmenu2x->joy[ACTION_UP ] ) action = FD_ACTION_UP; + if ( gmenu2x->joy[ACTION_L ] ) action = FD_ACTION_SCROLLUP; + if ( gmenu2x->joy[ACTION_DOWN ] ) action = FD_ACTION_DOWN; + if ( gmenu2x->joy[ACTION_R ] ) action = FD_ACTION_SCROLLDOWN; + if ( gmenu2x->joy[ACTION_X] || gmenu2x->joy[ACTION_LEFT] ) action = FD_ACTION_GOUP; + if ( gmenu2x->joy[ACTION_B ] ) action = FD_ACTION_SELECT; + + if (action == FD_ACTION_SELECT && fl[selected]=="..") action = FD_ACTION_GOUP; + switch (action) { + case FD_ACTION_CLOSE: { + close = true; + result = false; + } break; + case FD_ACTION_UP: { + if (selected==0) + selected = fl.size()-1; + else + selected -= 1; + } break; + case FD_ACTION_SCROLLUP: { + if ((int)(selected-9)<0) { + selected = 0; + } else { + selected -= 9; } - } - } -#else - while (SDL_PollEvent(&gmenu2x->event)) { - if ( gmenu2x->event.type == SDL_QUIT ) { close = true; result = false; } - if ( gmenu2x->event.type==SDL_KEYDOWN ) { - if ( gmenu2x->event.key.keysym.sym==SDLK_ESCAPE ) { close = true; result = false; } - if ( gmenu2x->event.key.keysym.sym==SDLK_UP ) { - if (selected==0) { - selected = fl.size()-1; - } else - selected -= 1; + } break; + case FD_ACTION_DOWN: { + if (selected+1>=fl.size()) + selected = 0; + else + selected += 1; + } break; + case FD_ACTION_SCROLLDOWN: { + if (selected+9>=fl.size()) { + selected = fl.size()-1; + } else { + selected += 9; } - if ( gmenu2x->event.key.keysym.sym==SDLK_DOWN ) { - if (selected+1>=fl.size()) - selected = 0; - else - selected += 1; - } - if ( gmenu2x->event.key.keysym.sym==SDLK_BACKSPACE ) { - string::size_type p = path().rfind("/"); - if (p==string::npos || path().substr(0,4)!="/mnt" || p<4) - return false; - else - setPath( path().substr(0,p) ); - } - if ( gmenu2x->event.key.keysym.sym==SDLK_RETURN ) { - if (fl.isDirectory(selected)) { - setPath( path()+"/"+fl[selected] ); - } else { - if (fl.isFile(selected)) { - file = fl[selected]; - close = true; - } + } break; + case FD_ACTION_GOUP: { + string::size_type p = path().rfind("/"); + if (p==string::npos || path().substr(0,4)!="/mnt" || p<4) + return false; + else + setPath( path().substr(0,p) ); + } break; + case FD_ACTION_SELECT: { + if (fl.isDirectory(selected)) { + setPath( path()+"/"+fl[selected] ); + } else { + if (fl.isFile(selected)) { + file = fl[selected]; + close = true; } } - } + } break; } -#endif } return result; Modified: trunk/utils/gmenu2x/source/filedialog.h =================================================================== --- trunk/utils/gmenu2x/source/filedialog.h 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/filedialog.h 2008-12-24 16:34:17 UTC (rev 346) @@ -25,6 +25,17 @@ #include "filelister.h" #include "gmenu2x.h" +#define FD_NO_ACTION 0 +#define FD_ACTION_CLOSE 1 +#define FD_ACTION_UP 2 +#define FD_ACTION_DOWN 3 +#define FD_ACTION_LEFT 4 +#define FD_ACTION_RIGHT 5 +#define FD_ACTION_SCROLLDOWN 6 +#define FD_ACTION_SCROLLUP 7 +#define FD_ACTION_GOUP 8 +#define FD_ACTION_SELECT 9 + using std::string; using std::vector; Modified: trunk/utils/gmenu2x/source/filelister.cpp =================================================================== --- trunk/utils/gmenu2x/source/filelister.cpp 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/filelister.cpp 2008-12-24 16:34:17 UTC (rev 346) @@ -73,7 +73,7 @@ while ((dptr = readdir(dirp))) { file = dptr->d_name; - if (file[0]=='.') continue; + if (file[0]=='.' && file!="..") continue; filepath = path+file; int statRet = stat(filepath.c_str(), &st); if (statRet == -1) { @@ -81,6 +81,9 @@ continue; } + if (find(exclude.begin(), exclude.end(), file) != exclude.end()) + continue; + if (S_ISDIR(st.st_mode)) { if (!showDirectories) continue; #ifdef TARGET_GP2X Modified: trunk/utils/gmenu2x/source/filelister.h =================================================================== --- trunk/utils/gmenu2x/source/filelister.h 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/filelister.h 2008-12-24 16:34:17 UTC (rev 346) @@ -36,7 +36,7 @@ FileLister(string startPath = "/mnt/sd", bool showDirectories = true, bool showFiles = true); void browse(); - vector<string> directories, files; + vector<string> directories, files, exclude; uint size(); uint dirCount(); uint fileCount(); Modified: trunk/utils/gmenu2x/source/font.xcf =================================================================== (Binary files differ) Modified: trunk/utils/gmenu2x/source/gmenu2x.cpp =================================================================== --- trunk/utils/gmenu2x/source/gmenu2x.cpp 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/gmenu2x.cpp 2008-12-24 16:34:17 UTC (rev 346) @@ -28,16 +28,11 @@ #include <SDL_gfxPrimitives.h> #include <signal.h> -//for statfs -#include <sys/vfs.h> +#include <sys/statvfs.h> #include <errno.h> #include "gp2x.h" -#ifdef TARGET_GP2X -//#include <SDL_gp2x.h> -#include <SDL_joystick.h> #include <sys/fcntl.h> //for battery -#endif //for browsing the filesystem #include <sys/stat.h> @@ -75,6 +70,7 @@ #include <sys/mman.h> + using namespace std; using namespace fastdelegate; @@ -94,49 +90,50 @@ gp2x_memregs=(unsigned short *)mmap(0, 0x10000, PROT_READ|PROT_WRITE, MAP_SHARED, gp2x_mem, 0xc0000000); MEM_REG=&gp2x_memregs[0]; - if (f200) + batteryHandle = open(f200 ? "/dev/mmsp2adc" : "/dev/batt", O_RDONLY); + if (f200) { //if wm97xx fails to open, set f200 to false to prevent any further access to the touchscreen f200 = ts.init(); + } #endif } void GMenu2X::gp2x_deinit() { #ifdef TARGET_GP2X - gp2x_memregs[0x28DA>>1]=0x4AB; - gp2x_memregs[0x290C>>1]=640; - close(gp2x_mem); + if (gp2x_mem!=0) { + gp2x_memregs[0x28DA>>1]=0x4AB; + gp2x_memregs[0x290C>>1]=640; + close(gp2x_mem); + } + if (batteryHandle!=0) close(batteryHandle); if (f200) ts.deinit(); #endif } void GMenu2X::gp2x_tvout_on(bool pal) { #ifdef TARGET_GP2X - if (cx25874!=0) gp2x_tvout_off(); - //if tv-out is enabled without cx25874 open, stop - //if (gp2x_memregs[0x2800>>1]&0x100) return; - cx25874 = open("/dev/cx25874",O_RDWR); - ioctl(cx25874, _IOW('v', 0x02, unsigned char), pal ? 4 : 3); - gp2x_memregs[0x2906>>1]=512; - gp2x_memregs[0x28E4>>1]=gp2x_memregs[0x290C>>1]; - gp2x_memregs[0x28E8>>1]=239; - -#ifdef DEBUG - for (uint window=0; window<4; window++) { - int x1=gp2x_memregs[(0x28e2+window*8)>>1]; - int x2=gp2x_memregs[(0x28e4+window*8)>>1]; - int y1=gp2x_memregs[(0x28e6+window*8)>>1]; - int y2=gp2x_memregs[(0x28e8+window*8)>>1]; - printf ("Window %i: %i,%i,%i,%i\n",window,x1,x2,y1,y2); + if (gp2x_mem!=0) { + /*Ioctl_Dummy_t *msg; + int TVHandle = ioctl(SDL_videofd, FBMMSP2CTRL, msg);*/ + if (cx25874!=0) gp2x_tvout_off(); + //if tv-out is enabled without cx25874 open, stop + //if (gp2x_memregs[0x2800>>1]&0x100) return; + cx25874 = open("/dev/cx25874",O_RDWR); + ioctl(cx25874, _IOW('v', 0x02, unsigned char), pal ? 4 : 3); + gp2x_memregs[0x2906>>1]=512; + gp2x_memregs[0x28E4>>1]=gp2x_memregs[0x290C>>1]; + gp2x_memregs[0x28E8>>1]=239; } #endif -#endif } void GMenu2X::gp2x_tvout_off() { #ifdef TARGET_GP2X - close(cx25874); - cx25874 = 0; - gp2x_memregs[0x2906>>1]=1024; + if (gp2x_mem!=0) { + close(cx25874); + cx25874 = 0; + gp2x_memregs[0x2906>>1]=1024; + } #endif } @@ -183,18 +180,26 @@ saveSelection = true; outputLogs = false; maxClock = 300; - menuClock = 100; - globalVolume = 100; + menuClock = f200 ? 136 : 100; + //senquack - I don't understand why gmenu2x's default mixer level is 100, since + //the truth is the GP2X's default is 67 and the only reason I think noone complained + //was because gmenu2x never set the mixer value unless you changed it from the default + //100. I could be wrong.. but a lot of people would have complained if it really had + //been getting set to 100 like this implies: + globalVolume = fwType == "open2x" ? 67 : 100; numRows = 4; numCols = 5; tvoutEncoding = "NTSC"; wallpaper = ""; skinWallpaper = ""; - //G - gamma = 10; - startSectionIndex = 0; - startLinkIndex = 0; + //open2x + savedVolumeMode = 0; + volumeMode = VOLUME_MODE_NORMAL; + //senquack - bugfix here, this was incorrectly being set to VOLUME_MODE_NORMAL: + volumeScalerNormal = VOLUME_SCALER_NORMAL; + volumeScalerPhones = VOLUME_SCALER_PHONES; + o2x_usb_net_on_boot = false; o2x_usb_net_ip = ""; o2x_ftp_on_boot = false; @@ -204,33 +209,49 @@ o2x_usb_hid_on_boot = false; o2x_usb_storage_on_boot = false; + //G + gamma = 10; + startSectionIndex = 0; + startLinkIndex = 0; + usbnet = samba = inet = web = false; useSelectionPng = false; //load config data readConfig(); - if(fwType == "open2x") { + if (fwType=="open2x") { readConfigOpen2x(); - } - readCommonIni(); + // VOLUME MODIFIER + switch(volumeMode) { + case VOLUME_MODE_MUTE: setVolumeScaler(VOLUME_SCALER_MUTE); break; + case VOLUME_MODE_PHONES: setVolumeScaler(volumeScalerPhones); break; + case VOLUME_MODE_NORMAL: setVolumeScaler(volumeScalerNormal); break; + } + } else + readCommonIni(); + path = ""; getExePath(); #ifdef TARGET_GP2X gp2x_mem = 0; cx25874 = 0; + batteryHandle = 0; gp2x_init(); //Fix tv-out - if (gp2x_memregs[0x2800>>1]&0x100) { - gp2x_memregs[0x2906>>1]=512; - //gp2x_memregs[0x290C>>1]=640; - gp2x_memregs[0x28E4>>1]=gp2x_memregs[0x290C>>1]; + if (gp2x_mem!=0) { + if (gp2x_memregs[0x2800>>1]&0x100) { + gp2x_memregs[0x2906>>1]=512; + //gp2x_memregs[0x290C>>1]=640; + gp2x_memregs[0x28E4>>1]=gp2x_memregs[0x290C>>1]; + } + gp2x_memregs[0x28E8>>1]=239; } - gp2x_memregs[0x28E8>>1]=239; #endif + //Screen if( SDL_Init(SDL_INIT_VIDEO|SDL_INIT_AUDIO|SDL_INIT_JOYSTICK)<0 ) { cout << "\033[0;34mGMENU2X:\033[0;31m Could not initialize SDL:\033[0m " << SDL_GetError() << endl; @@ -238,12 +259,18 @@ } s = new Surface(); - SDL_JoystickOpen(0); - //s->raw = SDL_SetVideoMode(320, 240, 16, SDL_HWSURFACE|SDL_DOUBLEBUF); - s->raw = SDL_SetVideoMode(320, 240, 16, SDL_SWSURFACE); #ifdef TARGET_GP2X - SDL_ShowCursor(0); + { + //I use a tmp variable to hide the cursor as soon as possible (and create the double buffer surface only after that) + //I'm forced to use SW surfaces since with HW there are issuse with changing the clock frequency + SDL_Surface *tmps = SDL_SetVideoMode(320, 240, 16, SDL_SWSURFACE); + SDL_ShowCursor(0); + s->enableVirtualDoubleBuffer(tmps); + } +#else + s->raw = SDL_SetVideoMode(320, 240, 16, SDL_HWSURFACE|SDL_DOUBLEBUF); #endif + bg = NULL; font = NULL; initMenu(); @@ -252,7 +279,7 @@ if (!fileExists(wallpaper)) { #ifdef DEBUG - cout << "Searching wallpaper" << endl; + cout << "Searching wallpaper" << endl; #endif FileLister fl("skins/"+skin+"/wallpapers",false,true); fl.setFilter(".png,.jpg,.jpeg,.bmp"); @@ -262,15 +289,12 @@ if (fl.files.size()>0) wallpaper = fl.getPath()+fl.files[0]; } + initBG(); - - //Events -#ifdef TARGET_GP2X - joy.init(0); -#endif + joy.init(path+"input.conf"); setInputSpeed(); + initServices(); - initServices(); //G setGamma(gamma); setVolume(globalVolume); @@ -288,6 +312,7 @@ recalcLinkGrid = true; main(); writeConfig(); + if (fwType=="open2x") writeConfigOpen2x(); quit(); exit(0); @@ -300,6 +325,8 @@ } void GMenu2X::quit() { + sc.clear(); + s->free(); SDL_Quit(); #ifdef TARGET_GP2X if (gp2x_mem!=0) { @@ -395,14 +422,14 @@ //Add virtual links in the setting section else if (menu->sections[i]=="settings") { menu->addActionLink(i,"GMenu2X",MakeDelegate(this,&GMenu2X::options),tr["Configure GMenu2X's options"],"skin:icons/configure.png"); - if(fwType == "open2x")menu->addActionLink(i,"Open2x",MakeDelegate(this,&GMenu2X::settingsOpen2x),tr["Configure Open2x system settings"],"skin:icons/o2xconfigure.png"); + if (fwType=="open2x") + menu->addActionLink(i,"Open2x",MakeDelegate(this,&GMenu2X::settingsOpen2x),tr["Configure Open2x system settings"],"skin:icons/o2xconfigure.png"); menu->addActionLink(i,tr["Skin"],MakeDelegate(this,&GMenu2X::skinMenu),tr["Configure skin"],"skin:icons/skin.png"); menu->addActionLink(i,tr["Wallpaper"],MakeDelegate(this,&GMenu2X::changeWallpaper),tr["Change GMenu2X wallpaper"],"skin:icons/wallpaper.png"); menu->addActionLink(i,"TV",MakeDelegate(this,&GMenu2X::toggleTvOut),tr["Activate/deactivate tv-out"],"skin:icons/tv.png"); menu->addActionLink(i,"USB Sd",MakeDelegate(this,&GMenu2X::activateSdUsb),tr["Activate Usb on SD"],"skin:icons/usb.png"); - if (fwType=="gph") { + if (fwType=="gph" && !f200) menu->addActionLink(i,"USB Nand",MakeDelegate(this,&GMenu2X::activateNandUsb),tr["Activate Usb on Nand"],"skin:icons/usb.png"); - } if (fileExists(path+"log.txt")) menu->addActionLink(i,tr["Log Viewer"],MakeDelegate(this,&GMenu2X::viewLog),tr["Displays last launched program's output"],"skin:icons/ebook.png"); menu->addActionLink(i,tr["About"],MakeDelegate(this,&GMenu2X::about),tr["Info about GMenu2X"],"skin:icons/about.png"); @@ -460,7 +487,7 @@ lorystorm90\n\ and all the anonymous donors...\n\ (If I missed to list you or if you want to be removed, contact me.)","\n"); - TextDialog td(this, "GMenu2X", tr.translate("Version $1 (Build date: $2)","0.9",__DATE__,NULL), "icons/about.png", &text); + TextDialog td(this, "GMenu2X", tr.translate("Version $1 (Build date: $2)","0.10-test3",__DATE__,NULL), "icons/about.png", &text); td.exec(); } @@ -480,9 +507,9 @@ td.exec(); MessageBox mb(this, tr["Do you want to delete the log file?"], "icons/ebook.png"); - mb.buttons[GP2X_BUTTON_B] = tr["Yes"]; - mb.buttons[GP2X_BUTTON_X] = tr["No"]; - if (mb.exec() == GP2X_BUTTON_B) { + mb.buttons[ACTION_B] = tr["Yes"]; + mb.buttons[ACTION_X] = tr["No"]; + if (mb.exec() == ACTION_B) { ledOn(); unlink(logfile.c_str()); sync(); @@ -525,32 +552,6 @@ } } -void GMenu2X::readConfigOpen2x() { - // Read the networking config file - string conffile = "/etc/config/open2x.conf"; - if (fileExists(conffile)) { - ifstream inf(conffile.c_str(), ios_base::in); - if (inf.is_open()) { - string line; - while (getline(inf, line, '\n')) { - string::size_type pos = line.find("="); - string name = trim(line.substr(0,pos)); - string value = trim(line.substr(pos+1,line.length())); - - if (name=="USB_NET_ON_BOOT") o2x_usb_net_on_boot = value == "y" ? true : false; - else if (name=="USB_NET_IP") o2x_usb_net_ip = value; - else if (name=="TELNET_ON_BOOT") o2x_telnet_on_boot = value == "y" ? true : false; - else if (name=="FTP_ON_BOOT") o2x_ftp_on_boot = value == "y" ? true : false; - else if (name=="GP2XJOY_ON_BOOT") o2x_gp2xjoy_on_boot = value == "y" ? true : false; - else if (name=="USB_HOST_ON_BOOT") o2x_usb_host_on_boot = value == "y" ? true : false; - else if (name=="USB_HID_ON_BOOT") o2x_usb_hid_on_boot = value == "y" ? true : false; - else if (name=="USB_STORAGE_ON_BOOT") o2x_usb_storage_on_boot = value == "y" ? true : false; - } - inf.close(); - } - } -} - void GMenu2X::writeConfig() { ledOn(); string conffile = path+"gmenu2x.conf"; @@ -582,24 +583,53 @@ ledOff(); } + +void GMenu2X::readConfigOpen2x() { + string conffile = "/etc/config/open2x.conf"; + if (fileExists(conffile)) { + ifstream inf(conffile.c_str(), ios_base::in); + if (inf.is_open()) { + string line; + while (getline(inf, line, '\n')) { + string::size_type pos = line.find("="); + string name = trim(line.substr(0,pos)); + string value = trim(line.substr(pos+1,line.length())); + + if (name=="USB_NET_ON_BOOT") o2x_usb_net_on_boot = value == "y" ? true : false; + else if (name=="USB_NET_IP") o2x_usb_net_ip = value; + else if (name=="TELNET_ON_BOOT") o2x_telnet_on_boot = value == "y" ? true : false; + else if (name=="FTP_ON_BOOT") o2x_ftp_on_boot = value == "y" ? true : false; + else if (name=="GP2XJOY_ON_BOOT") o2x_gp2xjoy_on_boot = value == "y" ? true : false; + else if (name=="USB_HOST_ON_BOOT") o2x_usb_host_on_boot = value == "y" ? true : false; + else if (name=="USB_HID_ON_BOOT") o2x_usb_hid_on_boot = value == "y" ? true : false; + else if (name=="USB_STORAGE_ON_BOOT") o2x_usb_storage_on_boot = value == "y" ? true : false; + else if (name=="VOLUME_MODE") volumeMode = savedVolumeMode = constrain( atoi(value.c_str()), 0, 2); + else if (name=="PHONES_VALUE") volumeScalerPhones = constrain( atoi(value.c_str()), 0, 100); + else if (name=="NORMAL_VALUE") volumeScalerNormal = constrain( atoi(value.c_str()), 0, 150); + } + inf.close(); + } + } +} void GMenu2X::writeConfigOpen2x() { ledOn(); string conffile = "/etc/config/open2x.conf"; ofstream inf(conffile.c_str()); if (inf.is_open()) { - if (saveSelection) { - startSectionIndex = menu->selSectionIndex(); - startLinkIndex = menu->selLinkIndex(); - } - inf << "USB_NET_ON_BOOT=" << ( o2x_usb_net_on_boot ? "y" : "n" ) << endl; inf << "USB_NET_IP=" << o2x_usb_net_ip << endl; inf << "TELNET_ON_BOOT=" << ( o2x_telnet_on_boot ? "y" : "n" ) << endl; inf << "FTP_ON_BOOT=" << ( o2x_ftp_on_boot ? "y" : "n" ) << endl; inf << "GP2XJOY_ON_BOOT=" << ( o2x_gp2xjoy_on_boot ? "y" : "n" ) << endl; - inf << "USB_HOST_ON_BOOT=" << ( o2x_usb_host_on_boot ? "y" : "n" ) << endl; + //senquack - if user specified they want USB HID or USB storage on boot, they obviously + // meant they also wanted USB host on boot, so be sure it's forced on too +// inf << "USB_HOST_ON_BOOT=" << ( o2x_usb_host_on_boot ? "y" : "n" ) << endl; + inf << "USB_HOST_ON_BOOT=" << ( (o2x_usb_host_on_boot || o2x_usb_hid_on_boot || o2x_usb_storage_on_boot) ? "y" : "n" ) << endl; inf << "USB_HID_ON_BOOT=" << ( o2x_usb_hid_on_boot ? "y" : "n" ) << endl; inf << "USB_STORAGE_ON_BOOT=" << ( o2x_usb_storage_on_boot ? "y" : "n" ) << endl; + inf << "VOLUME_MODE=" << volumeMode << endl; + inf << "PHONES_VALUE=" << volumeScalerPhones << endl; + inf << "NORMAL_VALUE=" << volumeScalerNormal << endl; inf.close(); sync(); } @@ -731,14 +761,14 @@ void GMenu2X::ledOn() { #ifdef TARGET_GP2X - if (!f200) gp2x_memregs[0x106E >> 1] ^= 16; + if (gp2x_mem!=0 && !f200) gp2x_memregs[0x106E >> 1] ^= 16; //SDL_SYS_JoystickGp2xSys(joy.joystick, BATT_LED_ON); #endif } void GMenu2X::ledOff() { #ifdef TARGET_GP2X - if (!f200) gp2x_memregs[0x106E >> 1] ^= 16; + if (gp2x_mem!=0 && !f200) gp2x_memregs[0x106E >> 1] ^= 16; //SDL_SYS_JoystickGp2xSys(joy.joystick, BATT_LED_OFF); #endif } @@ -747,12 +777,13 @@ uint linksPerPage = 0, linkH = 0, linkW = 0; bool quit = false; - int x,y, offset = 0; + int x,y, offset = 0, helpBoxHeight = fwType=="open2x" ? 154 : 139; uint i; long tickBattery = -60000, tickNow; string batteryIcon = "imgs/battery/0.png"; stringstream ss; uint sectionsCoordX = 24; + SDL_Rect re = {0,0,0,0}; #ifdef DEBUG //framerate @@ -761,8 +792,7 @@ #endif IconButton btnContextMenu(this,"skin:imgs/menu.png"); - btnContextMenu.setPosition(301, 222); - btnContextMenu.setSize(16, 16); + btnContextMenu.setPosition(282, 222); btnContextMenu.setAction(MakeDelegate(this, &GMenu2X::contextMenu)); while (!quit) { @@ -826,6 +856,12 @@ drawScrollBar(numRows,menu->sectionLinks()->size()/numCols + ((menu->sectionLinks()->size()%numCols==0) ? 0 : 1),menu->firstDispRow(),43,159); + switch(volumeMode) { + case VOLUME_MODE_MUTE: sc.skinRes("imgs/mute.png")->blit(s,279,222); break; + case VOLUME_MODE_PHONES: sc.skinRes("imgs/phones.png")->blit(s,279,222); break; + default: sc.skinRes("imgs/volume.png")->blit(s,279,222); break; + } + if (menu->selLink()!=NULL) { s->write ( font, menu->selLink()->getDescription(), 160, 221, SFontHAlignCenter, SFontVAlignBottom ); if (menu->selLinkApp()!=NULL) { @@ -839,32 +875,26 @@ if (f200) { btnContextMenu.paint(); - } else { - //check battery status every 60 seconds - if (tickNow-tickBattery >= 60000) { - tickBattery = tickNow; - unsigned short battlevel = getBatteryLevel(); - if (battlevel>5) { - batteryIcon = "imgs/battery/ac.png"; - } else { - ss.clear(); - ss << battlevel; - ss >> batteryIcon; - batteryIcon = "imgs/battery/"+batteryIcon+".png"; - } + } + //check battery status every 60 seconds + if (tickNow-tickBattery >= 60000) { + tickBattery = tickNow; + unsigned short battlevel = getBatteryLevel(); + if (battlevel>5) { + batteryIcon = "imgs/battery/ac.png"; + } else { + ss.clear(); + ss << battlevel; + ss >> batteryIcon; + batteryIcon = "imgs/battery/"+batteryIcon+".png"; } - sc.skinRes(batteryIcon)->blit( s, 301, 222 ); } + sc.skinRes(batteryIcon)->blit( s, 301, 222 ); //On Screen Help -#ifdef TARGET_GP2X - if (joy[GP2X_BUTTON_A]) -#else - if (event.type==SDL_KEYDOWN && event.key.keysym.sym==SDLK_h) -#endif - { + if (joy[ACTION_A]) { s->box(10,50,300,143, messageBoxColor); - s->rectangle( 12,52,296,139, messageBoxBorderColor ); + s->rectangle( 12,52,296,helpBoxHeight, messageBoxBorderColor ); s->write( font, tr["CONTROLS"], 20, 60 ); s->write( font, tr["B, Stick press: Launch link / Confirm action"], 20, 80 ); s->write( font, tr["L, R: Change section"], 20, 95 ); @@ -873,6 +903,7 @@ s->write( font, tr["A+VOLUP, A+VOLDOWN: Change volume"], 20, 140 ); s->write( font, tr["SELECT: Show contextual menu"], 20, 155 ); s->write( font, tr["START: Show options menu"], 20, 170 ); + if (fwType=="open2x") s->write( font, tr["X: Toggle speaker mode"], 20, 185 ); } #ifdef DEBUG @@ -890,64 +921,90 @@ //touchscreen if (f200) { ts.poll(); - if (!btnContextMenu.handleTS()) { - if (ts.pressed() && ts.y<=32) - for (i=menu->firstDispSection(); i<menu->sections.size() && i<menu->firstDispSection()+5; i++) { - sectionsCoordX = 24 + min( 5-menu->sections.size(), 5 ) * 30; - x = (i-menu->firstDispSection())*60+sectionsCoordX; + btnContextMenu.handleTS(); + re.x = 0; re.y = 0; re.h = 32; re.w = 320; + if (ts.pressed() && ts.inRect(re)) { + re.w = 60; + for (i=menu->firstDispSection(); !ts.handled() && i<menu->sections.size() && i<menu->firstDispSection()+5; i++) { + sectionsCoordX = 10 + max(0, min( 5-menu->sections.size(), 5 )) * 30; + re.x = (i-menu->firstDispSection())*60+sectionsCoordX; - if (ts.x>=x && ts.x<x+32) - menu->setSectionIndex(i); + if (ts.inRect(re)) { + menu->setSectionIndex(i); + ts.setHandled(); } + } + } - for (i=menu->firstDispRow()*numCols; i<(menu->firstDispRow()*numCols)+linksPerPage && i<menu->sectionLinks()->size(); i++) - menu->sectionLinks()->at(i)->handleTS(); + i=menu->firstDispRow()*numCols; + while ( i<(menu->firstDispRow()*numCols)+linksPerPage && i<menu->sectionLinks()->size()) { + if (menu->sectionLinks()->at(i)->isPressed()) + menu->setLinkIndex(i); + if (menu->sectionLinks()->at(i)->handleTS()) + i = menu->sectionLinks()->size(); + i++; } } -#ifdef TARGET_GP2X +//#ifdef TARGET_GP2X joy.update(); - if ( (joy[GP2X_BUTTON_B] || joy[GP2X_BUTTON_CLICK]) && menu->selLink()!=NULL ) menu->selLink()->run(); - else if ( joy[GP2X_BUTTON_START] ) options(); - else if ( joy[GP2X_BUTTON_SELECT] ) contextMenu(); + if ( joy[ACTION_B] && menu->selLink()!=NULL ) menu->selLink()->run(); + else if ( joy[ACTION_START] ) options(); + else if ( joy[ACTION_SELECT] ) contextMenu(); + // VOLUME SCALE MODIFIER + else if ( joy[ACTION_X] ) { + volumeMode = constrain(volumeMode-1, -VOLUME_MODE_MUTE-1, VOLUME_MODE_NORMAL); + if(volumeMode < VOLUME_MODE_MUTE) + volumeMode = VOLUME_MODE_NORMAL; + switch(volumeMode) { + case VOLUME_MODE_MUTE: setVolumeScaler(VOLUME_SCALER_MUTE); break; + case VOLUME_MODE_PHONES: setVolumeScaler(volumeScalerPhones); break; + case VOLUME_MODE_NORMAL: setVolumeScaler(volumeScalerNormal); break; + } + //senquack - this really should be set to the global volume, not read from the + //mixer and written back again, since the mixer's reported value is intertwined with + //the current scaling setting +// setVolume(getVolume()); + setVolume(globalVolume); + } // LINK NAVIGATION - else if ( joy[GP2X_BUTTON_LEFT ] ) menu->linkLeft(); - else if ( joy[GP2X_BUTTON_RIGHT] ) menu->linkRight(); - else if ( joy[GP2X_BUTTON_UP ] ) menu->linkUp(); - else if ( joy[GP2X_BUTTON_DOWN ] ) menu->linkDown(); + else if ( joy[ACTION_LEFT ] ) menu->linkLeft(); + else if ( joy[ACTION_RIGHT] ) menu->linkRight(); + else if ( joy[ACTION_UP ] ) menu->linkUp(); + else if ( joy[ACTION_DOWN ] ) menu->linkDown(); // SELLINKAPP SELECTED else if (menu->selLinkApp()!=NULL) { - if ( joy[GP2X_BUTTON_Y] ) menu->selLinkApp()->showManual(); - else if ( joy.isDown(GP2X_BUTTON_A) ) { + if ( joy[ACTION_Y] ) menu->selLinkApp()->showManual(); + else if ( joy.isActive(ACTION_A) ) { // VOLUME - if ( joy[GP2X_BUTTON_VOLDOWN] && !joy.isDown(GP2X_BUTTON_VOLUP) ) + if ( joy[ACTION_VOLDOWN] && !joy.isActive(ACTION_VOLUP) ) menu->selLinkApp()->setVolume( constrain(menu->selLinkApp()->volume()-1,0,100) ); - if ( joy[GP2X_BUTTON_VOLUP] && !joy.isDown(GP2X_BUTTON_VOLDOWN) ) + if ( joy[ACTION_VOLUP] && !joy.isActive(ACTION_VOLDOWN) ) menu->selLinkApp()->setVolume( constrain(menu->selLinkApp()->volume()+1,0,100) );; - if ( joy.isDown(GP2X_BUTTON_VOLUP) && joy.isDown(GP2X_BUTTON_VOLDOWN) ) menu->selLinkApp()->setVolume(-1); + if ( joy.isActive(ACTION_VOLUP) && joy.isActive(ACTION_VOLDOWN) ) menu->selLinkApp()->setVolume(-1); } else { // CLOCK - if ( joy[GP2X_BUTTON_VOLDOWN] && !joy.isDown(GP2X_BUTTON_VOLUP) ) + if ( joy[ACTION_VOLDOWN] && !joy.isActive(ACTION_VOLUP) ) menu->selLinkApp()->setClock( constrain(menu->selLinkApp()->clock()-1,50,maxClock) ); - if ( joy[GP2X_BUTTON_VOLUP] && !joy.isDown(GP2X_BUTTON_VOLDOWN) ) + if ( joy[ACTION_VOLUP] && !joy.isActive(ACTION_VOLDOWN) ) menu->selLinkApp()->setClock( constrain(menu->selLinkApp()->clock()+1,50,maxClock) ); - if ( joy.isDown(GP2X_BUTTON_VOLUP) && joy.isDown(GP2X_BUTTON_VOLDOWN) ) menu->selLinkApp()->setClock(200); + if ( joy.isActive(ACTION_VOLUP) && joy.isActive(ACTION_VOLDOWN) ) menu->selLinkApp()->setClock(200); } } - if ( joy.isDown(GP2X_BUTTON_A) ) { - if (joy.isDown(GP2X_BUTTON_L) && joy.isDown(GP2X_BUTTON_R)) + if ( joy.isActive(ACTION_A) ) { + if (joy.isActive(ACTION_L) && joy.isActive(ACTION_R)) saveScreenshot(); } else { // SECTIONS - if ( joy[GP2X_BUTTON_L ] ) { + if ( joy[ACTION_L ] ) { menu->decSectionIndex(); offset = menu->sectionLinks()->size()>linksPerPage ? 0 : 4; - } else if ( joy[GP2X_BUTTON_R ] ) { + } else if ( joy[ACTION_R ] ) { menu->incSectionIndex(); offset = menu->sectionLinks()->size()>linksPerPage ? 0 : 4; } } -#else +/*#else while (SDL_PollEvent(&event)) { if ( event.type == SDL_QUIT ) quit = true; if ( event.type==SDL_KEYDOWN ) { @@ -983,7 +1040,7 @@ if ( event.key.keysym.sym==SDLK_SPACE ) contextMenu(); } } -#endif +#endif*/ } return -1; @@ -992,11 +1049,32 @@ void GMenu2X::explorer() { FileDialog fd(this,tr["Select an application"],".gpu,.gpe,.sh"); if (fd.exec()) { - setClock(200); - quit(); + if (saveSelection && (startSectionIndex!=menu->selSectionIndex() || startLinkIndex!=menu->selLinkIndex())) + writeConfig(); + if (fwType == "open2x" && savedVolumeMode != volumeMode) + writeConfigOpen2x(); + + //senquack - not correct, we cannot put the wrapper behavior around every app + //launched with explorer, because then we'll usually end up with two active + //instances of gmenu2x since almost all programs re-launch the menu +// string command = cmdclean(fd.path()+"/"+fd.file) + "; sync & cd "+cmdclean(getExePath())+"; exec ./gmenu2x"; + //senquack - putting old behavior back in string command = cmdclean(fd.path()+"/"+fd.file); + chdir(fd.path().c_str()); - execl(command.c_str(), command.c_str(), NULL); + fflush(NULL); + quit(); + setClock(200); + execlp("/bin/sh","/bin/sh","-c",command.c_str(),NULL); + + //senquack -adding this, this should not be missing code to relaunch gmenu2x, + //as SDL is shut down at this point and any further blits will segfault it. + + //if execution continues then something went wrong and as we already called SDL_Quit we cannot continue + //try relaunching gmenu2x + fprintf(stderr, "Error executing selected application, re-launching gmenu2x\n"); + chdir(getExePath().c_str()); + execlp("./gmenu2x", "./gmenu2x", NULL); } } @@ -1055,14 +1133,29 @@ sd.addSetting(new MenuSettingBool(this,tr["USB host on boot"],tr["Allow USB host to be started at boot time"],&o2x_usb_host_on_boot)); sd.addSetting(new MenuSettingBool(this,tr["USB HID on boot"],tr["Allow USB HID to be started at boot time"],&o2x_usb_hid_on_boot)); sd.addSetting(new MenuSettingBool(this,tr["USB storage on boot"],tr["Allow USB storage to be started at boot time"],&o2x_usb_storage_on_boot)); + //sd.addSetting(new MenuSettingInt(this,tr["Speaker Mode on boot"],tr["Set Speaker mode. 0 = Mute, 1 = Phones, 2 = Speaker"],&volumeMode,0,2)); + //senquack - added a bit more description to these + sd.addSetting(new MenuSettingInt(this,tr["Speaker Scaler"],tr["Set the Speaker Mode scaling 0-150\% (default is 100\%)"],&volumeScalerNormal,0,150)); + sd.addSetting(new MenuSettingInt(this,tr["Headphones Scaler"],tr["Set the Headphones Mode scaling 0-100\% (default is 65\%)"],&volumeScalerPhones,0,100)); - if (sd.exec() && sd.edited()) { + if (sd.exec() && sd.edited()) + { writeConfigOpen2x(); + //senquack - must make sure the scaler gets updated since the values might have changed + // VOLUME MODIFIER + switch(volumeMode) { + case VOLUME_MODE_MUTE: setVolumeScaler(VOLUME_SCALER_MUTE); break; + case VOLUME_MODE_PHONES: setVolumeScaler(volumeScalerPhones); break; + case VOLUME_MODE_NORMAL: setVolumeScaler(volumeScalerNormal); break; + } + setVolume(globalVolume); } + } void GMenu2X::skinMenu() { FileLister fl_sk("skins",true,false); + fl_sk.exclude.push_back(".."); fl_sk.browse(); string curSkin = skin; @@ -1213,7 +1306,7 @@ } else { system("scripts/usbon.sh sd"); MessageBox mb(this,tr["USB Enabled (SD)"],"icons/usb.png"); - mb.buttons[GP2X_BUTTON_B] = tr["Turn off"]; + mb.buttons[ACTION_B] = tr["Turn off"]; mb.exec(); system("scripts/usboff.sh sd"); } @@ -1226,7 +1319,7 @@ } else { system("scripts/usbon.sh nand"); MessageBox mb(this,tr["USB Enabled (Nand)"],"icons/usb.png"); - mb.buttons[GP2X_BUTTON_B] = tr["Turn off"]; + mb.buttons[ACTION_B] = tr["Turn off"]; mb.exec(); system("scripts/usboff.sh nand"); } @@ -1239,7 +1332,7 @@ } else { system("scripts/usbon.sh root"); MessageBox mb(this,tr["USB Enabled (Root)"],"icons/usb.png"); - mb.buttons[GP2X_BUTTON_B] = tr["Turn off"]; + mb.buttons[ACTION_B] = tr["Turn off"]; mb.exec(); system("scripts/usboff.sh root"); } @@ -1310,7 +1403,7 @@ //touchscreen if (f200) { ts.poll(); - if (ts.pressed()) { + if (ts.released()) { if (!ts.inRect(box)) close = true; else if (ts.x>=selbox.x && ts.x<=selbox.x+selbox.w) @@ -1322,26 +1415,22 @@ i = voices.size(); } } + } else if (ts.pressed() && ts.inRect(box)) { + for (i=0; i<voices.size(); i++) { + selbox.y = box.y+4+(h+2)*i; + if (ts.y>=selbox.y && ts.y<=selbox.y+selbox.h) { + sel = i; + i = voices.size(); + } + } } } -#ifdef TARGET_GP2X joy.update(); - if ( joy[GP2X_BUTTON_SELECT] ) close = true; - if ( joy[GP2X_BUTTON_UP ] ) sel = max(0, sel-1); - if ( joy[GP2X_BUTTON_DOWN ] ) sel = min(voices.size()-1, sel+1); - if ( joy[GP2X_BUTTON_B] || joy[GP2X_BUTTON_CLICK] ) { voices[sel].action(); close = true; } -#else - while (SDL_PollEvent(&event)) { - if ( event.type == SDL_QUIT ) return; - if ( event.type==SDL_KEYDOWN ) { - if ( event.key.keysym.sym==SDLK_ESCAPE ) close = true; - if ( event.key.keysym.sym==SDLK_UP ) sel = max(0, sel-1); - if ( event.key.keysym.sym==SDLK_DOWN ) sel = min((int)voices.size()-1, sel+1); - if ( event.key.keysym.sym==SDLK_RETURN ) { voices[sel].action(); close = true; } - } - } -#endif + if ( joy[ACTION_SELECT] ) close = true; + if ( joy[ACTION_UP ] ) sel = max(0, sel-1); + if ( joy[ACTION_DOWN ] ) sel = min((int)voices.size()-1, sel+1); + if ( joy[ACTION_B] ) { voices[sel].action(); close = true; } } } @@ -1409,19 +1498,22 @@ //G int linkGamma = menu->selLinkApp()->gamma(); - SettingsDialog sd(this,tr["Edit link"]); - sd.addSetting(new MenuSettingString(this,tr["Title"],tr["Link title"],&linkTitle)); - sd.addSetting(new MenuSettingString(this,tr["Description"],tr["Link description"],&linkDescription)); + string diagTitle = tr.translate("Edit link: $1",linkTitle.c_str(),NULL); + string diagIcon = menu->selLinkApp()->getIconPath(); + + SettingsDialog sd(this,diagTitle,diagIcon); + sd.addSetting(new MenuSettingString(this,tr["Title"],tr["Link title"],&linkTitle, diagTitle,diagIcon)); + sd.addSetting(new MenuSettingString(this,tr["Description"],tr["Link description"],&linkDescription, diagTitle,diagIcon)); sd.addSetting(new MenuSettingMultiString(this,tr["Section"],tr["The section this link belongs to"],&newSection,&menu->sections)); sd.addSetting(new MenuSettingImage(this,tr["Icon"],tr.translate("Select an icon for the link: $1",linkTitle.c_str(),NULL),&linkIcon,".png,.bmp,.jpg,.jpeg")); sd.addSetting(new MenuSettingFile(this,tr["Manual"],tr["Select a graphic/textual manual or a readme"],&linkManual,".man.png,.txt")); sd.addSetting(new MenuSettingInt(this,tr["Clock (default: 200)"],tr["Cpu clock frequency to set when launching this link"],&linkClock,50,maxClock)); sd.addSetting(new MenuSettingBool(this,tr["Tweak RAM Timings"],tr["This usually speeds up the application at the cost of stability"],&linkUseRamTimings)); sd.addSetting(new MenuSettingInt(this,tr["Volume (default: -1)"],tr["Volume to set for this link"],&linkVolume,-1,100)); - sd.addSetting(new MenuSettingString(this,tr["Parameters"],tr["Parameters to pass to the application"],&linkParams)); + sd.addSetting(new MenuSettingString(this,tr["Parameters"],tr["Parameters to pass to the application"],&linkParams, diagTitle,diagIcon)); sd.addSetting(new MenuSettingDir(this,tr["Selector Directory"],tr["Directory to scan for the selector"],&linkSelDir)); sd.addSetting(new MenuSettingBool(this,tr["Selector Browser"],tr["Allow the selector to change directory"],&linkSelBrowser)); - sd.addSetting(new MenuSettingString(this,tr["Selector Filter"],tr["Filter for the selector (Separate values with a comma)"],&linkSelFilter)); + sd.addSetting(new MenuSettingString(this,tr["Selector Filter"],tr["Filter for the selector (Separate values with a comma)"],&linkSelFilter, diagTitle,diagIcon)); sd.addSetting(new MenuSettingDir(this,tr["Selector Screenshots"],tr["Directory of the screenshots for the selector"],&linkSelScreens)); sd.addSetting(new MenuSettingFile(this,tr["Selector Aliases"],tr["File containing a list of aliases for the selector"],&linkSelAliases)); //G @@ -1480,9 +1572,9 @@ void GMenu2X::deleteLink() { if (menu->selLinkApp()!=NULL) { MessageBox mb(this, tr.translate("Deleting $1",menu->selLink()->getTitle().c_str(),NULL)+"\n"+tr["Are you sure?"], menu->selLink()->getIconPath()); - mb.buttons[GP2X_BUTTON_B] = tr["Yes"]; - mb.buttons[GP2X_BUTTON_X] = tr["No"]; - if (mb.exec() == GP2X_BUTTON_B) { + mb.buttons[ACTION_B] = tr["Yes"]; + mb.buttons[ACTION_X] = tr["No"]; + if (mb.exec() == ACTION_B) { ledOn(); menu->deleteSelectedLink(); sync(); @@ -1517,11 +1609,17 @@ string sectiondir = "sections/"+menu->selSection(); ledOn(); if (rename(sectiondir.c_str(), "tmpsection")==0 && rename("tmpsection", newsectiondir.c_str())==0) { - string oldicon = sectiondir+".png", newicon = newsectiondir+".png"; - if (fileExists(oldicon) && !fileExists(newicon)) { - rename(oldicon.c_str(), "tmpsectionicon"); - rename("tmpsectionicon", newicon.c_str()); - sc.move(oldicon, newicon); + string oldpng = sectiondir+".png", newpng = newsectiondir+".png"; + string oldicon = sc.getSkinFilePath(oldpng), newicon = sc.getSkinFilePath(newpng); + if (!oldicon.empty() && newicon.empty()) { + newicon = oldicon; + newicon.replace(newicon.find(oldpng), oldpng.length(), newpng); + + if (!fileExists(newicon)) { + rename(oldicon.c_str(), "tmpsectionicon"); + rename("tmpsectionicon", newicon.c_str()); + sc.move("skin:"+oldpng, "skin:"+newpng); + } } menu->sections[menu->selSectionIndex()] = id.input; sync(); @@ -1533,9 +1631,9 @@ void GMenu2X::deleteSection() { MessageBox mb(this,tr["You will lose all the links in this section."]+"\n"+tr["Are you sure?"]); - mb.buttons[GP2X_BUTTON_B] = tr["Yes"]; - mb.buttons[GP2X_BUTTON_X] = tr["No"]; - if (mb.exec() == GP2X_BUTTON_B) { + mb.buttons[ACTION_B] = tr["Yes"]; + mb.buttons[ACTION_X] = tr["No"]; + if (mb.exec() == ACTION_B) { ledOn(); if (rmtree(path+"sections/"+menu->selSection())) { menu->deleteSelectedSection(); @@ -1570,7 +1668,7 @@ scanPath("/mnt/sd",&files); //Onyl gph firmware has nand - if (fwType=="gph") { + if (fwType=="gph" && !f200) { scanbg.write(font,tr["Scanning NAND filesystem..."],5,lineY); scanbg.blit(s,0,0); s->flip(); @@ -1622,17 +1720,13 @@ bool close = false; while (!close) { -#ifdef TARGET_GP2X joy.update(); - if (joy[GP2X_BUTTON_START] || joy[GP2X_BUTTON_B] || joy[GP2X_BUTTON_X]) close = true; -#else - while (SDL_PollEvent(&event)) - if (event.key.keysym.sym==SDLK_ESCAPE || event.key.keysym.sym==SDLK_RETURN) close = true; -#endif + if (joy[ACTION_START] || joy[ACTION_B] || joy[ACTION_X]) close = true; } sync(); ledOff(); + recalcLinkGrid = true; } void GMenu2X::scanPath(string path, vector<string> *files) { @@ -1663,31 +1757,39 @@ unsigned short GMenu2X::getBatteryLevel() { #ifdef TARGET_GP2X - int devbatt = open ("/dev/batt", O_RDONLY); - if (devbatt<0) return 0; + if (batteryHandle<=0) return 0; - int battval = 0; - unsigned short cbv, min=900, max=0; - int v; + if (f200) { + MMSP2ADC val; + int rv = read(batteryHandle, &val, sizeof(MMSP2ADC)); - for (int i = 0; i < BATTERY_READS; i ++) { - if (read (devbatt, &cbv, 2) == 2) { - battval += cbv; - if (cbv>max) max = cbv; - if (cbv<min) min = cbv; + if (val.batt==0) return 5; + if (val.batt==1) return 3; + if (val.batt==2) return 1; + if (val.batt==3) return 0; + } else { + int battval = 0; + unsigned short cbv, min=900, max=0; + int v; + + for (int i = 0; i < BATTERY_READS; i ++) { + if ( read(batteryHandle, &cbv, 2) == 2) { + battval += cbv; + if (cbv>max) max = cbv; + if (cbv<min) min = cbv; + } } - } - close(devbatt); - battval -= min+max; - battval /= BATTERY_READS-2; + battval -= min+max; + battval /= BATTERY_READS-2; - if (battval>=850) return 6; - if (battval>780) return 5; - if (battval>740) return 4; - if (battval>700) return 3; - if (battval>690) return 2; - if (battval>680) return 1; + if (battval>=850) return 6; + if (battval>780) return 5; + if (battval>740) return 4; + if (battval>700) return 3; + if (battval>690) return 2; + if (battval>680) return 1; + } return 0; #else return 6; //AC Power @@ -1695,53 +1797,57 @@ } void GMenu2X::setInputSpeed() { -#ifdef TARGET_GP2X joy.setInterval(150); - joy.setInterval(30, GP2X_BUTTON_VOLDOWN); - joy.setInterval(30, GP2X_BUTTON_VOLUP ); - joy.setInterval(30, GP2X_BUTTON_A ); - joy.setInterval(500, GP2X_BUTTON_START ); - joy.setInterval(500, GP2X_BUTTON_SELECT ); - joy.setInterval(300, GP2X_BUTTON_X ); - joy.setInterval(1000,GP2X_BUTTON_B ); - joy.setInterval(1000,GP2X_BUTTON_CLICK ); - joy.setInterval(300, GP2X_BUTTON_L ); - joy.setInterval(300, GP2X_BUTTON_R ); -#else + joy.setInterval(30, ACTION_VOLDOWN); + joy.setInterval(30, ACTION_VOLUP ); + joy.setInterval(30, ACTION_A ); + joy.setInterval(500, ACTION_START ); + joy.setInterval(500, ACTION_SELECT ); + joy.setInterval(300, ACTION_X ); + joy.setInterval(30, ACTION_Y ); + joy.setInterval(1000,ACTION_B ); + //joy.setInterval(1000,ACTION_CLICK ); + joy.setInterval(300, ACTION_L ); + joy.setInterval(300, ACTION_R ); SDL_EnableKeyRepeat(1,150); -#endif } void GMenu2X::applyRamTimings() { #ifdef TARGET_GP2X // 6 4 1 1 1 2 2 - int tRC = 5, tRAS = 3, tWR = 0, tMRD = 0, tRFC = 0, tRP = 1, tRCD = 1; - gp2x_memregs[0x3802>>1] = ((tMRD & 0xF) << 12) | ((tRFC & 0xF) << 8) | ((tRP & 0xF) << 4) | (tRCD & 0xF); - gp2x_memregs[0x3804>>1] = ((tRC & 0xF) << 8) | ((tRAS & 0xF) << 4) | (tWR & 0xF); + if (gp2x_mem!=0) { + int tRC = 5, tRAS = 3, tWR = 0, tMRD = 0, tRFC = 0, tRP = 1, tRCD = 1; + gp2x_memregs[0x3802>>1] = ((tMRD & 0xF) << 12) | ((tRFC & 0xF) << 8) | ((tRP & 0xF) << 4) | (tRCD & 0xF); + gp2x_memregs[0x3804>>1] = ((tRC & 0xF) << 8) | ((tRAS & 0xF) << 4) | (tWR & 0xF); + } #endif } void GMenu2X::applyDefaultTimings() { #ifdef TARGET_GP2X // 8 16 3 8 8 8 8 - int tRC = 7, tRAS = 15, tWR = 2, tMRD = 7, tRFC = 7, tRP = 7, tRCD = 7; - gp2x_memregs[0x3802>>1] = ((tMRD & 0xF) << 12) | ((tRFC & 0xF) << 8) | ((tRP & 0xF) << 4) | (tRCD & 0xF); - gp2x_memregs[0x3804>>1] = ((tRC & 0xF) << 8) | ((tRAS & 0xF) << 4) | (tWR & 0xF); + if (gp2x_mem!=0) { + int tRC = 7, tRAS = 15, tWR = 2, tMRD = 7, tRFC = 7, tRP = 7, tRCD = 7; + gp2x_memregs[0x3802>>1] = ((tMRD & 0xF) << 12) | ((tRFC & 0xF) << 8) | ((tRP & 0xF) << 4) | (tRCD & 0xF); + gp2x_memregs[0x3804>>1] = ((tRC & 0xF) << 8) | ((tRAS & 0xF) << 4) | (tWR & 0xF); + } #endif } void GMenu2X::setClock(unsigned mhz) { mhz = constrain(mhz,50,maxClock); #ifdef TARGET_GP2X - unsigned v; - unsigned mdiv,pdiv=3,scale=0; - mhz*=1000000; - mdiv=(mhz*pdiv)/GP2X_CLK_FREQ; - mdiv=((mdiv-8)<<8) & 0xff00; - pdiv=((pdiv-2)<<2) & 0xfc; - scale&=3; - v=mdiv | pdiv | scale; - MEM_REG[0x910>>1]=v; + if (gp2x_mem!=0) { + unsigned v; + unsigned mdiv,pdiv=3,scale=0; + mhz*=1000000; + mdiv=(mhz*pdiv)/GP2X_CLK_FREQ; + mdiv=((mdiv-8)<<8) & 0xff00; + pdiv=((pdiv-2)<<2) & 0xfc; + scale&=3; + v=mdiv | pdiv | scale; + MEM_REG[0x910>>1]=v; + } #endif } @@ -1761,17 +1867,49 @@ #endif } +int GMenu2X::getVolume() { + int vol = -1; + unsigned long soundDev = open("/dev/mixer", O_RDONLY); + if (soundDev) { + ioctl(soundDev, SOUND_MIXER_READ_PCM, &vol); + close(soundDev); + if (vol != -1) { + //just return one channel , not both channels, they're hopefully the same anyways + return vol & 0xFF; + } + } + return vol; +} + void GMenu2X::setVolume(int vol) { -#ifdef TARGET_GP2X + vol = constrain(vol,0,100); unsigned long soundDev = open("/dev/mixer", O_RDWR); if (soundDev) { - vol =(((vol*0x50)/100)<<8)|((vol*0x50)/100); + vol = (vol << 8) | vol; ioctl(soundDev, SOUND_MIXER_WRITE_PCM, &vol); close(soundDev); } -#endif } +void GMenu2X::setVolumeScaler(int scale) { + scale = constrain(scale,0,MAX_VOLUME_SCALE_FACTOR); + unsigned long soundDev = open("/dev/mixer", O_WRONLY); + if (soundDev) { + ioctl(soundDev, SOUND_MIXER_PRIVATE2, &scale); + close(soundDev); + } +} + +int GMenu2X::getVolumeScaler() { + int currentscalefactor = -1; + unsigned long soundDev = open("/dev/mixer", O_RDONLY); + if (soundDev) { + ioctl(soundDev, SOUND_MIXER_PRIVATE1, ¤tscalefactor); + close(soundDev); + } + return currentscalefactor; +} + string GMenu2X::getExePath() { if (path.empty()) { char buf[255]; @@ -1788,24 +1926,39 @@ string GMenu2X::getDiskFree() { stringstream ss; string df = ""; - struct statfs b; + struct statvfs b; - int ret = statfs("/mnt/sd", &b); + int ret = statvfs("/mnt/sd", &b); if (ret==0) { - ss << b.f_bfree*b.f_bsize/1048576 << "/" << b.f_blocks*b.f_bsize/1048576 << "MB"; + //DKS - fixing a bug where wrong sizes are reported because of overflowed int + printf("b.f_bfree: %d\tb.f_bsize: %d\n", b.f_bfree, b.f_bsize); + printf("b.f_blocks: %d\tb.f_frsize:%d\n", b.f_blocks, b.f_frsize); +// unsigned long free = b.f_bfree*b.f_frsize/1048576; + double free = (double)b.f_bfree * (double)b.f_bsize / 1048576.0; +// unsigned long total = b.f_blocks*b.f_frsize/1048576; + double total = (double)b.f_blocks * (double)b.f_frsize / 1048576.0; +// ss << free << "/" << total << "MB"; + ss << (unsigned long)free << "/" << (unsigned long)total << "MB"; ss >> df; - } else cout << "\033[0;34mGMENU2X:\033[0;31m statfs failed with error '" << strerror(errno) << "'\033[0m" << endl; + } else cout << "\033[0;34mGMENU2X:\033[0;31m statvfs failed with error '" << strerror(errno) << "'\033[0m" << endl; return df; } +int GMenu2X::drawButton(IconButton *btn, int x, int y) { + btn->setPosition(x, y-7); + btn->paint(); + return x+btn->getRect().w+6; +} + int GMenu2X::drawButton(Surface *s, string btn, string text, int x, int y) { + SDL_Rect re = {x, y-7, 0, 16}; if (sc.skinRes("imgs/buttons/"+btn+".png") != NULL) { sc["imgs/buttons/"+btn+".png"]->blit(s, x, y-7); - x += sc["imgs/buttons/"+btn+".png"]->raw->w+3; - s->write(font, text, x, y, SFontHAlignLeft, SFontVAlignMiddle); - return x+6+font->getTextWidth(text); + re.w = sc["imgs/buttons/"+btn+".png"]->raw->w+3; + s->write(font, text, x+re.w, y, SFontHAlignLeft, SFontVAlignMiddle); + re.w += font->getTextWidth(text); } - return x+6; + return x+re.w+6; } int GMenu2X::drawButtonRight(Surface *s, string btn, string text, int x, int y) { Modified: trunk/utils/gmenu2x/source/gmenu2x.h =================================================================== --- trunk/utils/gmenu2x/source/gmenu2x.h 2008-12-22 23:35:57 UTC (rev 345) +++ trunk/utils/gmenu2x/source/gmenu2x.h 2008-12-24 16:34:17 UTC (rev 346) @@ -24,22 +24,33 @@ #include <string> #include <iostream> #include "surfacecollection.h" +#include "iconbutton.h" #include "translator.h" #include "FastDelegate.h" #include "utilities.h" #include "touchscreen.h" +#include "inputmanager.h" -#ifdef TARGET_GP2X -#include "joystick.h" -#endif +const int MAX_VOLUME_SCALE_FACTOR = 200; +// Default values - going to add settings adjustment, saving, loading and such +const int VOLUME_SCALER_MUTE = 0; +const int VOLUME_SCALER_PHONES = 55; +const int VOLUME_SCALER_NORMAL = 100; +const int VOLUME_MODE_MUTE = 0; +const int VOLUME_MODE_PHONES = 1; +const int VOLUME_MODE_NORMAL = 2; +const int BATTERY_READS = 10; -#define BATTERY_READS 10 - using std::string; using fastdelegate::FastDelegate0; typedef FastDelegate0<> MenuAction; +typedef struct { + unsigned short batt; + unsigned short remocon; +} MMSP2ADC; + struct MenuOption { string text; MenuAction action; @@ -63,6 +74,7 @@ @return A number representing battery charge. 0 means fully discharged. 5 means fully charged. 6 represents a gp2x using AC power. */ unsigned short getBatteryLevel(); + int batteryHandle; void browsePath(string path, vector<string>* directories, vector<string>* files); /*! Starts the scanning of the nand and sd filesystems, searching for gpe and gpu files and creating the links in 2 dedicated sections. @@ -124,11 +136,7 @@ */ string getExePath(); -#ifdef TARGET_GP2X - Joystick joy; -#else - SDL_Event event; -#endif + InputManager joy; Touchscreen ts; //Configuration settings @@ -145,10 +153,16 @@ //gp2x type bool f200; - // Open2x settings + // Open2x settings --------------------------------------------------------- bool o2x_usb_net_on_boot, o2x_ftp_on_boot, o2x_telnet_on_boot, o2x_gp2xjoy_on_boot, o2x_usb_host_on_boot, o2x_usb_hid_on_boot, o2x_usb_storage_on_boot; string o2x_usb_net_ip; + int volumeMode, savedVolumeMode; // just use the const int scale values at top of source + // Volume scaling values to store from config files + int volumeScalerPhones; + int volumeScalerNormal; + //-------------------------------------------------------------------------- + SurfaceCollection sc; Translator tr; Surface *s, *bg; @@ -173,7 +187,11 @@ void setCl... [truncated message content] |
From: <sen...@us...> - 2008-12-22 23:36:01
|
Revision: 345 http://open2x.svn.sourceforge.net/open2x/?rev=345&view=rev Author: senquack Date: 2008-12-22 23:35:57 +0000 (Mon, 22 Dec 2008) Log Message: ----------- Added ability to turn off mouse button events coming from F200 touchscreen: SDL_GP2X_TouchpadMouseButtonEvents() Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2008-12-22 23:35:18 UTC (rev 344) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c 2008-12-22 23:35:57 UTC (rev 345) @@ -363,25 +363,29 @@ posted += SDL_PrivateMouseMotion(0, relative, dx, dy); } - /* Swap button 1 and 3 */ - button_1 = (button & 0x04) >> 2; - button_3 = (button & 0x01) << 2; - button &= ~0x05; - button |= (button_1|button_3); + //senquack - support for new option to disable mouse button events from touchscreen + if (current_video->hidden->mouse_button_events_enabled) + { + /* Swap button 1 and 3 */ + button_1 = (button & 0x04) >> 2; + button_3 = (button & 0x01) << 2; + button &= ~0x05; + button |= (button_1|button_3); - /* See what changed */ - button_state = SDL_GetMouseState(NULL, NULL); - state_changed = button_state ^ button; - for (i=0; i<8; ++i ) { - if (state_changed & (1<<i)) { - if (button & (1<<i)) { - state = SDL_PRESSED; - } else { - state = SDL_RELEASED; - } - posted += SDL_PrivateMouseButton(state, i+1, 0, 0); - } - } + /* See what changed */ + button_state = SDL_GetMouseState(NULL, NULL); + state_changed = button_state ^ button; + for (i=0; i<8; ++i ) { + if (state_changed & (1<<i)) { + if (button & (1<<i)) { + state = SDL_PRESSED; + } else { + state = SDL_RELEASED; + } + posted += SDL_PrivateMouseButton(state, i+1, 0, 0); + } + } + } } //DKS - pulled from my modifications to SDL 1.2.9 Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c 2008-12-22 23:35:18 UTC (rev 344) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c 2008-12-22 23:35:57 UTC (rev 345) @@ -184,6 +184,9 @@ device->hidden->mouse_fd = -1; device->hidden->keyboard_fd = -1; + // senquack - new user-configurable option, see SDL_gp2xvideo.h for description + device->hidden->mouse_button_events_enabled = 1; /* default is enabled */ + // Set the function pointers device->VideoInit = GP2X_VideoInit; device->ListModes = GP2X_ListModes; @@ -1610,3 +1613,14 @@ if (y) *y = current_video->hidden->touch_y; return current_video->hidden->touch_pressure; } + +// Enable (1) or disable (0) the touchscreen stylus from causing mouse button events. +// In some games/apps it is desirable to have the stylus only used for positioning of +// the cursor with clicking done by joystick buttons. Default is enabled. +void SDL_GP2X_TouchpadMouseButtonEvents(int enabled) +{ + if (current_video->hidden->mouse_type == 2) + { + current_video->hidden->mouse_button_events_enabled = enabled ? 1:0; + } +} Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h 2008-12-22 23:35:18 UTC (rev 344) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h 2008-12-22 23:35:57 UTC (rev 345) @@ -137,6 +137,10 @@ int current_vt; int saved_vt; int mouse_type; + //senquack - new option + int mouse_button_events_enabled; /* User-configurable option. default = 1: post mouse + button events when stylus goes up or down. + 0: don't post button events */ struct tsdev *ts_dev; struct termios saved_kbd_termios; int touch_x, touch_y, touch_pressure; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-22 23:35:21
|
Revision: 344 http://open2x.svn.sourceforge.net/open2x/?rev=344&view=rev Author: senquack Date: 2008-12-22 23:35:18 +0000 (Mon, 22 Dec 2008) Log Message: ----------- Added ability to turn off mouse button events coming from F200 touchscreen: SDL_GP2X_TouchpadMouseButtonEvents() Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_config.h trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_config.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_config.h 2008-12-22 16:57:00 UTC (rev 343) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_config.h 2008-12-22 23:35:18 UTC (rev 344) @@ -128,7 +128,7 @@ #define HAVE_ICONV 1 #define HAVE_SIGACTION 1 #define HAVE_SETJMP 1 -#define HAVE_NANOSLEEP 1 +/* #undef HAVE_NANOSLEEP */ /* #undef HAVE_CLOCK_GETTIME */ #define HAVE_DLVSYM 1 Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h 2008-12-22 16:57:00 UTC (rev 343) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h 2008-12-22 23:35:18 UTC (rev 344) @@ -52,6 +52,11 @@ // Return value is pressure (any non zero value means pressed) int SDL_GP2X_Touchpad(int *x, int *y); +// Enable (1) or disable (0) the touchscreen stylus from causing mouse button events. +// In some games/apps it is desirable to have the stylus only used for positioning of +// the cursor with clicking done by joystick buttons. Default is enabled. +void SDL_GP2X_TouchpadMouseButtonEvents(int enabled); + #ifdef __cplusplus } #endif This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-22 16:57:05
|
Revision: 343 http://open2x.svn.sourceforge.net/open2x/?rev=343&view=rev Author: senquack Date: 2008-12-22 16:57:00 +0000 (Mon, 22 Dec 2008) Log Message: ----------- Final tweaking of F100/F200 sound volumes Modified Paths: -------------- trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/sound/ac97_codec.c Modified: trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/sound/ac97_codec.c =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/sound/ac97_codec.c 2008-12-21 21:37:38 UTC (rev 342) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/sound/ac97_codec.c 2008-12-22 16:57:00 UTC (rev 343) @@ -448,8 +448,8 @@ //senquack - 115 proved to be too quiet for some apps like Supertux // left = (left * g_volume_scale) / 115; // right = (right * g_volume_scale) / 115; - left = (left * g_volume_scale) / 105; - right = (right * g_volume_scale) / 105; + left = (left * g_volume_scale) / 85; + right = (right * g_volume_scale) / 85; if (left > 100) { left = 100; @@ -479,15 +479,17 @@ right_pcm = right >> 1; right -= right_pcm; - //senquack - ok the above seems to put us somewhere in the range 0-25 #ifdef CONFIG_MACH_GP2XF200 -//// left += 8; -//// right += 8; - //senquack - changed this to 6. F200s are naturally louder and need this tweak. +// left += 8; +// right += 8; + //senquack - changed this to 7 to perfectly match F100's volume left += 6; right += 6; #endif + + //senquack - ok the above seems to put us somewhere in the range 0-25 + printk("senquack - left: %d left_pcm: %d right %d right_pcm %d\n", left,left_pcm,right,right_pcm); val = (left << 8) | right; val_pcm = (left_pcm << 8) | right_pcm; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-21 22:22:07
|
Revision: 342 http://open2x.svn.sourceforge.net/open2x/?rev=342&view=rev Author: senquack Date: 2008-12-21 21:37:38 +0000 (Sun, 21 Dec 2008) Log Message: ----------- Disabled use of nanosleep() to improve compatibility with older SDLs Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/configure.in Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/configure.in =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/configure.in 2008-12-20 19:41:21 UTC (rev 341) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/configure.in 2008-12-21 21:37:38 UTC (rev 342) @@ -133,7 +133,10 @@ if test x$ac_cv_func_strtod = xyes; then AC_DEFINE(HAVE_STRTOD) fi - AC_CHECK_FUNCS(malloc calloc realloc free getenv putenv unsetenv qsort abs bcopy memset memcpy memmove strlen strlcpy strlcat strdup _strrev _strupr _strlwr strchr strrchr strstr itoa _ltoa _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp strncasecmp sscanf snprintf vsnprintf iconv sigaction setjmp nanosleep) +#DKS - disabled check for nanosleep, we don't want to use it, it causes problems with +# SDL_Delay on GP2X +# AC_CHECK_FUNCS(malloc calloc realloc free getenv putenv unsetenv qsort abs bcopy memset memcpy memmove strlen strlcpy strlcat strdup _strrev _strupr _strlwr strchr strrchr strstr itoa _ltoa _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp strncasecmp sscanf snprintf vsnprintf iconv sigaction setjmp nanosleep) + AC_CHECK_FUNCS(malloc calloc realloc free getenv putenv unsetenv qsort abs bcopy memset memcpy memmove strlen strlcpy strlcat strdup _strrev _strupr _strlwr strchr strrchr strstr itoa _ltoa _uitoa _ultoa strtol strtoul _i64toa _ui64toa strtoll strtoull atoi atof strcmp strncmp _stricmp strcasecmp _strnicmp strncasecmp sscanf snprintf vsnprintf iconv sigaction setjmp) AC_CHECK_LIB(iconv, libiconv_open, [EXTRA_LDFLAGS="$EXTRA_LDFLAGS -liconv"]) AC_CHECK_LIB(m, pow, [EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lm"]) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-20 19:41:23
|
Revision: 341 http://open2x.svn.sourceforge.net/open2x/?rev=341&view=rev Author: senquack Date: 2008-12-20 19:41:21 +0000 (Sat, 20 Dec 2008) Log Message: ----------- Bringing in more 1.2.9/1.2.13 functionality (forgot these) Added Paths: ----------- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xkeys.h Added: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xkeys.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xkeys.h (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xkeys.h 2008-12-20 19:41:21 UTC (rev 341) @@ -0,0 +1,170 @@ +/* + SDL - Simple DirectMedia Layer + Copyright (C) 1997-2004 Sam Lantinga + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + Sam Lantinga + sl...@li... +*/ + +#ifdef SAVE_RCSID +static char rcsid = + "@(#) $Id: $"; +#endif + +#ifndef _SDL_gp2xkeys_h +#define _SDL_gp2xkeys_h + + +/* Scancodes for the Linux console + - Bits taken with thanks from SVGAlib 1.4.0 +*/ + +#define SCANCODE_ESCAPE 1 + +#define SCANCODE_1 2 +#define SCANCODE_2 3 +#define SCANCODE_3 4 +#define SCANCODE_4 5 +#define SCANCODE_5 6 +#define SCANCODE_6 7 +#define SCANCODE_7 8 +#define SCANCODE_8 9 +#define SCANCODE_9 10 +#define SCANCODE_0 11 + +#define SCANCODE_MINUS 12 +#define SCANCODE_EQUAL 13 + +#define SCANCODE_BACKSPACE 14 +#define SCANCODE_TAB 15 + +#define SCANCODE_Q 16 +#define SCANCODE_W 17 +#define SCANCODE_E 18 +#define SCANCODE_R 19 +#define SCANCODE_T 20 +#define SCANCODE_Y 21 +#define SCANCODE_U 22 +#define SCANCODE_I 23 +#define SCANCODE_O 24 +#define SCANCODE_P 25 +#define SCANCODE_BRACKET_LEFT 26 +#define SCANCODE_BRACKET_RIGHT 27 + +#define SCANCODE_ENTER 28 + +#define SCANCODE_LEFTCONTROL 29 + +#define SCANCODE_A 30 +#define SCANCODE_S 31 +#define SCANCODE_D 32 +#define SCANCODE_F 33 +#define SCANCODE_G 34 +#define SCANCODE_H 35 +#define SCANCODE_J 36 +#define SCANCODE_K 37 +#define SCANCODE_L 38 +#define SCANCODE_SEMICOLON 39 +#define SCANCODE_APOSTROPHE 40 +#define SCANCODE_GRAVE 41 + +#define SCANCODE_LEFTSHIFT 42 +#define SCANCODE_BACKSLASH 43 + +#define SCANCODE_Z 44 +#define SCANCODE_X 45 +#define SCANCODE_C 46 +#define SCANCODE_V 47 +#define SCANCODE_B 48 +#define SCANCODE_N 49 +#define SCANCODE_M 50 +#define SCANCODE_COMMA 51 +#define SCANCODE_PERIOD 52 +#define SCANCODE_SLASH 53 + +#define SCANCODE_RIGHTSHIFT 54 +#define SCANCODE_KEYPADMULTIPLY 55 + +#define SCANCODE_LEFTALT 56 +#define SCANCODE_SPACE 57 +#define SCANCODE_CAPSLOCK 58 + +#define SCANCODE_F1 59 +#define SCANCODE_F2 60 +#define SCANCODE_F3 61 +#define SCANCODE_F4 62 +#define SCANCODE_F5 63 +#define SCANCODE_F6 64 +#define SCANCODE_F7 65 +#define SCANCODE_F8 66 +#define SCANCODE_F9 67 +#define SCANCODE_F10 68 + +#define SCANCODE_NUMLOCK 69 +#define SCANCODE_SCROLLLOCK 70 + +#define SCANCODE_KEYPAD7 71 +#define SCANCODE_CURSORUPLEFT 71 +#define SCANCODE_KEYPAD8 72 +#define SCANCODE_CURSORUP 72 +#define SCANCODE_KEYPAD9 73 +#define SCANCODE_CURSORUPRIGHT 73 +#define SCANCODE_KEYPADMINUS 74 +#define SCANCODE_KEYPAD4 75 +#define SCANCODE_CURSORLEFT 75 +#define SCANCODE_KEYPAD5 76 +#define SCANCODE_KEYPAD6 77 +#define SCANCODE_CURSORRIGHT 77 +#define SCANCODE_KEYPADPLUS 78 +#define SCANCODE_KEYPAD1 79 +#define SCANCODE_CURSORDOWNLEFT 79 +#define SCANCODE_KEYPAD2 80 +#define SCANCODE_CURSORDOWN 80 +#define SCANCODE_KEYPAD3 81 +#define SCANCODE_CURSORDOWNRIGHT 81 +#define SCANCODE_KEYPAD0 82 +#define SCANCODE_KEYPADPERIOD 83 + +#define SCANCODE_LESS 86 + +#define SCANCODE_F11 87 +#define SCANCODE_F12 88 + +#define SCANCODE_KEYPADENTER 96 +#define SCANCODE_RIGHTCONTROL 97 +#define SCANCODE_CONTROL 97 +#define SCANCODE_KEYPADDIVIDE 98 +#define SCANCODE_PRINTSCREEN 99 +#define SCANCODE_RIGHTALT 100 +#define SCANCODE_BREAK 101 /* Beware: is 119 */ +#define SCANCODE_BREAK_ALTERNATIVE 119 /* on some keyboards! */ + +#define SCANCODE_HOME 102 +#define SCANCODE_CURSORBLOCKUP 103 /* Cursor key block */ +#define SCANCODE_PAGEUP 104 +#define SCANCODE_CURSORBLOCKLEFT 105 /* Cursor key block */ +#define SCANCODE_CURSORBLOCKRIGHT 106 /* Cursor key block */ +#define SCANCODE_END 107 +#define SCANCODE_CURSORBLOCKDOWN 108 /* Cursor key block */ +#define SCANCODE_PAGEDOWN 109 +#define SCANCODE_INSERT 110 +#define SCANCODE_REMOVE 111 + +#define SCANCODE_RIGHTWIN 126 +#define SCANCODE_LEFTWIN 125 + +#endif // _SDL_gp2xkeys_h This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-20 19:40:54
|
Revision: 340 http://open2x.svn.sourceforge.net/open2x/?rev=340&view=rev Author: senquack Date: 2008-12-20 19:40:44 +0000 (Sat, 20 Dec 2008) Log Message: ----------- Bringing in more 1.2.9/1.2.13 functionality (forgot these) Added Paths: ----------- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h Added: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/gp2x_tslib.c 2008-12-20 19:40:44 UTC (rev 340) @@ -0,0 +1,1450 @@ +/* + * tslib-1.0 based touchscreen event handler + * + * Altered to work without dynamic loading and fixed modules, + * i.e. all code in this file, modules supported are: + * module_raw ucb1x00 + * module pthres + * module variance + * module dejitter + * + * Specifically re-written for HWSDL on the GP2X F-200 + * changes in functions to remove un-needed stuff like reading >1 value + * at a time (SDL only ever reads 1) + */ + +#include <stdlib.h> +#include <stdio.h> +#include <unistd.h> +#include <sys/fcntl.h> +#include <sys/stat.h> +#include <errno.h> +#include <limits.h> +#include <string.h> + +#include "tslib.h" + +typedef struct tsdev { + int fd; +} TSDEV; + +typedef struct ts_sample TS_SAMPLE; + +typedef struct tslib_vars { + const char *name; + void *data; + int (*fn)(char *str, void *data); +} TSLIB_VARS; + +int tslib_parse_vars(const TSLIB_VARS *, int, const char *); + +#define SQR(x) ((x) * (x)) + +/****************************** + * tslib open/close + ******************************/ + +TSDEV *ts_open(const char *name, int nonblock) +{ + TSDEV *ts; + int flags = O_RDONLY; + + if (nonblock) + flags |= O_NONBLOCK; + + ts = malloc(sizeof(TSDEV)); + if (ts) { + memset(ts, 0, sizeof(TSDEV)); + + ts->fd = open(name, flags); + if (ts->fd == -1) { + free(ts); + ts = NULL; + } + } + + return ts; +} + +int ts_close(TSDEV *ts) +{ + int ret; + + ret = close(ts->fd); + free(ts); + + return ret; +} + +int ts_fd(TSDEV *ts) +{ + return ts->fd; +} + + +/****************************** + * ucb1x100-raw + ******************************/ + +//DKS - I am having problems reading the device, it is only returning 8 bytes +//typedef struct ucb1x00_ts_event { +// unsigned short pressure; +// unsigned short x; +// unsigned short y; +// unsigned short pad; +// struct timeval stamp; +//} UCB1X00_TS_EVENT; +typedef struct ucb1x00_ts_event { + unsigned short pressure; + unsigned short x; + unsigned short y; + unsigned short pad; +} UCB1X00_TS_EVENT; + + +//DKS +//static int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp) +//{ +// UCB1X00_TS_EVENT ucb1x00_evt; +// int ret; +// +// ret = read(ts->fd, &ucb1x00_evt, sizeof(ucb1x00_evt)); +// if (ret > 0) { +// samp->x = ucb1x00_evt.x; +// samp->y = ucb1x00_evt.y; +// samp->pressure = ucb1x00_evt.pressure; +// samp->tv.tv_usec = ucb1x00_evt.stamp.tv_usec; +// samp->tv.tv_sec = ucb1x00_evt.stamp.tv_sec; +// ret = 1; +// } else +// ret = -1; +// +// return ret; +//} +//DKS - known working copy, latest one before change to read multiple samples: +//static int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp) +//{ +// UCB1X00_TS_EVENT ucb1x00_evt; +// int ret; +// +// ret = read(ts->fd, &ucb1x00_evt, sizeof(ucb1x00_evt)); +// if (ret > 0) { +// samp->x = ucb1x00_evt.x; +// samp->y = ucb1x00_evt.y; +// samp->pressure = ucb1x00_evt.pressure; +// +// //DKS +//#ifdef DKS_DEBUG +// if (samp->pressure > 0) { +// if (samp->pressure < tslib_minpressure) { +// tslib_minpressure = samp->pressure; +// } +// if (samp->pressure > tslib_maxpressure) { +// tslib_maxpressure = samp->pressure; +// } +// } +//#endif +// +// //DKS - we're never going to need this +//// samp->tv.tv_usec = ucb1x00_evt.stamp.tv_usec; +//// samp->tv.tv_sec = ucb1x00_evt.stamp.tv_sec; +// ret = 1; +// } else +// ret = -1; +// +// return ret; +//} +//DKS - OK, hours of work only to find you cannot read more than one sample at a time +// out of the touchscreen device +//DKS - I am gonna disable this code for now, change it to a for loop and read more at a time +//static inline int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +//{ +//// struct tsdev *ts = inf->dev; +//// struct ucb1x00_ts_event *ucb1x00_evt; +// UCB1X00_TS_EVENT *ucb1x00_evt; +// int ret; +//// int total = 0; +// ucb1x00_evt = alloca(sizeof(UCB1X00_TS_EVENT) * nr); +// +// tslib_debug5 = sizeof(UCB1X00_TS_EVENT) * nr; // DKS - got 16 here +// +// ret = read(ts->fd, ucb1x00_evt, sizeof(UCB1X00_TS_EVENT) * nr); +// +// //DKS - debugging +//// tslib_debug = ret; // this gave me 8 +// tslib_debug = sizeof(UCB1X00_TS_EVENT); // this gave me 16 +// tslib_debug4 = ret; // GOT 8 here +// +// int numread = 0; +// if(ret > 0) { +// numread = ret / sizeof(UCB1X00_TS_EVENT); +// +// tslib_debug2 = numread; +// +// while(ret >= (int)sizeof(UCB1X00_TS_EVENT)) { +// samp->x = ucb1x00_evt->x; +// samp->y = ucb1x00_evt->y; +// samp->pressure = ucb1x00_evt->pressure; +////#ifdef DEBUG +//// fprintf(stderr,"RAW---------------------------> %d %d %d\n",samp->x,samp->y,samp->pressure); +////#endif /*DEBUG*/ +// //DKS - won't need these +//// samp->tv.tv_usec = ucb1x00_evt->stamp.tv_usec; +//// samp->tv.tv_sec = ucb1x00_evt->stamp.tv_sec; +// samp++; +// ucb1x00_evt++; +// ret -= sizeof(UCB1X00_TS_EVENT); +// } +// } else { +// return -1; +// } +// +// ret = numread; +// return ret; +//} +//DKS - Originially, I had made this read multiple samples but it turns out the driver +//for the touchscreen is set up to give only one sample per read, so had to go back +//to this optimized version. It should be noted that the device file only ever provides +//8 bytes of data, basically 3shorts: x,y,and pressure, and the old code tried to read +//data that was never provided. +static inline int ucb1x00_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + UCB1X00_TS_EVENT ucb1x00_evt; + + if (read(ts->fd, &ucb1x00_evt, sizeof(UCB1X00_TS_EVENT)) == sizeof(UCB1X00_TS_EVENT)) { + samp->x = ucb1x00_evt.x; + samp->y = ucb1x00_evt.y; + samp->pressure = ucb1x00_evt.pressure; + return 1; + } else { + return -1; + } + +} + + +/****************************** + * pthres + ******************************/ + +//DKS - don't need these +//typedef struct tslib_pthres { +// unsigned int pmin; +// unsigned int pmax; +//} TSLIB_PTHRES; +// +//TSLIB_PTHRES pthres_dev; +// +//int threshold_vars(char *str, void *data) +//{ +// unsigned long v; +// int err = errno; +// +// v = strtoul(str, NULL, 0); +// if (v == ULONG_MAX && errno == ERANGE) +// return -1; +// errno = err; +// switch ((int)data) { +// case 0: +// pthres_dev.pmin = v; +// break; +// case 1: +// pthres_dev.pmax = v; +// break; +// default: +// return -1; +// } +// return 0; +//} + +//DKS - don't need this +//static const TSLIB_VARS pthres_vars[] = { +// {"pmin", (void *)0, threshold_vars}, +// {"pmax", (void *)1, threshold_vars} +//}; + +//DKS - don't need this +//#define NR_PTHRES_VARS (sizeof(pthres_vars) / sizeof(pthres_vars[0])) + + +//DKS - no idea why we might still need this +//int pthres_init(const char *params) +//{ +// int ret = 0; +// +// pthres_dev.pmin = 1; +// pthres_dev.pmax = INT_MAX; +// if (tslib_parse_vars(pthres_vars, NR_PTHRES_VARS, params)) { +// ret = 1; +// } +// +// return ret; +//} + +//DKS ok, there is a bad pointer dereference in TS_SAMPLE below, gonna copy and fix it. +//int pthres_read(TSDEV *ts, TS_SAMPLE *samp) +//{ +//#ifdef DKS_DEBUG +// //DKS - continuously update this to current global variable value, so programs can +// // tweak it real-time +// pthres_dev.pmin = tslib_pmin; +//#endif +// +// int ret; +// static int xsave = 0, ysave = 0; +// static int press = 0; +// +// ret = ucb1x00_read(ts, samp); +// if (ret >= 0) { +// TS_SAMPLE *s; +// +// if (s->pressure < pthres_dev.pmin) { +// if (press != 0) { +// press = 0; +// s->pressure = 0; +// s->x = xsave; +// s->y = ysave; +// ret = 1; +// } else +// ret = 0; +// } else { +// if (s->pressure > pthres_dev.pmax) +// ret = 0; +// else { +// press = 1; +// xsave = s->x; +// ysave = s->y; +// ret = 1; +// } +// } +// } +// +// return ret; +//} +//int pthres_read(TSDEV *ts, TS_SAMPLE *samp) +#define MINPRESSURE 35000 // Accepting pressures below this on the GP2X F200 leads to + // cursor jumping on taps. +static inline int pthres_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + int ret; + static int xsave = 0, ysave = 0; + static int press = 0; + + ret = ucb1x00_read(ts, samp,1); + if (ret >= 0) + { + if (samp->pressure < MINPRESSURE) + { + if (press != 0) { + press = 0; + samp->pressure = 0; + samp->x = xsave; + samp->y = ysave; + ret = 1; + } else { + ret = 0; + } + } else { + press = 1; + xsave = samp->x; + ysave = samp->y; + ret = 1; + } + } + + return ret; +} +//DKS - known working copy of multiple-sample version, but changing back to 1-sample for now +//#define MINPRESSURE 35000 //DKS - for the GP2X, reading values below this results in +// // tapping inaccuracies +////static int +//static inline int +////pthres_read(struct tslib_module_info *info, struct ts_sample *samp, int nr) +//pthres_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +//{ +//// struct tslib_pthres *p = (struct tslib_pthres *)info; +// int ret; +// static int xsave = 0, ysave = 0; +// static int press = 0; +// +//// ret = info->next->ops->read(info->next, samp, nr); +// ret = ucb1x00_read(ts, samp, nr); +// if (ret >= 0) { +// int nr = 0, i; +// struct ts_sample *s; +// +// for (s = samp, i = 0; i < ret; i++, s++) { +//// if (s->pressure < p->pmin) { +// if (s->pressure < MINPRESSURE) { +// if (press != 0) { +// /* release */ +// press = 0; +// s->pressure = 0; +// s->x = xsave; +// s->y = ysave; +// } else { +// /* release with no press, outside bounds, dropping */ +// int left = ret - nr - 1; +// if (left > 0) { +// memmove(s, s + 1, left * sizeof(struct ts_sample)); +// s--; +// continue; +// } +// break; +// } +// } else { +////DKS - on the GP2X F200, we don't worry about pressure maximums +//// if (s->pressure > p->pmax) { +//// /* pressure outside bounds, dropping */ +//// int left = ret - nr - 1; +//// if (left > 0) { +//// memmove(s, s + 1, left * sizeof(struct ts_sample)); +//// s--; +//// continue; +//// } +//// break; +//// } +// /* press */ +// press = 1; +// xsave = s->x; +// ysave = s->y; +// } +// nr++; +// } +// return nr; +// } +// return ret; +//} + +//DKS - no idea why we might need this still +//static int pthres_fini(struct tslib_module_info *info) +//{ +// free(info); +// return 0; +//} + + +/****************************** + * variance + ******************************/ + +typedef struct tslib_variance { + int delta; + TS_SAMPLE last; + TS_SAMPLE noise; + unsigned int flags; +#define VAR_PENDOWN 0x00000001 +#define VAR_LASTVALID 0x00000002 +#define VAR_NOISEVALID 0x00000004 +#define VAR_SUBMITNOISE 0x00000008 +} TSLIB_VARIANCE; + +TSLIB_VARIANCE variance_dev; + +static int variance_limit(char *str, void *data) +{ + unsigned long v; + int err = errno; + + v = strtoul(str, NULL, 0); + if (v == ULONG_MAX && errno == ERANGE) + return -1; + errno = err; + switch ((int)data) { + case 1: + variance_dev.delta = v; + break; + default: + return -1; + } + return 0; +} + +static const TSLIB_VARS variance_vars[] = { + {"delta", (void *)1, variance_limit} +}; + +#define NR_VAR_VARS (sizeof(variance_vars) / sizeof(variance_vars[0])) + +int variance_init(const char *params) +{ + int ret = 0; + + bzero(&variance_dev, sizeof(variance_dev)); + variance_dev.delta = 30; + variance_dev.flags = 0; + if (tslib_parse_vars(variance_vars, NR_VAR_VARS, params)) { + ret = 1; + } +// variance_dev.delta = sqr(variance_dev.delta); + variance_dev.delta = SQR(variance_dev.delta); + + return ret; +} + +//DKS - added parameter, flush_history, that gets assigned to 1 if a fast movement is +// detected.. this is so the averaging algorithm will flush its history if +// enough of them are detected +static inline int variance_read(TSDEV *ts, TS_SAMPLE *samp, int nr, int *flush_history) +{ + struct ts_sample cur; + int count = 0, dist; + + while (count < nr) { + if (variance_dev.flags & VAR_SUBMITNOISE) { + cur = variance_dev.noise; + variance_dev.flags &= ~VAR_SUBMITNOISE; + } else { + if (pthres_read(ts, &cur, 1) < 1) + return count; + } + + if (cur.pressure == 0) { + /* Flush the queue immediately when the pen is just + * released, otherwise the previous layer will + * get the pen up notification too late. This + * will happen if info->next->ops->read() blocks. + */ + if (variance_dev.flags & VAR_PENDOWN) { + variance_dev.flags |= VAR_SUBMITNOISE; + variance_dev.noise = cur; + } + /* Reset the state machine on pen up events. */ + variance_dev.flags &= ~(VAR_PENDOWN | VAR_NOISEVALID | VAR_LASTVALID); + goto acceptsample; + } else + variance_dev.flags |= VAR_PENDOWN; + + if (!(variance_dev.flags & VAR_LASTVALID)) { + variance_dev.last = cur; + variance_dev.flags |= VAR_LASTVALID; + continue; + } + + if (variance_dev.flags & VAR_PENDOWN) { + /* Compute the distance between last sample and current */ + dist = SQR (cur.x - variance_dev.last.x) + + SQR (cur.y - variance_dev.last.y); + + if (dist > variance_dev.delta) { + /* Do we suspect the previous sample was a noise? */ + if (variance_dev.flags & VAR_NOISEVALID) { + /* Two "noises": it's just a quick pen movement */ + samp [count++] = variance_dev.last = variance_dev.noise; + variance_dev.flags = (variance_dev.flags & ~VAR_NOISEVALID) | + VAR_SUBMITNOISE; + + //DKS - flush sample history in averaging module + *flush_history = 1; + } else + variance_dev.flags |= VAR_NOISEVALID; + + /* The pen jumped too far, maybe it's a noise ... */ + variance_dev.noise = cur; + continue; + } else + variance_dev.flags &= ~VAR_NOISEVALID; + } + +acceptsample: +//#ifdef DEBUG +// fprintf(stderr,"VARIANCE----------------> %d %d %d\n", +// var->last.x, var->last.y, var->last.pressure); +//#endif + samp [count++] = variance_dev.last; + variance_dev.last = cur; + } + + return count; +} + + +/****************************** + * dejitter + ******************************/ + +//#define NR_SAMPHISTLEN 4 +//static const unsigned char weight[NR_SAMPHISTLEN - 1][NR_SAMPHISTLEN + 1] = +// { +// // DKS - experiment.. the last of each row is the number 2^x that we should divide by, +// // the first four numbers in each row should add up to 2^x +//// {5, 3, 0, 0, 3}, +//// {8, 5, 3, 0, 4}, +//// {6, 4, 3, 3, 4} +// {1, 3, 2, 2, 3}, +// {2, 6, 4, 4, 4}, +// {6, 4, 3, 3, 4} +// }; +// +//typedef struct ts_hist { +// int x; +// int y; +// unsigned int p; +//} TS_HIST; +// +//typedef struct tslib_dejitter { +// int delta; +// int x; +// int y; +// int down; +// int nr; +// int head; +// TS_HIST hist[NR_SAMPHISTLEN]; +//} TSLIB_DEJITTER; +// +//TSLIB_DEJITTER dejitter_dev; +// +//static int dejitter_limit(char *str, void *data) +//{ +// unsigned long v; +// int err = errno; +// +// v = strtoul(str, NULL, 0); +// if (v == ULONG_MAX && errno == ERANGE) +// return -1; +// errno = err; +// switch ((int)data) { +// case 1: +// dejitter_dev.delta = v; +// break; +// default: +// return -1; +// } +// return 0; +//} +// +//static const TSLIB_VARS dejitter_vars[] = { +// {"delta", (void *)1, dejitter_limit} +//}; +// +//#define NR_DEJITTER_VARS (sizeof(dejitter_vars) / sizeof(dejitter_vars[0])) + +//DKS - changing to use SQR macro, not that it matters here +//int dejitter_init(const char *params) +//{ +// int ret = 0; +// +// bzero(&dejitter_dev, sizeof(dejitter_dev)); +// dejitter_dev.delta = 100; +// dejitter_dev.head = 0; +// if (tslib_parse_vars(dejitter_vars, NR_DEJITTER_VARS, params)) { +// ret = 1; +// } +// dejitter_dev.delta = sqr(dejitter_dev.delta); +// +// return ret; +//} +//int dejitter_init(const char *params) +//{ +// int ret = 0; +// +// bzero(&dejitter_dev, sizeof(dejitter_dev)); +// dejitter_dev.delta = 100; +// dejitter_dev.head = 0; +// if (tslib_parse_vars(dejitter_vars, NR_DEJITTER_VARS, params)) { +// ret = 1; +// } +//// dejitter_dev.delta = sqr(dejitter_dev.delta); +// dejitter_dev.delta = SQR(dejitter_dev.delta); +// +// return ret; +//} + +//static void average(TS_SAMPLE *samp) +//{ +// const unsigned char *w; +// int sn = dejitter_dev.head; +// int i, x = 0, y = 0; +// unsigned int p = 0; +// +// w = weight[dejitter_dev.nr - 2]; +// +// for (i = 0; i < dejitter_dev.nr; i++) { +// x += dejitter_dev.hist[sn].x * w[i]; +// y += dejitter_dev.hist[sn].y * w[i]; +// p += dejitter_dev.hist[sn].p * w[i]; +// sn = (sn - 1) & (NR_SAMPHISTLEN - 1); +// } +// +// samp->x = x >> w[NR_SAMPHISTLEN]; +// samp->y = y >> w[NR_SAMPHISTLEN]; +// samp->pressure = p >> w[NR_SAMPHISTLEN]; +//} +// +//static int dejitter_read(TSDEV *ts, TS_SAMPLE *samp) +//{ +//#ifdef DKS_DEBUG +// dejitter_dev.delta = tslib_dejitter; +// if (tslib_skipdejitter) { +// return (variance_read(ts, samp)); +// } +//#endif +// TS_SAMPLE *s; +// int count = 0, ret; +// +// ret = variance_read(ts, samp); +// for (s = samp; ret > 0; s++, ret--) { +// if (s->pressure == 0) { +// dejitter_dev.nr = 0; +// samp[count++] = *s; +// continue; +// } +// +// if (dejitter_dev.nr) { +// int prev = (dejitter_dev.head - 1) & (NR_SAMPHISTLEN - 1); +// if (sqr(s->x - dejitter_dev.hist[prev].x) + +// sqr(s->y - dejitter_dev.hist[prev].y) > dejitter_dev.delta) +// dejitter_dev.nr = 0; +// } +// +// dejitter_dev.hist[dejitter_dev.head].x = s->x; +// dejitter_dev.hist[dejitter_dev.head].y = s->y; +// dejitter_dev.hist[dejitter_dev.head].p = s->pressure; +// if (dejitter_dev.nr < NR_SAMPHISTLEN) +// dejitter_dev.nr++; +// +// if (dejitter_dev.nr == 1) +// samp[count] = *s; +// else { +// average(samp + count); +// samp[count].tv = s->tv; +// } +// count++; +// dejitter_dev.head = (dejitter_dev.head + 1) & (NR_SAMPHISTLEN - 1); +// } +// +// return count; +//} + +//DKS - gonna do my own de-jitterer that can handle high noise level of the GP2X +typedef struct { + int x; + int y; +} XYHIST; + +#define XYHISTLENGTH 15 +XYHIST average_xyhist[XYHISTLENGTH]; + +static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + + int ret = 0; + int newx, newy; + + int flush_history = 0; // variance module will tell us if we are getting fast movements + static int flush_count = 0; // when we get enough fast movements, flush the history + static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 + static int xyhist_counter = 0; // DKS - how many entires in history? + static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array + + ret = variance_read(ts, samp, nr, &flush_history); + flush_count += flush_history; + struct ts_sample *s; + s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x + // touchscreen driver only ever provides 1 sample each read so + // it's not really necessary but not really inefficient either way + int i; + + for( i = ret; i > 0; i--, s--) { + if ((s->pressure == 0) || (flush_count > 7)) { + // when pen is lifted, or a fast movement is detected, flush stored history + xyhist_full = 0; + xyhist_counter = 0; + xyhist_index = 0; + flush_count = 0; + } else { + average_xyhist[xyhist_index].x = s->x; + average_xyhist[xyhist_index].y = s->y; + + xyhist_counter++; + if (xyhist_counter == XYHISTLENGTH) { + xyhist_full = 1; + } + + xyhist_index++; + if (xyhist_index == XYHISTLENGTH) { + xyhist_index = 0; // point back at beginning since array is full + } + + if (xyhist_full) { + //we have a full sample history, we can average this sample with the others + + int j = xyhist_index - 1; // point j to most recent entry in history + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // 15-sample weighted average, pyramid, provides great smoothing for precise + // operations like menus and drawing + + // sample 1 has weight of * 1 + newx = average_xyhist[j].x; + newy = average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 2 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 3 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 4 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 5 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 6 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 7 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 8, middle sample, has weight of * 8 + newx += (average_xyhist[j].x << 3); + newy += (average_xyhist[j].y << 3); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 9 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 10 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 11 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 12 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 13 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 14 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 15 has weight of * 1 + newx += average_xyhist[j].x; + newy += average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // divide results by 64 to provide average + samp->x = newx >> 6; + samp->y = newy >> 6; + } + } + } + + return ret; +} +//DKS - non-pyramid form of the above, I cannot tell a real difference, will use pyramid for now. +//#define XYHISTLENGTH 15 +//XYHIST average_xyhist[XYHISTLENGTH]; +// +//static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +//{ +// +// int ret = 0; +// int newx, newy; +// +// int flush_history = 0; // variance module will tell us if we are getting fast movements +// static int flush_count = 0; // when we get enough fast movements, flush the history +// static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 +// static int xyhist_counter = 0; // DKS - how many entires in history? +// static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array +// +// ret = variance_read(ts, samp, nr, &flush_history); +// flush_count += flush_history; +// struct ts_sample *s; +// s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x +// // touchscreen driver only ever provides 1 sample each read so +// // it's not really necessary but not really inefficient either way +// int i; +// +// for( i = ret; i > 0; i--, s--) { +// if ((s->pressure == 0) || (flush_count > 7)) { +// // when pen is lifted, or a fast movement is detected, flush stored history +// xyhist_full = 0; +// xyhist_counter = 0; +// xyhist_index = 0; +// flush_count = 0; +// } else { +// average_xyhist[xyhist_index].x = s->x; +// average_xyhist[xyhist_index].y = s->y; +// +// xyhist_counter++; +// if (xyhist_counter == XYHISTLENGTH) { +// xyhist_full = 1; +// } +// +// xyhist_index++; +// if (xyhist_index == XYHISTLENGTH) { +// xyhist_index = 0; // point back at beginning since array is full +// } +// +// if (xyhist_full) { +// //we have a full sample history, we can average this sample with the others +// +// int j = xyhist_index - 1; // point j to most recent entry in history +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // 15-sample weighted average, pyramid, provides great smoothing for precise +// // operations like menus and drawing +// +// // sample 1 has weight of * 15 +// newx = average_xyhist[j].x * 15; +// newy = average_xyhist[j].y * 15; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 2 has weight of * 14 +// newx += average_xyhist[j].x * 14; +// newy += average_xyhist[j].y * 14; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 3 has weight of * 13 +// newx += average_xyhist[j].x * 13; +// newy += average_xyhist[j].y * 13; +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 4 has weight of * 12 +// newx += average_xyhist[j].x * 12; +// newy += average_xyhist[j].y * 12; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 5 has weight of * 11 +// newx += average_xyhist[j].x * 11; +// newy += average_xyhist[j].y * 11; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 6 has weight of * 10 +// newx += average_xyhist[j].x * 10; +// newy += average_xyhist[j].y * 10; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 7 has weight of * 9 +// newx += average_xyhist[j].x * 9; +// newy += average_xyhist[j].y * 9; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 8, middle sample, has weight of * 8 +// newx += (average_xyhist[j].x << 3); +// newy += (average_xyhist[j].y << 3); +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 9 has weight of * 7 +// newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; +// newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 10 has weight of * 6 +// newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); +// newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 11 has weight of * 5 +// newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; +// newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 12 has weight of * 4 +// newx += average_xyhist[j].x << 2; +// newy += average_xyhist[j].y << 2; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 13 has weight of * 3 +// newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; +// newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 14 has weight of * 2 +// newx += average_xyhist[j].x << 1; +// newy += average_xyhist[j].y << 1; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// // sample 15 has weight of * 1 +// newx += average_xyhist[j].x; +// newy += average_xyhist[j].y; +// +// j--; +// if (j < 0) { +// j = XYHISTLENGTH - 1; +// } +// +// samp->x = newx / 120; +// samp->y = newy / 120; +// } +// } +// } +// +// return ret; +//} + +/****************************** + * linear + ******************************/ + +typedef struct tslib_linear { + int swap_xy; + int a[7]; +} TSLIB_LINEAR; + +TSLIB_LINEAR linear_dev; + +//DKS - don't need this anymore +//static int linear_xyswap(char *str, void *data) +//{ +// linear_dev.swap_xy = 1; +// return 0; +//} + +//DKS - don't need this anymore +//static const TSLIB_VARS linear_vars[] = { +// {"xyswap", (void *)1, linear_xyswap} +//}; +//#define NR_LINEAR_VARS (sizeof(linear_vars) / sizeof(linear_vars[0])) + +int linear_init(const char *params) +{ + struct stat sbuf; + int pcal_fd, ret = 0; + char pcalbuf[200]; + int index; + char *tokptr; + char *calfile=NULL; + char *defaultcalfile="/etc/pointercal"; + + /* set defaults to typical GP2X values */ + linear_dev.a[0] = 6203; + linear_dev.a[1] = 0; + linear_dev.a[2] = -1501397; + linear_dev.a[3] = 0; + linear_dev.a[4] = -4200; + linear_dev.a[5] = 16132680; + linear_dev.a[6] = 65536; + // DKS +// linear_dev.swap_xy = 0; + + + //DKS - new sanity checks for pointercal file having good values to fix segfault on empty /etc/pointercal +// if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; +// if (stat(calfile, &sbuf) == 0) { +// pcal_fd = open(calfile, O_RDONLY); +// read(pcal_fd, pcalbuf, 200); +// linear_dev.a[0] = atoi(strtok(pcalbuf, " ")); +// index = 1; +// while (index < 7) { +// tokptr = strtok(NULL, " "); +// if (*tokptr != '\0') { +// linear_dev.a[index] = atoi(tokptr); +// index++; +// } +// } +// close(pcal_fd); +// } + + TSLIB_LINEAR tmp_linear_dev; + memset(pcalbuf, 0, 200); + int got_good_values = 1; // only when this remains 1 throughout reading of /etc/pointercal will values be accepted into driver + + if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; + if (stat(calfile, &sbuf) == 0) { + pcal_fd = open(calfile, O_RDONLY); + if (pcal_fd != -1) { + int bytes_read = read(pcal_fd, pcalbuf, 200); + if (bytes_read > 0) { + tokptr = strtok(pcalbuf, " "); + if (tokptr && (isdigit(*tokptr) || (*tokptr == '-'))) { + tmp_linear_dev.a[0] = atoi(tokptr); + index = 1; + while ((index < 7) && got_good_values) { + tokptr = strtok(NULL, " "); + if (tokptr && (isdigit(*tokptr) || (*tokptr == '-'))) { + tmp_linear_dev.a[index] = atoi(tokptr); + index++; + } else { + got_good_values = 0; + } + } + } else { + got_good_values = 0; + } + } else { + got_good_values = 0; + } + + close(pcal_fd); + + } else { + got_good_values = 0; + } + + if (got_good_values) { + linear_dev = tmp_linear_dev; + fprintf(stderr, "Successfully loaded saved touchscreen calibration values.\n"); + } else { + fprintf(stderr, "Error loading saved touchscreen calibration, using default values\n"); + } + } + // DKS +// if (tslib_parse_vars(linear_vars, NR_LINEAR_VARS, params)) +// ret = -1; + + return ret; +} + + +//DKS - last known working copy, before conversion to multi-sample +//int linear_read(TSDEV *ts, TS_SAMPLE *samp) +//{ +// int ret; +// int xtemp, ytemp; +// +// //DKS - experimenting with my own filter +//// ret = dejitter_read(ts, samp); +// ret = average_read(ts, samp); +// //DKS - why not try averaging after linear instead of before? +//// ret = variance_read(ts, samp); +// if (ret >= 0) { +// xtemp = samp->x; +// ytemp = samp->y; +// if (linear_dev.a[6] == 65536) { +// samp->x = (linear_dev.a[2] + +// linear_dev.a[0] * xtemp) >> 16; +// samp->y = (linear_dev.a[5] + +// linear_dev.a[4] * ytemp) >> 16; +// } else { +// samp->x = (linear_dev.a[2] + +// linear_dev.a[0] * xtemp) / linear_dev.a[6]; +// samp->y = (linear_dev.a[5] + +// linear_dev.a[4] * ytemp) / linear_dev.a[6]; +// } +// +// //DKS - why was this enabled? I hope this isn't related to the MK2 F200's swapping problem +// +//// if (linear_dev.swap_xy) { +//// int tmp = samp->x; +//// samp->x = samp->y; +//// samp->y = tmp; +//// } +// } +// +// return ret; +//} +static inline int linear_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + int ret; + +//// ret = dejitter_read(ts, samp); + ret = average_read(ts, samp, nr); + + if (ret > 0) { + if (linear_dev.a[6] == 65536) { + samp->x = (linear_dev.a[2] + + linear_dev.a[0] * samp->x) >> 16; + samp->y = (linear_dev.a[5] + + linear_dev.a[4] * samp->y) >> 16; + } else { + samp->x = (linear_dev.a[2] + + linear_dev.a[0] * samp->x) / linear_dev.a[6]; + samp->y = (linear_dev.a[5] + + linear_dev.a[4] * samp->y) / linear_dev.a[6]; + } + } + + return ret; +} + +/****************************** + * ts_read + ******************************/ + +int ts_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + // DKS - original line: +// ret = linear_read(ts, samp); + return(linear_read(ts, samp, nr)); +} + + +/* + * ts_config + */ + +#define BUF_SIZE 512 +static const char *DEFAULT_TSLIB_CONF[] = { + "module pthres pmin=1", + "module variance delta=30", + // //DKS +// "module dejitter delta=100", + "module linear", + NULL +}; +const char *sep = " \t"; + +char *ts_fgets(char *buf, int size, FILE *f, int line) +{ + char *ret; + + if (f) + ret = fgets(buf, size, f); + else { + if (DEFAULT_TSLIB_CONF[line] == NULL) + ret = NULL; + else + ret = strcpy(buf, DEFAULT_TSLIB_CONF[line]); + } + + return ret; +} + + +int ts_config(TSDEV *ts) +{ + char buf[BUF_SIZE], *p; + FILE *f; + int line = 0; + int ret = 0; + + char *conffile; + + if ((conffile = getenv("TSLIB_CONFFILE")) == NULL) { + conffile = "/etc/ts.conf"; + } + + f = fopen(conffile, "r"); + + buf[BUF_SIZE - 2] = '\0'; + while ((p = ts_fgets(buf, BUF_SIZE, f, line)) != NULL) { + char *e; + char *tok; + char *module_name; + + line++; + e = strchr(p, '\n'); + if (e) + *e = '\0'; + + if (buf[BUF_SIZE - 2] != '\0') { + fprintf(stderr, "%s: line %d too long\n", conffile, line); + break; + } + + tok = strsep(&p, sep); + if (p == NULL || *tok == '#') + continue; + + if (strcasecmp(tok, "module") == 0) { + module_name = strsep(&p, sep); + ret = ts_load_module(ts, module_name, p); + } else if (strcasecmp(tok, "module_raw") == 0) { + module_name = strsep(&p, sep); + ret = 0; /* ignore */ + } else { + fprintf(stderr, "%s: Unrecognised option %s at line %d\n", + conffile, tok, line); + break; + } + if (ret != 0) { + fprintf(stderr, "Couldn't load module %s\n", module_name); + break; + } + } + + if (f) fclose(f); + + return ret; +} + + +int ts_load_module(TSDEV *ts, const char *module, const char *p) +{ + int ret; + + +// if (!strcmp(module, "pthres")) +//DKS - disabled this, no initialization needed +// ret = pthres_init(p); + if (!strcmp(module, "variance")) + ret = variance_init(p); +// else if (!strcmp(module, "dejitter")) +// DKS - dejitter module disabled +// ret = dejitter_init(p); + else if (!strcmp(module, "linear")) + ret = linear_init(p); + else + ret = 0; + + return ret; +} + +char s_holder[1024]; + +int tslib_parse_vars(const TSLIB_VARS *vars, int nr, const char *str) +{ + char *s, *p; + int ret = 0; + + if (!str) + return 0; + + bzero(s_holder, 1024); + strncpy(s_holder, str, strlen(str)); + s = s_holder; + while ((p = strsep(&s, sep)) != NULL && ret == 0) { + const TSLIB_VARS *v; + char *eq; + + eq = strchr(p, '='); + if (eq) + *eq++ = '\0'; + + for (v = vars; v < vars + nr; v++) + if (strcasecmp(v->name, p) == 0) { + ret = v->fn(eq, v->data); + break; + } + } + + return ret; +} Added: trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/tslib.h 2008-12-20 19:40:44 UTC (rev 340) @@ -0,0 +1,93 @@ +#ifndef _TSLIB_H_ +#define _TSLIB_H_ +/* + * tslib/src/tslib.h + * + * Copyright (C) 2001 Russell King. + * + * This file is placed under the LGPL. + * + * $Id: tslib.h,v 1.4 2005/02/26 01:47:23 kergoth Exp $ + * + * Touch screen library interface definitions. + */ +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ +#include <stdarg.h> +#include <sys/time.h> + +#ifdef WIN32 + #define TSIMPORT __declspec(dllimport) + #define TSEXPORT __declspec(dllexport) + #define TSLOCAL +#else + #define TSIMPORT + #ifdef GCC_HASCLASSVISIBILITY + #define TSEXPORT __attribute__ ((visibility("default"))) + #define TSLOCAL __attribute__ ((visibility("hidden"))) + #else + #define TSEXPORT + #define TSLOCAL + #endif +#endif + +#ifdef TSLIB_INTERNAL + #define TSAPI TSEXPORT +#else + #define TSAPI TSIMPORT +#endif // TSLIB_INTERNAL + +struct tsdev; + +struct ts_sample { + int x; + int y; + unsigned int pressure; + struct timeval tv; +}; + +/* + * Close the touchscreen device, free all resources. + */ +TSAPI int ts_close(struct tsdev *); + +/* + * Configure the touchscreen device. + */ +TSAPI int ts_config(struct tsdev *); + +/* + * Change this hook to point to your custom error handling function. + */ +extern TSAPI int (*ts_error_fn)(const char *fmt, va_list ap); + +/* + * Returns the file descriptor in use for the touchscreen device. + */ +TSAPI int ts_fd(struct tsdev *); + +/* + * Load a filter/scaling module + */ +TSAPI int ts_load_module(struct tsdev *, const char *mod, const char *params); + +/* + * Open the touchscreen device. + */ +TSAPI struct tsdev *ts_open(const char *dev_name, int nonblock); + +/* + * Return a scaled touchscreen sample. + */ +TSAPI int ts_read(struct tsdev *, struct ts_sample *, int); + +/* + * Returns a raw, unscaled sample from the touchscreen. + */ +TSAPI int ts_read_raw(struct tsdev *, struct ts_sample *, int); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ +#endif /* _TSLIB_H_ */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-12-20 13:35:27
|
Revision: 339 http://open2x.svn.sourceforge.net/open2x/?rev=339&view=rev Author: senquack Date: 2008-12-20 13:35:18 +0000 (Sat, 20 Dec 2008) Log Message: ----------- Incorporated all latest improvements from 1.2.9/1.2.13 Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.11/configure trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_config.h trunk/libs-new/sdl/sdl/SDL-1.2.11/include/SDL_gp2x.h trunk/libs-new/sdl/sdl/SDL-1.2.11/sdl.pc trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xevents_c.h trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.c trunk/libs-new/sdl/sdl/SDL-1.2.11/src/video/gp2x/SDL_gp2xvideo.h trunk/libs-new/sdl/sdl/SDL-1.2.11/test/autom4te.cache/output.0 trunk/libs-new/sdl/sdl/SDL-1.2.11/test/autom4te.cache/requests trunk/libs-new/sdl/sdl/SDL-1.2.11/test/autom4te.cache/traces.0 trunk/libs-new/sdl/sdl/SDL-1.2.11/test/configure Modified: trunk/libs-new/sdl/sdl/SDL-1.2.11/configure =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.11/configure 2008-09-27 09:04:18 UTC (rev 338) +++ trunk/libs-new/sdl/sdl/SDL-1.2.11/configure 2008-12-20 13:35:18 UTC (rev 339) @@ -1,9 +1,9 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.61. +# Generated by GNU Autoconf 2.62. # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## --------------------- ## @@ -15,7 +15,7 @@ if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST @@ -37,19 +37,47 @@ as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - echo "#! /bin/sh" >conf$$.sh - echo "exit 0" >>conf$$.sh - chmod +x conf$$.sh - if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then - PATH_SEPARATOR=';' +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' else - PATH_SEPARATOR=: + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' fi - rm -f conf$$.sh + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' fi +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi + # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset @@ -63,8 +91,6 @@ # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) -as_nl=' -' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. @@ -87,7 +113,7 @@ as_myself=$0 fi if test ! -f "$as_myself"; then - echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi @@ -100,17 +126,10 @@ PS4='+ ' # NLS nuisances. -for as_var in \ - LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ - LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ - LC_TELEPHONE LC_TIME -do - if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then - eval $as_var=C; export $as_var - else - ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var - fi -done +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && @@ -132,7 +151,7 @@ $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || -echo X/"$0" | +$as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q @@ -158,7 +177,7 @@ as_have_required=no fi - if test $as_have_required = yes && (eval ": + if test $as_have_required = yes && (eval ": (as_func_return () { (exit \$1) } @@ -240,7 +259,7 @@ if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST @@ -261,7 +280,7 @@ if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST @@ -341,10 +360,10 @@ if test "x$CONFIG_SHELL" != x; then for as_var in BASH_ENV ENV - do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var - done - export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} + do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var + done + export CONFIG_SHELL + exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi @@ -413,9 +432,10 @@ test \$exitcode = 0") || { echo No shell found that supports shell functions. - echo Please tell aut...@gn... about your system, - echo including any error possibly output before this - echo message + echo Please tell bug...@gn... about your system, + echo including any error possibly output before this message. + echo This can help us improve future autoconf versions. + echo Configuration will now proceed without shell functions. } @@ -451,7 +471,7 @@ s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || - { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems @@ -479,7 +499,6 @@ *) ECHO_N='-n';; esac - if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr @@ -492,19 +511,22 @@ rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir - mkdir conf$$.dir + mkdir conf$$.dir 2>/dev/null fi -echo >conf$$.file -if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -p'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -p' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else as_ln_s='cp -p' -elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln + fi else as_ln_s='cp -p' fi @@ -529,10 +551,10 @@ as_test_x=' eval sh -c '\'' if test -d "$1"; then - test -d "$1/."; + test -d "$1/."; else case $1 in - -*)set "./$1";; + -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi @@ -804,6 +826,16 @@ build_alias host_alias target_alias +CC +CFLAGS +LDFLAGS +CPPFLAGS +ac_ct_CC +EXEEXT +OBJEXT +CPP +GREP +EGREP SDL_MAJOR_VERSION SDL_MINOR_VERSION SDL_MICRO_VERSION @@ -822,16 +854,6 @@ host_cpu host_vendor host_os -CC -CFLAGS -LDFLAGS -CPPFLAGS -ac_ct_CC -EXEEXT -OBJEXT -CPP -GREP -EGREP LN_S ECHO AR @@ -892,6 +914,94 @@ EXTRA_LDFLAGS LTLIBOBJS' ac_subst_files='' +ac_user_opts=' +enable_option_checking +enable_shared +enable_static +enable_fast_install +with_gnu_ld +enable_libtool_lock +with_pic +with_tags +enable_libc +enable_audio +enable_video +enable_events +enable_joystick +enable_cdrom +enable_threads +enable_timers +enable_file +enable_loadso +enable_cpuinfo +enable_assembly +enable_oss +enable_alsa +with_alsa_prefix +with_alsa_inc_prefix +enable_alsatest +enable_alsa_shared +enable_esd +with_esd_prefix +with_esd_exec_prefix +enable_esdtest +enable_esd_shared +enable_arts +enable_arts_shared +enable_nas +enable_diskaudio +enable_dummyaudio +enable_mintaudio +enable_nasm +enable_altivec +enable_ipod +enable_video_nanox +enable_nanox_debug +enable_nanox_share_memory +enable_nanox_direct_fb +enable_video_x11 +with_x +enable_x11_shared +enable_dga +enable_video_dga +enable_video_x11_dgamouse +enable_video_x11_vm +enable_video_x11_xv +enable_video_x11_xinerama +enable_video_x11_xme +enable_video_x11_xrandr +enable_video_x11_dpms +enable_video_photon +enable_video_carbon +enable_video_cocoa +enable_video_gp2x +enable_video_fbcon +enable_video_directfb +enable_video_ps2gs +enable_video_ggi +enable_video_svga +enable_video_vgl +enable_video_wscons +enable_video_aalib +enable_video_qtopia +enable_video_picogui +enable_xbios +enable_gem +enable_video_dummy +enable_video_opengl +enable_osmesa_shared +enable_input_events +enable_input_tslib +enable_pth +enable_pthreads +enable_pthread_sem +enable_stdio_redirect +enable_directx +enable_sdl_dlopen +enable_atari_ldg +enable_clock_gettime +enable_rpath +' ac_precious_vars='build_alias host_alias target_alias @@ -913,6 +1023,8 @@ # Initialize some variables set by options. ac_init_help= ac_init_version=false +ac_unrecognized_opts= +ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null @@ -1011,13 +1123,21 @@ datarootdir=$ac_optarg ;; -disable-* | --disable-*) - ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` + ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. - expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2 { (exit 1); exit 1; }; } - ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` - eval enable_$ac_feature=no ;; + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; @@ -1030,13 +1150,21 @@ dvidir=$ac_optarg ;; -enable-* | --enable-*) - ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` + ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. - expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid feature name: $ac_feature" >&2 + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2 { (exit 1); exit 1; }; } - ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` - eval enable_$ac_feature=\$ac_optarg ;; + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"enable_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ @@ -1227,22 +1355,38 @@ ac_init_version=: ;; -with-* | --with-*) - ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` + ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. - expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid package name: $ac_package" >&2 + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2 { (exit 1); exit 1; }; } - ac_package=`echo $ac_package | sed 's/[-.]/_/g'` - eval with_$ac_package=\$ac_optarg ;; + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) - ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` + ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. - expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid package name: $ac_package" >&2 + expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && + { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2 { (exit 1); exit 1; }; } - ac_package=`echo $ac_package | sed 's/[-.]/_/g'` - eval with_$ac_package=no ;; + ac_useropt_orig=$ac_useropt + ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + case $ac_user_opts in + *" +"with_$ac_useropt" +"*) ;; + *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" + ac_unrecognized_sep=', ';; + esac + eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. @@ -1262,7 +1406,7 @@ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; - -*) { echo "$as_me: error: unrecognized option: $ac_option + -*) { $as_echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; @@ -1271,16 +1415,16 @@ ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && - { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 + { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. - echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; @@ -1289,22 +1433,38 @@ if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` - { echo "$as_me: error: missing argument to $ac_option" >&2 + { $as_echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi -# Be sure to have absolute directory names. +if test -n "$ac_unrecognized_opts"; then + case $enable_option_checking in + no) ;; + fatal) { $as_echo "$as_me: error: Unrecognized options: $ac_unrecognized_opts" >&2 + { (exit 1); exit 1; }; } ;; + *) $as_echo "$as_me: WARNING: Unrecognized options: $ac_unrecognized_opts" >&2 ;; + esac +fi + +# Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var + # Remove trailing slashes. case $ac_val in + */ ) + ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` + eval $ac_var=\$ac_val;; + esac + # Be sure to have absolute directory names. + case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac - { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 + { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; } done @@ -1319,7 +1479,7 @@ if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe - echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. + $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes @@ -1335,10 +1495,10 @@ ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || - { echo "$as_me: error: Working directory cannot be determined" >&2 + { $as_echo "$as_me: error: Working directory cannot be determined" >&2 { (exit 1); exit 1; }; } test "X$ac_ls_di" = "X$ac_pwd_ls_di" || - { echo "$as_me: error: pwd does not report name of working directory" >&2 + { $as_echo "$as_me: error: pwd does not report name of working directory" >&2 { (exit 1); exit 1; }; } @@ -1346,12 +1506,12 @@ if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. - ac_confdir=`$as_dirname -- "$0" || -$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$0" : 'X\(//\)[^/]' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -echo X"$0" | + ac_confdir=`$as_dirname -- "$as_myself" || +$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_myself" : 'X\(//\)[^/]' \| \ + X"$as_myself" : 'X\(//\)$' \| \ + X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -1378,12 +1538,12 @@ fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." - { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 + { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( - cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2 + cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2 { (exit 1); exit 1; }; } pwd)` # When building in place, set srcdir=. @@ -1432,9 +1592,9 @@ Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX - [$ac_default_prefix] + [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX - [PREFIX] + [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify @@ -1444,25 +1604,25 @@ For better control, use the options below. Fine tuning of the installation directories: - --bindir=DIR user executables [EPREFIX/bin] - --sbindir=DIR system admin executables [EPREFIX/sbin] - --libexecdir=DIR program executables [EPREFIX/libexec] - --sysconfdir=DIR read-only single-machine data [PREFIX/etc] - --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] - --localstatedir=DIR modifiable single-machine data [PREFIX/var] - --libdir=DIR object code libraries [EPREFIX/lib] - --includedir=DIR C header files [PREFIX/include] - --oldincludedir=DIR C header files for non-gcc [/usr/include] - --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] - --datadir=DIR read-only architecture-independent data [DATAROOTDIR] - --infodir=DIR info documentation [DATAROOTDIR/info] - --localedir=DIR locale-dependent data [DATAROOTDIR/locale] - --mandir=DIR man documentation [DATAROOTDIR/man] - --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] - --htmldir=DIR html documentation [DOCDIR] - --dvidir=DIR dvi documentation [DOCDIR] - --pdfdir=DIR pdf documentation [DOCDIR] - --psdir=DIR ps documentation [DOCDIR] + --bindir=DIR user executables [EPREFIX/bin] + --sbindir=DIR system admin executables [EPREFIX/sbin] + --libexecdir=DIR program executables [EPREFIX/libexec] + --sysconfdir=DIR read-only single-machine data [PREFIX/etc] + --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] + --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --libdir=DIR object code libraries [EPREFIX/lib] + --includedir=DIR C header files [PREFIX/include] + --oldincludedir=DIR C header files for non-gcc [/usr/include] + --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] + --datadir=DIR read-only architecture-independent data [DATAROOTDIR] + --infodir=DIR info documentation [DATAROOTDIR/info] + --localedir=DIR locale-dependent data [DATAROOTDIR/locale] + --mandir=DIR man documentation [DATAROOTDIR/man] + --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] + --htmldir=DIR html documentation [DOCDIR] + --dvidir=DIR dvi documentation [DOCDIR] + --pdfdir=DIR pdf documentation [DOCDIR] + --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF @@ -1482,6 +1642,7 @@ cat <<\_ACEOF Optional Features: + --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-shared[=PKGS] build shared libraries [default=yes] @@ -1619,15 +1780,17 @@ if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue - test -d "$ac_dir" || continue + test -d "$ac_dir" || + { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || + continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) - ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; @@ -1663,7 +1826,7 @@ echo && $SHELL "$ac_srcdir/configure" --help=recursive else - echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done @@ -1673,10 +1836,10 @@ if $ac_init_version; then cat <<\_ACEOF configure -generated by GNU Autoconf 2.61 +generated by GNU Autoconf 2.62 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1687,7 +1850,7 @@ running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was -generated by GNU Autoconf 2.61. Invocation command line was +generated by GNU Autoconf 2.62. Invocation command line was $ $0 $@ @@ -1723,7 +1886,7 @@ do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - echo "PATH: $as_dir" + $as_echo "PATH: $as_dir" done IFS=$as_save_IFS @@ -1758,7 +1921,7 @@ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) - ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; @@ -1810,11 +1973,12 @@ case $ac_val in #( *${as_nl}*) case $ac_var in #( - *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 -echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; + *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 +$as_echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) $as_unset $ac_var ;; esac ;; esac @@ -1844,9 +2008,9 @@ do eval ac_val=\$$ac_var case $ac_val in - *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac - echo "$ac_var='\''$ac_val'\''" + $as_echo "$ac_var='\''$ac_val'\''" done | sort echo @@ -1861,9 +2025,9 @@ do eval ac_val=\$$ac_var case $ac_val in - *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac - echo "$ac_var='\''$ac_val'\''" + $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi @@ -1879,8 +2043,8 @@ echo fi test "$ac_signal" != 0 && - echo "$as_me: caught signal $ac_signal" - echo "$as_me: exit $exit_status" + $as_echo "$as_me: caught signal $ac_signal" + $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && @@ -1922,21 +2086,24 @@ # Let the site file select an alternate cache file if it wants to. -# Prefer explicitly selected file to automatically selected ones. +# Prefer an explicitly selected file to automatically selected ones. +ac_site_file1=NONE +ac_site_file2=NONE if test -n "$CONFIG_SITE"; then - set x "$CONFIG_SITE" + ac_site_file1=$CONFIG_SITE elif test "x$prefix" != xNONE; then - set x "$prefix/share/config.site" "$prefix/etc/config.site" + ac_site_file1=$prefix/share/config.site + ac_site_file2=$prefix/etc/config.site else - set x "$ac_default_prefix/share/config.site" \ - "$ac_default_prefix/etc/config.site" + ac_site_file1=$ac_default_prefix/share/config.site + ac_site_file2=$ac_default_prefix/etc/config.site fi -shift -for ac_site_file +for ac_site_file in "$ac_site_file1" "$ac_site_file2" do + test "x$ac_site_file" = xNONE && continue if test -r "$ac_site_file"; then - { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 -echo "$as_me: loading site script $ac_site_file" >&6;} + { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 +$as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi @@ -1946,16 +2113,16 @@ # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then - { echo "$as_me:$LINENO: loading cache $cache_file" >&5 -echo "$as_me: loading cache $cache_file" >&6;} + { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5 +$as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else - { echo "$as_me:$LINENO: creating cache $cache_file" >&5 -echo "$as_me: creating cache $cache_file" >&6;} + { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5 +$as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi @@ -1969,29 +2136,38 @@ eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) - { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} + { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) - { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 -echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} + { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 +$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then - { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 -echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 -echo "$as_me: former value: $ac_old_val" >&2;} - { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 -echo "$as_me: current value: $ac_new_val" >&2;} - ac_cache_corrupted=: + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 +$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 +$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { $as_echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5 +$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} + { $as_echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5 +$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in - *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in @@ -2001,10 +2177,10 @@ fi done if $ac_cache_corrupted; then - { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 -echo "$as_me: error: changes in the environment can compromise the build" >&2;} - { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 -echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} + { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 +$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} + { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 +$as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi @@ -2033,162 +2209,6 @@ ac_config_headers="$ac_config_headers include/SDL_config.h" - -cat >>confdefs.h <<\_ACEOF -#define _GNU_SOURCE 1 -_ACEOF - - - -# -# Making releases: -# Edit include/SDL/SDL_version.h and change the version, then: -# SDL_MICRO_VERSION += 1; -# SDL_INTERFACE_AGE += 1; -# SDL_BINARY_AGE += 1; -# if any functions have been added, set SDL_INTERFACE_AGE to 0. -# if backwards compatibility has been broken, -# set SDL_BINARY_AGE and SDL_INTERFACE_AGE to 0. -# -SDL_MAJOR_VERSION=1 -SDL_MINOR_VERSION=2 -SDL_MICRO_VERSION=11 -SDL_INTERFACE_AGE=0 -SDL_BINARY_AGE=11 -SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION - - - - - - - - -# libtool versioning -LT_RELEASE=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION -LT_CURRENT=`expr $SDL_MICRO_VERSION - $SDL_INTERFACE_AGE` -LT_REVISION=$SDL_INTERFACE_AGE -LT_AGE=`expr $SDL_BINARY_AGE - $SDL_INTERFACE_AGE` - - - - - - -ac_aux_dir= -for ac_dir in $srcdir/build-scripts; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir/build-scripts" >&5 -echo "$as_me: error: cannot find install-sh or install.sh in $srcdir/build-scripts" >&2;} - { (exit 1); exit 1; }; } -fi - -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. - - -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 -echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;} - { (exit 1); exit 1; }; } - -{ echo "$as_me:$LINENO: checking build system type" >&5 -echo $ECHO_N "checking build system type... $ECHO_C" >&6; } -if test "${ac_cv_build+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - ac_build_alias=$build_alias -test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` -test "x$ac_build_alias" = x && - { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 -echo "$as_me: error: cannot guess build type; you must specify one" >&2;} - { (exit 1); exit 1; }; } -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5 -echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;} - { (exit 1); exit 1; }; } - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5 -echo "${ECHO_T}$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5 -echo "$as_me: error: invalid value of canonical build" >&2;} - { (exit 1); exit 1; }; };; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac - - -{ echo "$as_me:$LINENO: checking host system type" >&5 -echo $ECHO_N "checking host system type... $ECHO_C" >&6; } -if test "${ac_cv_host+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 -else - if test "x$host_alias" = x; then - ac_cv_host=$ac_cv_build -else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5 -echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;} - { (exit 1); exit 1; }; } -fi - -fi -{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5 -echo "${ECHO_T}$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5 -echo "$as_me: error: invalid value of canonical host" >&2;} - { (exit 1); exit 1; }; };; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac - - ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -2197,10 +2217,10 @@ if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2213,7 +2233,7 @@ for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2224,11 +2244,11 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi @@ -2237,10 +2257,10 @@ ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. @@ -2253,7 +2273,7 @@ for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2264,11 +2284,11 @@ fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -echo "${ECHO_T}$ac_ct_CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then @@ -2276,10 +2296,10 @@ else case $cross_compiling:$ac_tool_warned in yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools +{ $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to aut...@gn...." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools +$as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to aut...@gn...." >&2;} ac_tool_warned=yes ;; @@ -2294,10 +2314,10 @@ if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2310,7 +2330,7 @@ for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2321,11 +2341,11 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi @@ -2334,10 +2354,10 @@ if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2355,7 +2375,7 @@ continue fi ac_cv_prog_CC="cc" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2378,11 +2398,11 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi @@ -2393,10 +2413,10 @@ do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. @@ -2409,7 +2429,7 @@ for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2420,11 +2440,11 @@ fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { echo "$as_me:$LINENO: result: $CC" >&5 -echo "${ECHO_T}$CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi @@ -2437,10 +2457,10 @@ do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ echo "$as_me:$LINENO: checking for $ac_word" >&5 -echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. @@ -2453,7 +2473,7 @@ for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" - echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -2464,11 +2484,11 @@ fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -echo "${ECHO_T}$ac_ct_CC" >&6; } + { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } else - { echo "$as_me:$LINENO: result: no" >&5 -echo "${ECHO_T}no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi @@ -2480,10 +2500,10 @@ else case $cross_compiling:$ac_tool_warned in yes:) -{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools +{ $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to aut...@gn...." >&5 -echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools +$as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to aut...@gn...." >&2;} ac_tool_warned=yes ;; @@ -2495,44 +2515,48 @@ fi -test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH +test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&5 -echo "$as_me: error: no acceptable C compiler found in \$PATH +$as_echo "$as_me: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } # Provide some information about the compiler. -echo "$as_me:$LINENO: checking for C compiler version" >&5 -ac_compiler=`set X $ac_compile; echo $2` +$as_echo "$as_me:$LINENO: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } cat >conftest.$ac_ext <<_ACEOF @@ -2551,27 +2575,22 @@ } _ACEOF ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files a.out a.exe b.out" +ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. -{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 -echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; } -ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` -# -# List of possible output files, starting from the most likely. -# The algorithm is not robust to junk in `.', hence go to wildcards (a.*) -# only as a last resort. b.out is created by i960 compilers. -ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out' -# -# The IRIX 6 linker writes into existing files which may not be -# executable, retaining their permissions. Remove them first so a -# subsequent execution test works. +{ $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 +$as_echo_n "checking for C compiler default output file name... " >&6; } +ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` + +# The possible output files: +ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" + ac_rmfiles= for ac_file in $ac_files do case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done @@ -2582,10 +2601,11 @@ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_link_default") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' @@ -2596,7 +2616,7 @@ do test -f "$ac_file" || continue case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most @@ -2623,15 +2643,15 @@ ac_file='' fi -{ echo "$as_me:$LINENO: result: $ac_file" >&5 -echo "${ECHO_T}$ac_file" >&6; } +{ $as_echo "$as_me:$LINENO: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } if test -z "$ac_file"; then - echo "$as_me: failed program was:" >&5 + $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -{ { echo "$as_me:$LINENO: error: C compiler cannot create executables +{ { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables See \`config.log' for more details." >&5 -echo "$as_me: error: C compiler cannot create executables +$as_echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; } fi @@ -2640,8 +2660,8 @@ # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. -{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5 -echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5 +$as_echo_n "checking whether the C compiler works... " >&6; } # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then @@ -2650,49 +2670,51 @@ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_try") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else - { { echo "$as_me:$LINENO: error: cannot run C compiled programs. + { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 -echo "$as_me: error: cannot run C compiled programs. +$as_echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi fi fi -{ echo "$as_me:$LINENO: result: yes" >&5 -echo "${ECHO_T}yes" >&6; } +{ $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } -rm -f a.out a.exe conftest$ac_cv_exeext b.out +rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. -{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 -echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; } -{ echo "$as_me:$LINENO: result: $cross_compiling" >&5 -echo "${ECHO_T}$cross_compiling" >&6; } +{ $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +{ $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } -{ echo "$as_me:$LINENO: checking for suffix of executables" >&5 -echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5 +$as_echo_n "checking for suffix of executables... " >&6; } if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_link") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will @@ -2701,31 +2723,31 @@ for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else - { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link + { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute suffix of executables: cannot compile and link +$as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext -{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 -echo "${ECHO_T}$ac_cv_exeext" >&6; } +{ $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 +$as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT -{ echo "$as_me:$LINENO: checking for suffix of object files" >&5 -echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5 +$as_echo_n "checking for suffix of object files... " >&6; } if test "${ac_cv_objext+set}" = set; then - echo $ECHO_N "(cached) $ECHO_C" >&6 + $as_echo_n "(cached) " >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ @@ -2748,40 +2770,41 @@ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac -eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 (eval "$ac_compile") 2>&5 ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;; + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else - echo "$as_me: failed program was:" >&5 + $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile +{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&5 -echo "$as_me: error: cannot compute suffix of object files: cannot compile +$as_echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi -{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 -echo "${ECHO_T}$ac_cv_objext" >&6; } +{ $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 +$as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT -{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 -echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; } +{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... [truncated message content] |
From: <or...@us...> - 2008-09-27 09:06:35
|
Revision: 338 http://open2x.svn.sourceforge.net/open2x/?rev=338&view=rev Author: orkie Date: 2008-09-27 09:04:18 +0000 (Sat, 27 Sep 2008) Log Message: ----------- Bring libs-new fully up to date Modified Paths: -------------- trunk/libs-new/Makefile trunk/libs-new/bzip2/1.0.3.mk trunk/libs-new/bzip2/1.0.4.mk trunk/libs-new/bzip2/1.0.5.mk trunk/libs-new/freetype/2.1.10.mk trunk/libs-new/freetype/2.3.5.mk trunk/libs-new/imlib2/1.2.2.mk trunk/libs-new/imlib2/1.4.0.mk trunk/libs-new/libexpat/2.0.1.mk trunk/libs-new/libiconv/1.11.mk trunk/libs-new/libiconv/1.12.mk trunk/libs-new/libid3tag/0.15.1b.mk trunk/libs-new/libjpeg/0.6b.mk trunk/libs-new/libmad/0.15.1b.mk trunk/libs-new/libmikmod/3.1.11.mk trunk/libs-new/libogg/1.1.3.mk trunk/libs-new/libpng/1.2.15.mk trunk/libs-new/libpng/1.2.23.mk trunk/libs-new/libpng/1.2.25.mk trunk/libs-new/libpng/1.2.8.mk trunk/libs-new/libtiff/3.8.2.mk trunk/libs-new/libungif/4.1.4.mk trunk/libs-new/libvorbis/1.1.2.mk trunk/libs-new/libvorbis/1.2.0.mk trunk/libs-new/libxml2/2.6.23.mk trunk/libs-new/libxml2/2.6.29.mk trunk/libs-new/libxml2/2.6.30.mk trunk/libs-new/libxml2/2.6.31.mk trunk/libs-new/libxml2/libxml2-2.6.31/xstc/Makefile trunk/libs-new/mpeg2dec/gp2x.mk trunk/libs-new/ncurses/5.5.mk trunk/libs-new/ncurses/5.6.mk trunk/libs-new/readline/5.1.mk trunk/libs-new/readline/5.2.mk trunk/libs-new/sdl/sdl/1.2.11.mk trunk/libs-new/sdl/sdl/1.2.9.mk trunk/libs-new/sdl/sdl/SDL-1.2.13/configure trunk/libs-new/sdl/sdl/SDL-1.2.13/include/SDL_config.h trunk/libs-new/sdl/sdl_gfx/2.0.13.mk trunk/libs-new/sdl/sdl_gfx/2.0.15.mk trunk/libs-new/sdl/sdl_gfx/2.0.16.mk trunk/libs-new/sdl/sdl_image/1.2.4.mk trunk/libs-new/sdl/sdl_image/1.2.6.mk trunk/libs-new/sdl/sdl_mixer/1.2.6.mk trunk/libs-new/sdl/sdl_mixer/1.2.7.mk trunk/libs-new/sdl/sdl_mixer/1.2.8.mk trunk/libs-new/sdl/sdl_svg/1.1.9.mk trunk/libs-new/sdl/sdl_ttf/2.0.7.mk trunk/libs-new/sdl/sdl_ttf/2.0.8.mk trunk/libs-new/sdl/sdl_ttf/2.0.9.mk trunk/libs-new/smpeg/0.4.4.mk trunk/libs-new/smpeg/cvs.mk trunk/libs-new/tremor/0.0.0.mk trunk/libs-new/tremor/19102007.mk trunk/libs-new/tremor/tremor-19102007/framing.c trunk/libs-new/zlib/1.2.3.mk Added Paths: ----------- trunk/libs-new/faad/ trunk/libs-new/faad/2.6.1.mk trunk/libs-new/faad/Makefile.mk trunk/libs-new/faad/faad2-2.6.1/ trunk/libs-new/faad/faad2-2.6.1/AUTHORS trunk/libs-new/faad/faad2-2.6.1/COPYING trunk/libs-new/faad/faad2-2.6.1/ChangeLog trunk/libs-new/faad/faad2-2.6.1/INSTALL trunk/libs-new/faad/faad2-2.6.1/Makefile trunk/libs-new/faad/faad2-2.6.1/Makefile.am trunk/libs-new/faad/faad2-2.6.1/Makefile.in trunk/libs-new/faad/faad2-2.6.1/NEWS trunk/libs-new/faad/faad2-2.6.1/README trunk/libs-new/faad/faad2-2.6.1/README.linux trunk/libs-new/faad/faad2-2.6.1/TODO trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/ trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/Script.rc trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/aacDECdrop/ trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/aacDECdrop/aacDECdrop.dsp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/aacDECdrop/aacDECdrop.dsw trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/aacDECdrop/aacDECdrop.sln trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/aacDECdrop/aacDECdrop.vcproj trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/audio.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/audio.h trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/decode.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/decode.h trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/decthread.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/decthread.h trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/main.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/misc.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/misc.h trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/ trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC01.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC01.ico trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC02.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC03.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC04.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC05.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC06.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC07.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource/AAC08.bmp trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/resource.h trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/wave_out.c trunk/libs-new/faad/faad2-2.6.1/aacDECdrop/wave_out.h trunk/libs-new/faad/faad2-2.6.1/aclocal.m4 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/ trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/output.0 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/output.1 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/output.2 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/requests trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/traces.0 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/traces.1 trunk/libs-new/faad/faad2-2.6.1/autom4te.cache/traces.2 trunk/libs-new/faad/faad2-2.6.1/bootstrap trunk/libs-new/faad/faad2-2.6.1/common/ trunk/libs-new/faad/faad2-2.6.1/common/Makefile trunk/libs-new/faad/faad2-2.6.1/common/Makefile.am trunk/libs-new/faad/faad2-2.6.1/common/Makefile.in trunk/libs-new/faad/faad2-2.6.1/common/faad/ trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.c trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.dsp trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.dsw trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.h trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.sln trunk/libs-new/faad/faad2-2.6.1/common/faad/aacinfo.vcproj trunk/libs-new/faad/faad2-2.6.1/common/faad/filestream.c trunk/libs-new/faad/faad2-2.6.1/common/faad/filestream.h trunk/libs-new/faad/faad2-2.6.1/common/faad/getopt.c trunk/libs-new/faad/faad2-2.6.1/common/faad/getopt.h trunk/libs-new/faad/faad2-2.6.1/common/faad/id3v2tag.c trunk/libs-new/faad/faad2-2.6.1/common/faad/id3v2tag.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/ trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/ trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-drms.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4atom.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4ff.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4meta.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4sample.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4tagupdate.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/.deps/libmp4ff_la-mp4util.Plo trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/Makefile trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/Makefile.am trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/Makefile.in trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/drms.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/drms.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/drmstables.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4atom.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ff.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ff.dsp trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ff.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ff.vcproj trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ff_int_types.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4ffint.h trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4meta.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4sample.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4tagupdate.c trunk/libs-new/faad/faad2-2.6.1/common/mp4ff/mp4util.c trunk/libs-new/faad/faad2-2.6.1/config.guess trunk/libs-new/faad/faad2-2.6.1/config.h trunk/libs-new/faad/faad2-2.6.1/config.h.in trunk/libs-new/faad/faad2-2.6.1/config.log trunk/libs-new/faad/faad2-2.6.1/config.status trunk/libs-new/faad/faad2-2.6.1/config.sub trunk/libs-new/faad/faad2-2.6.1/configure trunk/libs-new/faad/faad2-2.6.1/configure.in trunk/libs-new/faad/faad2-2.6.1/depcomp trunk/libs-new/faad/faad2-2.6.1/docs/ trunk/libs-new/faad/faad2-2.6.1/docs/Ahead AAC Decoder library documentation.doc trunk/libs-new/faad/faad2-2.6.1/docs/Ahead AAC Decoder library documentation.pdf trunk/libs-new/faad/faad2-2.6.1/faad2.spec trunk/libs-new/faad/faad2-2.6.1/faad2.spec.in trunk/libs-new/faad/faad2-2.6.1/frontend/ trunk/libs-new/faad/faad2-2.6.1/frontend/.deps/ trunk/libs-new/faad/faad2-2.6.1/frontend/.deps/audio.Po trunk/libs-new/faad/faad2-2.6.1/frontend/.deps/getopt.Po trunk/libs-new/faad/faad2-2.6.1/frontend/.deps/main.Po trunk/libs-new/faad/faad2-2.6.1/frontend/Makefile trunk/libs-new/faad/faad2-2.6.1/frontend/Makefile.am trunk/libs-new/faad/faad2-2.6.1/frontend/Makefile.in trunk/libs-new/faad/faad2-2.6.1/frontend/audio.c trunk/libs-new/faad/faad2-2.6.1/frontend/audio.h trunk/libs-new/faad/faad2-2.6.1/frontend/faad.dsp trunk/libs-new/faad/faad2-2.6.1/frontend/faad.dsw trunk/libs-new/faad/faad2-2.6.1/frontend/faad.sln trunk/libs-new/faad/faad2-2.6.1/frontend/faad.vcproj trunk/libs-new/faad/faad2-2.6.1/frontend/main.c trunk/libs-new/faad/faad2-2.6.1/in_mpeg4aac.nsi trunk/libs-new/faad/faad2-2.6.1/include/ trunk/libs-new/faad/faad2-2.6.1/include/faad.h trunk/libs-new/faad/faad2-2.6.1/include/neaacdec.h trunk/libs-new/faad/faad2-2.6.1/install-sh trunk/libs-new/faad/faad2-2.6.1/libfaad/ trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/bits.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/cfft.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/common.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/decoder.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/drc.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/drm_dec.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/error.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/filtbank.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/hcr.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/huffman.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ic_predict.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/is.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/lt_predict.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/mdct.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/mp4.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ms.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/output.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/pns.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ps_dec.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ps_syntax.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/pulse.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/rvlc.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_dct.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_dec.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_e_nf.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_fbt.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_hfadj.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_hfgen.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_huff.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_qmf.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_syntax.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/sbr_tf_grid.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/specrec.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ssr.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ssr_fb.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/ssr_ipqf.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/syntax.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/.deps/tns.Plo trunk/libs-new/faad/faad2-2.6.1/libfaad/Makefile trunk/libs-new/faad/faad2-2.6.1/libfaad/Makefile.am trunk/libs-new/faad/faad2-2.6.1/libfaad/Makefile.in trunk/libs-new/faad/faad2-2.6.1/libfaad/analysis.h trunk/libs-new/faad/faad2-2.6.1/libfaad/bits.c trunk/libs-new/faad/faad2-2.6.1/libfaad/bits.h trunk/libs-new/faad/faad2-2.6.1/libfaad/cfft.c trunk/libs-new/faad/faad2-2.6.1/libfaad/cfft.h trunk/libs-new/faad/faad2-2.6.1/libfaad/cfft_tab.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/ trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_1.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_10.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_11.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_2.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_3.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_4.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_5.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_6.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_7.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_8.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_9.h trunk/libs-new/faad/faad2-2.6.1/libfaad/codebook/hcb_sf.h trunk/libs-new/faad/faad2-2.6.1/libfaad/common.c trunk/libs-new/faad/faad2-2.6.1/libfaad/common.h trunk/libs-new/faad/faad2-2.6.1/libfaad/decoder.c trunk/libs-new/faad/faad2-2.6.1/libfaad/decoder.h trunk/libs-new/faad/faad2-2.6.1/libfaad/drc.c trunk/libs-new/faad/faad2-2.6.1/libfaad/drc.h trunk/libs-new/faad/faad2-2.6.1/libfaad/drm_dec.c trunk/libs-new/faad/faad2-2.6.1/libfaad/drm_dec.h trunk/libs-new/faad/faad2-2.6.1/libfaad/error.c trunk/libs-new/faad/faad2-2.6.1/libfaad/error.h trunk/libs-new/faad/faad2-2.6.1/libfaad/filtbank.c trunk/libs-new/faad/faad2-2.6.1/libfaad/filtbank.h trunk/libs-new/faad/faad2-2.6.1/libfaad/fixed.h trunk/libs-new/faad/faad2-2.6.1/libfaad/hcr.c trunk/libs-new/faad/faad2-2.6.1/libfaad/huffman.c trunk/libs-new/faad/faad2-2.6.1/libfaad/huffman.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ic_predict.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ic_predict.h trunk/libs-new/faad/faad2-2.6.1/libfaad/iq_table.h trunk/libs-new/faad/faad2-2.6.1/libfaad/is.c trunk/libs-new/faad/faad2-2.6.1/libfaad/is.h trunk/libs-new/faad/faad2-2.6.1/libfaad/kbd_win.h trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad.dsp trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad.dsw trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad.sln trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad.vcproj trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2.def trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2.vcp trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2.vcw trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2_dll.dsp trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2_dll.dsw trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2_dll.sln trunk/libs-new/faad/faad2-2.6.1/libfaad/libfaad2_dll.vcproj trunk/libs-new/faad/faad2-2.6.1/libfaad/lt_predict.c trunk/libs-new/faad/faad2-2.6.1/libfaad/lt_predict.h trunk/libs-new/faad/faad2-2.6.1/libfaad/mdct.c trunk/libs-new/faad/faad2-2.6.1/libfaad/mdct.h trunk/libs-new/faad/faad2-2.6.1/libfaad/mdct_tab.h trunk/libs-new/faad/faad2-2.6.1/libfaad/mp4.c trunk/libs-new/faad/faad2-2.6.1/libfaad/mp4.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ms.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ms.h trunk/libs-new/faad/faad2-2.6.1/libfaad/output.c trunk/libs-new/faad/faad2-2.6.1/libfaad/output.h trunk/libs-new/faad/faad2-2.6.1/libfaad/pns.c trunk/libs-new/faad/faad2-2.6.1/libfaad/pns.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ps_dec.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ps_dec.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ps_syntax.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ps_tables.h trunk/libs-new/faad/faad2-2.6.1/libfaad/pulse.c trunk/libs-new/faad/faad2-2.6.1/libfaad/pulse.h trunk/libs-new/faad/faad2-2.6.1/libfaad/rvlc.c trunk/libs-new/faad/faad2-2.6.1/libfaad/rvlc.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_dct.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_dct.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_dec.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_dec.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_e_nf.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_e_nf.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_fbt.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_fbt.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_hfadj.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_hfadj.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_hfgen.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_hfgen.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_huff.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_huff.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_noise.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_qmf.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_qmf.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_qmf_c.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_syntax.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_syntax.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_tf_grid.c trunk/libs-new/faad/faad2-2.6.1/libfaad/sbr_tf_grid.h trunk/libs-new/faad/faad2-2.6.1/libfaad/sine_win.h trunk/libs-new/faad/faad2-2.6.1/libfaad/specrec.c trunk/libs-new/faad/faad2-2.6.1/libfaad/specrec.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr_fb.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr_fb.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr_ipqf.c trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr_ipqf.h trunk/libs-new/faad/faad2-2.6.1/libfaad/ssr_win.h trunk/libs-new/faad/faad2-2.6.1/libfaad/structs.h trunk/libs-new/faad/faad2-2.6.1/libfaad/syntax.c trunk/libs-new/faad/faad2-2.6.1/libfaad/syntax.h trunk/libs-new/faad/faad2-2.6.1/libfaad/tns.c trunk/libs-new/faad/faad2-2.6.1/libfaad/tns.h trunk/libs-new/faad/faad2-2.6.1/libtool trunk/libs-new/faad/faad2-2.6.1/ltmain.sh trunk/libs-new/faad/faad2-2.6.1/missing trunk/libs-new/faad/faad2-2.6.1/plugins/ trunk/libs-new/faad/faad2-2.6.1/plugins/Makefile trunk/libs-new/faad/faad2-2.6.1/plugins/Makefile.am trunk/libs-new/faad/faad2-2.6.1/plugins/Makefile.in trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/ trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDFAAD.c trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDFAAD.dsp trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDFAAD.dsw trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDInputDLL.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDModDefs.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/QCDModInput.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/ReadMe.txt trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/logo.bmp trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/plugin_dlg.rc trunk/libs-new/faad/faad2-2.6.1/plugins/QCD/resource.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/ trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDInputDLL.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDModDefs.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDModInput.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDModTagEditor.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.c trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.dsp trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.dsw trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.rc trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.sln trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4.vcproj trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDMp4Tag.cpp trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/QCDTagsDLL.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/aac2mp4.cpp trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/aac2mp4.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/aacinfo.c trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/aacinfo.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/config.c trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/config.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/mbs.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/resource.h trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/utils.c trunk/libs-new/faad/faad2-2.6.1/plugins/QCDMp4/utils.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/ trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/aac2mp4.cpp trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/aac2mp4.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/aacinfo.c trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/aacinfo.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/config.c trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/config.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in2.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.c trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.dsp trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.dsw trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.rc trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.sln trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/in_mp4.vcproj trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/mbs.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/out.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/resource.h trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/utils.c trunk/libs-new/faad/faad2-2.6.1/plugins/in_mp4/utils.h trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/ trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/.deps/ trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/.deps/aa_file.Plo trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/.deps/faad2.Plo trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/Makefile trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/Makefile.am trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/Makefile.in trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/README_WIN32.txt trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/aa_file.cpp trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/aa_file.h trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/faad2.cpp trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/faad2.h trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/faad2_plugin.dsp trunk/libs-new/faad/faad2-2.6.1/plugins/mpeg4ip/faad2_plugin.dsw trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/ trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/AUTHORS trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/ChangeLog trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/INSTALL trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/Makefile trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/Makefile.am trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/Makefile.in trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/NEWS trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/README trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/TODO trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/ trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/.deps/ trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/.deps/libmp4_la-aac_utils.Plo trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/.deps/libmp4_la-libmp4.Plo trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/.deps/libmp4_la-mp4_utils.Plo trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/Makefile trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/Makefile.am trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/Makefile.in trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/aac_utils.c trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/libmp4.c trunk/libs-new/faad/faad2-2.6.1/plugins/xmms/src/mp4_utils.c trunk/libs-new/faad/faad2-2.6.1/stamp-h1 trunk/libs-new/flac/ trunk/libs-new/flac/1.2.1.mk trunk/libs-new/flac/Makefile.mk trunk/libs-new/flac/flac-1.2.1/ trunk/libs-new/flac/flac-1.2.1/AUTHORS trunk/libs-new/flac/flac-1.2.1/COPYING.FDL trunk/libs-new/flac/flac-1.2.1/COPYING.GPL trunk/libs-new/flac/flac-1.2.1/COPYING.LGPL trunk/libs-new/flac/flac-1.2.1/COPYING.Xiph trunk/libs-new/flac/flac-1.2.1/FLAC.dsw trunk/libs-new/flac/flac-1.2.1/FLAC.sln trunk/libs-new/flac/flac-1.2.1/Makefile trunk/libs-new/flac/flac-1.2.1/Makefile.am trunk/libs-new/flac/flac-1.2.1/Makefile.in trunk/libs-new/flac/flac-1.2.1/Makefile.lite trunk/libs-new/flac/flac-1.2.1/README trunk/libs-new/flac/flac-1.2.1/aclocal.m4 trunk/libs-new/flac/flac-1.2.1/all.dsp trunk/libs-new/flac/flac-1.2.1/all_dynamic.dsp trunk/libs-new/flac/flac-1.2.1/all_static.dsp trunk/libs-new/flac/flac-1.2.1/autogen.sh trunk/libs-new/flac/flac-1.2.1/build/ trunk/libs-new/flac/flac-1.2.1/build/Makefile trunk/libs-new/flac/flac-1.2.1/build/Makefile.am trunk/libs-new/flac/flac-1.2.1/build/Makefile.in trunk/libs-new/flac/flac-1.2.1/build/config.mk trunk/libs-new/flac/flac-1.2.1/build/exe.mk trunk/libs-new/flac/flac-1.2.1/build/lib.mk trunk/libs-new/flac/flac-1.2.1/config.guess trunk/libs-new/flac/flac-1.2.1/config.h trunk/libs-new/flac/flac-1.2.1/config.h.in trunk/libs-new/flac/flac-1.2.1/config.log trunk/libs-new/flac/flac-1.2.1/config.rpath trunk/libs-new/flac/flac-1.2.1/config.status trunk/libs-new/flac/flac-1.2.1/config.sub trunk/libs-new/flac/flac-1.2.1/configure trunk/libs-new/flac/flac-1.2.1/configure.in trunk/libs-new/flac/flac-1.2.1/depcomp trunk/libs-new/flac/flac-1.2.1/doc/ trunk/libs-new/flac/flac-1.2.1/doc/Doxyfile trunk/libs-new/flac/flac-1.2.1/doc/FLAC.tag trunk/libs-new/flac/flac-1.2.1/doc/Makefile trunk/libs-new/flac/flac-1.2.1/doc/Makefile.am trunk/libs-new/flac/flac-1.2.1/doc/Makefile.in trunk/libs-new/flac/flac-1.2.1/doc/Makefile.lite trunk/libs-new/flac/flac-1.2.1/doc/doxygen.footer.html trunk/libs-new/flac/flac-1.2.1/doc/doxygen.header.html trunk/libs-new/flac/flac-1.2.1/doc/html/ trunk/libs-new/flac/flac-1.2.1/doc/html/Makefile trunk/libs-new/flac/flac-1.2.1/doc/html/Makefile.am trunk/libs-new/flac/flac-1.2.1/doc/html/Makefile.in trunk/libs-new/flac/flac-1.2.1/doc/html/api/ trunk/libs-new/flac/flac-1.2.1/doc/html/api/+_2all_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/+_2export_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/+_2export_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/+_2metadata_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/+_2metadata_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/all_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/annotated.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/assert_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/callback_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/callback_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1File-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1File.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1File.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1Stream-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1Stream.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1Stream.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1Stream_1_1State-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Decoder_1_1Stream_1_1State.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1File-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1File.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1File.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1Stream-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1Stream.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1Stream.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1Stream_1_1State-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Encoder_1_1Stream_1_1State.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Application-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Application.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Application.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Chain-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Chain.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Chain_1_1Status-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Chain_1_1Status.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1CueSheet-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1CueSheet.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1CueSheet.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1CueSheet_1_1Track-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1CueSheet_1_1Track.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Iterator-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Iterator.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Padding-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Padding.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Padding.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Picture-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Picture.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Picture.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Prototype-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Prototype.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Prototype.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SeekTable-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SeekTable.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SeekTable.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SimpleIterator-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SimpleIterator.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SimpleIterator_1_1Status-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1SimpleIterator_1_1Status.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1StreamInfo-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1StreamInfo.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1StreamInfo.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Unknown-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Unknown.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1Unknown.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1VorbisComment-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1VorbisComment.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1VorbisComment.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1VorbisComment_1_1Entry-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classFLAC_1_1Metadata_1_1VorbisComment_1_1Entry.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/classes.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/decoder_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/decoder_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/dir_000000.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/dir_000001.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/dir_000002.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/dirs.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/doxygen.css trunk/libs-new/flac/flac-1.2.1/doc/html/api/doxygen.png trunk/libs-new/flac/flac-1.2.1/doc/html/api/encoder_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/encoder_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/export_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/export_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/files.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/format_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/format_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/functions.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/functions_func.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/functions_vars.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_0x66.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_0x67.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_defs.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_enum.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_eval.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_func.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_type.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/globals_vars.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__callbacks.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__decoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__encoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__export.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__format.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__metadata.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__metadata__level0.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__metadata__level1.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__metadata__level2.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__metadata__object.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__stream__decoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flac__stream__encoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__decoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__encoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__export.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__metadata.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__metadata__level0.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__metadata__level1.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__metadata__level2.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__flacpp__metadata__object.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__porting.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__porting__1__1__2__to__1__1__3.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__porting__1__1__3__to__1__1__4.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/group__porting__1__1__4__to__1__2__0.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/hierarchy.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/index.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/metadata_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/metadata_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/modules.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/ordinals_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/stream__decoder_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/stream__decoder_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/stream__encoder_8h-source.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/stream__encoder_8h.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod__PartitionedRice-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod__PartitionedRice.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod__PartitionedRiceContents-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____EntropyCodingMethod__PartitionedRiceContents.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Frame-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Frame.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____FrameFooter-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____FrameFooter.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____FrameHeader-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____FrameHeader.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____IOCallbacks-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____IOCallbacks.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamDecoder-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamDecoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamEncoder-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamEncoder.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Application-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Application.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet__Index-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet__Index.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet__Track-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__CueSheet__Track.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Padding-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Padding.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Picture-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Picture.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__SeekPoint-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__SeekPoint.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__SeekTable-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__SeekTable.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__StreamInfo-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__StreamInfo.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Unknown-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__Unknown.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__VorbisComment-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__VorbisComment.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__VorbisComment__Entry-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____StreamMetadata__VorbisComment__Entry.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Constant-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Constant.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Fixed-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Fixed.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__LPC-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__LPC.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Verbatim-members.html trunk/libs-new/flac/flac-1.2.1/doc/html/api/structFLAC____Subframe__Verbatim.html trunk/libs-new/flac/flac-1.2.1/doc/html/changelog.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__chopin_prelude_24.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__dream_theater_600.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__eddie_warner_titus.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__fanfare_de_l_eventail_de_jeanne.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__gloria_estefan_conga.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__hand_in_my_pocket.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__l_sub_raga_sivapriya.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__laetatus_sum.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__mummified_in_barbed_wire.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__prokofiev_pcon3_3.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__ravel_sq4_4.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__scarlatti_k42.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__tool_forty_six_and_2.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison__white_room.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison_all_cpudectime.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison_all_cpuenctime.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison_all_procdectime.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison_all_procenctime.html trunk/libs-new/flac/flac-1.2.1/doc/html/comparison_all_ratio.html trunk/libs-new/flac/flac-1.2.1/doc/html/developers.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_bugs.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_example_code.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_format_overview.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_tasks.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_tools.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_tools_flac.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_tools_metaflac.html trunk/libs-new/flac/flac-1.2.1/doc/html/documentation_tools_plugins.html trunk/libs-new/flac/flac-1.2.1/doc/html/download.html trunk/libs-new/flac/flac-1.2.1/doc/html/faq.html trunk/libs-new/flac/flac-1.2.1/doc/html/favicon.ico trunk/libs-new/flac/flac-1.2.1/doc/html/features.html trunk/libs-new/flac/flac-1.2.1/doc/html/flac.css trunk/libs-new/flac/flac-1.2.1/doc/html/format.html trunk/libs-new/flac/flac-1.2.1/doc/html/id.html trunk/libs-new/flac/flac-1.2.1/doc/html/images/ trunk/libs-new/flac/flac-1.2.1/doc/html/images/1x1.gif trunk/libs-new/flac/flac-1.2.1/doc/html/images/Makefile trunk/libs-new/flac/flac-1.2.1/doc/html/images/Makefile.am trunk/libs-new/flac/flac-1.2.1/doc/html/images/Makefile.in trunk/libs-new/flac/flac-1.2.1/doc/html/images/cafebug.gif trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/ trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Blackbird_Front_low3_325x87.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/MS300frontsmall_270x108.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Makefile trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Makefile.am trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Makefile.in trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/MediaBox_Frt_170x325.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/SB_Hero_Black_325x182.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Sooloos-ControlOne_325x328.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/Z500_front_325x94.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/a2_01_325x252.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/arcus_325x135.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/bmp-1430_325x241.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/cs505_front_lrg_325x113.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/enus_3-4lft-hires_product_eva8000_325x127.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/escient_ProductLine_325x163.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/hifidelio_bl_front_Z_RGB_325x163.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/i-station-mini-dx_325x237.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/iwod-g10_325x257.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/knc_hr-2800_325x209.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/mediaready_prodmain_MRMCa_325x232.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/meizu_m6_325x206.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/musica_artwork_325x90.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/neodigits_x5000_325x124.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/onda-vx737_325x240.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/request_n_front_325x103.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/rio_karma_279x254.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/sonos_family_RGB_325x200.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/teclast-tl29_325x244.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/transporter_hero_grey_325x208.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/tvix-4000_325x204.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/hw/vibez_nofm_combi_black_b_325x220.jpg trunk/libs-new/flac/flac-1.2.1/doc/html/images/logo100.gif trunk/libs-new/flac/flac-1.2.1/doc/html/images/logo130.gif trunk/libs-new/flac/flac-1.2.1/doc/html/index.html trunk/libs-new/flac/flac-1.2.1/doc/html/itunes.html trunk/libs-new/flac/flac-1.2.1/doc/html/license.html trunk/libs-new/flac/flac-1.2.1/doc/html/links.html trunk/libs-new/flac/flac-1.2.1/doc/html/news.html trunk/libs-new/flac/flac-1.2.1/doc/html/ogg_mapping.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/ trunk/libs-new/flac/flac-1.2.1/doc/html/ru/Makefile trunk/libs-new/flac/flac-1.2.1/doc/html/ru/Makefile.am trunk/libs-new/flac/flac-1.2.1/doc/html/ru/Makefile.in trunk/libs-new/flac/flac-1.2.1/doc/html/ru/authors.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/comparison.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/developers.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/documentation.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/download.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/features.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/format.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/goals.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/id.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/index.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/links.html trunk/libs-new/flac/flac-1.2.1/doc/html/ru/news.html trunk/libs-new/flac/flac-1.2.1/examples/ trunk/libs-new/flac/flac-1.2.1/examples/Makefile trunk/libs-new/flac/flac-1.2.1/examples/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/Makefile.lite trunk/libs-new/flac/flac-1.2.1/examples/README trunk/libs-new/flac/flac-1.2.1/examples/c/ trunk/libs-new/flac/flac-1.2.1/examples/c/Makefile trunk/libs-new/flac/flac-1.2.1/examples/c/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/c/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/c/decode/ trunk/libs-new/flac/flac-1.2.1/examples/c/decode/Makefile trunk/libs-new/flac/flac-1.2.1/examples/c/decode/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/c/decode/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/ trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/.deps/ trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/.deps/main.Po trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/Makefile trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/Makefile.lite trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/example_c_decode_file.dsp trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/example_c_decode_file.vcproj trunk/libs-new/flac/flac-1.2.1/examples/c/decode/file/main.c trunk/libs-new/flac/flac-1.2.1/examples/c/encode/ trunk/libs-new/flac/flac-1.2.1/examples/c/encode/Makefile trunk/libs-new/flac/flac-1.2.1/examples/c/encode/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/c/encode/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/ trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/.deps/ trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/.deps/main.Po trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/Makefile trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/Makefile.lite trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/example_c_encode_file.dsp trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/example_c_encode_file.vcproj trunk/libs-new/flac/flac-1.2.1/examples/c/encode/file/main.c trunk/libs-new/flac/flac-1.2.1/examples/cpp/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/Makefile trunk/libs-new/flac/flac-1.2.1/examples/cpp/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/cpp/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/Makefile trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/.deps/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/.deps/main.Po trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/Makefile trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/Makefile.lite trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/example_cpp_decode_file.dsp trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/example_cpp_decode_file.vcproj trunk/libs-new/flac/flac-1.2.1/examples/cpp/decode/file/main.cpp trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/Makefile trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/.deps/ trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/.deps/main.Po trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/Makefile trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/Makefile.am trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/Makefile.in trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/Makefile.lite trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/example_cpp_encode_file.dsp trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/example_cpp_encode_file.vcproj trunk/libs-new/flac/flac-1.2.1/examples/cpp/encode/file/main.cpp trunk/libs-new/flac/flac-1.2.1/examples/examples.dsp trunk/libs-new/flac/flac-1.2.1/include/ trunk/libs-new/flac/flac-1.2.1/include/FLAC/ trunk/libs-new/flac/flac-1.2.1/include/FLAC/Makefile trunk/libs-new/flac/flac-1.2.1/include/FLAC/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/FLAC/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/FLAC/all.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/assert.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/callback.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/export.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/format.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/metadata.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/ordinals.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/stream_decoder.h trunk/libs-new/flac/flac-1.2.1/include/FLAC/stream_encoder.h trunk/libs-new/flac/flac-1.2.1/include/FLAC++/ trunk/libs-new/flac/flac-1.2.1/include/FLAC++/Makefile trunk/libs-new/flac/flac-1.2.1/include/FLAC++/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/FLAC++/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/FLAC++/all.h trunk/libs-new/flac/flac-1.2.1/include/FLAC++/decoder.h trunk/libs-new/flac/flac-1.2.1/include/FLAC++/encoder.h trunk/libs-new/flac/flac-1.2.1/include/FLAC++/export.h trunk/libs-new/flac/flac-1.2.1/include/FLAC++/metadata.h trunk/libs-new/flac/flac-1.2.1/include/Makefile trunk/libs-new/flac/flac-1.2.1/include/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/share/ trunk/libs-new/flac/flac-1.2.1/include/share/Makefile trunk/libs-new/flac/flac-1.2.1/include/share/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/share/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/share/alloc.h trunk/libs-new/flac/flac-1.2.1/include/share/getopt.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/ trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/Makefile trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/cuesheet.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/file.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/picture.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/replaygain.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag/seektable.h trunk/libs-new/flac/flac-1.2.1/include/share/grabbag.h trunk/libs-new/flac/flac-1.2.1/include/share/replaygain_analysis.h trunk/libs-new/flac/flac-1.2.1/include/share/replaygain_synthesis.h trunk/libs-new/flac/flac-1.2.1/include/share/utf8.h trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/ trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/Makefile trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/Makefile.am trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/Makefile.in trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/file_utils_flac.h trunk/libs-new/flac/flac-1.2.1/include/test_libs_common/metadata_utils.h trunk/libs-new/flac/flac-1.2.1/install-sh trunk/libs-new/flac/flac-1.2.1/libtool trunk/libs-new/flac/flac-1.2.1/libtool-disable-static trunk/libs-new/flac/flac-1.2.1/ltmain.sh trunk/libs-new/flac/flac-1.2.1/m4/ trunk/libs-new/flac/flac-1.2.1/m4/Makefile trunk/libs-new/flac/flac-1.2.1/m4/Makefile.am trunk/libs-new/flac/flac-1.2.1/m4/Makefile.in trunk/libs-new/flac/flac-1.2.1/m4/ogg.m4 trunk/libs-new/flac/flac-1.2.1/m4/xmms.m4 trunk/libs-new/flac/flac-1.2.1/man/ trunk/libs-new/flac/flac-1.2.1/man/Makefile trunk/libs-new/flac/flac-1.2.1/man/Makefile.am trunk/libs-new/flac/flac-1.2.1/man/Makefile.in trunk/libs-new/flac/flac-1.2.1/man/flac.1 trunk/libs-new/flac/flac-1.2.1/man/flac.sgml trunk/libs-new/flac/flac-1.2.1/man/metaflac.1 trunk/libs-new/flac/flac-1.2.1/man/metaflac.sgml trunk/libs-new/flac/flac-1.2.1/missing trunk/libs-new/flac/flac-1.2.1/mkinstalldirs trunk/libs-new/flac/flac-1.2.1/obj/ trunk/libs-new/flac/flac-1.2.1/obj/Makefile trunk/libs-new/flac/flac-1.2.1/obj/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/debug/ trunk/libs-new/flac/flac-1.2.1/obj/debug/Makefile trunk/libs-new/flac/flac-1.2.1/obj/debug/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/debug/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/debug/bin/ trunk/libs-new/flac/flac-1.2.1/obj/debug/bin/Makefile trunk/libs-new/flac/flac-1.2.1/obj/debug/bin/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/debug/bin/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/debug/lib/ trunk/libs-new/flac/flac-1.2.1/obj/debug/lib/Makefile trunk/libs-new/flac/flac-1.2.1/obj/debug/lib/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/debug/lib/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/release/ trunk/libs-new/flac/flac-1.2.1/obj/release/Makefile trunk/libs-new/flac/flac-1.2.1/obj/release/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/release/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/release/bin/ trunk/libs-new/flac/flac-1.2.1/obj/release/bin/Makefile trunk/libs-new/flac/flac-1.2.1/obj/release/bin/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/release/bin/Makefile.in trunk/libs-new/flac/flac-1.2.1/obj/release/lib/ trunk/libs-new/flac/flac-1.2.1/obj/release/lib/Makefile trunk/libs-new/flac/flac-1.2.1/obj/release/lib/Makefile.am trunk/libs-new/flac/flac-1.2.1/obj/release/lib/Makefile.in trunk/libs-new/flac/flac-1.2.1/src/ trunk/libs-new/flac/flac-1.2.1/src/Makefile trunk/libs-new/flac/flac-1.2.1/src/Makefile.am trunk/libs-new/flac/flac-1.2.1/src/Makefile.in trunk/libs-new/flac/flac-1.2.1/src/Makefile.lite trunk/libs-new/flac/flac-1.2.1/src/flac/ trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/ trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/analyze.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/decode.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/encode.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/foreign_metadata.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/local_string_utils.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/main.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/utils.Po trunk/libs-new/flac/flac-1.2.1/src/flac/.deps/vorbiscomment.Po trunk/libs-new/flac/flac-1.2.1/src/flac/Makefile trunk/libs-new/flac/flac-1.2.1/src/flac/Makefile.am trunk/libs-new/flac/flac-1.2.1/src/flac/Makefile.in trunk/libs-new/flac/flac-1.2.1/src/flac/Makefile.lite trunk/libs-new/flac/flac-1.2.1/src... [truncated message content] |
From: <or...@us...> - 2008-09-27 08:30:40
|
Revision: 337 http://open2x.svn.sourceforge.net/open2x/?rev=337&view=rev Author: orkie Date: 2008-09-27 08:30:27 +0000 (Sat, 27 Sep 2008) Log Message: ----------- Updated to make CD work Modified Paths: -------------- trunk/libs-new/sdl/sdl/1.2.13.mk Modified: trunk/libs-new/sdl/sdl/1.2.13.mk =================================================================== --- trunk/libs-new/sdl/sdl/1.2.13.mk 2008-09-17 17:52:45 UTC (rev 336) +++ trunk/libs-new/sdl/sdl/1.2.13.mk 2008-09-27 08:30:27 UTC (rev 337) @@ -2,6 +2,7 @@ o2x-sdl: @-echo "Build SDL" + $(FLAGS) make -C $(SDL_DIR) distclean (cd $(SDL_DIR); rm -rf config.cache; \ ./autogen.sh; \ $(FLAGS) ./configure --prefix=$(PREFIX)\ @@ -16,6 +17,7 @@ --enable-threads\ --disable-video-directfb\ --disable-video-x11\ + --enable-cdrom\ --disable-arts\ --disable-esd\ --enable-video\ @@ -23,4 +25,4 @@ ) $(FLAGS) make -C $(SDL_DIR) $(FLAGS) make -C $(SDL_DIR) install - #$(FLAGS) make -C $(SDL_DIR) clean + $(FLAGS) make -C $(SDL_DIR) clean This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <min...@us...> - 2008-09-17 17:52:35
|
Revision: 336 http://open2x.svn.sourceforge.net/open2x/?rev=336&view=rev Author: mindless2112 Date: 2008-09-17 17:52:45 +0000 (Wed, 17 Sep 2008) Log Message: ----------- O2xIV: don't reset zoom for each image Modified Paths: -------------- trunk/utils/o2xiv/src/main.c Modified: trunk/utils/o2xiv/src/main.c =================================================================== --- trunk/utils/o2xiv/src/main.c 2008-09-17 16:52:29 UTC (rev 335) +++ trunk/utils/o2xiv/src/main.c 2008-09-17 17:52:45 UTC (rev 336) @@ -310,7 +310,7 @@ if (image_loaded && image != NULL) { set_rotation(auto_rotate && image->h > image->w ? 3 : 0); - set_scale(auto_fit ? (fit_pref == 1 ? fit_outside : fit_inside) : int_to_fixed(1)); + set_scale(auto_fit ? (fit_pref == 1 ? fit_outside : fit_inside) : scale); } image_update = false; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <min...@us...> - 2008-09-14 20:08:11
|
Revision: 333 http://open2x.svn.sourceforge.net/open2x/?rev=333&view=rev Author: mindless2112 Date: 2008-09-14 20:08:20 +0000 (Sun, 14 Sep 2008) Log Message: ----------- adding O2xIV 0.10 Added Paths: ----------- trunk/utils/o2xiv/Makefile trunk/utils/o2xiv/o2xiv.png trunk/utils/o2xiv/o2xiv.xcf trunk/utils/o2xiv/obj/ trunk/utils/o2xiv/src/ trunk/utils/o2xiv/src/files.c trunk/utils/o2xiv/src/files.h trunk/utils/o2xiv/src/fixed.h trunk/utils/o2xiv/src/font.c trunk/utils/o2xiv/src/font.h trunk/utils/o2xiv/src/image.c trunk/utils/o2xiv/src/image.h trunk/utils/o2xiv/src/input.c trunk/utils/o2xiv/src/input.h trunk/utils/o2xiv/src/main.c trunk/utils/o2xiv/src/main.h trunk/utils/o2xiv/src/menu.c trunk/utils/o2xiv/src/menu.h trunk/utils/o2xiv/src/prefs.c trunk/utils/o2xiv/src/prefs.h trunk/utils/o2xiv/src/scale.c trunk/utils/o2xiv/src/scale.h trunk/utils/o2xiv/src/thread.c trunk/utils/o2xiv/src/thread.h Property Changed: ---------------- trunk/utils/o2xiv/ Property changes on: trunk/utils/o2xiv ___________________________________________________________________ Added: svn:ignore + o2xiv o2xiv.gpu o2xiv.pref Added: trunk/utils/o2xiv/Makefile =================================================================== --- trunk/utils/o2xiv/Makefile (rev 0) +++ trunk/utils/o2xiv/Makefile 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,57 @@ +# BUILD SETTINGS ################################### +DEBUG := 1 +# Valid values: UNIX, GP2X +PLATFORM := UNIX + +# If building for the GP2X +GP2X_CHAINPREFIX := /opt/open2x/gcc-4.1.1-glibc-2.3.6 +GP2X_CHAIN := $(GP2X_CHAINPREFIX)/bin/arm-open2x-linux- + +# END SETTINGS ##################################### + +TARGET := o2xiv +OBJS := files.o font.o image.o input.o main.o menu.o prefs.o scale.o thread.o + +ifeq ($(DEBUG), 1) + DEBUG_FLAGS := -g3 -O0 +else + DEBUG_FLAGS := -O3 -DNDEBUG +endif + +ifeq ($(PLATFORM), GP2X) + SDL_CFLAGS := `$(GP2X_CHAINPREFIX)/bin/sdl-config --cflags` -I$(GP2X_CHAINPREFIX)/include -DTARGET_GP2X -mcpu=arm920t -mtune=arm920t -ffast-math + SDL_LDFLAGS := `$(GP2X_CHAINPREFIX)/bin/sdl-config --libs` -lSDL_image -ljpeg -L$(GP2X_CHAINPREFIX)/lib + CC := $(GP2X_CHAIN)gcc + STRIP := $(GP2X_CHAIN)strip + TARGET := $(TARGET).gpu +endif +ifeq ($(PLATFORM), UNIX) + SDL_CFLAGS := $(shell sdl-config --cflags) -DTARGET_UNIX + SDL_LDFLAGS := $(shell sdl-config --libs) -lSDL_image -ljpeg +endif + +CFLAGS := --std=c99 -pedantic -Wall -Wextra -Werror -I$(CURDIR)/src/ $(DEBUG_FLAGS) $(SDL_CFLAGS) +LDFLAGS := $(SDL_LDFLAGS) + +#################################################### + +all : $(TARGET) + +OBJS := $(foreach obj, $(OBJS), obj/$(obj)) + +$(TARGET) : $(OBJS) + $(CC) -o $@ $^ $(LDFLAGS) + +ifneq ($(MAKECMDGOALS), clean) +-include $(OBJS:.o=.d) +endif + +obj/%.d : obj/%.o +obj/%.o : src/%.c + $(CC) -o $@ -MMD -c $(CFLAGS) $< + +.PHONY : clean + +clean : + rm -f obj/*.o obj/*.d + rm -f $(TARGET) Property changes on: trunk/utils/o2xiv/o2xiv.png ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Property changes on: trunk/utils/o2xiv/o2xiv.xcf ___________________________________________________________________ Added: svn:mime-type + application/octet-stream Property changes on: trunk/utils/o2xiv/obj ___________________________________________________________________ Added: svn:ignore + *.d *.o Added: trunk/utils/o2xiv/src/files.c =================================================================== --- trunk/utils/o2xiv/src/files.c (rev 0) +++ trunk/utils/o2xiv/src/files.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,234 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "files.h" +#include "font.h" +#include "input.h" +#include "main.h" +#include "menu.h" +#include "prefs.h" +#include "thread.h" + +#include <assert.h> +#include <dirent.h> +#include <libgen.h> +#include <stdlib.h> +#include <string.h> + +#ifndef DT_DIR +#define DT_DIR 4 +#define DT_REG 8 +#endif + +bool file_selector = false; + +char *path = NULL; + +unsigned int file_index = 0, temp_file_index = 0; +char *files[1000] = { "../", NULL }; +unsigned int file_min = 0, file_max = 0; + +void toggle_file_selector( void ) { + file_selector = !file_selector; + + if (file_selector) { + temp_file_index = file_index; + SDL_LockMutex(files_modify_mutex); + } else { + SDL_UnlockMutex(files_modify_mutex); + } +} + +void file_selector_input( void ) { + switch (last_key) { + case SDLK_ESCAPE: + quit = true; + break; + + case SDLK_KP0: + toggle_menu(); + + case SDLK_KP_PERIOD: + case SDLK_KP_MINUS: + case SDLK_KP_PLUS: + toggle_file_selector(); + need_redraw = true; + break; + + case SDLK_KP_DIVIDE: + case SDLK_KP_MULTIPLY: + // selected a directory or file? + if (temp_file_index < file_min) { + // ..? + if (temp_file_index == 0) { + char *new_path = dirname(path); + strcpy(path, new_path); + if (strcmp(path, "/") != 0) + strcat(path, "/"); + } else { + path = realloc(path, strlen(path) + strlen(files[temp_file_index]) + 1); + strcat(path, files[temp_file_index]); + } + + populate_files(path, true); + temp_file_index = 0; + + force_image_load = true; + } else { + file_index = temp_file_index; + toggle_file_selector(); + } + + need_redraw = true; + break; + + default: + break; + } + + if (input[0]) { + temp_file_index = wrap_file_index(temp_file_index - 1, false); + delay += 150; + need_redraw = true; + } + if (input[2]) { + temp_file_index = wrap_file_index(temp_file_index + 1, false); + delay += 150; + need_redraw = true; + } +} + +void draw_file_selector( void ) { + SDL_FillRect(surface, NULL, BACKGROUND); + + if SDL_MUSTLOCK(surface) SDL_LockSurface(surface); + + text8x8(surface, 4, 10, shorten(path, 39), HEADER); + + int y = 25; + for (int i = -10; i <= 10; i++) { + if (temp_file_index + i < file_max) { + if (i == 0) { + text8x8(surface, 4, y, ">", SELECTED); + text8x8(surface, 12, y, shorten(files[temp_file_index + i], 38), SELECTED); + } else + text8x8(surface, 12, y, shorten(files[temp_file_index + i], 38), NORMAL); + } + y += 10; + } + +#if 0 + for (int y = 0; y < 8; y++) { + for (int x = 0; x < 16; x++) { + char8x8(surface, 160 + x * 10, y * 10, y * 16 + x, 0xffff); + } + } +#endif + + if SDL_MUSTLOCK(surface) SDL_UnlockSurface(surface); +} + + +int wrap_file_index( signed int index, bool only_files ) { + int temp_min = only_files ? file_min : 0; + + if (file_max - temp_min == 0) + return 0; + + while (index < temp_min) + index += file_max - temp_min; + while (index >= (signed)file_max) + index -= file_max - temp_min; + return index; +} + + +bool maybe_image( const char *filename ) { + int temp = strlen(filename); + return (temp >= 5 && (strcasecmp(&filename[temp - 5], ".jpeg") == 0 || + strcasecmp(&filename[temp - 5], ".tiff") == 0)) || + (temp >= 4 && (strcasecmp(&filename[temp - 4], ".jpg") == 0 || + strcasecmp(&filename[temp - 4], ".jpe") == 0 || + strcasecmp(&filename[temp - 4], ".png") == 0 || + strcasecmp(&filename[temp - 4], ".tif") == 0 || + strcasecmp(&filename[temp - 4], ".tga") == 0 || + strcasecmp(&filename[temp - 4], ".gif") == 0 || + strcasecmp(&filename[temp - 4], ".bmp") == 0 || + strcasecmp(&filename[temp - 4], ".pcx") == 0 || + strcasecmp(&filename[temp - 4], ".pnm") == 0 || + strcasecmp(&filename[temp - 4], ".xpm") == 0 || + strcasecmp(&filename[temp - 4], ".xcf") == 0 || + strcasecmp(&filename[temp - 4], ".lbm") == 0)); +} + +static int strcmpq( const void *s1, const void *s2 ) { + return strcmp(*(char * const *)s1, *(char * const *)s2); +} + +void populate_files( const char *path, bool only_images ) { + DIR *dir = opendir(path); + + file_min = file_max = 1; + + if (dir) { + struct dirent *entry; + + while ((entry = readdir(dir)) != NULL && file_min < countof(files)) { + if (entry->d_type == DT_DIR && strcmp(entry->d_name, ".") != 0 && strcmp(entry->d_name, "..") != 0) { + files[file_min] = realloc(files[file_min], strlen(entry->d_name) + 1 + 1); + strcpy(files[file_min], entry->d_name); + strcat(files[file_min], "/"); + file_min++; + } + } + + file_max = file_min; + + rewinddir(dir); + + while ((entry = readdir(dir)) != NULL && file_max < countof(files)) { + if (entry->d_type == DT_REG) { + if (!only_images || maybe_image(entry->d_name)) { + files[file_max] = realloc(files[file_max], strlen(entry->d_name) + 1); + strcpy(files[file_max], entry->d_name); + file_max++; + } + } + } + closedir(dir); + + file_index = (file_min == file_max) ? 0 : file_min; + + qsort(&files[1], file_min - 1, sizeof(char *), strcmpq); + qsort(&files[file_min], file_max - file_min, sizeof(char *), strcmpq); + } +} + +char *shorten( char *text, unsigned int len ) { + assert(len > 10 && len <= 40); + + static char buffer[40 + 1]; + if (strlen(text) > len) { + sprintf(buffer, "%.7s...%s", text, text + strlen(text) - (len - 10)); + return buffer; + } + + return text; +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/files.h =================================================================== --- trunk/utils/o2xiv/src/files.h (rev 0) +++ trunk/utils/o2xiv/src/files.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,47 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef FILES_H +#define FILES_H + +#include <stdbool.h> + +extern bool file_selector; + +extern char *path; + +extern unsigned int file_index; +extern char *files[1000]; +extern unsigned int file_min, file_max; + +void toggle_file_selector( void ); + +void file_selector_input( void ); +void draw_file_selector( void ); + +int wrap_file_index( int index, bool files_only ); + +bool maybe_image( const char *filename ); + +void populate_files( const char *path, bool only_images ); + +char *shorten( char *text, unsigned int len ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/fixed.h =================================================================== --- trunk/utils/o2xiv/src/fixed.h (rev 0) +++ trunk/utils/o2xiv/src/fixed.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,41 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef FIXED_H +#define FIXED_H + +#include "SDL.h" + +#define fixed_bits 16 +#define fixed_mask ((1 << fixed_bits) - 1) +typedef Uint32 fixed; +typedef Uint64 fixed_dbl; + +#define fixed_to_float(fixed_) ((float)(fixed_) / (1 << fixed_bits)) +#define int_to_fixed(int_) ((fixed)(int_) << fixed_bits) +#define fixed_to_int(fixed_) ((fixed_) >> fixed_bits) + +#define fixed_mul(fixed1, fixed2) (((fixed_dbl)(fixed1) * (fixed2)) >> fixed_bits) +#define fixed_div(fixed1, fixed2) (((fixed_dbl)(fixed1) << fixed_bits) / (fixed2)) + +#define int_div_int_to_fixed(int1, int2) (int_to_fixed(int1) / (int2)) +#define int_div_fixed_to_fixed(int_, fixed_) (fixed_div(int_to_fixed(int_), (fixed_))) + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/font.c =================================================================== --- trunk/utils/o2xiv/src/font.c (rev 0) +++ trunk/utils/o2xiv/src/font.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,195 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "assert.h" + +#include "SDL.h" + +#include "font.h" +#include "main.h" + + +/* stolen from picodrive ... font had no license info */ +unsigned char fontdata8x8[][8] = +{ + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x3C,0x42,0x99,0xBD,0xBD,0x99,0x42,0x3C }, + { 0x3C,0x42,0x81,0x81,0x81,0x81,0x42,0x3C }, + { 0xFE,0x82,0x8A,0xD2,0xA2,0x82,0xFE,0x00 }, + { 0xFE,0x82,0x82,0x82,0x82,0x82,0xFE,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x38,0x64,0x74,0x7C,0x38,0x00,0x00 }, + { 0x80,0xC0,0xF0,0xFC,0xF0,0xC0,0x80,0x00 }, + { 0x01,0x03,0x0F,0x3F,0x0F,0x03,0x01,0x00 }, + { 0x18,0x3C,0x7E,0x18,0x7E,0x3C,0x18,0x00 }, + { 0xEE,0xEE,0xEE,0xCC,0x00,0xCC,0xCC,0x00 }, + { 0x00,0x00,0x30,0x68,0x78,0x30,0x00,0x00 }, + { 0x00,0x38,0x64,0x74,0x7C,0x38,0x00,0x00 }, + { 0x3C,0x66,0x7A,0x7A,0x7E,0x7E,0x3C,0x00 }, + { 0x0E,0x3E,0x3A,0x22,0x26,0x6E,0xE4,0x40 }, + { 0x18,0x3C,0x7E,0x3C,0x3C,0x3C,0x3C,0x00 }, + { 0x3C,0x3C,0x3C,0x3C,0x7E,0x3C,0x18,0x00 }, + { 0x08,0x7C,0x7E,0x7E,0x7C,0x08,0x00,0x00 }, + { 0x10,0x3E,0x7E,0x7E,0x3E,0x10,0x00,0x00 }, + { 0x58,0x2A,0xDC,0xC8,0xDC,0x2A,0x58,0x00 }, + { 0x24,0x66,0xFF,0xFF,0x66,0x24,0x00,0x00 }, + { 0x00,0x10,0x10,0x38,0x38,0x7C,0xFE,0x00 }, + { 0xFE,0x7C,0x38,0x38,0x10,0x10,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 }, + { 0x1C,0x1C,0x1C,0x18,0x00,0x18,0x18,0x00 }, + { 0x6C,0x6C,0x24,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x28,0x7C,0x28,0x7C,0x28,0x00,0x00 }, + { 0x10,0x38,0x60,0x38,0x0C,0x78,0x10,0x00 }, + { 0x40,0xA4,0x48,0x10,0x24,0x4A,0x04,0x00 }, + { 0x18,0x34,0x18,0x3A,0x6C,0x66,0x3A,0x00 }, + { 0x18,0x18,0x20,0x00,0x00,0x00,0x00,0x00 }, + { 0x30,0x60,0x60,0x60,0x60,0x60,0x30,0x00 }, + { 0x0C,0x06,0x06,0x06,0x06,0x06,0x0C,0x00 }, + { 0x10,0x54,0x38,0x7C,0x38,0x54,0x10,0x00 }, + { 0x00,0x18,0x18,0x7E,0x18,0x18,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x18,0x18,0x30,0x00 }, + { 0x00,0x00,0x00,0x00,0x3E,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x18,0x18,0x00,0x00 }, + { 0x00,0x04,0x08,0x10,0x20,0x40,0x00,0x00 }, + { 0x38,0x4C,0xC6,0xC6,0xC6,0x64,0x38,0x00 }, + { 0x18,0x38,0x18,0x18,0x18,0x18,0x7E,0x00 }, + { 0x7C,0xC6,0x0E,0x3C,0x78,0xE0,0xFE,0x00 }, + { 0x7E,0x0C,0x18,0x3C,0x06,0xC6,0x7C,0x00 }, + { 0x1C,0x3C,0x6C,0xCC,0xFE,0x0C,0x0C,0x00 }, + { 0xFC,0xC0,0xFC,0x06,0x06,0xC6,0x7C,0x00 }, + { 0x3C,0x60,0xC0,0xFC,0xC6,0xC6,0x7C,0x00 }, + { 0xFE,0xC6,0x0C,0x18,0x30,0x30,0x30,0x00 }, + { 0x78,0xC4,0xE4,0x78,0x86,0x86,0x7C,0x00 }, + { 0x7C,0xC6,0xC6,0x7E,0x06,0x0C,0x78,0x00 }, + { 0x00,0x00,0x18,0x00,0x00,0x18,0x00,0x00 }, + { 0x00,0x00,0x18,0x00,0x00,0x18,0x18,0x30 }, + { 0x1C,0x38,0x70,0xE0,0x70,0x38,0x1C,0x00 }, + { 0x00,0x7C,0x00,0x00,0x7C,0x00,0x00,0x00 }, + { 0x70,0x38,0x1C,0x0E,0x1C,0x38,0x70,0x00 }, + { 0x7C,0xC6,0xC6,0x1C,0x18,0x00,0x18,0x00 }, + { 0x3C,0x42,0x99,0xA1,0xA5,0x99,0x42,0x3C }, + { 0x38,0x6C,0xC6,0xC6,0xFE,0xC6,0xC6,0x00 }, + { 0xFC,0xC6,0xC6,0xFC,0xC6,0xC6,0xFC,0x00 }, + { 0x3C,0x66,0xC0,0xC0,0xC0,0x66,0x3C,0x00 }, + { 0xF8,0xCC,0xC6,0xC6,0xC6,0xCC,0xF8,0x00 }, + { 0xFE,0xC0,0xC0,0xFC,0xC0,0xC0,0xFE,0x00 }, + { 0xFE,0xC0,0xC0,0xFC,0xC0,0xC0,0xC0,0x00 }, + { 0x3E,0x60,0xC0,0xCE,0xC6,0x66,0x3E,0x00 }, + { 0xC6,0xC6,0xC6,0xFE,0xC6,0xC6,0xC6,0x00 }, + { 0x7E,0x18,0x18,0x18,0x18,0x18,0x7E,0x00 }, + { 0x06,0x06,0x06,0x06,0xC6,0xC6,0x7C,0x00 }, + { 0xC6,0xCC,0xD8,0xF0,0xF8,0xDC,0xCE,0x00 }, + { 0x60,0x60,0x60,0x60,0x60,0x60,0x7E,0x00 }, + { 0xC6,0xEE,0xFE,0xFE,0xD6,0xC6,0xC6,0x00 }, + { 0xC6,0xE6,0xF6,0xFE,0xDE,0xCE,0xC6,0x00 }, + { 0x7C,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00 }, + { 0xFC,0xC6,0xC6,0xC6,0xFC,0xC0,0xC0,0x00 }, + { 0x7C,0xC6,0xC6,0xC6,0xDE,0xCC,0x7A,0x00 }, + { 0xFC,0xC6,0xC6,0xCE,0xF8,0xDC,0xCE,0x00 }, + { 0x78,0xCC,0xC0,0x7C,0x06,0xC6,0x7C,0x00 }, + { 0x7E,0x18,0x18,0x18,0x18,0x18,0x18,0x00 }, + { 0xC6,0xC6,0xC6,0xC6,0xC6,0xC6,0x7C,0x00 }, + { 0xC6,0xC6,0xC6,0xEE,0x7C,0x38,0x10,0x00 }, + { 0xC6,0xC6,0xD6,0xFE,0xFE,0xEE,0xC6,0x00 }, + { 0xC6,0xEE,0x3C,0x38,0x7C,0xEE,0xC6,0x00 }, + { 0x66,0x66,0x66,0x3C,0x18,0x18,0x18,0x00 }, + { 0xFE,0x0E,0x1C,0x38,0x70,0xE0,0xFE,0x00 }, + { 0x3C,0x30,0x30,0x30,0x30,0x30,0x3C,0x00 }, + { 0x60,0x60,0x30,0x18,0x0C,0x06,0x06,0x00 }, + { 0x3C,0x0C,0x0C,0x0C,0x0C,0x0C,0x3C,0x00 }, + { 0x18,0x3C,0x66,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF }, + { 0x30,0x30,0x18,0x00,0x00,0x00,0x00,0x00 }, + { 0x00,0x3C,0x06,0x3E,0x66,0x66,0x3C,0x00 }, + { 0x60,0x7C,0x66,0x66,0x66,0x66,0x7C,0x00 }, + { 0x00,0x3C,0x66,0x60,0x60,0x66,0x3C,0x00 }, + { 0x06,0x3E,0x66,0x66,0x66,0x66,0x3E,0x00 }, + { 0x00,0x3C,0x66,0x66,0x7E,0x60,0x3C,0x00 }, + { 0x1C,0x30,0x78,0x30,0x30,0x30,0x30,0x00 }, + { 0x00,0x3E,0x66,0x66,0x66,0x3E,0x06,0x3C }, + { 0x60,0x7C,0x76,0x66,0x66,0x66,0x66,0x00 }, + { 0x18,0x00,0x38,0x18,0x18,0x18,0x18,0x00 }, + { 0x0C,0x00,0x1C,0x0C,0x0C,0x0C,0x0C,0x38 }, + { 0x60,0x60,0x66,0x6C,0x78,0x6C,0x66,0x00 }, + { 0x38,0x18,0x18,0x18,0x18,0x18,0x18,0x00 }, + { 0x00,0xEC,0xFE,0xFE,0xFE,0xD6,0xC6,0x00 }, + { 0x00,0x7C,0x76,0x66,0x66,0x66,0x66,0x00 }, + { 0x00,0x3C,0x66,0x66,0x66,0x66,0x3C,0x00 }, + { 0x00,0x7C,0x66,0x66,0x66,0x7C,0x60,0x60 }, + { 0x00,0x3E,0x66,0x66,0x66,0x3E,0x06,0x06 }, + { 0x00,0x7E,0x70,0x60,0x60,0x60,0x60,0x00 }, + { 0x00,0x3C,0x60,0x3C,0x06,0x66,0x3C,0x00 }, + { 0x30,0x78,0x30,0x30,0x30,0x30,0x1C,0x00 }, + { 0x00,0x66,0x66,0x66,0x66,0x6E,0x3E,0x00 }, + { 0x00,0x66,0x66,0x66,0x66,0x3C,0x18,0x00 }, + { 0x00,0xC6,0xD6,0xFE,0xFE,0x7C,0x6C,0x00 }, + { 0x00,0x66,0x3C,0x18,0x3C,0x66,0x66,0x00 }, + { 0x00,0x66,0x66,0x66,0x66,0x3E,0x06,0x3C }, + { 0x00,0x7E,0x0C,0x18,0x30,0x60,0x7E,0x00 }, + { 0x0E,0x18,0x0C,0x38,0x0C,0x18,0x0E,0x00 }, + { 0x18,0x18,0x18,0x00,0x18,0x18,0x18,0x00 }, + { 0x70,0x18,0x30,0x1C,0x30,0x18,0x70,0x00 }, + { 0x00,0x00,0x76,0xDC,0x00,0x00,0x00,0x00 }, + { 0x10,0x28,0x10,0x54,0xAA,0x44,0x00,0x00 }, +}; + +void char8x8( SDL_Surface *const surface, int x, int y, const char c, const Uint16 color ) { + assert(x >= 0 && y >= 0); + + const unsigned int bpp = surface->format->BytesPerPixel; + Uint8 *s = (Uint8 *)surface->pixels + y * surface->pitch + x * bpp; + + for (unsigned int y = 0; y < 8; y++) { + int temp = fontdata8x8[(int)c][y]; + for (unsigned int x = 0; x < 8; x++) { + if (temp & 0x80) + *(Uint16 *)s = color; + s += bpp; + temp <<= 1; + } + s += surface->pitch - 8 * bpp; + } +} + +void text8x8( SDL_Surface *const surface, int x, int y, const char text[], const Uint16 color ) { + assert(y >= 0 && y + 8 < surface->h); + for (unsigned int i = 0; i < strlen(text); i++) { + assert(x >= 0 && x + 8 < surface->w); + char8x8(surface, x, y, text[i], color); + x += 8; + } +} + +void outline8x8( SDL_Surface *const surface, int x, int y, const char text[], const Uint16 color, const Uint16 outline ) { + text8x8(surface, x - 1, y, text, outline); + text8x8(surface, x, y - 1, text, outline); + text8x8(surface, x + 1, y, text, outline); + text8x8(surface, x, y + 1, text, outline); + text8x8(surface, x, y, text, color); +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/font.h =================================================================== --- trunk/utils/o2xiv/src/font.h (rev 0) +++ trunk/utils/o2xiv/src/font.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,30 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef FONT_H +#define FONT_H + +#include "SDL.h" + +void char8x8( SDL_Surface *const surface, int x, int y, const char c, const Uint16 color ); +void text8x8( SDL_Surface *const surface, int x, int y, const char text[], const Uint16 color ); +void outline8x8( SDL_Surface *const surface, int x, int y, const char text[], const Uint16 color, const Uint16 outline ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/image.c =================================================================== --- trunk/utils/o2xiv/src/image.c (rev 0) +++ trunk/utils/o2xiv/src/image.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,122 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "main.h" +#include "image.h" + +#include "SDL.h" +#ifdef TARGET_GP2X +#undef HAVE_STDLIB_H +#endif +#include "jpeglib.h" + +#include <setjmp.h> +#include <stdbool.h> +#include <stdio.h> +#include <string.h> + +struct jpeg_client_data { + jmp_buf escape; +}; + +static void error_exit( j_common_ptr jpeg ) { + struct jpeg_client_data *jpeg_usr = jpeg->client_data; + + longjmp(jpeg_usr->escape, 1); + + return; +} + +SDL_Surface *jpeg_load( const char *filename ) { + struct jpeg_decompress_struct jpeg; + + struct jpeg_client_data jpeg_usr; + jpeg.client_data = &jpeg_usr; + + struct jpeg_error_mgr jpeg_err; + jpeg.err = jpeg_std_error(&jpeg_err); + jpeg_err.error_exit = error_exit; + jpeg_err.output_message = error_exit; + + FILE *f = fopen(filename, "rb"); + + if (f == NULL) + return NULL; + + Uint8 *dst_mem = NULL; + SDL_Surface *dst = NULL; + + if (setjmp(jpeg_usr.escape)) { + printf("error: JPEG decoding failed for '%s'\n\t", filename); + printf(jpeg_err.jpeg_message_table[jpeg_err.msg_code], jpeg_err.msg_parm.i[0], jpeg_err.msg_parm.i[1]); + printf("\n"); + + goto jpeg_cleanup; + } + + jpeg_create_decompress(&jpeg); + jpeg_stdio_src(&jpeg, f); + jpeg_read_header(&jpeg, true); + + jpeg.mem->max_memory_to_use = 1000000; + + jpeg.out_color_space = JCS_RGB; + jpeg.dct_method = JDCT_FASTEST; + //jpeg.do_fancy_upsampling = false; // disabling this causes some images to crash libjpeg + jpeg.do_block_smoothing = false; + jpeg.quantize_colors = false; + + jpeg_calc_output_dimensions(&jpeg); + + int i = 0; + while ((jpeg.output_width >> i) * (jpeg.output_height >> i) > 1500 * 1500) + i++; + jpeg.scale_num = 1; + jpeg.scale_denom = 1 << i; + + jpeg_calc_output_dimensions(&jpeg); + + jpeg_start_decompress(&jpeg); + + dst_mem = malloc(jpeg.output_width * jpeg.output_height * 3); + if (dst_mem) { + JSAMPROW dst_temp[1] = { (JSAMPROW)dst_mem }; + dst = SDL_CreateRGBSurfaceFrom(dst_mem, jpeg.output_width, jpeg.output_height, 24, jpeg.output_width * 3, 0x0000ff, 0x00ff00, 0xff0000, 0); + dst->flags &= ~SDL_PREALLOC; // this is not what we should be doing, but it'll work for now + + while (jpeg.output_scanline < jpeg.output_height) { + jpeg_read_scanlines(&jpeg, dst_temp, jpeg.rec_outbuf_height); + dst_temp[0] += jpeg.output_width * 3 * jpeg.rec_outbuf_height; + } + } else { + printf("error: JPEG decoding failed for '%s'\n\t", filename); + printf("out of memory!\n"); + } + + jpeg_finish_decompress(&jpeg); + +jpeg_cleanup: + jpeg_destroy_decompress(&jpeg); + + if (f) + fclose(f); + + return dst; +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/image.h =================================================================== --- trunk/utils/o2xiv/src/image.h (rev 0) +++ trunk/utils/o2xiv/src/image.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,26 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef IMAGE_H +#define IMAGE_H + +SDL_Surface *jpeg_load( const char *filename ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/input.c =================================================================== --- trunk/utils/o2xiv/src/input.c (rev 0) +++ trunk/utils/o2xiv/src/input.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,124 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "input.h" +#include "main.h" + +#include "SDL.h" + +#include <stdbool.h> + +SDLKey last_key; +Uint8 *key_down; + +Uint8 input[5]; + +SDL_Joystick *joy; + +void init_input( void ) { + SDL_EnableKeyRepeat(SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL); + key_down = SDL_GetKeyState(NULL); + + if (SDL_InitSubSystem(SDL_INIT_JOYSTICK) == -1) { + printf("failed to initialize SDL joystick subsystem: %s\n", SDL_GetError()); + return; + } + + if (SDL_NumJoysticks() > 0) { + joy = SDL_JoystickOpen(0); + + printf("found joystick: %s\n", SDL_JoystickName(0)); + } +} + +void poll_input( void ) { + SDL_Event ev; + while (SDL_PollEvent(&ev)) { + switch (ev.type) { + + case SDL_KEYDOWN: + last_key = ev.key.keysym.sym; + break; + +#ifdef TARGET_GP2X + case SDL_JOYBUTTONDOWN: + switch (ev.jbutton.button) { + case GP2X_VK_FY: + last_key = SDLK_KP_MINUS; + break; + case GP2X_VK_FX: + last_key = SDLK_KP_PLUS; + break; + case GP2X_VK_FA: + last_key = SDLK_KP_DIVIDE; + break; + case GP2X_VK_FB: + last_key = SDLK_KP_MULTIPLY; + break; + case GP2X_VK_FL: + last_key = SDLK_KP7; + break; + case GP2X_VK_FR: + last_key = SDLK_KP9; + break; + case GP2X_VK_START: + last_key = SDLK_KP0; + break; + case GP2X_VK_SELECT: + last_key = SDLK_KP_PERIOD; + break; + } + break; +#endif /* TARGET_GP2X */ + + case SDL_QUIT: + exit(0); + break; + + default: + break; + } + } + + input[0] = key_down[SDLK_KP8]; + input[1] = key_down[SDLK_KP6]; + input[2] = key_down[SDLK_KP2]; + input[3] = key_down[SDLK_KP4]; + input[4] = input[1] && input[3]; + +#ifdef TARGET_GP2X + input[0] |= SDL_JoystickGetButton(joy, GP2X_VK_UP) + || SDL_JoystickGetButton(joy, GP2X_VK_UP_LEFT) + || SDL_JoystickGetButton(joy, GP2X_VK_UP_RIGHT); + input[1] |= SDL_JoystickGetButton(joy, GP2X_VK_RIGHT) + || SDL_JoystickGetButton(joy, GP2X_VK_UP_RIGHT) + || SDL_JoystickGetButton(joy, GP2X_VK_DOWN_RIGHT); + input[2] |= SDL_JoystickGetButton(joy, GP2X_VK_DOWN) + || SDL_JoystickGetButton(joy, GP2X_VK_DOWN_LEFT) + || SDL_JoystickGetButton(joy, GP2X_VK_DOWN_RIGHT); + input[3] |= SDL_JoystickGetButton(joy, GP2X_VK_LEFT) + || SDL_JoystickGetButton(joy, GP2X_VK_UP_LEFT) + || SDL_JoystickGetButton(joy, GP2X_VK_DOWN_LEFT); + input[4] |= SDL_JoystickGetButton(joy, GP2X_VK_CLICK); + + if (SDL_JoystickGetButton(joy, GP2X_VK_START) && SDL_JoystickGetButton(joy, GP2X_VK_SELECT)) + quit = true; +#endif /* TARGET_GP2X */ +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/input.h =================================================================== --- trunk/utils/o2xiv/src/input.h (rev 0) +++ trunk/utils/o2xiv/src/input.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,60 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef INPUT_H +#define INPUT_H + +#include "SDL.h" + +#ifdef TARGET_GP2X +#ifndef GP2X_VK_UP + +#define GP2X_VK_UP 0 +#define GP2X_VK_DOWN 4 +#define GP2X_VK_LEFT 2 +#define GP2X_VK_RIGHT 6 +#define GP2X_VK_UP_LEFT 1 +#define GP2X_VK_UP_RIGHT 7 +#define GP2X_VK_DOWN_LEFT 3 +#define GP2X_VK_DOWN_RIGHT 5 +#define GP2X_VK_CLICK 18 +#define GP2X_VK_FA 12 +#define GP2X_VK_FB 13 +#define GP2X_VK_FX 15 +#define GP2X_VK_FY 14 +#define GP2X_VK_FL 10 +#define GP2X_VK_FR 11 +#define GP2X_VK_START 8 +#define GP2X_VK_SELECT 9 +#define GP2X_VK_VOL_UP 16 +#define GP2X_VK_VOL_DOWN 17 + +#endif +#endif + +extern SDLKey last_key; +extern Uint8 *key_down; + +extern Uint8 input[5]; + +void init_input( void ); +void poll_input( void ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/main.c =================================================================== --- trunk/utils/o2xiv/src/main.c (rev 0) +++ trunk/utils/o2xiv/src/main.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,587 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "files.h" +#include "font.h" +#include "input.h" +#include "main.h" +#include "menu.h" +#include "prefs.h" +#include "scale.h" +#include "thread.h" + +#include "SDL.h" + +#include <assert.h> +#include <libgen.h> +#include <stdbool.h> +#include <string.h> +#include <sys/stat.h> + +#ifndef strdup +#define strdup(src) (strcpy(malloc(strlen(src) + 1), src)) +#endif + +int main( int argc, char *argv[] ); + +void set_rotation( int new_rotation ); +void calculate_auto_fit( void ); + +void redraw( void ); +void rotate( void ); + +bool quit = false; + +bool need_redraw = true; +int delay; + +#define NOTE_SHOW 0x01 +#define NOTE_DELAY 0x02 +#define NOTE_MENU 0x04 +int note_flags[3] = { NOTE_MENU, 0, NOTE_MENU }; +Uint32 note_delay[3]; +char note[3][50]; + +SDL_Surface *surface, *image, *scaled, *scaled_rot[4]; + +fixed fit_outside, fit_inside; + +fixed scale = int_to_fixed(1), + scale_inv = int_to_fixed(1); // multiplicative inverse +int rotation = 0; // 0 is 0°, 1 is 90°, 2 is 180°, 3 is 270° + +SDL_Rect pan_rect, drawn_rect, scaled_rect, rotated_rect, surface_rect; + +int main( int argc, char *argv[] ) { + if (SDL_Init(SDL_INIT_TIMER | SDL_INIT_VIDEO) == -1) { + printf("%s:%d\n", __FILE__, __LINE__); + return -1; + } + + surface = SDL_SetVideoMode(320, 240, 16, SDL_HWSURFACE | SDL_DOUBLEBUF); + if (!surface) { + printf("%s:%d\n", __FILE__, __LINE__); + return -1; + } + +#ifdef TARGET_GP2X + SDL_ShowCursor(0); +#endif /* TARGET_GP2X */ + + scaled_rot[0] = SDL_CreateRGBSurfaceFrom(malloc(320 * 240 * 2), 320, 240, 16, 320 * 2, 0, 0, 0, 0); + scaled_rot[1] = SDL_CreateRGBSurfaceFrom(malloc(240 * 320 * 2), 240, 320, 16, 240 * 2, 0, 0, 0, 0); + scaled_rot[2] = SDL_CreateRGBSurfaceFrom(malloc(320 * 240 * 2), 320, 240, 16, 320 * 2, 0, 0, 0, 0); + scaled_rot[3] = scaled_rot[1]; + + init_input(); + + // parse parameter (file or directory) + if (argc > 1) { + struct stat temp; + stat(argv[1], &temp); + + if (S_ISREG(temp.st_mode) && maybe_image(argv[1])) { + char *path_temp = strdup(argv[1]); + path = strdup(dirname(path_temp)); + if (strcmp(path, "/") != 0) + strcat(path, "/"); + free(path_temp); + + populate_files(path, true); + + path_temp = strdup(argv[1]); + char *filename = basename(path_temp); + + for (file_index = file_min; file_index < file_max; file_index++) + if (strcmp(filename, files[file_index]) == 0) + break; + assert(file_index < file_max); + + free(path_temp); + } else if (S_ISDIR(temp.st_mode)) { + bool slash = argv[1][strlen(argv[1]) - 1] != '/'; + + path = malloc(strlen(argv[1]) + 3 + 1); + sprintf(path, "%s%s", argv[1], slash ? "/" : ""); + + populate_files(path, true); + + toggle_file_selector(); + } + } + + if (path == NULL) { + path = malloc(10); // arbitrary initial value, just don't overflow it yet +#ifdef TARGET_GP2X + strcpy(path, "/mnt/sd/"); +#else + strcpy(path, "./"); +#endif + + populate_files(path, true); + + toggle_file_selector(); + } + + image_modify_mutex = SDL_CreateMutex(); + files_modify_mutex = SDL_CreateMutex(); + SDL_Thread *load_images_thread = SDL_CreateThread(load_images, NULL); + + SDL_LockMutex(image_modify_mutex); + + load_prefs(); + + while (!quit) { + delay = SDL_GetTicks() + 20; + + poll_input(); + + // handle input + if (file_selector) { + file_selector_input(); + } else if (menu) { + menu_input(); + } else { // viewing input + switch (last_key) { + case SDLK_ESCAPE: + quit = true; + break; + + case SDLK_KP_PERIOD: + toggle_file_selector(); + need_redraw = true; + break; + + case SDLK_KP0: + toggle_menu(); + need_redraw = true; + break; + + case SDLK_KP_MINUS: + case SDLK_KP_PLUS: + { + fixed ratio = last_key == SDLK_KP_MINUS ? int_div_int_to_fixed(4, 5) : int_div_int_to_fixed(5, 4); + set_scale(fixed_mul(scale, ratio)); + need_redraw = true; + break; + } + + case SDLK_KP_DIVIDE: + case SDLK_KP_MULTIPLY: + set_rotation(rotation + (last_key == SDLK_KP_DIVIDE ? 3 : 1)); + set_scale(auto_fit ? (fit_pref == 1 ? fit_outside : fit_inside) : scale); + need_redraw = true; + break; + + case SDLK_KP7: + case SDLK_KP9: + file_index = wrap_file_index(file_index + (last_key == SDLK_KP7 ? -1 : 1), true); + break; + + default: + break; + } + + const int scroll = 10; + + if (input[0] || input[1] || input[2] || input[3]) { + pan_rect.x += scroll * (input[(1 + rotation) % 4] - input[(3 + rotation) % 4]); + pan_rect.y += scroll * (input[(2 + rotation) % 4] - input[(0 + rotation) % 4]); + + need_redraw = true; + } + if (input[4]) + need_redraw = true; + } + last_key = 0; + + // hide notes on timeout + for (unsigned int i = 0; i < countof(note); i++) + if (note_flags[i] & NOTE_DELAY && note_delay[i] < SDL_GetTicks() && note_delay[i]) { + note_flags[i] &= ~NOTE_DELAY; + note_delay[i] = 0; + + need_redraw = true; + } + + if (need_redraw) { + need_redraw = false; + + if (image) + redraw(); + else + SDL_FillRect(surface, NULL, 0); + + if SDL_MUSTLOCK(surface) SDL_LockSurface(surface); + + // display notes + for (unsigned int i = 0; i < countof(note_delay); i++) { + if (note_flags[i] & (NOTE_SHOW | NOTE_DELAY | (menu ? NOTE_MENU : 0)) || note_delay[i]) { + int x = i & 1 ? 2 : 320 - strlen(shorten(note[i], 39)) * 8 - 2, + y = i > 0 ? 240 - 8 - 2 : 2; + outline8x8(surface, x, y, shorten(note[i], 39), 0xffff, 0x0000); + + if (note_flags[i] & NOTE_DELAY && note_delay[i] == 0) + note_delay[i] = SDL_GetTicks() + 1000; + } + } + + if SDL_MUSTLOCK(surface) SDL_UnlockSurface(surface); + + if (file_selector) { + draw_file_selector(); + } else if (menu) { + draw_menu(); + } + + if SDL_MUSTLOCK(surface) SDL_LockSurface(surface); + + if (input[4]) { + outline8x8(surface, 4, 240 - 10, "Open2xIV v0.10", 0xffff, 0x0000); + + const char buffer[] = "!sseldniM yb dedoc"; // sneaky... not really + static int j = 0; j++; + for (unsigned int i = 0; i < strlen(buffer); i++) { + char8x8(surface, 320 - i * 8 - 12 - 1, 240 - 10, buffer[i], 0xffff); + char8x8(surface, 320 - i * 8 - 12, 240 - 10 - 1, buffer[i], 0xffff); + char8x8(surface, 320 - i * 8 - 12 + 1, 240 - 10, buffer[i], 0xffff); + char8x8(surface, 320 - i * 8 - 12, 240 - 10 + 1, buffer[i], 0xffff); + char8x8(surface, 320 - i * 8 - 12, 240 - 10, buffer[i], (i + j) % 3 == 2 ? 0xd000 : ((i + j) % 3 == 1 ? 0x0340 : 0x001a)); + } + + delay += 100; + need_redraw = true; + } + + if SDL_MUSTLOCK(surface) SDL_UnlockSurface(surface); + + //static int j = 0; char buffer[8]; sprintf(buffer, "%d", j++); text8x8(surface, 0, 0, buffer, 0xffff); // frame counter + + SDL_Flip(surface); + } + + SDL_UnlockMutex(image_modify_mutex); + + delay -= SDL_GetTicks(); + if (delay > 0) + SDL_Delay(delay); + + SDL_LockMutex(image_modify_mutex); + + if (image_update) { + if (image_loaded) { + sprintf(note[0], "%s %d/%d", files[file_index], file_index - file_min + 1, file_max - file_min); + note_flags[0] |= NOTE_DELAY; + note_delay[0] = 0; + + note_flags[1] &= ~NOTE_SHOW; + } + + if (image_loading) { + strcpy(note[1], "Loading..."); + note_flags[1] |= NOTE_SHOW; + } + + if (image_loaded && image == NULL) { + note_flags[0] |= NOTE_SHOW; + + strcpy(note[1], "Nothing to display!"); + note_flags[1] |= NOTE_SHOW; + + strcpy(note[2], ""); + } else { + note_flags[0] &= ~NOTE_SHOW; + } + + if (image_loaded && image != NULL) { + set_rotation(auto_rotate && image->h > image->w ? 3 : 0); + set_scale(auto_fit ? (fit_pref == 1 ? fit_outside : fit_inside) : int_to_fixed(1)); + } + + image_update = false; + need_redraw = true; + } + + } + + save_prefs(); + + if (file_selector) + SDL_UnlockMutex(files_modify_mutex); + + SDL_UnlockMutex(image_modify_mutex); + + thread_die = true; + SDL_WaitThread(load_images_thread, NULL); + + SDL_DestroyMutex(files_modify_mutex); + SDL_DestroyMutex(image_modify_mutex); + + free(scaled_rot[0]->pixels); // yeah, this is wrong, but I'm lazy + SDL_FreeSurface(scaled_rot[0]); + free(scaled_rot[1]->pixels); + SDL_FreeSurface(scaled_rot[1]); + free(scaled_rot[2]->pixels); + SDL_FreeSurface(scaled_rot[2]); + SDL_FreeSurface(surface); + + SDL_Quit(); + + return 0; +} + +void set_rotation( int new_rotation ) { + if (!image_loaded) + return; + + rotation = new_rotation % 4; + scaled = scaled_rot[rotation]; + + calculate_auto_fit(); +} + +void rotate( void ) { + const int Bpp = 2; + + Uint8 *src = scaled->pixels, + *dst = scaled_rot[0]->pixels; + + if (rotation == 0) { + return; + } else if (rotation == 2) { + const int src_w = 320, src_h = 240; + + const int dst_pitch = 320 * Bpp; + + dst += src_h /*dst_h*/ * dst_pitch; + for (int y = src_h; y; y--) { + // dst -= dst_extra; + for (int x = src_w; x; x--) { + dst -= Bpp; + *(Uint16 *)dst = *(Uint16 *)src; + src += Bpp; + } + // src += src_extra; + } + return; + } else { + const int src_w = 240, src_h = 320, + dst_w = 320, dst_h = 240; + + const int dst_pitch = 320 * Bpp; + + switch (rotation) + { + case 1: + dst += dst_w * Bpp; + for (int y = src_h; y; y--) { + dst -= Bpp; + for (int x = src_w; x; x--) { + *(Uint16 *)dst = *(Uint16 *)src; + src += Bpp; + dst += dst_pitch; + } + // src += src_extra; + dst -= dst_h * dst_pitch; + } + return; + case 3: + for (int y = src_h; y; y--) { + dst += dst_h * dst_pitch; + for (int x = src_w; x; x--) { + dst -= dst_pitch; + *(Uint16 *)dst = *(Uint16 *)src; + src += Bpp; + } + // src += src_extra; + dst += Bpp; + } + return; + default: + assert(false); + return; + } + } +} + +void calculate_auto_fit( void ) { + fit_outside = int_to_fixed(scaled->w) / image->w; + fit_inside = int_to_fixed(scaled->h) / image->h; + if (fit_outside < fit_inside) { + fixed temp = fit_outside; + fit_outside = fit_inside; + fit_inside = temp; + } +} + +void set_scale( fixed new_scale ) { + if (!image_loaded) + return; + + new_scale = min(max(new_scale, int_div_int_to_fixed(1, 100)), int_to_fixed(4)); + + // prepare for recentering + int center_x = 0, center_y = 0; + if (scaled_rect.w != 0) { + center_x = fixed_mul((pan_rect.x + scaled_rect.w / 2), fixed_div(new_scale, scale)); + center_y = fixed_mul((pan_rect.y + scaled_rect.h / 2), fixed_div(new_scale, scale)); + } + + if (scale != new_scale) { + if (scale < (int_div_int_to_fixed(1, 10))) + sprintf(note[2], "%ix%i %.1f%%", image->w, image->h, fixed_to_float(new_scale * 100)); + else + sprintf(note[2], "%ix%i %.0f%%", image->w, image->h, fixed_to_float(new_scale * 100)); + note_flags[2] |= NOTE_DELAY; + note_delay[2] = 0; + } + + scale = new_scale; + scale_inv = int_div_fixed_to_fixed(1, scale); + + // panning maximums (dimensions of scaled image) + pan_rect.w = fixed_mul(image->w, scale); + pan_rect.h = fixed_mul(image->h, scale); + + // for blitting from scaled surface, which is max of 320x240 + scaled_rect.w = min(pan_rect.w, scaled->w); + scaled_rect.h = min(pan_rect.h, scaled->h); + + // recenter the panning when image larger than 320x240 + pan_rect.x = max(center_x - scaled_rect.w / 2, 0); + pan_rect.y = max(center_y - scaled_rect.h / 2, 0); + + drawn_rect.w = drawn_rect.h = 0; + + // printf("%dx%d\t%3.1f%%\t%d°\t%dx%d\n", image->w, image->h, fixed_to_float(scale * 100), rotation * 90, pan_rect.w, pan_rect.h); +} + +void redraw( void ) { + void (*fixed_scale)( SDL_Surface *src, SDL_Surface *dst, const fixed src_x, fixed src_y, const SDL_Rect *dst_area, const fixed scale, const fixed scale_inv ) = &fixed_scale_16; + + switch (image->format->BytesPerPixel) { + case 4: + fixed_scale = &fixed_scale_32; + break; + case 3: + fixed_scale = &fixed_scale_24; + break; + case 2: + fixed_scale = &fixed_scale_16; + break; + case 1: + fixed_scale = &fixed_scale_8; + break; + default: + assert(0); + break; + } + + // keep the panning within the image + pan_rect.x = max(min(pan_rect.x, pan_rect.w - scaled_rect.w), 0); + pan_rect.y = max(min(pan_rect.y, pan_rect.h - scaled_rect.h), 0); + + // no scaling needed + if (scale == int_to_fixed(1) && (drawn_rect.w == 0 || pan_rect.x != drawn_rect.x || pan_rect.y != drawn_rect.y)) { + // printf("pan (no scale)\tx %d\ty %d\tx %d\ty %d\n", pan_rect.x, pan_rect.y, pan_rect.x + min(pan_rect.w, scaled->w), pan_rect.y + min(pan_rect.h, scaled->h)); fflush(stdout); + + SDL_SetAlpha(image, 0, SDL_ALPHA_OPAQUE); + SDL_BlitSurface(image, &pan_rect, scaled, NULL); + + // scale entire screen + } else if (drawn_rect.w == 0) { + // printf("pan (scale)\tx %d\ty %d\tx %d\ty %d\n", pan_rect.x, pan_rect.y, pan_rect.x + min(pan_rect.w, scaled->w), pan_rect.y + min(pan_rect.h, scaled->h)); fflush(stdout); + + if SDL_MUSTLOCK(image) SDL_LockSurface(image); + if SDL_MUSTLOCK(scaled) SDL_LockSurface(scaled); + + fixed_scale(image, scaled, pan_rect.x * scale_inv, pan_rect.y * scale_inv, &scaled_rect, scale, scale_inv); + + if SDL_MUSTLOCK(image) SDL_UnlockSurface(image); + if SDL_MUSTLOCK(scaled) SDL_UnlockSurface(scaled); + + // scale partial screen + } else if (pan_rect.x != drawn_rect.x || pan_rect.y != drawn_rect.y) { + // printf("pan (partial)\tx %d\ty %d\tx %d\ty %d\n", pan_rect.x, pan_rect.y, pan_rect.x + min(pan_rect.w, scaled->w), pan_rect.y + min(pan_rect.h, scaled->h)); fflush(stdout); + + // shift already drawn image + SDL_Rect move_rect = { drawn_rect.x - pan_rect.x, drawn_rect.y - pan_rect.y, 0, 0 }; + // printf("move\tx %d\ty %d\tx %d\ty %d\n", move_rect.x, move_rect.y, move_rect.x + move_rect.w, move_rect.y + move_rect.h); fflush(stdout); + SDL_BlitSurface(scaled, NULL, scaled, &move_rect); + + if SDL_MUSTLOCK(image) SDL_LockSurface(image); + if SDL_MUSTLOCK(scaled) SDL_LockSurface(scaled); + + // scale the rest + if (pan_rect.x < drawn_rect.x) { // left + SDL_Rect draw_rect = { 0, 0, drawn_rect.x - pan_rect.x, scaled_rect.h }; +#ifdef TARGET_GP2X + draw_rect.w++; // cover over ugly SDL bug +#endif + // printf("draw\tx %d\ty %d\tx %d\ty %d\n", draw_rect.x, draw_rect.y, draw_rect.x + draw_rect.w, draw_rect.y + draw_rect.h); fflush(stdout); + fixed_scale(image, scaled, pan_rect.x * scale_inv, pan_rect.y * scale_inv, &draw_rect, scale, scale_inv); + } + if (pan_rect.x > drawn_rect.x) { // right + SDL_Rect draw_rect = { scaled_rect.w - (pan_rect.x - drawn_rect.x), 0, pan_rect.x - drawn_rect.x, scaled_rect.h }; + // printf("draw\tx %d\ty %d\tx %d\ty %d\n", draw_rect.x, draw_rect.y, draw_rect.x + draw_rect.w, draw_rect.y + draw_rect.h); fflush(stdout); + fixed_scale(image, scaled, (pan_rect.x + draw_rect.x) * scale_inv, pan_rect.y * scale_inv, &draw_rect, scale, scale_inv); + } + if (pan_rect.y < drawn_rect.y) { // top + SDL_Rect draw_rect = { 0, 0, scaled_rect.w, drawn_rect.y - pan_rect.y }; + // printf("draw\tx %d\ty %d\tx %d\ty %d\n", draw_rect.x, draw_rect.y, draw_rect.x + draw_rect.w, draw_rect.y + draw_rect.h); fflush(stdout); + fixed_scale(image, scaled, pan_rect.x * scale_inv, pan_rect.y * scale_inv, &draw_rect, scale, scale_inv); +#ifdef TARGET_GP2X + draw_rect.h++; // cover over ugly SDL bug +#endif + } + if (pan_rect.y > drawn_rect.y) { // bottom + SDL_Rect draw_rect = { 0, scaled_rect.h - (pan_rect.y - drawn_rect.y), scaled_rect.w, pan_rect.y - drawn_rect.y }; + // printf("draw\tx %d\ty %d\tx %d\ty %d\n", draw_rect.x, draw_rect.y, draw_rect.x + draw_rect.w, draw_rect.y + draw_rect.h); fflush(stdout); + fixed_scale(image, scaled, pan_rect.x * scale_inv, (pan_rect.y + draw_rect.y) * scale_inv, &draw_rect, scale, scale_inv); + } + + if SDL_MUSTLOCK(image) SDL_UnlockSurface(image); + if SDL_MUSTLOCK(scaled) SDL_UnlockSurface(scaled); + } + + drawn_rect = pan_rect; + + // swap width and height for 90 and 270 + if (rotation == 1 || rotation == 3) { + rotated_rect.w = scaled_rect.h; + rotated_rect.h = scaled_rect.w; + } else { + rotated_rect.w = scaled_rect.w; + rotated_rect.h = scaled_rect.h; + } + + // upper left corner of scaled image + rotated_rect.x = (rotation == 1 || rotation == 2) ? scaled_rot[0]->w - rotated_rect.w : 0; + rotated_rect.y = (rotation == 3 || rotation == 2) ? scaled_rot[0]->h - rotated_rect.h : 0; + + // center the scaled image when smaller than 320x240 + surface_rect.x = (scaled_rot[0]->w - rotated_rect.w) / 2; + surface_rect.y = (scaled_rot[0]->h - rotated_rect.h) / 2; + + rotate(); + + SDL_FillRect(surface, NULL, 0); + SDL_BlitSurface(scaled_rot[0], &rotated_rect, surface, &surface_rect); +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/main.h =================================================================== --- trunk/utils/o2xiv/src/main.h (rev 0) +++ trunk/utils/o2xiv/src/main.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,50 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef MAIN_H +#define MAIN_H + +#include "fixed.h" + +#include <stdbool.h> + +#define min(a, b) (a < b ? a : b) +#define max(a, b) (a > b ? a : b) + +#define countof(x) (sizeof(x) / sizeof(*x)) + +#define BACKGROUND 0x0000 /* 0x110a */ +#define HEADER 0x8518 +#define SELECTED 0xffff +#define NORMAL 0x6d12 + +extern bool quit; + +extern bool need_redraw; + +extern int delay; + +extern SDL_Surface *surface, *image; + +extern fixed fit_outside, fit_inside; + +void set_scale( fixed new_scale ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/menu.c =================================================================== --- trunk/utils/o2xiv/src/menu.c (rev 0) +++ trunk/utils/o2xiv/src/menu.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,161 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "SDL.h" + +#include "files.h" +#include "fixed.h" +#include "font.h" +#include "input.h" +#include "main.h" +#include "menu.h" +#include "prefs.h" + +bool menu = false; + +unsigned int menu_select = 2; + +void toggle_menu( void ) { + menu = !menu; +} + +void menu_input( void ) { + switch (last_key) { + case SDLK_ESCAPE: + quit = true; + break; + + case SDLK_KP_PERIOD: + toggle_file_selector(); + + case SDLK_KP0: + case SDLK_KP_MINUS: + case SDLK_KP_PLUS: + toggle_menu(); + need_redraw = true; + break; + + case SDLK_KP_DIVIDE: + case SDLK_KP_MULTIPLY: + switch (menu_select) { + case 2: + set_scale(int_to_fixed(1)); + break; + case 3: + set_scale(fit_inside); + fit_pref = 0; + break; + case 4: + set_scale(fit_outside); + fit_pref = 1; + break; + + case 6: + auto_fit = !auto_fit; + break; + case 7: + auto_rotate = !auto_rotate; + break; + + case 9: + toggle_file_selector(); + break; + case 10: + toggle_menu(); + break; + case 11: + quit = true; + break; + } + need_redraw = true; + break; + + default: + break; + } + + if (input[0]) { + switch (--menu_select) { + case 1: + menu_select = 11; + break; + case 5: + case 8: + menu_select--; + break; + } + delay += 150; + need_redraw = true; + } + if (input[2]) { + switch (++menu_select) { + case 5: + case 8: + menu_select++; + break; + case 12: + menu_select = 2; + break; + } + delay += 150; + need_redraw = true; + } +} + +void draw_menu( void ) { + static char items[][14] = { + "__ Open2xIV __", + "", + "Original size", + "Fit inside", + "Fit outside", + "", + "\177 Auto-fit", + "\177 Auto-rotate", + "", + "Browse...", + "Return", + "Quit" + }; + items[6][0] = auto_fit ? '\014' : '\015'; + items[7][0] = auto_rotate ? '\014' : '\015'; + + SDL_Rect temp_rect = { 8, 15, 8 + 14 * 8 + 8, 10 + 9 * 10 + 3 * 6 + 10 }; + SDL_FillRect(surface, &temp_rect, 0x0000); + + if SDL_MUSTLOCK(surface) SDL_LockSurface(surface); + + int y = 25; + for (unsigned int i = 0; i < sizeof(items) / sizeof(*items); i++) { + if (items[i][0]) { + if (i == 0) + text8x8(surface, 16, y, items[i], HEADER); + else if (i == menu_select) + text8x8(surface, 16, y, items[i], SELECTED); + else + text8x8(surface, 16, y, items[i], NORMAL); + y += 10; + } else { + y += 6; + } + } + + if SDL_MUSTLOCK(surface) SDL_UnlockSurface(surface); +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/menu.h =================================================================== --- trunk/utils/o2xiv/src/menu.h (rev 0) +++ trunk/utils/o2xiv/src/menu.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,34 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#ifndef MENU_H +#define MENU_H + +#include <stdbool.h> + +extern bool menu; +extern unsigned int menu_select; + +void toggle_menu( void ); + +void menu_input( void ); +void draw_menu( void ); + +#endif + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/prefs.c =================================================================== --- trunk/utils/o2xiv/src/prefs.c (rev 0) +++ trunk/utils/o2xiv/src/prefs.c 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,51 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +#include "prefs.h" + +#include <stdbool.h> +#include <stdio.h> + +bool auto_fit = true, auto_rotate = false; +Uint8 fit_pref = 0; + +void load_prefs( void ) { + FILE *f = fopen("o2xiv.pref", "rb"); + + if (f) { + fit_pref = fgetc(f); + auto_fit = fgetc(f); + auto_rotate = fgetc(f); + + fclose(f); + } +} + +void save_prefs( void ) { + FILE *f = fopen("o2xiv.pref", "wb"); + + if (f) { + fputc(fit_pref, f); + fputc(auto_fit, f); + fputc(auto_rotate, f); + + fclose(f); + } +} + +// kate: tab-width 4; Added: trunk/utils/o2xiv/src/prefs.h =================================================================== --- trunk/utils/o2xiv/src/prefs.h (rev 0) +++ trunk/utils/o2xiv/src/prefs.h 2008-09-14 20:08:20 UTC (rev 333) @@ -0,0 +1,34 @@ +/* + * O2xIV + * Copyright (C) 2008 Carl Reinke + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; witho... [truncated message content] |
From: <or...@us...> - 2008-09-13 19:40:13
|
Revision: 331 http://open2x.svn.sourceforge.net/open2x/?rev=331&view=rev Author: orkie Date: 2008-09-13 19:40:15 +0000 (Sat, 13 Sep 2008) Log Message: ----------- Fix USB host... AGAIN Modified Paths: -------------- trunk/kernel/linux-open2x-2.4.26_FW2-3/arch/arm/mach-mmsp2/proto_gpio.c Modified: trunk/kernel/linux-open2x-2.4.26_FW2-3/arch/arm/mach-mmsp2/proto_gpio.c =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/arch/arm/mach-mmsp2/proto_gpio.c 2008-09-13 09:02:46 UTC (rev 330) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/arch/arm/mach-mmsp2/proto_gpio.c 2008-09-13 19:40:15 UTC (rev 331) @@ -351,6 +351,7 @@ EXPORT_SYMBOL(SetGp2xInfo); EXPORT_SYMBOL(mmsp_set_SDCLK); EXPORT_SYMBOL(mmsp_get_SDCLK); +EXPORT_SYMBOL(mmsp_get_usbCONN); EXPORT_SYMBOL(mmsp_set_usbCONN); EXPORT_SYMBOL(mmsp_get_sdsize); EXPORT_SYMBOL(set_gpio_ctrl); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <or...@us...> - 2008-09-12 16:01:35
|
Revision: 329 http://open2x.svn.sourceforge.net/open2x/?rev=329&view=rev Author: orkie Date: 2008-09-12 16:01:39 +0000 (Fri, 12 Sep 2008) Log Message: ----------- Fix for SD automounter Modified Paths: -------------- trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/mmcsd/mmcsd_slot_mmsp2.c Modified: trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/mmcsd/mmcsd_slot_mmsp2.c =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/mmcsd/mmcsd_slot_mmsp2.c 2008-08-25 15:26:46 UTC (rev 328) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/drivers/mmcsd/mmcsd_slot_mmsp2.c 2008-09-12 16:01:39 UTC (rev 329) @@ -795,9 +795,6 @@ static void add_task_handler(void *data) { - //senquack - added to fix compilation - char argv[3][12] = {"/bin/mount", "/mnt/sd", ""}; - struct mmcsd_slot *slot = (struct mmcsd_slot *)data; int wp; slot->card_in = card_in; @@ -826,12 +823,12 @@ add_mmcsd_device(slot); #ifdef CONFIG_OPEN2X_SD_AUTOMOUNT + char *argv[3]; printk("mount...1 \n"); - // DKS - had to change to get this to compile -// argv[0] = "/bin/mount"; -// argv[1] = "/mnt/sd"; -// argv[2] = 0; + argv[0] = "/bin/mount"; + argv[1] = "/mnt/sd"; + argv[2] = 0; call_usermodehelper(argv[0], argv, 0); printk("mount...2: \n"); @@ -852,7 +849,6 @@ } - static void del_task_handler(void *data) { struct mmcsd_slot *slot = (struct mmcsd_slot *)data; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-08-25 15:27:18
|
Revision: 328 http://open2x.svn.sourceforge.net/open2x/?rev=328&view=rev Author: senquack Date: 2008-08-25 15:26:46 +0000 (Mon, 25 Aug 2008) Log Message: ----------- Added several sanity checks to reading of /etc/pointercal Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-25 09:47:45 UTC (rev 327) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-25 15:26:46 UTC (rev 328) @@ -1165,20 +1165,66 @@ // DKS // linear_dev.swap_xy = 0; - if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; - if (stat(calfile, &sbuf) == 0) { - pcal_fd = open(calfile, O_RDONLY); - read(pcal_fd, pcalbuf, 200); - linear_dev.a[0] = atoi(strtok(pcalbuf, " ")); - index = 1; - while (index < 7) { - tokptr = strtok(NULL, " "); - if (*tokptr != '\0') { - linear_dev.a[index] = atoi(tokptr); - index++; - } - } - close(pcal_fd); + + //DKS - new sanity checks for pointercal file having good values to fix segfault on empty /etc/pointercal +// if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; +// if (stat(calfile, &sbuf) == 0) { +// pcal_fd = open(calfile, O_RDONLY); +// read(pcal_fd, pcalbuf, 200); +// linear_dev.a[0] = atoi(strtok(pcalbuf, " ")); +// index = 1; +// while (index < 7) { +// tokptr = strtok(NULL, " "); +// if (*tokptr != '\0') { +// linear_dev.a[index] = atoi(tokptr); +// index++; +// } +// } +// close(pcal_fd); +// } + + TSLIB_LINEAR tmp_linear_dev; + memset(pcalbuf, 0, 200); + int got_good_values = 1; // only when this remains 1 throughout reading of /etc/pointercal will values be accepted into driver + + if ((calfile = getenv("TSLIB_CALIBFILE")) == NULL) calfile = defaultcalfile; + if (stat(calfile, &sbuf) == 0) { + pcal_fd = open(calfile, O_RDONLY); + if (pcal_fd != -1) { + int bytes_read = read(pcal_fd, pcalbuf, 200); + if (bytes_read > 0) { + tokptr = strtok(pcalbuf, " "); + if (tokptr && (isdigit(*tokptr) || (*tokptr == '-'))) { + tmp_linear_dev.a[0] = atoi(tokptr); + index = 1; + while ((index < 7) && got_good_values) { + tokptr = strtok(NULL, " "); + if (tokptr && (isdigit(*tokptr) || (*tokptr == '-'))) { + tmp_linear_dev.a[index] = atoi(tokptr); + index++; + } else { + got_good_values = 0; + } + } + } else { + got_good_values = 0; + } + } else { + got_good_values = 0; + } + + close(pcal_fd); + + } else { + got_good_values = 0; + } + + if (got_good_values) { + linear_dev = tmp_linear_dev; + fprintf(stderr, "Successfully loaded saved touchscreen calibration values.\n"); + } else { + fprintf(stderr, "Error loading saved touchscreen calibration, using default values\n"); + } } // DKS // if (tslib_parse_vars(linear_vars, NR_LINEAR_VARS, params)) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <or...@us...> - 2008-08-25 09:47:40
|
Revision: 327 http://open2x.svn.sourceforge.net/open2x/?rev=327&view=rev Author: orkie Date: 2008-08-25 09:47:45 +0000 (Mon, 25 Aug 2008) Log Message: ----------- Please start using libs-new Modified Paths: -------------- trunk/libs-new/sdl/sdl/SDL-1.2.13/configure.in trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c Added Paths: ----------- trunk/libs-new/sdl/sdl/SDL-1.2.13/README.GP2X trunk/libs-new/sdl/sdl/SDL-1.2.13/include/SDL_gp2x.h trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h Added: trunk/libs-new/sdl/sdl/SDL-1.2.13/README.GP2X =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/README.GP2X (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/README.GP2X 2008-08-25 09:47:45 UTC (rev 327) @@ -0,0 +1,295 @@ +---------------------------------------- +|Open2x - SDL Port to use GP2X hardware| +---------------------------------------- + +Version: SDL for the GP2X (Based on SDL 1.2.13) +----------------------------------------------- + +Using the official http://www.libsdl.org/ 1.2.13 release as a basis this +release aims to add advanced support for the GP2X handheld console/computer. + +This libary is part of the Open2x libs project. + + http://wiki.open2x.org/open2x/wiki/index.php?title=Libraries + +Changes from stock SDL +---------------------- + +Added hardware support, made as a seperate video driver rather than +extending fbcon driver. +Added ability to scale display surface to full-screen. +Fixed X & Y buttons. +Added (partial) hardware cursor support +Added regions - user-definable areas of the physical display to show. +Added support for non-scaled displays that are smaller than native resolution. +Added single USB mouse support. +Added USB joystick and keyboard support. +Added backlight & CPU speed adjustments. +Added preliminary TV-out control. +Added option to allow extra 16MB gfx memory +Added Touchscreen support for F200. +Added YUV support (very limited). + +TODO: + + Cursor support may be flaky on interlaced TV modes. + Better control of gfx memory. + Lots more + +Building: +--------- + +You can just install SDL onto most popular GP2X development kits by +downloading and installing a recent prebuilt library package + + http://wiki.open2x.org/open2x/wiki/index.php?title=Prebuilt_Library_Packages + +You can also build and install all the libraries by running ./open2x-libs.sh +from the root libs/ folder. Please review the README.OPEN2X in that folder for +more info. + +Lastly, you can just build SDL on its own using a configure flag something +like what is shown below. + +./configure --prefix=$LIB_ROOT --host=$HOST --disable-shared --enable-video-gp2x --enable-video-fbcon=no + + +Using: +------ + +This is SDL and can be used just like any other SDL build. + +**** +** Limitations of GP2X video driver +**** + +The primary surface (as set by SDL_SetVideoMode) is limited to 8 or 16 bit. +24 and 32 bit modes are NOT supported, driver will use 16bit instead. +SetVideoMode also forces SDL_HWSURFACE + +WARNING: Loading images with IMG_Load(filename) will create SWSURFACES, to +convert them to HWSURFACES do this: + + img_temp = IMG_Load("my_image.png"); + img = SDL_DisplayFormat(img_temp); + SDL_FreeSurface(img_temp); + +Screen sizes can be between 64x64 and 1024x768 inclusive, but the width must +be a multiple of 8 (legacy), width will be rounded up if need be. +The primary surface will be visually expanded or shrunk to fill either the +LCD or TV. The scaler is coarse only, no nice bilinear filtering. + +HWSURFACE to HWSURFACE blits are accelerated and ASYNCHRONOUS, SDL_BlitSurface +will return as soon as it has set the blit up, you MUST lock the surface if +you want to be sure the blit has taken place. + +==== +== SWSURFACE to HWSURFACE blits have moderate acceleration and SDL_BlitSurface +== will return when the blit is finished, although locking the surface is still +== required to ensure the blitter flushes its cache. +=== +== NOTE: My driver supports it, but SDL seems to not call my blit routine if +== the source surface is SWSURFACE. Will look into it later. +==== + +The harware cursor is capable of colour (although only 2), but is 24bit +regardless of the display surface. It can also alpha-blend it's fore- and +background colours at different levels, each ranging from 0=transparent to +15=opaque. + + +**** +** Additional non-standard SDL functions, GP2X specific. +** +** These are defined in the non-standard SDL_gp2x.h +**** + +//// +int SDL_GP2X_GetPhysicalScreenSize(SDL_Rect *size); + + Fills size->w and size->h with dimensions of the current screen, + LCD : 320x240 + NTSC : 720x480 + PAL : 720x576 + Returns + 0 for progressive (LCD) + 1 for interlaced (NTSC & PAL) + -1 if SDL_Init hasn't been called yet + +//// +void SDL_GP2X_Display(SDL_Rect *area); + + Sets the hardware scaler to show requested area of primary surface as + fullscreen. The scaler does not physically alter the surface, it just + affects how the surface will appear on-screen. This allows you to pan + around a surface larger than the screen, and/or zoom in/out. + You cannot zoom out further than having the full surface on-screen. + + area->x and area->y set which pixel of the primary surface will appear at + the top-left corner of the display, + area->w and area->h set the width and height of the area to fill the display. + +//// +void SDL_GP2X_MiniDisplay(int x, int y); + + Similar to the above function, but does not scale and blanks the borders. + Only really useful if your videomode is less than 320x240. Gives rise to + possible small speed increase as the display hardware doesn't access + memory in the borders. Region 1 (see SDL_GP2X_DefineRegion below) area is + set to {x, y, x+videomode_width-1, y+videomodeheight-1}. + The x & y values are where the top-left corner of you screen will placed + on the display. e.g. for a 200x200 videomode centred in the middle of the + display you'd use x=60 y=20 + NO checking is done to make sure your screen fits! + +//// +void SDL_GP2X_SetCursorColour(SDL_Cursor *cursor + int b_red, b_green, b_blue, b_alpha, + int f_red, f_green, f_blue, f_alpha); + + Sets the background and foreground colours of the hardware cursor. + SDL assumes black and white for all cursors, this lets you choose + your own colours for each cursor. Cursor colours are full 24bit, each + component wraps instead of clamping (so if you try setting red to 257 + you'll actually get 1 etc.) + Also, the background and foreground colours have seperate levels of + alpha-blending (0=transparent -> 15=opaque). Again, the values wrap. + +//// +void SDL_GP2X_DefineRegion(int region, SDL_Rect *area); + + Allows you to define regions (1-4) that will be visible. + By default region 1 is set to fullscreen (apart from when using MiniDisplay). + Regions work by defining rectangles of the display that the video hardware + will show. Think of it like painting your LCD black and for each region + you use, scrape the paint off for that rectangle. + Region areas are in hardware coordinates, 0x0 is the top-left, + 319x239 is bottom-right regardless of size and position of your surface. + +//// +void SDL_GP2X_ActivateRegion(int region, int activate); + + After defining regions above, use this to switch individual regions + on (activate = 1) or off (activate=0). + By default only region 1 is active. + There is a fifth region, region 5, but this is fullscreen only and hence + not available to SDL_GP2X_DefineRegion(). + +//// +void SDL_SYS_JoystickGp2xSys(SDL_Joystick joystick, int command); + + joystick _must_ be the value returned by SDL_JoystickOpen(0). This is + because this function relies on data that is stored in the joystick + structure of the internal joystick. To be doing anything on the GP2X + you'll more than likely be wanting access to the buttons anyway. + The values you can pass as the command are as follows: + BACK_LIGHT_OFF - Switches the backlight off ;) + BACK_LIGHT_ON - Switches the backlight back on. + BATT_LED_OFF - Switches the red battery light on. + BATT_LED_ON - Switches the red battery light off. + FCLK_200 - Runs the CPU at 200 MHz. + FCLK_166 - Runs the CPU at 166 MHz. + FCLK_133 - Runs the CPU at 133 MHz. + FCLK_100 - Runs the CPU at 100 MHz. + FCLK_78 - Runs the CPU at 78 MHz. + FCLK_64 - Runs the CPU at 64 MHz. + The following is allowed, but I've just checked the soruce for /dev/gpio to + see what speed it corresponded to and found that it doesn't actually do + anything. + FCLK_DEFAULT - Runs the CPU at it's default speed. + +//// +void SDL_GP2X_TV(int state); + + Allows user control of TV-Out. + state = 0 Internal screen on - TV off. + state = 1 TV on - internal screen off + +//// +int SDL_GP2X_TVMode(int mode); + + Allows switching of the TV-out chip's mode. + Where mode is one of :- + DISPLAY_LCD, + DISPLAY_MONITOR, + DISPLAY_TV_NTSC, + DISPLAY_TV_PAL, + DISPLAY_TV_GAME_NTSC; + +//// +void SDL_GP2X_TVAdjust(int direction); + + Allows adjustment of TV position. + Where direction is one of :- + TV_POS_LEFT, + TV_POS_RIGHT, + TV_POS_UP, + TV_POS_DOWN; + +//// +void SDL_GP2X_AllowGfxMemory(char *start, int size); + + Allows the user to make regions of upper memory available to SDL. + Call this function AFTER SDL_Init() but before SDL_SetVideoMode(). + + ** Partial implementation + ** The values are currently ignored, calling this function will enable + ** SDL to use the first 16MB of upper memory in addition to the standard + ** 5MB frame buffer. Gfx memory will be 21MB + +//// +void SDL_GP2X_DenyGfxMemory(char *start, int size); + + Allows the user to make regions of upper memory unavailable to SDL. + Call this function AFTER SDL_Init() but before SDL_SetVideoMode(). + + ** Partial implementation + ** The values are currently ignored, calling this function will prevent + ** SDL from using the first 16MB of upper memory. + ** Gfx memory will be the standard 5MB frame buffer. + +//// +void SDL_GP2X_VSync(); + + Waits for the current frame to be fully displayed. + Not needed for double buffered screens. + +//// +void *SDL_GP2X_PhysAddress(SDL_Surface *surface); + + Returns the address of the surface's bitmap for use by the 940. + Only the hardware and 940 can use the address returned by this function. + This function is only valid for hardware surfaces that have been locked + with SDL_LockSurface(). + + ** NOTE ** + You must lock the surface first, and after you unlock the surface + the pointer that was returned must be considered invalid. + + If the function returns NULL then SDL_GetError() will return one of + the following :- + + "Invalid or unlocked surface" - You passed either a null pointer or + the surface wasn't locked. + + "PhysAddress() only valid for hardware surfaces" + - You tried getting the address of a + software surface which the 940 cannot + access. + +************************************************************* +** The following functions are implemented, but not tested ** +************************************************************* + +//// +void SDL_GP2X_SetMonoColours(int background, int foreground); + **** + ** untested function + **** + When blitting a 1bpp surface, this sets what colour the 0s and 1s will + be translated into. Useful for drawing fonts. + This is a global setting, not per-surface. + +------------------------------------- + +The Open2x Project Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/configure.in =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/configure.in 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/configure.in 2008-08-25 09:47:45 UTC (rev 327) @@ -2271,7 +2271,7 @@ CheckX11 CheckNANOX CheckFBCON - CheckGP2XVideo + CheckGP2XVideo CheckDirectFB CheckPS2GS CheckGGI Added: trunk/libs-new/sdl/sdl/SDL-1.2.13/include/SDL_gp2x.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/include/SDL_gp2x.h (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/include/SDL_gp2x.h 2008-08-25 09:47:45 UTC (rev 327) @@ -0,0 +1,54 @@ +/* + * Non-standard SDL header. + * + * This header gives access to a few extra features of the GP2X hardware + * that I added to the video driver. + */ + +#ifndef SDL_GP2X__H +#define SDL_GP2X__H + +#ifdef __cplusplus +extern "C" { +#endif + +#define GP2X_MOUSE_NONE 0 +#define GP2X_MOUSE_STD 1 +#define GP2X_MOUSE_TOUCHSCREEN 2 + + +void SDL_GP2X_SetMonoColours(int background, int foreground); +int SDL_GP2X_GetPhysicalScreenSize(SDL_Rect *size); +void SDL_GP2X_Display(SDL_Rect *area); +void SDL_GP2X_InitializeCursor(); +void SDL_GP2X_SetCursorColour(WMcursor *wcursor, + int bred, int bgreen, int bblue, int balpha, + int fred, int fgreen, int fblue, int falpha); +void SDL_GP2X_DefineRegion(int region, SDL_Rect *area); +void SDL_GP2X_ActivateRegion(int region, int activate); +void SDL_GP2X_MiniDisplay(int x, int y); +void SDL_GP2X_WaitForBlitter(); + +int SDL_GP2X_TV(int state); +int SDL_GP2X_TVMode(int mode); +void SDL_GP2X_TVAdjust(int direction); + +void SDL_GP2X_AllowGfxMemory(char *start, int size); +void SDL_GP2X_DenyGfxMemory(char *start, int size); + +void SDL_GP2X_VSync(); + +// Return a hardware surface's bitmap address for use by the 940 +// Surface has to be SDL_HWSURFACE *and* SDL_LockSurface()ed +// When you unlock the surface the address you got from here *must* +// be considered invalid. +void *SDL_GP2X_PhysAddress(SDL_Surface *surface); + +// Query GP2X mouse type +int SDL_GP2X_MouseType(); + +#ifdef __cplusplus +} +#endif + +#endif Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c 2008-08-25 09:47:45 UTC (rev 327) @@ -51,12 +51,9 @@ #include "SDL.h" #include "SDL_mutex.h" - -//senquack - had to add path prefixes to all of these to get this to compile -#include "../../events/SDL_sysevents.h" #include "../SDL_sysvideo.h" #include "../../events/SDL_events_c.h" - +#include "../../events/SDL_sysevents.h" #include "SDL_gp2xvideo.h" #include "SDL_gp2xevents_c.h" #include "SDL_gp2xkeys.h" @@ -211,8 +208,7 @@ if (mousedev == NULL) { /* FIXME someday... allow multiple mice in this driver */ static const char * const ps2mice[] = { - "/dev/input/mouse/0", NULL - // "/dev/input/mouse/0", "/dev/usbmouse", "/dev/psaux", NULL + "/dev/input/mouse/0", "/dev/usbmouse", "/dev/psaux", NULL }; /* Now try to use a modern PS/2 mouse */ for (i=0; (this->hidden->mouse_fd < 0) && ps2mice[i]; ++i ) { Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c 2008-08-25 09:47:45 UTC (rev 327) @@ -30,7 +30,6 @@ #include "SDL_error.h" #include "SDL_mouse.h" -//senquack - had to add path prefix: #include "../../events/SDL_events_c.h" #include "SDL_gp2xmouse_c.h" Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c 2008-08-25 09:47:45 UTC (rev 327) @@ -44,7 +44,6 @@ #include "SDL_video.h" #include "SDL_mouse.h" -//senquack - had to add path prefixes to all of these to get this to compile #include "../SDL_sysvideo.h" #include "../SDL_pixels_c.h" #include "../../events/SDL_events_c.h" @@ -52,6 +51,7 @@ #include "SDL_gp2xvideo.h" #include "SDL_gp2xevents_c.h" #include "SDL_gp2xmouse_c.h" +#include "SDL_gp2xyuv_c.h" #include "mmsp2_regs.h" #define GP2XVID_DRIVER_NAME "GP2X" @@ -189,7 +189,7 @@ device->VideoInit = GP2X_VideoInit; device->ListModes = GP2X_ListModes; device->SetVideoMode = GP2X_SetVideoMode; - device->CreateYUVOverlay = NULL; + device->CreateYUVOverlay = GP2X_CreateYUVOverlay; device->SetColors = GP2X_SetColors; device->UpdateRects = GP2X_UpdateRects; device->VideoQuit = GP2X_VideoQuit; @@ -257,7 +257,7 @@ return -1; } data->vmem = mmap(NULL, GP2X_VIDEO_MEM_SIZE, PROT_READ|PROT_WRITE, - MAP_SHARED, data->memory_fd, 0x2000000); + MAP_SHARED, data->memory_fd, GP2X_UPPER_MEM_START); if (data->vmem == (char *)-1) { SDL_SetError("Unable to get video memory"); data->vmem = NULL; @@ -812,11 +812,14 @@ GP2X_DummyBlit(this); do {} while (data->fio[MESGSTATUS] & MESG_BUSY); + // Waiting for vblank can be used by the YUV stuff too, so I moved it into a separate function + GP2X_WaitVBlank(data); + // wait for vblank to start, choose transition type by polarity - if (data->vsync_polarity) - do {} while ((data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); - else - do {} while (!(data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); +// if (data->vsync_polarity) +// do {} while ((data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); +// else +// do {} while (!(data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); // Wait to be on even field (non-interlaced always returns 0) // do {} while (data->io[SC_STATUS] & SC_DISP_FIELD); @@ -1560,7 +1563,7 @@ { SDL_PrivateVideoData *data = current_video->hidden; char *end = start + size; - char *block = (char*)0x2000000; // Start of upper memory + char *block = (char*)GP2X_UPPER_MEM_START; // Start of upper memory data->allow_scratch_memory = 1; } Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h 2008-08-25 09:47:45 UTC (rev 327) @@ -50,6 +50,9 @@ #define GP2X_SCREEN_OFFSET 0 //0x1101000 +// This is used in both gp2xvideo and gp2xyuv, so I put it here to make maintenance easier +#define GP2X_UPPER_MEM_START 0x2000000 + // Number of native modes supported #define SDL_NUMMODES 8 Added: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c 2008-08-25 09:47:45 UTC (rev 327) @@ -0,0 +1,373 @@ +/* + SDL - Simple DirectMedia Layer - SDL_gp2xyuv.c extension + Copyright (C) 2007 Matt Ownby + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +/* This is the GP2X implementation of YUV video overlays */ + +#include <stdlib.h> +#include <string.h> +#include <fcntl.h> // for open +#include <sys/mman.h> // for mmap +#include <unistd.h> // for close + +#ifdef GP2X_DEBUG + #include <assert.h> // for self testing ... +#endif // GP2X_DEBUG + +#include "SDL_error.h" +#include "SDL_video.h" +#include "SDL_gp2xyuv_c.h" +#include "../SDL_yuvfuncs.h" +#include "mmsp2_regs.h" +//#include "arm_colorconv.h" + +/* The functions used to manipulate software video overlays */ +static struct private_yuvhwfuncs gp2x_yuvfuncs = +{ + GP2X_LockYUVOverlay, + GP2X_UnlockYUVOverlay, + GP2X_DisplayYUVOverlay, + GP2X_FreeYUVOverlay +}; + +struct private_yuvhwdata +{ + Uint8 *YUVBuf[2]; // we will have two buffers, a front and back (double buffered) + unsigned int GP2XAddr[2]; // the yuv buffer address from the gp2x's perspective + unsigned int uBackBuf; // which buffer is currently the back buffer (0 or 1) + unsigned int uBufSize; // how big the YUVBuf buffers are (in bytes) + SDL_Rect rctLast; // the last rectangle we used for displaying (so we know when to rescale/change coordinates) + Uint16 u16PixelWidth; // value stored for MLC_VLA_TP_PXW register + + /* These are just so we don't have to allocate them separately */ + Uint16 pitches[3]; + Uint8 *planes[3]; +}; + +// These are the registers (currently) modified by this code; +// They are in this array so we can restore them to their previous state after the overlay is destroyed. +const unsigned int g_pTouchedRegs[] = +{ + MLC_OVLAY_CNTR, + 0x2882 >> 1, + 0x2884 >> 1, + 0x2886 >> 1, + 0x288A >> 1, + 0x288C >> 1, + 0x2892 >> 1, + 0x2896 >> 1, + 0x2898 >> 1, + 0x289A >> 1, + 0x289C >> 1, + 0x289E >> 1, + 0x28A0 >> 1, + 0x28A2 >> 1, + 0x28A4 >> 1, + 0x28A6 >> 1, + 0x28C0 >> 1, + 0x28C2 >> 1 +}; + +const unsigned int TOUCHEDREGS_COUNT = sizeof(g_pTouchedRegs) / sizeof(unsigned int); + +// where we save the regs (compiler wouldn't let me use TOUCHEDREGS_COUNT in array) +static unsigned short g_pu16SavedRegs[sizeof(g_pTouchedRegs) / sizeof(unsigned int)]; + +#ifdef GP2X_DEBUG + // to test whether saving and restoring the regs is working + void *g_pRegTester = NULL; +#endif // GP2X_DEBUG + +// saves or restores registers that are used by the YUV code depending on 'iSave' +static void GP2X_SaveRestoreRegs(_THIS, int iSave) +{ + SDL_PrivateVideoData *data = this->hidden; + unsigned int u = 0; + + for (u = 0; u < TOUCHEDREGS_COUNT; u++) + { + // if we're saving the registers + if (iSave) + { + g_pu16SavedRegs[u] = data->io[g_pTouchedRegs[u]]; + } + // else we're restoring the registers + else + { + data->io[g_pTouchedRegs[u]] = g_pu16SavedRegs[u]; + } + } +} + +static int GP2X_SetupYUV(_THIS, int width, int height, Uint32 format, struct private_yuvhwdata *hwdata) +{ + int iSuccess = 0; + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + + hwdata->uBufSize = width * height * 2; // YUY2 is (2 * width) bytes per line + + // initialize to values that will never be used so that we force a rescale the first time GP2X_DisplayYUVOverlay is called + hwdata->rctLast.h = hwdata->rctLast.w = 0; + hwdata->rctLast.x = hwdata->rctLast.y = -1; + + hwdata->uBackBuf = 0; // arbitrary starting point (can be 0 or 1) + + // We're using GP2X_UPPER_MEM_START because that's where vmem is mapped in SDL_gp2xvideo.c + hwdata->GP2XAddr[0] = GP2X_UPPER_MEM_START; // this is where vmem is mapped from the gp2x's pov + hwdata->GP2XAddr[1] = GP2X_UPPER_MEM_START + hwdata->uBufSize; + + //map memory for our cursor + 4 YUV regions (double buffered each one) + hwdata->YUVBuf[0] = (Uint8 *) data->vmem; + hwdata->YUVBuf[1] = ((Uint8 *) data->vmem) + hwdata->uBufSize; + + // tests have shown that this value should be the width of the overlay, not the width of the display (ie not always 320) + hwdata->u16PixelWidth = width; + + // Set MLC_VLA_TP_PXW + p16GP2XRegs[0x2892>>1] = hwdata->u16PixelWidth; + + // MLC_YUV_CNTL: set YUV source to external memory for regions A and B, turn off "stepping" + p16GP2XRegs[0x2884>>1]=0; + + // disable all RGB Windows, and YUV region B + p16GP2XRegs[MLC_OVLAY_CNTR] &= ~(DISP_STL5EN|DISP_STL4EN|DISP_STL3EN|DISP_STL2EN|DISP_STL1EN|DISP_VLBON); + + // enable YUV region A + p16GP2XRegs[MLC_OVLAY_CNTR] |= DISP_VLAON; + + // disable bottom regions for A & B, and turn off all mirroring + p16GP2XRegs[0x2882>>1] &= 0xFC00; + + // Region B is disabled so we (hopefully) don't need to set anything for it + + // There currently is no way for this function to fail, but I'm leaving this in in case a future way presents itself + iSuccess = 1; + + return iSuccess; +} + +SDL_Overlay *GP2X_CreateYUVOverlay(_THIS, int width, int height, Uint32 format, SDL_Surface *display) +{ + SDL_Overlay *overlay = NULL; + struct private_yuvhwdata *hwdata; + + // we ONLY support YUY2 because that is the native gp2x YUV format + if (format != SDL_YUY2_OVERLAY) + { + printf("SDL_GP2X: Unsupported YUV format for hardware acceleration. Falling back to software.\n"); + return NULL; + } + + /* Create the overlay structure */ + overlay = (SDL_Overlay *)malloc(sizeof *overlay); + if ( overlay == NULL ) { + SDL_OutOfMemory(); + return(NULL); + } + memset(overlay, 0, (sizeof *overlay)); + + /* Fill in the basic members */ + overlay->format = format; + overlay->w = width; + overlay->h = height; + + /* Set up the YUV surface function structure */ + overlay->hwfuncs = &gp2x_yuvfuncs; + + // save our registers + GP2X_SaveRestoreRegs(this, 1); + +#ifdef GP2X_DEBUG + // this is a self-test precaution + { + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + g_pRegTester = malloc(0x50); + memcpy(g_pRegTester, (const void *) &p16GP2XRegs[0x2880 >> 1], 0x50); // store a big chunk of register info so we can compare it later + } +#endif // GP2X_DEBUG + + /* Create the pixel data and lookup tables */ + hwdata = (struct private_yuvhwdata *)malloc(sizeof *hwdata); + overlay->hwdata = hwdata; + if ( hwdata == NULL ) + { + SDL_OutOfMemory(); + SDL_FreeYUVOverlay(overlay); + return(NULL); + } + + // if YUV setup failed + if (!GP2X_SetupYUV(this, width, height, format, hwdata)) + { + SDL_FreeYUVOverlay(overlay); + return(NULL); + } + + overlay->hw_overlay = 1; + + /* Set up the plane pointers */ + overlay->pitches = hwdata->pitches; + overlay->pixels = hwdata->planes; + overlay->planes = 1; // since we only support YUY2, there is always only 1 plane + + // the pitch will always be the overlay width * 2, because we only support YUY2 + overlay->pitches[0] = overlay->w * 2; + + // start on the correct back buffer + overlay->pixels[0] = hwdata->YUVBuf[hwdata->uBackBuf]; + + /* We're all done.. */ + printf("SDL_GP2X: Created YUY2 overlay\n"); + return(overlay); +} + +int GP2X_LockYUVOverlay(_THIS, SDL_Overlay *overlay) +{ + return(0); +} + +void GP2X_UnlockYUVOverlay(_THIS, SDL_Overlay *overlay) +{ +} + +int GP2X_DisplayYUVOverlay(_THIS, SDL_Overlay *overlay, SDL_Rect *dstrect) +{ + struct private_yuvhwdata *hwdata = overlay->hwdata; + unsigned int uAddress = (unsigned int) hwdata->GP2XAddr[hwdata->uBackBuf]; + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + + // check to see if we are using a different rectangle + // (This should be a faster way than doing a bunch of conditionals and comparisons) + if (((dstrect->w ^ hwdata->rctLast.w) | (dstrect->h ^ hwdata->rctLast.h) | (dstrect->x ^ hwdata->rctLast.x) | + (dstrect->y ^ hwdata->rctLast.y)) == 0) + { + // if we get here, it means that the rectangle size has not changed, so we can flip after vblank + GP2X_WaitVBlank(data); + } + // else we are using a different rectangle + else + { + Uint16 u16HScaleVal = (unsigned short)((1024 * overlay->w) / dstrect->w); + unsigned int uVScaleVal = (unsigned int) ((hwdata->u16PixelWidth * overlay->h) / dstrect->h); + + // the boundary of the window on the right and bottom sides + // (-1 because 0 is the first pixel) + Sint16 s16Right, s16Bottom; + Sint16 x = dstrect->x; + Sint16 y = dstrect->y; + +#ifdef GP2X_DEBUG + // warn the user if this extra math is being done every frame + printf("SDL_GP2X: GP2X YUV Overlay is being resized. This usually should NOT happen every frame!\n"); +#endif // GP2X_DEV + + // gp2x doesn't seem to handle negative coordinates + if (x < 0) x = 0; + if (y < 0) y = 0; + + s16Right = x + (dstrect->w - 1); + s16Bottom = y + (dstrect->h - 1); + + // gp2x doesn't seem like the coordinates going outside the physical boundaries + if (s16Right > 319) s16Right = 319; + if (s16Bottom > 239) s16Bottom = 239; + + // now that we've done all the calculations we can before changing registers, wait for vblank + GP2X_WaitVBlank(data); + + // we need to rescale now ... + // MLC_YUVA_TP_HSC (horizontal scale factor of Region A, top) + p16GP2XRegs[0x2886>>1] = u16HScaleVal; + + // MLC_YUVA_TP_VSC[L/H] (vertical scale factor of Region A, top) + p16GP2XRegs[0x288A>>1] = (unsigned short) (uVScaleVal & 0xFFFF); + p16GP2XRegs[0x288C>>1] = (unsigned short) (uVScaleVal >> 16); // this will usually be 0 + + // NOW SET COORDINATES + + // MLC_YUVA_STX (X start coordinate of region A) + p16GP2XRegs[0x2896>>1]=x; + + // MLC_YUVA_ENDX (X stop coordinate of region A) + p16GP2XRegs[0x2898>>1]=s16Right; + + // MLC_YUV_TP_STY (Y start coordinate of region A top) + p16GP2XRegs[0x289A>>1]=y; + + // MLC_YUV_TP_ENDY (Y stop coordinate of region A top, and the start of the bottom) + p16GP2XRegs[0x289C>>1] = s16Bottom; + + // MLC_YUV_BT_ENDY (Y stop coordinate of region A bottom) + p16GP2XRegs[0x289E>>1] = s16Bottom; + + // copy new rectangle over to rctLast so that we don't do this stuff on every single frame + hwdata->rctLast = *dstrect; + } + + // NOW FLIP THE ACTUAL BUFFER + + // NOTE : I am flipping the odd and even fields here because that's how rlyeh did it, but I am not sure + // whether both of these need to be flipped. + + // region A, odd fields + p16GP2XRegs[0x28A0>>1] = (uAddress & 0xFFFF); + p16GP2XRegs[0x28A2>>1] = (uAddress >> 16); + + // region A, even fields + p16GP2XRegs[0x28A4>>1] = (uAddress & 0xFFFF); + p16GP2XRegs[0x28A6>>1] = (uAddress >> 16); + + // change back buffer to the other buffer (can be 0 or 1, so XOR works nicely) + hwdata->uBackBuf ^= 1; + + // update the pixel pointer to new back buffer + overlay->pixels[0] = hwdata->YUVBuf[hwdata->uBackBuf]; + + return(0); +} + +void GP2X_FreeYUVOverlay(_THIS, SDL_Overlay *overlay) +{ + struct private_yuvhwdata *hwdata; + unsigned short volatile *p16GP2XRegs = this->hidden->io; + + hwdata = overlay->hwdata; + + if ( hwdata ) + { + free(hwdata); + } + + // restore our registers + GP2X_SaveRestoreRegs(this, 0); + +#ifdef GP2X_DEBUG + // this is a self-test precaution + + // make sure that the registers were restored properly + assert (memcmp(g_pRegTester, (const void *) &p16GP2XRegs[0x2880 >> 1], 0x50) == 0); + + free(g_pRegTester); +#endif // GP2X_DEBUG + +} + + Added: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h (rev 0) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h 2008-08-25 09:47:45 UTC (rev 327) @@ -0,0 +1,34 @@ +/* + SDL - Simple DirectMedia Layer - SDL_gp2xyuv extension + Copyright (C) 2007 Matt Ownby + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +/* This is the GP2X implementation of YUV video overlays */ + +#include "SDL_video.h" +#include "SDL_gp2xvideo.h" + +extern SDL_Overlay *GP2X_CreateYUVOverlay(_THIS, int width, int height, Uint32 format, SDL_Surface *display); + +extern int GP2X_LockYUVOverlay(_THIS, SDL_Overlay *overlay); + +extern void GP2X_UnlockYUVOverlay(_THIS, SDL_Overlay *overlay); + +extern int GP2X_DisplayYUVOverlay(_THIS, SDL_Overlay *overlay, SDL_Rect *dstrect); + +extern void GP2X_FreeYUVOverlay(_THIS, SDL_Overlay *overlay); + Modified: trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c =================================================================== --- trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-19 11:43:56 UTC (rev 326) +++ trunk/libs-new/sdl/sdl/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-25 09:47:45 UTC (rev 327) @@ -722,6 +722,206 @@ int y; } XYHIST; +#define XYHISTLENGTH 15 +XYHIST average_xyhist[XYHISTLENGTH]; + +static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + + int ret = 0; + int newx, newy; + + int flush_history = 0; // variance module will tell us if we are getting fast movements + static int flush_count = 0; // when we get enough fast movements, flush the history + static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 + static int xyhist_counter = 0; // DKS - how many entires in history? + static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array + + ret = variance_read(ts, samp, nr, &flush_history); + flush_count += flush_history; + struct ts_sample *s; + s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x + // touchscreen driver only ever provides 1 sample each read so + // it's not really necessary but not really inefficient either way + int i; + + for( i = ret; i > 0; i--, s--) { + if ((s->pressure == 0) || (flush_count > 7)) { + // when pen is lifted, or a fast movement is detected, flush stored history + xyhist_full = 0; + xyhist_counter = 0; + xyhist_index = 0; + flush_count = 0; + } else { + average_xyhist[xyhist_index].x = s->x; + average_xyhist[xyhist_index].y = s->y; + + xyhist_counter++; + if (xyhist_counter == XYHISTLENGTH) { + xyhist_full = 1; + } + + xyhist_index++; + if (xyhist_index == XYHISTLENGTH) { + xyhist_index = 0; // point back at beginning since array is full + } + + if (xyhist_full) { + //we have a full sample history, we can average this sample with the others + + int j = xyhist_index - 1; // point j to most recent entry in history + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // 15-sample weighted average, pyramid, provides great smoothing for precise + // operations like menus and drawing + + // sample 1 has weight of * 1 + newx = average_xyhist[j].x; + newy = average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 2 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 3 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 4 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 5 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 6 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 7 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 8, middle sample, has weight of * 8 + newx += (average_xyhist[j].x << 3); + newy += (average_xyhist[j].y << 3); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 9 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 10 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 11 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 12 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 13 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 14 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 15 has weight of * 1 + newx += average_xyhist[j].x; + newy += average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // divide results by 64 to provide average + samp->x = newx >> 6; + samp->y = newy >> 6; + } + } + } + + return ret; +} +//DKS - non-pyramid form of the above, I cannot tell a real difference, will use pyramid for now. //#define XYHISTLENGTH 15 //XYHIST average_xyhist[XYHISTLENGTH]; // @@ -777,70 +977,69 @@ // // 15-sample weighted average, pyramid, provides great smoothing for precise // // operations like menus and drawing // -// // sample 1 has weight of * 1 -// newx = average_xyhist[j].x; -// newy = average_xyhist[j].y; +// // sample 1 has weight of * 15 +// newx = average_xyhist[j].x * 15; +// newy = average_xyhist[j].y * 15; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 2 has weight of * 2 -// newx += average_xyhist[j].x << 1; -// newy += average_xyhist[j].y << 1; +// // sample 2 has weight of * 14 +// newx += average_xyhist[j].x * 14; +// newy += average_xyhist[j].y * 14; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 3 has weight of * 3 -// newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; -// +// // sample 3 has weight of * 13 +// newx += average_xyhist[j].x * 13; +// newy += average_xyhist[j].y * 13; // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 4 has weight of * 4 -// newx += average_xyhist[j].x << 2; -// newy += average_xyhist[j].y << 2; +// // sample 4 has weight of * 12 +// newx += average_xyhist[j].x * 12; +// newy += average_xyhist[j].y * 12; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 5 has weight of * 5 -// newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; +// // sample 5 has weight of * 11 +// newx += average_xyhist[j].x * 11; +// newy += average_xyhist[j].y * 11; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 6 has weight of * 6 -// newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); -// newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); +// // sample 6 has weight of * 10 +// newx += average_xyhist[j].x * 10; +// newy += average_xyhist[j].y * 10; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 7 has weight of * 7 -// newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; -// newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; +// // sample 7 has weight of * 9 +// newx += average_xyhist[j].x * 9; +// newy += average_xyhist[j].y * 9; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 8, middle sample, has weight of * 8 +// // sample 8, middle sample, has weight of * 8 // newx += (average_xyhist[j].x << 3); // newy += (average_xyhist[j].y << 3); // @@ -912,213 +1111,15 @@ // j = XYHISTLENGTH - 1; // } // -// // divide results by 64 to provide average -// samp->x = newx >> 6; -// samp->y = newy >> 6; +// samp->x = newx / 120; +// samp->y = newy / 120; // } // } // } // // return ret; //} -#define XYHISTLENGTH 5 -XYHIST average_xyhist[XYHISTLENGTH]; -static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) -{ - - int ret = 0; - int newx, newy; - - int flush_history = 0; // variance module will tell us if we are getting fast movements - static int flush_count = 0; // when we get enough fast movements, flush the history - static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 - static int xyhist_counter = 0; // DKS - how many entires in history? - static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array - - ret = variance_read(ts, samp, nr, &flush_history); - flush_count += flush_history; - struct ts_sample *s; - s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x - // touchscreen driver only ever provides 1 sample each read so - // it's not really necessary but not really inefficient either way - int i; - - for( i = ret; i > 0; i--, s--) { - if ((s->pressure == 0) || (flush_count > 7)) { - // when pen is lifted, or a fast movement is detected, flush stored history - xyhist_full = 0; - xyhist_counter = 0; - xyhist_index = 0; - flush_count = 0; - } else { - average_xyhist[xyhist_index].x = s->x; - average_xyhist[xyhist_index].y = s->y; - - xyhist_counter++; - if (xyhist_counter == XYHISTLENGTH) { - xyhist_full = 1; - } - - xyhist_index++; - if (xyhist_index == XYHISTLENGTH) { - xyhist_index = 0; // point back at beginning since array is full - } - - if (xyhist_full) { - //we have a full sample history, we can average this sample with the others - - int j = xyhist_index - 1; // point j to most recent entry in history - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // 15-sample weighted average, pyramid, provides great smoothing for precise - // operations like menus and drawing - - // sample 1 has weight of * 15 - newx = average_xyhist[j].x * 15; - newy = average_xyhist[j].y * 15; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 2 has weight of * 14 - newx += average_xyhist[j].x * 14; - newy += average_xyhist[j].y * 14; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 3 has weight of * 13 - newx += average_xyhist[j].x * 13; - newy += average_xyhist[j].y * 13; - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 4 has weight of * 12 - newx += average_xyhist[j].x * 12; - newy += average_xyhist[j].y * 12; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 5 has weight of * 11 - newx += average_xyhist[j].x * 11; - newy += average_xyhist[j].y * 11; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 6 has weight of * 10 - newx += average_xyhist[j].x * 10; - newy += average_xyhist[j].y * 10; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 7 has weight of * 9 - newx += average_xyhist[j].x * 9; - newy += average_xyhist[j].y * 9; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 8, middle sample, has weight of * 8 - newx += (average_xyhist[j].x << 3); - newy += (average_xyhist[j].y << 3); - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 9 has weight of * 7 - newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; - newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 10 has weight of * 6 - newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); - newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 11 has weight of * 5 - newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; - newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 12 has weight of * 4 - newx += average_xyhist[j].x << 2; - newy += average_xyhist[j].y << 2; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 13 has weight of * 3 - newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; - newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 14 has weight of * 2 - newx += average_xyhist[j].x << 1; - newy += average_xyhist[j].y << 1; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 15 has weight of * 1 - newx += average_xyhist[j].x; - newy += average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - samp->x = newx / 120; - samp->y = newy / 120; - } - } - } - - return ret; -} - /****************************** * linear ******************************/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <djw...@us...> - 2008-08-19 11:43:49
|
Revision: 326 http://open2x.svn.sourceforge.net/open2x/?rev=326&view=rev Author: djwillis Date: 2008-08-19 11:43:56 +0000 (Tue, 19 Aug 2008) Log Message: ----------- Merge some missing functionality into the SDL 1.2.13 tree from the 1.2.11 backend and a few small cleanups, put the README.GP2X back etc.. Compile tested and ScummVM built with it. If there are problems let me know and I will revery/sort the commit. - John Modified Paths: -------------- trunk/libs/SDL-1.2.13/configure.in trunk/libs/SDL-1.2.13/sdl.pc trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h Added Paths: ----------- trunk/libs/SDL-1.2.13/README.GP2X trunk/libs/SDL-1.2.13/include/SDL_gp2x.h trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h Added: trunk/libs/SDL-1.2.13/README.GP2X =================================================================== --- trunk/libs/SDL-1.2.13/README.GP2X (rev 0) +++ trunk/libs/SDL-1.2.13/README.GP2X 2008-08-19 11:43:56 UTC (rev 326) @@ -0,0 +1,295 @@ +---------------------------------------- +|Open2x - SDL Port to use GP2X hardware| +---------------------------------------- + +Version: SDL for the GP2X (Based on SDL 1.2.13) +----------------------------------------------- + +Using the official http://www.libsdl.org/ 1.2.13 release as a basis this +release aims to add advanced support for the GP2X handheld console/computer. + +This libary is part of the Open2x libs project. + + http://wiki.open2x.org/open2x/wiki/index.php?title=Libraries + +Changes from stock SDL +---------------------- + +Added hardware support, made as a seperate video driver rather than +extending fbcon driver. +Added ability to scale display surface to full-screen. +Fixed X & Y buttons. +Added (partial) hardware cursor support +Added regions - user-definable areas of the physical display to show. +Added support for non-scaled displays that are smaller than native resolution. +Added single USB mouse support. +Added USB joystick and keyboard support. +Added backlight & CPU speed adjustments. +Added preliminary TV-out control. +Added option to allow extra 16MB gfx memory +Added Touchscreen support for F200. +Added YUV support (very limited). + +TODO: + + Cursor support may be flaky on interlaced TV modes. + Better control of gfx memory. + Lots more + +Building: +--------- + +You can just install SDL onto most popular GP2X development kits by +downloading and installing a recent prebuilt library package + + http://wiki.open2x.org/open2x/wiki/index.php?title=Prebuilt_Library_Packages + +You can also build and install all the libraries by running ./open2x-libs.sh +from the root libs/ folder. Please review the README.OPEN2X in that folder for +more info. + +Lastly, you can just build SDL on its own using a configure flag something +like what is shown below. + +./configure --prefix=$LIB_ROOT --host=$HOST --disable-shared --enable-video-gp2x --enable-video-fbcon=no + + +Using: +------ + +This is SDL and can be used just like any other SDL build. + +**** +** Limitations of GP2X video driver +**** + +The primary surface (as set by SDL_SetVideoMode) is limited to 8 or 16 bit. +24 and 32 bit modes are NOT supported, driver will use 16bit instead. +SetVideoMode also forces SDL_HWSURFACE + +WARNING: Loading images with IMG_Load(filename) will create SWSURFACES, to +convert them to HWSURFACES do this: + + img_temp = IMG_Load("my_image.png"); + img = SDL_DisplayFormat(img_temp); + SDL_FreeSurface(img_temp); + +Screen sizes can be between 64x64 and 1024x768 inclusive, but the width must +be a multiple of 8 (legacy), width will be rounded up if need be. +The primary surface will be visually expanded or shrunk to fill either the +LCD or TV. The scaler is coarse only, no nice bilinear filtering. + +HWSURFACE to HWSURFACE blits are accelerated and ASYNCHRONOUS, SDL_BlitSurface +will return as soon as it has set the blit up, you MUST lock the surface if +you want to be sure the blit has taken place. + +==== +== SWSURFACE to HWSURFACE blits have moderate acceleration and SDL_BlitSurface +== will return when the blit is finished, although locking the surface is still +== required to ensure the blitter flushes its cache. +=== +== NOTE: My driver supports it, but SDL seems to not call my blit routine if +== the source surface is SWSURFACE. Will look into it later. +==== + +The harware cursor is capable of colour (although only 2), but is 24bit +regardless of the display surface. It can also alpha-blend it's fore- and +background colours at different levels, each ranging from 0=transparent to +15=opaque. + + +**** +** Additional non-standard SDL functions, GP2X specific. +** +** These are defined in the non-standard SDL_gp2x.h +**** + +//// +int SDL_GP2X_GetPhysicalScreenSize(SDL_Rect *size); + + Fills size->w and size->h with dimensions of the current screen, + LCD : 320x240 + NTSC : 720x480 + PAL : 720x576 + Returns + 0 for progressive (LCD) + 1 for interlaced (NTSC & PAL) + -1 if SDL_Init hasn't been called yet + +//// +void SDL_GP2X_Display(SDL_Rect *area); + + Sets the hardware scaler to show requested area of primary surface as + fullscreen. The scaler does not physically alter the surface, it just + affects how the surface will appear on-screen. This allows you to pan + around a surface larger than the screen, and/or zoom in/out. + You cannot zoom out further than having the full surface on-screen. + + area->x and area->y set which pixel of the primary surface will appear at + the top-left corner of the display, + area->w and area->h set the width and height of the area to fill the display. + +//// +void SDL_GP2X_MiniDisplay(int x, int y); + + Similar to the above function, but does not scale and blanks the borders. + Only really useful if your videomode is less than 320x240. Gives rise to + possible small speed increase as the display hardware doesn't access + memory in the borders. Region 1 (see SDL_GP2X_DefineRegion below) area is + set to {x, y, x+videomode_width-1, y+videomodeheight-1}. + The x & y values are where the top-left corner of you screen will placed + on the display. e.g. for a 200x200 videomode centred in the middle of the + display you'd use x=60 y=20 + NO checking is done to make sure your screen fits! + +//// +void SDL_GP2X_SetCursorColour(SDL_Cursor *cursor + int b_red, b_green, b_blue, b_alpha, + int f_red, f_green, f_blue, f_alpha); + + Sets the background and foreground colours of the hardware cursor. + SDL assumes black and white for all cursors, this lets you choose + your own colours for each cursor. Cursor colours are full 24bit, each + component wraps instead of clamping (so if you try setting red to 257 + you'll actually get 1 etc.) + Also, the background and foreground colours have seperate levels of + alpha-blending (0=transparent -> 15=opaque). Again, the values wrap. + +//// +void SDL_GP2X_DefineRegion(int region, SDL_Rect *area); + + Allows you to define regions (1-4) that will be visible. + By default region 1 is set to fullscreen (apart from when using MiniDisplay). + Regions work by defining rectangles of the display that the video hardware + will show. Think of it like painting your LCD black and for each region + you use, scrape the paint off for that rectangle. + Region areas are in hardware coordinates, 0x0 is the top-left, + 319x239 is bottom-right regardless of size and position of your surface. + +//// +void SDL_GP2X_ActivateRegion(int region, int activate); + + After defining regions above, use this to switch individual regions + on (activate = 1) or off (activate=0). + By default only region 1 is active. + There is a fifth region, region 5, but this is fullscreen only and hence + not available to SDL_GP2X_DefineRegion(). + +//// +void SDL_SYS_JoystickGp2xSys(SDL_Joystick joystick, int command); + + joystick _must_ be the value returned by SDL_JoystickOpen(0). This is + because this function relies on data that is stored in the joystick + structure of the internal joystick. To be doing anything on the GP2X + you'll more than likely be wanting access to the buttons anyway. + The values you can pass as the command are as follows: + BACK_LIGHT_OFF - Switches the backlight off ;) + BACK_LIGHT_ON - Switches the backlight back on. + BATT_LED_OFF - Switches the red battery light on. + BATT_LED_ON - Switches the red battery light off. + FCLK_200 - Runs the CPU at 200 MHz. + FCLK_166 - Runs the CPU at 166 MHz. + FCLK_133 - Runs the CPU at 133 MHz. + FCLK_100 - Runs the CPU at 100 MHz. + FCLK_78 - Runs the CPU at 78 MHz. + FCLK_64 - Runs the CPU at 64 MHz. + The following is allowed, but I've just checked the soruce for /dev/gpio to + see what speed it corresponded to and found that it doesn't actually do + anything. + FCLK_DEFAULT - Runs the CPU at it's default speed. + +//// +void SDL_GP2X_TV(int state); + + Allows user control of TV-Out. + state = 0 Internal screen on - TV off. + state = 1 TV on - internal screen off + +//// +int SDL_GP2X_TVMode(int mode); + + Allows switching of the TV-out chip's mode. + Where mode is one of :- + DISPLAY_LCD, + DISPLAY_MONITOR, + DISPLAY_TV_NTSC, + DISPLAY_TV_PAL, + DISPLAY_TV_GAME_NTSC; + +//// +void SDL_GP2X_TVAdjust(int direction); + + Allows adjustment of TV position. + Where direction is one of :- + TV_POS_LEFT, + TV_POS_RIGHT, + TV_POS_UP, + TV_POS_DOWN; + +//// +void SDL_GP2X_AllowGfxMemory(char *start, int size); + + Allows the user to make regions of upper memory available to SDL. + Call this function AFTER SDL_Init() but before SDL_SetVideoMode(). + + ** Partial implementation + ** The values are currently ignored, calling this function will enable + ** SDL to use the first 16MB of upper memory in addition to the standard + ** 5MB frame buffer. Gfx memory will be 21MB + +//// +void SDL_GP2X_DenyGfxMemory(char *start, int size); + + Allows the user to make regions of upper memory unavailable to SDL. + Call this function AFTER SDL_Init() but before SDL_SetVideoMode(). + + ** Partial implementation + ** The values are currently ignored, calling this function will prevent + ** SDL from using the first 16MB of upper memory. + ** Gfx memory will be the standard 5MB frame buffer. + +//// +void SDL_GP2X_VSync(); + + Waits for the current frame to be fully displayed. + Not needed for double buffered screens. + +//// +void *SDL_GP2X_PhysAddress(SDL_Surface *surface); + + Returns the address of the surface's bitmap for use by the 940. + Only the hardware and 940 can use the address returned by this function. + This function is only valid for hardware surfaces that have been locked + with SDL_LockSurface(). + + ** NOTE ** + You must lock the surface first, and after you unlock the surface + the pointer that was returned must be considered invalid. + + If the function returns NULL then SDL_GetError() will return one of + the following :- + + "Invalid or unlocked surface" - You passed either a null pointer or + the surface wasn't locked. + + "PhysAddress() only valid for hardware surfaces" + - You tried getting the address of a + software surface which the 940 cannot + access. + +************************************************************* +** The following functions are implemented, but not tested ** +************************************************************* + +//// +void SDL_GP2X_SetMonoColours(int background, int foreground); + **** + ** untested function + **** + When blitting a 1bpp surface, this sets what colour the 0s and 1s will + be translated into. Useful for drawing fonts. + This is a global setting, not per-surface. + +------------------------------------- + +The Open2x Project Modified: trunk/libs/SDL-1.2.13/configure.in =================================================================== --- trunk/libs/SDL-1.2.13/configure.in 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/configure.in 2008-08-19 11:43:56 UTC (rev 326) @@ -2271,7 +2271,7 @@ CheckX11 CheckNANOX CheckFBCON - CheckGP2XVideo + CheckGP2XVideo CheckDirectFB CheckPS2GS CheckGGI Added: trunk/libs/SDL-1.2.13/include/SDL_gp2x.h =================================================================== --- trunk/libs/SDL-1.2.13/include/SDL_gp2x.h (rev 0) +++ trunk/libs/SDL-1.2.13/include/SDL_gp2x.h 2008-08-19 11:43:56 UTC (rev 326) @@ -0,0 +1,54 @@ +/* + * Non-standard SDL header. + * + * This header gives access to a few extra features of the GP2X hardware + * that I added to the video driver. + */ + +#ifndef SDL_GP2X__H +#define SDL_GP2X__H + +#ifdef __cplusplus +extern "C" { +#endif + +#define GP2X_MOUSE_NONE 0 +#define GP2X_MOUSE_STD 1 +#define GP2X_MOUSE_TOUCHSCREEN 2 + + +void SDL_GP2X_SetMonoColours(int background, int foreground); +int SDL_GP2X_GetPhysicalScreenSize(SDL_Rect *size); +void SDL_GP2X_Display(SDL_Rect *area); +void SDL_GP2X_InitializeCursor(); +void SDL_GP2X_SetCursorColour(WMcursor *wcursor, + int bred, int bgreen, int bblue, int balpha, + int fred, int fgreen, int fblue, int falpha); +void SDL_GP2X_DefineRegion(int region, SDL_Rect *area); +void SDL_GP2X_ActivateRegion(int region, int activate); +void SDL_GP2X_MiniDisplay(int x, int y); +void SDL_GP2X_WaitForBlitter(); + +int SDL_GP2X_TV(int state); +int SDL_GP2X_TVMode(int mode); +void SDL_GP2X_TVAdjust(int direction); + +void SDL_GP2X_AllowGfxMemory(char *start, int size); +void SDL_GP2X_DenyGfxMemory(char *start, int size); + +void SDL_GP2X_VSync(); + +// Return a hardware surface's bitmap address for use by the 940 +// Surface has to be SDL_HWSURFACE *and* SDL_LockSurface()ed +// When you unlock the surface the address you got from here *must* +// be considered invalid. +void *SDL_GP2X_PhysAddress(SDL_Surface *surface); + +// Query GP2X mouse type +int SDL_GP2X_MouseType(); + +#ifdef __cplusplus +} +#endif + +#endif Modified: trunk/libs/SDL-1.2.13/sdl.pc =================================================================== --- trunk/libs/SDL-1.2.13/sdl.pc 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/sdl.pc 2008-08-19 11:43:56 UTC (rev 326) @@ -1,6 +1,6 @@ # sdl pkg-config source file -prefix=/home/senquack/projects/open2x/build/open2x/gcc-4.1.1-glibc-2.3.6 +prefix=/opt/open2x/gcc-4.1.1-glibc-2.3.6 exec_prefix=${prefix} libdir=${exec_prefix}/lib includedir=${prefix}/include Modified: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xevents.c 2008-08-19 11:43:56 UTC (rev 326) @@ -51,12 +51,9 @@ #include "SDL.h" #include "SDL_mutex.h" - -//senquack - had to add path prefixes to all of these to get this to compile -#include "../../events/SDL_sysevents.h" #include "../SDL_sysvideo.h" #include "../../events/SDL_events_c.h" - +#include "../../events/SDL_sysevents.h" #include "SDL_gp2xvideo.h" #include "SDL_gp2xevents_c.h" #include "SDL_gp2xkeys.h" @@ -211,8 +208,7 @@ if (mousedev == NULL) { /* FIXME someday... allow multiple mice in this driver */ static const char * const ps2mice[] = { - "/dev/input/mouse/0", NULL - // "/dev/input/mouse/0", "/dev/usbmouse", "/dev/psaux", NULL + "/dev/input/mouse/0", "/dev/usbmouse", "/dev/psaux", NULL }; /* Now try to use a modern PS/2 mouse */ for (i=0; (this->hidden->mouse_fd < 0) && ps2mice[i]; ++i ) { Modified: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xmouse.c 2008-08-19 11:43:56 UTC (rev 326) @@ -30,7 +30,6 @@ #include "SDL_error.h" #include "SDL_mouse.h" -//senquack - had to add path prefix: #include "../../events/SDL_events_c.h" #include "SDL_gp2xmouse_c.h" Modified: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.c 2008-08-19 11:43:56 UTC (rev 326) @@ -44,7 +44,6 @@ #include "SDL_video.h" #include "SDL_mouse.h" -//senquack - had to add path prefixes to all of these to get this to compile #include "../SDL_sysvideo.h" #include "../SDL_pixels_c.h" #include "../../events/SDL_events_c.h" @@ -52,6 +51,7 @@ #include "SDL_gp2xvideo.h" #include "SDL_gp2xevents_c.h" #include "SDL_gp2xmouse_c.h" +#include "SDL_gp2xyuv_c.h" #include "mmsp2_regs.h" #define GP2XVID_DRIVER_NAME "GP2X" @@ -189,7 +189,7 @@ device->VideoInit = GP2X_VideoInit; device->ListModes = GP2X_ListModes; device->SetVideoMode = GP2X_SetVideoMode; - device->CreateYUVOverlay = NULL; + device->CreateYUVOverlay = GP2X_CreateYUVOverlay; device->SetColors = GP2X_SetColors; device->UpdateRects = GP2X_UpdateRects; device->VideoQuit = GP2X_VideoQuit; @@ -257,7 +257,7 @@ return -1; } data->vmem = mmap(NULL, GP2X_VIDEO_MEM_SIZE, PROT_READ|PROT_WRITE, - MAP_SHARED, data->memory_fd, 0x2000000); + MAP_SHARED, data->memory_fd, GP2X_UPPER_MEM_START); if (data->vmem == (char *)-1) { SDL_SetError("Unable to get video memory"); data->vmem = NULL; @@ -812,11 +812,14 @@ GP2X_DummyBlit(this); do {} while (data->fio[MESGSTATUS] & MESG_BUSY); + // Waiting for vblank can be used by the YUV stuff too, so I moved it into a separate function + GP2X_WaitVBlank(data); + // wait for vblank to start, choose transition type by polarity - if (data->vsync_polarity) - do {} while ((data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); - else - do {} while (!(data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); +// if (data->vsync_polarity) +// do {} while ((data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); +// else +// do {} while (!(data->io[GPIOB_PINLVL] & GPIOB_VSYNC)); // Wait to be on even field (non-interlaced always returns 0) // do {} while (data->io[SC_STATUS] & SC_DISP_FIELD); @@ -1560,7 +1563,7 @@ { SDL_PrivateVideoData *data = current_video->hidden; char *end = start + size; - char *block = (char*)0x2000000; // Start of upper memory + char *block = (char*)GP2X_UPPER_MEM_START; // Start of upper memory data->allow_scratch_memory = 1; } Modified: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h 2008-08-18 20:29:31 UTC (rev 325) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xvideo.h 2008-08-19 11:43:56 UTC (rev 326) @@ -50,6 +50,9 @@ #define GP2X_SCREEN_OFFSET 0 //0x1101000 +// This is used in both gp2xvideo and gp2xyuv, so I put it here to make maintenance easier +#define GP2X_UPPER_MEM_START 0x2000000 + // Number of native modes supported #define SDL_NUMMODES 8 Added: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c (rev 0) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv.c 2008-08-19 11:43:56 UTC (rev 326) @@ -0,0 +1,373 @@ +/* + SDL - Simple DirectMedia Layer - SDL_gp2xyuv.c extension + Copyright (C) 2007 Matt Ownby + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +/* This is the GP2X implementation of YUV video overlays */ + +#include <stdlib.h> +#include <string.h> +#include <fcntl.h> // for open +#include <sys/mman.h> // for mmap +#include <unistd.h> // for close + +#ifdef GP2X_DEBUG + #include <assert.h> // for self testing ... +#endif // GP2X_DEBUG + +#include "SDL_error.h" +#include "SDL_video.h" +#include "SDL_gp2xyuv_c.h" +#include "../SDL_yuvfuncs.h" +#include "mmsp2_regs.h" +//#include "arm_colorconv.h" + +/* The functions used to manipulate software video overlays */ +static struct private_yuvhwfuncs gp2x_yuvfuncs = +{ + GP2X_LockYUVOverlay, + GP2X_UnlockYUVOverlay, + GP2X_DisplayYUVOverlay, + GP2X_FreeYUVOverlay +}; + +struct private_yuvhwdata +{ + Uint8 *YUVBuf[2]; // we will have two buffers, a front and back (double buffered) + unsigned int GP2XAddr[2]; // the yuv buffer address from the gp2x's perspective + unsigned int uBackBuf; // which buffer is currently the back buffer (0 or 1) + unsigned int uBufSize; // how big the YUVBuf buffers are (in bytes) + SDL_Rect rctLast; // the last rectangle we used for displaying (so we know when to rescale/change coordinates) + Uint16 u16PixelWidth; // value stored for MLC_VLA_TP_PXW register + + /* These are just so we don't have to allocate them separately */ + Uint16 pitches[3]; + Uint8 *planes[3]; +}; + +// These are the registers (currently) modified by this code; +// They are in this array so we can restore them to their previous state after the overlay is destroyed. +const unsigned int g_pTouchedRegs[] = +{ + MLC_OVLAY_CNTR, + 0x2882 >> 1, + 0x2884 >> 1, + 0x2886 >> 1, + 0x288A >> 1, + 0x288C >> 1, + 0x2892 >> 1, + 0x2896 >> 1, + 0x2898 >> 1, + 0x289A >> 1, + 0x289C >> 1, + 0x289E >> 1, + 0x28A0 >> 1, + 0x28A2 >> 1, + 0x28A4 >> 1, + 0x28A6 >> 1, + 0x28C0 >> 1, + 0x28C2 >> 1 +}; + +const unsigned int TOUCHEDREGS_COUNT = sizeof(g_pTouchedRegs) / sizeof(unsigned int); + +// where we save the regs (compiler wouldn't let me use TOUCHEDREGS_COUNT in array) +static unsigned short g_pu16SavedRegs[sizeof(g_pTouchedRegs) / sizeof(unsigned int)]; + +#ifdef GP2X_DEBUG + // to test whether saving and restoring the regs is working + void *g_pRegTester = NULL; +#endif // GP2X_DEBUG + +// saves or restores registers that are used by the YUV code depending on 'iSave' +static void GP2X_SaveRestoreRegs(_THIS, int iSave) +{ + SDL_PrivateVideoData *data = this->hidden; + unsigned int u = 0; + + for (u = 0; u < TOUCHEDREGS_COUNT; u++) + { + // if we're saving the registers + if (iSave) + { + g_pu16SavedRegs[u] = data->io[g_pTouchedRegs[u]]; + } + // else we're restoring the registers + else + { + data->io[g_pTouchedRegs[u]] = g_pu16SavedRegs[u]; + } + } +} + +static int GP2X_SetupYUV(_THIS, int width, int height, Uint32 format, struct private_yuvhwdata *hwdata) +{ + int iSuccess = 0; + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + + hwdata->uBufSize = width * height * 2; // YUY2 is (2 * width) bytes per line + + // initialize to values that will never be used so that we force a rescale the first time GP2X_DisplayYUVOverlay is called + hwdata->rctLast.h = hwdata->rctLast.w = 0; + hwdata->rctLast.x = hwdata->rctLast.y = -1; + + hwdata->uBackBuf = 0; // arbitrary starting point (can be 0 or 1) + + // We're using GP2X_UPPER_MEM_START because that's where vmem is mapped in SDL_gp2xvideo.c + hwdata->GP2XAddr[0] = GP2X_UPPER_MEM_START; // this is where vmem is mapped from the gp2x's pov + hwdata->GP2XAddr[1] = GP2X_UPPER_MEM_START + hwdata->uBufSize; + + //map memory for our cursor + 4 YUV regions (double buffered each one) + hwdata->YUVBuf[0] = (Uint8 *) data->vmem; + hwdata->YUVBuf[1] = ((Uint8 *) data->vmem) + hwdata->uBufSize; + + // tests have shown that this value should be the width of the overlay, not the width of the display (ie not always 320) + hwdata->u16PixelWidth = width; + + // Set MLC_VLA_TP_PXW + p16GP2XRegs[0x2892>>1] = hwdata->u16PixelWidth; + + // MLC_YUV_CNTL: set YUV source to external memory for regions A and B, turn off "stepping" + p16GP2XRegs[0x2884>>1]=0; + + // disable all RGB Windows, and YUV region B + p16GP2XRegs[MLC_OVLAY_CNTR] &= ~(DISP_STL5EN|DISP_STL4EN|DISP_STL3EN|DISP_STL2EN|DISP_STL1EN|DISP_VLBON); + + // enable YUV region A + p16GP2XRegs[MLC_OVLAY_CNTR] |= DISP_VLAON; + + // disable bottom regions for A & B, and turn off all mirroring + p16GP2XRegs[0x2882>>1] &= 0xFC00; + + // Region B is disabled so we (hopefully) don't need to set anything for it + + // There currently is no way for this function to fail, but I'm leaving this in in case a future way presents itself + iSuccess = 1; + + return iSuccess; +} + +SDL_Overlay *GP2X_CreateYUVOverlay(_THIS, int width, int height, Uint32 format, SDL_Surface *display) +{ + SDL_Overlay *overlay = NULL; + struct private_yuvhwdata *hwdata; + + // we ONLY support YUY2 because that is the native gp2x YUV format + if (format != SDL_YUY2_OVERLAY) + { + printf("SDL_GP2X: Unsupported YUV format for hardware acceleration. Falling back to software.\n"); + return NULL; + } + + /* Create the overlay structure */ + overlay = (SDL_Overlay *)malloc(sizeof *overlay); + if ( overlay == NULL ) { + SDL_OutOfMemory(); + return(NULL); + } + memset(overlay, 0, (sizeof *overlay)); + + /* Fill in the basic members */ + overlay->format = format; + overlay->w = width; + overlay->h = height; + + /* Set up the YUV surface function structure */ + overlay->hwfuncs = &gp2x_yuvfuncs; + + // save our registers + GP2X_SaveRestoreRegs(this, 1); + +#ifdef GP2X_DEBUG + // this is a self-test precaution + { + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + g_pRegTester = malloc(0x50); + memcpy(g_pRegTester, (const void *) &p16GP2XRegs[0x2880 >> 1], 0x50); // store a big chunk of register info so we can compare it later + } +#endif // GP2X_DEBUG + + /* Create the pixel data and lookup tables */ + hwdata = (struct private_yuvhwdata *)malloc(sizeof *hwdata); + overlay->hwdata = hwdata; + if ( hwdata == NULL ) + { + SDL_OutOfMemory(); + SDL_FreeYUVOverlay(overlay); + return(NULL); + } + + // if YUV setup failed + if (!GP2X_SetupYUV(this, width, height, format, hwdata)) + { + SDL_FreeYUVOverlay(overlay); + return(NULL); + } + + overlay->hw_overlay = 1; + + /* Set up the plane pointers */ + overlay->pitches = hwdata->pitches; + overlay->pixels = hwdata->planes; + overlay->planes = 1; // since we only support YUY2, there is always only 1 plane + + // the pitch will always be the overlay width * 2, because we only support YUY2 + overlay->pitches[0] = overlay->w * 2; + + // start on the correct back buffer + overlay->pixels[0] = hwdata->YUVBuf[hwdata->uBackBuf]; + + /* We're all done.. */ + printf("SDL_GP2X: Created YUY2 overlay\n"); + return(overlay); +} + +int GP2X_LockYUVOverlay(_THIS, SDL_Overlay *overlay) +{ + return(0); +} + +void GP2X_UnlockYUVOverlay(_THIS, SDL_Overlay *overlay) +{ +} + +int GP2X_DisplayYUVOverlay(_THIS, SDL_Overlay *overlay, SDL_Rect *dstrect) +{ + struct private_yuvhwdata *hwdata = overlay->hwdata; + unsigned int uAddress = (unsigned int) hwdata->GP2XAddr[hwdata->uBackBuf]; + SDL_PrivateVideoData *data = this->hidden; + unsigned short volatile *p16GP2XRegs = data->io; + + // check to see if we are using a different rectangle + // (This should be a faster way than doing a bunch of conditionals and comparisons) + if (((dstrect->w ^ hwdata->rctLast.w) | (dstrect->h ^ hwdata->rctLast.h) | (dstrect->x ^ hwdata->rctLast.x) | + (dstrect->y ^ hwdata->rctLast.y)) == 0) + { + // if we get here, it means that the rectangle size has not changed, so we can flip after vblank + GP2X_WaitVBlank(data); + } + // else we are using a different rectangle + else + { + Uint16 u16HScaleVal = (unsigned short)((1024 * overlay->w) / dstrect->w); + unsigned int uVScaleVal = (unsigned int) ((hwdata->u16PixelWidth * overlay->h) / dstrect->h); + + // the boundary of the window on the right and bottom sides + // (-1 because 0 is the first pixel) + Sint16 s16Right, s16Bottom; + Sint16 x = dstrect->x; + Sint16 y = dstrect->y; + +#ifdef GP2X_DEBUG + // warn the user if this extra math is being done every frame + printf("SDL_GP2X: GP2X YUV Overlay is being resized. This usually should NOT happen every frame!\n"); +#endif // GP2X_DEV + + // gp2x doesn't seem to handle negative coordinates + if (x < 0) x = 0; + if (y < 0) y = 0; + + s16Right = x + (dstrect->w - 1); + s16Bottom = y + (dstrect->h - 1); + + // gp2x doesn't seem like the coordinates going outside the physical boundaries + if (s16Right > 319) s16Right = 319; + if (s16Bottom > 239) s16Bottom = 239; + + // now that we've done all the calculations we can before changing registers, wait for vblank + GP2X_WaitVBlank(data); + + // we need to rescale now ... + // MLC_YUVA_TP_HSC (horizontal scale factor of Region A, top) + p16GP2XRegs[0x2886>>1] = u16HScaleVal; + + // MLC_YUVA_TP_VSC[L/H] (vertical scale factor of Region A, top) + p16GP2XRegs[0x288A>>1] = (unsigned short) (uVScaleVal & 0xFFFF); + p16GP2XRegs[0x288C>>1] = (unsigned short) (uVScaleVal >> 16); // this will usually be 0 + + // NOW SET COORDINATES + + // MLC_YUVA_STX (X start coordinate of region A) + p16GP2XRegs[0x2896>>1]=x; + + // MLC_YUVA_ENDX (X stop coordinate of region A) + p16GP2XRegs[0x2898>>1]=s16Right; + + // MLC_YUV_TP_STY (Y start coordinate of region A top) + p16GP2XRegs[0x289A>>1]=y; + + // MLC_YUV_TP_ENDY (Y stop coordinate of region A top, and the start of the bottom) + p16GP2XRegs[0x289C>>1] = s16Bottom; + + // MLC_YUV_BT_ENDY (Y stop coordinate of region A bottom) + p16GP2XRegs[0x289E>>1] = s16Bottom; + + // copy new rectangle over to rctLast so that we don't do this stuff on every single frame + hwdata->rctLast = *dstrect; + } + + // NOW FLIP THE ACTUAL BUFFER + + // NOTE : I am flipping the odd and even fields here because that's how rlyeh did it, but I am not sure + // whether both of these need to be flipped. + + // region A, odd fields + p16GP2XRegs[0x28A0>>1] = (uAddress & 0xFFFF); + p16GP2XRegs[0x28A2>>1] = (uAddress >> 16); + + // region A, even fields + p16GP2XRegs[0x28A4>>1] = (uAddress & 0xFFFF); + p16GP2XRegs[0x28A6>>1] = (uAddress >> 16); + + // change back buffer to the other buffer (can be 0 or 1, so XOR works nicely) + hwdata->uBackBuf ^= 1; + + // update the pixel pointer to new back buffer + overlay->pixels[0] = hwdata->YUVBuf[hwdata->uBackBuf]; + + return(0); +} + +void GP2X_FreeYUVOverlay(_THIS, SDL_Overlay *overlay) +{ + struct private_yuvhwdata *hwdata; + unsigned short volatile *p16GP2XRegs = this->hidden->io; + + hwdata = overlay->hwdata; + + if ( hwdata ) + { + free(hwdata); + } + + // restore our registers + GP2X_SaveRestoreRegs(this, 0); + +#ifdef GP2X_DEBUG + // this is a self-test precaution + + // make sure that the registers were restored properly + assert (memcmp(g_pRegTester, (const void *) &p16GP2XRegs[0x2880 >> 1], 0x50) == 0); + + free(g_pRegTester); +#endif // GP2X_DEBUG + +} + + Added: trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h (rev 0) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/SDL_gp2xyuv_c.h 2008-08-19 11:43:56 UTC (rev 326) @@ -0,0 +1,34 @@ +/* + SDL - Simple DirectMedia Layer - SDL_gp2xyuv extension + Copyright (C) 2007 Matt Ownby + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ + +/* This is the GP2X implementation of YUV video overlays */ + +#include "SDL_video.h" +#include "SDL_gp2xvideo.h" + +extern SDL_Overlay *GP2X_CreateYUVOverlay(_THIS, int width, int height, Uint32 format, SDL_Surface *display); + +extern int GP2X_LockYUVOverlay(_THIS, SDL_Overlay *overlay); + +extern void GP2X_UnlockYUVOverlay(_THIS, SDL_Overlay *overlay); + +extern int GP2X_DisplayYUVOverlay(_THIS, SDL_Overlay *overlay, SDL_Rect *dstrect); + +extern void GP2X_FreeYUVOverlay(_THIS, SDL_Overlay *overlay); + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-08-18 20:29:28
|
Revision: 325 http://open2x.svn.sourceforge.net/open2x/?rev=325&view=rev Author: senquack Date: 2008-08-18 20:29:31 +0000 (Mon, 18 Aug 2008) Log Message: ----------- Made F100 DR3 default .config and added .config.f100xxx and .config.f200xxx premade for both models Modified Paths: -------------- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config Added Paths: ----------- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f100DR3configuration trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f200GPHfirmwarev4_configuration Modified: trunk/kernel/linux-open2x-2.4.26_FW2-3/.config =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config 2008-08-18 19:38:19 UTC (rev 324) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/.config 2008-08-18 20:29:31 UTC (rev 325) @@ -135,7 +135,7 @@ # CONFIG_MACH_MMSP2_DTK3 is not set CONFIG_MACH_MMSP2_DTK4=y CONFIG_MACH_GP2X=y -CONFIG_MACH_GP2XF200=y +# CONFIG_MACH_GP2XF200 is not set # CONFIG_MACH_GP2X_DEBUG is not set # CONFIG_MACH_GP2X_SVIDEO_NTSC is not set # CONFIG_MACH_GP2X_SVIDEO_PAL is not set @@ -283,7 +283,7 @@ CONFIG_MTD_NAND=y # CONFIG_MTD_NAND_VERIFY_WRITE is not set # CONFIG_MTD_NAND_BONFS is not set -CONFIG_MTD_OPEN2X_SINGLE_PARTITION=y +# CONFIG_MTD_OPEN2X_SINGLE_PARTITION is not set # CONFIG_OPEN2X_IGNORE_BB_ERASE is not set # CONFIG_MTD_NAND_SPIA is not set # CONFIG_MTD_NAND_TOTO is not set @@ -491,8 +491,8 @@ CONFIG_MMSP2_VPP=y CONFIG_MMSP2_ISP=y CONFIG_MMSP2_KEY=y -# CONFIG_MMSP_GPX_BATT is not set -CONFIG_MMSP_GP2X_ADC=y +CONFIG_MMSP_GPX_BATT=y +# CONFIG_MMSP_GP2X_ADC is not set # # L3 serial bus support @@ -757,7 +757,7 @@ # Native Language Support # CONFIG_NLS_DEFAULT="UTF8" -CONFIG_NLS_CODEPAGE_437=y +# CONFIG_NLS_CODEPAGE_437 is not set # CONFIG_NLS_CODEPAGE_737 is not set # CONFIG_NLS_CODEPAGE_775 is not set # CONFIG_NLS_CODEPAGE_850 is not set @@ -780,7 +780,7 @@ # CONFIG_NLS_ISO8859_8 is not set # CONFIG_NLS_CODEPAGE_1250 is not set # CONFIG_NLS_CODEPAGE_1251 is not set -CONFIG_NLS_ISO8859_1=y +# CONFIG_NLS_ISO8859_1 is not set # CONFIG_NLS_ISO8859_2 is not set # CONFIG_NLS_ISO8859_3 is not set # CONFIG_NLS_ISO8859_4 is not set @@ -868,8 +868,6 @@ CONFIG_SOUND_MP2520F_AC97=y # CONFIG_SOUND_TVMIXER is not set # CONFIG_SOUND_AD1980 is not set -CONFIG_SOUND_WM97XX=y -CONFIG_SOUND_WM97XX=y # # Multimedia Capabilities Port drivers @@ -996,7 +994,7 @@ # CONFIG_MMCSD=y # CONFIG_MMCSD_DEBUG is not set -CONFIG_OPEN2X_SD_AUTOMOUNT=y +# CONFIG_OPEN2X_SD_AUTOMOUNT is not set CONFIG_MMCSD_DISK=y CONFIG_MMCSD_SLOT=y Added: trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f100DR3configuration =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f100DR3configuration (rev 0) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f100DR3configuration 2008-08-18 20:29:31 UTC (rev 325) @@ -0,0 +1,1050 @@ +# +# Automatically generated by make menuconfig: don't edit +# +CONFIG_ARM=y +# CONFIG_EISA is not set +# CONFIG_SBUS is not set +# CONFIG_MCA is not set +CONFIG_UID16=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_RWSEM_XCHGADD_ALGORITHM is not set +# CONFIG_GENERIC_BUST_SPINLOCK is not set +# CONFIG_GENERIC_ISA_DMA is not set + +# +# Code maturity level options +# +CONFIG_EXPERIMENTAL=y +# CONFIG_OBSOLETE is not set + +# +# Loadable module support +# +CONFIG_MODULES=y +# CONFIG_MODVERSIONS is not set +CONFIG_KMOD=y + +# +# System Type +# +# CONFIG_ARCH_ANAKIN is not set +# CONFIG_ARCH_ARCA5K is not set +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_CO285 is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_OMAHA is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_MX1ADS is not set +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_RISCSTATION is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_SHARK is not set +CONFIG_ARCH_MMSP2=y +# CONFIG_ARCH_AT91RM9200 is not set + +# +# Archimedes/A5000 Implementations +# +# CONFIG_ARCH_ARC is not set +# CONFIG_ARCH_A5K is not set + +# +# Footbridge Implementations +# +# CONFIG_ARCH_CATS is not set +# CONFIG_ARCH_PERSONAL_SERVER is not set +# CONFIG_ARCH_EBSA285_ADDIN is not set +# CONFIG_ARCH_EBSA285_HOST is not set +# CONFIG_ARCH_NETWINDER is not set + +# +# SA11x0 Implementations +# +# CONFIG_SA1100_ACCELENT is not set +# CONFIG_SA1100_ASSABET is not set +# CONFIG_ASSABET_NEPONSET is not set +# CONFIG_SA1100_ADSAGC is not set +# CONFIG_SA1100_ADSBITSY is not set +# CONFIG_SA1100_ADSBITSYPLUS is not set +# CONFIG_SA1100_BRUTUS is not set +# CONFIG_SA1100_CEP is not set +# CONFIG_SA1100_CERF is not set +# CONFIG_SA1100_H3100 is not set +# CONFIG_SA1100_H3600 is not set +# CONFIG_SA1100_H3800 is not set +# CONFIG_SA1100_H3XXX is not set +# CONFIG_H3600_SLEEVE is not set +# CONFIG_SA1100_EXTENEX1 is not set +# CONFIG_SA1100_FLEXANET is not set +# CONFIG_SA1100_FREEBIRD is not set +# CONFIG_SA1100_FRODO is not set +# CONFIG_SA1100_GRAPHICSCLIENT is not set +# CONFIG_SA1100_GRAPHICSMASTER is not set +# CONFIG_SA1100_HACKKIT is not set +# CONFIG_SA1100_BADGE4 is not set +# CONFIG_SA1100_JORNADA720 is not set +# CONFIG_SA1100_HUW_WEBPANEL is not set +# CONFIG_SA1100_ITSY is not set +# CONFIG_SA1100_LART is not set +# CONFIG_SA1100_NANOENGINE is not set +# CONFIG_SA1100_OMNIMETER is not set +# CONFIG_SA1100_PANGOLIN is not set +# CONFIG_SA1100_PLEB is not set +# CONFIG_SA1100_PT_SYSTEM3 is not set +# CONFIG_SA1100_SHANNON is not set +# CONFIG_SA1100_SHERMAN is not set +# CONFIG_SA1100_SIMPAD is not set +# CONFIG_SA1100_SIMPUTER is not set +# CONFIG_SA1100_PFS168 is not set +# CONFIG_SA1100_VICTOR is not set +# CONFIG_SA1100_XP860 is not set +# CONFIG_SA1100_YOPY is not set +# CONFIG_SA1100_USB is not set +# CONFIG_SA1100_USB_NETLINK is not set +# CONFIG_SA1100_USB_CHAR is not set +# CONFIG_SA1100_SSP is not set + +# +# AT91RM9200 Implementations +# +# CONFIG_ARCH_AT91RM9200DK is not set +# CONFIG_MACH_CSB337 is not set + +# +# CLPS711X/EP721X Implementations +# +# CONFIG_ARCH_AUTCPU12 is not set +# CONFIG_ARCH_CDB89712 is not set +# CONFIG_ARCH_CLEP7312 is not set +# CONFIG_ARCH_EDB7211 is not set +# CONFIG_ARCH_FORTUNET is not set +# CONFIG_ARCH_GUIDEA07 is not set +# CONFIG_ARCH_P720T is not set +# CONFIG_ARCH_EP7211 is not set +# CONFIG_ARCH_EP7212 is not set + +# +# MMSP2 Implementation +# +CONFIG_MMSP2_SHADOW_ENABLE=y +CONFIG_MACH_MMSP2_MDK=y +# CONFIG_MACH_MMSP2_DTK3 is not set +CONFIG_MACH_MMSP2_DTK4=y +CONFIG_MACH_GP2X=y +# CONFIG_MACH_GP2XF200 is not set +# CONFIG_MACH_GP2X_DEBUG is not set +# CONFIG_MACH_GP2X_SVIDEO_NTSC is not set +# CONFIG_MACH_GP2X_SVIDEO_PAL is not set +CONFIG_MMSP2_USBDEV=m +CONFIG_MMSP2_USBDEV_NETLINK=m +# CONFIG_ARCH_ACORN is not set +# CONFIG_PLD is not set +# CONFIG_FOOTBRIDGE is not set +# CONFIG_FOOTBRIDGE_HOST is not set +# CONFIG_FOOTBRIDGE_ADDIN is not set +CONFIG_CPU_32=y +# CONFIG_CPU_26 is not set +# CONFIG_CPU_ARM610 is not set +# CONFIG_CPU_ARM710 is not set +# CONFIG_CPU_ARM720T is not set +CONFIG_CPU_ARM920T=y +# CONFIG_CPU_ARM922T is not set +# CONFIG_CPU_ARM926T is not set +# CONFIG_CPU_ARM1020 is not set +# CONFIG_CPU_ARM1020E is not set +# CONFIG_CPU_ARM1022 is not set +# CONFIG_CPU_ARM1026 is not set +# CONFIG_CPU_SA110 is not set +# CONFIG_CPU_SA1100 is not set +# CONFIG_CPU_32v3 is not set +CONFIG_CPU_32v4=y +# CONFIG_ARM_THUMB is not set +# CONFIG_CPU_ICACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_WRITETHROUGH is not set +# CONFIG_DISCONTIGMEM is not set + +# +# General setup +# +# CONFIG_PCI is not set +# CONFIG_ISA is not set +# CONFIG_ISA_DMA is not set +# CONFIG_ZBOOT_ROM is not set +CONFIG_ZBOOT_ROM_TEXT=0 +CONFIG_ZBOOT_ROM_BSS=0 +CONFIG_KEXEC=y +CONFIG_HOTPLUG=y + +# +# PCMCIA/CardBus support +# +# CONFIG_PCMCIA is not set +# CONFIG_PCMCIA_CLPS6700 is not set +# CONFIG_PCMCIA_SA1100 is not set +CONFIG_NET=y +CONFIG_SYSVIPC=y +# CONFIG_BSD_PROCESS_ACCT is not set +CONFIG_SYSCTL=y +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set +CONFIG_KCORE_ELF=y +# CONFIG_KCORE_AOUT is not set +# CONFIG_BINFMT_AOUT is not set +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_MISC is not set +# CONFIG_PM is not set +# CONFIG_ARTHUR is not set +CONFIG_CMDLINE="root=/dev/mtdblock4 rw" +CONFIG_ALIGNMENT_TRAP=y + +# +# Parallel port support +# +# CONFIG_PARPORT is not set + +# +# Memory Technology Devices (MTD) +# +CONFIG_MTD=y +# CONFIG_MTD_DEBUG is not set +CONFIG_MTD_PARTITIONS=y +# CONFIG_MTD_CONCAT is not set +# CONFIG_MTD_REDBOOT_PARTS is not set +# CONFIG_MTD_CMDLINE_PARTS is not set +# CONFIG_MTD_AFS_PARTS is not set +CONFIG_MTD_CHAR=y +CONFIG_MTD_BLOCK=y +# CONFIG_FTL is not set +# CONFIG_NFTL is not set +# CONFIG_INFTL is not set + +# +# RAM/ROM/Flash chip drivers +# +# CONFIG_MTD_CFI is not set +# CONFIG_MTD_JEDECPROBE is not set +# CONFIG_MTD_GEN_PROBE is not set +# CONFIG_MTD_CFI_INTELEXT is not set +# CONFIG_MTD_CFI_AMDSTD is not set +# CONFIG_MTD_CFI_STAA is not set +# CONFIG_MTD_CFI_UTIL is not set +# CONFIG_MTD_RAM is not set +# CONFIG_MTD_ROM is not set +# CONFIG_MTD_ABSENT is not set +# CONFIG_MTD_OBSOLETE_CHIPS is not set +# CONFIG_MTD_AMDSTD is not set +# CONFIG_MTD_SHARP is not set +# CONFIG_MTD_JEDEC is not set + +# +# Mapping drivers for chip access +# +# CONFIG_MTD_COMPLEX_MAPPINGS is not set +# CONFIG_MTD_PHYSMAP is not set +# CONFIG_MTD_ARM_INTEGRATOR is not set +# CONFIG_MTD_CDB89712 is not set +# CONFIG_MTD_SA1100 is not set +# CONFIG_MTD_DC21285 is not set +# CONFIG_MTD_IQ80310 is not set +# CONFIG_MTD_LUBBOCK is not set +# CONFIG_MTD_IXP425 is not set +# CONFIG_MTD_EPXA10DB is not set +# CONFIG_MTD_FORTUNET is not set +# CONFIG_MTD_AUTCPU12 is not set +# CONFIG_MTD_EDB7312 is not set +# CONFIG_MTD_H720X is not set +# CONFIG_MTD_IMPA7 is not set +# CONFIG_MTD_CEIVA is not set +# CONFIG_MTD_NOR_TOTO is not set +# CONFIG_MTD_PCI is not set +# CONFIG_MTD_PCMCIA is not set + +# +# Self-contained MTD device drivers +# +# CONFIG_MTD_PMC551 is not set +# CONFIG_MTD_SLRAM is not set +# CONFIG_MTD_MTDRAM is not set +# CONFIG_MTD_BLKMTD is not set +# CONFIG_MTD_DOC2000 is not set +# CONFIG_MTD_DOC2001 is not set +# CONFIG_MTD_DOC2001PLUS is not set +# CONFIG_MTD_DOCPROBE is not set + +# +# NAND Flash Device Drivers +# +CONFIG_MTD_NAND=y +# CONFIG_MTD_NAND_VERIFY_WRITE is not set +# CONFIG_MTD_NAND_BONFS is not set +# CONFIG_MTD_OPEN2X_SINGLE_PARTITION is not set +# CONFIG_OPEN2X_IGNORE_BB_ERASE is not set +# CONFIG_MTD_NAND_SPIA is not set +# CONFIG_MTD_NAND_TOTO is not set +# CONFIG_MTD_NAND_AUTCPU12 is not set +# CONFIG_MTD_NAND_EDB7312 is not set +CONFIG_MTD_NAND_MP2520F=y +# CONFIG_MTD_NAND_MP2520F_HWECC is not set +# CONFIG_MTD_NAND_MP2520F_HWECC_DEBUG is not set +CONFIG_MTD_NAND_IDS=y + +# +# Plug and Play configuration +# +# CONFIG_PNP is not set +# CONFIG_ISAPNP is not set + +# +# Block devices +# +# CONFIG_BLK_DEV_FD is not set +# CONFIG_BLK_DEV_XD is not set +# CONFIG_PARIDE is not set +# CONFIG_BLK_CPQ_DA is not set +# CONFIG_BLK_CPQ_CISS_DA is not set +# CONFIG_CISS_SCSI_TAPE is not set +# CONFIG_CISS_MONITOR_THREAD is not set +# CONFIG_BLK_DEV_DAC960 is not set +# CONFIG_BLK_DEV_UMEM is not set +CONFIG_BLK_DEV_LOOP=y +CONFIG_BLK_DEV_NBD=m +# CONFIG_BLK_DEV_RAM is not set +# CONFIG_BLK_DEV_INITRD is not set +# CONFIG_BLK_STATS is not set + +# +# Multi-device support (RAID and LVM) +# +# CONFIG_MD is not set +# CONFIG_BLK_DEV_MD is not set +# CONFIG_MD_LINEAR is not set +# CONFIG_MD_RAID0 is not set +# CONFIG_MD_RAID1 is not set +# CONFIG_MD_RAID5 is not set +# CONFIG_MD_MULTIPATH is not set +# CONFIG_BLK_DEV_LVM is not set + +# +# Networking options +# +CONFIG_PACKET=m +# CONFIG_PACKET_MMAP is not set +# CONFIG_NETLINK_DEV is not set +# CONFIG_NETFILTER is not set +CONFIG_FILTER=y +CONFIG_UNIX=m +CONFIG_INET=y +CONFIG_IP_MULTICAST=y +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_PNP=y +# CONFIG_IP_PNP_DHCP is not set +CONFIG_IP_PNP_BOOTP=y +CONFIG_IP_PNP_RARP=y +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_IP_MROUTE is not set +# CONFIG_ARPD is not set +# CONFIG_INET_ECN is not set +CONFIG_SYN_COOKIES=y +# CONFIG_IPV6 is not set +# CONFIG_KHTTPD is not set + +# +# SCTP Configuration (EXPERIMENTAL) +# +# CONFIG_IP_SCTP is not set +# CONFIG_ATM is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set + +# +# Appletalk devices +# +# CONFIG_DEV_APPLETALK is not set +# CONFIG_DECNET is not set +# CONFIG_BRIDGE is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_LLC is not set +# CONFIG_NET_DIVERT is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_FASTROUTE is not set +# CONFIG_NET_HW_FLOWCONTROL is not set + +# +# QoS and/or fair queueing +# +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set + +# +# Network device support +# +# CONFIG_NETDEVICES is not set + +# +# Amateur Radio support +# +# CONFIG_HAMRADIO is not set + +# +# IrDA (infrared) support +# +# CONFIG_IRDA is not set + +# +# ATA/ATAPI/MFM/RLL support +# +# CONFIG_IDE is not set +# CONFIG_BLK_DEV_HD is not set + +# +# SCSI support +# +# CONFIG_SCSI is not set + +# +# I2O device support +# +# CONFIG_I2O is not set +# CONFIG_I2O_BLOCK is not set +# CONFIG_I2O_LAN is not set +# CONFIG_I2O_SCSI is not set +# CONFIG_I2O_PROC is not set + +# +# ISDN subsystem +# +# CONFIG_ISDN is not set + +# +# Input core support +# +CONFIG_INPUT=m +CONFIG_INPUT_KEYBDEV=m +CONFIG_INPUT_MOUSEDEV=m +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +CONFIG_INPUT_JOYDEV=m +# CONFIG_INPUT_EVDEV is not set +# CONFIG_INPUT_UINPUT is not set +# CONFIG_INPUT_MX1TS is not set + +# +# Character devices +# +CONFIG_VT=y +# CONFIG_VT_CONSOLE is not set +# CONFIG_SERIAL is not set +# CONFIG_SERIAL_EXTENDED is not set +# CONFIG_SERIAL_NONSTANDARD is not set +# CONFIG_IRDA_LIRC is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_ANAKIN is not set +# CONFIG_SERIAL_ANAKIN_CONSOLE is not set +# CONFIG_SERIAL_AMBA is not set +# CONFIG_SERIAL_AMBA_CONSOLE is not set +# CONFIG_SERIAL_CLPS711X is not set +# CONFIG_SERIAL_CLPS711X_CONSOLE is not set +# CONFIG_SERIAL_21285 is not set +# CONFIG_SERIAL_21285_OLD is not set +# CONFIG_SERIAL_21285_CONSOLE is not set +# CONFIG_SERIAL_UART00 is not set +# CONFIG_SERIAL_UART00_CONSOLE is not set +# CONFIG_SERIAL_SA1100 is not set +# CONFIG_SERIAL_SA1100_CONSOLE is not set +# CONFIG_SERIAL_OMAHA is not set +# CONFIG_SERIAL_OMAHA_CONSOLE is not set +# CONFIG_SERIAL_AT91 is not set +# CONFIG_SERIAL_AT91_CONSOLE is not set +CONFIG_SERIAL_MMSP2=y +CONFIG_SERIAL_MMSP2_CONSOLE=y +# CONFIG_SERIAL_8250 is not set +# CONFIG_SERIAL_8250_CONSOLE is not set +# CONFIG_SERIAL_8250_EXTENDED is not set +# CONFIG_SERIAL_8250_MANY_PORTS is not set +# CONFIG_SERIAL_8250_SHARE_IRQ is not set +# CONFIG_SERIAL_8250_DETECT_IRQ is not set +# CONFIG_SERIAL_8250_MULTIPORT is not set +# CONFIG_SERIAL_8250_HUB6 is not set +CONFIG_SERIAL_CORE=y +CONFIG_SERIAL_CORE_CONSOLE=y +CONFIG_UNIX98_PTYS=y +CONFIG_UNIX98_PTY_COUNT=256 +# CONFIG_MMSP2_TPC is not set +CONFIG_MMSP2_DUALCPU=m +CONFIG_MMSP2_VPP=y +CONFIG_MMSP2_ISP=y +CONFIG_MMSP2_KEY=y +CONFIG_MMSP_GPX_BATT=y +# CONFIG_MMSP_GP2X_ADC is not set + +# +# L3 serial bus support +# +# CONFIG_L3 is not set +# CONFIG_L3_ALGOBIT is not set +# CONFIG_L3_BIT_SA1100_GPIO is not set +# CONFIG_L3_SA1111 is not set +# CONFIG_BIT_SA1100_GPIO is not set + +# +# Mice +# +# CONFIG_BUSMOUSE is not set +# CONFIG_MOUSE is not set + +# +# Joysticks +# +# CONFIG_INPUT_GAMEPORT is not set +# CONFIG_INPUT_NS558 is not set +# CONFIG_INPUT_LIGHTNING is not set +# CONFIG_INPUT_PCIGAME is not set +# CONFIG_INPUT_CS461X is not set +# CONFIG_INPUT_EMU10K1 is not set +# CONFIG_INPUT_SERIO is not set +# CONFIG_INPUT_SERPORT is not set +# CONFIG_INPUT_ANALOG is not set +# CONFIG_INPUT_A3D is not set +# CONFIG_INPUT_ADI is not set +# CONFIG_INPUT_COBRA is not set +# CONFIG_INPUT_GP2X is not set +# CONFIG_INPUT_GF2K is not set +# CONFIG_INPUT_GRIP is not set +# CONFIG_INPUT_INTERACT is not set +# CONFIG_INPUT_TMDC is not set +# CONFIG_INPUT_SIDEWINDER is not set +# CONFIG_INPUT_IFORCE_USB is not set +# CONFIG_INPUT_IFORCE_232 is not set +# CONFIG_INPUT_WARRIOR is not set +# CONFIG_INPUT_MAGELLAN is not set +# CONFIG_INPUT_SPACEORB is not set +# CONFIG_INPUT_SPACEBALL is not set +# CONFIG_INPUT_STINGER is not set +# CONFIG_INPUT_DB9 is not set +# CONFIG_INPUT_GAMECON is not set +# CONFIG_INPUT_TURBOGRAFX is not set +# CONFIG_QIC02_TAPE is not set +# CONFIG_IPMI_HANDLER is not set +# CONFIG_IPMI_PANIC_EVENT is not set +# CONFIG_IPMI_DEVICE_INTERFACE is not set +# CONFIG_IPMI_KCS is not set +# CONFIG_IPMI_WATCHDOG is not set + +# +# Watchdog Cards +# +CONFIG_WATCHDOG=y +# CONFIG_WATCHDOG_NOWAYOUT is not set +# CONFIG_ACQUIRE_WDT is not set +# CONFIG_ADVANTECH_WDT is not set +# CONFIG_ALIM1535_WDT is not set +# CONFIG_ALIM7101_WDT is not set +# CONFIG_SC520_WDT is not set +# CONFIG_PCWATCHDOG is not set +# CONFIG_21285_WATCHDOG is not set +# CONFIG_977_WATCHDOG is not set +# CONFIG_SA1100_WATCHDOG is not set +# CONFIG_EPXA_WATCHDOG is not set +# CONFIG_OMAHA_WATCHDOG is not set +# CONFIG_AT91_WATCHDOG is not set +# CONFIG_MMSP2_WATCHDOG is not set +# CONFIG_EUROTECH_WDT is not set +# CONFIG_IB700_WDT is not set +# CONFIG_WAFER_WDT is not set +# CONFIG_I810_TCO is not set +# CONFIG_MIXCOMWD is not set +# CONFIG_60XX_WDT is not set +# CONFIG_SC1200_WDT is not set +# CONFIG_SCx200_WDT is not set +# CONFIG_SOFT_WATCHDOG is not set +# CONFIG_W83877F_WDT is not set +# CONFIG_WDT is not set +# CONFIG_WDTPCI is not set +# CONFIG_MACHZ_WDT is not set +# CONFIG_AMD7XX_TCO is not set +# CONFIG_SCx200 is not set +# CONFIG_SCx200_GPIO is not set +# CONFIG_AMD_PM768 is not set +# CONFIG_NVRAM is not set +# CONFIG_RTC is not set +CONFIG_MMSP2_RTC=y +# CONFIG_DTLK is not set +# CONFIG_R3964 is not set +# CONFIG_APPLICOM is not set + +# +# Ftape, the floppy tape device driver +# +# CONFIG_FTAPE is not set +# CONFIG_AGP is not set + +# +# Direct Rendering Manager (XFree86 DRI support) +# +# CONFIG_DRM is not set + +# +# Multimedia devices +# +CONFIG_VIDEO_DEV=y + +# +# Video For Linux +# +# CONFIG_VIDEO_PROC_FS is not set +# CONFIG_I2C_PARPORT is not set +# CONFIG_VIDEO_BT848 is not set +# CONFIG_VIDEO_PMS is not set +# CONFIG_VIDEO_OV9640 is not set +CONFIG_VIDEO_CX25874=y +# CONFIG_VIDEO_SAA7113H is not set +# CONFIG_VIDEO_CPIA is not set +# CONFIG_VIDEO_SAA5249 is not set +# CONFIG_TUNER_3036 is not set +# CONFIG_VIDEO_STRADIS is not set +# CONFIG_VIDEO_ZORAN is not set +# CONFIG_VIDEO_ZORAN_BUZ is not set +# CONFIG_VIDEO_ZORAN_DC10 is not set +# CONFIG_VIDEO_ZORAN_LML33 is not set +# CONFIG_VIDEO_ZR36120 is not set +# CONFIG_VIDEO_MEYE is not set +# CONFIG_VIDEO_CYBERPRO is not set + +# +# Radio Adapters +# +# CONFIG_RADIO_GEMTEK_PCI is not set +# CONFIG_RADIO_MAXIRADIO is not set +# CONFIG_RADIO_MAESTRO is not set +# CONFIG_RADIO_MIROPCM20 is not set + +# +# File systems +# +# CONFIG_QUOTA is not set +# CONFIG_QFMT_V2 is not set +# CONFIG_AUTOFS_FS is not set +CONFIG_AUTOFS4_FS=y +CONFIG_REISERFS_FS=m +# CONFIG_REISERFS_CHECK is not set +# CONFIG_REISERFS_PROC_INFO is not set +# CONFIG_ADFS_FS is not set +# CONFIG_ADFS_FS_RW is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BEFS_DEBUG is not set +# CONFIG_BFS_FS is not set +CONFIG_EXT3_FS=m +CONFIG_JBD=m +# CONFIG_JBD_DEBUG is not set +CONFIG_FAT_FS=y +# CONFIG_MSDOS_FS is not set +# CONFIG_UMSDOS_FS is not set +CONFIG_VFAT_FS=y +# CONFIG_EFS_FS is not set +# CONFIG_JFFS_FS is not set +CONFIG_JFFS2_FS=m +CONFIG_JFFS2_FS_DEBUG=0 +CONFIG_JFFS2_FS_NAND=y +CONFIG_CRAMFS=y +CONFIG_TMPFS=y +CONFIG_RAMFS=y +CONFIG_ISO9660_FS=m +CONFIG_JOLIET=y +# CONFIG_ZISOFS is not set +# CONFIG_JFS_FS is not set +# CONFIG_JFS_DEBUG is not set +# CONFIG_JFS_STATISTICS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_VXFS_FS is not set +CONFIG_NTFS_FS=m +# CONFIG_NTFS_RW is not set +# CONFIG_HPFS_FS is not set +CONFIG_PROC_FS=y +CONFIG_DEVFS_FS=y +CONFIG_DEVFS_MOUNT=y +# CONFIG_DEVFS_DEBUG is not set +CONFIG_DEVPTS_FS=y +# CONFIG_QNX4FS_FS is not set +# CONFIG_QNX4FS_RW is not set +# CONFIG_ROMFS_FS is not set +CONFIG_EXT2_FS=y +# CONFIG_SYSV_FS is not set +CONFIG_UDF_FS=m +# CONFIG_UDF_RW is not set +# CONFIG_UFS_FS is not set +# CONFIG_UFS_FS_WRITE is not set +# CONFIG_XFS_FS is not set +# CONFIG_XFS_QUOTA is not set +# CONFIG_XFS_RT is not set +# CONFIG_XFS_TRACE is not set +# CONFIG_XFS_DEBUG is not set +CONFIG_YAFFS_FS=y +# CONFIG_YAFFS2_FS is not set + +# +# Network File Systems +# +# CONFIG_CODA_FS is not set +# CONFIG_INTERMEZZO_FS is not set +CONFIG_NFS_FS=m +CONFIG_NFS_V3=y +# CONFIG_NFS_DIRECTIO is not set +# CONFIG_ROOT_NFS is not set +# CONFIG_NFSD is not set +# CONFIG_NFSD_V3 is not set +# CONFIG_NFSD_TCP is not set +CONFIG_SUNRPC=m +CONFIG_LOCKD=m +CONFIG_LOCKD_V4=y +CONFIG_SMB_FS=m +CONFIG_SMB_NLS_DEFAULT=y +CONFIG_SMB_NLS_REMOTE="cp949" +CONFIG_SMB_UNIX=y +# CONFIG_NCP_FS is not set +# CONFIG_NCPFS_PACKET_SIGNING is not set +# CONFIG_NCPFS_IOCTL_LOCKING is not set +# CONFIG_NCPFS_STRONG is not set +# CONFIG_NCPFS_NFS_NS is not set +# CONFIG_NCPFS_OS2_NS is not set +# CONFIG_NCPFS_SMALLDOS is not set +# CONFIG_NCPFS_NLS is not set +# CONFIG_NCPFS_EXTRAS is not set +# CONFIG_ZISOFS_FS is not set + +# +# Partition Types +# +CONFIG_PARTITION_ADVANCED=y +# CONFIG_ACORN_PARTITION is not set +# CONFIG_OSF_PARTITION is not set +# CONFIG_AMIGA_PARTITION is not set +# CONFIG_ATARI_PARTITION is not set +# CONFIG_MAC_PARTITION is not set +CONFIG_MSDOS_PARTITION=y +# CONFIG_BSD_DISKLABEL is not set +# CONFIG_MINIX_SUBPARTITION is not set +# CONFIG_SOLARIS_X86_PARTITION is not set +# CONFIG_UNIXWARE_DISKLABEL is not set +# CONFIG_LDM_PARTITION is not set +# CONFIG_SGI_PARTITION is not set +# CONFIG_ULTRIX_PARTITION is not set +# CONFIG_SUN_PARTITION is not set +# CONFIG_EFI_PARTITION is not set +CONFIG_SMB_NLS=y +CONFIG_NLS=y + +# +# Native Language Support +# +CONFIG_NLS_DEFAULT="UTF8" +# CONFIG_NLS_CODEPAGE_437 is not set +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ISO8859_1 is not set +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +CONFIG_NLS_UTF8=y + +# +# Console drivers +# +CONFIG_PC_KEYMAP=y +# CONFIG_VGA_CONSOLE is not set + +# +# Frame-buffer support +# +CONFIG_FB=y +CONFIG_DUMMY_CONSOLE=y +# CONFIG_FB_ACORN is not set +CONFIG_FB_MMSP2=y +# CONFIG_FB_ANAKIN is not set +# CONFIG_FB_CLPS711X is not set +# CONFIG_FB_SA1100 is not set +# CONFIG_FB_DBMX1 is not set +CONFIG_LPP=y +# CONFIG_FB_CYBER2000 is not set +# CONFIG_FB_VIRTUAL is not set +CONFIG_FBCON_ADVANCED=y +# CONFIG_FBCON_MFB is not set +# CONFIG_FBCON_CFB2 is not set +# CONFIG_FBCON_CFB4 is not set +# CONFIG_FBCON_CFB8 is not set +CONFIG_FBCON_CFB16=y +# CONFIG_FBCON_CFB24 is not set +# CONFIG_FBCON_CFB32 is not set +# CONFIG_FBCON_AFB is not set +# CONFIG_FBCON_ILBM is not set +# CONFIG_FBCON_IPLAN2P2 is not set +# CONFIG_FBCON_IPLAN2P4 is not set +# CONFIG_FBCON_IPLAN2P8 is not set +# CONFIG_FBCON_MAC is not set +# CONFIG_FBCON_VGA_PLANES is not set +# CONFIG_FBCON_VGA is not set +# CONFIG_FBCON_HGA is not set +# CONFIG_FBCON_FONTWIDTH8_ONLY is not set +# CONFIG_FBCON_FONTS is not set +CONFIG_FONT_8x8=y +CONFIG_FONT_8x16=y + +# +# Sound +# +CONFIG_SOUND=y +# CONFIG_SOUND_ALI5455 is not set +# CONFIG_SOUND_BT878 is not set +# CONFIG_SOUND_CMPCI is not set +# CONFIG_SOUND_EMU10K1 is not set +# CONFIG_MIDI_EMU10K1 is not set +# CONFIG_SOUND_FUSION is not set +# CONFIG_SOUND_CS4281 is not set +# CONFIG_SOUND_ES1370 is not set +# CONFIG_SOUND_ES1371 is not set +# CONFIG_SOUND_ESSSOLO1 is not set +# CONFIG_SOUND_MAESTRO is not set +# CONFIG_SOUND_MAESTRO3 is not set +# CONFIG_SOUND_FORTE is not set +# CONFIG_SOUND_ICH is not set +# CONFIG_SOUND_RME96XX is not set +# CONFIG_SOUND_SONICVIBES is not set +# CONFIG_SOUND_TRIDENT is not set +# CONFIG_SOUND_MSNDCLAS is not set +# CONFIG_SOUND_MSNDPIN is not set +# CONFIG_SOUND_VIA82CXXX is not set +# CONFIG_MIDI_VIA82CXXX is not set +# CONFIG_SOUND_OSS is not set +# CONFIG_SOUND_VIDC is not set +# CONFIG_SOUND_WAVEARTIST is not set +CONFIG_SOUND_MP2520F_AC97=y +# CONFIG_SOUND_TVMIXER is not set +# CONFIG_SOUND_AD1980 is not set + +# +# Multimedia Capabilities Port drivers +# +# CONFIG_MCP is not set +# CONFIG_MCP_SA1100 is not set +# CONFIG_MCP_UCB1200 is not set +# CONFIG_MCP_UCB1200_AUDIO is not set +# CONFIG_MCP_UCB1200_TS is not set + +# +# USB support +# +CONFIG_USB=m +# CONFIG_USB_DEBUG is not set +# CONFIG_USB_DEVICEFS is not set +# CONFIG_USB_BANDWIDTH is not set +# CONFIG_USB_EHCI_HCD is not set +# CONFIG_USB_UHCI is not set +# CONFIG_USB_UHCI_ALT is not set +# CONFIG_USB_OHCI is not set +# CONFIG_USB_OHCI_SA1111 is not set +CONFIG_USB_OHCI_MMSP2=m +# CONFIG_MMSP2_UPAD3_TO_DEVICE is not set +# CONFIG_USB_SL811HS_ALT is not set +# CONFIG_USB_SL811HS is not set +CONFIG_USB_AUDIO=m +CONFIG_USB_EMI26=m +CONFIG_USB_MIDI=m +# CONFIG_USB_STORAGE is not set +# CONFIG_USB_STORAGE_DEBUG is not set +# CONFIG_USB_STORAGE_DATAFAB is not set +# CONFIG_USB_STORAGE_FREECOM is not set +# CONFIG_USB_STORAGE_ISD200 is not set +# CONFIG_USB_STORAGE_DPCM is not set +# CONFIG_USB_STORAGE_HP8200e is not set +# CONFIG_USB_STORAGE_SDDR09 is not set +# CONFIG_USB_STORAGE_SDDR55 is not set +# CONFIG_USB_STORAGE_JUMPSHOT is not set +CONFIG_USB_ACM=m +CONFIG_USB_PRINTER=m +CONFIG_USB_HID=m +CONFIG_USB_HIDINPUT=y +CONFIG_USB_HIDDEV=y +CONFIG_USB_KBD=m +CONFIG_USB_MOUSE=m +# CONFIG_USB_AIPTEK is not set +CONFIG_USB_WACOM=m +# CONFIG_USB_KBTAB is not set +CONFIG_USB_POWERMATE=m +# CONFIG_USB_DC2XX is not set +# CONFIG_USB_MDC800 is not set +CONFIG_USB_SCANNER=m +# CONFIG_USB_MICROTEK is not set +# CONFIG_USB_HPUSBSCSI is not set +# CONFIG_USB_IBMCAM is not set +# CONFIG_USB_KONICAWC is not set +# CONFIG_USB_OV511 is not set +# CONFIG_USB_PWC is not set +# CONFIG_USB_SE401 is not set +# CONFIG_USB_STV680 is not set +# CONFIG_USB_W9968CF is not set +# CONFIG_USB_VICAM is not set +# CONFIG_USB_DSBR is not set +# CONFIG_USB_DABUSB is not set +CONFIG_USB_PEGASUS=m +CONFIG_USB_RTL8150=m +CONFIG_USB_KAWETH=m +CONFIG_USB_CATC=m +CONFIG_USB_CDCETHER=m +CONFIG_USB_USBNET=m +# CONFIG_USB_USS720 is not set + +# +# USB Serial Converter support +# +CONFIG_USB_SERIAL=m +# CONFIG_USB_SERIAL_DEBUG is not set +# CONFIG_USB_SERIAL_GENERIC is not set +# CONFIG_USB_SERIAL_BELKIN is not set +# CONFIG_USB_SERIAL_WHITEHEAT is not set +# CONFIG_USB_SERIAL_DIGI_ACCELEPORT is not set +# CONFIG_USB_SERIAL_EMPEG is not set +# CONFIG_USB_SERIAL_FTDI_SIO is not set +# CONFIG_USB_SERIAL_VISOR is not set +# CONFIG_USB_SERIAL_IPAQ is not set +# CONFIG_USB_SERIAL_IR is not set +# CONFIG_USB_SERIAL_EDGEPORT is not set +# CONFIG_USB_SERIAL_EDGEPORT_TI is not set +# CONFIG_USB_SERIAL_KEYSPAN_PDA is not set +# CONFIG_USB_SERIAL_KEYSPAN is not set +# CONFIG_USB_SERIAL_MCT_U232 is not set +# CONFIG_USB_SERIAL_KLSI is not set +# CONFIG_USB_SERIAL_KOBIL_SCT is not set +# CONFIG_USB_SERIAL_PL2303 is not set +# CONFIG_USB_SERIAL_CYBERJACK is not set +# CONFIG_USB_SERIAL_XIRCOM is not set +# CONFIG_USB_SERIAL_OMNINET is not set +# CONFIG_USB_RIO500 is not set +# CONFIG_USB_AUERSWALD is not set +# CONFIG_USB_TIGL is not set +# CONFIG_USB_BRLVGER is not set +# CONFIG_USB_LCD is not set + +# +# Support for USB gadgets +# +CONFIG_USB_GADGET=m +CONFIG_USB_GADGET_NET2272=y +# CONFIG_USB_GADGET_NET2280 is not set +# CONFIG_USB_GADGET_CONTROLLER is not set +CONFIG_USB_NET2272=m +CONFIG_USB_GADGET_CONTROLLER=m +CONFIG_USB_GADGET_DUALSPEED=y +CONFIG_USB_ZERO=m +CONFIG_USB_GADGETFS=m +CONFIG_USB_ETH=m +CONFIG_USB_ETH_RNDIS=y +CONFIG_USB_FILE_STORAGE=m +# CONFIG_USB_FILE_STORAGE_TEST is not set + +# +# MMC/SD Card support +# +CONFIG_MMCSD=y +# CONFIG_MMCSD_DEBUG is not set +# CONFIG_OPEN2X_SD_AUTOMOUNT is not set +CONFIG_MMCSD_DISK=y +CONFIG_MMCSD_SLOT=y + +# +# Bluetooth support +# +CONFIG_BLUEZ=m +# CONFIG_BLUEZ_L2CAP is not set +# CONFIG_BLUEZ_SCO is not set +# CONFIG_BLUEZ_RFCOMM is not set +# CONFIG_BLUEZ_BNEP is not set + +# +# Bluetooth device drivers +# +CONFIG_BLUEZ_HCIUSB=m +CONFIG_BLUEZ_HCIUSB_SCO=y +CONFIG_BLUEZ_HCIUART=m +CONFIG_BLUEZ_HCIUART_H4=y +CONFIG_BLUEZ_HCIUART_BCSP=y +# CONFIG_BLUEZ_HCIUART_BCSP_TXCRC is not set +CONFIG_BLUEZ_HCIBFUSB=m +# CONFIG_BLUEZ_HCIDTL1 is not set +# CONFIG_BLUEZ_HCIBT3C is not set +# CONFIG_BLUEZ_HCIBLUECARD is not set +# CONFIG_BLUEZ_HCIBTUART is not set +CONFIG_BLUEZ_HCIVHCI=m + +# +# Kernel hacking +# +CONFIG_FRAME_POINTER=y +CONFIG_DEBUG_USER=y +# CONFIG_DEBUG_INFO is not set +# CONFIG_NO_PGT_CACHE is not set +# CONFIG_DEBUG_KERNEL is not set +# CONFIG_DEBUG_SLAB is not set +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_DEBUG_SPINLOCK is not set +# CONFIG_DEBUG_WAITQ is not set +# CONFIG_DEBUG_BUGVERBOSE is not set +# CONFIG_DEBUG_ERRORS is not set +# CONFIG_DEBUG_LL is not set +# CONFIG_DEBUG_DC21285_PORT is not set +# CONFIG_DEBUG_CLPS711X_UART2 is not set + +# +# Library routines +# +# CONFIG_CRC32 is not set +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=m +# CONFIG_FW_LOADER is not set Added: trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f200GPHfirmwarev4_configuration =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f200GPHfirmwarev4_configuration (rev 0) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/.config.f200GPHfirmwarev4_configuration 2008-08-18 20:29:31 UTC (rev 325) @@ -0,0 +1,1052 @@ +# +# Automatically generated by make menuconfig: don't edit +# +CONFIG_ARM=y +# CONFIG_EISA is not set +# CONFIG_SBUS is not set +# CONFIG_MCA is not set +CONFIG_UID16=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_RWSEM_XCHGADD_ALGORITHM is not set +# CONFIG_GENERIC_BUST_SPINLOCK is not set +# CONFIG_GENERIC_ISA_DMA is not set + +# +# Code maturity level options +# +CONFIG_EXPERIMENTAL=y +# CONFIG_OBSOLETE is not set + +# +# Loadable module support +# +CONFIG_MODULES=y +# CONFIG_MODVERSIONS is not set +CONFIG_KMOD=y + +# +# System Type +# +# CONFIG_ARCH_ANAKIN is not set +# CONFIG_ARCH_ARCA5K is not set +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_CO285 is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_OMAHA is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_MX1ADS is not set +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_RISCSTATION is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_SHARK is not set +CONFIG_ARCH_MMSP2=y +# CONFIG_ARCH_AT91RM9200 is not set + +# +# Archimedes/A5000 Implementations +# +# CONFIG_ARCH_ARC is not set +# CONFIG_ARCH_A5K is not set + +# +# Footbridge Implementations +# +# CONFIG_ARCH_CATS is not set +# CONFIG_ARCH_PERSONAL_SERVER is not set +# CONFIG_ARCH_EBSA285_ADDIN is not set +# CONFIG_ARCH_EBSA285_HOST is not set +# CONFIG_ARCH_NETWINDER is not set + +# +# SA11x0 Implementations +# +# CONFIG_SA1100_ACCELENT is not set +# CONFIG_SA1100_ASSABET is not set +# CONFIG_ASSABET_NEPONSET is not set +# CONFIG_SA1100_ADSAGC is not set +# CONFIG_SA1100_ADSBITSY is not set +# CONFIG_SA1100_ADSBITSYPLUS is not set +# CONFIG_SA1100_BRUTUS is not set +# CONFIG_SA1100_CEP is not set +# CONFIG_SA1100_CERF is not set +# CONFIG_SA1100_H3100 is not set +# CONFIG_SA1100_H3600 is not set +# CONFIG_SA1100_H3800 is not set +# CONFIG_SA1100_H3XXX is not set +# CONFIG_H3600_SLEEVE is not set +# CONFIG_SA1100_EXTENEX1 is not set +# CONFIG_SA1100_FLEXANET is not set +# CONFIG_SA1100_FREEBIRD is not set +# CONFIG_SA1100_FRODO is not set +# CONFIG_SA1100_GRAPHICSCLIENT is not set +# CONFIG_SA1100_GRAPHICSMASTER is not set +# CONFIG_SA1100_HACKKIT is not set +# CONFIG_SA1100_BADGE4 is not set +# CONFIG_SA1100_JORNADA720 is not set +# CONFIG_SA1100_HUW_WEBPANEL is not set +# CONFIG_SA1100_ITSY is not set +# CONFIG_SA1100_LART is not set +# CONFIG_SA1100_NANOENGINE is not set +# CONFIG_SA1100_OMNIMETER is not set +# CONFIG_SA1100_PANGOLIN is not set +# CONFIG_SA1100_PLEB is not set +# CONFIG_SA1100_PT_SYSTEM3 is not set +# CONFIG_SA1100_SHANNON is not set +# CONFIG_SA1100_SHERMAN is not set +# CONFIG_SA1100_SIMPAD is not set +# CONFIG_SA1100_SIMPUTER is not set +# CONFIG_SA1100_PFS168 is not set +# CONFIG_SA1100_VICTOR is not set +# CONFIG_SA1100_XP860 is not set +# CONFIG_SA1100_YOPY is not set +# CONFIG_SA1100_USB is not set +# CONFIG_SA1100_USB_NETLINK is not set +# CONFIG_SA1100_USB_CHAR is not set +# CONFIG_SA1100_SSP is not set + +# +# AT91RM9200 Implementations +# +# CONFIG_ARCH_AT91RM9200DK is not set +# CONFIG_MACH_CSB337 is not set + +# +# CLPS711X/EP721X Implementations +# +# CONFIG_ARCH_AUTCPU12 is not set +# CONFIG_ARCH_CDB89712 is not set +# CONFIG_ARCH_CLEP7312 is not set +# CONFIG_ARCH_EDB7211 is not set +# CONFIG_ARCH_FORTUNET is not set +# CONFIG_ARCH_GUIDEA07 is not set +# CONFIG_ARCH_P720T is not set +# CONFIG_ARCH_EP7211 is not set +# CONFIG_ARCH_EP7212 is not set + +# +# MMSP2 Implementation +# +CONFIG_MMSP2_SHADOW_ENABLE=y +CONFIG_MACH_MMSP2_MDK=y +# CONFIG_MACH_MMSP2_DTK3 is not set +CONFIG_MACH_MMSP2_DTK4=y +CONFIG_MACH_GP2X=y +CONFIG_MACH_GP2XF200=y +# CONFIG_MACH_GP2X_DEBUG is not set +# CONFIG_MACH_GP2X_SVIDEO_NTSC is not set +# CONFIG_MACH_GP2X_SVIDEO_PAL is not set +CONFIG_MMSP2_USBDEV=m +CONFIG_MMSP2_USBDEV_NETLINK=m +# CONFIG_ARCH_ACORN is not set +# CONFIG_PLD is not set +# CONFIG_FOOTBRIDGE is not set +# CONFIG_FOOTBRIDGE_HOST is not set +# CONFIG_FOOTBRIDGE_ADDIN is not set +CONFIG_CPU_32=y +# CONFIG_CPU_26 is not set +# CONFIG_CPU_ARM610 is not set +# CONFIG_CPU_ARM710 is not set +# CONFIG_CPU_ARM720T is not set +CONFIG_CPU_ARM920T=y +# CONFIG_CPU_ARM922T is not set +# CONFIG_CPU_ARM926T is not set +# CONFIG_CPU_ARM1020 is not set +# CONFIG_CPU_ARM1020E is not set +# CONFIG_CPU_ARM1022 is not set +# CONFIG_CPU_ARM1026 is not set +# CONFIG_CPU_SA110 is not set +# CONFIG_CPU_SA1100 is not set +# CONFIG_CPU_32v3 is not set +CONFIG_CPU_32v4=y +# CONFIG_ARM_THUMB is not set +# CONFIG_CPU_ICACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_WRITETHROUGH is not set +# CONFIG_DISCONTIGMEM is not set + +# +# General setup +# +# CONFIG_PCI is not set +# CONFIG_ISA is not set +# CONFIG_ISA_DMA is not set +# CONFIG_ZBOOT_ROM is not set +CONFIG_ZBOOT_ROM_TEXT=0 +CONFIG_ZBOOT_ROM_BSS=0 +CONFIG_KEXEC=y +CONFIG_HOTPLUG=y + +# +# PCMCIA/CardBus support +# +# CONFIG_PCMCIA is not set +# CONFIG_PCMCIA_CLPS6700 is not set +# CONFIG_PCMCIA_SA1100 is not set +CONFIG_NET=y +CONFIG_SYSVIPC=y +# CONFIG_BSD_PROCESS_ACCT is not set +CONFIG_SYSCTL=y +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set +CONFIG_KCORE_ELF=y +# CONFIG_KCORE_AOUT is not set +# CONFIG_BINFMT_AOUT is not set +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_MISC is not set +# CONFIG_PM is not set +# CONFIG_ARTHUR is not set +CONFIG_CMDLINE="root=/dev/mtdblock3 rw" +CONFIG_ALIGNMENT_TRAP=y + +# +# Parallel port support +# +# CONFIG_PARPORT is not set + +# +# Memory Technology Devices (MTD) +# +CONFIG_MTD=y +# CONFIG_MTD_DEBUG is not set +CONFIG_MTD_PARTITIONS=y +# CONFIG_MTD_CONCAT is not set +# CONFIG_MTD_REDBOOT_PARTS is not set +# CONFIG_MTD_CMDLINE_PARTS is not set +# CONFIG_MTD_AFS_PARTS is not set +CONFIG_MTD_CHAR=y +CONFIG_MTD_BLOCK=y +# CONFIG_FTL is not set +# CONFIG_NFTL is not set +# CONFIG_INFTL is not set + +# +# RAM/ROM/Flash chip drivers +# +# CONFIG_MTD_CFI is not set +# CONFIG_MTD_JEDECPROBE is not set +# CONFIG_MTD_GEN_PROBE is not set +# CONFIG_MTD_CFI_INTELEXT is not set +# CONFIG_MTD_CFI_AMDSTD is not set +# CONFIG_MTD_CFI_STAA is not set +# CONFIG_MTD_CFI_UTIL is not set +# CONFIG_MTD_RAM is not set +# CONFIG_MTD_ROM is not set +# CONFIG_MTD_ABSENT is not set +# CONFIG_MTD_OBSOLETE_CHIPS is not set +# CONFIG_MTD_AMDSTD is not set +# CONFIG_MTD_SHARP is not set +# CONFIG_MTD_JEDEC is not set + +# +# Mapping drivers for chip access +# +# CONFIG_MTD_COMPLEX_MAPPINGS is not set +# CONFIG_MTD_PHYSMAP is not set +# CONFIG_MTD_ARM_INTEGRATOR is not set +# CONFIG_MTD_CDB89712 is not set +# CONFIG_MTD_SA1100 is not set +# CONFIG_MTD_DC21285 is not set +# CONFIG_MTD_IQ80310 is not set +# CONFIG_MTD_LUBBOCK is not set +# CONFIG_MTD_IXP425 is not set +# CONFIG_MTD_EPXA10DB is not set +# CONFIG_MTD_FORTUNET is not set +# CONFIG_MTD_AUTCPU12 is not set +# CONFIG_MTD_EDB7312 is not set +# CONFIG_MTD_H720X is not set +# CONFIG_MTD_IMPA7 is not set +# CONFIG_MTD_CEIVA is not set +# CONFIG_MTD_NOR_TOTO is not set +# CONFIG_MTD_PCI is not set +# CONFIG_MTD_PCMCIA is not set + +# +# Self-contained MTD device drivers +# +# CONFIG_MTD_PMC551 is not set +# CONFIG_MTD_SLRAM is not set +# CONFIG_MTD_MTDRAM is not set +# CONFIG_MTD_BLKMTD is not set +# CONFIG_MTD_DOC2000 is not set +# CONFIG_MTD_DOC2001 is not set +# CONFIG_MTD_DOC2001PLUS is not set +# CONFIG_MTD_DOCPROBE is not set + +# +# NAND Flash Device Drivers +# +CONFIG_MTD_NAND=y +# CONFIG_MTD_NAND_VERIFY_WRITE is not set +# CONFIG_MTD_NAND_BONFS is not set +CONFIG_MTD_OPEN2X_SINGLE_PARTITION=y +# CONFIG_OPEN2X_IGNORE_BB_ERASE is not set +# CONFIG_MTD_NAND_SPIA is not set +# CONFIG_MTD_NAND_TOTO is not set +# CONFIG_MTD_NAND_AUTCPU12 is not set +# CONFIG_MTD_NAND_EDB7312 is not set +CONFIG_MTD_NAND_MP2520F=y +# CONFIG_MTD_NAND_MP2520F_HWECC is not set +# CONFIG_MTD_NAND_MP2520F_HWECC_DEBUG is not set +CONFIG_MTD_NAND_IDS=y + +# +# Plug and Play configuration +# +# CONFIG_PNP is not set +# CONFIG_ISAPNP is not set + +# +# Block devices +# +# CONFIG_BLK_DEV_FD is not set +# CONFIG_BLK_DEV_XD is not set +# CONFIG_PARIDE is not set +# CONFIG_BLK_CPQ_DA is not set +# CONFIG_BLK_CPQ_CISS_DA is not set +# CONFIG_CISS_SCSI_TAPE is not set +# CONFIG_CISS_MONITOR_THREAD is not set +# CONFIG_BLK_DEV_DAC960 is not set +# CONFIG_BLK_DEV_UMEM is not set +CONFIG_BLK_DEV_LOOP=y +CONFIG_BLK_DEV_NBD=m +# CONFIG_BLK_DEV_RAM is not set +# CONFIG_BLK_DEV_INITRD is not set +# CONFIG_BLK_STATS is not set + +# +# Multi-device support (RAID and LVM) +# +# CONFIG_MD is not set +# CONFIG_BLK_DEV_MD is not set +# CONFIG_MD_LINEAR is not set +# CONFIG_MD_RAID0 is not set +# CONFIG_MD_RAID1 is not set +# CONFIG_MD_RAID5 is not set +# CONFIG_MD_MULTIPATH is not set +# CONFIG_BLK_DEV_LVM is not set + +# +# Networking options +# +CONFIG_PACKET=m +# CONFIG_PACKET_MMAP is not set +# CONFIG_NETLINK_DEV is not set +# CONFIG_NETFILTER is not set +CONFIG_FILTER=y +CONFIG_UNIX=m +CONFIG_INET=y +CONFIG_IP_MULTICAST=y +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_PNP=y +# CONFIG_IP_PNP_DHCP is not set +CONFIG_IP_PNP_BOOTP=y +CONFIG_IP_PNP_RARP=y +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_IP_MROUTE is not set +# CONFIG_ARPD is not set +# CONFIG_INET_ECN is not set +CONFIG_SYN_COOKIES=y +# CONFIG_IPV6 is not set +# CONFIG_KHTTPD is not set + +# +# SCTP Configuration (EXPERIMENTAL) +# +# CONFIG_IP_SCTP is not set +# CONFIG_ATM is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set + +# +# Appletalk devices +# +# CONFIG_DEV_APPLETALK is not set +# CONFIG_DECNET is not set +# CONFIG_BRIDGE is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_LLC is not set +# CONFIG_NET_DIVERT is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_FASTROUTE is not set +# CONFIG_NET_HW_FLOWCONTROL is not set + +# +# QoS and/or fair queueing +# +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set + +# +# Network device support +# +# CONFIG_NETDEVICES is not set + +# +# Amateur Radio support +# +# CONFIG_HAMRADIO is not set + +# +# IrDA (infrared) support +# +# CONFIG_IRDA is not set + +# +# ATA/ATAPI/MFM/RLL support +# +# CONFIG_IDE is not set +# CONFIG_BLK_DEV_HD is not set + +# +# SCSI support +# +# CONFIG_SCSI is not set + +# +# I2O device support +# +# CONFIG_I2O is not set +# CONFIG_I2O_BLOCK is not set +# CONFIG_I2O_LAN is not set +# CONFIG_I2O_SCSI is not set +# CONFIG_I2O_PROC is not set + +# +# ISDN subsystem +# +# CONFIG_ISDN is not set + +# +# Input core support +# +CONFIG_INPUT=m +CONFIG_INPUT_KEYBDEV=m +CONFIG_INPUT_MOUSEDEV=m +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +CONFIG_INPUT_JOYDEV=m +# CONFIG_INPUT_EVDEV is not set +# CONFIG_INPUT_UINPUT is not set +# CONFIG_INPUT_MX1TS is not set + +# +# Character devices +# +CONFIG_VT=y +# CONFIG_VT_CONSOLE is not set +# CONFIG_SERIAL is not set +# CONFIG_SERIAL_EXTENDED is not set +# CONFIG_SERIAL_NONSTANDARD is not set +# CONFIG_IRDA_LIRC is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_ANAKIN is not set +# CONFIG_SERIAL_ANAKIN_CONSOLE is not set +# CONFIG_SERIAL_AMBA is not set +# CONFIG_SERIAL_AMBA_CONSOLE is not set +# CONFIG_SERIAL_CLPS711X is not set +# CONFIG_SERIAL_CLPS711X_CONSOLE is not set +# CONFIG_SERIAL_21285 is not set +# CONFIG_SERIAL_21285_OLD is not set +# CONFIG_SERIAL_21285_CONSOLE is not set +# CONFIG_SERIAL_UART00 is not set +# CONFIG_SERIAL_UART00_CONSOLE is not set +# CONFIG_SERIAL_SA1100 is not set +# CONFIG_SERIAL_SA1100_CONSOLE is not set +# CONFIG_SERIAL_OMAHA is not set +# CONFIG_SERIAL_OMAHA_CONSOLE is not set +# CONFIG_SERIAL_AT91 is not set +# CONFIG_SERIAL_AT91_CONSOLE is not set +CONFIG_SERIAL_MMSP2=y +CONFIG_SERIAL_MMSP2_CONSOLE=y +# CONFIG_SERIAL_8250 is not set +# CONFIG_SERIAL_8250_CONSOLE is not set +# CONFIG_SERIAL_8250_EXTENDED is not set +# CONFIG_SERIAL_8250_MANY_PORTS is not set +# CONFIG_SERIAL_8250_SHARE_IRQ is not set +# CONFIG_SERIAL_8250_DETECT_IRQ is not set +# CONFIG_SERIAL_8250_MULTIPORT is not set +# CONFIG_SERIAL_8250_HUB6 is not set +CONFIG_SERIAL_CORE=y +CONFIG_SERIAL_CORE_CONSOLE=y +CONFIG_UNIX98_PTYS=y +CONFIG_UNIX98_PTY_COUNT=256 +# CONFIG_MMSP2_TPC is not set +CONFIG_MMSP2_DUALCPU=m +CONFIG_MMSP2_VPP=y +CONFIG_MMSP2_ISP=y +CONFIG_MMSP2_KEY=y +# CONFIG_MMSP_GPX_BATT is not set +CONFIG_MMSP_GP2X_ADC=y + +# +# L3 serial bus support +# +# CONFIG_L3 is not set +# CONFIG_L3_ALGOBIT is not set +# CONFIG_L3_BIT_SA1100_GPIO is not set +# CONFIG_L3_SA1111 is not set +# CONFIG_BIT_SA1100_GPIO is not set + +# +# Mice +# +# CONFIG_BUSMOUSE is not set +# CONFIG_MOUSE is not set + +# +# Joysticks +# +# CONFIG_INPUT_GAMEPORT is not set +# CONFIG_INPUT_NS558 is not set +# CONFIG_INPUT_LIGHTNING is not set +# CONFIG_INPUT_PCIGAME is not set +# CONFIG_INPUT_CS461X is not set +# CONFIG_INPUT_EMU10K1 is not set +# CONFIG_INPUT_SERIO is not set +# CONFIG_INPUT_SERPORT is not set +# CONFIG_INPUT_ANALOG is not set +# CONFIG_INPUT_A3D is not set +# CONFIG_INPUT_ADI is not set +# CONFIG_INPUT_COBRA is not set +# CONFIG_INPUT_GP2X is not set +# CONFIG_INPUT_GF2K is not set +# CONFIG_INPUT_GRIP is not set +# CONFIG_INPUT_INTERACT is not set +# CONFIG_INPUT_TMDC is not set +# CONFIG_INPUT_SIDEWINDER is not set +# CONFIG_INPUT_IFORCE_USB is not set +# CONFIG_INPUT_IFORCE_232 is not set +# CONFIG_INPUT_WARRIOR is not set +# CONFIG_INPUT_MAGELLAN is not set +# CONFIG_INPUT_SPACEORB is not set +# CONFIG_INPUT_SPACEBALL is not set +# CONFIG_INPUT_STINGER is not set +# CONFIG_INPUT_DB9 is not set +# CONFIG_INPUT_GAMECON is not set +# CONFIG_INPUT_TURBOGRAFX is not set +# CONFIG_QIC02_TAPE is not set +# CONFIG_IPMI_HANDLER is not set +# CONFIG_IPMI_PANIC_EVENT is not set +# CONFIG_IPMI_DEVICE_INTERFACE is not set +# CONFIG_IPMI_KCS is not set +# CONFIG_IPMI_WATCHDOG is not set + +# +# Watchdog Cards +# +CONFIG_WATCHDOG=y +# CONFIG_WATCHDOG_NOWAYOUT is not set +# CONFIG_ACQUIRE_WDT is not set +# CONFIG_ADVANTECH_WDT is not set +# CONFIG_ALIM1535_WDT is not set +# CONFIG_ALIM7101_WDT is not set +# CONFIG_SC520_WDT is not set +# CONFIG_PCWATCHDOG is not set +# CONFIG_21285_WATCHDOG is not set +# CONFIG_977_WATCHDOG is not set +# CONFIG_SA1100_WATCHDOG is not set +# CONFIG_EPXA_WATCHDOG is not set +# CONFIG_OMAHA_WATCHDOG is not set +# CONFIG_AT91_WATCHDOG is not set +# CONFIG_MMSP2_WATCHDOG is not set +# CONFIG_EUROTECH_WDT is not set +# CONFIG_IB700_WDT is not set +# CONFIG_WAFER_WDT is not set +# CONFIG_I810_TCO is not set +# CONFIG_MIXCOMWD is not set +# CONFIG_60XX_WDT is not set +# CONFIG_SC1200_WDT is not set +# CONFIG_SCx200_WDT is not set +# CONFIG_SOFT_WATCHDOG is not set +# CONFIG_W83877F_WDT is not set +# CONFIG_WDT is not set +# CONFIG_WDTPCI is not set +# CONFIG_MACHZ_WDT is not set +# CONFIG_AMD7XX_TCO is not set +# CONFIG_SCx200 is not set +# CONFIG_SCx200_GPIO is not set +# CONFIG_AMD_PM768 is not set +# CONFIG_NVRAM is not set +# CONFIG_RTC is not set +CONFIG_MMSP2_RTC=y +# CONFIG_DTLK is not set +# CONFIG_R3964 is not set +# CONFIG_APPLICOM is not set + +# +# Ftape, the floppy tape device driver +# +# CONFIG_FTAPE is not set +# CONFIG_AGP is not set + +# +# Direct Rendering Manager (XFree86 DRI support) +# +# CONFIG_DRM is not set + +# +# Multimedia devices +# +CONFIG_VIDEO_DEV=y + +# +# Video For Linux +# +# CONFIG_VIDEO_PROC_FS is not set +# CONFIG_I2C_PARPORT is not set +# CONFIG_VIDEO_BT848 is not set +# CONFIG_VIDEO_PMS is not set +# CONFIG_VIDEO_OV9640 is not set +CONFIG_VIDEO_CX25874=y +# CONFIG_VIDEO_SAA7113H is not set +# CONFIG_VIDEO_CPIA is not set +# CONFIG_VIDEO_SAA5249 is not set +# CONFIG_TUNER_3036 is not set +# CONFIG_VIDEO_STRADIS is not set +# CONFIG_VIDEO_ZORAN is not set +# CONFIG_VIDEO_ZORAN_BUZ is not set +# CONFIG_VIDEO_ZORAN_DC10 is not set +# CONFIG_VIDEO_ZORAN_LML33 is not set +# CONFIG_VIDEO_ZR36120 is not set +# CONFIG_VIDEO_MEYE is not set +# CONFIG_VIDEO_CYBERPRO is not set + +# +# Radio Adapters +# +# CONFIG_RADIO_GEMTEK_PCI is not set +# CONFIG_RADIO_MAXIRADIO is not set +# CONFIG_RADIO_MAESTRO is not set +# CONFIG_RADIO_MIROPCM20 is not set + +# +# File systems +# +# CONFIG_QUOTA is not set +# CONFIG_QFMT_V2 is not set +# CONFIG_AUTOFS_FS is not set +CONFIG_AUTOFS4_FS=y +CONFIG_REISERFS_FS=m +# CONFIG_REISERFS_CHECK is not set +# CONFIG_REISERFS_PROC_INFO is not set +# CONFIG_ADFS_FS is not set +# CONFIG_ADFS_FS_RW is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BEFS_DEBUG is not set +# CONFIG_BFS_FS is not set +CONFIG_EXT3_FS=m +CONFIG_JBD=m +# CONFIG_JBD_DEBUG is not set +CONFIG_FAT_FS=y +# CONFIG_MSDOS_FS is not set +# CONFIG_UMSDOS_FS is not set +CONFIG_VFAT_FS=y +# CONFIG_EFS_FS is not set +# CONFIG_JFFS_FS is not set +CONFIG_JFFS2_FS=m +CONFIG_JFFS2_FS_DEBUG=0 +CONFIG_JFFS2_FS_NAND=y +CONFIG_CRAMFS=y +CONFIG_TMPFS=y +CONFIG_RAMFS=y +CONFIG_ISO9660_FS=m +CONFIG_JOLIET=y +# CONFIG_ZISOFS is not set +# CONFIG_JFS_FS is not set +# CONFIG_JFS_DEBUG is not set +# CONFIG_JFS_STATISTICS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_VXFS_FS is not set +CONFIG_NTFS_FS=m +# CONFIG_NTFS_RW is not set +# CONFIG_HPFS_FS is not set +CONFIG_PROC_FS=y +CONFIG_DEVFS_FS=y +CONFIG_DEVFS_MOUNT=y +# CONFIG_DEVFS_DEBUG is not set +CONFIG_DEVPTS_FS=y +# CONFIG_QNX4FS_FS is not set +# CONFIG_QNX4FS_RW is not set +# CONFIG_ROMFS_FS is not set +CONFIG_EXT2_FS=y +# CONFIG_SYSV_FS is not set +CONFIG_UDF_FS=m +# CONFIG_UDF_RW is not set +# CONFIG_UFS_FS is not set +# CONFIG_UFS_FS_WRITE is not set +# CONFIG_XFS_FS is not set +# CONFIG_XFS_QUOTA is not set +# CONFIG_XFS_RT is not set +# CONFIG_XFS_TRACE is not set +# CONFIG_XFS_DEBUG is not set +CONFIG_YAFFS_FS=y +# CONFIG_YAFFS2_FS is not set + +# +# Network File Systems +# +# CONFIG_CODA_FS is not set +# CONFIG_INTERMEZZO_FS is not set +CONFIG_NFS_FS=m +CONFIG_NFS_V3=y +# CONFIG_NFS_DIRECTIO is not set +# CONFIG_ROOT_NFS is not set +# CONFIG_NFSD is not set +# CONFIG_NFSD_V3 is not set +# CONFIG_NFSD_TCP is not set +CONFIG_SUNRPC=m +CONFIG_LOCKD=m +CONFIG_LOCKD_V4=y +CONFIG_SMB_FS=m +CONFIG_SMB_NLS_DEFAULT=y +CONFIG_SMB_NLS_REMOTE="cp949" +CONFIG_SMB_UNIX=y +# CONFIG_NCP_FS is not set +# CONFIG_NCPFS_PACKET_SIGNING is not set +# CONFIG_NCPFS_IOCTL_LOCKING is not set +# CONFIG_NCPFS_STRONG is not set +# CONFIG_NCPFS_NFS_NS is not set +# CONFIG_NCPFS_OS2_NS is not set +# CONFIG_NCPFS_SMALLDOS is not set +# CONFIG_NCPFS_NLS is not set +# CONFIG_NCPFS_EXTRAS is not set +# CONFIG_ZISOFS_FS is not set + +# +# Partition Types +# +CONFIG_PARTITION_ADVANCED=y +# CONFIG_ACORN_PARTITION is not set +# CONFIG_OSF_PARTITION is not set +# CONFIG_AMIGA_PARTITION is not set +# CONFIG_ATARI_PARTITION is not set +# CONFIG_MAC_PARTITION is not set +CONFIG_MSDOS_PARTITION=y +# CONFIG_BSD_DISKLABEL is not set +# CONFIG_MINIX_SUBPARTITION is not set +# CONFIG_SOLARIS_X86_PARTITION is not set +# CONFIG_UNIXWARE_DISKLABEL is not set +# CONFIG_LDM_PARTITION is not set +# CONFIG_SGI_PARTITION is not set +# CONFIG_ULTRIX_PARTITION is not set +# CONFIG_SUN_PARTITION is not set +# CONFIG_EFI_PARTITION is not set +CONFIG_SMB_NLS=y +CONFIG_NLS=y + +# +# Native Language Support +# +CONFIG_NLS_DEFAULT="UTF8" +# CONFIG_NLS_CODEPAGE_437 is not set +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ISO8859_1 is not set +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +CONFIG_NLS_UTF8=y + +# +# Console drivers +# +CONFIG_PC_KEYMAP=y +# CONFIG_VGA_CONSOLE is not set + +# +# Frame-buffer support +# +CONFIG_FB=y +CONFIG_DUMMY_CONSOLE=y +# CONFIG_FB_ACORN is not set +CONFIG_FB_MMSP2=y +# CONFIG_FB_ANAKIN is not set +# CONFIG_FB_CLPS711X is not set +# CONFIG_FB_SA1100 is not set +# CONFIG_FB_DBMX1 is not set +CONFIG_LPP=y +# CONFIG_FB_CYBER2000 is not set +# CONFIG_FB_VIRTUAL is not set +CONFIG_FBCON_ADVANCED=y +# CONFIG_FBCON_MFB is not set +# CONFIG_FBCON_CFB2 is not set +# CONFIG_FBCON_CFB4 is not set +# CONFIG_FBCON_CFB8 is not set +CONFIG_FBCON_CFB16=y +# CONFIG_FBCON_CFB24 is not set +# CONFIG_FBCON_CFB32 is not set +# CONFIG_FBCON_AFB is not set +# CONFIG_FBCON_ILBM is not set +# CONFIG_FBCON_IPLAN2P2 is not set +# CONFIG_FBCON_IPLAN2P4 is not set +# CONFIG_FBCON_IPLAN2P8 is not set +# CONFIG_FBCON_MAC is not set +# CONFIG_FBCON_VGA_PLANES is not set +# CONFIG_FBCON_VGA is not set +# CONFIG_FBCON_HGA is not set +# CONFIG_FBCON_FONTWIDTH8_ONLY is not set +# CONFIG_FBCON_FONTS is not set +CONFIG_FONT_8x8=y +CONFIG_FONT_8x16=y + +# +# Sound +# +CONFIG_SOUND=y +# CONFIG_SOUND_ALI5455 is not set +# CONFIG_SOUND_BT878 is not set +# CONFIG_SOUND_CMPCI is not set +# CONFIG_SOUND_EMU10K1 is not set +# CONFIG_MIDI_EMU10K1 is not set +# CONFIG_SOUND_FUSION is not set +# CONFIG_SOUND_CS4281 is not set +# CONFIG_SOUND_ES1370 is not set +# CONFIG_SOUND_ES1371 is not set +# CONFIG_SOUND_ESSSOLO1 is not set +# CONFIG_SOUND_MAESTRO is not set +# CONFIG_SOUND_MAESTRO3 is not set +# CONFIG_SOUND_FORTE is not set +# CONFIG_SOUND_ICH is not set +# CONFIG_SOUND_RME96XX is not set +# CONFIG_SOUND_SONICVIBES is not set +# CONFIG_SOUND_TRIDENT is not set +# CONFIG_SOUND_MSNDCLAS is not set +# CONFIG_SOUND_MSNDPIN is not set +# CONFIG_SOUND_VIA82CXXX is not set +# CONFIG_MIDI_VIA82CXXX is not set +# CONFIG_SOUND_OSS is not set +# CONFIG_SOUND_VIDC is not set +# CONFIG_SOUND_WAVEARTIST is not set +CONFIG_SOUND_MP2520F_AC97=y +# CONFIG_SOUND_TVMIXER is not set +# CONFIG_SOUND_AD1980 is not set +CONFIG_SOUND_WM97XX=y +CONFIG_SOUND_WM97XX=y + +# +# Multimedia Capabilities Port drivers +# +# CONFIG_MCP is not set +# CONFIG_MCP_SA1100 is not set +# CONFIG_MCP_UCB1200 is not set +# CONFIG_MCP_UCB1200_AUDIO is not set +# CONFIG_MCP_UCB1200_TS is not set + +# +# USB support +# +CONFIG_USB=m +# CONFIG_USB_DEBUG is not set +# CONFIG_USB_DEVICEFS is not set +# CONFIG_USB_BANDWIDTH is not set +# CONFIG_USB_EHCI_HCD is not set +# CONFIG_USB_UHCI is not set +# CONFIG_USB_UHCI_ALT is not set +# CONFIG_USB_OHCI is not set +# CONFIG_USB_OHCI_SA1111 is not set +CONFIG_USB_OHCI_MMSP2=m +# CONFIG_MMSP2_UPAD3_TO_DEVICE is not set +# CONFIG_USB_SL811HS_ALT is not set +# CONFIG_USB_SL811HS is not set +CONFIG_USB_AUDIO=m +CONFIG_USB_EMI26=m +CONFIG_USB_MIDI=m +# CONFIG_USB_STORAGE is not set +# CONFIG_USB_STORAGE_DEBUG is not set +# CONFIG_USB_STORAGE_DATAFAB is not set +# CONFIG_USB_STORAGE_FREECOM is not set +# CONFIG_USB_STORAGE_ISD200 is not set +# CONFIG_USB_STORAGE_DPCM is not set +# CONFIG_USB_STORAGE_HP8200e is not set +# CONFIG_USB_STORAGE_SDDR09 is not set +# CONFIG_USB_STORAGE_SDDR55 is not set +# CONFIG_USB_STORAGE_JUMPSHOT is not set +CONFIG_USB_ACM=m +CONFIG_USB_PRINTER=m +CONFIG_USB_HID=m +CONFIG_USB_HIDINPUT=y +CONFIG_USB_HIDDEV=y +CONFIG_USB_KBD=m +CONFIG_USB_MOUSE=m +# CONFIG_USB_AIPTEK is not set +CONFIG_USB_WACOM=m +# CONFIG_USB_KBTAB is not set +CONFIG_USB_POWERMATE=m +# CONFIG_USB_DC2XX is not set +# CONFIG_USB_MDC800 is not set +CONFIG_USB_SCANNER=m +# CONFIG_USB_MICROTEK is not set +# CONFIG_USB_HPUSBSCSI is not set +# CONFIG_USB_IBMCAM is not set +# CONFIG_USB_KONICAWC is not set +# CONFIG_USB_OV511 is not set +# CONFIG_USB_PWC is not set +# CONFIG_USB_SE401 is not set +# CONFIG_USB_STV680 is not set +# CONFIG_USB_W9968CF is not set +# CONFIG_USB_VICAM is not set +# CONFIG_USB_DSBR is not set +# CONFIG_USB_DABUSB is not set +CONFIG_USB_PEGASUS=m +CONFIG_USB_RTL8150=m +CONFIG_USB_KAWETH=m +CONFIG_USB_CATC=m +CONFIG_USB_CDCETHER=m +CONFIG_USB_USBNET=m +# CONFIG_USB_USS720 is not set + +# +# USB Serial Converter support +# +CONFIG_USB_SERIAL=m +# CONFIG_USB_SERIAL_DEBUG is not set +# CONFIG_USB_SERIAL_GENERIC is not set +# CONFIG_USB_SERIAL_BELKIN is not set +# CONFIG_USB_SERIAL_WHITEHEAT is not set +# CONFIG_USB_SERIAL_DIGI_ACCELEPORT is not set +# CONFIG_USB_SERIAL_EMPEG is not set +# CONFIG_USB_SERIAL_FTDI_SIO is not set +# CONFIG_USB_SERIAL_VISOR is not set +# CONFIG_USB_SERIAL_IPAQ is not set +# CONFIG_USB_SERIAL_IR is not set +# CONFIG_USB_SERIAL_EDGEPORT is not set +# CONFIG_USB_SERIAL_EDGEPORT_TI is not set +# CONFIG_USB_SERIAL_KEYSPAN_PDA is not set +# CONFIG_USB_SERIAL_KEYSPAN is not set +# CONFIG_USB_SERIAL_MCT_U232 is not set +# CONFIG_USB_SERIAL_KLSI is not set +# CONFIG_USB_SERIAL_KOBIL_SCT is not set +# CONFIG_USB_SERIAL_PL2303 is not set +# CONFIG_USB_SERIAL_CYBERJACK is not set +# CONFIG_USB_SERIAL_XIRCOM is not set +# CONFIG_USB_SERIAL_OMNINET is not set +# CONFIG_USB_RIO500 is not set +# CONFIG_USB_AUERSWALD is not set +# CONFIG_USB_TIGL is not set +# CONFIG_USB_BRLVGER is not set +# CONFIG_USB_LCD is not set + +# +# Support for USB gadgets +# +CONFIG_USB_GADGET=m +CONFIG_USB_GADGET_NET2272=y +# CONFIG_USB_GADGET_NET2280 is not set +# CONFIG_USB_GADGET_CONTROLLER is not set +CONFIG_USB_NET2272=m +CONFIG_USB_GADGET_CONTROLLER=m +CONFIG_USB_GADGET_DUALSPEED=y +CONFIG_USB_ZERO=m +CONFIG_USB_GADGETFS=m +CONFIG_USB_ETH=m +CONFIG_USB_ETH_RNDIS=y +CONFIG_USB_FILE_STORAGE=m +# CONFIG_USB_FILE_STORAGE_TEST is not set + +# +# MMC/SD Card support +# +CONFIG_MMCSD=y +# CONFIG_MMCSD_DEBUG is not set +CONFIG_OPEN2X_SD_AUTOMOUNT=y +CONFIG_MMCSD_DISK=y +CONFIG_MMCSD_SLOT=y + +# +# Bluetooth support +# +CONFIG_BLUEZ=m +# CONFIG_BLUEZ_L2CAP is not set +# CONFIG_BLUEZ_SCO is not set +# CONFIG_BLUEZ_RFCOMM is not set +# CONFIG_BLUEZ_BNEP is not set + +# +# Bluetooth device drivers +# +CONFIG_BLUEZ_HCIUSB=m +CONFIG_BLUEZ_HCIUSB_SCO=y +CONFIG_BLUEZ_HCIUART=m +CONFIG_BLUEZ_HCIUART_H4=y +CONFIG_BLUEZ_HCIUART_BCSP=y +# CONFIG_BLUEZ_HCIUART_BCSP_TXCRC is not set +CONFIG_BLUEZ_HCIBFUSB=m +# CONFIG_BLUEZ_HCIDTL1 is not set +# CONFIG_BLUEZ_HCIBT3C is not set +# CONFIG_BLUEZ_HCIBLUECARD is not set +# CONFIG_BLUEZ_HCIBTUART is not set +CONFIG_BLUEZ_HCIVHCI=m + +# +# Kernel hacking +# +CONFIG_FRAME_POINTER=y +CONFIG_DEBUG_USER=y +# CONFIG_DEBUG_INFO is not set +# CONFIG_NO_PGT_CACHE is not set +# CONFIG_DEBUG_KERNEL is not set +# CONFIG_DEBUG_SLAB is not set +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_DEBUG_SPINLOCK is not set +# CONFIG_DEBUG_WAITQ is not set +# CONFIG_DEBUG_BUGVERBOSE is not set +# CONFIG_DEBUG_ERRORS is not set +# CONFIG_DEBUG_LL is not set +# CONFIG_DEBUG_DC21285_PORT is not set +# CONFIG_DEBUG_CLPS711X_UART2 is not set + +# +# Library routines +# +# CONFIG_CRC32 is not set +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=m +# CONFIG_FW_LOADER is not set This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-08-18 19:38:26
|
Revision: 324 http://open2x.svn.sourceforge.net/open2x/?rev=324&view=rev Author: senquack Date: 2008-08-18 19:38:19 +0000 (Mon, 18 Aug 2008) Log Message: ----------- Modified Paths: -------------- trunk/libs/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c Modified: trunk/libs/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c =================================================================== --- trunk/libs/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-13 00:01:07 UTC (rev 323) +++ trunk/libs/SDL-1.2.13/src/video/gp2x/gp2x_tslib.c 2008-08-18 19:38:19 UTC (rev 324) @@ -722,6 +722,206 @@ int y; } XYHIST; +#define XYHISTLENGTH 15 +XYHIST average_xyhist[XYHISTLENGTH]; + +static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) +{ + + int ret = 0; + int newx, newy; + + int flush_history = 0; // variance module will tell us if we are getting fast movements + static int flush_count = 0; // when we get enough fast movements, flush the history + static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 + static int xyhist_counter = 0; // DKS - how many entires in history? + static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array + + ret = variance_read(ts, samp, nr, &flush_history); + flush_count += flush_history; + struct ts_sample *s; + s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x + // touchscreen driver only ever provides 1 sample each read so + // it's not really necessary but not really inefficient either way + int i; + + for( i = ret; i > 0; i--, s--) { + if ((s->pressure == 0) || (flush_count > 7)) { + // when pen is lifted, or a fast movement is detected, flush stored history + xyhist_full = 0; + xyhist_counter = 0; + xyhist_index = 0; + flush_count = 0; + } else { + average_xyhist[xyhist_index].x = s->x; + average_xyhist[xyhist_index].y = s->y; + + xyhist_counter++; + if (xyhist_counter == XYHISTLENGTH) { + xyhist_full = 1; + } + + xyhist_index++; + if (xyhist_index == XYHISTLENGTH) { + xyhist_index = 0; // point back at beginning since array is full + } + + if (xyhist_full) { + //we have a full sample history, we can average this sample with the others + + int j = xyhist_index - 1; // point j to most recent entry in history + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // 15-sample weighted average, pyramid, provides great smoothing for precise + // operations like menus and drawing + + // sample 1 has weight of * 1 + newx = average_xyhist[j].x; + newy = average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 2 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 3 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 4 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 5 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 6 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 7 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 8, middle sample, has weight of * 8 + newx += (average_xyhist[j].x << 3); + newy += (average_xyhist[j].y << 3); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 9 has weight of * 7 + newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; + newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 10 has weight of * 6 + newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); + newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 11 has weight of * 5 + newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 12 has weight of * 4 + newx += average_xyhist[j].x << 2; + newy += average_xyhist[j].y << 2; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 13 has weight of * 3 + newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; + newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 14 has weight of * 2 + newx += average_xyhist[j].x << 1; + newy += average_xyhist[j].y << 1; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // sample 15 has weight of * 1 + newx += average_xyhist[j].x; + newy += average_xyhist[j].y; + + j--; + if (j < 0) { + j = XYHISTLENGTH - 1; + } + + // divide results by 64 to provide average + samp->x = newx >> 6; + samp->y = newy >> 6; + } + } + } + + return ret; +} +//DKS - non-pyramid form of the above, I cannot tell a real difference, will use pyramid for now. //#define XYHISTLENGTH 15 //XYHIST average_xyhist[XYHISTLENGTH]; // @@ -777,70 +977,69 @@ // // 15-sample weighted average, pyramid, provides great smoothing for precise // // operations like menus and drawing // -// // sample 1 has weight of * 1 -// newx = average_xyhist[j].x; -// newy = average_xyhist[j].y; +// // sample 1 has weight of * 15 +// newx = average_xyhist[j].x * 15; +// newy = average_xyhist[j].y * 15; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 2 has weight of * 2 -// newx += average_xyhist[j].x << 1; -// newy += average_xyhist[j].y << 1; +// // sample 2 has weight of * 14 +// newx += average_xyhist[j].x * 14; +// newy += average_xyhist[j].y * 14; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 3 has weight of * 3 -// newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; -// +// // sample 3 has weight of * 13 +// newx += average_xyhist[j].x * 13; +// newy += average_xyhist[j].y * 13; // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 4 has weight of * 4 -// newx += average_xyhist[j].x << 2; -// newy += average_xyhist[j].y << 2; +// // sample 4 has weight of * 12 +// newx += average_xyhist[j].x * 12; +// newy += average_xyhist[j].y * 12; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 5 has weight of * 5 -// newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; -// newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; +// // sample 5 has weight of * 11 +// newx += average_xyhist[j].x * 11; +// newy += average_xyhist[j].y * 11; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 6 has weight of * 6 -// newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); -// newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); +// // sample 6 has weight of * 10 +// newx += average_xyhist[j].x * 10; +// newy += average_xyhist[j].y * 10; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 7 has weight of * 7 -// newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; -// newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; +// // sample 7 has weight of * 9 +// newx += average_xyhist[j].x * 9; +// newy += average_xyhist[j].y * 9; // // j--; // if (j < 0) { // j = XYHISTLENGTH - 1; // } // -// // sample 8, middle sample, has weight of * 8 +// // sample 8, middle sample, has weight of * 8 // newx += (average_xyhist[j].x << 3); // newy += (average_xyhist[j].y << 3); // @@ -912,213 +1111,15 @@ // j = XYHISTLENGTH - 1; // } // -// // divide results by 64 to provide average -// samp->x = newx >> 6; -// samp->y = newy >> 6; +// samp->x = newx / 120; +// samp->y = newy / 120; // } // } // } // // return ret; //} -#define XYHISTLENGTH 5 -XYHIST average_xyhist[XYHISTLENGTH]; -static inline int average_read(TSDEV *ts, TS_SAMPLE *samp, int nr) -{ - - int ret = 0; - int newx, newy; - - int flush_history = 0; // variance module will tell us if we are getting fast movements - static int flush_count = 0; // when we get enough fast movements, flush the history - static int xyhist_full = 0; //DKS - when we have a full four samples, this is 1 - static int xyhist_counter = 0; // DKS - how many entires in history? - static int xyhist_index = 0; //xyhist_index - 1 is index to most-recent sample in array - - ret = variance_read(ts, samp, nr, &flush_history); - flush_count += flush_history; - struct ts_sample *s; - s = samp + (ret - 1); // this module can handle more than one sample, but the gp2x - // touchscreen driver only ever provides 1 sample each read so - // it's not really necessary but not really inefficient either way - int i; - - for( i = ret; i > 0; i--, s--) { - if ((s->pressure == 0) || (flush_count > 7)) { - // when pen is lifted, or a fast movement is detected, flush stored history - xyhist_full = 0; - xyhist_counter = 0; - xyhist_index = 0; - flush_count = 0; - } else { - average_xyhist[xyhist_index].x = s->x; - average_xyhist[xyhist_index].y = s->y; - - xyhist_counter++; - if (xyhist_counter == XYHISTLENGTH) { - xyhist_full = 1; - } - - xyhist_index++; - if (xyhist_index == XYHISTLENGTH) { - xyhist_index = 0; // point back at beginning since array is full - } - - if (xyhist_full) { - //we have a full sample history, we can average this sample with the others - - int j = xyhist_index - 1; // point j to most recent entry in history - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // 15-sample weighted average, pyramid, provides great smoothing for precise - // operations like menus and drawing - - // sample 1 has weight of * 15 - newx = average_xyhist[j].x * 15; - newy = average_xyhist[j].y * 15; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 2 has weight of * 14 - newx += average_xyhist[j].x * 14; - newy += average_xyhist[j].y * 14; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 3 has weight of * 13 - newx += average_xyhist[j].x * 13; - newy += average_xyhist[j].y * 13; - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 4 has weight of * 12 - newx += average_xyhist[j].x * 12; - newy += average_xyhist[j].y * 12; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 5 has weight of * 11 - newx += average_xyhist[j].x * 11; - newy += average_xyhist[j].y * 11; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 6 has weight of * 10 - newx += average_xyhist[j].x * 10; - newy += average_xyhist[j].y * 10; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 7 has weight of * 9 - newx += average_xyhist[j].x * 9; - newy += average_xyhist[j].y * 9; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 8, middle sample, has weight of * 8 - newx += (average_xyhist[j].x << 3); - newy += (average_xyhist[j].y << 3); - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 9 has weight of * 7 - newx += (average_xyhist[j].x << 3) - average_xyhist[j].x; - newy += (average_xyhist[j].y << 3) - average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 10 has weight of * 6 - newx += (average_xyhist[j].x << 2) + (average_xyhist[j].x << 1); - newy += (average_xyhist[j].y << 2) + (average_xyhist[j].y << 1); - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 11 has weight of * 5 - newx += (average_xyhist[j].x << 2) + average_xyhist[j].x; - newy += (average_xyhist[j].y << 2) + average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 12 has weight of * 4 - newx += average_xyhist[j].x << 2; - newy += average_xyhist[j].y << 2; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 13 has weight of * 3 - newx += (average_xyhist[j].x << 1) + average_xyhist[j].x; - newy += (average_xyhist[j].y << 1) + average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 14 has weight of * 2 - newx += average_xyhist[j].x << 1; - newy += average_xyhist[j].y << 1; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - // sample 15 has weight of * 1 - newx += average_xyhist[j].x; - newy += average_xyhist[j].y; - - j--; - if (j < 0) { - j = XYHISTLENGTH - 1; - } - - samp->x = newx / 120; - samp->y = newy / 120; - } - } - } - - return ret; -} - /****************************** * linear ******************************/ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sen...@us...> - 2008-08-13 00:01:02
|
Revision: 323 http://open2x.svn.sourceforge.net/open2x/?rev=323&view=rev Author: senquack Date: 2008-08-13 00:01:07 +0000 (Wed, 13 Aug 2008) Log Message: ----------- Making mtdblock4 default root in .config Modified Paths: -------------- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config Modified: trunk/kernel/linux-open2x-2.4.26_FW2-3/.config =================================================================== --- trunk/kernel/linux-open2x-2.4.26_FW2-3/.config 2008-08-12 23:59:38 UTC (rev 322) +++ trunk/kernel/linux-open2x-2.4.26_FW2-3/.config 2008-08-13 00:01:07 UTC (rev 323) @@ -200,7 +200,7 @@ # CONFIG_BINFMT_MISC is not set # CONFIG_PM is not set # CONFIG_ARTHUR is not set -CONFIG_CMDLINE="root=/dev/mtdblock3 rw" +CONFIG_CMDLINE="root=/dev/mtdblock4 rw" CONFIG_ALIGNMENT_TRAP=y # This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |