Merge remote-tracking branch 'libretro/master'

This commit is contained in:
IlDucci 2015-09-14 12:25:56 +02:00
commit 384a5d2b97
478 changed files with 17478 additions and 13409 deletions

73
AUTHORS
View File

@ -1,73 +0,0 @@
Hans-Kristian Arntzen - <maister@archlinux.us>
- Main code
- Initial Gamecube/Wii libogc port
Daniel De Matteis - <libretro@gmail.com>
- Maintainer
- Main code
Devin J. Pohly - <djpohly@djpohly.com>
- Joypad axis support
Chris Moeller - <kode54@gmail.com>
- CoreAudio audio driver
Tobias Jakobi - <TBA>
- OMAP graphics driver
Jason Fetters - <TBA>
- Phoenix Java frontend
- Android port patches
- iOS port
CatalystG - <catalystgdev@gmail.com>
- Blackberry 10/Playbook input driver
- Blackberry 10/Playbook patches
David Reichelt - <freakdave@hotmail.com>
- XBox 1 port
tukuyomi - <tukuyomi@free.fr>
- Cleanups in quickbuild
Michael Lelli - <toadking@toadking.com>
- Gamecube/Wii libogc port
- Raspberry Pi video driver
- Linux Raw keyboard input driver
- Android port patches
Ali Bouhlel - <aliaspider@gmail.com>
- PSP port
- Convoluted Cosine resampler
Darren Alton -
- OpenPandora port
Fabian Knopf -
- WGL multi-monitor support
- D3D9 overlay, multi-monitor and menu support
Gražvydas Ignotas -
- ARM Linux patches
Saggi Mizrahi -
- RetroLaunch utility
Alfred Agrell - <floating@muncher.se>
- Rewritten savestate manager
Jean-André Santoni - <jean.andre.santoni@gmail.com>
- Lakka menu driver
Morgane Alonso -
- Lakka menu driver (graphic design)
Timo Strunk - <Timo.Strunk@gmail.com>
- 7zip support
Higor Euripedes - <TBA>
- SDL2 drivers
Jay McCarthy - <jay.mccarthy@gmail.com>
- CoreText font driver
- (Apple) CFRunLoop improvements

View File

@ -1,4 +1,5 @@
HAVE_FILE_LOGGER=1
MISSING_DECLS =0
include config.mk
@ -23,8 +24,16 @@ endif
include Makefile.common
ifeq ($(shell $(CC) -v 2>&1 | grep -c "clang"),1)
DEFINES += -Wno-invalid-source-encoding
endif
HEADERS = $(wildcard */*/*.h) $(wildcard */*.h) $(wildcard *.h)
ifeq ($(MISSING_DECLS), 1)
DEFINES += -Werror=missing-declarations
endif
ifeq ($(HAVE_DYLIB), 1)
LIBS += $(DYLIB_LIB)
endif
@ -46,7 +55,7 @@ else
endif
CFLAGS += -Wall $(OPTIMIZE_FLAG) $(INCLUDE_DIRS) $(DEBUG_FLAG) -I.
CXXFLAGS := $(CFLAGS) -std=c++0x -D__STDC_CONSTANT_MACROS
CXXFLAGS := $(CFLAGS) -std=c++98 -D__STDC_CONSTANT_MACROS
OBJCFLAGS := $(CFLAGS) -D__STDC_CONSTANT_MACROS
ifeq ($(CXX_BUILD), 1)
@ -158,16 +167,17 @@ install: $(TARGET)
rm -f $(OBJDIR)/git_version.o
mkdir -p $(DESTDIR)$(PREFIX)/bin 2>/dev/null || /bin/true
mkdir -p $(DESTDIR)$(GLOBAL_CONFIG_DIR) 2>/dev/null || /bin/true
mkdir -p $(DESTDIR)$(PREFIX)/share/man/man1 2>/dev/null || /bin/true
mkdir -p $(DESTDIR)$(PREFIX)/share/applications 2>/dev/null || /bin/true
mkdir -p $(DESTDIR)$(MAN_DIR) 2>/dev/null || /bin/true
mkdir -p $(DESTDIR)$(PREFIX)/share/pixmaps 2>/dev/null || /bin/true
install -m755 $(TARGET) $(DESTDIR)$(PREFIX)/bin
install -m755 tools/cg2glsl.py $(DESTDIR)$(PREFIX)/bin/retroarch-cg2glsl
install -m755 $(JTARGET) $(DESTDIR)$(PREFIX)/bin
install -m644 retroarch.cfg $(DESTDIR)$(GLOBAL_CONFIG_DIR)/retroarch.cfg
install -m644 retroarch.desktop $(DESTDIR)$(PREFIX)/share/applications
install -m644 docs/retroarch.1 $(DESTDIR)$(MAN_DIR)
install -m644 docs/retroarch-cg2glsl.1 $(DESTDIR)$(MAN_DIR)
install -m644 docs/retroarch-joyconfig.1 $(DESTDIR)$(MAN_DIR)
install -m644 media/retroarch.png $(DESTDIR)$(PREFIX)/share/pixmaps
install -m644 media/retroarch.svg $(DESTDIR)$(PREFIX)/share/pixmaps
uninstall:
@ -175,10 +185,10 @@ uninstall:
rm -f $(DESTDIR)$(PREFIX)/bin/retroarch-joyconfig
rm -f $(DESTDIR)$(PREFIX)/bin/retroarch-cg2glsl
rm -f $(DESTDIR)$(GLOBAL_CONFIG_DIR)/retroarch.cfg
rm -f $(DESTDIR)$(PREFIX)/share/man/man1/retroarch.1
rm -f $(DESTDIR)$(PREFIX)/share/man/man1/retroarch-cg2glsl.1
rm -f $(DESTDIR)$(PREFIX)/share/man/man1/retroarch-joyconfig.1
rm -f $(DESTDIR)$(PREFIX)/share/pixmaps/retroarch.png
rm -f $(DESTDIR)$(PREFIX)/share/applications/retroarch.desktop
rm -f $(DESTDIR)$(MAN_DIR)/retroarch.1
rm -f $(DESTDIR)$(MAN_DIR)/retroarch-cg2glsl.1
rm -f $(DESTDIR)$(MAN_DIR)/retroarch-joyconfig.1
rm -f $(DESTDIR)$(PREFIX)/share/pixmaps/retroarch.svg
clean:

View File

@ -130,8 +130,10 @@ OBJ += frontend/frontend.o \
content.o \
libretro-common/file/file_list.o \
libretro-common/file/dir_list.o \
libretro-common/file/retro_dirent.o \
libretro-common/string/string_list.o \
libretro-common/string/stdstring.o \
libretro-common/memmap/memalign.o \
dir_list_special.o \
file_ops.o \
libretro-common/file/nbio/nbio_stdio.o \
@ -209,19 +211,21 @@ OBJ += frontend/frontend.o \
OBJ += gfx/image/image.o
ifneq ($(C89_BUILD), 1)
# stb_image is not a C89-compliant API.
ifneq ($(C90_BUILD), 1)
# stb_image is not a C89/C90-compliant API.
ifeq ($(HAVE_IMAGEVIEWER), 1)
DEFINES += -DHAVE_IMAGEVIEWER
OBJ += cores/image_core.o
endif
endif
endif
# Qt
ifeq ($(HAVE_QT), 1)
OBJ += ui/drivers/ui_qt.o
# TODO/FIXME - figure out which libraries we need to link against
LIBS += -lQt5Quick -lQt5Widgets -lQt5Gui -lQt5Qml -lQt5Network -lQt5Core -lglu32 -lopengl32 -L./ui/drivers/qt/release -lwrapper
LIBS += -lQt5Quick -lQt5Widgets -lQt5Gui -lQt5Qml -lQt5Network -lQt5Core -lglu32 -lopengl32 -L./ui/drivers/qt/wrapper/build/release -lwrapper
endif
# LibretroDB
@ -243,16 +247,14 @@ ifeq ($(HAVE_STDIN_CMD), 1)
endif
ifneq ($(C89_BUILD), 1)
# Python 3.x bindings are not C89-compliant.
ifneq ($(C90_BUILD), 1)
# Python 3.x bindings are not C89/C90-compliant.
ifeq ($(HAVE_PYTHON), 1)
DEFINES += $(PYTHON_CFLAGS) -Wno-unused-parameter
LIBS += $(PYTHON_LIBS)
OBJ += gfx/video_state_python.o
endif
endif
ifeq ($(OSX), 1)
DEFINES += -Wno-invalid-source-encoding
endif
ifeq ($(HAVE_EMSCRIPTEN), 1)
@ -314,13 +316,15 @@ ifeq ($(HAVE_JACK),1)
endif
ifneq ($(C89_BUILD), 1)
# PulseAudio is not a C89-compliant API.
ifneq ($(C90_BUILD), 1)
# PulseAudio is not a C89/C90-compliant API.
ifeq ($(HAVE_PULSE), 1)
OBJ += audio/drivers/pulse.o
LIBS += $(PULSE_LIBS)
DEFINES += $(PULSE_CFLAGS)
endif
endif
endif
ifeq ($(HAVE_OSS_LIB), 1)
LIBS += -lossaudio
@ -392,6 +396,11 @@ endif
endif
ifeq ($(HAVE_MENU_COMMON), 1)
ifeq ($(PSEUDOLOC), 1)
PSEUDO_NS := pseudo
else
PSEUDO_NS :=
endif
OBJ += menu/menu.o \
menu/menu_hash.o \
menu/intl/menu_hash_de.o \
@ -402,7 +411,7 @@ ifeq ($(HAVE_MENU_COMMON), 1)
menu/intl/menu_hash_nl.o \
menu/intl/menu_hash_pl.o \
menu/intl/menu_hash_pt.o \
menu/intl/menu_hash_us.o \
menu/intl/menu_hash_us$(PSEUDO_NS).o \
menu/menu_input.o \
menu/menu_entry.o \
menu/menu_entries.o \
@ -422,7 +431,7 @@ ifeq ($(HAVE_MENU_COMMON), 1)
menu/cbs/menu_cbs_deferred_push.o \
menu/cbs/menu_cbs_scan.o \
menu/cbs/menu_cbs_get_value.o \
menu/cbs/menu_cbs_iterate.o \
menu/menu_iterate.o \
menu/cbs/menu_cbs_title.o \
menu/cbs/menu_cbs_up.o \
menu/cbs/menu_cbs_down.o \
@ -434,6 +443,10 @@ ifeq ($(HAVE_MENU_COMMON), 1)
menu/drivers/null.o
endif
ifeq ($(UTF8), 1)
DEFINES += -DHAVE_UTF8
endif
ifeq ($(HAVE_STB_FONT), 1)
OBJ += gfx/drivers_font_renderer/stb.o
endif
@ -462,13 +475,15 @@ endif
#Input
ifneq ($(C89_BUILD), 1)
# Wayland is not a C89-compliant API.
ifneq ($(C90_BUILD), 1)
# Wayland is not a C89/C90-compliant API.
ifeq ($(HAVE_WAYLAND), 1)
#OBJ += input/drivers/wayland.o
DEFINES += $(WAYLAND_CFLAGS)
LIBS += $(WAYLAND_LIBS)
endif
endif
endif
ifeq ($(HAVE_DINPUT), 1)
LIBS += -ldinput8 -ldxguid -lole32
@ -507,7 +522,8 @@ ifeq ($(HAVE_UDEV), 1)
endif
ifneq ($(C89_BUILD), 1)
# libusb is not a C89-compliant API.
ifneq ($(C90_BUILD), 1)
# libusb is not a C89/C90-compliant API.
ifeq ($(HAVE_LIBUSB), 1)
DEFINES += -DHAVE_LIBUSB
OBJ += input/drivers_hid/libusb_hid.o
@ -516,6 +532,7 @@ ifeq ($(HAVE_LIBUSB), 1)
HAVE_HID = 1
endif
endif
endif
ifeq ($(HAVE_IOHIDMANAGER), 1)
DEFINES += -DHAVE_IOHIDMANAGER
@ -596,12 +613,14 @@ ifeq ($(HAVE_GL_CONTEXT), 1)
endif
ifneq ($(C89_BUILD), 1)
# Wayland is not a C89-compliant API.
ifneq ($(C90_BUILD), 1)
# Wayland is not a C89/C90-compliant API.
ifeq ($(HAVE_WAYLAND), 1)
ifeq ($(HAVE_EGL), 1)
OBJ += gfx/drivers_context/wayland_ctx.o
endif
endif
endif
endif
ifeq ($(HAVE_GLES), 1)
@ -737,7 +756,6 @@ ifeq ($(HAVE_7ZIP),1)
7ZOBJ = deps/7zip/7zIn.o \
deps/7zip/7zAlloc.o \
deps/7zip/Bra86.o \
deps/7zip/CpuArch.o \
deps/7zip/7zFile.o \
deps/7zip/7zStream.o \
deps/7zip/7zBuf2.o \
@ -748,15 +766,13 @@ ifeq ($(HAVE_7ZIP),1)
deps/7zip/Bcj2.o \
deps/7zip/7zCrc.o \
deps/7zip/Lzma2Dec.o \
deps/7zip/7zBuf.o \
decompress/7zip_support.o
deps/7zip/7zBuf.o
OBJ += $(7ZOBJ)
endif
OBJ += libretro-common/formats/tga/tga_decode.o
ifeq ($(HAVE_ZLIB), 1)
ZLIB_OBJS = decompress/zip_support.o
OBJ += libretro-common/file/file_extract.o
OBJ += $(ZLIB_OBJS)
DEFINES += -DHAVE_ZLIB
@ -859,7 +875,8 @@ endif
# Record
ifneq ($(C89_BUILD), 1)
# ffmpeg and friends are not C89-compliant APIs.
ifneq ($(C90_BUILD), 1)
# ffmpeg and friends are not C89/C90-compliant APIs.
ifeq ($(HAVE_FFMPEG), 1)
OBJ += record/drivers/record_ffmpeg.o \
cores/ffmpeg_core.o
@ -868,6 +885,7 @@ ifeq ($(HAVE_FFMPEG), 1)
DEFINES += -DHAVE_FFMPEG -Iffmpeg
endif
endif
endif
ifeq ($(HAVE_COMPRESSION), 1)
DEFINES += -DHAVE_COMPRESSION

View File

@ -1,8 +1,222 @@
TARGET := retroarch_3ds
OBJS :=
OBJS += gfx/drivers/ctr_sprite.o griffin/griffin.o
#NO_SMDH = 1
LIBRETRO =
DEBUG = 0
GRIFFIN_BUILD = 1
WHOLE_ARCHIVE_LINK = 0
BUILD_3DSX = 1
BUILD_CIA = 1
APP_TITLE = Retroarch 3DS
APP_DESCRIPTION = Retroarch 3DS
APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RETROARCH-3DS
APP_UNIQUE_ID = 0xBAC00
APP_ICON = ctr/default.png
APP_BANNER = ctr/libretro_banner.png
APP_AUDIO = ctr/silent.wav
include ctr/Makefile.cores
OBJS :=
OBJS += gfx/drivers/ctr_sprite.o
ifeq ($(GRIFFIN_BUILD), 1)
OBJS += griffin/griffin.o
else
OBJS += libretro-common/file/file_extract.o
OBJS += performance.o
OBJS += libretro-common/compat/compat.o
OBJS += libretro-common/compat/compat_fnmatch.o
OBJS += libretro-common/memmap/memalign.o
OBJS += libretro-common/file/config_file.o
OBJS += libretro-common/file/config_file_userdata.o
OBJS += core_options.o
OBJS += cheats.o
OBJS += libretro-common/hash/rhash.o
OBJS += gfx/video_context_driver.o
OBJS += gfx/drivers_context/gfx_null_ctx.o
OBJS += gfx/image/image.o
OBJS += gfx/video_texture.o
OBJS += libretro-common/formats/tga/tga_decode.o
OBJS += libretro-common/formats/png/rpng_fbio.o
OBJS += libretro-common/formats/png/rpng_nbio.o
OBJS += libretro-common/formats/png/rpng_decode.o
OBJS += libretro-common/formats/png/rpng_encode.o
OBJS += gfx/drivers/ctr_gfx.o
OBJS += gfx/drivers/nullgfx.o
OBJS += gfx/font_renderer_driver.o
OBJS += gfx/drivers_font_renderer/bitmapfont.o
OBJS += gfx/font_driver.o
OBJS += input/input_autodetect.o
OBJS += input/input_joypad_driver.o
OBJS += input/input_joypad.o
OBJS += input/input_hid_driver.o
OBJS += input/input_common.o
OBJS += input/input_keymaps.o
OBJS += input/input_remapping.o
OBJS += input/input_sensor.o
OBJS += input/keyboard_line.o
OBJS += input/drivers/ctr_input.o
OBJS += input/drivers_joypad/ctr_joypad.o
OBJS += input/autoconf/builtin_ctr.o
OBJS += input/drivers/nullinput.o
OBJS += input/drivers_joypad/null_joypad.o
OBJS += input/drivers_joypad/hid_joypad.o
OBJS += input/drivers_hid/null_hid.o
OBJS += gfx/video_state_tracker.o
OBJS += libretro-common/queues/fifo_buffer.o
OBJS += audio/audio_resampler_driver.o
OBJS += audio/drivers_resampler/sinc.o
OBJS += audio/drivers_resampler/nearest.o
OBJS += audio/drivers_resampler/cc_resampler.o
OBJS += camera/drivers/nullcamera.o
OBJS += location/drivers/nulllocation.o
OBJS += audio/drivers/ctr_audio.o
OBJS += audio/drivers/nullaudio.o
OBJS += gfx/video_driver.o
OBJS += gfx/video_common.o
OBJS += gfx/video_pixel_converter.o
OBJS += gfx/video_viewport.o
OBJS += input/input_driver.o
OBJS += audio/audio_driver.o
OBJS += camera/camera_driver.o
OBJS += location/location_driver.o
OBJS += menu/menu_driver.o
OBJS += driver.o
OBJS += libretro-common/gfx/scaler/scaler_filter.o
OBJS += libretro-common/gfx/scaler/pixconv.o
OBJS += libretro-common/gfx/scaler/scaler.o
OBJS += libretro-common/gfx/scaler/scaler_int.o
OBJS += gfx/video_filters/2xsai.o
OBJS += gfx/video_filters/super2xsai.o
OBJS += gfx/video_filters/supereagle.o
OBJS += gfx/video_filters/2xbr.o
OBJS += gfx/video_filters/darken.o
OBJS += gfx/video_filters/epx.o
OBJS += gfx/video_filters/scale2x.o
OBJS += gfx/video_filters/blargg_ntsc_snes.o
OBJS += gfx/video_filters/lq2x.o
OBJS += gfx/video_filters/phosphor2x.o
OBJS += audio/audio_filters/echo.o
OBJS += audio/audio_filters/eq.o
OBJS += audio/audio_filters/chorus.o
OBJS += audio/audio_filters/iir.o
OBJS += audio/audio_filters/panning.o
OBJS += audio/audio_filters/phaser.o
OBJS += audio/audio_filters/reverb.o
OBJS += audio/audio_filters/wahwah.o
OBJS += libretro-common/dynamic/dylib.o
OBJS += dynamic.o
OBJS += gfx/video_filter.o
OBJS += audio/audio_dsp_filter.o
OBJS += cores/dynamic_dummy.o
OBJS += content.o
OBJS += libretro-common/file/file_path.o
OBJS += file_path_special.o
OBJS += libretro-common/file/dir_list.o
OBJS += libretro-common/file/retro_dirent.o
OBJS += dir_list_special.o
OBJS += libretro-common/string/string_list.o
OBJS += libretro-common/string/stdstring.o
OBJS += file_ops.o
OBJS += libretro-common/file/nbio/nbio_stdio.o
OBJS += libretro-common/file/file_list.o
OBJS += libretro-common/queues/message_queue.o
OBJS += patch.o
OBJS += configuration.o
OBJS += rewind.o
OBJS += frontend/frontend_driver.o
OBJS += frontend/drivers/platform_ctr.o
OBJS += frontend/drivers/platform_null.o
OBJS += core_info.o
OBJS += ui/ui_companion_driver.o
OBJS += ui/drivers/ui_null.o
OBJS += frontend/frontend.o
OBJS += libretro_version_1.o
OBJS += retroarch.o
OBJS += retroarch_info.o
OBJS += runloop.o
OBJS += runloop_data.o
OBJS += runloop_msg.o
OBJS += system.o
OBJS += msg_hash.o
OBJS += intl/msg_hash_de.o
OBJS += intl/msg_hash_es.o
OBJS += intl/msg_hash_eo.o
OBJS += intl/msg_hash_fr.o
OBJS += intl/msg_hash_it.o
OBJS += intl/msg_hash_nl.o
OBJS += intl/msg_hash_pt.o
OBJS += intl/msg_hash_pl.o
OBJS += intl/msg_hash_us.o
OBJS += movie.o
OBJS += record/record_driver.o
OBJS += record/drivers/record_null.o
OBJS += tasks/task_file_transfer.o
OBJS += screenshot.o
OBJS += playlist.o
OBJS += menu/menu.o
OBJS += menu/menu_hash.o
OBJS += menu/menu_input.o
OBJS += menu/menu_entry.o
OBJS += menu/menu_entries.o
OBJS += menu/menu_setting.o
OBJS += menu/menu_list.o
OBJS += menu/menu_cbs.o
OBJS += menu/menu_video.o
OBJS += menu/cbs/menu_cbs_ok.o
OBJS += menu/cbs/menu_cbs_cancel.o
OBJS += menu/cbs/menu_cbs_select.o
OBJS += menu/cbs/menu_cbs_start.o
OBJS += menu/cbs/menu_cbs_info.o
OBJS += menu/cbs/menu_cbs_refresh.o
OBJS += menu/cbs/menu_cbs_left.o
OBJS += menu/cbs/menu_cbs_right.o
OBJS += menu/cbs/menu_cbs_title.o
OBJS += menu/cbs/menu_cbs_deferred_push.o
OBJS += menu/cbs/menu_cbs_scan.o
OBJS += menu/cbs/menu_cbs_get_value.o
OBJS += menu/menu_iterate.o
OBJS += menu/cbs/menu_cbs_up.o
OBJS += menu/cbs/menu_cbs_down.o
OBJS += menu/cbs/menu_cbs_contentlist_switch.o
OBJS += menu/menu_shader.o
OBJS += menu/menu_navigation.o
OBJS += menu/menu_display.o
OBJS += menu/menu_displaylist.o
OBJS += menu/menu_animation.o
OBJS += menu/intl/menu_hash_de.o
OBJS += menu/intl/menu_hash_es.o
OBJS += menu/intl/menu_hash_eo.o
OBJS += menu/intl/menu_hash_fr.o
OBJS += menu/intl/menu_hash_it.o
OBJS += menu/intl/menu_hash_nl.o
OBJS += menu/intl/menu_hash_pl.o
OBJS += menu/intl/menu_hash_pt.o
OBJS += menu/intl/menu_hash_us.o
OBJS += menu/drivers/null.o
OBJS += menu/drivers/rgui.o
OBJS += command_event.o
OBJS += deps/zlib/adler32.o
OBJS += deps/zlib/compress.o
OBJS += deps/zlib/crc32.o
OBJS += deps/zlib/deflate.o
OBJS += deps/zlib/gzclose.o
OBJS += deps/zlib/gzlib.o
OBJS += deps/zlib/gzread.o
OBJS += deps/zlib/gzwrite.o
OBJS += deps/zlib/inffast.o
OBJS += deps/zlib/inflate.o
OBJS += deps/zlib/inftrees.o
OBJS += deps/zlib/trees.o
OBJS += deps/zlib/uncompr.o
OBJS += deps/zlib/zutil.o
OBJS += deps/zlib/ioapi.o
OBJS += deps/zlib/unzip.o
OBJS += audio/audio_utils.o
endif
ifeq ($(strip $(DEVKITARM)),)
@ -17,11 +231,20 @@ ifeq ($(strip $(AEMSTRO)),)
$(error "Please set AEMSTRO in your environment. export AEMSTRO=<path to>aemstro")
endif
APP_TITLE := $(shell echo "$(APP_TITLE)" | cut -c1-128)
APP_DESCRIPTION := $(shell echo "$(APP_DESCRIPTION)" | cut -c1-256)
APP_AUTHOR := $(shell echo "$(APP_AUTHOR)" | cut -c1-128)
APP_PRODUCT_CODE := $(shell echo $(APP_PRODUCT_CODE) | cut -c1-16)
APP_UNIQUE_ID := $(shell echo $(APP_UNIQUE_ID) | cut -c1-7)
INCDIRS := -I$(CTRULIB)/include
LIBDIRS := -L. -L$(CTRULIB)/lib
ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard
ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -marm -mfpu=vfp
CFLAGS += -mword-relocations \
-fomit-frame-pointer -ffast-math \
@ -35,6 +258,12 @@ ifeq ($(DEBUG), 1)
else
CFLAGS += -O3
endif
ifeq ($(WHOLE_ARCHIVE_LINK), 1)
WHOLE_START := -Wl,--whole-archive
WHOLE_END := -Wl,--no-whole-archive
endif
CFLAGS += -I. -Ideps/zlib -Ideps/7zip -Ilibretro-common/include
CFLAGS += -DRARCH_INTERNAL -DRARCH_CONSOLE -DSINC_LOWEST_QUALITY
@ -45,45 +274,35 @@ CFLAGS += -DHAVE_ZLIB -DHAVE_RPNG -DWANT_ZLIB -DHAVE_BUILTIN_AUTOCONFIG
CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -std=gnu++11
ASFLAGS := -g $(ARCH)
ASFLAGS := -g $(ARCH) -O3
LDFLAGS = -specs=3dsx.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map)
CFLAGS += -std=gnu99 -ffast-math
LIBS := -lretro_ctr -lctru -lm
LIBS := $(WHOLE_START) -lretro_ctr $(WHOLE_END) -lctru -lm
ifeq ($(BUILD_3DSX), 1)
TARGET_3DSX := $(TARGET).3dsx $(TARGET).smdh
endif
ifeq ($(BUILD_CIA), 1)
TARGET_CIA := $(TARGET).cia
endif
.PHONY: $(BUILD) clean all
#---------------------------------------------------------------------------------
all: $(TARGET)
clean:
rm -f $(OBJS)
rm -f $(TARGET).3dsx
rm -f $(TARGET).elf
$(TARGET): $(TARGET_3DSX) $(TARGET_CIA)
$(TARGET).3dsx: $(TARGET).elf
$(TARGET).elf: $(OBJS) libretro_ctr.a
ctr_sprite_shader_shbin.h: gfx/drivers/ctr_sprite.o
gfx/drivers/ctr_gfx.c: ctr_sprite_shader_shbin.h
griffin/griffin.o: gfx/drivers/ctr_gfx.c
$(TARGET): $(TARGET).3dsx
$(TARGET).3dsx : $(TARGET).elf
$(TARGET).elf : $(OBJS)
ifeq ($(strip $(APP_TITLE)),)
APP_TITLE := $(notdir $(TARGET))
endif
ifeq ($(strip $(APP_DESCRIPTION)),)
APP_DESCRIPTION := Built with devkitARM & libctru
endif
ifeq ($(strip $(APP_AUTHOR)),)
APP_AUTHOR := Unspecified Author
endif
ifeq ($(strip $(APP_ICON)),)
APP_ICON := $(CTRULIB)/default_icon.png
endif
PREFIX := $(DEVKITARM)/bin/arm-none-eabi-
@ -96,12 +315,21 @@ STRIP := $(PREFIX)strip
NM := $(PREFIX)nm
LD := $(CXX)
ifneq ($(findstring Linux,$(shell uname -a)),)
MAKEROM = ctr/tools/makerom-linux
BANNERTOOL = ctr/tools/bannertool-linux
else ifneq ($(findstring Darwin,$(shell uname -a)),)
MAKEROM = ctr/tools/makerom-mac
BANNERTOOL = ctr/tools/bannertool-mac
else
MAKEROM = ctr/tools/makerom.exe
BANNERTOOL = ctr/tools/bannertool.exe
endif
%.o: %.shader
#---------------------------------------------------------------------------------
@echo $(notdir $<)
python $(AEMSTRO)/aemstro_as.py $< $(notdir $<).shbin
bin2s $(notdir $<).shbin | $(PREFIX)as -o $@
$(DEVKITARM)/bin/bin2s $(notdir $<).shbin | $(PREFIX)as -o $@
echo "extern const u8" `(echo $(notdir $<).shbin | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end[];" > `(echo $(notdir $<).shbin | tr . _)`.h
echo "extern const u8" `(echo $(notdir $<).shbin | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"[];" >> `(echo $(notdir $<).shbin | tr . _)`.h
echo "extern const u32" `(echo $(notdir $<).shbin | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size";" >> `(echo $(notdir $<).shbin | tr . _)`.h
@ -125,22 +353,42 @@ LD := $(CXX)
%.vsh:
#---------------------------------------------------------------------------------
%.smdh: $(APP_ICON) $(MAKEFILE_LIST)
@echo building ... $(notdir $@)
%.smdh: $(APP_ICON)
smdhtool --create "$(APP_TITLE)" "$(APP_DESCRIPTION)" "$(APP_AUTHOR)" $(APP_ICON) $@
#---------------------------------------------------------------------------------
%.3dsx: %.elf
@echo building ... $(notdir $@)
3dsxtool $< $@ $(_3DSXFLAGS)
-3dsxtool $< $@ $(_3DSXFLAGS)
#---------------------------------------------------------------------------------
%.elf: .FORCE
@echo linking $(notdir $@)
%.elf:
$(LD) $(LDFLAGS) $(OBJS) $(LIBDIRS) $(LIBS) -o $@
$(NM) -CSn $@ > $(notdir $*.lst)
$(TARGET).bnr: $(APP_BANNER) $(APP_AUDIO)
$(BANNERTOOL) makebanner -i "$(APP_BANNER)" -a "$(APP_AUDIO)" -o $@
.PHONY: .FORCE
$(TARGET).icn: $(APP_ICON)
$(BANNERTOOL) makesmdh -s "$(APP_TITLE)" -l "$(APP_TITLE)" -p "$(APP_AUTHOR)" -i $(APP_ICON) -o $@
$(TARGET).rsf: ctr/tools/template-cia.rsf
cat ctr/tools/template-cia.rsf | sed 's/{APP_TITLE}/$(APP_TITLE)/' | sed 's/{APP_PRODUCT_CODE}/$(APP_PRODUCT_CODE)/' | sed 's/{APP_UNIQUE_ID}/$(APP_UNIQUE_ID)/' > $@
$(TARGET)_stripped.elf: $(TARGET).elf
cp $(TARGET).elf $@
$(STRIP) $@
$(TARGET).cia: $(TARGET)_stripped.elf $(TARGET).bnr $(TARGET).icn $(TARGET).rsf
$(MAKEROM) -f cia -o $@ -rsf $(TARGET).rsf -target t -exefslogo -elf $(TARGET)_stripped.elf -icon $(TARGET).icn -banner $(TARGET).bnr
clean:
rm -f $(OBJS)
rm -f $(TARGET).3dsx
rm -f $(TARGET).elf
rm -f $(TARGET)_stripped.elf
rm -f $(TARGET).cia
rm -f $(TARGET).bnr
rm -f $(TARGET).icn
rm -f $(TARGET).rsf
rm -f *_shader_shbin.h
.PHONY: clean

View File

@ -23,7 +23,11 @@ ifneq ($(NATIVE_ZLIB),)
endif
LIBS :=
LDFLAGS := -L. -s TOTAL_MEMORY=$(MEMORY) -s OUTLINING_LIMIT=50000 --js-library emscripten/library_rwebaudio.js --js-library emscripten/library_rwebinput.js --js-library emscripten/library_rwebcam.js --no-heap-copy
LDFLAGS := -L. --no-heap-copy -s USE_ZLIB=1 -s TOTAL_MEMORY=$(MEMORY) -s OUTLINING_LIMIT=50000 \
-s EXPORTED_FUNCTIONS="['_main', '_malloc', '_cmd_savefiles', '_cmd_save_state', '_cmd_load_state', '_cmd_take_screenshot']" \
--js-library emscripten/library_rwebaudio.js \
--js-library emscripten/library_rwebinput.js \
--js-library emscripten/library_rwebcam.js
include Makefile.common
@ -67,7 +71,8 @@ else
CFLAGS += -O2
endif
CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -Ilibretro-common/include -std=gnu99
CFLAGS += -DWANT_RPNG -Wall -Wno-unused-result -Wno-unused-variable -I. -Ilibretro-common/include -std=gnu99 -s USE_ZLIB=1 \
-s EXPORTED_FUNCTIONS="['_main', '_malloc', '_cmd_savefiles', '_cmd_save_state', '_cmd_take_screenshot']"
all: $(TARGET)
@ -111,4 +116,3 @@ clean:
rm -f *.d
.PHONY: all clean

View File

@ -5,6 +5,7 @@ WHOLE_ARCHIVE_LINK = 0
BIG_STACK = 1
PC_DEVELOPMENT_IP_ADDRESS = 255.255.255.255
PC_DEVELOPMENT_UDP_PORT = 3490
RARCH_CONSOLE = 0
ifneq ($(EMSCRIPTEN),)
platform = emscripten
@ -44,100 +45,184 @@ SHADER_CG_DIR := media/shaders_cg
OVERLAY_DIR := media/overlays
SHADER_GLSL_DIR := media/shaders_glsl
PYTHON2 = python2$(EXE_EXT)
PYTHON3 = python3$(EXE_EXT)
GIT = git$(EXE_EXT)
PYTHON2 := python2$(EXE_EXT)
PYTHON3 := python3$(EXE_EXT)
GIT := git$(EXE_EXT)
ifeq ($(WHOLE_ARCHIVE_LINK), 1)
WHOLE_START := -Wl,--whole-archive
WHOLE_END := -Wl,--no-whole-archive
endif
LIBS := $(WHOLE_START) -lretro_$(platform) $(WHOLE_END)
libogc_platform :=
ifeq ($(platform), ngc)
libogc_platform := 1
else ifeq ($(platform), wii)
libogc_platform := 1
endif
# PS3
ifeq ($(platform), ps3)
#TODO
MEDIA_SHADER_DIR := pkg/ps3/USRDIR/cores/shaders
RARCH_CONSOLE = 1
# PS3 - Cobra
else ifeq ($(platform), ps3-cobra)
#TODO
MEDIA_SHADER_DIR := ps3/iso/PS3_GAME/USRDIR/cores/shaders
RARCH_CONSOLE = 1
# NGC/Wii - libogc
else ifeq ($(libogc_platform), 1)
CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc$(EXE_EXT)
CXX = $(DEVKITPPC)/bin/powerpc-eabi-g++$(EXE_EXT)
LD = $(DEVKITPPC)/bin/powerpc-eabi-ld$(EXE_EXT)
ELF2DOL = $(DEVKITPPC)/bin/elf2dol$(EXE_EXT)
EXT_TARGET := $(TARGET_NAME)_ngc.dol
EXT_INTER_TARGET := $(TARGET_NAME)_ngc.elf
EXT_TARGET := $(TARGET_NAME)_$(platform).dol
EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf
INCLUDE += -I. -I$(DEVKITPRO)/libogc/include -Ideps/zlib
LIBDIRS += -L$(DEVKITPRO)/libogc/lib/cube -L.
MACHDEP := -DGEKKO -DHW_DOL -mogc -mcpu=750 -meabi -mhard-float -DMSB_FIRST
ifeq ($(platform), ngc)
LIBDIRS += -L$(DEVKITPRO)/libogc/lib/cube
MACHDEP := -DHW_DOL -mogc
else ifeq ($(platform), wii)
LIBDIRS += -L$(DEVKITPRO)/libogc/lib/wii
MACHDEP := -DHW_RVL -mrvl
endif
LIBDIRS += -L.
MACHDEP += -DGEKKO -mcpu=750 -meabi -mhard-float -DMSB_FIRST
ifeq ($(platform), ngc)
LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map
ifeq ($(BIG_STACK), 1)
LDFLAGS += -T gx/ld/ogc.ld
endif
LIBS := -lfat $(WHOLE_START) -lretro_ngc $(WHOLE_END) -logc
ifeq ($(HAVE_LOGGER), 1)
LIBS += -lbba
endif
PLATCFLAGS := -DGEKKO
HAVE_FILTERS_BUILTIN := 1
HAVE_THREADS := 1
HAVE_ZLIB := 1
HAVE_RPNG := 1
HAVE_7ZIP := 1
HAVE_RPNG := 1
HAVE_OVERLAY := 1
HAVE_BUILTIN_AUTOCONFIG := 1
else ifeq ($(platform), ps3)
#TODO
MEDIA_SHADER_DIR := ps3/pkg/USRDIR/cores/shaders
else ifeq ($(platform), ps3-cobra)
#TODO
MEDIA_SHADER_DIR := ps3/iso/PS3_GAME/USRDIR/cores/shaders
else ifeq ($(platform), wii)
CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc$(EXE_EXT)
CXX = $(DEVKITPPC)/bin/powerpc-eabi-g++$(EXE_EXT)
LD = $(DEVKITPPC)/bin/powerpc-eabi-ld$(EXE_EXT)
ELF2DOL = $(DEVKITPPC)/bin/elf2dol$(EXE_EXT)
EXT_TARGET := $(TARGET_NAME)_wii.dol
EXT_INTER_TARGET := $(TARGET_NAME)_wii.elf
INCLUDE += -I. -I$(DEVKITPRO)/libogc/include -Ideps/zlib
LIBDIRS += -L$(DEVKITPRO)/libogc/lib/wii -L.
MACHDEP := -DGEKKO -DHW_RVL -mrvl -mcpu=750 -meabi -mhard-float -DMSB_FIRST
LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map,-wrap,malloc,-wrap,free,-wrap,memalign,-wrap,calloc,-wrap,realloc,-wrap,strdup,-wrap,strndup,-wrap,malloc_usable_size
ifeq ($(BIG_STACK), 1)
LDFLAGS += -T gx/ld/rvl.ld
endif
LIBS := -lfat $(WHOLE_START) -lretro_wii $(WHOLE_END) -logc -lwiiuse -lbte
endif
LIBS += -lfat -logc
ifeq ($(platform), wii)
LIBS += -lwiiuse -lbte
ifeq ($(USBGECKO), 1)
LIBS += -ldb
endif
else ifeq ($(platform), ngc)
ifeq ($(HAVE_LOGGER), 1)
LIBS += -lbba
endif
endif
CFLAGS += -DGEKKO
HAVE_FILTERS_BUILTIN := 1
HAVE_THREADS := 1
HAVE_RPNG := 1
HAVE_OVERLAY := 1
HAVE_BUILTIN_AUTOCONFIG := 1
HAVE_ZLIB := 1
HAVE_7ZIP := 1
RARCH_CONSOLE = 1
ifeq ($(platform), wii)
HAVE_WIIUSB_HID := 1
HAVE_RARCH_EXEC := 1
HAVE_RSOUND := 1
HAVE_LIBRETRO_MANAGEMENT := 1
HAVE_LIBSICKSAXIS := 1
APP_BOOTER_DIR = wii/app_booter
PLATOBJS := $(APP_BOOTER_DIR)/app_booter.binobj
CFLAGS += -DGEKKO
ifeq ($(USBGECKO), 1)
CFLAGS += -DUSBGECKO
endif
endif
HAVE_FILTERS_BUILTIN := 1
HAVE_RARCH_EXEC := 1
# Libxenon (Xbox 360)
else ifeq ($(platform), xenon360)
CC = xenon-gcc$(EXE_EXT)
CXX = xenon-g++$(EXE_EXT)
OBJCOPY = xenon-objcopy$(EXE_EXT)
LD = xenon-ld$(EXE_EXT)
STRIP = xenon-strip$(EXE_EXT)
INCLUDE += -I$(DEVKITXENON)/usr/include
EXT_TARGET := $(TARGET_NAME)_$(platform).elf32
EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf
LIBS += -lxenon -lm -lc
LIBDIRS += -L. -L$(DEVKITXENON)/usr/lib -L$(DEVKITXENON)/xenon/lib/32
LDFLAGS += -Wl,-q -m32 -n -T$(DEVKITXENON)/app.lds
PLATCFLAGS := -DHAVE_GETOPT_LONG=1
PLATCFLAGS += -maltivec -mhard-float -m32 -mpowerpc64 -mcpu=cell -mtune=cell -fno-pic -g -Wall -DXENON $(INCDIRS) -Wno-char-subscripts
PLATCFLAGS += -u read -u _start -u exc_base
HAVE_THREADS := 1
HAVE_RSOUND := 1
HAVE_7ZIP := 1
HAVE_LIBRETRO_MANAGEMENT := 1
HAVE_ZLIB := 1
HAVE_RPNG := 1
HAVE_RPNG := 1
HAVE_OVERLAY := 1
HAVE_LIBSICKSAXIS := 1
HAVE_BUILTIN_AUTOCONFIG := 1
HAVE_GETOPT_LONG := 1
RARCH_CONSOLE = 1
# PSP
else ifeq ($(platform), psp1)
CC = psp-gcc$(EXE_EXT)
CXX = psp-g++$(EXE_EXT)
LD = psp-ld$(EXE_EXT)
INCLUDE += -I$(PSPSDK)/psp/sdk/include
EXT_TARGET := $(TARGET_NAME)_psp1.elf
EXT_INTER_TARGET := $(TARGET_NAME)_psp1.elf
PLATCFLAGS := -DPSP -D_PSP_FW_VERSION=150 -G0
EXT_TARGET := $(TARGET_NAME)_$(platform).elf
EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf
PLATCFLAGS := -DPSP -D_PSP_FW_VERSION=150 -G0 \
-D_MIPS_ARCH_ALLEGREX
LIBS += -lpspgu -lpspgum -lm -lpspaudio -lpspfpu -lpsppower -lpsprtc -lpspkernel
LIBDIRS += -L.
LDFLAGS += -Wl,-q
BUILD_PRX = 1
HAVE_LIBRETRO_MANAGEMENT := 1
HAVE_RPNG := 1
HAVE_KERNEL_PRX := 1
RARCH_CONSOLE = 1
ifeq ($(BUILD_PRX), 1)
LDFLAGS += $(addprefix -L,$(PSPSDK)/lib) -specs=$(PSPSDK)/lib/prxspecs -Wl,-q,-T$(PSPSDK)/lib/linkfile.prx $(LDFLAGS)
endif
CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(INCLUDE)
# Vita
else ifeq ($(platform), vita)
CC = arm-vita-eabi-gcc$(EXE_EXT)
CXX = arm-vita-eabi-g++$(EXE_EXT)
LD = arm-vita-eabi-ld$(EXE_EXT)
EXT_TARGET := $(TARGET_NAME)_$(platform).velf
EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf
MACHDEP := -DVITA
PLATCFLAGS := -O3 -U__ARM_NEON__
LIBS += -lSceKernel_stub -lSceDisplay_stub -lSceGxm_stub -lSceNet_stub \
-lSceSysmodule_stub -lSceCtrl_stub -lSceAudio_stub \
-lScePower_stub -lSceRtc_stub -lz -lm -lc
PLATOBJS += audio/audio_utils_neon.o audio/drivers_resampler/sinc_neon.o \
audio/drivers_resampler/cc_resampler_neon.o
LIBDIRS += -L.
LDFLAGS += -Wl,-q
HAVE_LIBRETRO_MANAGEMENT := 1
HAVE_BUILTIN_AUTOCONFIG := 1
HAVE_RPNG := 1
HAVE_ZLIB := 1
HAVE_VITA2D := 1
RARCH_CONSOLE = 1
endif
CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(PLATCFLAGS) $(INCLUDE)
OBJ = griffin/griffin.o $(PLATOBJS)
@ -149,18 +234,42 @@ CFLAGS += -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC
INCLUDE += -Ilogger/netlogger
endif
ifeq ($(platform), wii)
CFLAGS += -DHAVE_SOCKET_LEGACY
endif
ifeq ($(platform), vita)
CFLAGS += -DHAVE_SOCKET_LEGACY
endif
ifeq ($(HAVE_LIBRETRO_MANAGEMENT), 1)
CFLAGS += -DHAVE_LIBRETRO_MANAGEMENT
endif
ifeq ($(HAVE_KERNEL_PRX), 1)
CFLAGS += -DHAVE_KERNEL_PRX
endif
ifeq ($(HAVE_LIBSICKSAXIS), 1)
CFLAGS += -DHAVE_LIBSICKSAXIS
endif
ifeq ($(HAVE_WIIUSB_HID), 1)
CFLAGS += -DHAVE_WIIUSB_HID -DHAVE_HID
endif
ifeq ($(HAVE_VITA2D), 1)
CFLAGS += -DHAVE_VITA2D
endif
ifeq ($(HAVE_LIBRETRODB), 1)
CFLAGS += -DHAVE_LIBRETRODB
endif
ifeq ($(BIG_STACK),1)
CFLAGS += -DBIG_STACK
endif
ifeq ($(HAVE_RPNG), 1)
CFLAGS += -DWANT_RPNG
endif
@ -202,7 +311,15 @@ ifeq ($(HAVE_NETPLAY), 1)
CFLAGS += -DHAVE_NETPLAY
endif
CFLAGS += -std=gnu99 -DSINC_LOWER_QUALITY -DHAVE_RGUI -DHAVE_MENU -DRARCH_CONSOLE -DHAVE_GRIFFIN=1 -Wno-char-subscripts -DRARCH_INTERNAL
ifeq ($(RARCH_CONSOLE), 1)
CFLAGS += -DRARCH_CONSOLE
endif
ifeq ($(RARCH_MOBILE), 1)
CFLAGS += -DRARCH_MOBILE
endif
CFLAGS += -std=gnu99 -DSINC_LOWER_QUALITY -DHAVE_RGUI -DHAVE_MENU -DHAVE_GRIFFIN=1 -Wno-char-subscripts -DRARCH_INTERNAL
ifeq ($(HAVE_FILTERS_BUILTIN), 1)
CFLAGS += -DHAVE_FILTERS_BUILTIN
@ -215,10 +332,18 @@ LIBS += -lpthread-psp
endif
endif
ifeq ($(HAVE_VITA2D), 1)
LIBS := -lvita2d $(LIBS)
endif
ifeq ($(HAVE_RSOUND), 1)
CFLAGS += -DHAVE_RSOUND
endif
ifeq ($(HAVE_GETOPT_LONG), 1)
CFLAGS += -DHAVE_GETOPT_LONG=1
endif
ifeq ($(DEBUG), 1)
CFLAGS += -O0 -g -DDEBUG
else ifeq ($(platform), psp1)
@ -232,12 +357,29 @@ all: $(EXT_TARGET)
%.dol: %.elf
$(ELF2DOL) $< $@
%.velf: %.elf
arm-vita-eabi-strip -g $<
vita-elf-create $< $@ $(VITASDK)/bin/db.json
%.elf32: %.elf
ifeq ($(platform), xenon360)
$(OBJCOPY) -O elf32-powerpc --adjust-vma 0x80000000 $< $@
endif
%.prx: %.elf
ifeq ($(platform),psp1)
psp-prxgen $< $@
endif
$(EXT_INTER_TARGET): $(OBJ)
$(CXX) -o $@ $(LDFLAGS) $(LIBDIRS) $(OBJ) $(LIBS)
%.o: %.c
$(CC) $(CFLAGS) -c -o $@ $<
%.o: %.S
$(CC) $(CFLAGS) -c -o $@ $<
%.bmpobj: %.bmp
$(LD) -r -b binary -o $@ $<
@ -249,9 +391,9 @@ $(APP_BOOTER_DIR)/app_booter.bin:
pkg: all
ifeq ($(platform), wii)
cp -r $(EXT_TARGET) wii/pkg/CORE.dol
cp -r $(EXT_TARGET) pkg/wii/CORE.dol
else ifeq ($(platform), ngc)
cp -r $(EXT_TARGET) ngc/pkg/CORE.dol
cp -r $(EXT_TARGET) pkg/ngc/CORE.dol
else ifeq ($(platform), psp1)
psp-fixup-imports$(EXT) $(EXT_TARGET)
endif

View File

@ -30,8 +30,8 @@ include $(CELL_MK_DIR)/sdk.makedef.mk
PPU_TARGET = retroarch_ps3.elf
SALAMANDER_TARGET = retroarch-salamander_ps3.elf
EBOOT_PATH = ps3/pkg/USRDIR/EBOOT.BIN
CORE_PATH = ps3/pkg/USRDIR/cores/CORE.SELF
EBOOT_PATH = pkg/ps3/USRDIR/EBOOT.BIN
CORE_PATH = pkg/ps3/USRDIR/cores/CORE.SELF
LDDIRS = -L. -L$(CELL_SDK)/target/ppu/lib/PSGL/RSX/ultra-opt
INCDIRS = -I. -Ips3 -Icommon -Ideps/zlib -Ilibretro-common/include
@ -157,28 +157,28 @@ create-salamander:
$(MAKE_SELF) $(SALAMANDER_TARGET) $(EBOOT_PATH) $(CONTENT_ID_FULL)
copy-media-files:
@cp -r $(RMENU_IMG_DIR)/*.png ps3/pkg/USRDIR/cores/borders/Menu/
@cp -r $(RMENU_IMG_DIR)/*.png pkg/ps3/USRDIR/cores/borders/Menu/
create-shaders:
make -f Makefile.shaders deploy-ps3
pkg: $(PPU_TARGET) create-shaders copy-media-files create-npdrm-salamander create-npdrm-core
$(MAKE_PACKAGE_NPDRM) ps3/pkg/package.conf ps3/pkg
$(MAKE_PACKAGE_NPDRM) pkg/ps3/package.conf pkg/ps3
pkg-signed: $(PPU_TARGET) create-shaders copy-media-files create-salamander create-core
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
pkg-signed-standalone: $(PPU_TARGET) create-shaders copy-media-files create-core
$(MAKE_SELF) $(PPU_TARGET) $(EBOOT_PATH) $(CONTENT_ID)
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
pkg-signed-cfw: $(PPU_TARGET) create-shaders copy-media-files create-salamander create-core
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
$(PKG_FINALIZE) retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
pkg-signed-cfw-standalone: $(PPU_TARGET) create-shaders copy-media-files create-core
$(MAKE_SELF) $(PPU_TARGET) $(EBOOT_PATH) $(CONTENT_ID)
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PKG_FINALIZE) retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
clean-selfs:

View File

@ -30,8 +30,8 @@ include $(CELL_MK_DIR)/sdk.makedef.mk
PPU_TARGET = retroarch_ps3.elf
SALAMANDER_TARGET = retroarch-salamander_ps3.elf
EBOOT_PATH = ps3/pkg/USRDIR/EBOOT.BIN
CORE_PATH = ps3/pkg/USRDIR/cores/CORE.SELF
EBOOT_PATH = pkg/ps3/USRDIR/EBOOT.BIN
CORE_PATH = pkg/ps3/USRDIR/cores/CORE.SELF
LDDIRS = -L. -L$(CELL_SDK)/target/ppu/lib/PSGL/RSX/ultra-opt
INCDIRS = -I. -Ips3 -Icommon
@ -157,28 +157,28 @@ create-salamander:
$(MAKE_SELF) $(SALAMANDER_TARGET) $(EBOOT_PATH) $(CONTENT_ID_FULL)
copy-media-files:
@cp -r $(RMENU_IMG_DIR)/*.png ps3/pkg/USRDIR/cores/borders/Menu/
@cp -r $(RMENU_IMG_DIR)/*.png pkg/ps3/USRDIR/cores/borders/Menu/
create-shaders:
make -f Makefile.shaders deploy-ps3
pkg: $(PPU_TARGET) create-shaders copy-media-files create-npdrm-salamander create-npdrm-core
$(MAKE_PACKAGE_NPDRM) ps3/pkg/package.conf ps3/pkg
$(MAKE_PACKAGE_NPDRM) pkg/ps3/package.conf pkg/ps3
pkg-signed: $(PPU_TARGET) create-shaders copy-media-files create-salamander create-core
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
pkg-signed-standalone: $(PPU_TARGET) create-shaders copy-media-files create-core
$(MAKE_SELF) $(PPU_TARGET) $(EBOOT_PATH) $(CONTENT_ID)
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
pkg-signed-cfw: $(PPU_TARGET) create-shaders copy-media-files create-salamander create-core
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
$(PKG_FINALIZE) retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
pkg-signed-cfw-standalone: $(PPU_TARGET) create-shaders copy-media-files create-core
$(MAKE_SELF) $(PPU_TARGET) $(EBOOT_PATH) $(CONTENT_ID)
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PKG_FINALIZE) retroarch-ps3-cfw-$(RARCH_VERSION)-kmeaw.pkg
clean-selfs:

View File

@ -25,6 +25,7 @@ PPU_SRCS = frontend/frontend_salamander.c \
frontend/drivers/platform_null.c \
libretro-common/file/file_path.c \
libretro-common/file/dir_list.c \
libretro-common/file/retro_dirent.c \
libretro-common/hash/rhash.c \
libretro-common/string/string_list.c \
libretro-common/compat/compat.c \

View File

@ -14,8 +14,8 @@ LD = $(PS3DEV)/ppu/bin/ppu-ld
CONTENT_ID_FULL = UP0001-SSNE10000_00-0000000000000001
ELF_TARGET := retroarch_psl1ght.elf
EBOOT_PATH = ps3/pkg/USRDIR/EBOOT.BIN
CORE_PATH = ps3/pkg/USRDIR/cores/CORE.SELF
EBOOT_PATH = pkg/ps3/USRDIR/EBOOT.BIN
CORE_PATH = pkg/ps3/USRDIR/cores/CORE.SELF
INCLUDE := -I. -I$(PS3DEV)/ppu/include -Ideps/zlib -Ips3/gcmgl/include/export -Ips3/include
LIBDIRS := -L$(PS3DEV)/ppu/lib -L$(PS3DEV)/portlibs/ppu/lib -L.
@ -119,10 +119,10 @@ create-core:
$(MAKE_SELF_WC) $(ELF_TARGET) $(CORE_PATH)
pkg: $(ELF_TARGET) create-npdrm-core
$(MAKE_PACKAGE_NPDRM) ps3/pkg/package.conf ps3/pkg
$(MAKE_PACKAGE_NPDRM) pkg/ps3/package.conf ps3/pkg
pkg-signed: $(ELF_TARGET) create-core
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) ps3/pkg/ retroarch-ps3-cfw-$(RARCH_VERSION).pkg
$(PYTHON2) $(PKG_SCRIPT) --contentid $(CONTENT_ID_FULL) pkg/ps3 retroarch-ps3-cfw-$(RARCH_VERSION).pkg
clean:
rm -f $(ELF_TARGET)

View File

@ -38,6 +38,7 @@ OBJS = frontend/frontend_salamander.o \
libretro-common/file/file_path.o \
libretro-common/string/string_list.o \
libretro-common/file/dir_list.o \
libretro-common/file/retro_dirent.o \
libretro-common/compat/compat.o \
libretro-common/file/config_file.o \
libretro-common/hash/rhash.o \

View File

@ -39,7 +39,19 @@ LIBS := -lfat -lwiiuse -logc -lbte
APP_BOOTER_DIR = wii/app_booter
OBJ = frontend/frontend_salamander.o frontend/frontend_driver.o frontend/drivers/platform_gx.o frontend/drivers/platform_wii.o frontend/drivers/platform_null.o libretro-common/file/file_path.o libretro-common/hash/rhash.o libretro-common/string/string_list.o libretro-common/file/dir_list.o libretro-common/compat/compat.o libretro-common/file/config_file.o $(APP_BOOTER_DIR)/app_booter.binobj
OBJ = frontend/frontend_salamander.o \
frontend/frontend_driver.o \
frontend/drivers/platform_gx.o \
frontend/drivers/platform_wii.o \
frontend/drivers/platform_null.o \
libretro-common/file/file_path.o \
libretro-common/hash/rhash.o \
libretro-common/string/string_list.o \
libretro-common/file/dir_list.o \
libretro-common/file/retro_dirent.o \
libretro-common/compat/compat.o \
libretro-common/file/config_file.o \
$(APP_BOOTER_DIR)/app_booter.binobj
ifeq ($(HAVE_LOGGER), 1)
CFLAGS += -DHAVE_LOGGER
@ -79,7 +91,7 @@ $(APP_BOOTER_DIR)/app_booter.bin:
$(MAKE) -C $(APP_BOOTER_DIR)
pkg: all
cp -r $(DOL_TARGET) wii/pkg/boot.dol
cp -r $(DOL_TARGET) pkg/wii/boot.dol
clean:
rm -f $(DOL_TARGET)

View File

@ -127,9 +127,9 @@ else
endif
CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I.
CXXFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -std=c++0x -D__STDC_CONSTANT_MACROS
CXXFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -std=c++98 -D__STDC_CONSTANT_MACROS
ifeq ($(CXX_BUILD), 1)
CFLAGS += -std=c++0x -xc++ -D__STDC_CONSTANT_MACROS
CFLAGS += -std=c++98 -xc++ -D__STDC_CONSTANT_MACROS
else
ifneq ($(GNU90_BUILD), 1)
CFLAGS += -std=gnu99
@ -147,25 +147,26 @@ $(TARGET): $(RARCH_OBJ)
@$(if $(Q), $(shell echo echo LD $@),)
$(Q)$(CXX) -o $@ $(RARCH_OBJ) $(LIBS) $(LDFLAGS) $(LDCXXFLAGS)
#those mkdir shenanigans are really ugly, but I can't find any better solution
$(OBJDIR)/%.o: %.c
@mkdir -p $(dir $@)
@-mkdir -p $(dir $@) || mkdir $(subst /,\,$(dir $@)) || echo .
@$(if $(Q), $(shell echo echo CC $<),)
$(Q)$(CC) $(CFLAGS) $(DEFINES) -MMD -c -o $@ $<
.FORCE:
$(OBJDIR)/git_version.o: git_version.c .FORCE
@mkdir -p $(dir $@)
@-mkdir -p $(dir $@) || mkdir $(subst /,\,$(dir $@)) || echo .
@$(if $(Q), $(shell echo echo CC $<),)
$(Q)$(CC) $(CFLAGS) $(DEFINES) -MMD -c -o $@ $<
$(OBJDIR)/%.o: %.cpp
@mkdir -p $(dir $@)
$(OBJDIR)/%.o: %.cpp | $(dir $@)
@-mkdir -p $(dir $@) || mkdir $(subst /,\,$(dir $@)) || echo .
@$(if $(Q), $(shell echo echo CXX $<),)
$(Q)$(CXX) $(CXXFLAGS) $(DEFINES) -MMD -c -o $@ $<
$(OBJDIR)/%.o: %.rc $(HEADERS)
@mkdir -p $(dir $@)
@-mkdir -p $(dir $@) || mkdir $(subst /,\,$(dir $@)) || echo .
@$(if $(Q), $(shell echo echo WINDRES $<),)
$(Q)$(WINDRES) -o $@ $<

View File

@ -1,49 +0,0 @@
RARCH_VERSION = "0.9.9.3"
DEBUG = 0
CC = xenon-gcc
CXX = xenon-g++
OBJCOPY = xenon-objcopy
STRIP = xenon-strip
PPU_TARGET := retroarch-libxenon.elf
PPU_TARGET_ADJUSTED := retroarch-libxenon.elf32
LDDIRS = -L. -L$(DEVKITXENON)/usr/lib -L$(DEVKITXENON)/xenon/lib/32
INCDIRS = -I. -I$(DEVKITXENON)/usr/include
OBJ = griffin/griffin.o
LIBS = -lretro_xenon360 -lxenon -lm -lc
DEFINES = -std=gnu99 -DRARCH_CONSOLE -DHAVE_THREADS -DHAVE_GETOPT_LONG=1 -DHAVE_GRIFFIN -DRARCH_INTERNAL
DEFINES += -maltivec -mhard-float -m32 -mpowerpc64 -mcpu=cell -mtune=cell -fno-pic -g -Wall -DXENON $(INCDIRS) -Wno-char-subscripts
DEFINES += -u read -u _start -u exc_base
ifeq ($(DEBUG), 1)
OPTIMIZE_LV := -O0 -g
else
OPTIMIZE_LV := -O3
endif
all: $(PPU_TARGET_ADJUSTED)
CFLAGS := $(OPTIMIZE_LV) $(DEFINES)
LDFLAGS := -m32 -n -T $(DEVKITXENON)/app.lds
$(PPU_TARGET_ADJUSTED): $(PPU_TARGET)
$(OBJCOPY) -O elf32-powerpc --adjust-vma 0x80000000 $< $@
$(STRIP) $@
$(PPU_TARGET): $(OBJ)
$(CXX) -o $@ $(OBJ) $(LDFLAGS) $(LDDIRS) $(LIBS)
%.o: %.c config.h
$(CC) $(CFLAGS) -c -o $@ $<
clean:
rm -f $(PPU_TARGET)
rm -f $(OBJ)
.PHONY: clean

View File

@ -1,7 +1,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.retroarch"
android:versionCode="40"
android:versionName="1.2.1"
android:versionCode="42"
android:versionName="1.2.2"
android:installLocation="preferExternal">
<uses-feature android:glEsVersion="0x00020000" />
<uses-feature android:name="android.hardware.touchscreen" android:required="false"/>

View File

@ -3,7 +3,7 @@ include $(CLEAR_VARS)
LOCAL_MODULE := retroarch-jni
RARCH_DIR := ../../..
LOCAL_CFLAGS += -std=gnu99 -Wall -DHAVE_LOGGER -DRARCH_DUMMY_LOG -DHAVE_ZLIB -DHAVE_MMAP -DRARCH_INTERNAL
LOCAL_CFLAGS += -std=gnu99 -Wall -DRARCH_DUMMY_LOG -DHAVE_ZLIB -DHAVE_MMAP -DRARCH_INTERNAL
LOCAL_LDLIBS := -llog -lz
LOCAL_SRC_FILES := apk-extract/apk-extract.c $(RARCH_DIR)/libretro-common/file/file_extract.c $(RARCH_DIR)/libretro-common/file/file_path.c $(RARCH_DIR)/file_ops.c $(RARCH_DIR)/libretro-common/string/string_list.c $(RARCH_DIR)/libretro-common/compat/compat.c
@ -12,7 +12,7 @@ LOCAL_C_INCLUDES := $(LOCAL_PATH)/$(RARCH_DIR)/libretro-common/include/
include $(BUILD_SHARED_LIBRARY)
HAVE_NEON := 1
HAVE_LOGGER := 1
HAVE_LOGGER := 0
include $(CLEAR_VARS)
ifeq ($(TARGET_ARCH),arm)
@ -47,8 +47,8 @@ LOCAL_SRC_FILES += $(RARCH_DIR)/griffin/griffin.c
ifeq ($(HAVE_LOGGER), 1)
LOCAL_CFLAGS += -DHAVE_LOGGER
LOGGER_LDLIBS := -llog
endif
LOGGER_LDLIBS := -llog
ifeq ($(GLES),3)
GLES_LIB := -lGLESv3
@ -58,7 +58,7 @@ else
endif
LOCAL_CFLAGS += -Wall -pthread -Wno-unused-function -fno-stack-protector -funroll-loops -DRARCH_MOBILE -DHAVE_GRIFFIN -DANDROID -DHAVE_DYNAMIC -DHAVE_OPENGL -DHAVE_FBO -DHAVE_OVERLAY -DHAVE_OPENGLES -DHAVE_OPENGLES2 -DGLSL_DEBUG -DHAVE_DYLIB -DHAVE_GLSL -DHAVE_MENU -DHAVE_RGUI -DHAVE_ZLIB -DHAVE_RPNG -DINLINE=inline -DLSB_FIRST -DHAVE_THREADS -D__LIBRETRO__ -DHAVE_RSOUND -DHAVE_NETPLAY -DHAVE_NETWORKING -DRARCH_INTERNAL -DHAVE_FILTERS_BUILTIN -DHAVE_GLUI -DHAVE_XMB -std=gnu99 -DHAVE_LIBRETRODB -DHAVE_STB_FONT
LOCAL_CFLAGS += -Wall -pthread -Wno-unused-function -fno-stack-protector -funroll-loops -DRARCH_MOBILE -DHAVE_GRIFFIN -DANDROID -DHAVE_DYNAMIC -DHAVE_OPENGL -DHAVE_FBO -DHAVE_OVERLAY -DHAVE_OPENGLES -DHAVE_OPENGLES2 -DGLSL_DEBUG -DHAVE_DYLIB -DHAVE_GLSL -DHAVE_MENU -DHAVE_RGUI -DHAVE_ZLIB -DHAVE_RPNG -DINLINE=inline -DHAVE_THREADS -D__LIBRETRO__ -DHAVE_RSOUND -DHAVE_NETPLAY -DHAVE_NETWORKING -DRARCH_INTERNAL -DHAVE_FILTERS_BUILTIN -DHAVE_GLUI -DHAVE_XMB -std=gnu99 -DHAVE_LIBRETRODB -DHAVE_STB_FONT
LOCAL_CFLAGS += -DHAVE_7ZIP
ifeq ($(NDK_DEBUG),1)

View File

@ -1,9 +1,12 @@
#include <file/file_extract.h>
#include <file/file_path.h>
#include <stdio.h>
#include <string.h>
#include <file/file_extract.h>
#include <file/file_path.h>
#include <retro_assert.h>
#include <retro_miscellaneous.h>
#include "../native/com_retroarch_browser_NativeInterface.h"
//#define VERBOSE_LOG

View File

@ -11,7 +11,7 @@
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
# Project target.
target=android-21
target=android-22
android.library.reference.1=libs/appcompat
android.library=false
android.library.reference.2=libs/googleplay

View File

@ -20,12 +20,10 @@ To build libretro cores:
TARGET := vba_next_libretro.dylib
fpic := -fPIC
SHARED := -dynamiclib
ENDIANNESS_DEFINES = -DLSB_FIRST
else ifeq ($(platform), ios)
TARGET := vba_next_libretro.dylib
fpic := -fPIC
SHARED := -dynamiclib
ENDIANNESS_DEFINES = -DLSB_FIRST
sysroot = -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk/
CC = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -arch armv7 $(sysroot)

View File

@ -30,20 +30,20 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.1</string>
<string>1.2.2</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.1</string>
<string>1.2.2</string>
<key>LSMinimumSystemVersion</key>
<string>${MACOSX_DEPLOYMENT_TARGET}</string>
<key>NSHighResolutionCapable</key>
<true/>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2015 RetroArch. All rights reserved.</string>
<key>NSMainNibFile</key>
<string>MainMenu</string>
<key>NSPrincipalClass</key>
<string>RApplication</string>
<key>NSHighResolutionCapable</key>
<true/>
</dict>
</plist>

View File

@ -1,14 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.03">
<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="7.10">
<data>
<int key="IBDocument.SystemTarget">1050</int>
<string key="IBDocument.SystemVersion">9L31a</string>
<string key="IBDocument.InterfaceBuilderVersion">680</string>
<string key="IBDocument.AppKitVersion">949.54</string>
<string key="IBDocument.HIToolboxVersion">353.00</string>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<string key="IBDocument.SystemVersion">12F45</string>
<string key="IBDocument.InterfaceBuilderVersion">3084</string>
<string key="IBDocument.AppKitVersion">1187.40</string>
<string key="IBDocument.HIToolboxVersion">626.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="NS.object.0">3084</string>
</object>
<object class="NSArray" key="IBDocument.IntegratedClassDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
<integer value="57"/>
<string>NSCustomObject</string>
<string>NSMenu</string>
<string>NSMenuItem</string>
<string>NSView</string>
<string>NSWindowTemplate</string>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
@ -16,7 +24,7 @@
</object>
<object class="NSMutableDictionary" key="IBDocument.Metadata">
<string key="NS.key.0">PluginDependencyRecalculationVersion</string>
<integer value="1" key="NS.object.0" id="9"/>
<integer value="1" key="NS.object.0"/>
</object>
<object class="NSMutableArray" key="IBDocument.RootObjects" id="1048">
<bool key="EncodedWithXMLCoder">YES</bool>
@ -652,201 +660,49 @@
<string key="NSWindowTitle">RetroArch</string>
<string key="NSWindowClass">NSWindow</string>
<nil key="NSViewClass"/>
<string key="NSWindowContentMaxSize">{3.40282e+38, 3.40282e+38}</string>
<nil key="NSUserInterfaceItemIdentifier"/>
<object class="NSView" key="NSWindowView" id="439893737">
<nil key="NSNextResponder"/>
<reference key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<string key="NSFrameSize">{480, 360}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
</object>
<string key="NSScreenRect">{{0, 0}, {2560, 1418}}</string>
<string key="NSMaxSize">{3.40282e+38, 3.40282e+38}</string>
<string key="NSMaxSize">{10000000000000, 10000000000000}</string>
<bool key="NSWindowIsRestorable">YES</bool>
</object>
<object class="NSCustomObject" id="976324537">
<string key="NSClassName">RetroArch</string>
</object>
<object class="NSWindowTemplate" id="361653618">
<int key="NSWindowStyleMask">31</int>
<int key="NSWindowBacking">2</int>
<string key="NSWindowRect">{{272, 172}, {276, 89}}</string>
<int key="NSWTFlags">-1535638528</int>
<string key="NSWindowTitle">Window</string>
<string key="NSWindowClass">NSPanel</string>
<nil key="NSViewClass"/>
<string key="NSWindowContentMaxSize">{3.40282e+38, 3.40282e+38}</string>
<object class="NSView" key="NSWindowView" id="327272550">
<nil key="NSNextResponder"/>
<int key="NSvFlags">256</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSTextField" id="981013832">
<reference key="NSNextResponder" ref="327272550"/>
<int key="NSvFlags">268</int>
<string key="NSFrame">{{18, 72}, {240, 17}}</string>
<reference key="NSSuperview" ref="327272550"/>
<reference key="NSNextKeyView" ref="481701893"/>
<bool key="NSEnabled">YES</bool>
<object class="NSTextFieldCell" key="NSCell" id="45342161">
<int key="NSCellFlags">68157504</int>
<int key="NSCellFlags2">138413056</int>
<string key="NSContents">Select Core</string>
<object class="NSFont" key="NSSupport" id="698260743">
<string key="NSName">LucidaGrande</string>
<double key="NSSize">1.300000e+01</double>
<int key="NSfFlags">1044</int>
</object>
<reference key="NSControlView" ref="981013832"/>
<bool key="NSDrawsBackground">YES</bool>
<object class="NSColor" key="NSBackgroundColor">
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">controlColor</string>
<object class="NSColor" key="NSColor" id="962906968">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC42NjY2NjY2OQA</bytes>
</object>
</object>
<object class="NSColor" key="NSTextColor" id="1062340437">
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">controlTextColor</string>
<object class="NSColor" key="NSColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MAA</bytes>
</object>
</object>
</object>
</object>
<object class="NSComboBox" id="481701893">
<reference key="NSNextResponder" ref="327272550"/>
<int key="NSvFlags">268</int>
<string key="NSFrame">{{21, 45}, {239, 26}}</string>
<reference key="NSSuperview" ref="327272550"/>
<reference key="NSNextKeyView" ref="59737118"/>
<int key="NSTag">1</int>
<bool key="NSEnabled">YES</bool>
<object class="NSComboBoxCell" key="NSCell" id="50876060">
<int key="NSCellFlags">74448961</int>
<int key="NSCellFlags2">268436480</int>
<string key="NSContents"/>
<reference key="NSSupport" ref="698260743"/>
<reference key="NSControlView" ref="481701893"/>
<bool key="NSDrawsBackground">YES</bool>
<object class="NSColor" key="NSBackgroundColor">
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">textBackgroundColor</string>
<object class="NSColor" key="NSColor" id="67566624">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
</object>
</object>
<reference key="NSTextColor" ref="1062340437"/>
<int key="NSVisibleItemCount">5</int>
<bool key="NSHasVerticalScroller">YES</bool>
<reference key="NSDelegate" ref="481701893"/>
<object class="NSComboTableView" key="NSTableView" id="845451530">
<reference key="NSNextResponder"/>
<int key="NSvFlags">274</int>
<string key="NSFrameSize">{15, 0}</string>
<reference key="NSSuperview"/>
<reference key="NSWindow"/>
<bool key="NSEnabled">YES</bool>
<object class="NSMutableArray" key="NSTableColumns">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSTableColumn">
<double key="NSWidth">1.200000e+01</double>
<double key="NSMinWidth">1.000000e+01</double>
<double key="NSMaxWidth">1.000000e+03</double>
<object class="NSTableHeaderCell" key="NSHeaderCell">
<int key="NSCellFlags">75497472</int>
<int key="NSCellFlags2">0</int>
<string key="NSContents"/>
<object class="NSFont" key="NSSupport">
<string key="NSName">LucidaGrande</string>
<double key="NSSize">1.200000e+01</double>
<int key="NSfFlags">16</int>
</object>
<object class="NSColor" key="NSBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC4zMzMzMzI5OQA</bytes>
</object>
<reference key="NSTextColor" ref="67566624"/>
</object>
<object class="NSTextFieldCell" key="NSDataCell">
<int key="NSCellFlags">338690112</int>
<int key="NSCellFlags2">268436480</int>
<reference key="NSSupport" ref="698260743"/>
<reference key="NSControlView" ref="845451530"/>
<bool key="NSDrawsBackground">YES</bool>
<object class="NSColor" key="NSBackgroundColor" id="170588361">
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">controlBackgroundColor</string>
<reference key="NSColor" ref="962906968"/>
</object>
<reference key="NSTextColor" ref="1062340437"/>
</object>
<int key="NSResizingMask">3</int>
<bool key="NSIsResizeable">YES</bool>
<reference key="NSTableView" ref="845451530"/>
</object>
</object>
<double key="NSIntercellSpacingWidth">3.000000e+00</double>
<double key="NSIntercellSpacingHeight">2.000000e+00</double>
<reference key="NSBackgroundColor" ref="170588361"/>
<object class="NSColor" key="NSGridColor">
<int key="NSColorSpace">6</int>
<string key="NSCatalogName">System</string>
<string key="NSColorName">gridColor</string>
<object class="NSColor" key="NSColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MC41AA</bytes>
</object>
</object>
<double key="NSRowHeight">1.900000e+01</double>
<string key="NSAction">tableViewAction:</string>
<int key="NSTvFlags">-767524864</int>
<reference key="NSDelegate" ref="50876060"/>
<reference key="NSDataSource" ref="50876060"/>
<reference key="NSTarget" ref="50876060"/>
<int key="NSColumnAutoresizingStyle">1</int>
<int key="NSDraggingSourceMaskForLocal">15</int>
<int key="NSDraggingSourceMaskForNonLocal">0</int>
<bool key="NSAllowsTypeSelect">YES</bool>
</object>
</object>
</object>
<object class="NSButton" id="59737118">
<reference key="NSNextResponder" ref="327272550"/>
<int key="NSvFlags">268</int>
<string key="NSFrame">{{180, 13}, {82, 32}}</string>
<reference key="NSSuperview" ref="327272550"/>
<bool key="NSEnabled">YES</bool>
<object class="NSButtonCell" key="NSCell" id="404714727">
<int key="NSCellFlags">67108864</int>
<int key="NSCellFlags2">134217728</int>
<string key="NSContents">OK</string>
<reference key="NSSupport" ref="698260743"/>
<reference key="NSControlView" ref="59737118"/>
<int key="NSButtonFlags">-2038284288</int>
<int key="NSButtonFlags2">129</int>
<string key="NSAlternateContents"/>
<string type="base64-UTF8" key="NSKeyEquivalent">DQ</string>
<int key="NSPeriodicDelay">200</int>
<int key="NSPeriodicInterval">25</int>
</object>
</object>
</object>
<string key="NSFrameSize">{276, 89}</string>
<reference key="NSNextKeyView" ref="981013832"/>
</object>
<string key="NSScreenRect">{{0, 0}, {2560, 1418}}</string>
<string key="NSMaxSize">{3.40282e+38, 3.40282e+38}</string>
</object>
</object>
<object class="IBObjectContainer" key="IBDocument.Objects">
<object class="NSMutableArray" key="connectionRecords">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">terminate:</string>
<reference key="source" ref="1050"/>
<reference key="destination" ref="632727374"/>
</object>
<int key="connectionID">449</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">orderFrontStandardAboutPanel:</string>
<reference key="source" ref="1021"/>
<reference key="destination" ref="238522557"/>
</object>
<int key="connectionID">142</int>
</object>
<object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">delegate</string>
<reference key="source" ref="1021"/>
<reference key="destination" ref="976324537"/>
</object>
<int key="connectionID">495</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">performMiniaturize:</string>
@ -871,14 +727,6 @@
</object>
<int key="connectionID">127</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">orderFrontStandardAboutPanel:</string>
<reference key="source" ref="1021"/>
<reference key="destination" ref="238522557"/>
</object>
<int key="connectionID">142</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">performClose:</string>
@ -919,14 +767,6 @@
</object>
<int key="connectionID">370</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">terminate:</string>
<reference key="source" ref="1050"/>
<reference key="destination" ref="632727374"/>
</object>
<int key="connectionID">449</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">showHelp:</string>
@ -936,12 +776,20 @@
<int key="connectionID">493</int>
</object>
<object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">delegate</string>
<reference key="source" ref="1021"/>
<reference key="destination" ref="976324537"/>
<object class="IBActionConnection" key="connection">
<string key="label">toggleFullScreen:</string>
<reference key="source" ref="1014"/>
<reference key="destination" ref="1065388702"/>
</object>
<int key="connectionID">495</int>
<int key="connectionID">593</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">openDocument:</string>
<reference key="source" ref="1014"/>
<reference key="destination" ref="733060596"/>
</object>
<int key="connectionID">657</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
@ -975,14 +823,6 @@
</object>
<int key="connectionID">591</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">toggleFullScreen:</string>
<reference key="source" ref="1014"/>
<reference key="destination" ref="1065388702"/>
</object>
<int key="connectionID">593</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">basicEvent:</string>
@ -1127,14 +967,6 @@
</object>
<int key="connectionID">655</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">openDocument:</string>
<reference key="source" ref="1014"/>
<reference key="destination" ref="733060596"/>
</object>
<int key="connectionID">657</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">basicEvent:</string>
@ -1151,6 +983,14 @@
</object>
<int key="connectionID">664</int>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">openCore:</string>
<reference key="source" ref="976324537"/>
<reference key="destination" ref="722745758"/>
</object>
<int key="connectionID">665</int>
</object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
@ -1167,7 +1007,7 @@
<int key="objectID">-2</int>
<reference key="object" ref="1021"/>
<reference key="parent" ref="0"/>
<string type="base64-UTF8" key="objectName">RmlsZSdzIE93bmVyA</string>
<string key="objectName">File's Owner</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">-1</int>
@ -1227,11 +1067,11 @@
<reference key="object" ref="720053764"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="722745758"/>
<reference ref="1025936716"/>
<reference ref="776162233"/>
<reference ref="425164168"/>
<reference ref="733060596"/>
<reference ref="722745758"/>
</object>
<reference key="parent" ref="379814623"/>
</object>
@ -1411,68 +1251,6 @@
</object>
<reference key="parent" ref="265357942"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">557</int>
<reference key="object" ref="361653618"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="327272550"/>
</object>
<reference key="parent" ref="0"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">558</int>
<reference key="object" ref="327272550"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="981013832"/>
<reference ref="59737118"/>
<reference ref="481701893"/>
</object>
<reference key="parent" ref="361653618"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">559</int>
<reference key="object" ref="481701893"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="50876060"/>
</object>
<reference key="parent" ref="327272550"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">560</int>
<reference key="object" ref="981013832"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="45342161"/>
</object>
<reference key="parent" ref="327272550"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">567</int>
<reference key="object" ref="45342161"/>
<reference key="parent" ref="981013832"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">568</int>
<reference key="object" ref="50876060"/>
<reference key="parent" ref="481701893"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">570</int>
<reference key="object" ref="59737118"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="404714727"/>
</object>
<reference key="parent" ref="327272550"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">571</int>
<reference key="object" ref="404714727"/>
<reference key="parent" ref="59737118"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">585</int>
<reference key="object" ref="1225315"/>
@ -1757,13 +1535,12 @@
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSMutableArray" key="dict.sortedKeys">
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>-1.IBPluginDependency</string>
<string>-2.IBPluginDependency</string>
<string>-3.IBPluginDependency</string>
<string>124.IBPluginDependency</string>
<string>125.IBEditorWindowLastContentRect</string>
<string>125.IBPluginDependency</string>
<string>126.IBPluginDependency</string>
<string>130.IBPluginDependency</string>
@ -1778,50 +1555,34 @@
<string>23.IBPluginDependency</string>
<string>236.IBPluginDependency</string>
<string>239.IBPluginDependency</string>
<string>24.IBEditorWindowLastContentRect</string>
<string>24.IBPluginDependency</string>
<string>29.IBEditorWindowLastContentRect</string>
<string>29.IBPluginDependency</string>
<string>371.IBEditorWindowLastContentRect</string>
<string>371.IBPluginDependency</string>
<string>371.IBWindowTemplateEditedContentRect</string>
<string>371.NSWindowTemplate.visibleAtLaunch</string>
<string>372.IBPluginDependency</string>
<string>490.IBPluginDependency</string>
<string>491.IBEditorWindowLastContentRect</string>
<string>491.IBPluginDependency</string>
<string>492.IBPluginDependency</string>
<string>494.IBPluginDependency</string>
<string>5.IBPluginDependency</string>
<string>545.IBPluginDependency</string>
<string>546.IBEditorWindowLastContentRect</string>
<string>546.IBPluginDependency</string>
<string>549.IBPluginDependency</string>
<string>551.IBPluginDependency</string>
<string>557.IBEditorWindowLastContentRect</string>
<string>557.IBPluginDependency</string>
<string>557.IBWindowTemplateEditedContentRect</string>
<string>557.NSWindowTemplate.visibleAtLaunch</string>
<string>558.IBPluginDependency</string>
<string>559.IBPluginDependency</string>
<string>559.IBViewBoundsToFrameTransform</string>
<string>56.IBPluginDependency</string>
<string>560.IBPluginDependency</string>
<string>567.IBPluginDependency</string>
<string>568.IBPluginDependency</string>
<string>57.IBEditorWindowLastContentRect</string>
<string>57.IBPluginDependency</string>
<string>570.IBPluginDependency</string>
<string>571.IBPluginDependency</string>
<string>58.IBPluginDependency</string>
<string>585.IBPluginDependency</string>
<string>586.IBEditorWindowLastContentRect</string>
<string>586.IBPluginDependency</string>
<string>587.IBPluginDependency</string>
<string>592.IBPluginDependency</string>
<string>598.IBEditorWindowLastContentRect</string>
<string>603.IBEditorWindowLastContentRect</string>
<string>613.IBEditorWindowLastContentRect</string>
<string>597.IBPluginDependency</string>
<string>598.IBPluginDependency</string>
<string>602.IBPluginDependency</string>
<string>603.IBPluginDependency</string>
<string>612.IBPluginDependency</string>
<string>613.IBPluginDependency</string>
<string>614.IBPluginDependency</string>
<string>616.IBPluginDependency</string>
<string>618.IBPluginDependency</string>
@ -1829,7 +1590,8 @@
<string>622.IBPluginDependency</string>
<string>624.IBPluginDependency</string>
<string>626.IBPluginDependency</string>
<string>630.IBEditorWindowLastContentRect</string>
<string>629.IBPluginDependency</string>
<string>630.IBPluginDependency</string>
<string>633.IBPluginDependency</string>
<string>635.IBPluginDependency</string>
<string>637.IBPluginDependency</string>
@ -1844,24 +1606,21 @@
<string>656.IBPluginDependency</string>
<string>658.IBPluginDependency</string>
<string>660.IBPluginDependency</string>
<string>661.IBEditorWindowLastContentRect</string>
<string>661.IBPluginDependency</string>
<string>663.IBPluginDependency</string>
<string>72.IBPluginDependency</string>
<string>73.IBPluginDependency</string>
<string>79.IBPluginDependency</string>
<string>81.IBEditorWindowLastContentRect</string>
<string>81.IBPluginDependency</string>
<string>83.IBPluginDependency</string>
<string>92.IBPluginDependency</string>
</object>
<object class="NSMutableArray" key="dict.values">
<object class="NSArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{782, 496}, {143, 23}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@ -1876,52 +1635,36 @@
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{785, 425}, {284, 133}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{497, 558}, {420, 20}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{507, 199}, {480, 360}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{507, 199}, {480, 360}}</string>
<reference ref="9"/>
<string>{{438, 199}, {480, 360}}</string>
<integer value="1"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{856, 535}, {174, 23}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{642, 395}, {192, 163}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{329, 640}, {276, 89}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{329, 640}, {276, 89}}</string>
<boolean value="NO"/>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<object class="NSAffineTransform">
<bytes key="NSTransformStruct">P4AAAL+AAABBoAAAwooAAA</bytes>
</object>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{509, 405}, {206, 153}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{730, 535}, {151, 23}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{834, 455}, {144, 63}}</string>
<string>{{834, 495}, {185, 23}}</string>
<string>{{834, 455}, {123, 43}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@ -1929,7 +1672,6 @@
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{907, 316}, {79, 203}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@ -1944,13 +1686,11 @@
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{834, 535}, {137, 23}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>{{600, 465}, {182, 93}}</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
@ -1958,29 +1698,112 @@
</object>
<object class="NSMutableDictionary" key="unlocalizedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<reference key="dict.sortedKeys" ref="0"/>
<reference key="dict.values" ref="0"/>
</object>
<nil key="activeLocalization"/>
<object class="NSMutableDictionary" key="localizations">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<reference key="dict.sortedKeys" ref="0"/>
<reference key="dict.values" ref="0"/>
</object>
<nil key="sourceID"/>
<int key="maxID">664</int>
<int key="maxID">665</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBPartialClassDescription">
<string key="className">RetroArch</string>
<string key="superclassName">NSObject</string>
<object class="NSMutableDictionary" key="actions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>basicEvent:</string>
<string>openCore:</string>
<string>showCoresDirectory:</string>
<string>showPreferences:</string>
</object>
<object class="NSArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>id</string>
<string>id</string>
<string>id</string>
<string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="actionInfosByName">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>basicEvent:</string>
<string>openCore:</string>
<string>showCoresDirectory:</string>
<string>showPreferences:</string>
</object>
<object class="NSArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBActionInfo">
<string key="name">basicEvent:</string>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
<string key="name">openCore:</string>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
<string key="name">showCoresDirectory:</string>
<string key="candidateClassName">id</string>
</object>
<object class="IBActionInfo">
<string key="name">showPreferences:</string>
<string key="candidateClassName">id</string>
</object>
</object>
</object>
<object class="NSMutableDictionary" key="outlets">
<string key="NS.key.0">window</string>
<string key="NS.object.0">NSWindow</string>
</object>
<object class="NSMutableDictionary" key="toOneOutletInfosByName">
<string key="NS.key.0">window</string>
<object class="IBToOneOutletInfo" key="NS.object.0">
<string key="name">window</string>
<string key="candidateClassName">NSWindow</string>
</object>
</object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/RetroArch.h</string>
</object>
</object>
</object>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes"/>
<int key="IBDocument.localizationMode">0</int>
<string key="IBDocument.LastKnownRelativeProjectPath">../RetroArch.xcodeproj</string>
<string key="IBDocument.TargetRuntimeIdentifier">IBCocoaFramework</string>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.macosx</string>
<integer value="1050" key="NS.object.0"/>
</object>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3</string>
<integer value="3000" key="NS.object.0"/>
</object>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
<int key="IBDocument.defaultPropertyAccessControl">3</int>
<object class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>NSMenuCheckmark</string>
<string>NSMenuMixedState</string>
</object>
<object class="NSArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>{11, 11}</string>
<string>{10, 3}</string>
</object>
</object>
</data>
</archive>

View File

@ -282,7 +282,7 @@
ONLY_ACTIVE_ARCH = YES;
OTHER_CFLAGS = (
"-DHAVE_GRIFFIN",
"-DHAVE_CORETEXT",
"-DHAVE_STB_FONT",
"-DHAVE_IOHIDMANAGER",
"-DHAVE_RGUI",
"-DHAVE_MENU",
@ -348,6 +348,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_GRIFFIN",
"-DHAVE_STB_FONT",
"-DHAVE_IOHIDMANAGER",
"-DHAVE_RGUI",
"-DHAVE_MENU",

View File

@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeExtensions</key>
<array>
<string>*</string>
</array>
<key>CFBundleTypeName</key>
<string>All Files</string>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
</dict>
</array>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIconFile</key>
<string>retroarch</string>
<key>CFBundleIdentifier</key>
<string>libretro.${PRODUCT_NAME:rfc1034identifier}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.2.2</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.2.2</string>
<key>LSMinimumSystemVersion</key>
<string>${MACOSX_DEPLOYMENT_TARGET}</string>
<key>NSHighResolutionCapable</key>
<true/>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2015 RetroArch. All rights reserved.</string>
<key>NSMainNibFile</key>
<string>MainMenu</string>
<key>NSPrincipalClass</key>
<string>RApplication</string>
</dict>
</plist>

View File

@ -8,6 +8,20 @@
/* Begin PBXBuildFile section */
1DDD58160DA1D0A300B32029 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 1DDD58140DA1D0A300B32029 /* MainMenu.xib */; };
500845251B89300700CE6073 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; };
500845261B89300700CE6073 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 1DDD58140DA1D0A300B32029 /* MainMenu.xib */; };
500845271B89300700CE6073 /* retroarch.icns in Resources */ = {isa = PBXBuildFile; fileRef = 84DD5EB71A89F1C7007336C1 /* retroarch.icns */; };
500845291B89300700CE6073 /* griffin_objc.m in Sources */ = {isa = PBXBuildFile; fileRef = 509F0C9C1AA23AFC00619ECC /* griffin_objc.m */; };
5008452A1B89300700CE6073 /* griffin.c in Sources */ = {isa = PBXBuildFile; fileRef = 840222FB1A889EE2009AB261 /* griffin.c */; };
5008452C1B89300700CE6073 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 5061C8A31AE47E510080AE14 /* libz.dylib */; };
5008452D1B89300700CE6073 /* CoreAudio.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EA81A89E4BE007336C1 /* CoreAudio.framework */; };
5008452E1B89300700CE6073 /* AudioUnit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB21A89E6C0007336C1 /* AudioUnit.framework */; };
5008452F1B89300700CE6073 /* Cg.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB01A89E664007336C1 /* Cg.framework */; settings = {ATTRIBUTES = (Required, ); }; };
500845301B89300700CE6073 /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EAC1A89E5B4007336C1 /* OpenGL.framework */; };
500845311B89300700CE6073 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EA61A89E406007336C1 /* CoreLocation.framework */; };
500845321B89300700CE6073 /* AppKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29B97324FDCFA39411CA2CEA /* AppKit.framework */; };
500845331B89300700CE6073 /* CoreVideo.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5E9E1A88E45B007336C1 /* CoreVideo.framework */; };
500845341B89300700CE6073 /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB41A89E737007336C1 /* IOKit.framework */; };
5061C8A41AE47E510080AE14 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 5061C8A31AE47E510080AE14 /* libz.dylib */; };
509F0C9D1AA23AFC00619ECC /* griffin_objc.m in Sources */ = {isa = PBXBuildFile; fileRef = 509F0C9C1AA23AFC00619ECC /* griffin_objc.m */; };
840222FC1A889EE2009AB261 /* griffin.c in Sources */ = {isa = PBXBuildFile; fileRef = 840222FB1A889EE2009AB261 /* griffin.c */; };
@ -18,12 +32,29 @@
84DD5EAD1A89E5B4007336C1 /* OpenGL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EAC1A89E5B4007336C1 /* OpenGL.framework */; };
84DD5EB31A89E6C0007336C1 /* AudioUnit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB21A89E6C0007336C1 /* AudioUnit.framework */; };
84DD5EB51A89E737007336C1 /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB41A89E737007336C1 /* IOKit.framework */; };
84DD5EB61A89E76C007336C1 /* Cg.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 84DD5EB01A89E664007336C1 /* Cg.framework */; };
84DD5EB81A89F1C7007336C1 /* retroarch.icns in Resources */ = {isa = PBXBuildFile; fileRef = 84DD5EB71A89F1C7007336C1 /* retroarch.icns */; };
8D11072B0486CEB800E47090 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 089C165CFE840E0CC02AAC07 /* InfoPlist.strings */; };
/* End PBXBuildFile section */
/* Begin PBXCopyFilesBuildPhase section */
500845351B89300700CE6073 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 7;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
500845361B89300700CE6073 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
dstPath = "";
dstSubfolderSpec = 7;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
841CBB831A8A33B60066E9F1 /* CopyFiles */ = {
isa = PBXCopyFilesBuildPhase;
buildActionMask = 2147483647;
@ -48,6 +79,8 @@
089C165DFE840E0CC02AAC07 /* InfoPlist.strings */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.strings; name = InfoPlist.strings; path = OSX/en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
1DDD58150DA1D0A300B32029 /* MainMenu.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = MainMenu.xib; path = OSX/en.lproj/MainMenu.xib; sourceTree = "<group>"; };
29B97324FDCFA39411CA2CEA /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = "<absolute>"; };
5008453A1B89300700CE6073 /* RetroArch copy.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "RetroArch copy.app"; sourceTree = BUILT_PRODUCTS_DIR; };
5008453B1B89300700CE6073 /* RetroArch copy-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "RetroArch copy-Info.plist"; path = "/Users/squarepusher/libretro-super/retroarch/apple/RetroArch copy-Info.plist"; sourceTree = "<absolute>"; };
5061C8A31AE47E510080AE14 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; };
509F0C9C1AA23AFC00619ECC /* griffin_objc.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = griffin_objc.m; path = ../griffin/griffin_objc.m; sourceTree = "<group>"; };
840222FB1A889EE2009AB261 /* griffin.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = griffin.c; path = ../griffin/griffin.c; sourceTree = SOURCE_ROOT; };
@ -64,6 +97,22 @@
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
5008452B1B89300700CE6073 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
5008452C1B89300700CE6073 /* libz.dylib in Frameworks */,
5008452D1B89300700CE6073 /* CoreAudio.framework in Frameworks */,
5008452E1B89300700CE6073 /* AudioUnit.framework in Frameworks */,
5008452F1B89300700CE6073 /* Cg.framework in Frameworks */,
500845301B89300700CE6073 /* OpenGL.framework in Frameworks */,
500845311B89300700CE6073 /* CoreLocation.framework in Frameworks */,
500845321B89300700CE6073 /* AppKit.framework in Frameworks */,
500845331B89300700CE6073 /* CoreVideo.framework in Frameworks */,
500845341B89300700CE6073 /* IOKit.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
8D11072E0486CEB800E47090 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
@ -71,7 +120,6 @@
5061C8A41AE47E510080AE14 /* libz.dylib in Frameworks */,
84DD5EA91A89E4BE007336C1 /* CoreAudio.framework in Frameworks */,
84DD5EB31A89E6C0007336C1 /* AudioUnit.framework in Frameworks */,
84DD5EB61A89E76C007336C1 /* Cg.framework in Frameworks */,
84DD5EAD1A89E5B4007336C1 /* OpenGL.framework in Frameworks */,
84DD5EA71A89E406007336C1 /* CoreLocation.framework in Frameworks */,
84DD5EA31A89E2AA007336C1 /* AppKit.framework in Frameworks */,
@ -116,6 +164,7 @@
isa = PBXGroup;
children = (
8D1107320486CEB800E47090 /* RetroArch.app */,
5008453A1B89300700CE6073 /* RetroArch copy.app */,
);
name = Products;
sourceTree = "<group>";
@ -130,6 +179,7 @@
29B97317FDCFA39411CA2CEA /* Resources */,
29B97323FDCFA39411CA2CEA /* Frameworks */,
19C28FACFE9D520D11CA2CBB /* Products */,
5008453B1B89300700CE6073 /* RetroArch copy-Info.plist */,
);
indentWidth = 3;
name = RetroArch;
@ -184,6 +234,26 @@
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
500845231B89300700CE6073 /* RetroArch Cg */ = {
isa = PBXNativeTarget;
buildConfigurationList = 500845371B89300700CE6073 /* Build configuration list for PBXNativeTarget "RetroArch Cg" */;
buildPhases = (
500845241B89300700CE6073 /* Resources */,
500845281B89300700CE6073 /* Sources */,
5008452B1B89300700CE6073 /* Frameworks */,
500845351B89300700CE6073 /* CopyFiles */,
500845361B89300700CE6073 /* CopyFiles */,
);
buildRules = (
);
dependencies = (
);
name = "RetroArch Cg";
productInstallPath = "$(HOME)/Applications";
productName = RetroArch;
productReference = 5008453A1B89300700CE6073 /* RetroArch copy.app */;
productType = "com.apple.product-type.application";
};
8D1107260486CEB800E47090 /* RetroArch */ = {
isa = PBXNativeTarget;
buildConfigurationList = C01FCF4A08A954540054247B /* Build configuration list for PBXNativeTarget "RetroArch" */;
@ -223,12 +293,23 @@
projectDirPath = "";
projectRoot = "";
targets = (
500845231B89300700CE6073 /* RetroArch Cg */,
8D1107260486CEB800E47090 /* RetroArch */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
500845241B89300700CE6073 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
500845251B89300700CE6073 /* InfoPlist.strings in Resources */,
500845261B89300700CE6073 /* MainMenu.xib in Resources */,
500845271B89300700CE6073 /* retroarch.icns in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
8D1107290486CEB800E47090 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
@ -242,6 +323,15 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
500845281B89300700CE6073 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
500845291B89300700CE6073 /* griffin_objc.m in Sources */,
5008452A1B89300700CE6073 /* griffin.c in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
8D11072C0486CEB800E47090 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
@ -273,6 +363,128 @@
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
500845381B89300700CE6073 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = YES;
COPY_PHASE_STRIP = NO;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(LOCAL_LIBRARY_DIR)/Frameworks",
);
GCC_DYNAMIC_NO_PIC = NO;
GCC_ENABLE_FIX_AND_CONTINUE = YES;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
HEADER_SEARCH_PATHS = (
"$(SRCROOT)/..",
"$(SRCROOT)/../gfx/inc",
"$(SRCROOT)/../libretro-common/include",
);
INFOPLIST_FILE = "RetroArch copy-Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
MACOSX_DEPLOYMENT_TARGET = 10.5;
OTHER_CFLAGS = (
"-DHAVE_GRIFFIN",
"-DHAVE_IMAGEVIEWER",
"-DHAVE_CORETEXT",
"-DHAVE_IOHIDMANAGER",
"-DHAVE_CORELOCATION",
"-DHAVE_RGUI",
"-DHAVE_MENU",
"-DOSX",
"-DHAVE_OPENGL",
"-DHAVE_FBO",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-D__LIBRETRO__",
"-DWANT_RPNG",
"-DHAVE_COREAUDIO",
"-DHAVE_DYNAMIC",
"-DHAVE_OVERLAY",
"-DHAVE_ZLIB",
"-DHAVE_RPNG",
"-DHAVE_COCOA",
"-DHAVE_MAIN",
"-DSINC_LOWER_QUALITY",
"-DHAVE_NETPLAY",
"-DHAVE_NETWORKING",
"-DRARCH_INTERNAL",
"-DHAVE_THREADS",
"-DHAVE_DYLIB",
"-DHAVE_CG",
"-DHAVE_7ZIP",
"-DHAVE_GLUI",
"-DHAVE_HID",
"-DHAVE_XMB",
"-DHAVE_LIBRETRODB",
);
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = YES;
PRODUCT_NAME = "RetroArch copy";
};
name = Debug;
};
500845391B89300700CE6073 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(LOCAL_LIBRARY_DIR)/Frameworks",
);
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
HEADER_SEARCH_PATHS = (
"$(SRCROOT)/..",
"$(SRCROOT)/../gfx/inc",
"$(SRCROOT)/../libretro-common/include",
);
INFOPLIST_FILE = "RetroArch copy-Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
MACOSX_DEPLOYMENT_TARGET = 10.5;
OTHER_CFLAGS = (
"-DHAVE_GRIFFIN",
"-DHAVE_IMAGEVIEWER",
"-DHAVE_IOHIDMANAGER",
"-DHAVE_CORETEXT",
"-DHAVE_CORELOCATION",
"-DHAVE_RGUI",
"-DHAVE_MENU",
"-DOSX",
"-DHAVE_OPENGL",
"-DHAVE_FBO",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-D__LIBRETRO__",
"-DWANT_RPNG",
"-DHAVE_COREAUDIO",
"-DHAVE_DYNAMIC",
"-DHAVE_OVERLAY",
"-DHAVE_ZLIB",
"-DHAVE_RPNG",
"-DHAVE_COCOA",
"-DHAVE_MAIN",
"-DSINC_LOWER_QUALITY",
"-DHAVE_NETPLAY",
"-DHAVE_NETWORKING",
"-DRARCH_INTERNAL",
"-DHAVE_THREADS",
"-DHAVE_DYLIB",
"-DHAVE_CG",
"-DHAVE_7ZIP",
"-DHAVE_GLUI",
"-DHAVE_HID",
"-DHAVE_XMB",
"-DHAVE_LIBRETRODB",
);
PRECOMPS_INCLUDE_HEADERS_FROM_BUILT_PRODUCTS_DIR = YES;
PRODUCT_NAME = "RetroArch copy";
};
name = Release;
};
C01FCF4B08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
@ -323,7 +535,6 @@
"-DRARCH_INTERNAL",
"-DHAVE_THREADS",
"-DHAVE_DYLIB",
"-DHAVE_CG",
"-DHAVE_7ZIP",
"-DHAVE_GLUI",
"-DHAVE_HID",
@ -383,7 +594,6 @@
"-DRARCH_INTERNAL",
"-DHAVE_THREADS",
"-DHAVE_DYLIB",
"-DHAVE_CG",
"-DHAVE_7ZIP",
"-DHAVE_GLUI",
"-DHAVE_HID",
@ -424,6 +634,15 @@
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
500845371B89300700CE6073 /* Build configuration list for PBXNativeTarget "RetroArch Cg" */ = {
isa = XCConfigurationList;
buildConfigurations = (
500845381B89300700CE6073 /* Debug */,
500845391B89300700CE6073 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Debug;
};
C01FCF4A08A954540054247B /* Build configuration list for PBXNativeTarget "RetroArch" */ = {
isa = XCConfigurationList;
buildConfigurations = (

View File

@ -17,7 +17,7 @@ ${APPLICATION_NAME}_FILES = $(SRC_DIR)/griffin/griffin.c \
$(SRC_DIR)/audio/drivers_resampler/sinc_neon.S \
$(SRC_DIR)/audio/drivers_resampler/cc_resampler_neon.S
COMMON_FLAGS := -DIOS -DHAVE_GRIFFIN -DHAVE_CORELOCATION -DHAVE_NETPLAY -DHAVE_RGUI -DHAVE_MENU -DHAVE_DYNAMIC -DHAVE_OPENGL -DHAVE_FBO -DHAVE_OPENGLES -DHAVE_OPENGLES2 -DHAVE_GLSL -DINLINE=inline -DLSB_FIRST -DHAVE_THREADS -D__LIBRETRO__ -DRARCH_MOBILE -std=gnu99 -DHAVE_COREAUDIO -DHAVE_FBO -DHAVE_OVERLAY -DHAVE_ZLIB -DWANT_ZLIB -DSINC_LOWER_QUALITY -DRARCH_INTERNAL -DHAVE_FILTERS_BUILTIN -DHAVE_XMB -D_LZMA_UINT32_IS_ULONG -DHAVE_STRL
COMMON_FLAGS := -DIOS -DHAVE_GRIFFIN -DHAVE_CORELOCATION -DHAVE_NETPLAY -DHAVE_RGUI -DHAVE_MENU -DHAVE_DYNAMIC -DHAVE_OPENGL -DHAVE_FBO -DHAVE_OPENGLES -DHAVE_OPENGLES2 -DHAVE_GLSL -DINLINE=inline -DHAVE_THREADS -D__LIBRETRO__ -DRARCH_MOBILE -std=gnu99 -DHAVE_COREAUDIO -DHAVE_FBO -DHAVE_OVERLAY -DHAVE_ZLIB -DWANT_ZLIB -DSINC_LOWER_QUALITY -DRARCH_INTERNAL -DHAVE_FILTERS_BUILTIN -DHAVE_XMB -D_LZMA_UINT32_IS_ULONG -DHAVE_STRL
COMMON_FLAGS += -DHAVE_AVFOUNDATION
COMMON_IOS_FLAGS := -Wno-deprecated-declarations -Wno-error
COMMON_IOS_OBJCFLAGS := -fobjc-arc

View File

@ -496,6 +496,7 @@
ONLY_ACTIVE_ARCH = NO;
OTHER_CFLAGS = (
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -513,7 +514,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",
@ -563,6 +563,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -579,7 +580,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",
@ -602,6 +602,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -618,7 +619,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",
@ -672,6 +672,7 @@
ONLY_ACTIVE_ARCH = NO;
OTHER_CFLAGS = (
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -689,7 +690,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-DHAVE_THREADS",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
@ -733,6 +733,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -750,7 +751,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-DHAVE_THREADS",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
@ -796,6 +796,7 @@
ONLY_ACTIVE_ARCH = NO;
OTHER_CFLAGS = (
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -812,7 +813,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",
@ -865,6 +865,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -881,7 +882,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",
@ -906,6 +906,7 @@
"-DNS_BLOCK_ASSERTIONS=1",
"-DNDEBUG",
"-DHAVE_NETPLAY",
"-DHAVE_CORETEXT",
"-DHAVE_HID",
"-DHAVE_NETWORKING",
"-DHAVE_AVFOUNDATION",
@ -922,7 +923,6 @@
"-DHAVE_OPENGLES2",
"-DHAVE_GLSL",
"-DINLINE=inline",
"-DLSB_FIRST",
"-D__LIBRETRO__",
"-DRARCH_MOBILE",
"-DHAVE_COREAUDIO",

View File

@ -15,16 +15,14 @@
*/
#include <string.h>
#include <string/string_list.h>
#include "audio_driver.h"
#include "audio_monitor.h"
#include "audio_driver.h"
#include "audio_utils.h"
#include "audio_thread_wrapper.h"
#include "../driver.h"
#include "../general.h"
#include "../retroarch.h"
#include "../runloop.h"
#include "../performance.h"
#ifndef AUDIO_BUFFER_FREE_SAMPLES_COUNT
#define AUDIO_BUFFER_FREE_SAMPLES_COUNT (8 * 1024)
@ -118,8 +116,8 @@ static const audio_driver_t *audio_drivers[] = {
#ifdef EMSCRIPTEN
&audio_rwebaudio,
#endif
#ifdef PSP
&audio_psp1,
#if defined(PSP) || defined(VITA)
&audio_psp,
#endif
#ifdef _3DS
&audio_ctr,
@ -601,7 +599,6 @@ bool audio_driver_flush(const int16_t *data, size_t samples)
size_t output_size = sizeof(float);
struct resampler_data src_data = {0};
struct rarch_dsp_data dsp_data = {0};
runloop_t *runloop = rarch_main_get_ptr();
driver_t *driver = driver_get_ptr();
const audio_driver_t *audio = driver ?
(const audio_driver_t*)driver->audio : NULL;
@ -617,7 +614,7 @@ bool audio_driver_flush(const int16_t *data, size_t samples)
driver->recording->push_audio(driver->recording_data, &ffemu_data);
}
if (runloop->is_paused || settings->audio.mute_enable)
if (rarch_main_is_paused() || settings->audio.mute_enable)
return true;
if (!driver->audio_active || !audio_data.data)
return false;
@ -654,7 +651,7 @@ bool audio_driver_flush(const int16_t *data, size_t samples)
audio_driver_readjust_input_rate();
src_data.ratio = audio_data.src_ratio;
if (runloop->is_slowmotion)
if (rarch_main_is_slowmotion())
src_data.ratio *= settings->slowmotion_ratio;
RARCH_PERFORMANCE_INIT(resampler_proc);

View File

@ -88,7 +88,7 @@ extern audio_driver_t audio_coreaudio;
extern audio_driver_t audio_xenon360;
extern audio_driver_t audio_ps3;
extern audio_driver_t audio_gx;
extern audio_driver_t audio_psp1;
extern audio_driver_t audio_psp;
extern audio_driver_t audio_ctr;
extern audio_driver_t audio_rwebaudio;
extern audio_driver_t audio_null;

View File

@ -242,12 +242,15 @@ rarch_dsp_filter_t *rarch_dsp_filter_new(
#if !defined(HAVE_FILTERS_BUILTIN) && defined(HAVE_DYLIB)
fill_pathname_basedir(basedir, filter_config, sizeof(basedir));
plugs = dir_list_new(basedir, EXT_EXECUTABLES, false);
plugs = dir_list_new(basedir, EXT_EXECUTABLES, false, false);
if (!plugs)
goto error;
#endif
#if defined(HAVE_DYLIB) || defined(HAVE_FILTERS_BUILTIN)
if (!append_plugs(dsp, plugs))
goto error;
#endif
if (plugs)
string_list_free(plugs);

View File

@ -56,29 +56,32 @@ static void chorus_process(void *data, struct dspfilter_output *output,
for (i = 0; i < input->frames; i++, out += 2)
{
unsigned delay_int;
float delay_frac, l_a, l_b, r_a, r_b;
float chorus_l, chorus_r;
float in[2] = { out[0], out[1] };
float delay = ch->delay + ch->depth * sin((2.0 * M_PI * ch->lfo_ptr++) / ch->lfo_period);
delay *= ch->input_rate;
if (ch->lfo_ptr >= ch->lfo_period)
ch->lfo_ptr = 0;
unsigned delay_int = (unsigned)delay;
delay_int = (unsigned)delay;
if (delay_int >= CHORUS_MAX_DELAY - 1)
delay_int = CHORUS_MAX_DELAY - 2;
float delay_frac = delay - delay_int;
delay_frac = delay - delay_int;
ch->old[0][ch->old_ptr] = in[0];
ch->old[1][ch->old_ptr] = in[1];
float l_a = ch->old[0][(ch->old_ptr - delay_int - 0) & CHORUS_DELAY_MASK];
float l_b = ch->old[0][(ch->old_ptr - delay_int - 1) & CHORUS_DELAY_MASK];
float r_a = ch->old[1][(ch->old_ptr - delay_int - 0) & CHORUS_DELAY_MASK];
float r_b = ch->old[1][(ch->old_ptr - delay_int - 1) & CHORUS_DELAY_MASK];
l_a = ch->old[0][(ch->old_ptr - delay_int - 0) & CHORUS_DELAY_MASK];
l_b = ch->old[0][(ch->old_ptr - delay_int - 1) & CHORUS_DELAY_MASK];
r_a = ch->old[1][(ch->old_ptr - delay_int - 0) & CHORUS_DELAY_MASK];
r_b = ch->old[1][(ch->old_ptr - delay_int - 1) & CHORUS_DELAY_MASK];
// Lerp introduces aliasing of the chorus component, but doing full polyphase here is probably overkill.
float chorus_l = l_a * (1.0f - delay_frac) + l_b * delay_frac;
float chorus_r = r_a * (1.0f - delay_frac) + r_b * delay_frac;
/* Lerp introduces aliasing of the chorus component, but doing full polyphase here is probably overkill. */
chorus_l = l_a * (1.0f - delay_frac) + l_b * delay_frac;
chorus_r = r_a * (1.0f - delay_frac) + r_b * delay_frac;
out[0] = ch->mix_dry * in[0] + ch->mix_wet * chorus_l;
out[1] = ch->mix_dry * in[1] + ch->mix_wet * chorus_r;
@ -90,11 +93,11 @@ static void chorus_process(void *data, struct dspfilter_output *output,
static void *chorus_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
float delay, depth, lfo_freq, drywet;
struct chorus_data *ch = (struct chorus_data*)calloc(1, sizeof(*ch));
if (!ch)
return NULL;
float delay, depth, lfo_freq, drywet;
config->get_float(userdata, "delay_ms", &delay, 25.0f);
config->get_float(userdata, "depth_ms", &depth, 1.0f);
config->get_float(userdata, "lfo_freq", &lfo_freq, 0.5f);

View File

@ -60,6 +60,7 @@ static void echo_process(void *data, struct dspfilter_output *output,
for (i = 0; i < input->frames; i++, out += 2)
{
float left, right;
float echo_left = 0.0f;
float echo_right = 0.0f;
@ -72,8 +73,8 @@ static void echo_process(void *data, struct dspfilter_output *output,
echo_left *= echo->amp;
echo_right *= echo->amp;
float left = out[0] + echo_left;
float right = out[1] + echo_right;
left = out[0] + echo_left;
right = out[1] + echo_right;
for (c = 0; c < echo->num_channels; c++)
{
@ -94,22 +95,21 @@ static void echo_process(void *data, struct dspfilter_output *output,
static void *echo_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
unsigned i;
struct echo_data *echo = (struct echo_data*)calloc(1, sizeof(*echo));
if (!echo)
return NULL;
unsigned i, channels;
float *delay = NULL, *feedback = NULL;
unsigned num_delay = 0, num_feedback = 0;
static const float default_delay[] = { 200.0f };
static const float default_feedback[] = { 0.5f };
struct echo_data *echo = (struct echo_data*)calloc(1, sizeof(*echo));
if (!echo)
return NULL;
config->get_float_array(userdata, "delay", &delay, &num_delay, default_delay, 1);
config->get_float_array(userdata, "feedback", &feedback, &num_feedback, default_feedback, 1);
config->get_float(userdata, "amp", &echo->amp, 0.2f);
unsigned channels = num_feedback = num_delay = min(num_delay, num_feedback);
channels = num_feedback = num_delay = min(num_delay, num_feedback);
echo->channels = (struct echo_channel*)calloc(channels, sizeof(*echo->channels));
if (!echo->channels)

View File

@ -12,12 +12,14 @@
* You should have received a copy of the GNU General Public License along with RetroArch.
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "dspfilter.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <retro_inline.h>
#include <filters.h>
#include "dspfilter.h"
#include "fft/fft.c"
@ -45,7 +47,7 @@ struct eq_data
struct eq_gain
{
float freq;
float gain; // Linear.
float gain; /* Linear. */
};
static void eq_free(void *data)
@ -65,18 +67,22 @@ static void eq_free(void *data)
static void eq_process(void *data, struct dspfilter_output *output,
const struct dspfilter_input *input)
{
float *out;
const float *in;
unsigned input_frames;
struct eq_data *eq = (struct eq_data*)data;
output->samples = eq->buffer;
output->frames = 0;
float *out = eq->buffer;
const float *in = input->samples;
unsigned input_frames = input->frames;
out = eq->buffer;
in = input->samples;
input_frames = input->frames;
while (input_frames)
{
unsigned write_avail = eq->block_size - eq->block_ptr;
if (input_frames < write_avail)
write_avail = input_frames;
@ -119,9 +125,8 @@ static int gains_cmp(const void *a_, const void *b_)
const struct eq_gain *b = (const struct eq_gain*)b_;
if (a->freq < b->freq)
return -1;
else if (a->freq > b->freq)
if (a->freq > b->freq)
return 1;
else
return 0;
}
@ -147,6 +152,8 @@ static void generate_response(fft_complex_t *response,
// Create a response by linear interpolation between known frequency sample points.
for (i = 0; i <= samples; i++)
{
float gain;
float lerp = 0.5f;
float freq = (float)i / samples;
while (freq >= end_freq)
@ -171,11 +178,10 @@ static void generate_response(fft_complex_t *response,
}
}
float lerp = 0.5f;
// Edge case where i == samples.
/* Edge case where i == samples. */
if (end_freq > start_freq)
lerp = (freq - start_freq) / (end_freq - start_freq);
float gain = (1.0f - lerp) * start_gain + lerp * end_gain;
gain = (1.0f - lerp) * start_gain + lerp * end_gain;
response[i].real = gain;
response[i].imag = 0.0f;
@ -184,58 +190,25 @@ static void generate_response(fft_complex_t *response,
}
}
// Modified Bessel function of first order.
// Check Wiki for mathematical definition ...
static INLINE double kaiser_besseli0(double x)
{
unsigned i;
double sum = 0.0;
double factorial = 1.0;
double factorial_mult = 0.0;
double x_pow = 1.0;
double two_div_pow = 1.0;
double x_sqr = x * x;
// Approximate. This is an infinite sum.
// Luckily, it converges rather fast.
for (i = 0; i < 18; i++)
{
sum += x_pow * two_div_pow / (factorial * factorial);
factorial_mult += 1.0;
x_pow *= x_sqr;
two_div_pow *= 0.25;
factorial *= factorial_mult;
}
return sum;
}
static INLINE double kaiser_window(double index, double beta)
{
return kaiser_besseli0(beta * sqrt(1 - index * index));
}
static void create_filter(struct eq_data *eq, unsigned size_log2,
struct eq_gain *gains, unsigned num_gains, double beta, const char *filter_path)
{
int i;
int half_block_size = eq->block_size >> 1;
double window_mod = 1.0 / kaiser_window(0.0, beta);
double window_mod = 1.0 / kaiser_window_function(0.0, beta);
fft_t *fft = fft_new(size_log2);
float *time_filter = (float*)calloc(eq->block_size * 2 + 1, sizeof(*time_filter));
if (!fft || !time_filter)
goto end;
// Make sure bands are in correct order.
/* Make sure bands are in correct order. */
qsort(gains, num_gains, sizeof(*gains), gains_cmp);
// Compute desired filter response.
/* Compute desired filter response. */
generate_response(eq->filter, gains, num_gains, half_block_size);
// Get equivalent time-domain filter.
/* Get equivalent time-domain filter. */
fft_process_inverse(fft, time_filter, eq->filter, 1);
// ifftshift() to create the correct linear phase filter.
@ -248,16 +221,16 @@ static void create_filter(struct eq_data *eq, unsigned size_log2,
time_filter[i] = tmp;
}
// Apply a window to smooth out the frequency repsonse.
/* Apply a window to smooth out the frequency repsonse. */
for (i = 0; i < (int)eq->block_size; i++)
{
// Kaiser window.
/* Kaiser window. */
double phase = (double)i / eq->block_size;
phase = 2.0 * (phase - 0.5);
time_filter[i] *= window_mod * kaiser_window(phase, beta);
time_filter[i] *= window_mod * kaiser_window_function(phase, beta);
}
// Debugging.
/* Debugging. */
if (filter_path)
{
FILE *file = fopen(filter_path, "w");
@ -269,9 +242,10 @@ static void create_filter(struct eq_data *eq, unsigned size_log2,
}
}
// Padded FFT to create our FFT filter.
// Make our even-length filter odd by discarding the first coefficient.
// For some interesting reason, this allows us to design an odd-length linear phase filter.
/* Padded FFT to create our FFT filter.
* Make our even-length filter odd by discarding the first coefficient.
* For some interesting reason, this allows us to design an odd-length linear phase filter.
*/
fft_process_forward(eq->fft, eq->filter, time_filter + 1, 1);
end:
@ -282,28 +256,27 @@ end:
static void *eq_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
unsigned i;
float *frequencies, *gain;
unsigned num_freq, num_gain, i, size;
int size_log2;
float beta;
struct eq_gain *gains = NULL;
char *filter_path = NULL;
const float default_freq[] = { 0.0f, info->input_rate };
const float default_gain[] = { 0.0f, 0.0f };
struct eq_data *eq = (struct eq_data*)calloc(1, sizeof(*eq));
if (!eq)
return NULL;
const float default_freq[] = { 0.0f, info->input_rate };
const float default_gain[] = { 0.0f, 0.0f };
float beta;
config->get_float(userdata, "window_beta", &beta, 4.0f);
int size_log2;
config->get_int(userdata, "block_size_log2", &size_log2, 8);
unsigned size = 1 << size_log2;
size = 1 << size_log2;
struct eq_gain *gains = NULL;
float *frequencies, *gain;
unsigned num_freq, num_gain;
config->get_float_array(userdata, "frequencies", &frequencies, &num_freq, default_freq, 2);
config->get_float_array(userdata, "gains", &gain, &num_gain, default_gain, 2);
char *filter_path = NULL;
if (!config->get_string(userdata, "impulse_response_output", &filter_path, ""))
{
config->free(filter_path);
@ -331,8 +304,9 @@ static void *eq_init(const struct dspfilter_info *info,
eq->fftblock = (fft_complex_t*)calloc(2 * size, sizeof(*eq->fftblock));
eq->filter = (fft_complex_t*)calloc(2 * size, sizeof(*eq->filter));
// Use an FFT which is twice the block size with zero-padding
// to make circular convolution => proper convolution.
/* Use an FFT which is twice the block size with zero-padding
* to make circular convolution => proper convolution.
*/
eq->fft = fft_new(size_log2 + 1);
if (!eq->fft || !eq->fftblock || !eq->save || !eq->block || !eq->filter)

View File

@ -61,30 +61,34 @@ static void iir_free(void *data)
static void iir_process(void *data, struct dspfilter_output *output,
const struct dspfilter_input *input)
{
float b0, b1, b2, a0, a1, a2;
float xn1_l, xn2_l, yn1_l, yn2_l;
float xn1_r, xn2_r, yn1_r, yn2_r;
unsigned i;
float *out;
struct iir_data *iir = (struct iir_data*)data;
output->samples = input->samples;
output->frames = input->frames;
float *out = output->samples;
out = output->samples;
float b0 = iir->b0;
float b1 = iir->b1;
float b2 = iir->b2;
float a0 = iir->a0;
float a1 = iir->a1;
float a2 = iir->a2;
b0 = iir->b0;
b1 = iir->b1;
b2 = iir->b2;
a0 = iir->a0;
a1 = iir->a1;
a2 = iir->a2;
float xn1_l = iir->l.xn1;
float xn2_l = iir->l.xn2;
float yn1_l = iir->l.yn1;
float yn2_l = iir->l.yn2;
xn1_l = iir->l.xn1;
xn2_l = iir->l.xn2;
yn1_l = iir->l.yn1;
yn2_l = iir->l.yn2;
float xn1_r = iir->r.xn1;
float xn2_r = iir->r.xn2;
float yn1_r = iir->r.yn1;
float yn2_r = iir->r.yn2;
xn1_r = iir->r.xn1;
xn2_r = iir->r.xn2;
yn1_r = iir->r.yn1;
yn2_r = iir->r.yn2;
for (i = 0; i < input->frames; i++, out += 2)
{
@ -163,7 +167,7 @@ static void iir_filter_init(struct iir_data *iir,
float b0 = 0.0, b1 = 0.0, b2 = 0.0, a0 = 0.0, a1 = 0.0, a2 = 0.0;
// Set up filter coefficients according to type
/* Set up filter coefficients according to type */
switch (filter_type)
{
case LPF:
@ -216,6 +220,7 @@ static void iir_filter_init(struct iir_data *iir,
break;
case RIAA_phono: /* http://www.dsprelated.com/showmessage/73300/3.php */
{
double y, b_re, a_re, b_im, a_im, g;
float b[3], a[3];
if ((int)sample_rate == 44100)
@ -254,13 +259,14 @@ static void iir_filter_init(struct iir_data *iir,
a1 = a[1];
a2 = a[2];
/* Normalise to 0dB at 1kHz (Thanks to Glenn Davis) */
double y = 2.0 * M_PI * 1000.0 / sample_rate;
double b_re = b0 + b1 * cos(-y) + b2 * cos(-2.0 * y);
double a_re = a0 + a1 * cos(-y) + a2 * cos(-2.0 * y);
double b_im = b1 * sin(-y) + b2 * sin(-2.0 * y);
double a_im = a1 * sin(-y) + a2 * sin(-2.0 * y);
double g = 1.0 / sqrt((sqr(b_re) + sqr(b_im)) / (sqr(a_re) + sqr(a_im)));
y = 2.0 * M_PI * 1000.0 / sample_rate;
b_re = b0 + b1 * cos(-y) + b2 * cos(-2.0 * y);
a_re = a0 + a1 * cos(-y) + a2 * cos(-2.0 * y);
b_im = b1 * sin(-y) + b2 * sin(-2.0 * y);
a_im = a1 * sin(-y) + a2 * sin(-2.0 * y);
g = 1.0 / sqrt((sqr(b_re) + sqr(b_im)) / (sqr(a_re) + sqr(a_im)));
b0 *= g; b1 *= g; b2 *= g;
break;
}
@ -319,19 +325,20 @@ static void iir_filter_init(struct iir_data *iir,
static void *iir_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
float freq, qual, gain;
enum IIRFilter filter;
char *type = NULL;
struct iir_data *iir = (struct iir_data*)calloc(1, sizeof(*iir));
if (!iir)
return NULL;
float freq, qual, gain;
config->get_float(userdata, "frequency", &freq, 1024.0f);
config->get_float(userdata, "quality", &qual, 0.707f);
config->get_float(userdata, "gain", &gain, 0.0f);
char *type = NULL;
config->get_string(userdata, "type", &type, "LPF");
enum IIRFilter filter = str_to_type(type);
filter = str_to_type(type);
config->free(type);
iir_filter_init(iir, info->input_rate, freq, qual, gain, filter);

View File

@ -33,12 +33,12 @@ static void panning_process(void *data, struct dspfilter_output *output,
const struct dspfilter_input *input)
{
unsigned i;
float *out;
struct panning_data *pan = (struct panning_data*)data;
output->samples = input->samples;
output->frames = input->frames;
float *out = output->samples;
out = output->samples;
for (i = 0; i < input->frames; i++, out += 2)
{
@ -52,28 +52,19 @@ static void panning_process(void *data, struct dspfilter_output *output,
static void *panning_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
static const float default_left[] = { 1.0f, 0.0f };
static const float default_right[] = { 0.0f, 1.0f };
float *left = NULL, *right = NULL;
unsigned num_left = 0, num_right = 0;
struct panning_data *pan = (struct panning_data*)calloc(1, sizeof(*pan));
if (!pan)
return NULL;
float *left = NULL, *right = NULL;
unsigned num_left = 0, num_right = 0;
static const float default_left[] = { 1.0f, 0.0f };
static const float default_right[] = { 0.0f, 1.0f };
config->get_float_array(userdata, "left_mix", &left, &num_left, default_left, 2);
config->get_float_array(userdata, "right_mix", &right, &num_right, default_right, 2);
if (num_left == 2)
memcpy(pan->left, left, sizeof(pan->left));
else
memcpy(pan->left, default_left, sizeof(pan->left));
if (num_right == 2)
memcpy(pan->right, right, sizeof(pan->right));
else
memcpy(pan->right, default_right, sizeof(pan->right));
memcpy(pan->left, (num_left == 2) ? left : default_left, sizeof(pan->left));
memcpy(pan->right, (num_right == 2) ? right : default_right, sizeof(pan->right));
config->free(left);
config->free(right);

View File

@ -53,12 +53,12 @@ static void phaser_process(void *data, struct dspfilter_output *output,
{
unsigned i, c;
int s;
float m[2], tmp[2];
float m[2], tmp[2], *out;
struct phaser_data *ph = (struct phaser_data*)data;
output->samples = input->samples;
output->frames = input->frames;
float *out = output->samples;
out = output->samples;
for (i = 0; i < input->frames; i++, out += 2)
{
@ -95,12 +95,11 @@ static void phaser_process(void *data, struct dspfilter_output *output,
static void *phaser_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
float lfo_freq, lfo_start_phase;
struct phaser_data *ph = (struct phaser_data*)calloc(1, sizeof(*ph));
if (!ph)
return NULL;
float lfo_freq, lfo_start_phase;
config->get_float(userdata, "lfo_freq", &lfo_freq, 0.4f);
config->get_float(userdata, "lfo_start_phase", &lfo_start_phase, 0.0f);
config->get_float(userdata, "feedback", &ph->fb, 0.0f);

View File

@ -245,11 +245,12 @@ static void reverb_process(void *data, struct dspfilter_output *output,
const struct dspfilter_input *input)
{
unsigned i;
float *out;
struct reverb_data *rev = (struct reverb_data*)data;
output->samples = input->samples;
output->frames = input->frames;
float *out = output->samples;
out = output->samples;
for (i = 0; i < input->frames; i++, out += 2)
{
@ -263,11 +264,12 @@ static void reverb_process(void *data, struct dspfilter_output *output,
static void *reverb_init(const struct dspfilter_info *info,
const struct dspfilter_config *config, void *userdata)
{
struct reverb_data *rev = (struct reverb_data*)calloc(1, sizeof(*rev));
float drytime, wettime, damping, roomwidth, roomsize;
struct reverb_data *rev = (struct reverb_data*)
calloc(1, sizeof(*rev));
if (!rev)
return NULL;
float drytime, wettime, damping, roomwidth, roomsize;
config->get_float(userdata, "drytime", &drytime, 0.43f);
config->get_float(userdata, "wettime", &wettime, 0.4f);
config->get_float(userdata, "damping", &damping, 0.8f);

View File

@ -19,7 +19,7 @@
#include <stdlib.h>
#include <string.h>
#define wahwahlfoskipsamples 30
#define WAHWAH_LFO_SKIP_SAMPLES 30
#ifndef M_PI
#define M_PI 3.1415926535897932384626433832795
@ -42,6 +42,7 @@ struct wahwah_data
static void wahwah_free(void *data)
{
if (data)
free(data);
}
@ -49,26 +50,30 @@ static void wahwah_process(void *data, struct dspfilter_output *output,
const struct dspfilter_input *input)
{
unsigned i;
float *out;
struct wahwah_data *wah = (struct wahwah_data*)data;
output->samples = input->samples;
output->frames = input->frames;
float *out = output->samples;
out = output->samples;
for (i = 0; i < input->frames; i++, out += 2)
{
float out_l, out_r;
float in[2] = { out[0], out[1] };
if ((wah->skipcount++ % wahwahlfoskipsamples) == 0)
if ((wah->skipcount++ % WAHWAH_LFO_SKIP_SAMPLES) == 0)
{
float omega, sn, cs, alpha;
float frequency = (1.0 + cos(wah->skipcount * wah->lfoskip + wah->phase)) / 2.0;
frequency = frequency * wah->depth * (1.0 - wah->freqofs) + wah->freqofs;
frequency = exp((frequency - 1.0) * 6.0);
float omega = M_PI * frequency;
float sn = sin(omega);
float cs = cos(omega);
float alpha = sn / (2.0 * wah->res);
omega = M_PI * frequency;
sn = sin(omega);
cs = cos(omega);
alpha = sn / (2.0 * wah->res);
wah->b0 = (1.0 - cs) / 2.0;
wah->b1 = 1.0 - cs;
@ -78,8 +83,8 @@ static void wahwah_process(void *data, struct dspfilter_output *output,
wah->a2 = 1.0 - alpha;
}
float out_l = (wah->b0 * in[0] + wah->b1 * wah->l.xn1 + wah->b2 * wah->l.xn2 - wah->a1 * wah->l.yn1 - wah->a2 * wah->l.yn2) / wah->a0;
float out_r = (wah->b0 * in[1] + wah->b1 * wah->r.xn1 + wah->b2 * wah->r.xn2 - wah->a1 * wah->r.yn1 - wah->a2 * wah->r.yn2) / wah->a0;
out_l = (wah->b0 * in[0] + wah->b1 * wah->l.xn1 + wah->b2 * wah->l.xn2 - wah->a1 * wah->l.yn1 - wah->a2 * wah->l.yn2) / wah->a0;
out_r = (wah->b0 * in[1] + wah->b1 * wah->r.xn1 + wah->b2 * wah->r.xn2 - wah->a1 * wah->r.yn1 - wah->a2 * wah->r.yn2) / wah->a0;
wah->l.xn2 = wah->l.xn1;
wah->l.xn1 = in[0];

View File

@ -13,16 +13,13 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdlib.h>
#include <alsa/asoundlib.h>
#include "../../driver.h"
#include <stdlib.h>
#include <alsa/asoundlib.h>
#include "../../general.h"
#define TRY_ALSA(x) if (x < 0) { \
goto error; \
}
typedef struct alsa
{
snd_pcm_t *pcm;
@ -73,43 +70,72 @@ static void *alsa_init(const char *device, unsigned rate, unsigned latency)
if (device)
alsa_dev = device;
TRY_ALSA(snd_pcm_open(
&alsa->pcm, alsa_dev, SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK));
TRY_ALSA(snd_pcm_hw_params_malloc(&params));
if (snd_pcm_open(
&alsa->pcm, alsa_dev, SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK) < 0)
goto error;
if (snd_pcm_hw_params_malloc(&params) < 0)
goto error;
alsa->has_float = find_float_format(alsa->pcm, params);
format = alsa->has_float ? SND_PCM_FORMAT_FLOAT : SND_PCM_FORMAT_S16;
TRY_ALSA(snd_pcm_hw_params_any(alsa->pcm, params));
TRY_ALSA(snd_pcm_hw_params_set_access(
alsa->pcm, params, SND_PCM_ACCESS_RW_INTERLEAVED));
TRY_ALSA(snd_pcm_hw_params_set_format(alsa->pcm, params, format));
TRY_ALSA(snd_pcm_hw_params_set_channels(alsa->pcm, params, channels));
TRY_ALSA(snd_pcm_hw_params_set_rate(alsa->pcm, params, rate, 0));
if (snd_pcm_hw_params_any(alsa->pcm, params) < 0)
goto error;
TRY_ALSA(snd_pcm_hw_params_set_buffer_time_near(
alsa->pcm, params, &latency_usec, NULL));
TRY_ALSA(snd_pcm_hw_params_set_periods_near(
alsa->pcm, params, &periods, NULL));
if (snd_pcm_hw_params_set_access(
alsa->pcm, params, SND_PCM_ACCESS_RW_INTERLEAVED) < 0)
goto error;
TRY_ALSA(snd_pcm_hw_params(alsa->pcm, params));
if (snd_pcm_hw_params_set_format(alsa->pcm, params, format) < 0)
goto error;
if (snd_pcm_hw_params_set_channels(alsa->pcm, params, channels) < 0)
goto error;
if (snd_pcm_hw_params_set_rate(alsa->pcm, params, rate, 0) < 0)
goto error;
if (snd_pcm_hw_params_set_buffer_time_near(
alsa->pcm, params, &latency_usec, NULL) < 0)
goto error;
if (snd_pcm_hw_params_set_periods_near(
alsa->pcm, params, &periods, NULL) < 0)
goto error;
if (snd_pcm_hw_params(alsa->pcm, params) < 0)
goto error;
/* Shouldn't have to bother with this,
* but some drivers are apparently broken. */
if (snd_pcm_hw_params_get_period_size(params, &buffer_size, NULL))
snd_pcm_hw_params_get_period_size_min(params, &buffer_size, NULL);
RARCH_LOG("ALSA: Period size: %d frames\n", (int)buffer_size);
if (snd_pcm_hw_params_get_buffer_size(params, &buffer_size))
snd_pcm_hw_params_get_buffer_size_max(params, &buffer_size);
RARCH_LOG("ALSA: Buffer size: %d frames\n", (int)buffer_size);
alsa->buffer_size = snd_pcm_frames_to_bytes(alsa->pcm, buffer_size);
alsa->can_pause = snd_pcm_hw_params_can_pause(params);
RARCH_LOG("ALSA: Can pause: %s.\n", alsa->can_pause ? "yes" : "no");
TRY_ALSA(snd_pcm_sw_params_malloc(&sw_params));
TRY_ALSA(snd_pcm_sw_params_current(alsa->pcm, sw_params));
TRY_ALSA(snd_pcm_sw_params_set_start_threshold(
alsa->pcm, sw_params, buffer_size / 2));
TRY_ALSA(snd_pcm_sw_params(alsa->pcm, sw_params));
if (snd_pcm_sw_params_malloc(&sw_params) < 0)
goto error;
if (snd_pcm_sw_params_current(alsa->pcm, sw_params) < 0)
goto error;
if (snd_pcm_sw_params_set_start_threshold(
alsa->pcm, sw_params, buffer_size / 2) < 0)
goto error;
if (snd_pcm_sw_params(alsa->pcm, sw_params) < 0)
goto error;
snd_pcm_hw_params_free(params);
snd_pcm_sw_params_free(sw_params);

View File

@ -14,13 +14,13 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../general.h"
#include "../../driver.h"
#define ALSA_PCM_NEW_HW_PARAMS_API
#define ALSA_PCM_NEW_SW_PARAMS_API
#include <sys/asoundlib.h>
#include "../../general.h"
#include "../../driver.h"
#define MAX_FRAG_SIZE 3072
#define DEFAULT_RATE 48000

View File

@ -14,14 +14,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdlib.h>
#include <alsa/asoundlib.h>
#include "../../general.h"
#include <rthreads/rthreads.h>
#include <queues/fifo_buffer.h>
#include "../../driver.h"
#include "../../general.h"
#define TRY_ALSA(x) if (x < 0) { \
goto error; \
}

View File

@ -13,12 +13,8 @@
* You should have received a copy of the GNU General Public License along with RetroArch.
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include "../../general.h"
#include <queues/fifo_buffer.h>
#include <stdlib.h>
#include <boolean.h>
#include <pthread.h>
#if TARGET_OS_IPHONE
@ -31,6 +27,13 @@
#include <AudioUnit/AudioUnit.h>
#include <AudioUnit/AUComponent.h>
#include <boolean.h>
#include <queues/fifo_buffer.h>
#include <retro_endianness.h>
#include "../../driver.h"
#include "../../general.h"
#if defined(__powerpc__) || defined(__ppc__) || defined(__POWERPC__)
#ifndef OSX_PPC

View File

@ -17,7 +17,6 @@
#include "../../driver.h"
#include "../../performance.h"
typedef struct
{
bool nonblocking;

View File

@ -14,14 +14,28 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#if defined(_MSC_VER) && !defined(_XBOX)
#pragma comment(lib, "dsound")
#pragma comment(lib, "dxguid")
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#ifndef _XBOX
#include <windows.h>
#include <mmreg.h>
#include <mmsystem.h>
#endif
#include <dsound.h>
#include <boolean.h>
#include <retro_inline.h>
#include <retro_miscellaneous.h>
#include <rthreads/rthreads.h>
#include <queues/fifo_buffer.h>
#include "../../driver.h"
#include "../../general.h"
#ifdef _XBOX
#define DSERR_BUFFERLOST MAKE_DSHRESULT(150)
@ -29,21 +43,11 @@
#define DSERR_PRIOLEVELNEEDED MAKE_DSHRESULT(70)
#endif
#include "../../driver.h"
#include <stdlib.h>
#include <boolean.h>
#include <stddef.h>
#include <stdint.h>
#include <string.h>
#ifndef _XBOX
// Need these includes in MinGW-w64 4.9 it seems ...
#include <mmreg.h>
#include <mmsystem.h>
#if defined(_MSC_VER) && !defined(_XBOX)
#pragma comment(lib, "dsound")
#pragma comment(lib, "dxguid")
#endif
#include <dsound.h>
#include <queues/fifo_buffer.h>
#include "../../general.h"
typedef struct dsound
{
@ -83,7 +87,7 @@ struct audio_lock
DWORD size2;
};
static INLINE bool grab_region(dsound_t *ds, DWORD write_ptr,
static INLINE bool grab_region(dsound_t *ds, uint32_t write_ptr,
struct audio_lock *region)
{
const char *err;
@ -118,16 +122,11 @@ static INLINE bool grab_region(dsound_t *ds, DWORD write_ptr,
break;
default:
err = NULL;
return true;
}
if (err)
{
RARCH_WARN("[DirectSound error]: %s\n", err);
return false;
}
return true;
}
static INLINE void release_region(dsound_t *ds, const struct audio_lock *region)

View File

@ -14,12 +14,8 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdlib.h>
#include <boolean.h>
#include "../../general.h"
#include <string.h>
#include <retro_inline.h>
#ifdef GEKKO
#include <gccore.h>
@ -28,7 +24,12 @@
#include <cafe/ai.h>
#endif
#include "../../gfx/drivers/gx_sdk_defines.h"
#include <boolean.h>
#include <retro_inline.h>
#include "../../driver.h"
#include "../../general.h"
#include "../../defines/gx_defines.h"
#define CHUNK_FRAMES 64
#define CHUNK_SIZE (CHUNK_FRAMES * sizeof(uint32_t))

View File

@ -13,20 +13,22 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdint.h>
#include <stdlib.h>
#include "../../general.h"
#include <string.h>
#include <assert.h>
#include <jack/jack.h>
#include <jack/types.h>
#include <jack/ringbuffer.h>
#include <stdint.h>
#include <boolean.h>
#include <string.h>
#include <assert.h>
#include <rthreads/rthreads.h>
#include "../../driver.h"
#include "../../general.h"
#define FRAMES(x) (x / (sizeof(float) * 2))
typedef struct jack

View File

@ -13,8 +13,8 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include "../../general.h"
#include <string.h>
#include <time.h>
#ifdef __APPLE__
#include <OpenAL/al.h>
@ -24,13 +24,13 @@
#include <AL/alc.h>
#endif
#include <time.h>
#include <string.h>
#ifdef _WIN32
#include <windows.h>
#endif
#include "../../driver.h"
#include "../../general.h"
#define BUFSIZE 1024
typedef struct al

View File

@ -14,15 +14,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include "../../general.h"
#include <rthreads/rthreads.h>
#include <SLES/OpenSLES.h>
#ifdef ANDROID
#include <SLES/OpenSLES_Android.h>
#endif
#include <rthreads/rthreads.h>
#include "../../driver.h"
#include "../../general.h"
/* Helper macros, COM-style. */
#define SLObjectItf_Realize(a, ...) ((*(a))->Realize(a, __VA_ARGS__))
#define SLObjectItf_GetInterface(a, ...) ((*(a))->GetInterface(a, __VA_ARGS__))

View File

@ -12,14 +12,12 @@
* You should have received a copy of the GNU General Public License along with RetroArch.
* If not, see <http://www.gnu.org/licenses/>.
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "../../driver.h"
#include "../../general.h"
#include <stdint.h>
#include <stdlib.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <unistd.h>
#include <errno.h>
#ifdef HAVE_OSS_BSD
#include <soundcard.h>
@ -27,11 +25,14 @@
#include <sys/soundcard.h>
#endif
#include <fcntl.h>
#include <sys/ioctl.h>
#include <unistd.h>
#include <errno.h>
#include <stdint.h>
#include <retro_endianness.h>
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "../../driver.h"
#include "../../general.h"
#ifdef HAVE_OSS_BSD
#define DEFAULT_OSS_DEV "/dev/audio"

View File

@ -14,14 +14,15 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../driver.h"
#include "../general.h"
#include <stdlib.h>
#include <string.h>
#include <queues/fifo_buffer.h>
#include "../ps3/sdk_defines.h"
#include "../driver.h"
#include "../general.h"
#include "../../defines/ps3_defines.h"
#define AUDIO_BLOCKS 8
#define AUDIO_CHANNELS 2

View File

@ -15,14 +15,23 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdint.h>
#include <malloc.h>
#ifdef VITA
#include <psp2/kernel/processmgr.h>
#include <psp2/kernel/threadmgr.h>
#include <psp2/kernel/sysmem.h>
#include <psp2/audioout.h>
#else
#include <pspkernel.h>
#include <pspaudio.h>
#endif
#include "../../general.h"
#include "../../driver.h"
#include <pspkernel.h>
#include <pspaudio.h>
#include <stdint.h>
typedef struct psp1_audio
typedef struct psp_audio
{
bool nonblocking;
uint32_t* buffer;
@ -33,7 +42,7 @@ typedef struct psp1_audio
volatile bool running;
volatile uint16_t readPos;
volatile uint16_t writePos;
} psp1_audio_t;
} psp_audio_t;
#define AUDIO_OUT_COUNT 512u
#define AUDIO_BUFFER_SIZE (1u<<13u)
@ -41,29 +50,43 @@ typedef struct psp1_audio
static int audioMainLoop(SceSize args, void* argp)
{
psp1_audio_t* psp = *((psp1_audio_t**)argp);
psp_audio_t* psp = *((psp_audio_t**)argp);
#ifdef VITA
int port = sceAudioOutOpenPort(PSP2_AUDIO_OUT_PORT_TYPE_MAIN, AUDIO_OUT_COUNT,
psp->rate, PSP2_AUDIO_OUT_MODE_STEREO);
#else
sceAudioSRCChReserve(AUDIO_OUT_COUNT, psp->rate, 2);
#endif
while (psp->running)
{
/* Get a non-volatile copy. */
uint16_t readPos = psp->readPos;
bool cond = ((uint16_t)(psp->writePos - readPos) & AUDIO_BUFFER_SIZE_MASK)
< (AUDIO_OUT_COUNT * 2);
if (((uint16_t)(psp->writePos - readPos) & AUDIO_BUFFER_SIZE_MASK)
< (AUDIO_OUT_COUNT * 2))
sceAudioSRCOutputBlocking(PSP_AUDIO_VOLUME_MAX, psp->zeroBuffer);
else
#ifdef VITA
sceAudioOutOutput(port,
cond ? psp->zeroBuffer : (psp->buffer + readPos));
#else
sceAudioSRCOutputBlocking(PSP_AUDIO_VOLUME_MAX, cond ? (psp->zeroBuffer)
: (psp->buffer + readPos));
#endif
if (!cond)
{
sceAudioSRCOutputBlocking(PSP_AUDIO_VOLUME_MAX,
psp->buffer + readPos);
readPos += AUDIO_OUT_COUNT;
readPos &= AUDIO_BUFFER_SIZE_MASK;
psp->readPos = readPos;
}
}
#ifdef VITA
sceAudioOutReleasePort(port);
#else
sceAudioSRCChRelease();
#endif
sceKernelExitThread(0);
return 0;
}
@ -71,7 +94,7 @@ static int audioMainLoop(SceSize args, void* argp)
static void *psp_audio_init(const char *device,
unsigned rate, unsigned latency)
{
psp1_audio_t *psp = (psp1_audio_t*)calloc(1, sizeof(psp1_audio_t));
psp_audio_t *psp = (psp_audio_t*)calloc(1, sizeof(psp_audio_t));
if (!psp)
return NULL;
@ -91,12 +114,17 @@ static void *psp_audio_init(const char *device,
psp->readPos = 0;
psp->writePos = 0;
psp->rate = rate;
#if defined(VITA)
psp->thread = sceKernelCreateThread
("audioMainLoop", audioMainLoop, 0x10000100, 0x10000, 0, 0, NULL);
#else
psp->thread = sceKernelCreateThread
("audioMainLoop", audioMainLoop, 0x08, 0x10000, 0, NULL);
#endif
psp->nonblocking = false;
psp->running = true;
sceKernelStartThread(psp->thread, sizeof(psp1_audio_t*), &psp);
sceKernelStartThread(psp->thread, sizeof(psp_audio_t*), &psp);
return psp;
}
@ -104,13 +132,16 @@ static void *psp_audio_init(const char *device,
static void psp_audio_free(void *data)
{
SceUInt timeout = 100000;
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
if(!psp)
return;
psp->running = false;
#if defined(VITA)
sceKernelWaitThreadEnd(psp->thread, NULL, &timeout);
#else
sceKernelWaitThreadEnd(psp->thread, &timeout);
#endif
sceKernelDeleteThread(psp->thread);
free(psp->buffer);
@ -121,7 +152,7 @@ static void psp_audio_free(void *data)
static ssize_t psp_audio_write(void *data, const void *buf, size_t size)
{
uint16_t sampleCount;
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
uint16_t writePos = psp->writePos;
sampleCount= size / sizeof(uint32_t);
@ -153,7 +184,7 @@ static ssize_t psp_audio_write(void *data, const void *buf, size_t size)
static bool psp_audio_alive(void *data)
{
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
if (!psp)
return false;
return psp->running;
@ -161,28 +192,63 @@ static bool psp_audio_alive(void *data)
static bool psp_audio_stop(void *data)
{
SceKernelThreadRunStatus runStatus;
SceUInt timeout = 100000;
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
#if defined(VITA)
SceKernelThreadInfo info;
info.size = sizeof(SceKernelThreadInfo);
if (sceKernelGetThreadInfo(
psp->thread, &info) < 0) /* Error */
return false;
if (info.status == PSP2_THREAD_STOPPED)
return false;
#else
SceKernelThreadRunStatus runStatus;
runStatus.size = sizeof(SceKernelThreadRunStatus);
if (sceKernelReferThreadRunStatus(
psp->thread, &runStatus) < 0) /* Error */
return false;
if (runStatus.status == PSP_THREAD_STOPPED)
return false;
#endif
psp->running = false;
#if defined(VITA)
sceKernelWaitThreadEnd(psp->thread, NULL, &timeout);
#else
sceKernelWaitThreadEnd(psp->thread, &timeout);
#endif
return true;
}
static bool psp_audio_start(void *data)
{
psp_audio_t* psp = (psp_audio_t*)data;
#if defined(VITA)
SceKernelThreadInfo info;
info.size = sizeof(SceKernelThreadInfo);
if (sceKernelGetThreadInfo(
psp->thread, &info) < 0) /* Error */
return false;
if (info.status != PSP2_THREAD_STOPPED)
return false;
#else
SceKernelThreadRunStatus runStatus;
psp1_audio_t* psp = (psp1_audio_t*)data;
runStatus.size = sizeof(SceKernelThreadRunStatus);
@ -192,16 +258,18 @@ static bool psp_audio_start(void *data)
if (runStatus.status != PSP_THREAD_STOPPED)
return false;
#endif
psp->running = true;
sceKernelStartThread(psp->thread, sizeof(psp1_audio_t*), &psp);
sceKernelStartThread(psp->thread, sizeof(psp_audio_t*), &psp);
return true;
}
static void psp_audio_set_nonblock_state(void *data, bool toggle)
{
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
if (psp)
psp->nonblocking = toggle;
}
@ -215,7 +283,7 @@ static bool psp_audio_use_float(void *data)
static size_t psp_write_avail(void *data)
{
/* TODO */
psp1_audio_t* psp = (psp1_audio_t*)data;
psp_audio_t* psp = (psp_audio_t*)data;
return AUDIO_BUFFER_SIZE - ((uint16_t)
(psp->writePos - psp->readPos) & AUDIO_BUFFER_SIZE_MASK);
}
@ -227,7 +295,7 @@ static size_t psp_buffer_size(void *data)
}
audio_driver_t audio_psp1 = {
audio_driver_t audio_psp = {
psp_audio_init,
psp_audio_write,
psp_audio_stop,
@ -236,7 +304,11 @@ audio_driver_t audio_psp1 = {
psp_audio_set_nonblock_state,
psp_audio_free,
psp_audio_use_float,
"psp1",
#ifdef VITA
"vita",
#else
"psp",
#endif
psp_write_avail,
psp_buffer_size,
};

View File

@ -13,13 +13,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdint.h>
#include <string.h>
#include <pulse/pulseaudio.h>
#include <boolean.h>
#include <retro_endianness.h>
#include "../../driver.h"
#include "../../general.h"
#include <pulse/pulseaudio.h>
#include <boolean.h>
#include <string.h>
#include <stdint.h>
typedef struct
{

View File

@ -13,13 +13,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdint.h>
#include <stdlib.h>
#include <errno.h>
#include <roaraudio.h>
#include <boolean.h>
#include "../../driver.h"
#include <stdlib.h>
#include <roaraudio.h>
#include <errno.h>
#include <stdint.h>
#include <boolean.h>
#include "../../general.h"
typedef struct

View File

@ -13,13 +13,15 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdlib.h>
#include <boolean.h>
#include <queues/fifo_buffer.h>
#include <rthreads/rthreads.h>
#include "../audio_driver.h"
#include <stdlib.h>
#include "rsound.h"
#include <queues/fifo_buffer.h>
#include <boolean.h>
#include <rthreads/rthreads.h>
typedef struct rsd
{

View File

@ -13,22 +13,22 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdlib.h>
#include <boolean.h>
#include <stddef.h>
#include <stdint.h>
#include <stddef.h>
#include <stdlib.h>
#include <string.h>
#include "SDL.h"
#include "SDL_audio.h"
#include <rthreads/rthreads.h>
#include "../../general.h"
#include <boolean.h>
#include <rthreads/rthreads.h>
#include <queues/fifo_buffer.h>
#include <retro_inline.h>
#include "../../driver.h"
#include "../../general.h"
typedef struct sdl_audio
{
bool nonblock;

View File

@ -14,14 +14,17 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdint.h>
#include <stdio.h>
#include <stdint.h>
#include <stddef.h>
#include <compat/msvc.h>
#include <boolean.h>
#include <stdlib.h>
#include <boolean.h>
#include <compat/msvc.h>
#include "xaudio.h"
#include "../../driver.h"
#include "../../general.h"
typedef struct xaudio2 xaudio2_t;
@ -71,7 +74,7 @@ struct xaudio2 : public IXAudio2VoiceCallback
IXAudio2SourceVoice *pSourceVoice;
HANDLE hEvent;
volatile long buffers;
unsigned long volatile buffers;
unsigned bufsize;
unsigned bufptr;
unsigned write_buffer;

View File

@ -14,14 +14,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../../driver.h"
#include <stdlib.h>
#include <boolean.h>
#include "../../general.h"
#include <retro_inline.h>
#include <xenon_sound/sound.h>
#include <retro_inline.h>
#include "../../driver.h"
#include "../../general.h"
#define SOUND_FREQUENCY 48000
#define MAX_BUFFER 2048

View File

@ -15,7 +15,6 @@
/* Convoluted Cosine Resampler */
#include "../audio_resampler_driver.h"
#include <math.h>
#include <stdint.h>
#include <stdlib.h>
@ -23,6 +22,9 @@
#include <xmmintrin.h>
#endif
#include <retro_inline.h>
#include <memalign.h>
#include "../audio_resampler_driver.h"
/* Since SSE and NEON don't provide support for trigonometric functions
* we approximate those with polynoms
@ -54,34 +56,6 @@ typedef struct rarch_CC_resampler
void (*process)(void *re, struct resampler_data *data);
} rarch_CC_resampler_t;
/* memalign() replacement functions
* copied from sinc.c and changed signature so no conflict
* happens when using griffin.c
* these functions should probably be moved to a common header
*/
static void *memalign_alloc__(size_t boundary, size_t size)
{
void **place;
uintptr_t addr = 0;
void *ptr = malloc(boundary + size + sizeof(uintptr_t));
if (!ptr)
return NULL;
addr = ((uintptr_t)
ptr + sizeof(uintptr_t) + boundary)
& ~(boundary - 1);
place = (void**)addr;
place[-1] = ptr;
return (void*)addr;
}
static void memalign_free__(void *ptr)
{
void **p = (void**)ptr;
free(p[-1]);
}
#ifdef _MIPS_ARCH_ALLEGREX
static void resampler_CC_process(void *re_, struct resampler_data *data)
@ -177,12 +151,6 @@ done:
data->output_frames = outp - (audio_frame_float_t*)data->data_out;
}
static void resampler_CC_free(void *re_)
{
(void)re_;
}
static void *resampler_CC_init(const struct resampler_config *config,
double bandwidth_mod, resampler_simd_mask_t mask)
{
@ -206,25 +174,21 @@ static void *resampler_CC_init(const struct resampler_config *config,
}
#else
#if defined(__SSE__)
#define CC_RESAMPLER_IDENT "SSE"
static void resampler_CC_downsample(void *re_, struct resampler_data *data)
{
__m128 vec_previous, vec_current;
float ratio, b;
rarch_CC_resampler_t *re = (rarch_CC_resampler_t*)re_;
audio_frame_float_t *inp = (audio_frame_float_t*)data->data_in;
audio_frame_float_t *inp_max = (audio_frame_float_t*)(inp + data->input_frames);
audio_frame_float_t *outp = (audio_frame_float_t*)data->data_out;
float ratio = 1.0 / data->ratio;
float b = data->ratio; /* cutoff frequency. */
ratio = 1.0 / data->ratio;
b = data->ratio; /* cutoff frequency. */
vec_previous = _mm_loadu_ps((float*)&re->buffer[0]);
vec_current = _mm_loadu_ps((float*)&re->buffer[2]);
__m128 vec_previous = _mm_loadu_ps((float*)&re->buffer[0]);
__m128 vec_current = _mm_loadu_ps((float*)&re->buffer[2]);
while (inp != inp_max)
{
@ -527,19 +491,13 @@ static void resampler_CC_process(void *re_, struct resampler_data *data)
re->process(re_, data);
}
static void resampler_CC_free(void *re_)
{
rarch_CC_resampler_t *re = (rarch_CC_resampler_t*)re_;
if (re)
memalign_free__(re);
}
static void *resampler_CC_init(const struct resampler_config *config,
double bandwidth_mod, resampler_simd_mask_t mask)
{
int i;
rarch_CC_resampler_t *re = (rarch_CC_resampler_t*)
memalign_alloc__(32, sizeof(rarch_CC_resampler_t));
memalign_alloc(32, sizeof(rarch_CC_resampler_t));
/* TODO: lookup if NEON support can be detected at
* runtime and a funcptr set at runtime for either
@ -547,7 +505,6 @@ static void *resampler_CC_init(const struct resampler_config *config,
* Android. */
(void)mask;
(void)config;
if (!re)
return NULL;
@ -574,6 +531,16 @@ static void *resampler_CC_init(const struct resampler_config *config,
}
#endif
static void resampler_CC_free(void *re_)
{
#ifndef _MIPS_ARCH_ALLEGREX
rarch_CC_resampler_t *re = (rarch_CC_resampler_t*)re_;
if (re)
memalign_free(re);
#endif
(void)re_;
}
rarch_resampler_t CC_resampler = {
resampler_CC_init,
resampler_CC_process,

View File

@ -15,7 +15,6 @@
/* Bog-standard windowed SINC implementation. */
#include "../audio_resampler_driver.h"
#include <math.h>
#include <stdint.h>
#include <stdlib.h>
@ -24,7 +23,12 @@
#ifdef __SSE__
#include <xmmintrin.h>
#endif
#include <retro_inline.h>
#include <filters.h>
#include <memalign.h>
#include "../audio_resampler_driver.h"
/* Rough SNR values for upsampling:
* LOWEST: 40 dB
@ -113,44 +117,10 @@ typedef struct rarch_sinc_resampler
float *main_buffer;
} rarch_sinc_resampler_t;
static INLINE double sinc(double val)
{
if (fabs(val) < 0.00001)
return 1.0;
return sin(val) / val;
}
#if defined(SINC_WINDOW_LANCZOS)
#define window_function(idx) (sinc(M_PI * (idx)))
#define window_function(idx) (lanzcos_window_function(idx))
#elif defined(SINC_WINDOW_KAISER)
/* Modified Bessel function of first order.
* Check Wiki for mathematical definition ... */
static INLINE double besseli0(double x)
{
unsigned i;
double sum = 0.0;
double factorial = 1.0;
double factorial_mult = 0.0;
double x_pow = 1.0;
double two_div_pow = 1.0;
double x_sqr = x * x;
/* Approximate. This is an infinite sum.
* Luckily, it converges rather fast. */
for (i = 0; i < 18; i++)
{
sum += x_pow * two_div_pow / (factorial * factorial);
factorial_mult += 1.0;
x_pow *= x_sqr;
two_div_pow *= 0.25;
factorial *= factorial_mult;
}
return sum;
}
#define window_function(idx) (besseli0(SINC_WINDOW_KAISER_BETA * sqrt(1 - (idx) * (idx))))
#define window_function(idx) (kaiser_window_function(idx, SINC_WINDOW_KAISER_BETA))
#else
#error "No SINC window function defined."
#endif
@ -212,30 +182,6 @@ static void init_sinc_table(rarch_sinc_resampler_t *resamp, double cutoff,
}
}
/* No memalign() for us on Win32 ... */
static void *aligned_alloc__(size_t boundary, size_t size)
{
void **place;
uintptr_t addr = 0;
void *ptr = malloc(boundary + size + sizeof(uintptr_t));
if (!ptr)
return NULL;
addr = ((uintptr_t)ptr + sizeof(uintptr_t) + boundary)
& ~(boundary - 1);
place = (void**)addr;
place[-1] = ptr;
return (void*)addr;
}
static void aligned_free__(void *ptr)
{
void **p = (void**)ptr;
free(p[-1]);
}
#if !(defined(__AVX__) && ENABLE_AVX) && !defined(__SSE__)
static INLINE void process_sinc_C(rarch_sinc_resampler_t *resamp,
float *out_buffer)
@ -462,7 +408,7 @@ static void resampler_sinc_free(void *re)
{
rarch_sinc_resampler_t *resampler = (rarch_sinc_resampler_t*)re;
if (resampler)
aligned_free__(resampler->main_buffer);
memalign_free(resampler->main_buffer);
free(resampler);
}
@ -503,8 +449,7 @@ static void *resampler_sinc_new(const struct resampler_config *config,
#endif
elems = phase_elems + 4 * re->taps;
re->main_buffer = (float*)
aligned_alloc__(128, sizeof(float) * elems);
re->main_buffer = (float*)memalign_alloc(128, sizeof(float) * elems);
if (!re->main_buffer)
goto error;

View File

@ -46,6 +46,7 @@
#define NETWORK_COMPAT_HEADERS 1
#endif
#ifdef NETWORK_COMPAT_HEADERS
#include <sys/socket.h>
#include <netdb.h>
@ -71,6 +72,7 @@
#include <compat/strl.h>
#include <retro_inline.h>
#include <retro_miscellaneous.h>
/*
****************************************************************************
@ -748,22 +750,7 @@ static int64_t rsnd_get_time_usec(void)
static void rsnd_sleep(int msec)
{
#if defined(__CELLOS_LV2__) && !defined(__PSL1GHT__)
sys_timer_usleep(1000 * msec);
#elif defined(PSP)
sceKernelDelayThread(1000 * msec);
#elif defined(_WIN32)
Sleep(msec);
#elif defined(XENON)
udelay(1000 * msec);
#elif defined(GEKKO) || defined(__PSL1GHT__) || defined(__QNX__)
usleep(1000 * msec);
#else
struct timespec tv = {0};
tv.tv_sec = msec / 1000;
tv.tv_nsec = (msec % 1000) * 1000000;
nanosleep(&tv, NULL);
#endif
rarch_sleep(msec);
}

View File

@ -11,18 +11,28 @@ TESTS := test-sinc-lowest \
test-cc \
test-snr-cc
LIBRETRO_COMM_DIR = ../../libretro-common
CFLAGS += -O3 -ffast-math -g -Wall -pedantic -march=native -std=gnu99
CFLAGS += -DRESAMPLER_TEST -DRARCH_DUMMY_LOG
CFLAGS += -I../../libretro-common/include -I../../
CFLAGS += -DRESAMPLER_TEST -DRARCH_DUMMY_LOG -DRARCH_INTERNAL
CFLAGS += -I$(LIBRETRO_COMM_DIR)/include -I../../
LDFLAGS += -lm
SHAREDOBJ += $(LIBRETRO_COMM_DIR)/memmap/memalign.o \
$(LIBRETRO_COMM_DIR)/string/string_list.o \
$(LIBRETRO_COMM_DIR)/file/config_file_userdata.o \
$(LIBRETRO_COMM_DIR)/file/config_file.o \
$(LIBRETRO_COMM_DIR)/file/file_path.o \
$(LIBRETRO_COMM_DIR)/compat/compat.o \
$(LIBRETRO_COMM_DIR)/hash/rhash.o \
all: $(TESTS)
resampler-sinc.o: ../audio_resampler_driver.c
resampler-sinc.o: ../audio_resampler_driver.c $(SHAREDOBJ)
$(CC) -c -o $@ $< $(CFLAGS)
resampler-cc.o: ../audio_resampler_driver.c
resampler-cc.o: ../audio_resampler_driver.c $(SHAREDOBJ)
$(CC) -c -o $@ $< $(CFLAGS) -DRESAMPLER_IDENT='"CC"'
main-cc.o: main.c
@ -31,7 +41,7 @@ main-cc.o: main.c
snr-cc.o: snr.c
$(CC) -c -o $@ $< $(CFLAGS) -DRESAMPLER_IDENT='"CC"'
cc-resampler.o: ../resamplers/cc_resampler.c
cc-resampler.o: ../drivers_resampler/cc_resampler.c
$(CC) -c -o $@ $< $(CFLAGS)
sinc-lowest.o: ../drivers_resampler/sinc.c
@ -52,40 +62,40 @@ sinc-higher.o: ../drivers_resampler/sinc.c
sinc-highest.o: ../drivers_resampler/sinc.c
$(CC) -c -o $@ $< $(CFLAGS) -DSINC_HIGHEST_QUALITY
test-sinc-lowest: sinc-lowest.o ../audio_utils.o main.o resampler-sinc.o nearest.o
test-sinc-lowest: sinc-lowest.o ../audio_utils.o main.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-sinc-lowest: sinc-lowest.o ../audio_utils.o snr.o resampler-sinc.o nearest.o
test-snr-sinc-lowest: sinc-lowest.o ../audio_utils.o snr.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-sinc-lower: sinc-lower.o ../audio_utils.o main.o resampler-sinc.o nearest.o
test-sinc-lower: sinc-lower.o ../audio_utils.o main.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-sinc-lower: sinc-lower.o ../audio_utils.o snr.o resampler-sinc.o nearest.o
test-snr-sinc-lower: sinc-lower.o ../audio_utils.o snr.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-sinc: sinc.o ../audio_utils.o main.o resampler-sinc.o nearest.o
test-sinc: sinc.o ../audio_utils.o main.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-sinc: sinc.o ../audio_utils.o snr.o resampler-sinc.o nearest.o
test-snr-sinc: sinc.o ../audio_utils.o snr.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-sinc-higher: sinc-higher.o ../audio_utils.o main.o resampler-sinc.o nearest.o
test-sinc-higher: sinc-higher.o ../audio_utils.o main.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-sinc-higher: sinc-higher.o ../audio_utils.o snr.o resampler-sinc.o nearest.o
test-snr-sinc-higher: sinc-higher.o ../audio_utils.o snr.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-sinc-highest: sinc-highest.o ../audio_utils.o main.o resampler-sinc.o nearest.o
test-sinc-highest: sinc-highest.o ../audio_utils.o main.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-sinc-highest: sinc-highest.o ../audio_utils.o snr.o resampler-sinc.o nearest.o
test-snr-sinc-highest: sinc-highest.o ../audio_utils.o snr.o resampler-sinc.o resampler-cc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-cc: cc-resampler.o ../audio_utils.o main-cc.o resampler-cc.o sinc.o nearest.o
test-cc: cc-resampler.o ../audio_utils.o main-cc.o resampler-cc.o resampler-cc.o sinc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
test-snr-cc: cc-resampler.o ../audio_utils.o snr-cc.o resampler-cc.o sinc.o nearest.o
test-snr-cc: cc-resampler.o ../audio_utils.o snr-cc.o resampler-cc.o sinc.o nearest.o $(SHAREDOBJ)
$(CC) -o $@ $^ $(LDFLAGS)
%.o: %.c

View File

@ -13,8 +13,6 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../resamplers/resampler.h"
#include "../audio_utils.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
@ -23,6 +21,9 @@
#include <assert.h>
#include <stdbool.h>
#include "../audio_resampler_driver.h"
#include "../audio_utils.h"
#ifndef RESAMPLER_IDENT
#define RESAMPLER_IDENT "sinc"
#endif

View File

@ -14,12 +14,14 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "autosave.h"
#include <rthreads/rthreads.h>
#include <stdlib.h>
#include <boolean.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <boolean.h>
#include <rthreads/rthreads.h>
#include "general.h"
struct autosave
@ -196,10 +198,10 @@ void lock_autosave(void)
unsigned i;
global_t *global = global_get_ptr();
for (i = 0; i < global->num_autosave; i++)
for (i = 0; i < global->autosave.num; i++)
{
if (global->autosave[i])
autosave_lock(global->autosave[i]);
if (global->autosave.list[i])
autosave_lock(global->autosave.list[i]);
}
}
@ -213,10 +215,10 @@ void unlock_autosave(void)
unsigned i;
global_t *global = global_get_ptr();
for (i = 0; i < global->num_autosave; i++)
for (i = 0; i < global->autosave.num; i++)
{
if (global->autosave[i])
autosave_unlock(global->autosave[i]);
if (global->autosave.list[i])
autosave_unlock(global->autosave.list[i]);
}
}

View File

@ -16,10 +16,9 @@
#include <string.h>
#include <string/string_list.h>
#include "camera_driver.h"
#include "../driver.h"
#include "../general.h"
#include "../system.h"
static const camera_driver_t *camera_drivers[] = {
#ifdef HAVE_V4L2

View File

@ -27,12 +27,12 @@
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/time.h>
#include <sys/mman.h>
#include <sys/ioctl.h>
#include <asm/types.h>
#include <linux/videodev2.h>
#include <memmap.h>
#include <retro_miscellaneous.h>
#include <gfx/scaler/scaler.h>

View File

@ -14,22 +14,52 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "cheats.h"
#include "general.h"
#include "runloop.h"
#include "dynamic.h"
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <file/config_file.h>
#include <file/file_path.h>
#include <compat/strl.h>
#include <compat/posix_string.h>
#include "cheats.h"
#include "general.h"
#include "runloop.h"
#include "dynamic.h"
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
struct item_cheat
{
char *desc;
bool state;
char *code;
};
struct cheat_manager
{
struct item_cheat *cheats;
unsigned ptr;
unsigned size;
unsigned buf_size;
};
unsigned cheat_manager_get_buf_size(cheat_manager_t *handle)
{
if (!handle)
return 0;
return handle->buf_size;
}
unsigned cheat_manager_get_size(cheat_manager_t *handle)
{
if (!handle)
return 0;
return handle->size;
}
void cheat_manager_apply_cheats(cheat_manager_t *handle)
{
@ -47,6 +77,14 @@ void cheat_manager_apply_cheats(cheat_manager_t *handle)
}
}
void cheat_manager_set_code(cheat_manager_t *handle, unsigned i, const char *str)
{
if (!handle)
return;
handle->cheats[i].code = strdup(str);
handle->cheats[i].state = true;
}
/**
* cheat_manager_save:
* @path : Path to cheats file (relative path).
@ -264,6 +302,14 @@ void cheat_manager_update(cheat_manager_t *handle, unsigned handle_idx)
RARCH_LOG("%s\n", msg);
}
void cheat_manager_toggle_index(cheat_manager_t *handle, unsigned i)
{
if (!handle)
return;
handle->cheats[i].state = !handle->cheats[i].state;
cheat_manager_update(handle, i);
}
void cheat_manager_toggle(cheat_manager_t *handle)
{
@ -296,3 +342,24 @@ void cheat_manager_index_prev(cheat_manager_t *handle)
cheat_manager_update(handle, handle->ptr);
}
const char *cheat_manager_get_code(cheat_manager_t *handle, unsigned i)
{
if (!handle)
return NULL;
return handle->cheats[i].code;
}
const char *cheat_manager_get_desc(cheat_manager_t *handle, unsigned i)
{
if (!handle)
return NULL;
return handle->cheats[i].desc;
}
bool cheat_manager_get_code_state(cheat_manager_t *handle, unsigned i)
{
if (!handle)
return false;
return handle->cheats[i].state;
}

View File

@ -23,23 +23,10 @@
extern "C" {
#endif
struct item_cheat
{
char *desc;
bool state;
char *code;
};
struct cheat_manager
{
struct item_cheat *cheats;
unsigned ptr;
unsigned size;
unsigned buf_size;
};
typedef struct cheat_manager cheat_manager_t;
unsigned cheat_manager_get_size(cheat_manager_t *handle);
cheat_manager_t *cheat_manager_new(unsigned size);
cheat_manager_t *cheat_manager_load(const char *path);
@ -56,6 +43,8 @@ bool cheat_manager_save(cheat_manager_t *handle, const char *path);
bool cheat_manager_realloc(cheat_manager_t *handle, unsigned new_size);
void cheat_manager_set_code(cheat_manager_t *handle, unsigned index, const char *str);
void cheat_manager_free(cheat_manager_t *handle);
void cheat_manager_index_next(cheat_manager_t *handle);
@ -68,6 +57,16 @@ void cheat_manager_apply_cheats(cheat_manager_t *handle);
void cheat_manager_update(cheat_manager_t *handle, unsigned handle_idx);
void cheat_manager_toggle_index(cheat_manager_t *handle, unsigned i);
unsigned cheat_manager_get_buf_size(cheat_manager_t *handle);
const char *cheat_manager_get_desc(cheat_manager_t *handle, unsigned i);
const char *cheat_manager_get_code(cheat_manager_t *handle, unsigned i);
bool cheat_manager_get_code_state(cheat_manager_t *handle, unsigned i);
#ifdef __cplusplus
}
#endif

View File

@ -19,8 +19,6 @@
#include "general.h"
#include "performance.h"
#include "runloop_data.h"
#include "runloop.h"
#include "dynamic.h"
#include "content.h"
#include "screenshot.h"
@ -28,6 +26,7 @@
#include "retroarch.h"
#include "dir_list_special.h"
#include "runloop_data.h"
#include "configuration.h"
#include "input/input_remapping.h"
@ -102,11 +101,11 @@ static void event_init_autosave(void)
if (settings->autosave_interval < 1 || !global->savefiles)
return;
if (!(global->autosave = (autosave_t**)calloc(global->savefiles->size,
sizeof(*global->autosave))))
if (!(global->autosave.list = (autosave_t**)calloc(global->savefiles->size,
sizeof(*global->autosave.list))))
return;
global->num_autosave = global->savefiles->size;
global->autosave.num = global->savefiles->size;
for (i = 0; i < global->savefiles->size; i++)
{
@ -116,12 +115,12 @@ static void event_init_autosave(void)
if (pretro_get_memory_size(type) <= 0)
continue;
global->autosave[i] = autosave_new(path,
global->autosave.list[i] = autosave_new(path,
pretro_get_memory_data(type),
pretro_get_memory_size(type),
settings->autosave_interval);
if (!global->autosave[i])
if (!global->autosave.list[i])
RARCH_WARN("%s\n", msg_hash_to_str(MSG_AUTOSAVE_FAILED));
}
}
@ -131,14 +130,14 @@ static void event_deinit_autosave(void)
unsigned i;
global_t *global = global_get_ptr();
for (i = 0; i < global->num_autosave; i++)
autosave_free(global->autosave[i]);
for (i = 0; i < global->autosave.num; i++)
autosave_free(global->autosave.list[i]);
if (global->autosave)
free(global->autosave);
global->autosave = NULL;
if (global->autosave.list)
free(global->autosave.list);
global->num_autosave = 0;
global->autosave.list = NULL;
global->autosave.num = 0;
}
#endif
@ -147,7 +146,7 @@ static void event_save_files(void)
unsigned i;
global_t *global = global_get_ptr();
if (!global->savefiles || !global->use_sram)
if (!global->savefiles || !global->sram.use)
return;
for (i = 0; i < global->savefiles->size; i++)
@ -256,60 +255,6 @@ static void event_disk_control_set_eject(bool new_state, bool print_log)
}
}
/**
* event_disk_control_append_image:
* @path : Path to disk image.
*
* Appends disk image to disk image list.
**/
void event_disk_control_append_image(const char *path)
{
unsigned new_idx;
char msg[PATH_MAX_LENGTH] = {0};
struct retro_game_info info = {0};
global_t *global = global_get_ptr();
rarch_system_info_t *sysinfo = rarch_system_info_get_ptr();
const struct retro_disk_control_callback *control =
sysinfo ? (const struct retro_disk_control_callback*)&sysinfo->disk_control
: NULL;
if (!control)
return;
event_disk_control_set_eject(true, false);
control->add_image_index();
new_idx = control->get_num_images();
if (!new_idx)
return;
new_idx--;
info.path = path;
control->replace_image_index(new_idx, &info);
snprintf(msg, sizeof(msg), "%s: ", msg_hash_to_str(MSG_APPENDED_DISK));
strlcat(msg, path, sizeof(msg));
RARCH_LOG("%s\n", msg);
rarch_main_msg_queue_push(msg, 0, 180, true);
event_command(EVENT_CMD_AUTOSAVE_DEINIT);
/* TODO: Need to figure out what to do with subsystems case. */
if (!*global->subsystem)
{
/* Update paths for our new image.
* If we actually use append_image, we assume that we
* started out in a single disk case, and that this way
* of doing it makes the most sense. */
rarch_set_paths(path);
rarch_fill_pathnames();
}
event_command(EVENT_CMD_AUTOSAVE_INIT);
event_disk_control_set_eject(false, false);
}
/**
* event_check_disk_eject:
* @control : Handle to disk control handle.
@ -377,6 +322,60 @@ static void event_disk_control_set_index(unsigned idx)
}
}
/**
* event_disk_control_append_image:
* @path : Path to disk image.
*
* Appends disk image to disk image list.
**/
void event_disk_control_append_image(const char *path)
{
unsigned new_idx;
char msg[PATH_MAX_LENGTH] = {0};
struct retro_game_info info = {0};
global_t *global = global_get_ptr();
rarch_system_info_t *sysinfo = rarch_system_info_get_ptr();
const struct retro_disk_control_callback *control =
sysinfo ? (const struct retro_disk_control_callback*)&sysinfo->disk_control
: NULL;
if (!control)
return;
event_disk_control_set_eject(true, false);
control->add_image_index();
new_idx = control->get_num_images();
if (!new_idx)
return;
new_idx--;
info.path = path;
control->replace_image_index(new_idx, &info);
snprintf(msg, sizeof(msg), "%s: ", msg_hash_to_str(MSG_APPENDED_DISK));
strlcat(msg, path, sizeof(msg));
RARCH_LOG("%s\n", msg);
rarch_main_msg_queue_push(msg, 0, 180, true);
event_command(EVENT_CMD_AUTOSAVE_DEINIT);
/* TODO: Need to figure out what to do with subsystems case. */
if (!*global->subsystem)
{
/* Update paths for our new image.
* If we actually use append_image, we assume that we
* started out in a single disk case, and that this way
* of doing it makes the most sense. */
rarch_set_paths(path);
rarch_fill_pathnames();
}
event_command(EVENT_CMD_AUTOSAVE_INIT);
event_disk_control_set_index(new_idx);
event_disk_control_set_eject(false, false);
}
/**
* event_check_disk_prev:
* @control : Handle to disk control handle.
@ -534,7 +533,7 @@ static void event_deinit_core(bool reinit)
{
global_t *global = global_get_ptr();
settings_t *settings = config_get_ptr();
rarch_system_info_t *info = rarch_system_info_get_ptr();
pretro_unload_game();
pretro_deinit();
@ -543,13 +542,11 @@ static void event_deinit_core(bool reinit)
/* per-core saves: restore the original path so the config is not affected */
if(settings->sort_savefiles_enable)
strlcpy(global->savefile_dir,orig_savefile_dir,sizeof(global->savefile_dir));
strlcpy(global->dir.savefile, orig_savefile_dir,
sizeof(global->dir.savefile));
if(settings->sort_savestates_enable)
strlcpy(global->savestate_dir,orig_savestate_dir,sizeof(global->savestate_dir));
/* restore system directory if it was set to <content dir> */
if(settings->system_in_content_dir && !strcmp(info->info.library_name,"No Core"))
settings->system_directory[0] = '\0';
strlcpy(global->dir.savestate, orig_savestate_dir,
sizeof(global->dir.savestate));
/* auto overrides: reload the original config */
if(global->overrides_active)
@ -587,7 +584,7 @@ static bool event_load_save_files(void)
if (!global)
return false;
if (!global->savefiles || global->sram_load_disable)
if (!global->savefiles || global->sram.load_disable)
return false;
for (i = 0; i < global->savefiles->size; i++)
@ -606,14 +603,14 @@ static void event_load_auto_state(void)
global_t *global = global_get_ptr();
#ifdef HAVE_NETPLAY
if (global->netplay_enable && !global->netplay_is_spectate)
if (global->netplay.enable && !global->netplay.is_spectate)
return;
#endif
if (!settings->savestate_auto_load)
return;
fill_pathname_noext(savestate_name_auto, global->savestate_name,
fill_pathname_noext(savestate_name_auto, global->name.savestate,
".auto", sizeof(savestate_name_auto));
if (!path_file_exists(savestate_name_auto))
@ -649,9 +646,9 @@ static void event_set_savestate_auto_index(void)
* /foo/path/content.state%d, where %d is the largest number available.
*/
fill_pathname_basedir(state_dir, global->savestate_name,
fill_pathname_basedir(state_dir, global->name.savestate,
sizeof(state_dir));
fill_pathname_base(state_base, global->savestate_name,
fill_pathname_base(state_base, global->name.savestate,
sizeof(state_base));
if (!(dir_list = dir_list_new_special(state_dir, DIR_LIST_PLAIN)))
@ -670,7 +667,7 @@ static void event_set_savestate_auto_index(void)
continue;
end = dir_elem + strlen(dir_elem);
while ((end > dir_elem) && isdigit(end[-1]))
while ((end > dir_elem) && isdigit((int)end[-1]))
end--;
idx = strtoul(end, NULL, 0);
@ -690,16 +687,16 @@ static bool event_init_content(void)
/* No content to be loaded for dummy core,
* just successfully exit. */
if (global->core_type == CORE_TYPE_DUMMY)
if (global->inited.core.type == CORE_TYPE_DUMMY)
return true;
if (!global->libretro_no_content)
if (!global->inited.core.no_content)
rarch_fill_pathnames();
if (!init_content_file())
return false;
if (global->libretro_no_content)
if (global->inited.core.no_content)
return true;
event_set_savestate_auto_index();
@ -723,9 +720,11 @@ static bool event_init_core(void)
/* per-core saves: save the original path */
if(orig_savefile_dir[0] == '\0')
strlcpy(orig_savefile_dir,global->savefile_dir,sizeof(orig_savefile_dir));
strlcpy(orig_savefile_dir, global->dir.savefile,
sizeof(orig_savefile_dir));
if(orig_savestate_dir[0] == '\0')
strlcpy(orig_savestate_dir,global->savestate_dir,sizeof(orig_savestate_dir));
strlcpy(orig_savestate_dir, global->dir.savestate,
sizeof(orig_savestate_dir));
/* auto overrides: apply overrides */
if(settings->auto_overrides_enable)
@ -746,14 +745,14 @@ static bool event_init_core(void)
config_load_remap();
/* per-core saves: reset redirection paths */
if((settings->sort_savestates_enable || settings->sort_savefiles_enable) && !global->libretro_no_content)
set_paths_redirect(global->basename);
if((settings->sort_savestates_enable || settings->sort_savefiles_enable) && !global->inited.core.no_content)
set_paths_redirect(global->name.base);
rarch_verify_api_version();
pretro_init();
global->use_sram = (global->core_type == CORE_TYPE_PLAIN) &&
!global->libretro_no_content;
global->sram.use = (global->inited.core.type == CORE_TYPE_PLAIN) &&
!global->inited.core.no_content;
if (!event_init_content())
return false;
@ -772,11 +771,11 @@ static bool event_save_auto_state(void)
global_t *global = global_get_ptr();
if (!settings->savestate_auto_save ||
(global->core_type == CORE_TYPE_DUMMY) ||
global->libretro_no_content)
(global->inited.core.type == CORE_TYPE_DUMMY) ||
global->inited.core.no_content)
return false;
fill_pathname_noext(savestate_name_auto, global->savestate_name,
fill_pathname_noext(savestate_name_auto, global->name.savestate,
".auto", sizeof(savestate_name_auto));
ret = save_state(savestate_name_auto);
@ -821,8 +820,8 @@ static bool event_save_core_config(void)
if (*settings->menu_config_directory)
strlcpy(config_dir, settings->menu_config_directory,
sizeof(config_dir));
else if (*global->config_path) /* Fallback */
fill_pathname_basedir(config_dir, global->config_path,
else if (*global->path.config) /* Fallback */
fill_pathname_basedir(config_dir, global->path.config,
sizeof(config_dir));
else
{
@ -882,8 +881,8 @@ static bool event_save_core_config(void)
if ((ret = config_save_file(config_path)))
{
strlcpy(global->config_path, config_path,
sizeof(global->config_path));
strlcpy(global->path.config, config_path,
sizeof(global->path.config));
snprintf(msg, sizeof(msg), "Saved new config to \"%s\".",
config_path);
RARCH_LOG("%s\n", msg);
@ -964,12 +963,12 @@ static void event_main_state(unsigned cmd)
if (settings->state_slot > 0)
snprintf(path, sizeof(path), "%s%d",
global->savestate_name, settings->state_slot);
global->name.savestate, settings->state_slot);
else if (settings->state_slot < 0)
fill_pathname_join_delim(path,
global->savestate_name, "auto", '.', sizeof(path));
global->name.savestate, "auto", '.', sizeof(path));
else
strlcpy(path, global->savestate_name, sizeof(path));
strlcpy(path, global->name.savestate, sizeof(path));
if (pretro_serialize_size())
{
@ -1003,11 +1002,11 @@ static bool event_update_system_info(struct retro_system_info *_info,
libretro_get_system_info(settings->libretro, _info,
load_no_content);
#endif
if (!global->core_info)
if (!global->core_info.list)
return false;
if (!core_info_list_get_info(global->core_info,
global->core_info_current, settings->libretro))
if (!core_info_list_get_info(global->core_info.list,
global->core_info.current, settings->libretro))
return false;
return true;
@ -1025,7 +1024,6 @@ bool event_command(enum event_command cmd)
{
unsigned i = 0;
bool boolean = false;
runloop_t *runloop = rarch_main_get_ptr();
driver_t *driver = driver_get_ptr();
global_t *global = global_get_ptr();
settings_t *settings = config_get_ptr();
@ -1056,7 +1054,7 @@ bool event_command(enum event_command cmd)
rarch_environment_cb(RETRO_ENVIRONMENT_SET_LIBRETRO_PATH,
(void*)settings->libretro);
rarch_environment_cb(RETRO_ENVIRONMENT_EXEC,
(void*)global->fullpath);
(void*)global->path.fullpath);
event_command(EVENT_CMD_QUIT);
#endif
break;
@ -1129,6 +1127,14 @@ bool event_command(enum event_command cmd)
event_main_state(cmd);
break;
case EVENT_CMD_SAVE_STATE_DECREMENT:
/* Slot -1 is (auto) slot. */
if (settings->state_slot >= 0)
settings->state_slot--;
break;
case EVENT_CMD_SAVE_STATE_INCREMENT:
settings->state_slot++;
break;
case EVENT_CMD_TAKE_SCREENSHOT:
if (!take_screenshot())
return false;
@ -1142,7 +1148,7 @@ bool event_command(enum event_command cmd)
#endif
rarch_main_data_deinit();
*global->fullpath = '\0';
*global->path.fullpath = '\0';
rarch_main_set_state(RARCH_ACTION_STATE_LOAD_CONTENT);
}
@ -1189,6 +1195,12 @@ bool event_command(enum event_command cmd)
event_command(EVENT_CMD_CHEATS_DEINIT);
event_init_cheats();
break;
case EVENT_CMD_CHEATS_APPLY:
if (!global->cheat)
break;
cheat_manager_apply_cheats(global->cheat);
break;
case EVENT_CMD_REMAPPING_DEINIT:
break;
case EVENT_CMD_REMAPPING_INIT:
@ -1207,6 +1219,7 @@ bool event_command(enum event_command cmd)
global->rewind.state = NULL;
break;
case EVENT_CMD_REWIND_INIT:
if (!driver->netplay_data)
init_rewind();
break;
case EVENT_CMD_REWIND_TOGGLE:
@ -1334,9 +1347,9 @@ bool event_command(enum event_command cmd)
if (!global)
break;
if (global->core_info)
core_info_list_free(global->core_info);
global->core_info = NULL;
if (global->core_info.list)
core_info_list_free(global->core_info.list);
global->core_info.list = NULL;
break;
case EVENT_CMD_DATA_RUNLOOP_FREE:
rarch_main_data_free();
@ -1345,7 +1358,7 @@ bool event_command(enum event_command cmd)
event_command(EVENT_CMD_CORE_INFO_DEINIT);
if (*settings->libretro_directory)
global->core_info = core_info_list_new();
global->core_info.list = core_info_list_new();
break;
case EVENT_CMD_CORE_DEINIT:
{
@ -1409,9 +1422,9 @@ bool event_command(enum event_command cmd)
break;
case EVENT_CMD_RESTART_RETROARCH:
#if defined(GEKKO) && defined(HW_RVL)
fill_pathname_join(global->fullpath, g_defaults.core_dir,
fill_pathname_join(global->path.fullpath, g_defaults.dir.core,
SALAMANDER_FILE,
sizeof(global->fullpath));
sizeof(global->path.fullpath));
#endif
if (driver->frontend_ctx && driver->frontend_ctx->set_fork)
driver->frontend_ctx->set_fork(true, false);
@ -1426,7 +1439,7 @@ bool event_command(enum event_command cmd)
#endif
break;
case EVENT_CMD_PAUSE_CHECKS:
if (runloop->is_paused)
if (rarch_main_is_paused())
{
RARCH_LOG("%s\n", msg_hash_to_str(MSG_PAUSED));
event_command(EVENT_CMD_AUDIO_STOP);
@ -1441,15 +1454,15 @@ bool event_command(enum event_command cmd)
}
break;
case EVENT_CMD_PAUSE_TOGGLE:
runloop->is_paused = !runloop->is_paused;
rarch_main_set_pause(!rarch_main_is_paused());
event_command(EVENT_CMD_PAUSE_CHECKS);
break;
case EVENT_CMD_UNPAUSE:
runloop->is_paused = false;
rarch_main_set_pause(false);
event_command(EVENT_CMD_PAUSE_CHECKS);
break;
case EVENT_CMD_PAUSE:
runloop->is_paused = true;
rarch_main_set_pause(true);
event_command(EVENT_CMD_PAUSE_CHECKS);
break;
case EVENT_CMD_MENU_PAUSE_LIBRETRO:
@ -1508,17 +1521,17 @@ bool event_command(enum event_command cmd)
global->savefiles = NULL;
break;
case EVENT_CMD_SAVEFILES_INIT:
global->use_sram = global->use_sram && !global->sram_save_disable
global->sram.use = global->sram.use && !global->sram.save_disable
#ifdef HAVE_NETPLAY
&& (!driver->netplay_data || !global->netplay_is_client)
&& (!driver->netplay_data || !global->netplay.is_client)
#endif
;
if (!global->use_sram)
if (!global->sram.use)
RARCH_LOG("%s\n",
msg_hash_to_str(MSG_SRAM_WILL_NOT_BE_SAVED));
if (global->use_sram)
if (global->sram.use)
event_command(EVENT_CMD_AUTOSAVE_INIT);
break;
case EVENT_CMD_MSG_QUEUE_DEINIT:
@ -1707,6 +1720,9 @@ bool event_command(enum event_command cmd)
case EVENT_CMD_VOLUME_DOWN:
event_set_volume(-0.5f);
break;
case EVENT_CMD_SET_FRAME_LIMIT:
rarch_main_set_frame_limit_last_time();
break;
case EVENT_CMD_NONE:
default:
return false;

View File

@ -41,6 +41,8 @@ enum event_command
EVENT_CMD_UNLOAD_CORE,
EVENT_CMD_LOAD_STATE,
EVENT_CMD_SAVE_STATE,
EVENT_CMD_SAVE_STATE_DECREMENT,
EVENT_CMD_SAVE_STATE_INCREMENT,
/* Takes screenshot. */
EVENT_CMD_TAKE_SCREENSHOT,
/* Initializes dummy core. */
@ -149,6 +151,8 @@ enum event_command
EVENT_CMD_CHEATS_INIT,
/* Deinitializes cheats. */
EVENT_CMD_CHEATS_DEINIT,
/* Apply cheats. */
EVENT_CMD_CHEATS_APPLY,
/* Deinitializes network system. */
EVENT_CMD_NETWORK_DEINIT,
/* Initializes network system. */
@ -196,6 +200,7 @@ enum event_command
EVENT_CMD_REMAPPING_DEINIT,
EVENT_CMD_VOLUME_UP,
EVENT_CMD_VOLUME_DOWN,
EVENT_CMD_SET_FRAME_LIMIT,
EVENT_CMD_DATA_RUNLOOP_FREE
};

View File

@ -37,7 +37,7 @@ enum
VIDEO_XENON360,
VIDEO_XDK_D3D,
VIDEO_PSP1,
VIDEO_VITA,
VIDEO_VITA2D,
VIDEO_CTR,
VIDEO_D3D9,
VIDEO_VG,
@ -66,7 +66,7 @@ enum
AUDIO_XENON360,
AUDIO_WII,
AUDIO_RWEBAUDIO,
AUDIO_PSP1,
AUDIO_PSP,
AUDIO_CTR,
AUDIO_NULL,
@ -143,8 +143,8 @@ enum
#define VIDEO_DEFAULT_DRIVER VIDEO_D3D9
#elif defined(HAVE_VG)
#define VIDEO_DEFAULT_DRIVER VIDEO_VG
#elif defined(SN_TARGET_PSP2)
#define VIDEO_DEFAULT_DRIVER VIDEO_VITA
#elif defined(HAVE_VITA2D)
#define VIDEO_DEFAULT_DRIVER VIDEO_VITA2D
#elif defined(PSP)
#define VIDEO_DEFAULT_DRIVER VIDEO_PSP1
#elif defined(_3DS)
@ -167,8 +167,8 @@ enum
#define AUDIO_DEFAULT_DRIVER AUDIO_XENON360
#elif defined(GEKKO)
#define AUDIO_DEFAULT_DRIVER AUDIO_WII
#elif defined(PSP)
#define AUDIO_DEFAULT_DRIVER AUDIO_PSP1
#elif defined(PSP) || defined(VITA)
#define AUDIO_DEFAULT_DRIVER AUDIO_PSP
#elif defined(_3DS)
#define AUDIO_DEFAULT_DRIVER AUDIO_CTR
#elif defined(HAVE_ALSA) && defined(HAVE_VIDEOCORE)
@ -231,7 +231,7 @@ enum
#define INPUT_DEFAULT_DRIVER INPUT_DINPUT
#elif defined(__CELLOS_LV2__)
#define INPUT_DEFAULT_DRIVER INPUT_PS3
#elif (defined(SN_TARGET_PSP2) || defined(PSP))
#elif defined(PSP) || defined(VITA)
#define INPUT_DEFAULT_DRIVER INPUT_PSP
#elif defined(_3DS)
#define INPUT_DEFAULT_DRIVER INPUT_CTR
@ -265,7 +265,7 @@ enum
#define JOYPAD_DEFAULT_DRIVER JOYPAD_GX
#elif defined(_XBOX)
#define JOYPAD_DEFAULT_DRIVER JOYPAD_XDK
#elif defined(PSP)
#elif defined(PSP) || defined(VITA)
#define JOYPAD_DEFAULT_DRIVER JOYPAD_PSP
#elif defined(_3DS)
#define JOYPAD_DEFAULT_DRIVER JOYPAD_CTR
@ -317,10 +317,10 @@ enum
#define MENU_DEFAULT_DRIVER MENU_RMENU
#elif defined(HAVE_RMENU_XUI)
#define MENU_DEFAULT_DRIVER MENU_RMENU_XUI
#elif defined(MAC_OS_X_VERSION_10_6)
#define MENU_DEFAULT_DRIVER MENU_XMB
#elif defined(IOS) || defined(ANDROID) || defined(__CELLOS_LV2__)
#define MENU_DEFAULT_DRIVER MENU_GLUI
#elif defined(MAC_OS_X_VERSION_10_6)
#define MENU_DEFAULT_DRIVER MENU_XMB
#else
#define MENU_DEFAULT_DRIVER MENU_RGUI
#endif
@ -599,7 +599,11 @@ static const bool allow_rotate = true;
static const bool audio_enable = true;
/* Output samplerate. */
#ifdef GEKKO
static const unsigned out_rate = 32000;
#else
static const unsigned out_rate = 48000;
#endif
/* Audio device (e.g. hw:0,0 or /dev/audio). If NULL, will use defaults. */
static const char *audio_device = NULL;
@ -677,10 +681,7 @@ static const bool savestate_auto_load = false;
static const float slowmotion_ratio = 3.0;
/* Maximum fast forward ratio. */
static const float fastforward_ratio = 1.0;
/* Throttle fast forward. */
static const bool fastforward_ratio_throttle_enable = false;
static const float fastforward_ratio = 0.0;
/* Enable stdin/network command interface. */
static const bool network_cmd_enable = false;

View File

@ -25,7 +25,6 @@
#include "input/input_common.h"
#include "input/input_keymaps.h"
#include "input/input_remapping.h"
#include "configuration.h"
#include "general.h"
#include "system.h"
@ -114,8 +113,12 @@ const char *config_get_default_audio(void)
return "ps3";
case AUDIO_WII:
return "gx";
case AUDIO_PSP1:
return "psp1";
case AUDIO_PSP:
#ifdef VITA
return "vita";
#else
return "psp";
#endif
case AUDIO_CTR:
return "ctr";
case AUDIO_RWEBAUDIO:
@ -186,8 +189,8 @@ const char *config_get_default_video(void)
return "d3d";
case VIDEO_PSP1:
return "psp1";
case VIDEO_VITA:
return "vita";
case VIDEO_VITA2D:
return "vita2d";
case VIDEO_CTR:
return "ctr";
case VIDEO_XVIDEO:
@ -231,7 +234,11 @@ const char *config_get_default_input(void)
case INPUT_PS3:
return "ps3";
case INPUT_PSP:
#ifdef VITA
return "vita";
#else
return "psp";
#endif
case INPUT_CTR:
return "ctr";
case INPUT_SDL:
@ -287,7 +294,11 @@ const char *config_get_default_joypad(void)
case JOYPAD_XDK:
return "xdk";
case JOYPAD_PSP:
#ifdef VITA
return "vita";
#else
return "psp";
#endif
case JOYPAD_CTR:
return "ctr";
case JOYPAD_DINPUT:
@ -538,7 +549,6 @@ static void config_set_defaults(void)
settings->rewind_granularity = rewind_granularity;
settings->slowmotion_ratio = slowmotion_ratio;
settings->fastforward_ratio = fastforward_ratio;
settings->fastforward_ratio_throttle_enable = fastforward_ratio_throttle_enable;
settings->pause_nonactive = pause_nonactive;
settings->autosave_interval = autosave_interval;
@ -641,11 +651,13 @@ static void config_set_defaults(void)
settings->input.autodetect_enable = input_autodetect_enable;
*settings->input.keyboard_layout = '\0';
settings->osk.enable = true;
for (i = 0; i < MAX_USERS; i++)
{
settings->input.joypad_map[i] = i;
settings->input.analog_dpad_mode[i] = ANALOG_DPAD_NONE;
if (!global->has_set_libretro_device[i])
if (!global->has_set.libretro_device[i])
settings->input.libretro_device[i] = RETRO_DEVICE_JOYPAD;
}
@ -655,21 +667,21 @@ static void config_set_defaults(void)
/* Make sure settings from other configs carry over into defaults
* for another config. */
if (!global->has_set_save_path)
*global->savefile_dir = '\0';
if (!global->has_set_state_path)
*global->savestate_dir = '\0';
if (!global->has_set.save_path)
*global->dir.savefile = '\0';
if (!global->has_set.state_path)
*global->dir.savestate = '\0';
*settings->libretro_info_path = '\0';
if (!global->has_set_libretro_directory)
if (!global->has_set.libretro_directory)
*settings->libretro_directory = '\0';
if (!global->has_set_ups_pref)
global->ups_pref = false;
if (!global->has_set_bps_pref)
global->bps_pref = false;
if (!global->has_set_ips_pref)
global->ips_pref = false;
if (!global->has_set.ups_pref)
global->patch.ups_pref = false;
if (!global->has_set.bps_pref)
global->patch.bps_pref = false;
if (!global->has_set.ips_pref)
global->patch.ips_pref = false;
*global->record.output_dir = '\0';
*global->record.config_dir = '\0';
@ -728,117 +740,117 @@ static void config_set_defaults(void)
global->console.sound.mode = SOUND_MODE_NORMAL;
#endif
if (*g_defaults.wallpapers_dir)
if (*g_defaults.dir.wallpapers)
strlcpy(settings->dynamic_wallpapers_directory,
g_defaults.wallpapers_dir, sizeof(settings->dynamic_wallpapers_directory));
if (*g_defaults.remap_dir)
g_defaults.dir.wallpapers, sizeof(settings->dynamic_wallpapers_directory));
if (*g_defaults.dir.remap)
strlcpy(settings->input_remapping_directory,
g_defaults.remap_dir, sizeof(settings->input_remapping_directory));
if (*g_defaults.extraction_dir)
g_defaults.dir.remap, sizeof(settings->input_remapping_directory));
if (*g_defaults.dir.extraction)
strlcpy(settings->extraction_directory,
g_defaults.extraction_dir, sizeof(settings->extraction_directory));
if (*g_defaults.audio_filter_dir)
g_defaults.dir.extraction, sizeof(settings->extraction_directory));
if (*g_defaults.dir.audio_filter)
strlcpy(settings->audio.filter_dir,
g_defaults.audio_filter_dir, sizeof(settings->audio.filter_dir));
if (*g_defaults.video_filter_dir)
g_defaults.dir.audio_filter, sizeof(settings->audio.filter_dir));
if (*g_defaults.dir.video_filter)
strlcpy(settings->video.filter_dir,
g_defaults.video_filter_dir, sizeof(settings->video.filter_dir));
if (*g_defaults.assets_dir)
g_defaults.dir.video_filter, sizeof(settings->video.filter_dir));
if (*g_defaults.dir.assets)
strlcpy(settings->assets_directory,
g_defaults.assets_dir, sizeof(settings->assets_directory));
if (*g_defaults.core_assets_dir)
g_defaults.dir.assets, sizeof(settings->assets_directory));
if (*g_defaults.dir.core_assets)
strlcpy(settings->core_assets_directory,
g_defaults.core_assets_dir, sizeof(settings->core_assets_directory));
if (*g_defaults.playlist_dir)
g_defaults.dir.core_assets, sizeof(settings->core_assets_directory));
if (*g_defaults.dir.playlist)
strlcpy(settings->playlist_directory,
g_defaults.playlist_dir, sizeof(settings->playlist_directory));
if (*g_defaults.core_dir)
g_defaults.dir.playlist, sizeof(settings->playlist_directory));
if (*g_defaults.dir.core)
fill_pathname_expand_special(settings->libretro_directory,
g_defaults.core_dir, sizeof(settings->libretro_directory));
if (*g_defaults.core_path)
strlcpy(settings->libretro, g_defaults.core_path,
g_defaults.dir.core, sizeof(settings->libretro_directory));
if (*g_defaults.path.core)
strlcpy(settings->libretro, g_defaults.path.core,
sizeof(settings->libretro));
if (*g_defaults.database_dir)
strlcpy(settings->content_database, g_defaults.database_dir,
if (*g_defaults.dir.database)
strlcpy(settings->content_database, g_defaults.dir.database,
sizeof(settings->content_database));
if (*g_defaults.cursor_dir)
strlcpy(settings->cursor_directory, g_defaults.cursor_dir,
if (*g_defaults.dir.cursor)
strlcpy(settings->cursor_directory, g_defaults.dir.cursor,
sizeof(settings->cursor_directory));
if (*g_defaults.cheats_dir)
strlcpy(settings->cheat_database, g_defaults.cheats_dir,
if (*g_defaults.dir.cheats)
strlcpy(settings->cheat_database, g_defaults.dir.cheats,
sizeof(settings->cheat_database));
if (*g_defaults.core_info_dir)
if (*g_defaults.dir.core_info)
fill_pathname_expand_special(settings->libretro_info_path,
g_defaults.core_info_dir, sizeof(settings->libretro_info_path));
g_defaults.dir.core_info, sizeof(settings->libretro_info_path));
#ifdef HAVE_OVERLAY
if (*g_defaults.overlay_dir)
if (*g_defaults.dir.overlay)
{
fill_pathname_expand_special(global->overlay_dir,
g_defaults.overlay_dir, sizeof(global->overlay_dir));
fill_pathname_expand_special(global->dir.overlay,
g_defaults.dir.overlay, sizeof(global->dir.overlay));
#ifdef RARCH_MOBILE
if (!*settings->input.overlay)
fill_pathname_join(settings->input.overlay,
global->overlay_dir,
global->dir.overlay,
"gamepads/retropad/retropad.cfg",
sizeof(settings->input.overlay));
#endif
}
if (*g_defaults.osk_overlay_dir)
if (*g_defaults.dir.osk_overlay)
{
fill_pathname_expand_special(global->osk_overlay_dir,
g_defaults.osk_overlay_dir, sizeof(global->osk_overlay_dir));
fill_pathname_expand_special(global->dir.osk_overlay,
g_defaults.dir.osk_overlay, sizeof(global->dir.osk_overlay));
#ifdef RARCH_MOBILE
if (!*settings->input.overlay)
if (!*settings->osk.overlay)
fill_pathname_join(settings->osk.overlay,
global->osk_overlay_dir,
"overlays/keyboards/US-101/US-101.cfg",
global->dir.osk_overlay,
"keyboards/modular-keyboard/opaque/big.cfg",
sizeof(settings->osk.overlay));
#endif
}
else
strlcpy(global->osk_overlay_dir,
global->overlay_dir, sizeof(global->osk_overlay_dir));
strlcpy(global->dir.osk_overlay,
global->dir.overlay, sizeof(global->dir.osk_overlay));
#endif
#ifdef HAVE_MENU
if (*g_defaults.menu_config_dir)
if (*g_defaults.dir.menu_config)
strlcpy(settings->menu_config_directory,
g_defaults.menu_config_dir,
g_defaults.dir.menu_config,
sizeof(settings->menu_config_directory));
#endif
if (*g_defaults.shader_dir)
if (*g_defaults.dir.shader)
fill_pathname_expand_special(settings->video.shader_dir,
g_defaults.shader_dir, sizeof(settings->video.shader_dir));
if (*g_defaults.autoconfig_dir)
g_defaults.dir.shader, sizeof(settings->video.shader_dir));
if (*g_defaults.dir.autoconfig)
strlcpy(settings->input.autoconfig_dir,
g_defaults.autoconfig_dir,
g_defaults.dir.autoconfig,
sizeof(settings->input.autoconfig_dir));
if (!global->has_set_state_path && *g_defaults.savestate_dir)
strlcpy(global->savestate_dir,
g_defaults.savestate_dir, sizeof(global->savestate_dir));
if (!global->has_set_save_path && *g_defaults.sram_dir)
strlcpy(global->savefile_dir,
g_defaults.sram_dir, sizeof(global->savefile_dir));
if (*g_defaults.system_dir)
if (!global->has_set.state_path && *g_defaults.dir.savestate)
strlcpy(global->dir.savestate,
g_defaults.dir.savestate, sizeof(global->dir.savestate));
if (!global->has_set.save_path && *g_defaults.dir.sram)
strlcpy(global->dir.savefile,
g_defaults.dir.sram, sizeof(global->dir.savefile));
if (*g_defaults.dir.system)
strlcpy(settings->system_directory,
g_defaults.system_dir, sizeof(settings->system_directory));
if (*g_defaults.screenshot_dir)
g_defaults.dir.system, sizeof(settings->system_directory));
if (*g_defaults.dir.screenshot)
strlcpy(settings->screenshot_directory,
g_defaults.screenshot_dir,
g_defaults.dir.screenshot,
sizeof(settings->screenshot_directory));
if (*g_defaults.resampler_dir)
if (*g_defaults.dir.resampler)
strlcpy(settings->resampler_directory,
g_defaults.resampler_dir,
g_defaults.dir.resampler,
sizeof(settings->resampler_directory));
if (*g_defaults.content_history_dir)
if (*g_defaults.dir.content_history)
strlcpy(settings->content_history_directory,
g_defaults.content_history_dir,
g_defaults.dir.content_history,
sizeof(settings->content_history_directory));
if (*g_defaults.config_path)
fill_pathname_expand_special(global->config_path,
g_defaults.config_path, sizeof(global->config_path));
if (*g_defaults.path.config)
fill_pathname_expand_special(global->path.config,
g_defaults.path.config, sizeof(global->path.config));
settings->config_save_on_exit = config_save_on_exit;
@ -1021,7 +1033,7 @@ static config_file_t *open_default_config_file(void)
"retroarch.cfg", sizeof(skeleton_conf));
conf = config_file_new(skeleton_conf);
if (conf)
RARCH_WARN("Using skeleton config \"%s\" as base for a new config file.\n", skeleton_conf);
RARCH_WARN("Config: using skeleton config \"%s\" as base for a new config file.\n", skeleton_conf);
else
conf = config_file_new(NULL);
@ -1041,7 +1053,7 @@ static config_file_t *open_default_config_file(void)
return NULL;
}
RARCH_WARN("Created new config file in: \"%s\".\n", conf_path);
RARCH_WARN("Config: Created new config file in: \"%s\".\n", conf_path);
}
}
}
@ -1050,8 +1062,8 @@ static config_file_t *open_default_config_file(void)
if (!conf)
return NULL;
strlcpy(global->config_path, conf_path,
sizeof(global->config_path));
strlcpy(global->path.config, conf_path,
sizeof(global->path.config));
return conf;
}
@ -1199,17 +1211,17 @@ static bool config_load_file(const char *path, bool set_defaults)
if (set_defaults)
config_set_defaults();
strlcpy(tmp_append_path, global->append_config_path,
strlcpy(tmp_append_path, global->path.append_config,
sizeof(tmp_append_path));
extra_path = strtok_r(tmp_append_path, "|", &save);
while (extra_path)
{
bool ret = false;
RARCH_LOG("Appending config \"%s\"\n", extra_path);
RARCH_LOG("Config: appending config \"%s\"\n", extra_path);
ret = config_append_file(conf, extra_path);
if (!ret)
RARCH_ERR("Failed to append config \"%s\"\n", extra_path);
RARCH_ERR("Config: failed to append config \"%s\"\n", extra_path);
extra_path = strtok_r(NULL, "|", &save);
}
#if 0
@ -1420,24 +1432,24 @@ static bool config_load_file(const char *path, bool set_defaults)
snprintf(buf, sizeof(buf), "input_player%u_analog_dpad_mode", i + 1);
CONFIG_GET_INT_BASE(conf, settings, input.analog_dpad_mode[i], buf);
if (!global->has_set_libretro_device[i])
if (!global->has_set.libretro_device[i])
{
snprintf(buf, sizeof(buf), "input_libretro_device_p%u", i + 1);
CONFIG_GET_INT_BASE(conf, settings, input.libretro_device[i], buf);
}
}
if (!global->has_set_ups_pref)
if (!global->has_set.ups_pref)
{
CONFIG_GET_BOOL_BASE(conf, global, ups_pref, "ups_pref");
CONFIG_GET_BOOL_BASE(conf, global, patch.ups_pref, "ups_pref");
}
if (!global->has_set_bps_pref)
if (!global->has_set.bps_pref)
{
CONFIG_GET_BOOL_BASE(conf, global, bps_pref, "bps_pref");
CONFIG_GET_BOOL_BASE(conf, global, patch.bps_pref, "bps_pref");
}
if (!global->has_set_ips_pref)
if (!global->has_set.ips_pref)
{
CONFIG_GET_BOOL_BASE(conf, global, ips_pref, "ips_pref");
CONFIG_GET_BOOL_BASE(conf, global, patch.ips_pref, "ips_pref");
}
/* Audio settings. */
@ -1474,9 +1486,9 @@ static bool config_load_file(const char *path, bool set_defaults)
CONFIG_GET_STRING_BASE(conf, settings, input.joypad_driver, "input_joypad_driver");
CONFIG_GET_STRING_BASE(conf, settings, input.keyboard_layout, "input_keyboard_layout");
if (!global->has_set_libretro)
if (!global->has_set.libretro)
config_get_path(conf, "libretro_path", settings->libretro, sizeof(settings->libretro));
if (!global->has_set_libretro_directory)
if (!global->has_set.libretro_directory)
config_get_path(conf, "libretro_directory", settings->libretro_directory, sizeof(settings->libretro_directory));
/* Safe-guard against older behavior. */
@ -1551,7 +1563,7 @@ static bool config_load_file(const char *path, bool set_defaults)
#endif
CONFIG_GET_INT_BASE(conf, settings, libretro_log_level, "libretro_log_level");
if (!global->has_set_verbosity)
if (!global->has_set.verbosity)
CONFIG_GET_BOOL_BASE(conf, global, verbosity, "log_verbosity");
CONFIG_GET_BOOL_BASE(conf, global, perfcnt_enable, "perfcnt_enable");
@ -1562,9 +1574,9 @@ static bool config_load_file(const char *path, bool set_defaults)
sizeof(global->record.config_dir));
#ifdef HAVE_OVERLAY
config_get_path(conf, "overlay_directory", global->overlay_dir, sizeof(global->overlay_dir));
if (!strcmp(global->overlay_dir, "default"))
*global->overlay_dir = '\0';
config_get_path(conf, "overlay_directory", global->dir.overlay, sizeof(global->dir.overlay));
if (!strcmp(global->dir.overlay, "default"))
*global->dir.overlay = '\0';
config_get_path(conf, "input_overlay", settings->input.overlay, sizeof(settings->input.overlay));
CONFIG_GET_BOOL_BASE(conf, settings, input.overlay_enable, "input_overlay_enable");
@ -1573,9 +1585,9 @@ static bool config_load_file(const char *path, bool set_defaults)
CONFIG_GET_FLOAT_BASE(conf, settings, input.overlay_opacity, "input_overlay_opacity");
CONFIG_GET_FLOAT_BASE(conf, settings, input.overlay_scale, "input_overlay_scale");
config_get_path(conf, "osk_overlay_directory", global->osk_overlay_dir, sizeof(global->osk_overlay_dir));
if (!strcmp(global->osk_overlay_dir, "default"))
*global->osk_overlay_dir = '\0';
config_get_path(conf, "osk_overlay_directory", global->dir.osk_overlay, sizeof(global->dir.osk_overlay));
if (!strcmp(global->dir.osk_overlay, "default"))
*global->dir.osk_overlay = '\0';
config_get_path(conf, "input_osk_overlay", settings->osk.overlay, sizeof(settings->osk.overlay));
CONFIG_GET_BOOL_BASE(conf, settings, osk.enable, "input_osk_overlay_enable");
@ -1599,11 +1611,8 @@ static bool config_load_file(const char *path, bool set_defaults)
/* Sanitize fastforward_ratio value - previously range was -1
* and up (with 0 being skipped) */
if (settings->fastforward_ratio <= 0.0f)
settings->fastforward_ratio = 1.0f;
CONFIG_GET_BOOL_BASE(conf, settings, fastforward_ratio_throttle_enable,
"fastforward_ratio_throttle_enable");
if (settings->fastforward_ratio < 0.0f)
settings->fastforward_ratio = 0.0f;
CONFIG_GET_BOOL_BASE(conf, settings, pause_nonactive, "pause_nonactive");
CONFIG_GET_INT_BASE(conf, settings, autosave_interval, "autosave_interval");
@ -1635,58 +1644,58 @@ static bool config_load_file(const char *path, bool set_defaults)
CONFIG_GET_BOOL_BASE(conf, settings, input.autodetect_enable, "input_autodetect_enable");
CONFIG_GET_PATH_BASE(conf, settings, input.autoconfig_dir, "joypad_autoconfig_dir");
if (!global->has_set_username)
if (!global->has_set.username)
CONFIG_GET_PATH_BASE(conf, settings, username, "netplay_nickname");
CONFIG_GET_INT_BASE(conf, settings, user_language, "user_language");
#ifdef HAVE_NETPLAY
if (!global->has_set_netplay_mode)
CONFIG_GET_BOOL_BASE(conf, global, netplay_is_spectate,
if (!global->has_set.netplay_mode)
CONFIG_GET_BOOL_BASE(conf, global, netplay.is_spectate,
"netplay_spectator_mode_enable");
if (!global->has_set_netplay_mode)
CONFIG_GET_BOOL_BASE(conf, global, netplay_is_client, "netplay_mode");
if (!global->has_set_netplay_ip_address)
CONFIG_GET_PATH_BASE(conf, global, netplay_server, "netplay_ip_address");
if (!global->has_set_netplay_delay_frames)
CONFIG_GET_INT_BASE(conf, global, netplay_sync_frames, "netplay_delay_frames");
if (!global->has_set_netplay_ip_port)
CONFIG_GET_INT_BASE(conf, global, netplay_port, "netplay_ip_port");
if (!global->has_set.netplay_mode)
CONFIG_GET_BOOL_BASE(conf, global, netplay.is_client, "netplay_mode");
if (!global->has_set.netplay_ip_address)
CONFIG_GET_PATH_BASE(conf, global, netplay.server, "netplay_ip_address");
if (!global->has_set.netplay_delay_frames)
CONFIG_GET_INT_BASE(conf, global, netplay.sync_frames, "netplay_delay_frames");
if (!global->has_set.netplay_ip_port)
CONFIG_GET_INT_BASE(conf, global, netplay.port, "netplay_ip_port");
#endif
CONFIG_GET_BOOL_BASE(conf, settings, config_save_on_exit, "config_save_on_exit");
if (!global->has_set_save_path &&
if (!global->has_set.save_path &&
config_get_path(conf, "savefile_directory", tmp_str, sizeof(tmp_str)))
{
if (!strcmp(tmp_str, "default"))
strlcpy(global->savefile_dir, g_defaults.sram_dir,
sizeof(global->savefile_dir));
strlcpy(global->dir.savefile, g_defaults.dir.sram,
sizeof(global->dir.savefile));
else if (path_is_directory(tmp_str))
{
strlcpy(global->savefile_dir, tmp_str,
sizeof(global->savefile_dir));
strlcpy(global->savefile_name, tmp_str,
sizeof(global->savefile_name));
fill_pathname_dir(global->savefile_name, global->basename,
".srm", sizeof(global->savefile_name));
strlcpy(global->dir.savefile, tmp_str,
sizeof(global->dir.savefile));
strlcpy(global->name.savefile, tmp_str,
sizeof(global->name.savefile));
fill_pathname_dir(global->name.savefile, global->name.base,
".srm", sizeof(global->name.savefile));
}
else
RARCH_WARN("savefile_directory is not a directory, ignoring ...\n");
}
if (!global->has_set_state_path &&
if (!global->has_set.state_path &&
config_get_path(conf, "savestate_directory", tmp_str, sizeof(tmp_str)))
{
if (!strcmp(tmp_str, "default"))
strlcpy(global->savestate_dir, g_defaults.savestate_dir,
sizeof(global->savestate_dir));
strlcpy(global->dir.savestate, g_defaults.dir.savestate,
sizeof(global->dir.savestate));
else if (path_is_directory(tmp_str))
{
strlcpy(global->savestate_dir, tmp_str,
sizeof(global->savestate_dir));
strlcpy(global->savestate_name, tmp_str,
sizeof(global->savestate_name));
fill_pathname_dir(global->savestate_name, global->basename,
".state", sizeof(global->savestate_name));
strlcpy(global->dir.savestate, tmp_str,
sizeof(global->dir.savestate));
strlcpy(global->name.savestate, tmp_str,
sizeof(global->name.savestate));
fill_pathname_dir(global->name.savestate, global->name.base,
".state", sizeof(global->name.savestate));
}
else
RARCH_WARN("savestate_directory is not a directory, ignoring ...\n");
@ -1704,7 +1713,7 @@ static bool config_load_file(const char *path, bool set_defaults)
else
{
fill_pathname_resolve_relative(settings->content_history_path,
global->config_path, "content_history.lpl",
global->path.config, "content_history.lpl",
sizeof(settings->content_history_path));
}
}
@ -1712,17 +1721,14 @@ static bool config_load_file(const char *path, bool set_defaults)
if (!config_get_path(conf, "system_directory",
settings->system_directory, sizeof(settings->system_directory)))
{
RARCH_WARN("system_directory is not set in config. Assuming system directory is same folder as game: \"%s\".\n",
settings->system_directory);
settings->system_in_content_dir = true;
RARCH_WARN("SYSTEM DIR is empty, assume CONTENT DIR\n");
*settings->system_directory = '\0';
}
if (!strcmp(settings->system_directory, "default"))
{
RARCH_WARN("system_directory is not set in config. Assuming system directory is same folder as game: \"%s\".\n",
settings->system_directory);
RARCH_WARN("SYSTEM DIR is empty, assume CONTENT DIR\n");
*settings->system_directory = '\0';
settings->system_in_content_dir = true;
}
config_read_keybinds_conf(conf);
@ -1752,12 +1758,12 @@ static void config_load_core_specific(void)
settings_t *settings = config_get_ptr();
global_t *global = global_get_ptr();
*global->core_specific_config_path = '\0';
*global->path.core_specific_config = '\0';
if (!*settings->libretro)
return;
#ifdef HAVE_DYNAMIC
if (global->core_type == CORE_TYPE_DUMMY)
if (global->inited.core.type == CORE_TYPE_DUMMY)
return;
#endif
@ -1766,35 +1772,35 @@ static void config_load_core_specific(void)
{
path_resolve_realpath(settings->menu_config_directory,
sizeof(settings->menu_config_directory));
strlcpy(global->core_specific_config_path,
strlcpy(global->path.core_specific_config,
settings->menu_config_directory,
sizeof(global->core_specific_config_path));
sizeof(global->path.core_specific_config));
}
else
#endif
{
/* Use original config file's directory as a fallback. */
fill_pathname_basedir(global->core_specific_config_path,
global->config_path, sizeof(global->core_specific_config_path));
fill_pathname_basedir(global->path.core_specific_config,
global->path.config, sizeof(global->path.core_specific_config));
}
fill_pathname_dir(global->core_specific_config_path, settings->libretro,
".cfg", sizeof(global->core_specific_config_path));
fill_pathname_dir(global->path.core_specific_config, settings->libretro,
".cfg", sizeof(global->path.core_specific_config));
if (settings->core_specific_config)
{
char tmp[PATH_MAX_LENGTH] = {0};
/* Toggle has_save_path to false so it resets */
global->has_set_save_path = false;
global->has_set_state_path = false;
global->has_set.save_path = false;
global->has_set.state_path = false;
strlcpy(tmp, settings->libretro, sizeof(tmp));
RARCH_LOG("Loading core-specific config from: %s.\n",
global->core_specific_config_path);
RARCH_LOG("Config: loading core-specific config from: %s.\n",
global->path.core_specific_config);
if (!config_load_file(global->core_specific_config_path, true))
RARCH_WARN("Core-specific config not found, reusing last config.\n");
if (!config_load_file(global->path.core_specific_config, true))
RARCH_WARN("Config: core-specific config not found, reusing last config.\n");
/* Force some parameters which are implied when using core specific configs.
* Don't have the core config file overwrite the libretro path. */
@ -1804,8 +1810,8 @@ static void config_load_core_specific(void)
settings->core_specific_config = true;
/* Reset save paths */
global->has_set_save_path = true;
global->has_set_state_path = true;
global->has_set.save_path = true;
global->has_set.state_path = true;
}
}
@ -1842,8 +1848,8 @@ bool config_load_override(void)
if (!info->info.library_name || !strcmp(info->info.library_name,"No Core"))
return false;
RARCH_LOG("Game name: %s\n", global->basename);
RARCH_LOG("Core name: %s\n", info->info.library_name);
RARCH_LOG("Overrides: core name: %s\n", info->info.library_name);
RARCH_LOG("Overrides: game name: %s\n", global->name.base);
if (!global || !settings )
{
@ -1856,18 +1862,18 @@ bool config_load_override(void)
* fallback to the location of the current configuration file. */
if (settings->menu_config_directory[0] != '\0')
strlcpy(config_directory, settings->menu_config_directory, PATH_MAX_LENGTH);
else if (global->config_path[0] != '\0')
fill_pathname_basedir(config_directory, global->config_path, PATH_MAX_LENGTH);
else if (global->path.config[0] != '\0')
fill_pathname_basedir(config_directory, global->path.config, PATH_MAX_LENGTH);
else
{
RARCH_WARN("No config directory set under Settings > Path and retroarch.cfg not found.\n");
RARCH_WARN("Overrides: no config directory set\n");
return false;
}
RARCH_LOG("Config directory: %s\n", config_directory);
RARCH_LOG("Overrides: config directory: %s\n", config_directory);
core_name = info->info.library_name;
game_name = path_basename(global->basename);
game_name = path_basename(global->name.base);
/* Concatenate strings into full paths for core_path, game_path */
fill_pathname_join(core_path, config_directory, core_name, PATH_MAX_LENGTH);
@ -1886,15 +1892,15 @@ bool config_load_override(void)
{
if (settings->core_specific_config)
{
RARCH_LOG("Can't use overrides in conjunction with per-core configs, disabling overrides\n");
RARCH_LOG("Overrides: can't use overrides with with per-core configs, disabling overrides\n");
return false;
}
RARCH_LOG("Core-specific overrides found at %s. Appending.\n", core_path);
strlcpy(global->append_config_path, core_path, sizeof(global->append_config_path));
RARCH_LOG("Overrides: core-specific overrides found at %s\n", core_path);
strlcpy(global->path.append_config, core_path, sizeof(global->path.append_config));
should_append = true;
}
else
RARCH_LOG("No core-specific overrides found at %s.\n", core_path);
RARCH_LOG("Overrides: no core-specific overrides found at %s\n", core_path);
/* Create a new config file from game_path */
new_conf = config_file_new(game_path);
@ -1902,19 +1908,19 @@ bool config_load_override(void)
/* If a game override exists, add it's location to append_config_path */
if (new_conf)
{
RARCH_LOG("Game-specific overrides found at %s. Appending.\n", game_path);
RARCH_LOG("Overrides: game-specific overrides found at %s\n", game_path);
if (should_append)
{
strlcat(global->append_config_path, "|", sizeof(global->append_config_path));
strlcat(global->append_config_path, game_path, sizeof(global->append_config_path));
strlcat(global->path.append_config, "|", sizeof(global->path.append_config));
strlcat(global->path.append_config, game_path, sizeof(global->path.append_config));
}
else
strlcpy(global->append_config_path, game_path, sizeof(global->append_config_path));
strlcpy(global->path.append_config, game_path, sizeof(global->path.append_config));
should_append = true;
}
else
RARCH_LOG("No game-specific overrides found at %s.\n", game_path);
RARCH_LOG("Overrides: no game-specific overrides found at %s\n", game_path);
/* Re-load the configuration with any overrides that might have been found */
if (should_append)
@ -1923,14 +1929,14 @@ bool config_load_override(void)
if (settings->core_specific_config)
{
RARCH_WARN("Can't use overrides in conjunction with per-core configs, disabling overrides\n");
RARCH_LOG("Overrides: can't use overrides with with per-core configs, disabling overrides\n");
return false;
}
#ifdef HAVE_NETPLAY
if (global->netplay_enable)
if (global->netplay.enable)
{
RARCH_WARN("Can't use overrides in conjunction with netplay, disabling overrides\n");
RARCH_WARN("Overrides: can't use overrides in conjunction with netplay, disabling overrides\n");
return false;
}
#endif
@ -1939,10 +1945,10 @@ bool config_load_override(void)
strlcpy(buf,settings->libretro,sizeof(buf));
/* Toggle has_save_path to false so it resets */
global->has_set_save_path = false;
global->has_set_state_path = false;
global->has_set.save_path = false;
global->has_set.state_path = false;
if (config_load_file(global->config_path, false))
if (config_load_file(global->path.config, false))
{
/* Restore the libretro_path we're using
* since it will be overwritten by the override when reloading. */
@ -1950,8 +1956,8 @@ bool config_load_override(void)
rarch_main_msg_queue_push("Configuration override loaded", 1, 100, true);
/* Reset save paths */
global->has_set_save_path = true;
global->has_set_state_path = true;
global->has_set.save_path = true;
global->has_set.state_path = true;
return true;
}
}
@ -1974,19 +1980,19 @@ bool config_load_override(void)
if (!global)
return false;
*global->append_config_path = '\0';
*global->path.append_config = '\0';
/* Toggle has_save_path to false so it resets */
global->has_set_save_path = false;
global->has_set_state_path = false;
global->has_set.save_path = false;
global->has_set.state_path = false;
if (config_load_file(global->config_path, false))
if (config_load_file(global->path.config, false))
{
RARCH_LOG("Configuration overrides unloaded, original configuration reset\n");
RARCH_LOG("Overrides: configuration overrides unloaded, original configuration restored\n");
/* Reset save paths */
global->has_set_save_path = true;
global->has_set_state_path = true;
global->has_set.save_path = true;
global->has_set.state_path = true;
return true;
}
@ -2023,8 +2029,8 @@ bool config_load_remap(void)
if (!info->info.library_name || !strcmp(info->info.library_name,"No Core"))
return false;
RARCH_LOG("Game name: %s\n", global->basename);
RARCH_LOG("Core name: %s\n", info->info.library_name);
RARCH_LOG("Remaps: core name: %s\n", info->info.library_name);
RARCH_LOG("Remaps: game name: %s\n", global->name.base);
/* Remap directory: remap_directory.
* Try remap directory setting, no fallbacks defined */
@ -2032,13 +2038,13 @@ bool config_load_remap(void)
strlcpy(remap_directory, settings->input_remapping_directory, PATH_MAX_LENGTH);
else
{
RARCH_WARN("No remap directory set.\n");
RARCH_WARN("Remaps: no remap directory set.\n");
return false;
}
RARCH_LOG("Remap directory: %s\n", remap_directory);
RARCH_LOG("Remaps: remap directory: %s\n", remap_directory);
core_name = info->info.library_name;
game_name = path_basename(global->basename);
game_name = path_basename(global->name.base);
/* Concatenate strings into full paths for core_path, game_path */
fill_pathname_join(core_path, remap_directory, core_name, PATH_MAX_LENGTH);
@ -2055,7 +2061,7 @@ bool config_load_remap(void)
/* If a game remap file exists, load it. */
if (new_conf)
{
RARCH_LOG("Game-specific remap found at %s. Appending.\n", game_path);
RARCH_LOG("Remaps: game-specific remap found at %s\n", game_path);
if (input_remapping_load_file(game_path))
{
rarch_main_msg_queue_push("Game remap file loaded", 1, 100, true);
@ -2064,7 +2070,7 @@ bool config_load_remap(void)
}
else
{
RARCH_LOG("No core-specific remap found at %s.\n", core_path);
RARCH_LOG("Remaps: no game-specific remap found at %s\n", game_path);
*settings->input.remapping_path= '\0';
input_remapping_set_defaults();
}
@ -2077,7 +2083,7 @@ bool config_load_remap(void)
/* If a core remap file exists, load it. */
if (new_conf)
{
RARCH_LOG("Core-specific remap found at %s. Loading.\n", core_path);
RARCH_LOG("Remaps: core-specific remap found at %s\n", core_path);
if (input_remapping_load_file(core_path))
{
rarch_main_msg_queue_push("Core remap file loaded", 1, 100, true);
@ -2086,7 +2092,7 @@ bool config_load_remap(void)
}
else
{
RARCH_LOG("No core-specific remap found at %s.\n", core_path);
RARCH_LOG("Remaps: no core-specific remap found at %s\n", core_path);
*settings->input.remapping_path= '\0';
input_remapping_set_defaults();
}
@ -2099,25 +2105,25 @@ bool config_load_remap(void)
static void parse_config_file(void)
{
global_t *global = global_get_ptr();
bool ret = config_load_file((*global->config_path)
? global->config_path : NULL, false);
bool ret = config_load_file((*global->path.config)
? global->path.config : NULL, false);
if (*global->config_path)
if (*global->path.config)
{
RARCH_LOG("Loading config from: %s.\n", global->config_path);
RARCH_LOG("Config: loading config from: %s.\n", global->path.config);
}
else
{
RARCH_LOG("Loading default config.\n");
if (*global->config_path)
RARCH_LOG("Found default config: %s.\n", global->config_path);
if (*global->path.config)
RARCH_LOG("Config: found default config: %s.\n", global->path.config);
}
if (ret)
return;
RARCH_ERR("Couldn't find config at path: \"%s\"\n",
global->config_path);
RARCH_ERR("Config: couldn't find config at path: \"%s\"\n",
global->path.config);
}
@ -2290,12 +2296,12 @@ void config_load(void)
global_t *global = global_get_ptr();
/* Flush out per-core configs before loading a new config. */
if (*global->core_specific_config_path &&
if (*global->path.core_specific_config &&
settings->config_save_on_exit && settings->core_specific_config)
config_save_file(global->core_specific_config_path);
config_save_file(global->path.core_specific_config);
/* Flush out some states that could have been set by core environment variables */
global->has_set_input_descriptors = false;
global->has_set.input_descriptors = false;
if (!global->block_config_read)
{
@ -2384,7 +2390,7 @@ bool config_save_autoconf_profile(const char *path, unsigned user)
if(settings->input.vid[user] && settings->input.pid[user])
{
config_set_int(conf, "input_vendor_id", settings->input.vid[user]);
config_set_int(conf, "input_product_id_id", settings->input.pid[user]);
config_set_int(conf, "input_product_id", settings->input.pid[user]);
}
for (i = 0; i < RARCH_FIRST_META_KEY; i++)
@ -2565,12 +2571,12 @@ bool config_save_file(const char *path)
config_set_float(conf, "video_font_size", settings->video.font_size);
config_set_bool(conf, "video_font_enable", settings->video.font_enable);
if (!global->has_set_ups_pref)
config_set_bool(conf, "ups_pref", global->ups_pref);
if (!global->has_set_bps_pref)
config_set_bool(conf, "bps_pref", global->bps_pref);
if (!global->has_set_ips_pref)
config_set_bool(conf, "ips_pref", global->ips_pref);
if (!global->has_set.ups_pref)
config_set_bool(conf, "ups_pref", global->patch.ups_pref);
if (!global->has_set.bps_pref)
config_set_bool(conf, "bps_pref", global->patch.bps_pref);
if (!global->has_set.ips_pref)
config_set_bool(conf, "ips_pref", global->patch.ips_pref);
config_set_path(conf, "system_directory",
*settings->system_directory ?
@ -2585,9 +2591,9 @@ bool config_save_file(const char *path)
settings->resampler_directory);
config_set_string(conf, "audio_resampler", settings->audio.resampler);
config_set_path(conf, "savefile_directory",
*global->savefile_dir ? global->savefile_dir : "default");
*global->dir.savefile ? global->dir.savefile : "default");
config_set_path(conf, "savestate_directory",
*global->savestate_dir ? global->savestate_dir : "default");
*global->dir.savestate ? global->dir.savestate : "default");
config_set_path(conf, "video_shader_dir",
*settings->video.shader_dir ?
settings->video.shader_dir : "default");
@ -2650,7 +2656,7 @@ bool config_save_file(const char *path)
#ifdef HAVE_OVERLAY
config_set_path(conf, "overlay_directory",
*global->overlay_dir ? global->overlay_dir : "default");
*global->dir.overlay ? global->dir.overlay : "default");
config_set_path(conf, "input_overlay", settings->input.overlay);
config_set_bool(conf, "input_overlay_enable", settings->input.overlay_enable);
config_set_bool(conf, "input_overlay_enable_autopreferred", settings->input.overlay_enable_autopreferred);
@ -2661,7 +2667,7 @@ bool config_save_file(const char *path)
settings->input.overlay_scale);
config_set_path(conf, "osk_overlay_directory",
*global->osk_overlay_dir ? global->osk_overlay_dir : "default");
*global->dir.osk_overlay ? global->dir.osk_overlay : "default");
config_set_path(conf, "input_osk_overlay", settings->osk.overlay);
config_set_bool(conf, "input_osk_overlay_enable", settings->osk.enable);
#endif
@ -2712,8 +2718,6 @@ bool config_save_file(const char *path)
settings->history_list_enable);
config_set_float(conf, "fastforward_ratio", settings->fastforward_ratio);
config_set_bool(conf, "fastforward_ratio_throttle_enable",
settings->fastforward_ratio_throttle_enable);
config_set_float(conf, "slowmotion_ratio", settings->slowmotion_ratio);
config_set_bool(conf, "config_save_on_exit",
@ -2723,11 +2727,11 @@ bool config_save_file(const char *path)
#ifdef HAVE_NETPLAY
config_set_bool(conf, "netplay_spectator_mode_enable",
global->netplay_is_spectate);
config_set_bool(conf, "netplay_mode", global->netplay_is_client);
config_set_string(conf, "netplay_ip_address", global->netplay_server);
config_set_int(conf, "netplay_ip_port", global->netplay_port);
config_set_int(conf, "netplay_delay_frames", global->netplay_sync_frames);
global->netplay.is_spectate);
config_set_bool(conf, "netplay_mode", global->netplay.is_client);
config_set_string(conf, "netplay_ip_address", global->netplay.server);
config_set_int(conf, "netplay_ip_port", global->netplay.port);
config_set_int(conf, "netplay_delay_frames", global->netplay.sync_frames);
#endif
config_set_string(conf, "netplay_nickname", settings->username);
config_set_int(conf, "user_language", settings->user_language);

View File

@ -303,7 +303,6 @@ typedef struct settings
char resampler_directory[PATH_MAX_LENGTH];
char screenshot_directory[PATH_MAX_LENGTH];
char system_directory[PATH_MAX_LENGTH];
bool system_in_content_dir;
char extraction_directory[PATH_MAX_LENGTH];
char playlist_directory[PATH_MAX_LENGTH];
@ -315,7 +314,6 @@ typedef struct settings
float slowmotion_ratio;
float fastforward_ratio;
bool fastforward_ratio_throttle_enable;
bool pause_nonactive;
unsigned autosave_interval;

View File

@ -73,7 +73,7 @@ static bool read_content_file(unsigned i, const char *path, void **buf,
return true;
/* Attempt to apply a patch. */
if (!global->block_patch)
if (!global->patch.block_patch)
patch_content(&ret_buf, length);
#ifdef HAVE_ZLIB
@ -610,7 +610,7 @@ bool init_content_file(void)
attr.i |= system->info.need_fullpath << 1;
attr.i |= (!system->no_content) << 2;
string_list_append(content,
(global->libretro_no_content && settings->core.set_supports_no_game_enable) ? "" : global->fullpath, attr);
(global->inited.core.no_content && settings->core.set_supports_no_game_enable) ? "" : global->path.fullpath, attr);
}
#ifdef HAVE_ZLIB
@ -655,7 +655,7 @@ bool init_content_file(void)
ret = load_content(special, content);
error:
global->content_is_init = (ret) ? true : false;
global->inited.content = (ret) ? true : false;
if (content)
string_list_free(content);

View File

@ -15,11 +15,10 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "core_info.h"
#include "general.h"
#include <file/file_path.h>
#include "file_ext.h"
#include <file/file_extract.h>
#include "general.h"
#include "dir_list_special.h"
#include "config.def.h"

View File

@ -14,14 +14,16 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "core_options.h"
#include <string.h>
#include <file/config_file.h>
#include <file/dir_list.h>
#include <compat/posix_string.h>
#include <compat/strl.h>
#include <retro_miscellaneous.h>
#include "core_options.h"
struct core_option
{
char *desc;

View File

@ -15,11 +15,13 @@
* If not, see <http://www.gnu.org/licenses/>.
*/
#include "../libretro.h"
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include "internal_cores.h"
#include "../libretro.h"
static uint16_t *frame_buf;
void libretro_dummy_retro_init(void)

View File

@ -36,6 +36,7 @@ extern "C" {
#include <queues/fifo_buffer.h>
#ifdef RARCH_INTERNAL
#include "internal_cores.h"
#include "../libretro.h"
#define CORE_PREFIX(s) libretro_ffmpeg_##s
#else

View File

@ -1,8 +1,9 @@
#include <assert.h>
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <stdint.h>
#include <assert.h>
#include <boolean.h>
#define STB_IMAGE_IMPLEMENTATION
@ -19,6 +20,7 @@
#include "stb_image.h"
#ifdef RARCH_INTERNAL
#include "internal_cores.h"
#include "../libretro.h"
#define IMAGE_CORE_PREFIX(s) libretro_imageviewer_##s
#else

View File

@ -1,3 +1,6 @@
ifneq ($(EMSCRIPTEN),)
platform = emscripten
endif
ifeq ($(platform),)
platform = unix
@ -38,7 +41,7 @@ ifeq ($(platform), unix)
fpic := -fPIC
SHARED := -shared -Wl,--version-script=link.T -Wl,--no-undefined
GL_LIB := -lGL
else ifeq ($(platform), osx)
else ifneq (,$(findstring osx,$(platform)))
TARGET := $(TARGET_NAME)_libretro.dylib
fpic := -fPIC
SHARED := -dynamiclib
@ -49,9 +52,7 @@ else ifeq ($(platform), osx)
endif
OSXVER = `sw_vers -productVersion | cut -d. -f 2`
OSX_LT_MAVERICKS = `(( $(OSXVER) <= 9)) && echo "YES"`
ifeq ($(OSX_LT_MAVERICKS),"YES")
fpic += -mmacosx-version-min=10.5
endif
fpic += -mmacosx-version-min=10.1
else ifeq ($(platform), pi)
TARGET := $(TARGET_NAME)_libretro.so
fpic := -fPIC
@ -67,7 +68,7 @@ else ifeq ($(platform), ios)
DEFINES := -DIOS
CFLAGS += -DGLES $(DEFINES)
CC = clang -arch armv7 -isysroot $(IOSSDK)
else ifeq ($(platform), qnx)
else ifneq (,$(findstring qnx,$(platform)))
TARGET := $(TARGET_NAME)_libretro_qnx.so
fpic := -fPIC
SHARED := -shared -Wl,--version-script=link.T
@ -77,6 +78,7 @@ else ifeq ($(platform), qnx)
AR = qcc -Vgcc_ntoarmv7le
CFLAGS += -DGLES
GL_LIB := -lGLESv2
GLES := 1
else ifneq (,$(findstring armv,$(platform)))
CC = gcc
TARGET := $(TARGET_NAME)_libretro.so
@ -103,6 +105,9 @@ else ifneq (,$(findstring hardfloat,$(platform)))
CFLAGS += -mfloat-abi=hard
endif
CFLAGS += -DARM
# emscripten
else ifeq ($(platform), emscripten)
TARGET := $(TARGET_NAME)_libretro_emscripten.bc
else
CC = gcc
TARGET := $(TARGET_NAME)_libretro.dll
@ -117,8 +122,8 @@ else
CFLAGS += -O3
endif
ifeq ($(platform), qnx)
CFLAGS += -Wc,-std=gnu99
ifneq (,$(findstring qnx,$(platform)))
CFLAGS += -Wc,-std=c99
else
CFLAGS += -std=gnu99
endif

View File

@ -1,15 +1,16 @@
#include "../../libretro.h"
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <glsym/glsym.h>
#include "../../libretro.h"
#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0]))
static struct retro_hw_render_callback hw_render;
#include <glsym/glsym.h>
#if defined(HAVE_PSGL)
#define RARCH_GL_FRAMEBUFFER GL_FRAMEBUFFER_OES
#define RARCH_GL_FRAMEBUFFER_COMPLETE GL_FRAMEBUFFER_COMPLETE_OES
@ -50,16 +51,6 @@ static GLuint fbo;
static GLuint rbo_color, rbo_depth_stencil;
#endif
static const GLfloat vertex_data[] = {
-0.5, -0.5,
0.5, -0.5,
-0.5, 0.5,
0.5, 0.5,
1.0, 1.0, 1.0, 1.0,
1.0, 1.0, 0.0, 1.0,
0.0, 1.0, 1.0, 1.0,
1.0, 0.0, 1.0, 1.0,
};
#ifdef CORE
static const char *vertex_shader[] = {
@ -182,6 +173,17 @@ static void init_multisample(unsigned samples)
static void setup_vao(void)
{
static const GLfloat vertex_data[] = {
-0.5, -0.5,
0.5, -0.5,
-0.5, 0.5,
0.5, 0.5,
1.0, 1.0, 1.0, 1.0,
1.0, 1.0, 0.0, 1.0,
0.0, 1.0, 1.0, 1.0,
1.0, 0.0, 1.0, 1.0,
};
#ifdef CORE
glGenVertexArrays(1, &vao);
#endif

View File

@ -1,8 +1,3 @@
ifneq ($(EMSCRIPTEN),)
platform = emscripten
endif
ifeq ($(platform),)
platform = unix
ifeq ($(shell uname -a),)
@ -16,6 +11,21 @@ else ifneq ($(findstring win,$(shell uname -a)),)
endif
endif
# system platform
system_platform = unix
ifeq ($(shell uname -a),)
EXE_EXT = .exe
system_platform = win
else ifneq ($(findstring Darwin,$(shell uname -a)),)
system_platform = osx
arch = intel
ifeq ($(shell uname -p),powerpc)
arch = ppc
endif
else ifneq ($(findstring MINGW,$(shell uname -a)),)
system_platform = win
endif
TARGET_NAME := test
LIBM = -lm
@ -28,7 +38,7 @@ else ifeq ($(platform), linux-portable)
fpic := -fPIC -nostdlib
SHARED := -shared -Wl,--version-script=link.T
LIBM :=
else ifeq ($(platform), osx)
else ifneq (,$(findstring osx,$(platform)))
TARGET := $(TARGET_NAME)_libretro.dylib
fpic := -fPIC
SHARED := -dynamiclib
@ -38,14 +48,20 @@ else ifeq ($(platform), ios)
SHARED := -dynamiclib
DEFINES := -DIOS
CC = clang -arch armv7 -isysroot $(IOSSDK)
else ifeq ($(platform), qnx)
else ifneq (,$(findstring qnx,$(platform)))
TARGET := $(TARGET_NAME)_libretro_qnx.so
fpic := -fPIC
SHARED := -shared -Wl,--version-script=link.T -Wl,--no-undefined
else ifeq ($(platform), emscripten)
TARGET := $(TARGET_NAME)_libretro_emscripten.so
TARGET := $(TARGET_NAME)_libretro_emscripten.bc
fpic := -fPIC
SHARED := -shared -Wl,--version-script=link.T -Wl,--no-undefined
else ifeq ($(platform), vita)
TARGET := $(TARGET_NAME)_vita.a
CC = arm-vita-eabi-gcc
AR = arm-vita-eabi-ar
CFLAGS += -Wl,-q -Wall -O3
STATIC_LINKING = 1
else
CC = gcc
TARGET := $(TARGET_NAME)_libretro.dll
@ -63,8 +79,8 @@ endif
OBJECTS := libretro-test.o
CFLAGS += -Wall -pedantic $(fpic)
ifeq ($(platform), qnx)
CFLAGS += -Wc,-std=gnu99
ifneq (,$(findstring qnx,$(platform)))
CFLAGS += -Wc,-std=c99
else
CFLAGS += -std=gnu99
endif
@ -72,7 +88,11 @@ endif
all: $(TARGET)
$(TARGET): $(OBJECTS)
ifeq ($(STATIC_LINKING), 1)
$(AR) rcs $@ $(OBJECTS)
else
$(CC) $(fpic) $(SHARED) $(INCLUDES) -o $@ $(OBJECTS) $(LDFLAGS)
endif
%.o: %.c
$(CC) $(CFLAGS) -c -o $@ $<

View File

@ -1,13 +1,19 @@
#include "../../libretro.h"
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <stdarg.h>
#include "../../libretro.h"
#ifndef M_PI
#define M_PI 3.14159265358979323846
#endif
static uint16_t *frame_buf;
static struct retro_log_callback logging;
static retro_log_printf_t log_cb;
static bool use_audio_cb;
static float last_aspect;
static float last_sample_rate;
@ -39,7 +45,7 @@ unsigned retro_api_version(void)
void retro_set_controller_port_device(unsigned port, unsigned device)
{
logging.log(RETRO_LOG_INFO, "Plugging device %u into port %u.\n", device, port);
log_cb(RETRO_LOG_INFO, "Plugging device %u into port %u.\n", device, port);
}
void retro_get_system_info(struct retro_system_info *info)
@ -112,8 +118,10 @@ void retro_set_environment(retro_environment_t cb)
bool no_content = true;
cb(RETRO_ENVIRONMENT_SET_SUPPORT_NO_GAME, &no_content);
if (!cb(RETRO_ENVIRONMENT_GET_LOG_INTERFACE, &logging))
logging.log = fallback_log;
if (cb(RETRO_ENVIRONMENT_GET_LOG_INTERFACE, &logging))
log_cb = logging.log;
else
log_cb = fallback_log;
static const struct retro_subsystem_memory_info mem1[] = {{ "ram1", 0x400 }, { "ram2", 0x401 }};
static const struct retro_subsystem_memory_info mem2[] = {{ "ram3", 0x402 }, { "ram4", 0x403 }};
@ -197,10 +205,10 @@ static void update_input(void)
dir_x++;
if (input_state_cb(0, RETRO_DEVICE_KEYBOARD, 0, RETROK_RETURN))
logging.log(RETRO_LOG_INFO, "Return key is pressed!\n");
log_cb(RETRO_LOG_INFO, "Return key is pressed!\n");
if (input_state_cb(0, RETRO_DEVICE_KEYBOARD, 0, RETROK_x))
logging.log(RETRO_LOG_INFO, "x key is pressed!\n");
log_cb(RETRO_LOG_INFO, "x key is pressed!\n");
int16_t mouse_x = input_state_cb(0, RETRO_DEVICE_MOUSE, 0, RETRO_DEVICE_ID_MOUSE_X);
int16_t mouse_y = input_state_cb(0, RETRO_DEVICE_MOUSE, 0, RETRO_DEVICE_ID_MOUSE_Y);
@ -210,19 +218,19 @@ static void update_input(void)
bool mouse_up = input_state_cb(0, RETRO_DEVICE_MOUSE, 0, RETRO_DEVICE_ID_MOUSE_WHEELUP);
bool mouse_middle = input_state_cb(0, RETRO_DEVICE_MOUSE, 0, RETRO_DEVICE_ID_MOUSE_MIDDLE);
if (mouse_x)
logging.log(RETRO_LOG_INFO, "Mouse X: %d\n", mouse_x);
log_cb(RETRO_LOG_INFO, "Mouse X: %d\n", mouse_x);
if (mouse_y)
logging.log(RETRO_LOG_INFO, "Mouse Y: %d\n", mouse_y);
log_cb(RETRO_LOG_INFO, "Mouse Y: %d\n", mouse_y);
if (mouse_l)
logging.log(RETRO_LOG_INFO, "Mouse L pressed.\n");
log_cb(RETRO_LOG_INFO, "Mouse L pressed.\n");
if (mouse_r)
logging.log(RETRO_LOG_INFO, "Mouse R pressed.\n");
log_cb(RETRO_LOG_INFO, "Mouse R pressed.\n");
if (mouse_down)
logging.log(RETRO_LOG_INFO, "Mouse wheeldown pressed.\n");
log_cb(RETRO_LOG_INFO, "Mouse wheeldown pressed.\n");
if (mouse_up)
logging.log(RETRO_LOG_INFO, "Mouse wheelup pressed.\n");
log_cb(RETRO_LOG_INFO, "Mouse wheelup pressed.\n");
if (mouse_middle)
logging.log(RETRO_LOG_INFO, "Mouse middle pressed.\n");
log_cb(RETRO_LOG_INFO, "Mouse middle pressed.\n");
mouse_rel_x += mouse_x;
mouse_rel_y += mouse_y;
@ -239,7 +247,7 @@ static void update_input(void)
int16_t pointer_x = input_state_cb(0, RETRO_DEVICE_POINTER, 0, RETRO_DEVICE_ID_POINTER_X);
int16_t pointer_y = input_state_cb(0, RETRO_DEVICE_POINTER, 0, RETRO_DEVICE_ID_POINTER_Y);
if (pointer_pressed)
logging.log(RETRO_LOG_INFO, "Pointer: (%6d, %6d).\n", pointer_x, pointer_y);
log_cb(RETRO_LOG_INFO, "Pointer: (%6d, %6d).\n", pointer_x, pointer_y);
dir_x += input_state_cb(0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_LEFT, RETRO_DEVICE_ID_ANALOG_X) / 5000;
dir_y += input_state_cb(0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_LEFT, RETRO_DEVICE_ID_ANALOG_Y) / 5000;
@ -258,11 +266,11 @@ static void update_input(void)
bool start = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_START);
bool select = input_state_cb(0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_SELECT);
if (old_start != start)
logging.log(RETRO_LOG_INFO, "Strong rumble: %s.\n", start ? "ON": "OFF");
log_cb(RETRO_LOG_INFO, "Strong rumble: %s.\n", start ? "ON": "OFF");
rumble.set_rumble_state(0, RETRO_RUMBLE_STRONG, start * strength_strong);
if (old_select != select)
logging.log(RETRO_LOG_INFO, "Weak rumble: %s.\n", select ? "ON": "OFF");
log_cb(RETRO_LOG_INFO, "Weak rumble: %s.\n", select ? "ON": "OFF");
rumble.set_rumble_state(0, RETRO_RUMBLE_WEAK, select * strength_weak);
old_start = start;
@ -298,13 +306,13 @@ static void check_variables(void)
struct retro_variable var = {0};
var.key = "test_opt0";
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
logging.log(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
log_cb(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
var.key = "test_opt1";
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
logging.log(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
log_cb(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
var.key = "test_opt2";
if (environ_cb(RETRO_ENVIRONMENT_GET_VARIABLE, &var) && var.value)
logging.log(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
log_cb(RETRO_LOG_INFO, "Key -> Val: %s -> %s.\n", var.key, var.value);
float last = last_aspect;
float last_rate = last_sample_rate;
@ -323,7 +331,7 @@ static void check_variables(void)
ret = environ_cb(RETRO_ENVIRONMENT_SET_SYSTEM_AV_INFO, &info);
else // If only aspect changed, take the simpler path.
ret = environ_cb(RETRO_ENVIRONMENT_SET_GEOMETRY, &info.geometry);
logging.log(RETRO_LOG_INFO, "SET_SYSTEM_AV_INFO/SET_GEOMETRY = %u.\n", ret);
log_cb(RETRO_LOG_INFO, "SET_SYSTEM_AV_INFO/SET_GEOMETRY = %u.\n", ret);
}
}
@ -358,7 +366,7 @@ void retro_run(void)
static void keyboard_cb(bool down, unsigned keycode,
uint32_t character, uint16_t mod)
{
logging.log(RETRO_LOG_INFO, "Down: %s, Code: %d, Char: %u, Mod: %u.\n",
log_cb(RETRO_LOG_INFO, "Down: %s, Code: %d, Char: %u, Mod: %u.\n",
down ? "yes" : "no", keycode, character, mod);
}
@ -378,16 +386,16 @@ bool retro_load_game(const struct retro_game_info *info)
enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_RGB565;
if (!environ_cb(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt))
{
logging.log(RETRO_LOG_INFO, "RGB565 is not supported.\n");
log_cb(RETRO_LOG_INFO, "RGB565 is not supported.\n");
return false;
}
struct retro_keyboard_callback cb = { keyboard_cb };
environ_cb(RETRO_ENVIRONMENT_SET_KEYBOARD_CALLBACK, &cb);
if (environ_cb(RETRO_ENVIRONMENT_GET_RUMBLE_INTERFACE, &rumble))
logging.log(RETRO_LOG_INFO, "Rumble environment supported.\n");
log_cb(RETRO_LOG_INFO, "Rumble environment supported.\n");
else
logging.log(RETRO_LOG_INFO, "Rumble environment not supported.\n");
log_cb(RETRO_LOG_INFO, "Rumble environment not supported.\n");
struct retro_audio_callback audio_cb = { audio_callback, audio_set_state };
use_audio_cb = environ_cb(RETRO_ENVIRONMENT_SET_AUDIO_CALLBACK, &audio_cb);

View File

@ -1179,6 +1179,10 @@ STBIDEF void stbi_ldr_to_hdr_gamma(float gamma) { stbi__l2h_gamma = gamma; }
STBIDEF void stbi_ldr_to_hdr_scale(float scale) { stbi__l2h_scale = scale; }
#endif
/* forward declarations */
STBIDEF void stbi_hdr_to_ldr_gamma(float gamma);
STBIDEF void stbi_hdr_to_ldr_scale(float scale);
STBIDEF void stbi_hdr_to_ldr_gamma(float gamma) { stbi__h2l_gamma_i = 1/gamma; }
STBIDEF void stbi_hdr_to_ldr_scale(float scale) { stbi__h2l_scale_i = 1/scale; }

BIN
ctr/2048.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

134
ctr/Makefile.cores Normal file
View File

@ -0,0 +1,134 @@
ifeq ($(LIBRETRO), gambatte)
APP_TITLE = Gambatte Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-GAMBATTE
APP_UNIQUE_ID = 0xBAC01
APP_ICON = ctr/gambatte.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), gpsp)
APP_TITLE = gpSP Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-GPSP
APP_UNIQUE_ID = 0xBAC02
APP_ICON = ctr/gpsp.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), fceumm)
APP_TITLE = FCeumm Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-FCEUMM
APP_UNIQUE_ID = 0xBAC03
APP_ICON = ctr/fceumm.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), nestopia)
APP_TITLE = Nestopia Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-NESTOPIA
APP_UNIQUE_ID = 0xBAC04
APP_ICON = ctr/nestopia.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
BUILD_3DSX = 0
else ifeq ($(LIBRETRO), nxengine)
APP_TITLE = NXengine Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-NXENGINE
APP_UNIQUE_ID = 0xBAC05
APP_ICON = ctr/nxengine.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), genesis_plus_gx)
APP_TITLE = Genesis Plus GX Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-GENPLUSGX
APP_UNIQUE_ID = 0xBAC06
APP_ICON = ctr/genesis_plus_gx.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), catsfc)
APP_TITLE = CATSFC Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-CATSFC
APP_UNIQUE_ID = 0xBAC07
APP_ICON = ctr/catsfc.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), mednafen_wswan)
APP_TITLE = Mednafen wswan Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-M-WSWAN
APP_UNIQUE_ID = 0xBAC08
APP_ICON = ctr/mednafen_wswan.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), mednafen_vb)
APP_TITLE = Mednafen VB Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-M-VB
APP_UNIQUE_ID = 0xBAC09
APP_ICON = ctr/mednafen_vb.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), mednafen_ngp)
APP_TITLE = Mednafen NGP Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-M-NGP
APP_UNIQUE_ID = 0xBAC0A
APP_ICON = ctr/mednafen_ngp.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), 2048)
APP_TITLE = 2048 Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-2048
APP_UNIQUE_ID = 0xBAC0B
APP_ICON = ctr/2048.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), picodrive)
APP_TITLE = Picodrive Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-PICODRIVE
APP_UNIQUE_ID = 0xBAC0C
APP_ICON = ctr/picodrive.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
else ifeq ($(LIBRETRO), snes9x_next)
APP_TITLE = Snes9x Next Libretro
#APP_DESCRIPTION = Retroarch 3DS
#APP_AUTHOR = Team Libretro
APP_PRODUCT_CODE = RARCH-SNES9XNEXT
APP_UNIQUE_ID = 0xBAC0D
APP_ICON = ctr/snes9x_next.png
#APP_BANNER = ctr/libretro_banner.png
#APP_AUDIO = ctr/silent.wav
endif

BIN
ctr/catsfc.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

BIN
ctr/default.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
ctr/fceumm.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
ctr/gambatte.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
ctr/genesis_plus_gx.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

BIN
ctr/gpsp.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

BIN
ctr/libretro_banner.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

BIN
ctr/mednafen_ngp.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
ctr/mednafen_vb.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
ctr/mednafen_wswan.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
ctr/mgba.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

BIN
ctr/nestopia.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

BIN
ctr/nxengine.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.4 KiB

BIN
ctr/picodrive.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

BIN
ctr/silent.wav Normal file

Binary file not shown.

BIN
ctr/snes9x_next.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Some files were not shown because too many files have changed in this diff Show More