diff --git a/360/media/hd/rarch_main.xui b/360/media/hd/rarch_main.xui index 9b3950aef3..42328264c9 100644 --- a/360/media/hd/rarch_main.xui +++ b/360/media/hd/rarch_main.xui @@ -6,17 +6,17 @@ XuiScene1 -752.000061 -512.000122 -264.000031,88.000008,0.000000 +584.528076 +363.320007 +347.429474,184.843964,0.000000 RetroArchMain XuiBtnRomBrowser -689.672302 -48.992096 -38.127724,73.215515,0.000000 +488.312012 +30.799988 +38.127724,64.215515,0.000000 245.362122,102.247192,0.000000 XuiBtnQuit XuiBtnQuickMenu @@ -39,9 +39,9 @@ XuiBtnSettings -689.672302 -48.992096 -40.000000,263.960022,0.000000 +488.312012 +30.799988 +38.127960,196.615982,0.000000 XuiBtnControls XuiBtnLibsnesCore Settings @@ -50,9 +50,9 @@ XuiBtnQuit -689.672302 -48.992096 -40.199776,392.352020,0.000000 +488.312012 +30.799988 +38.327736,287.007996,0.000000 245.162109,-84.153275,0.000000 XuiBtnLibsnesCore XuiBtnRomBrowser @@ -64,7 +64,7 @@ XuiLblCore 124.000000 28.000000 -40.000000,448.400055,0.000000 +12.544006,324.792023,0.000000 Libretro core: @@ -73,7 +73,7 @@ XuiTxtCoreText 224.399963 34.000000 -162.400024,448.000031,0.000000 +134.944031,324.391998,0.000000 0xff0f0f0f 0x800f0f0f Arial Unicode MS @@ -82,9 +82,9 @@ XuiBtnQuickMenu -689.672302 -48.992096 -39.999996,138.000000,0.000000 +488.312012 +30.799988 +38.130001,106.655991,0.000000 XuiBtnRomBrowser XuiBtnControls Quick Menu @@ -93,9 +93,9 @@ XuiBtnControls -689.672302 -48.992096 -40.002041,202.000015,0.000000 +488.312012 +30.799988 +38.130001,151.655991,0.000000 XuiBtnQuickMenu XuiBtnSettings Controls @@ -104,9 +104,9 @@ XuiBtnLibsnesCore -689.672302 -48.992096 -40.000000,328.959991,0.000000 +488.312012 +30.799988 +38.127960,241.615982,0.000000 XuiBtnSettings XuiBtnQuit Change libretro core diff --git a/360/media/hd/rarch_quickmenu.xui b/360/media/hd/rarch_quickmenu.xui index d1ba7e28c7..e4ef653472 100644 --- a/360/media/hd/rarch_quickmenu.xui +++ b/360/media/hd/rarch_quickmenu.xui @@ -8,7 +8,7 @@ XuiScene1 824.000061 496.000061 -182.000031,120.000023,0.000000 +32.029999,76.040001,0.000000 RetroArchQuickMenu @@ -127,6 +127,18 @@ Return to Dashboard 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_controls.xui b/360/media/sd/rarch_controls.xui index b8d9f35a73..16632792a3 100644 --- a/360/media/sd/rarch_controls.xui +++ b/360/media/sd/rarch_controls.xui @@ -8,7 +8,7 @@ XuiScene1 584.528076 363.320007 -344.000031,184.000015,0.000000 +32.029999,76.040001,0.000000 RetroArchControls @@ -266,6 +266,18 @@ Reset all buttons to defaults 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_filebrowser.xui b/360/media/sd/rarch_filebrowser.xui index 8a1fefcd56..8eec41c80d 100644 --- a/360/media/sd/rarch_filebrowser.xui +++ b/360/media/sd/rarch_filebrowser.xui @@ -8,7 +8,7 @@ XuiSceneFileBrowser 575.888062 336.017609 -333.995880,209.035965,0.000000 +32.029999,76.040001,0.000000 RetroArchFileBrowser @@ -129,6 +129,18 @@ 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_libretrocore_browser.xui b/360/media/sd/rarch_libretrocore_browser.xui index 01a196d110..25f8692396 100644 --- a/360/media/sd/rarch_libretrocore_browser.xui +++ b/360/media/sd/rarch_libretrocore_browser.xui @@ -8,7 +8,7 @@ XuiSceneCoreFileBrowser 575.888062 336.017609 -353.995880,209.035965,0.000000 +32.029999,76.040001,0.000000 RetroArchCoreBrowser @@ -139,6 +139,18 @@ 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_main.xui b/360/media/sd/rarch_main.xui index 42328264c9..05cee67d85 100644 --- a/360/media/sd/rarch_main.xui +++ b/360/media/sd/rarch_main.xui @@ -8,7 +8,7 @@ XuiScene1 584.528076 363.320007 -347.429474,184.843964,0.000000 +32.029472,76.043968,0.000000 RetroArchMain diff --git a/360/media/sd/rarch_quickmenu.xui b/360/media/sd/rarch_quickmenu.xui index 7e460bb7b5..023641dc4f 100644 --- a/360/media/sd/rarch_quickmenu.xui +++ b/360/media/sd/rarch_quickmenu.xui @@ -8,7 +8,7 @@ XuiScene1 584.528076 363.320007 -302.429474,184.843964,0.000000 +32.029999,76.040001,0.000000 RetroArchQuickMenu @@ -115,6 +115,18 @@ Return to Dashboard 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_settings.xui b/360/media/sd/rarch_settings.xui index 3b63a8a502..9703a87690 100644 --- a/360/media/sd/rarch_settings.xui +++ b/360/media/sd/rarch_settings.xui @@ -8,7 +8,7 @@ XuiScene1 584.528076 363.320007 -344.000031,184.000015,0.000000 +32.029999,76.040001,0.000000 RetroArchSettings @@ -187,6 +187,18 @@ Cutom Scaling Factor: 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/media/sd/rarch_shader_browser.xui b/360/media/sd/rarch_shader_browser.xui index b7deca9427..18a2682c4c 100644 --- a/360/media/sd/rarch_shader_browser.xui +++ b/360/media/sd/rarch_shader_browser.xui @@ -8,7 +8,7 @@ XuiSceneCoreFileBrowser 575.888062 336.017609 -353.995880,209.035965,0.000000 +32.029999,76.040001,0.000000 RetroArchShaderBrowser @@ -175,6 +175,18 @@ 0.000000,10.000000,0.000000 + + +control_ListItem +226.000000 +45.000000 +7.000000,22.000000,0.000000 +5 +false +XuiButton +0.000000,10.000000,0.000000 + + diff --git a/360/menu.cpp b/360/menu.cpp index 444e6bbf64..657b344653 100644 --- a/360/menu.cpp +++ b/360/menu.cpp @@ -798,6 +798,8 @@ int menu_init (void) xdk360_video_t *vid = (xdk360_video_t*)driver.video_data; + bool hdmenus_allowed = g_console.menus_hd_enable; + hr = app.InitShared(vid->d3d_render_device, &vid->d3dpp, XuiPNGTextureLoader); if (hr < 0) @@ -821,7 +823,7 @@ int menu_init (void) return 1; } - hr = XuiSceneCreate(L"file://game:/media/sd/", L"rarch_main.xur", NULL, &app.hMainScene); + hr = XuiSceneCreate(hdmenus_allowed ? L"file://game:/media/hd/" : L"file://game:/media/sd/", L"rarch_main.xur", NULL, &app.hMainScene); if (hr < 0) { RARCH_ERR("Failed to create scene 'rarch_main.xur'.\n"); diff --git a/AUTHORS b/AUTHORS index 4400772483..4045c6066d 100644 --- a/AUTHORS +++ b/AUTHORS @@ -11,3 +11,6 @@ Daniel De Matteis - - PlayStation 3 port - XBox 360 XDK port +tukuyomi - + - Cleanups in quickbuild + diff --git a/Makefile.ps3 b/Makefile.ps3 index f42249d76b..78c26d75c7 100644 --- a/Makefile.ps3 +++ b/Makefile.ps3 @@ -1,4 +1,4 @@ -RARCH_VERSION = "0.9.6-rc1" +RARCH_VERSION = "0.9.6" #which compiler to build with - GCC or SNC #set to GCC for debug builds for use with debugger @@ -122,7 +122,7 @@ create-salamander: create-shaders: ifeq ($(DOWNLOAD_SHADERS),1) $(RM) -rf ps3/pkg/USRDIR/cores/shaders - $(GIT) clone git://github.com/twinaphex/common-shaders.git ps3/pkg/USRDIR/cores/shaders + $(GIT) clone git://github.com/libretro/common-shaders.git ps3/pkg/USRDIR/cores/shaders endif pkg: $(PPU_TARGET) create-shaders create-npdrm-salamander create-npdrm-core diff --git a/Makefile.wii b/Makefile.wii index 94a039f730..68064c0ca0 100644 --- a/Makefile.wii +++ b/Makefile.wii @@ -37,7 +37,7 @@ ifeq ($(HAVE_FILE_LOGGER), 1) CFLAGS += -DHAVE_FILE_LOGGER endif -CFLAGS += -std=gnu99 -DRARCH_CONSOLE -DHAVE_CONFIGFILE=1 -DGEKKO -DHW_RVL -DHAVE_ZLIB -DHAVE_RARCH_MAIN_WRAP -DHAVE_FREETYPE -DHAVE_GRIFFIN=1 -DPACKAGE_VERSION=\"0.9.6-rc1\" -Dmain=ssnes_main -Wno-char-subscripts -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC_DEVELOPMENT_UDP_PORT=$(PC_DEVELOPMENT_UDP_PORT) +CFLAGS += -std=gnu99 -DRARCH_CONSOLE -DHAVE_CONFIGFILE=1 -DGEKKO -DHW_RVL -DHAVE_ZLIB -DHAVE_RARCH_MAIN_WRAP -DHAVE_FREETYPE -DHAVE_GRIFFIN=1 -DPACKAGE_VERSION=\"0.9.6\" -Dmain=ssnes_main -Wno-char-subscripts -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC_DEVELOPMENT_UDP_PORT=$(PC_DEVELOPMENT_UDP_PORT) ifeq ($(DEBUG), 1) CFLAGS += -O0 -g diff --git a/Makefile.win b/Makefile.win index 4ce79a2b52..9cde4ad3cc 100644 --- a/Makefile.win +++ b/Makefile.win @@ -30,7 +30,7 @@ endif libretro ?= -lretro LIBS = -lm -DEFINES = -I. -DHAVE_CONFIGFILE -DHAVE_SDL -DHAVE_SCREENSHOTS -DHAVE_BSV_MOVIE -DPACKAGE_VERSION=\"0.9.6-rc1\" +DEFINES = -I. -DHAVE_CONFIGFILE -DHAVE_SDL -DHAVE_SCREENSHOTS -DHAVE_BSV_MOVIE -DPACKAGE_VERSION=\"0.9.6\" LDFLAGS = -L. -static-libgcc LDCXXFLAGS = -s @@ -192,10 +192,10 @@ clean: rm -f tools/*.o dist_x86: all - zip -r retroarch-win32-0.9.6-rc1.zip $(TARGET) $(JTARGET) retroarch.cfg SDL.dll + zip -r retroarch-win32-0.9.6.zip $(TARGET) $(JTARGET) retroarch.cfg SDL.dll dist_x86_64: all - zip -r retroarch-win64-0.9.6-rc1.zip $(TARGET) $(JTARGET) retroarch.cfg SDL.dll + zip -r retroarch-win64-0.9.6.zip $(TARGET) $(JTARGET) retroarch.cfg SDL.dll libs_x86: wget https://github.com/downloads/Themaister/RetroArch/RetroArch-win32-libs.zip --no-check-certificate diff --git a/Makefile.xenon b/Makefile.xenon index 54d0c8d407..ec25a6d6fa 100644 --- a/Makefile.xenon +++ b/Makefile.xenon @@ -21,7 +21,7 @@ INCDIRS = -I. -I$(DEVKITXENON)/usr/include OBJ = fifo_buffer.o retroarch.o driver.o file.o file_path.o settings.o message.o rewind.o movie.o gfx/gfx_common.o patch.o compat/compat.o screenshot.o audio/hermite.o dynamic.o audio/utils.o conf/config_file.o xenon/main.o xenon/xenon360_audio.o xenon/xenon360_input.o xenon/xenon360_video.o LIBS = -lretro -lxenon -lm -lc -DEFINES = -std=gnu99 -DHAVE_CONFIGFILE=1 -DPACKAGE_VERSION=\"0.9.6-rc1\" -DRARCH_CONSOLE -DHAVE_GETOPT_LONG=1 -Dmain=rarch_main +DEFINES = -std=gnu99 -DHAVE_CONFIGFILE=1 -DPACKAGE_VERSION=\"0.9.6\" -DRARCH_CONSOLE -DHAVE_GETOPT_LONG=1 -Dmain=rarch_main DEFINES += -maltivec -mhard-float -m32 -mpowerpc64 -mcpu=cell -mtune=cell -fno-pic -g -Wall -DXENON $(INCDIRS) DEFINES += -u read -u _start -u exc_base diff --git a/README.md b/README.md index 2a7dad0cbc..251dd8cf36 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ Latest Windows binaries are currently hosted on my [homepage](http://themaister. - GUI frontend for PC: [RetroArch-Phoenix](https://github.com/Themaister/RetroArch-Phoenix) - Cg/HLSL shaders: [common-shaders](https://github.com/twinaphex/common-shaders) - More Cg shaders: [Emulator-Shader-Pack](https://github.com/Themaister/Emulator-Shader-Pack) - - Helper scripts to build libretro implementations: [libretro-super](https://github.com/Themaister/libretro-super) + - Helper scripts to build libretro implementations: [libretro-super](https://github.com/libretro/libretro-super) # Philosophy diff --git a/config.def.h b/config.def.h index d0b4f6760d..2e986c59ed 100644 --- a/config.def.h +++ b/config.def.h @@ -281,6 +281,11 @@ static const bool block_sram_overwrite = false; // When the ROM is loaded, state index will be set to the highest existing value. static const bool savestate_auto_index = false; +// Automatically saves a savestate at the end of RetroArch's lifetime. +// The path is $SRAM_PATH.auto. +// RetroArch will automatically load any savestate with this path on startup. +static const bool savestate_auto_save = false; + // Slowmotion ratio. static const float slowmotion_ratio = 3.0; diff --git a/configure b/configure index d50a2b8eae..2c058a58ba 100755 --- a/configure +++ b/configure @@ -2,9 +2,10 @@ echo "" -. qb/config.params.sh +PACKAGE_NAME=retroarch +PACKAGE_VERSION=0.9.6 -parse_input "$@" +. qb/qb.params.sh . qb/qb.comp.sh . qb/config.libs.sh diff --git a/console/console_ext.h b/console/console_ext.h index 299c8f33e8..4ef5611d11 100644 --- a/console/console_ext.h +++ b/console/console_ext.h @@ -31,6 +31,21 @@ VIDEO ============================================================ */ +#define MIN_SCALING_FACTOR (1.0f) + +#if defined(__CELLOS_LV2__) +#define MAX_SCALING_FACTOR (5.0f) +#else +#define MAX_SCALING_FACTOR (2.0f) +#endif + +enum +{ + FBO_DEINIT = 0, + FBO_INIT, + FBO_REINIT +}; + enum aspect_ratio { ASPECT_RATIO_1_1 = 0, diff --git a/console/console_settings.c b/console/console_settings.c index d3cd8bf268..ebd666c8ad 100644 --- a/console/console_settings.c +++ b/console/console_settings.c @@ -27,11 +27,11 @@ void rarch_settings_change(unsigned setting) switch(setting) { case S_ASPECT_RATIO_DECREMENT: - if(g_console.aspect_ratio_index > 0) + if(g_console.aspect_ratio_index > 0) g_console.aspect_ratio_index--; break; - case S_ASPECT_RATIO_INCREMENT: - if(g_console.aspect_ratio_index < LAST_ASPECT_RATIO) + case S_ASPECT_RATIO_INCREMENT: + if(g_console.aspect_ratio_index < LAST_ASPECT_RATIO) g_console.aspect_ratio_index++; break; case S_FRAME_ADVANCE: @@ -57,6 +57,20 @@ void rarch_settings_change(unsigned setting) if(g_console.overscan_amount == 0.0f) g_console.overscan_enable = 0; break; + case S_RESOLUTION_PREVIOUS: + if (g_console.current_resolution_index) + { + g_console.current_resolution_index--; + g_console.current_resolution_id = g_console.supported_resolutions[g_console.current_resolution_index]; + } + break; + case S_RESOLUTION_NEXT: + if (g_console.current_resolution_index + 1 < g_console.supported_resolutions_count) + { + g_console.current_resolution_index++; + g_console.current_resolution_id = g_console.supported_resolutions[g_console.current_resolution_index]; + } + break; case S_QUIT: g_console.menu_enable = false; g_console.ingame_menu_enable = false; diff --git a/console/console_settings.h b/console/console_settings.h index d2ef16c157..bebc2df457 100644 --- a/console/console_settings.h +++ b/console/console_settings.h @@ -33,6 +33,8 @@ enum S_OVERSCAN_DECREMENT, S_OVERSCAN_INCREMENT, S_QUIT, + S_RESOLUTION_PREVIOUS, + S_RESOLUTION_NEXT, S_RETURN_TO_DASHBOARD, S_RETURN_TO_GAME, S_RETURN_TO_LAUNCHER, diff --git a/console/rzlib/rzlib.c b/console/rzlib/rzlib.c index c8257f2773..a82a5f19ec 100644 --- a/console/rzlib/rzlib.c +++ b/console/rzlib/rzlib.c @@ -3398,3 +3398,36 @@ extern int unzSetOffset (unzFile file, unsigned long pos) s->current_file_ok = (err == UNZ_OK); return err; } + +int uncompress (unsigned char *dest, unsigned int *destLen, const unsigned char *source, unsigned int sourceLen) +{ + z_stream stream; + int err; + + stream.next_in = (unsigned char*)source; + stream.avail_in = (unsigned int)sourceLen; + /* Check for source > 64K on 16-bit machine: */ + if ((unsigned int)stream.avail_in != sourceLen) return Z_BUF_ERROR; + + stream.next_out = dest; + stream.avail_out = (unsigned int)*destLen; + if ((unsigned int)stream.avail_out != *destLen) return Z_BUF_ERROR; + + stream.zalloc = (alloc_func)0; + stream.zfree = (free_func)0; + + err = inflateInit(&stream); + if (err != Z_OK) return err; + + err = inflate(&stream, Z_FINISH); + if (err != Z_STREAM_END) { + inflateEnd(&stream); + if (err == Z_NEED_DICT || (err == Z_BUF_ERROR && stream.avail_in == 0)) + return Z_DATA_ERROR; + return err; + } + *destLen = stream.total_out; + + err = inflateEnd(&stream); + return err; +} diff --git a/docs/retroarch.1 b/docs/retroarch.1 index 076944ed19..13192b6973 100644 --- a/docs/retroarch.1 +++ b/docs/retroarch.1 @@ -177,6 +177,16 @@ Clients can connect and disconnect at any time. Clients thus cannot interact as player 2. For spectating mode to work, both host and clients will need to use this flag. +.TP +\fB--command CMD\fR +Sends a command over UDP to an already running RetroArch application, and exit. +The command is formatted as "COMMAND:HOST:PORT". +HOST and PORT are both optional. "COMMAND:HOST" will set PORT to +"network_cmd_port" default setting. +If only "COMMAND" is used, HOST and PORT will be assumed to be "localhost" and "network_cmd_port" respectively. + +The available commands are listed if "COMMAND" is invalid. + .TP \fB--nick NICK\fR Pick a nickname for use with netplay. diff --git a/dynamic.c b/dynamic.c index 2bf7d65f46..c0d2a8d542 100644 --- a/dynamic.c +++ b/dynamic.c @@ -320,6 +320,10 @@ static bool environment_cb(unsigned cmd, void *data) g_extern.system.shutdown = true; break; + case RETRO_ENVIRONMENT_SET_PERFORMANCE_LEVEL: + g_extern.system.performance_level = *(const unsigned*)data; + break; + default: RARCH_LOG("Environ UNSUPPORTED (#%u).\n", cmd); return false; diff --git a/general.h b/general.h index 40c75fe97a..796079c323 100644 --- a/general.h +++ b/general.h @@ -181,6 +181,7 @@ struct settings bool block_sram_overwrite; bool savestate_auto_index; + bool savestate_auto_save; bool network_cmd_enable; uint16_t network_cmd_port; @@ -329,6 +330,7 @@ struct global unsigned rotation; bool shutdown; + unsigned performance_level; } system; struct diff --git a/gfx/context/ps3_ctx.c b/gfx/context/ps3_ctx.c index 4d137d574f..960108eb72 100644 --- a/gfx/context/ps3_ctx.c +++ b/gfx/context/ps3_ctx.c @@ -309,24 +309,6 @@ void gfx_ctx_get_available_resolutions (void) g_console.check_available_resolutions = true; } -void ps3_next_resolution (void) -{ - if (g_console.current_resolution_index + 1 < g_console.supported_resolutions_count) - { - g_console.current_resolution_index++; - g_console.current_resolution_id = g_console.supported_resolutions[g_console.current_resolution_index]; - } -} - -void ps3_previous_resolution (void) -{ - if (g_console.current_resolution_index) - { - g_console.current_resolution_index--; - g_console.current_resolution_id = g_console.supported_resolutions[g_console.current_resolution_index]; - } -} - int gfx_ctx_check_resolution(unsigned resolution_id) { return cellVideoOutGetResolutionAvailability(CELL_VIDEO_OUT_PRIMARY, resolution_id, CELL_VIDEO_OUT_ASPECT_AUTO, 0); diff --git a/gfx/gl.c b/gfx/gl.c index 1b3352bb43..518ff7cd27 100644 --- a/gfx/gl.c +++ b/gfx/gl.c @@ -338,7 +338,7 @@ error: return false; } -static void gl_deinit_fbo(gl_t *gl) +void gl_deinit_fbo(gl_t *gl) { if (gl->fbo_inited) { @@ -352,7 +352,7 @@ static void gl_deinit_fbo(gl_t *gl) } } -static void gl_init_fbo(gl_t *gl, unsigned width, unsigned height) +void gl_init_fbo(gl_t *gl, unsigned width, unsigned height) { // No need to use FBOs. if (!g_settings.video.render_to_texture && gl_shader_num() == 0) diff --git a/gfx/gl_common.h b/gfx/gl_common.h index 0cb15c479c..6b43d7b8cf 100644 --- a/gfx/gl_common.h +++ b/gfx/gl_common.h @@ -225,4 +225,7 @@ void gl_shader_use(unsigned index); void gl_set_projection(gl_t *gl, struct gl_ortho *ortho, bool allow_rotate); void gl_set_viewport(gl_t *gl, unsigned width, unsigned height, bool force_full, bool allow_rotate); +void gl_init_fbo(gl_t * gl, unsigned width, unsigned height); +void gl_deinit_fbo(gl_t *gl); + #endif diff --git a/libretro.h b/libretro.h index 1ce9cbd382..e497aff58d 100755 --- a/libretro.h +++ b/libretro.h @@ -122,6 +122,27 @@ extern "C" { // Should only be used if game has a specific // way to shutdown the game from a menu item or similar. +#define RETRO_ENVIRONMENT_SET_PERFORMANCE_LEVEL 8 + // const unsigned * -- + // Gives a hint to the frontend how demanding this implementation + // is on a system. E.g. reporting a level of 2 means + // this implementation should run decently on all frontends + // of level 2 and up. + // + // It can be used by the frontend to potentially warn + // about too demanding implementations. + // + // The levels are "floating", but roughly defined as: + // 1: Low-powered devices such as Raspberry Pi, smart phones, tablets, etc. + // 2: Medium-spec consoles, such as PS3/360, with sub-par CPUs. + // 3: Modern desktop/laptops with reasonably powerful CPUs. + // 4: High-end desktops with very powerful CPUs. + // + // This function can be called on a per-game basis, + // as certain games an implementation can play might be + // particularily demanding. + // If called, it should be called in retro_load_game(). + struct retro_message { const char *msg; // Message to be displayed. diff --git a/msvc-360/RetroArch-360/RetroArch-360.vcxproj b/msvc-360/RetroArch-360/RetroArch-360.vcxproj index bd321a251c..27e22ed102 100644 --- a/msvc-360/RetroArch-360/RetroArch-360.vcxproj +++ b/msvc-360/RetroArch-360/RetroArch-360.vcxproj @@ -113,7 +113,7 @@ true false MultiThreadedDebug - _DEBUG;_XBOX;PACKAGE_VERSION="0.9.6-rc1";%(PreprocessorDefinitions);_CRT_SECURE_NO_WARNINGS;main=rarch_main;RARCH_CONSOLE;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + _DEBUG;_XBOX;PACKAGE_VERSION="0.9.6";%(PreprocessorDefinitions);_CRT_SECURE_NO_WARNINGS;main=rarch_main;RARCH_CONSOLE;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 Callcap @@ -151,7 +151,7 @@ AnalyzeOnly false MultiThreadedDebug - _DEBUG;_XBOX;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6-rc1";_CRT_SECURE_NO_WARNINGS;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;RARCH_CONSOLE;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + _DEBUG;_XBOX;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6";_CRT_SECURE_NO_WARNINGS;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;RARCH_CONSOLE;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 Callcap @@ -190,7 +190,7 @@ Size false MultiThreaded - NDEBUG;_XBOX;PROFILE;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6-rc1";_CRT_SECURE_NO_WARNINGS;RARCH_CONSOLE;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + NDEBUG;_XBOX;PROFILE;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6";_CRT_SECURE_NO_WARNINGS;RARCH_CONSOLE;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 Callcap @@ -234,7 +234,7 @@ Size false MultiThreaded - NDEBUG;_XBOX;PROFILE;FASTCAP;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6-rc1";_CRT_SECURE_NO_WARNINGS;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + NDEBUG;_XBOX;PROFILE;FASTCAP;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6";_CRT_SECURE_NO_WARNINGS;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 true @@ -275,7 +275,7 @@ false false MultiThreaded - NDEBUG;_XBOX;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6-rc1";_CRT_SECURE_NO_WARNINGS;main=rarch_main;RARCH_CONSOLE=1;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + NDEBUG;_XBOX;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6";_CRT_SECURE_NO_WARNINGS;main=rarch_main;RARCH_CONSOLE=1;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 true @@ -316,7 +316,7 @@ false false MultiThreaded - NDEBUG;_XBOX;LTCG;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6-rc1";_CRT_SECURE_NO_WARNINGS;RARCH_CONSOLE;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 + NDEBUG;_XBOX;LTCG;%(PreprocessorDefinitions);PACKAGE_VERSION="0.9.6";_CRT_SECURE_NO_WARNINGS;RARCH_CONSOLE;main=rarch_main;HAVE_CONFIGFILE;HAVE_FILEBROWSER;HAVE_NETPLAY;HAVE_SOCKET_LEGACY;HAVE_ZLIB;HAVE_RARCH_MAIN_WRAP;HAVE_RARCH_EXEC;HAVE_LIBRETRO_MANAGEMENT;D3DCOMPILE_USEVOIDS;HAVE_GRIFFIN;HAVE_HLSL;HAVE_VID_CONTEXT;HAVE_D3D9 true diff --git a/msvc-ps3/RetroArch-PS3/RetroArch-PS3.vcxproj b/msvc-ps3/RetroArch-PS3/RetroArch-PS3.vcxproj index 5cb4a35f6e..7cb44aa56e 100644 --- a/msvc-ps3/RetroArch-PS3/RetroArch-PS3.vcxproj +++ b/msvc-ps3/RetroArch-PS3/RetroArch-PS3.vcxproj @@ -48,7 +48,7 @@ - _DEBUG;__CELL_ASSERT__;HAVE_OPENGL=1;RARCH_CONSOLE;HAVE_CG=1;HAVE_CONFIGFILE=1;HAVE_NETPLAY=1;HAVE_SOCKET_LEGACY=1;PACKAGE_VERSION="0.9.6-rc1";HAVE_SCREENSHOTS_BUILTIN=1;main=rarch_main;%(UserPreprocessorDefinitions);HAVE_RARCH_MAIN_WRAP;HAVE_RSOUND;HAVE_RARCH_EXEC;HAVE_ZLIB=1;HAVE_LIBRETRO_MANAGEMENT + _DEBUG;__CELL_ASSERT__;HAVE_OPENGL=1;RARCH_CONSOLE;HAVE_CG=1;HAVE_CONFIGFILE=1;HAVE_NETPLAY=1;HAVE_SOCKET_LEGACY=1;PACKAGE_VERSION="0.9.6";HAVE_SCREENSHOTS_BUILTIN=1;main=rarch_main;%(UserPreprocessorDefinitions);HAVE_RARCH_MAIN_WRAP;HAVE_RSOUND;HAVE_RARCH_EXEC;HAVE_ZLIB=1;HAVE_LIBRETRO_MANAGEMENT true %(UserPreprocessorDefinitions);$(BuiltInDefines);__INTELLISENSE__;%(PreprocessorDefinitions); NotUsing @@ -60,7 +60,7 @@ - NDEBUG;HAVE_OPENGL=1;RARCH_CONSOLE;HAVE_CG=1;HAVE_CONFIGFILE=1;HAVE_NETPLAY=1;HAVE_SOCKET_LEGACY=1;PACKAGE_VERSION="0.9.6-rc1";HAVE_SCREENSHOTS_BUILTIN=1;main="rarch_main";%(UserPreprocessorDefinitions);HAVE_RARCH_MAIN_WRAP;HAVE_RSOUND;HAVE_RARCH_EXEC;HAVE_ZLIB=1;HAVE_LIBRETRO_MANAGEMENT + NDEBUG;HAVE_OPENGL=1;RARCH_CONSOLE;HAVE_CG=1;HAVE_CONFIGFILE=1;HAVE_NETPLAY=1;HAVE_SOCKET_LEGACY=1;PACKAGE_VERSION="0.9.6";HAVE_SCREENSHOTS_BUILTIN=1;main="rarch_main";%(UserPreprocessorDefinitions);HAVE_RARCH_MAIN_WRAP;HAVE_RSOUND;HAVE_RARCH_EXEC;HAVE_ZLIB=1;HAVE_LIBRETRO_MANAGEMENT Level2 %(UserPreprocessorDefinitions);$(BuiltInDefines);__INTELLISENSE__;%(PreprocessorDefinitions); NotUsing diff --git a/netplay.c b/netplay.c index 9c977b9097..26bfac9440 100644 --- a/netplay.c +++ b/netplay.c @@ -233,19 +233,86 @@ static void log_connection(const struct sockaddr_storage *their_addr, } #endif +static int init_tcp_connection(const struct addrinfo *res, bool server, bool spectate, + struct sockaddr *other_addr, socklen_t addr_size) +{ + bool ret = true; + int fd = socket(res->ai_family, res->ai_socktype, res->ai_protocol); + if (fd < 0) + { + ret = false; + goto end; + } + + if (server) + { + if (connect(fd, res->ai_addr, res->ai_addrlen) < 0) + { + ret = false; + goto end; + } + } + else if (spectate) + { + int yes = 1; + setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, CONST_CAST &yes, sizeof(int)); + + if (bind(fd, res->ai_addr, res->ai_addrlen) < 0 || + listen(fd, MAX_SPECTATORS) < 0) + { + ret = false; + goto end; + } + } + else + { + int yes = 1; + setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, CONST_CAST &yes, sizeof(int)); + + if (bind(fd, res->ai_addr, res->ai_addrlen) < 0 || + listen(fd, 1) < 0) + { + ret = false; + goto end; + } + + int new_fd = accept(fd, other_addr, &addr_size); + if (new_fd < 0) + { + ret = false; + goto end; + } + + close(fd); + fd = new_fd; + } + +end: + if (!ret && fd >= 0) + { + close(fd); + fd = -1; + } + + return fd; +} + static bool init_tcp_socket(netplay_t *handle, const char *server, uint16_t port, bool spectate) { struct addrinfo hints, *res = NULL; memset(&hints, 0, sizeof(hints)); + #if defined(_WIN32) || defined(HAVE_SOCKET_LEGACY) hints.ai_family = AF_INET; #else hints.ai_family = AF_UNSPEC; #endif + hints.ai_socktype = SOCK_STREAM; if (!server) hints.ai_flags = AI_PASSIVE; + bool ret = false; char port_buf[16]; snprintf(port_buf, sizeof(port_buf), "%hu", (unsigned short)port); if (getaddrinfo(server, port_buf, &hints, &res) < 0) @@ -254,75 +321,29 @@ static bool init_tcp_socket(netplay_t *handle, const char *server, uint16_t port if (!res) return false; - handle->fd = socket(res->ai_family, res->ai_socktype, res->ai_protocol); - if (handle->fd < 0) + // If "localhost" is used, it is important to check every possible address for ipv4/ipv6. + const struct addrinfo *tmp_info = res; + while (tmp_info) { - RARCH_ERR("Failed to init socket...\n"); - - if (res) - freeaddrinfo(res); - return false; - } - - if (server) - { - if (connect(handle->fd, res->ai_addr, res->ai_addrlen) < 0) + int fd; + if ((fd = init_tcp_connection(tmp_info, server, handle->spectate, + (struct sockaddr*)&handle->other_addr, sizeof(handle->other_addr))) >= 0) { - RARCH_ERR("Failed to connect to server.\n"); - close(handle->fd); - handle->fd = -1; - freeaddrinfo(res); - return false; - } - } - else if (handle->spectate) - { - int yes = 1; - setsockopt(handle->fd, SOL_SOCKET, SO_REUSEADDR, CONST_CAST &yes, sizeof(int)); - - if (bind(handle->fd, res->ai_addr, res->ai_addrlen) < 0 || - listen(handle->fd, MAX_SPECTATORS) < 0) - { - RARCH_ERR("Failed to bind socket.\n"); - close(handle->fd); - handle->fd = -1; - freeaddrinfo(res); - return false; - } - } - else - { - int yes = 1; - setsockopt(handle->fd, SOL_SOCKET, SO_REUSEADDR, CONST_CAST &yes, sizeof(int)); - - if (bind(handle->fd, res->ai_addr, res->ai_addrlen) < 0 || - listen(handle->fd, 1) < 0) - { - RARCH_ERR("Failed to bind socket.\n"); - close(handle->fd); - handle->fd = -1; - freeaddrinfo(res); - return false; + ret = true; + handle->fd = fd; + break; } - socklen_t addr_size = sizeof(handle->other_addr); - int new_fd = accept(handle->fd, - (struct sockaddr*)&handle->other_addr, &addr_size); - if (new_fd < 0) - { - RARCH_ERR("Failed to accept socket.\n"); - close(handle->fd); - handle->fd = -1; - freeaddrinfo(res); - return false; - } - close(handle->fd); - handle->fd = new_fd; + tmp_info = tmp_info->ai_next; } - freeaddrinfo(res); + if (res) + freeaddrinfo(res); - return true; + if (!ret) + RARCH_ERR("Failed to set up netplay sockets.\n"); + + return ret; } static bool init_udp_socket(netplay_t *handle, const char *server, uint16_t port) @@ -374,7 +395,7 @@ static bool init_udp_socket(netplay_t *handle, const char *server, uint16_t port } // Platform specific socket library init. -static bool init_network(void) +bool netplay_init_network(void) { static bool inited = false; if (inited) @@ -400,7 +421,7 @@ static bool init_network(void) static bool init_socket(netplay_t *handle, const char *server, uint16_t port) { - if (!init_network()) + if (!netplay_init_network()) return false; if (!init_tcp_socket(handle, server, port, handle->spectate)) @@ -717,8 +738,6 @@ netplay_t *netplay_new(const char *server, uint16_t port, bool spectate, const char *nick) { - (void)spectate; - if (frames > UDP_FRAME_PACKETS) frames = UDP_FRAME_PACKETS; diff --git a/netplay.h b/netplay.h index 5da2df58aa..4da0a58064 100644 --- a/netplay.h +++ b/netplay.h @@ -41,6 +41,8 @@ struct retro_callbacks retro_input_state_t state_cb; }; +bool netplay_init_network(void); + // Creates a new netplay handle. A NULL host means we're hosting (player 1). :) netplay_t *netplay_new(const char *server, uint16_t port, unsigned frames, diff --git a/network_cmd.c b/network_cmd.c index 258cd31a41..91ef85aabf 100644 --- a/network_cmd.c +++ b/network_cmd.c @@ -14,12 +14,17 @@ */ #include "netplay_compat.h" +#include "netplay.h" #include "network_cmd.h" #include "driver.h" #include "general.h" +#include "compat/strl.h" +#include "compat/posix_string.h" #include #include +#define DEFAULT_NETWORK_CMD_PORT 55355 + struct network_cmd { int fd; @@ -38,10 +43,15 @@ static bool socket_nonblock(int fd) network_cmd_t *network_cmd_new(uint16_t port) { + if (!netplay_init_network()) + return NULL; + network_cmd_t *handle = (network_cmd_t*)calloc(1, sizeof(*handle)); if (!handle) return NULL; + RARCH_LOG("Bringing up command interface on port %hu.\n", (unsigned short)port); + handle->fd = -1; struct addrinfo hints, *res = NULL; @@ -76,7 +86,6 @@ network_cmd_t *network_cmd_new(uint16_t port) } freeaddrinfo(res); - return handle; error: @@ -190,3 +199,114 @@ void network_cmd_pre_frame(network_cmd_t *handle) } } +static bool send_udp_packet(const char *host, uint16_t port, const char *msg) +{ + struct addrinfo hints, *res = NULL; + memset(&hints, 0, sizeof(hints)); +#if defined(_WIN32) || defined(HAVE_SOCKET_LEGACY) + hints.ai_family = AF_INET; +#else + hints.ai_family = AF_UNSPEC; +#endif + hints.ai_socktype = SOCK_DGRAM; + + int fd = -1; + bool ret = true; + char port_buf[16]; + + snprintf(port_buf, sizeof(port_buf), "%hu", (unsigned short)port); + if (getaddrinfo(host, port_buf, &hints, &res) < 0) + return false; + + // Send to all possible targets. + // "localhost" might resolve to several different IPs. + const struct addrinfo *tmp = res; + while (tmp) + { + fd = socket(tmp->ai_family, tmp->ai_socktype, tmp->ai_protocol); + if (fd < 0) + { + ret = false; + goto end; + } + + ssize_t len = strlen(msg); + ssize_t ret = sendto(fd, msg, len, 0, tmp->ai_addr, tmp->ai_addrlen); + if (ret < len) + { + ret = false; + goto end; + } + + close(fd); + fd = -1; + tmp = tmp->ai_next; + } + +end: + freeaddrinfo(res); + if (fd >= 0) + close(fd); + return ret; +} + +static bool verify_command(const char *cmd) +{ + for (unsigned i = 0; i < sizeof(map) / sizeof(map[0]); i++) + { + if (strcmp(map[i].str, cmd) == 0) + return true; + } + + RARCH_ERR("Command \"%s\" is not recognized by RetroArch.\n", cmd); + RARCH_ERR("\tValid commands:\n"); + for (unsigned i = 0; i < sizeof(map) / sizeof(map[0]); i++) + RARCH_ERR("\t\t%s\n", map[i].str); + + return false; +} + +bool network_cmd_send(const char *cmd_) +{ + if (!netplay_init_network()) + return NULL; + + char *command = strdup(cmd_); + if (!command) + return false; + + bool old_verbose = g_extern.verbose; + g_extern.verbose = true; + + const char *cmd = NULL; + const char *host = NULL; + const char *port_ = NULL; + uint16_t port = DEFAULT_NETWORK_CMD_PORT; + + cmd = strtok(command, ":"); + if (cmd) + host = strtok(NULL, ":"); + if (host) + port_ = strtok(NULL, ":"); + + if (!host) + { +#ifdef _WIN32 + host = "127.0.0.1"; +#else + host = "localhost"; +#endif + } + + if (port_) + port = strtoul(port_, NULL, 0); + + RARCH_LOG("Sending command: \"%s\" to %s:%hu\n", cmd, host, (unsigned short)port); + + bool ret = verify_command(cmd) && send_udp_packet(host, port, cmd); + free(command); + + g_extern.verbose = old_verbose; + return ret; +} + diff --git a/network_cmd.h b/network_cmd.h index 696f5c5a2d..267bcdeaf6 100644 --- a/network_cmd.h +++ b/network_cmd.h @@ -28,5 +28,7 @@ void network_cmd_pre_frame(network_cmd_t *handle); void network_cmd_set(network_cmd_t *handle, unsigned id); bool network_cmd_get(network_cmd_t *handle, unsigned id); +bool network_cmd_send(const char *cmd); + #endif diff --git a/ps3/main.c b/ps3/main.c index 9a5fb096d6..1ae53780b1 100644 --- a/ps3/main.c +++ b/ps3/main.c @@ -40,7 +40,6 @@ #include #include "ps3_input.h" -#include "ps3_video_psgl.h" #include "../console/console_ext.h" #include "../conf/config_file.h" diff --git a/ps3/menu.c b/ps3/menu.c index c1704387f3..27b513d51f 100644 --- a/ps3/menu.c +++ b/ps3/menu.c @@ -28,7 +28,6 @@ #include "../console/console_ext.h" -#include "ps3_video_psgl.h" #include "../gfx/gl_common.h" #include "shared.h" @@ -148,6 +147,9 @@ static menu menu_controlssettings = { items_generalsettings /* items */ }; +//forward decls +extern const char *ps3_get_resolution_label(unsigned resolution); + static void display_menubar(uint32_t menu_enum) { gl_t *gl = driver.video_data; @@ -1169,12 +1171,12 @@ static void producesettingentry(menu * menu_obj, uint64_t switchvalue) case SETTING_CHANGE_RESOLUTION: if(CTRL_RIGHT(state) || CTRL_LSTICK_RIGHT(state) ) { - ps3_next_resolution(); + rarch_settings_change(S_RESOLUTION_NEXT); set_delay = DELAY_SMALL; } if(CTRL_LEFT(state) || CTRL_LSTICK_LEFT(state) ) { - ps3_previous_resolution(); + rarch_settings_change(S_RESOLUTION_PREVIOUS); set_delay = DELAY_SMALL; } if(CTRL_CROSS(state)) diff --git a/ps3/ps3_input.c b/ps3/ps3_input.c index 546d8c7312..f4f4559ee6 100644 --- a/ps3/ps3_input.c +++ b/ps3/ps3_input.c @@ -24,9 +24,8 @@ #include #include "ps3_input.h" -#include "ps3_video_psgl.h" #include "../driver.h" -#include "../console/console_ext_input.h" +#include "../console/console_ext.h" #include "../libretro.h" #include "../general.h" #include "shared.h" diff --git a/ps3/ps3_video_psgl.h b/ps3/ps3_video_psgl.h deleted file mode 100644 index f0dceb6187..0000000000 --- a/ps3/ps3_video_psgl.h +++ /dev/null @@ -1,48 +0,0 @@ -/* RetroArch - A frontend for libretro. - * Copyright (C) 2010-2012 - Hans-Kristian Arntzen - * Copyright (C) 2011-2012 - Daniel De Matteis - * - * RetroArch 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 Found- - * ation, either version 3 of the License, or (at your option) any later version. - * - * RetroArch 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 RetroArch. - * If not, see . - */ - -#ifndef _PS3_VIDEO_PSGL_H -#define _PS3_VIDEO_PSGL_H - -#include "../gfx/gl_common.h" -#include "../gfx/gfx_common.h" -#include "../gfx/image.h" -#include "../console/console_ext.h" - -enum -{ - FBO_DEINIT = 0, - FBO_INIT, - FBO_REINIT -}; - -#define MIN_SCALING_FACTOR (1.0f) -#define MAX_SCALING_FACTOR (4.0f) - -const char * ps3_get_resolution_label(uint32_t resolution); -void ps3_previous_resolution (void); -void ps3_next_resolution (void); - -void gl_deinit_fbo(gl_t * gl); -void gl_init_fbo(gl_t * gl, unsigned width, unsigned height); - -bool gl_cg_reinit(const char *path); -bool gl_cg_save_cgp(const char *path, const struct gl_cg_cgp_info *info); -bool gl_cg_load_shader(unsigned index, const char *path); - -unsigned gl_cg_get_lut_info(struct gl_cg_lut_info *info, unsigned elems); - -#endif diff --git a/qb/config.libs.sh b/qb/config.libs.sh index a26cde2318..c77ac8cda6 100644 --- a/qb/config.libs.sh +++ b/qb/config.libs.sh @@ -25,7 +25,7 @@ else HAVE_RPI=no fi -if [ $OS = BSD ]; then +if [ "$OS" = BSD ]; then DYLIB=-lc else DYLIB=-ldl @@ -38,7 +38,7 @@ else HAVE_DYNAMIC=no fi -if [ $HAVE_DYNAMIC != yes ]; then +if [ "$HAVE_DYNAMIC" != yes ]; then check_lib_cxx RETRO $LIBRETRO retro_init $DYLIB check_critical RETRO "Cannot find libretro." add_define_make libretro $LIBRETRO @@ -48,10 +48,10 @@ check_lib THREADS -lpthread pthread_create check_lib DYLIB $DYLIB dlopen check_lib NETPLAY -lc socket -if [ $HAVE_NETPLAY = yes ]; then +if [ "$HAVE_NETPLAY" = yes ]; then HAVE_GETADDRINFO=auto check_lib GETADDRINFO -lc getaddrinfo - if [ $HAVE_GETADDRINFO = yes ]; then + if [ "$HAVE_GETADDRINFO" = yes ]; then HAVE_SOCKET_LEGACY=no else HAVE_SOCKET_LEGACY=yes @@ -61,10 +61,9 @@ else HAVE_NETWORK_CMD=no fi - check_lib GETOPT_LONG -lc getopt_long -if [ $HAVE_DYLIB = no ] && [ $HAVE_DYNAMIC = yes ]; then +if [ "$HAVE_DYLIB" = no ] && [ "$HAVE_DYNAMIC" = yes ]; then echo "Dynamic loading of libsnes is enabled, but your platform does not appear to have dlopen(), use --disable-dynamic or --with-libsnes=\"-lsnes\"". exit 1 fi @@ -74,13 +73,13 @@ check_header OSS sys/soundcard.h check_header OSS_BSD soundcard.h check_lib OSS_LIB -lossaudio -if [ $OS = Darwin ]; then +if [ "$OS" = Darwin ]; then check_lib AL "-framework OpenAL" alcOpenDevice else check_lib AL -lopenal alcOpenDevice fi -if [ $OS = Darwin ]; then +if [ "$OS" = Darwin ]; then check_lib FBO "-framework OpenGL" glFramebufferTexture2D else check_lib FBO -lGL glFramebufferTexture2D @@ -97,7 +96,7 @@ check_pkgconf SDL sdl 1.2.10 check_critical SDL "Cannot find SDL library." # On some distros, -lCg doesn't link against -lstdc++ it seems ... -if [ $HAVE_OPENGL != no ]; then +if [ "$HAVE_OPENGL" != no ]; then check_lib_cxx CG -lCg cgCreateContext else echo "Ignoring Cg. OpenGL is not enabled." @@ -107,17 +106,17 @@ fi check_pkgconf XML libxml-2.0 check_pkgconf SDL_IMAGE SDL_image -if [ $HAVE_THREADS != no ]; then - if [ $HAVE_FFMPEG != no ]; then +if [ "$HAVE_THREADS" != no ]; then + if [ "$HAVE_FFMPEG" != no ]; then check_pkgconf AVCODEC libavcodec check_pkgconf AVFORMAT libavformat check_pkgconf AVUTIL libavutil check_pkgconf SWSCALE libswscale - ( [ $HAVE_FFMPEG = auto ] && ( [ $HAVE_AVCODEC = no ] || [ $HAVE_AVFORMAT = no ] || [ $HAVE_AVUTIL = no ] || [ $HAVE_SWSCALE = no ] ) && HAVE_FFMPEG=no ) || HAVE_FFMPEG=yes + ( [ "$HAVE_FFMPEG" = auto ] && ( [ "$HAVE_AVCODEC" = no ] || [ "$HAVE_AVFORMAT" = no ] || [ "$HAVE_AVUTIL" = no ] || [ "$HAVE_SWSCALE" = no ] ) && HAVE_FFMPEG=no ) || HAVE_FFMPEG=yes fi - if [ $HAVE_FFMPEG = yes ]; then + if [ "$HAVE_FFMPEG" = yes ]; then check_lib FFMPEG_ALLOC_CONTEXT3 "$AVCODEC_LIBS" avcodec_alloc_context3 check_lib FFMPEG_AVCODEC_OPEN2 "$AVCODEC_LIBS" avcodec_open2 check_lib FFMPEG_AVCODEC_ENCODE_AUDIO2 "$AVCODEC_LIBS" avcodec_encode_audio2 @@ -127,7 +126,7 @@ if [ $HAVE_THREADS != no ]; then check_lib FFMPEG_AVCODEC_ENCODE_VIDEO2 "$AVCODEC_LIBS" avcodec_encode_video2 fi - if [ $HAVE_FFMPEG = no ] && [ $HAVE_X264RGB = yes ]; then + if [ "$HAVE_FFMPEG" = no ] && [ "$HAVE_X264RGB" = yes ]; then echo "x264 RGB recording is enabled, but FFmpeg is not. --enable-x264rgb will not have any effect." fi else @@ -140,7 +139,7 @@ check_lib DYNAMIC $DYLIB dlopen check_pkgconf FREETYPE freetype2 check_pkgconf X11 x11 check_pkgconf XEXT xext -if [ $HAVE_X11 = yes ] && [ $HAVE_XEXT = yes ]; then +if [ "$HAVE_X11" = yes ] && [ "$HAVE_XEXT" = yes ]; then check_pkgconf XVIDEO xv else echo "X11 or Xext not present. Skipping XVideo." diff --git a/qb/config.params.sh b/qb/config.params.sh index df9fb84079..3a2f311363 100644 --- a/qb/config.params.sh +++ b/qb/config.params.sh @@ -1,35 +1,26 @@ -. qb/qb.params.sh - -PACKAGE_NAME=ssnes -PACKAGE_VERSION=0.9.6-rc1 - -# Adds a command line opt to ./configure --help -# $1: Variable (HAVE_ALSA, HAVE_OSS, etc) -# $2: Comment -# $3: Default arg. auto implies that HAVE_ALSA will be set according to library checks later on. -add_command_line_enable DYNAMIC "Disable dynamic loading of libsnes library" yes -add_command_line_string LIBRETRO "libretro library used" "" -add_command_line_enable THREADS "Threading support" auto -add_command_line_enable FFMPEG "Enable FFmpeg recording support" auto -add_command_line_enable X264RGB "Enable lossless X264 RGB recording" no -add_command_line_enable DYLIB "Enable dynamic loading support" auto -add_command_line_enable NETPLAY "Enable netplay support" auto -add_command_line_enable CONFIGFILE "Disable support for config file" yes -add_command_line_enable OPENGL "Disable OpenGL support" yes -add_command_line_enable CG "Enable Cg shader support" auto -add_command_line_enable XML "Enable bSNES-style XML shader support" auto -add_command_line_enable FBO "Enable render-to-texture (FBO) support" auto -add_command_line_enable ALSA "Enable ALSA support" auto -add_command_line_enable OSS "Enable OSS support" auto -add_command_line_enable RSOUND "Enable RSound support" auto -add_command_line_enable ROAR "Enable RoarAudio support" auto -add_command_line_enable AL "Enable OpenAL support" auto -add_command_line_enable JACK "Enable JACK support" auto -add_command_line_enable COREAUDIO "Enable CoreAudio support" auto -add_command_line_enable PULSE "Enable PulseAudio support" auto -add_command_line_enable FREETYPE "Enable FreeType support" auto -add_command_line_enable XVIDEO "Enable XVideo support" auto -add_command_line_enable SDL_IMAGE "Enable SDL_image support" auto -add_command_line_enable PYTHON "Enable Python 3 support for shaders" auto -add_command_line_enable SINC "Disable SINC resampler" yes -add_command_line_enable BSV_MOVIE "Disable BSV movie support" yes +HAVE_DYNAMIC=yes # Disable dynamic loading of libsnes library +HAVE_LIBRETRO= # libretro library used +HAVE_THREADS=auto # Threading support +HAVE_FFMPEG=auto # Enable FFmpeg recording support +HAVE_X264RGB=no # Enable lossless X264 RGB recording +HAVE_DYLIB=auto # Enable dynamic loading support +HAVE_NETPLAY=auto # Enable netplay support +HAVE_CONFIGFILE=yes # Disable support for config file +HAVE_OPENGL=yes # Disable OpenGL support +HAVE_CG=auto # Enable Cg shader support +HAVE_XML=auto # Enable bSNES-style XML shader support +HAVE_FBO=auto # Enable render-to-texture (FBO) support +HAVE_ALSA=auto # Enable ALSA support +HAVE_OSS=auto # Enable OSS support +HAVE_RSOUND=auto # Enable RSound support +HAVE_ROAR=auto # Enable RoarAudio support +HAVE_AL=auto # Enable OpenAL support +HAVE_JACK=auto # Enable JACK support +HAVE_COREAUDIO=auto # Enable CoreAudio support +HAVE_PULSE=auto # Enable PulseAudio support +HAVE_FREETYPE=auto # Enable FreeType support +HAVE_XVIDEO=auto # Enable XVideo support +HAVE_SDL_IMAGE=auto # Enable SDL_image support +HAVE_PYTHON=auto # Enable Python 3 support for shaders +HAVE_SINC=yes # Disable SINC resampler +HAVE_BSV_MOVIE=yes # Disable BSV movie support diff --git a/qb/qb.comp.sh b/qb/qb.comp.sh index cd7e273b37..3ff8f9c469 100644 --- a/qb/qb.comp.sh +++ b/qb/qb.comp.sh @@ -41,7 +41,7 @@ if [ "$USE_LANG_C" = yes ]; then rm -rf $TEMP_C $TEMP_EXE - [ $answer = no ] && echo "Can't find suitable C compiler. Exiting ..." && exit 1 + [ "$answer" = no ] && echo "Can't find suitable C compiler. Exiting ..." && exit 1 fi # Checking for working C++ compiler @@ -64,6 +64,6 @@ if [ "$USE_LANG_CXX" = "yes" ]; then rm -rf $TEMP_CXX $TEMP_EXE - [ $answer = no ] && echo "Can't find suitable C++ compiler. Exiting ..." && exit 1 + [ "$answer" = no ] && echo "Can't find suitable C++ compiler. Exiting ..." && exit 1 fi diff --git a/qb/qb.params.sh b/qb/qb.params.sh index 0e5988e5f2..c5669a0f28 100644 --- a/qb/qb.params.sh +++ b/qb/qb.params.sh @@ -1,153 +1,79 @@ -COMMAND_LINE_OPTS_ENABLE="" - -add_command_line_enable() -{ - COMMAND_LINE_OPTS_ENABLE="$COMMAND_LINE_OPTS_ENABLE:\"$1\" \"$2\" \"$3\":" - eval HAVE_$1=$3 -} - -add_command_line_string() -{ - COMMAND_LINE_OPTS_STRINGS="$COMMAND_LINE_OPTS_STRINGS:\"$1\" \"$2\" \"$3\":" - eval $1=$3 -} - ## lvl. 43 regex dragon awaits thee. print_help() -{ - echo "====================" - echo " Quickbuild script" - echo "====================" - echo "Package: $PACKAGE_NAME" - echo "Version: $PACKAGE_VERSION" - echo "" - echo "General environment variables:" - echo "CC: C compiler" - echo "CFLAGS: C compiler flags" - echo "CXX: C++ compiler" - echo "CXXFLAGS: C++ compiler flags" - echo "LDFLAGS: Linker flags" - echo "" - echo "General options:" - echo "--prefix=\$path: Install path prefix" - echo "--help: Show this help" - echo "" - echo "Custom options:" +{ cat << EOF +==================== + Quickbuild script +==================== +Package: $PACKAGE_NAME +Version: $PACKAGE_VERSION - tmpopts="$COMMAND_LINE_OPTS_ENABLE" - while [ ! -z "$tmpopts" ] - do - subopts="`echo $tmpopts | sed 's|^:"\([^"]*\)"."\([^"]*\)"."\([^"]*\)":.*$|"\1":"\2":"\3"|'`" - tmpopts="`echo $tmpopts | sed 's|^\W*$||'`" - tmpopts="`echo $tmpopts | sed 's|^:"[^"]*"."[^"]*"."[^"]*":||'`" - print_sub_opt "$subopts" - done +General environment variables: +CC: C compiler +CFLAGS: C compiler flags +CXX: C++ compiler +CXXFLAGS: C++ compiler flags +LDFLAGS: Linker flags - echo "" +General options: +--prefix=\$path: Install path prefix +--help: Show this help - tmpopts="$COMMAND_LINE_OPTS_STRINGS" - while [ ! -z "$tmpopts" ] - do - subopts="`echo $tmpopts | sed 's|^:"\([^"]*\)"."\([^"]*\)"."\([^"]*\)":.*$|"\1":"\2":"\3"|'`" - tmpopts="`echo $tmpopts | sed 's|^\W*$||'`" - tmpopts="`echo $tmpopts | sed 's|^:"[^"]*"."[^"]*"."[^"]*":||'`" - print_sub_str_opt "$subopts" - done +Custom options: +EOF + while IFS='=#' read VAR VAL COMMENT; do + VAR=$(echo "${VAR##HAVE_}" | tr '[A-Z]' '[a-z]') + case "$VAL" in + 'yes'*) echo "--disable-$VAR: $COMMENT";; + 'no'*) echo "--enable-$VAR: $COMMENT";; + 'auto'*) echo "--enable-$VAR: $COMMENT"; echo "--disable-$VAR";; + *) echo "--with-$VAR: $COMMENT";; + esac + done < 'qb/config.params.sh' } -print_sub_opt() +opt_exists() # $opt is returned if exists in OPTS { - arg1="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\1|'`" - arg2="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\2|'`" - arg3="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\3|'`" - - lowertext="`echo $arg1 | tr '[A-Z]' '[a-z]'`" - - if [ "$arg3" = "auto" ]; then - echo "--enable-$lowertext: $arg2" - echo "--disable-$lowertext" - elif [ "$arg3" = "yes" ]; then - echo "--disable-$lowertext: $arg2" - elif [ "$arg3" = "no" ]; then - echo "--enable-$lowertext: $arg2" - fi + opt=$(echo "$1" | tr '[a-z]' '[A-Z]') + for OPT in $OPTS; do [ "$opt" = "$OPT" ] && return; done + print_help; exit 1 } -print_sub_str_opt() +parse_input() # Parse stuff :V { - arg1="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\1|'`" - arg2="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\2|'`" - arg3="`echo $1 | sed 's|^"\([^"]*\)":"\([^"]*\)":"\([^"]*\)"$|\3|'`" + #OPTS contains all available options in config.params.sh + while IFS='=' read VAR dummy; do OPTS="$OPTS ${VAR##HAVE_}"; done < 'qb/config.params.sh' + + while [ "$1" ]; do + case "$1" in + --prefix=*) PREFIX=${1##--prefix=};; - lowertext="`echo $arg1 | tr '[A-Z]' '[a-z]'`" + --enable-*) + opt_exists "${1##--enable-}" "$OPTS" + eval "HAVE_$opt=yes" + ;; - echo "--with-$lowertext: $arg2" + --disable-*) + opt_exists "${1##--disable-}" "$OPTS" + eval "HAVE_$opt=no" + ;; + + --with-*) + arg=${1##--with-} + val=${arg##*=} + opt_exists "${arg%%=*}" "$OPTS" + eval "$opt=$val" + ;; + + -h|--help) print_help; exit 0;; + + *) print_help; exit 1;; + esac + shift + done } -parse_input() -{ - ### Parse stuff :V - - while [ ! -z "$1" ] - do - - case "$1" in - - --prefix=*) - prefix="`echo $1 | sed -e 's|^--prefix=||' -e 's|^\(.*\)/$|\1|'`" - - if [ "$prefix" != "$1" ]; then - PREFIX="$prefix" - fi - ;; - - --enable-*) - tmp="$1" - enable="${tmp#--enable-}" - if [ -z "`echo $COMMAND_LINE_OPTS_ENABLE | grep -i -- $enable`" ]; then - print_help - exit 1 - fi - eval HAVE_`echo $enable | tr '[a-z]' '[A-Z]'`=yes - ;; - - --disable-*) - tmp="$1" - disable="${tmp#--disable-}" - if [ -z "`echo $COMMAND_LINE_OPTS_ENABLE | grep -i -- $disable`" ]; then - print_help - exit 1 - fi - eval HAVE_`echo $disable | tr '[a-z]' '[A-Z]'`=no - ;; - - --with-*) - tmp="$1" - arg="${tmp#--with-*=}" - tmp="${tmp#--with-}" - with="${tmp%%=*}" - if [ -z "`echo $COMMAND_LINE_OPTS_STRINGS | grep -i -- $with`" ]; then - print_help - exit 1 - fi - eval "`echo $with | tr '[a-z]' '[A-Z]'`=\"$arg\"" - ;; - - - -h|--help) - print_help - exit 0 - ;; - *) - print_help - exit 1 - ;; - - esac - - shift - - done -} +. qb/config.params.sh +parse_input "$@" + diff --git a/retroarch.c b/retroarch.c index a3577c1ce4..acc9ff50a1 100644 --- a/retroarch.c +++ b/retroarch.c @@ -543,6 +543,10 @@ static void print_help(void) puts("\t\tHowever, the client will not be able to play. Multiple clients can connect to the host."); puts("\t--nick: Picks a nickname for use with netplay. Not mandatory."); #endif +#ifdef HAVE_NETWORK_CMD + puts("\t--command: Sends a command over UDP to an already running RetroArch process."); + puts("\t\tAvailable commands are listed if command is invalid."); +#endif #ifdef HAVE_FFMPEG puts("\t-r/--record: Path to record video file.\n\t\tUsing .mkv extension is recommended."); @@ -699,6 +703,9 @@ static void parse_input(int argc, char *argv[]) { "port", 1, &val, 'p' }, { "spectate", 0, &val, 'S' }, { "nick", 1, &val, 'N' }, +#endif +#ifdef HAVE_NETWORK_CMD + { "command", 1, &val, 'c' }, #endif { "ups", 1, NULL, 'U' }, { "bps", 1, &val, 'B' }, @@ -896,8 +903,6 @@ static void parse_input(int argc, char *argv[]) case 'F': g_extern.netplay_sync_frames = strtol(optarg, NULL, 0); - if (g_extern.netplay_sync_frames > 16) - g_extern.netplay_sync_frames = 16; break; #endif @@ -933,6 +938,15 @@ static void parse_input(int argc, char *argv[]) break; #endif +#ifdef HAVE_NETWORK_CMD + case 'c': + if (network_cmd_send(optarg)) + exit(0); + else + rarch_fail(1, "network_cmd_send()"); + break; +#endif + case 'B': strlcpy(g_extern.bps_name, optarg, sizeof(g_extern.bps_name)); g_extern.bps_pref = true; @@ -1624,14 +1638,28 @@ static void load_auto_state(void) if (path_file_exists(savestate_name_auto)) { RARCH_LOG("Found auto savestate in: %s\n", savestate_name_auto); - load_state(savestate_name_auto); + bool ret = load_state(savestate_name_auto); char msg[PATH_MAX]; - snprintf(msg, sizeof(msg), "Auto-loaded savestate from: \"%s\"", savestate_name_auto); + snprintf(msg, sizeof(msg), "Auto-loading savestate from \"%s\" %s.", savestate_name_auto, ret ? "succeeded" : "failed"); msg_queue_push(g_extern.msg_queue, msg, 1, 180); + RARCH_LOG("%s\n", msg); } } +static void save_auto_state(void) +{ + if (!g_settings.savestate_auto_save) + return; + + char savestate_name_auto[PATH_MAX]; + fill_pathname_noext(savestate_name_auto, g_extern.savestate_name, + ".auto", sizeof(savestate_name_auto)); + + bool ret = save_state(savestate_name_auto); + RARCH_LOG("Auto save state to \"%s\" %s.\n", savestate_name_auto, ret ? "succeeded" : "failed"); +} + void rarch_load_state(void) { char load_path[PATH_MAX]; @@ -2548,6 +2576,8 @@ void rarch_main_deinit(void) deinit_movie(); #endif + save_auto_state(); + pretro_unload_game(); pretro_deinit(); uninit_drivers(); diff --git a/retroarch.cfg b/retroarch.cfg index 9246d93788..3cf0b40a3b 100644 --- a/retroarch.cfg +++ b/retroarch.cfg @@ -8,6 +8,11 @@ # This will be overridden by explicit command line options. # savestate_directory = +# Automatically saves a savestate at the end of RetroArch's lifetime. +# The path is $SRAM_PATH.auto. +# RetroArch will automatically load any savestate with this path on startup. +# savestate_auto_save = false + # Load libretro from a dynamic location for dynamically built RetroArch. # This option is mandatory. # libretro_path = "/path/to/libretro.so" diff --git a/settings.c b/settings.c index b80e68a4c9..f2ecd40be0 100644 --- a/settings.c +++ b/settings.c @@ -193,6 +193,7 @@ void config_set_defaults(void) g_settings.block_sram_overwrite = block_sram_overwrite; g_settings.savestate_auto_index = savestate_auto_index; + g_settings.savestate_auto_save = savestate_auto_save; g_settings.network_cmd_enable = network_cmd_enable; g_settings.network_cmd_port = network_cmd_port; @@ -462,6 +463,7 @@ bool config_load_file(const char *path) CONFIG_GET_BOOL(block_sram_overwrite, "block_sram_overwrite"); CONFIG_GET_BOOL(savestate_auto_index, "savestate_auto_index"); + CONFIG_GET_BOOL(savestate_auto_save, "savestate_auto_save"); CONFIG_GET_BOOL(network_cmd_enable, "network_cmd_enable"); CONFIG_GET_INT(network_cmd_port, "network_cmd_port"); diff --git a/tools/retroarch-joyconfig.c b/tools/retroarch-joyconfig.c index b13b5c62d0..417e0d5f73 100644 --- a/tools/retroarch-joyconfig.c +++ b/tools/retroarch-joyconfig.c @@ -71,6 +71,10 @@ static struct bind binds[] = { BIND("Y button (left)", y) BIND("L button (left shoulder)", l) BIND("R button (right shoulder)", r) + BIND("L2 button (left shoulder #2)", l2) + BIND("R2 button (right shoulder #2)", r2) + BIND("L3 button (left analog button)", l3) + BIND("R3 button (right analog button)", r3) BIND("Start button", start) BIND("Select button", select) BIND("Left D-pad", left) diff --git a/wii/pkg/meta.xml b/wii/pkg/meta.xml index a8cb7e9b4d..6eb3513ed2 100644 --- a/wii/pkg/meta.xml +++ b/wii/pkg/meta.xml @@ -2,7 +2,7 @@ RetroArch Wii Themaister, Squarepusher2 - 0.9.6-rc1 + 0.9.6 2012 Multi-system emulator A port of RetroArch to the Wii.