diff --git a/AUTHORS.h b/AUTHORS.h index 2c3ffeb235..c9eee84309 100644 --- a/AUTHORS.h +++ b/AUTHORS.h @@ -95,6 +95,7 @@ FIX94 Flame Sage (chris062689) flyinghead Francisco José García García (frangarcj) +Francisco Javier Trujillo Mata (fjtrujy) GameDragon2k Garrett Brown (garbear) gblues @@ -142,6 +143,7 @@ JuanVCS Justin Jacobs (dorkster) Justin Weiss (justinweiss) Ken Rossato (rossato) +Krzysztof Haładyn (krzys_h) kurumushi kwyxz l3iggs diff --git a/CHANGES.md b/CHANGES.md index ac79af4e4d..f0cf1a4b97 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,23 +1,45 @@ # 1.7.6 (future) +- ANDROID: Fix Xperia Play input binding +- CHEEVOS: Reset when hardcore mode is toggled +- CORE UPDATER: Allow sideloading cores from the menu - CPU FILTERS: Add Normal2x filter. - DATE: Add Date / Time style options. -- MIDI: Add a Linux ALSA driver for MIDI. +- DEBUGGING: Add an integrated crash handler for debug builds (see https://docs.libretro.com/tech/debugging) +- DISCORD: Register the application name properly. +- DISK CONTROL: Remember the last used folder / current active folder to make disk-swapping faster. +- INPUT: Add new menu toggle (hold start button for 2 seconds) +- INPUT/SDL: Flush the joypad events. Decreases cpu usage over time with the SDL joypad driver. - LOCALIZATION: Add Greek translation. - LOCALIZATION: Update German translation. - LOCALIZATION: Update Italian translation. -- LOCALIZATION: Update Simplified Chinese translation. - LOCALIZATION: Update Japanese translation. +- LOCALIZATION: Update Simplified Chinese translation. +- LOCALIZATION: Update Spanish translation. - MENU: Only show CRT SwitchRes if video display server is implemented (Windows/Linux for now) - MENU: User Interface -> Appearance -> 'Menu Font Green/Blue Color' settings now work properly. +- MIDI: Add a Linux ALSA driver for MIDI. +- NETPLAY: Force fast-save-states when netlay is enabled +- PS2: Initial PlayStation2 port. +- PS4: Initial PlayStation4 port. +- RECORDING: Implement recording options in the menu complete with quality profiles, streaming, and proper file naming - SCANNER: Fix GDI disc scanning. +- SHADERS: Fix auto shader preset loading on D3D10, D3D11, D3D12 +- SUBSYSTEM: Allow more than 10 subsystems +- SUBSYSTEM: Cores that use subsystem for complex scenarios can now load content without starting a regular content first +- SUBSYSTEM: Remember the last used folder to make loading subsystem type content faster - SWITCH/LIBNX: Improve touch scaling calculation. - SWITCH: Proper button labels. - VULKAN: Fix RGUI crashing at startup. - VULKAN: Fix secondary screens in overlays not working. - WAYLAND: Implement idle-inhibit support (needed for screensaver suspend). -- WINDOWS/WSA: Network Information info is blank until first network operation. -- WINDOWS: SSL/TLS connections now work properly. - WIIU: Initial netplay peer-to-peer support. Network information working. +- WINDOWS/WSA: Network Information info is blank until first network operation. +- WINDOWS: Fix an ancient bug that caused wrong mappings for keyboard arrows +- WINDOWS: Remember window size and position if so desired +- WINDOWS: SSL/TLS connections now work properly. +- UWP: Initial UWP port. +- XBONE: Initial Xbox One port. +- XMB/OZONE: Add more icons # 1.7.5 - CAMERA: Fix Video4Linux2 driver that broke years ago. diff --git a/Makefile b/Makefile index 304bc4309f..c5750e7c4e 100644 --- a/Makefile +++ b/Makefile @@ -16,26 +16,35 @@ include config.mk TARGET = retroarch +OBJ := +LIBS := +DEF_FLAGS := +DEFINES := -DHAVE_CONFIG_H -DRARCH_INTERNAL -D_FILE_OFFSET_BITS=64 +DEFINES += -DGLOBAL_CONFIG_DIR='"$(GLOBAL_CONFIG_DIR)"' + OBJDIR_BASE := obj-unix ifeq ($(DEBUG), 1) OBJDIR := $(OBJDIR_BASE)/debug + CFLAGS ?= -O0 -g + CXXFLAGS ?= -O0 -g + DEFINES += -DDEBUG -D_DEBUG else OBJDIR := $(OBJDIR_BASE)/release + CFLAGS ?= -O3 + CXXFLAGS ?= -O3 + DEF_FLAGS += -ffast-math endif -OBJ := -LIBS := -DEFINES := -DHAVE_CONFIG_H -DRARCH_INTERNAL -D_FILE_OFFSET_BITS=64 -DEFINES += -DGLOBAL_CONFIG_DIR='"$(GLOBAL_CONFIG_DIR)"' - ifneq ($(findstring BSD,$(OS)),) - CFLAGS += -DBSD + DEF_FLAGS += -DBSD LDFLAGS += -L/usr/local/lib + UDEV_CFLAGS += -I/usr/local/include/libepoll-shim + UDEV_LIBS += -lepoll-shim endif ifneq ($(findstring DOS,$(OS)),) - CFLAGS += -march=i386 + DEF_FLAGS += -march=i386 LDFLAGS += -lemu endif @@ -75,21 +84,19 @@ ifneq ($(V),1) Q := @ endif -ifeq ($(DEBUG), 1) - OPTIMIZE_FLAG = -O0 -g - DEFINES += -DDEBUG -D_DEBUG -else - OPTIMIZE_FLAG = -O3 -ffast-math +ifeq ($(HAVE_DRMINGW), 1) + DEF_FLAGS += -DHAVE_DRMINGW + LDFLAGS += $(DRMINGW_LIBS) endif ifneq ($(findstring Win32,$(OS)),) LDFLAGS += -mwindows endif -CFLAGS += -Wall $(OPTIMIZE_FLAG) $(INCLUDE_DIRS) -I. -Ideps -Ideps/stb +DEF_FLAGS += -Wall $(INCLUDE_DIRS) -I. -Ideps -Ideps/stb -APPEND_CFLAGS := $(CFLAGS) -CXXFLAGS += $(APPEND_CFLAGS) -std=c++11 -D__STDC_CONSTANT_MACROS +CFLAGS += $(DEF_FLAGS) +CXXFLAGS += $(DEF_FLAGS) -std=c++11 -D__STDC_CONSTANT_MACROS OBJCFLAGS := $(CFLAGS) -D__STDC_CONSTANT_MACROS ifeq ($(HAVE_CXX), 1) diff --git a/Makefile.common b/Makefile.common index c33e9d7597..4c92c23fb5 100644 --- a/Makefile.common +++ b/Makefile.common @@ -4,7 +4,7 @@ LIBRETRO_COMM_DIR := $(ROOT_DIR)/libretro-common WANT_WGL = 0 ifeq ($(HAVE_STACK_USAGE), 1) - CFLAGS += -fstack-usage + DEF_FLAGS += -fstack-usage endif ifeq ($(HAVE_GL_CONTEXT),) @@ -31,11 +31,6 @@ ifeq ($(HAVE_VIDEO_PROCESSOR), 1) DEFINES += -DHAVE_VIDEO_PROCESSOR endif -ifeq ($(HAVE_MENU), 1) - DEFINES += -DHAVE_MENU - HAVE_MENU_COMMON = 1 -endif - ifeq ($(HAVE_SOCKET_LEGACY), 1) DEFINES += -DHAVE_SOCKET_LEGACY endif @@ -65,13 +60,11 @@ ifeq ($(HAVE_PRESERVE_DYLIB),1) endif ifeq ($(GL_DEBUG), 1) - CFLAGS += -DGL_DEBUG - CXXFLAGS += -DGL_DEBUG + DEF_FLAGS += -DGL_DEBUG endif ifeq ($(VULKAN_DEBUG), 1) - CFLAGS += -DVULKAN_DEBUG - CXXFLAGS += -DVULKAN_DEBUG + DEF_FLAGS += -DVULKAN_DEBUG endif ifeq ($(HAVE_HARD_FLOAT), 1) @@ -83,23 +76,23 @@ ifeq ($(TDM_GCC),) endif ifeq ($(HAVE_FILE_LOGGER), 1) - CFLAGS += -DHAVE_FILE_LOGGER + DEF_FLAGS += -DHAVE_FILE_LOGGER endif ifeq ($(HAVE_SHADERPIPELINE), 1) - CFLAGS += -DHAVE_SHADERPIPELINE + DEF_FLAGS += -DHAVE_SHADERPIPELINE endif -CFLAGS += -I$(LIBRETRO_COMM_DIR)/include -I$(DEPS_DIR) +DEF_FLAGS += -I$(LIBRETRO_COMM_DIR)/include -I$(DEPS_DIR) # Switches # ifeq ($(HAVE_NETPLAYDISCOVERY), 1) - CFLAGS += -DHAVE_NETPLAYDISCOVERY + DEF_FLAGS += -DHAVE_NETPLAYDISCOVERY endif ifeq ($(HAVE_NETLOGGER), 1) - CFLAGS += -DHAVE_LOGGER + DEF_FLAGS += -DHAVE_LOGGER DEFINES += -DHAVE_LOGGER OBJ += network/net_logger.o endif @@ -151,7 +144,7 @@ endif # General object files DEFINES += -DHAVE_DR_MP3 -CFLAGS += -DHAVE_DR_MP3 +DEF_FLAGS += -DHAVE_DR_MP3 OBJ += frontend/frontend.o \ frontend/frontend_driver.o \ @@ -343,7 +336,7 @@ ifeq ($(HAVE_QT), 1) ui/drivers/qt/ui_qt_browser_window.o \ ui/drivers/qt/ui_qt_load_core_window.o \ ui/drivers/qt/ui_qt_msg_window.o \ - ui/drivers/qt/flowlayout.o \ + ui/drivers/qt/gridview.o \ ui/drivers/qt/shaderparamsdialog.o \ ui/drivers/qt/coreoptionsdialog.o \ ui/drivers/qt/filedropwidget.o \ @@ -358,7 +351,7 @@ ifeq ($(HAVE_QT), 1) MOC_HEADERS += ui/drivers/ui_qt.h \ ui/drivers/qt/ui_qt_load_core_window.h \ - ui/drivers/qt/flowlayout.h \ + ui/drivers/qt/gridview.h \ ui/drivers/qt/shaderparamsdialog.h \ ui/drivers/qt/coreoptionsdialog.h \ ui/drivers/qt/filedropwidget.h \ @@ -645,7 +638,7 @@ ifeq ($(HAVE_NEON),1) $(LIBRETRO_COMM_DIR)/audio/conversion/float_to_s16_neon.o endif -HW_CONTEXT_MENU_DRIVERS=$(HAVE_RGUI) +HW_CONTEXT_MENU_DRIVERS=$(HAVE_MENU) ifeq ($(HW_CONTEXT_MENU_DRIVERS),0) ifeq ($(HAVE_GL_CONTEXT),1) @@ -662,6 +655,10 @@ ifeq ($(HW_CONTEXT_MENU_DRIVERS), 1) HAVE_ZARCH = 0 endif + ifeq ($(HAVE_RGUI),) + HAVE_RGUI = 1 + endif + ifeq ($(HAVE_MATERIALUI),) HAVE_MATERIALUI = 1 endif @@ -683,6 +680,7 @@ ifeq ($(HW_CONTEXT_MENU_DRIVERS), 1) endif else HAVE_ZARCH ?= 0 + HAVE_RGUI ?= 0 HAVE_MATERIALUI ?= 0 HAVE_NUKLEAR ?= 0 HAVE_XMB ?= 0 @@ -690,53 +688,57 @@ else HAVE_OZONE ?= 0 endif -ifeq ($(HAVE_RGUI), 1) - OBJ += menu/drivers/rgui.o - DEFINES += -DHAVE_MENU -DHAVE_RGUI +ifeq ($(HAVE_MENU), 1) + DEFINES += -DHAVE_MENU HAVE_MENU_COMMON = 1 + + ifeq ($(HAVE_RGUI), 1) + OBJ += menu/drivers/rgui.o + DEFINES += -DHAVE_RGUI + endif + ifeq ($(HAVE_MATERIALUI), 1) OBJ += menu/drivers/materialui.o DEFINES += -DHAVE_MATERIALUI - HAVE_MENU_COMMON = 1 HAVE_ASSETS = 1 endif + ifeq ($(HAVE_NUKLEAR), 1) - OBJ += menu/drivers/nuklear/nk_common.o - OBJ += menu/drivers/nuklear/nk_menu.o - OBJ += menu/drivers/nuklear/nk_wnd_debug.o - OBJ += menu/drivers/nuklear.o + OBJ += menu/drivers/nuklear/nk_common.o \ + menu/drivers/nuklear/nk_menu.o \ + menu/drivers/nuklear/nk_wnd_debug.o \ + menu/drivers/nuklear.o DEFINES += -DHAVE_NUKLEAR HAVE_ASSETS = 1 endif + ifeq ($(HAVE_ZARCH), 1) OBJ += menu/drivers/zarch.o DEFINES += -DHAVE_ZARCH HAVE_ASSETS = 1 endif -endif -ifeq ($(HAVE_XMB), 1) - OBJ += menu/drivers/xmb.o - DEFINES += -DHAVE_XMB - HAVE_MENU_COMMON = 1 - HAVE_ASSETS = 1 -endif + ifeq ($(HAVE_XMB), 1) + OBJ += menu/drivers/xmb.o + DEFINES += -DHAVE_XMB + HAVE_ASSETS = 1 + endif -ifeq ($(HAVE_OZONE), 1) - OBJ += menu/drivers/ozone/ozone.o - OBJ += menu/drivers/ozone/ozone_entries.o - OBJ += menu/drivers/ozone/ozone_display.o - OBJ += menu/drivers/ozone/ozone_texture.o - OBJ += menu/drivers/ozone/ozone_theme.o - OBJ += menu/drivers/ozone/ozone_sidebar.o - DEFINES += -DHAVE_OZONE - HAVE_MENU_COMMON = 1 - HAVE_ASSETS = 1 -endif + ifeq ($(HAVE_OZONE), 1) + OBJ += menu/drivers/ozone/ozone.o \ + menu/drivers/ozone/ozone_entries.o \ + menu/drivers/ozone/ozone_display.o \ + menu/drivers/ozone/ozone_texture.o \ + menu/drivers/ozone/ozone_theme.o \ + menu/drivers/ozone/ozone_sidebar.o + DEFINES += -DHAVE_OZONE + HAVE_ASSETS = 1 + endif -ifeq ($(HAVE_STRIPES), 1) - OBJ += menu/drivers/stripes.o - DEFINES += -DHAVE_STRIPES + ifeq ($(HAVE_STRIPES), 1) + OBJ += menu/drivers/stripes.o + DEFINES += -DHAVE_STRIPES + endif endif ifeq ($(HAVE_LAKKA), 1) @@ -747,6 +749,8 @@ ifeq ($(HAVE_LAKKA_SWITCH), 1) DEFINES += -DHAVE_LAKKA_SWITCH endif +OBJ += menu/menu_shader.o + ifeq ($(HAVE_MENU_COMMON), 1) OBJ += menu/menu_driver.o \ menu/menu_content.o \ @@ -754,7 +758,6 @@ ifeq ($(HAVE_MENU_COMMON), 1) menu/menu_entries.o \ menu/menu_setting.o \ menu/menu_networking.o \ - menu/menu_shader.o \ menu/widgets/menu_filebrowser.o \ menu/widgets/menu_dialog.o \ menu/widgets/menu_input_dialog.o \ @@ -781,9 +784,12 @@ ifeq ($(HAVE_MENU_COMMON), 1) menu/cbs/menu_cbs_contentlist_switch.o \ menu/menu_displaylist.o \ menu/menu_animation.o \ - menu/drivers_display/menu_display_null.o \ menu/drivers/menu_generic.o \ menu/drivers/null.o + + ifeq ($(HAVE_MENU_COMMON),1) + OBJ += menu/drivers_display/menu_display_null.o + endif endif ifeq ($(HAVE_OVERLAY), 1) @@ -833,14 +839,14 @@ ifeq ($(HAVE_VITA2D), 1) $(DEPS_DIR)/libvita2d/shader/texture_f_gxp.o \ $(DEPS_DIR)/libvita2d/shader/texture_tint_f_gxp.o - ifeq ($(HAVE_MENU),1) + ifeq ($(HAVE_MENU_COMMON),1) OBJ += menu/drivers_display/menu_display_vita2d.o endif OBJ += gfx/drivers/vita2d_gfx.o \ gfx/drivers_font/vita2d_font.o - CFLAGS += -I$(DEPS_DIR)/libvita2d/include + DEF_FLAGS += -I$(DEPS_DIR)/libvita2d/include endif ifeq ($(TARGET), retroarch_3ds) @@ -941,7 +947,7 @@ endif ifeq ($(HAVE_DBUS), 1) LIBS += $(DBUS_LIBS) - CFLAGS += $(DBUS_CFLAGS) + DEF_FLAGS += $(DBUS_CFLAGS) OBJ += gfx/common/dbus_common.o endif @@ -1036,7 +1042,7 @@ endif ifeq ($(HAVE_SIXEL), 1) DEFINES += -DHAVE_SIXEL - CFLAGS += -I/usr/include/sixel + DEF_FLAGS += -I/usr/include/sixel OBJ += gfx/drivers/sixel_gfx.o gfx/drivers_font/sixel_font.o \ gfx/drivers_context/sixel_ctx.o LIBS += -lsixel @@ -1048,7 +1054,7 @@ endif ifeq ($(HAVE_PLAIN_DRM), 1) OBJ += gfx/drivers/drm_gfx.o - CFLAGS += -I/usr/include/libdrm + DEF_FLAGS += -I/usr/include/libdrm LIBS += -ldrm endif @@ -1117,8 +1123,11 @@ ifeq ($(HAVE_GL_CONTEXT), 1) gfx/common/metal/MenuDisplay.o \ gfx/common/metal_common.o \ gfx/drivers/metal.o \ - menu/drivers_display/menu_display_metal.o \ gfx/drivers_font/metal_raster_font.o + + ifeq ($(HAVE_MENU_COMMON), 1) + OBJ += menu/drivers_display/menu_display_metal.o + endif endif ifeq ($(HAVE_MPV), 1) @@ -1300,16 +1309,20 @@ endif ifeq ($(HAVE_D3D10), 1) OBJ += gfx/drivers/d3d10.o \ gfx/common/d3d10_common.o \ - gfx/drivers_font/d3d10_font.o \ - menu/drivers_display/menu_display_d3d10.o + gfx/drivers_font/d3d10_font.o + ifeq ($(HAVE_MENU_COMMON), 1) + OBJ += menu/drivers_display/menu_display_d3d10.o + endif DEFINES += -DHAVE_D3D10 endif ifeq ($(HAVE_D3D11), 1) OBJ += gfx/drivers/d3d11.o \ gfx/common/d3d11_common.o \ - gfx/drivers_font/d3d11_font.o \ - menu/drivers_display/menu_display_d3d11.o + gfx/drivers_font/d3d11_font.o + ifeq ($(HAVE_MENU_COMMON), 1) + OBJ += menu/drivers_display/menu_display_d3d11.o + endif DEFINES += -DHAVE_D3D11 HAVE_SLANG = 1 HAVE_GLSLANG = 1 @@ -1319,8 +1332,10 @@ endif ifeq ($(HAVE_D3D12), 1) OBJ += gfx/drivers/d3d12.o \ gfx/common/d3d12_common.o \ - gfx/drivers_font/d3d12_font.o \ - menu/drivers_display/menu_display_d3d12.o + gfx/drivers_font/d3d12_font.o + ifeq ($(HAVE_MENU_COMMON), 1) + OBJ += menu/drivers_display/menu_display_d3d12.o + endif DEFINES += -DHAVE_D3D12 HAVE_SLANG = 1 HAVE_GLSLANG = 1 @@ -1331,7 +1346,7 @@ ifneq ($(findstring 1, $(HAVE_D3D10) $(HAVE_D3D11) $(HAVE_D3D12)),) INCLUDE_DIRS += -isystemgfx/include/dxsdk OBJ += gfx/common/d3dcompiler_common.o \ gfx/common/dxgi_common.o - CFLAGS += -Wno-unknown-pragmas + DEF_FLAGS += -Wno-unknown-pragmas endif ifeq ($(HAVE_D3D8), 1) @@ -1447,7 +1462,7 @@ OBJ += $(LIBRETRO_COMM_DIR)/file/archive_file.o \ $(LIBRETRO_COMM_DIR)/streams/trans_stream_pipe.o ifeq ($(HAVE_7ZIP),1) - CFLAGS += -I$(DEPS_DIR)/7zip + DEF_FLAGS += -I$(DEPS_DIR)/7zip HAVE_COMPRESSION = 1 DEFINES += -DHAVE_7ZIP -D_7ZIP_ST 7ZOBJ = $(DEPS_DIR)/7zip/7zIn.o \ @@ -1476,8 +1491,8 @@ endif ifeq ($(HAVE_BUILTINFLAC),1) HAVE_FLAC = 1 DEFINES += -DHAVE_DR_FLAC -I$(DEPS_DIR) - CFLAGS += -DHAVE_DR_FLAC - CFLAGS += -DHAVE_FLAC -I$(DEPS_DIR)/libFLAC/include + DEF_FLAGS += -DHAVE_DR_FLAC + DEF_FLAGS += -DHAVE_FLAC -I$(DEPS_DIR)/libFLAC/include DEFINES += -DHAVE_STDINT_H -DHAVE_LROUND -DFLAC__HAS_OGG=0 \ -DFLAC_PACKAGE_VERSION="\"retroarch\"" FLACOBJ = $(DEPS_DIR)/libFLAC/bitmath.o \ @@ -1535,7 +1550,7 @@ ifeq ($(HAVE_ZLIB), 1) endif ifeq ($(HAVE_CHD), 1) - CFLAGS += -I$(LIBRETRO_COMM_DIR)/formats/libchdr + DEF_FLAGS += -I$(LIBRETRO_COMM_DIR)/formats/libchdr DEFINES += -DHAVE_CHD -DWANT_SUBCODE -DWANT_RAW_DATA_SECTOR OBJ += $(LIBRETRO_COMM_DIR)/formats/libchdr/libchdr_bitstream.o \ $(LIBRETRO_COMM_DIR)/formats/libchdr/libchdr_cdrom.o \ @@ -1587,6 +1602,12 @@ ifdef HAVE_COMPRESSION DEFINES += -DHAVE_COMPRESSION endif +# Easter Egg +ifeq ($(HAVE_EASTEREGG),1) + DEFINES += -DHAVE_EASTEREGG + OBJ += cores/libretro-gong/gong.o +endif + # Video4Linux 2 ifeq ($(HAVE_V4L2),1) @@ -1754,9 +1775,11 @@ ifneq ($(findstring Win32,$(OS)),) OBJ += gfx/drivers/gdi_gfx.o \ gfx/drivers_context/gdi_ctx.o \ gfx/drivers_font/gdi_font.o \ - gfx/display_servers/dispserv_win32.o \ - menu/drivers_display/menu_display_gdi.o + gfx/display_servers/dispserv_win32.o + ifeq ($(HAVE_MENU_COMMON), 1) + OBJ += menu/drivers_display/menu_display_gdi.o + endif LIBS += -lmsimg32 -lhid -lsetupapi endif @@ -1827,7 +1850,7 @@ endif ifeq ($(WANT_IOSUHAX), 1) DEFINES += -I$(DEPS_DIR)/libiosuhax - CFLAGS += -I$(DEPS_DIR)/libiosuhax + DEF_FLAGS += -I$(DEPS_DIR)/libiosuhax OBJ += $(DEPS_DIR)/libiosuhax/iosuhax.o \ $(DEPS_DIR)/libiosuhax/iosuhax_devoptab.o \ $(DEPS_DIR)/libiosuhax/iosuhax_disc_interface.o @@ -1835,7 +1858,7 @@ endif ifeq ($(WANT_LIBFAT), 1) DEFINES += -I$(DEPS_DIR)/libfat/include - CFLAGS += -I$(DEPS_DIR)/libfat/include + DEF_FLAGS += -I$(DEPS_DIR)/libfat/include OBJ += $(DEPS_DIR)/libfat/cache.o \ $(DEPS_DIR)/libfat/directory.o \ $(DEPS_DIR)/libfat/disc.o \ @@ -1869,7 +1892,7 @@ endif # Help at https://modmyclassic.com/comp ifeq ($(HAVE_CLASSIC), 1) - CFLAGS += -DHAVE_CLASSIC + DEF_FLAGS += -DHAVE_CLASSIC endif ifeq ($(HAVE_C_A7A7), 1) @@ -1881,12 +1904,11 @@ ifeq ($(HAVE_C_A7A7), 1) -fno-unwind-tables -fno-asynchronous-unwind-tables -fno-unroll-loops \ -fmerge-all-constants -fno-math-errno \ -marm -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard - CFLAGS += $(C_A7A7_OPT) - CXXFLAGS += $(C_A7A7_OPT) + DEF_FLAGS += $(C_A7A7_OPT) ifeq ($(shell echo `$(CC) -dumpversion` "< 4.9" | bc -l), 1) - CFLAGS += -march=armv7-a + DEF_FLAGS += -march=armv7-a else - CFLAGS += -march=armv7ve + DEF_FLAGS += -march=armv7ve # If gcc is 5.0 or later ifeq ($(shell echo `$(CC) -dumpversion` ">= 5" | bc -l), 1) LDFLAGS += -static-libgcc -static-libstdc++ @@ -1895,6 +1917,6 @@ ifeq ($(HAVE_C_A7A7), 1) endif ifeq ($(HAVE_HAKCHI), 1) - CFLAGS += -DHAVE_HAKCHI + DEF_FLAGS += -DHAVE_HAKCHI endif ################################## diff --git a/Makefile.ctr b/Makefile.ctr index 4b1318aadf..295cd4b557 100644 --- a/Makefile.ctr +++ b/Makefile.ctr @@ -62,6 +62,7 @@ else HAVE_RPNG = 1 HAVE_RJPEG = 1 HAVE_RBMP = 1 + HAVE_MENU = 1 HAVE_RGUI = 1 HAVE_ZLIB = 1 HAVE_7ZIP = 1 @@ -80,6 +81,7 @@ else #HAVE_BUILTINMBEDTLS = 1 include Makefile.common + CFLAGS += $(DEF_FLAGS) BLACKLIST := BLACKLIST += input/input_overlay.o BLACKLIST += tasks/task_overlay.o @@ -105,7 +107,6 @@ MAKEROM_ARGS_COMMON = -rsf $(APP_RSF) -exefslogo -elf $(TARGET).elf -icon $(TARG INCDIRS := -I$(CTRULIB)/include LIBDIRS := -L. -L$(CTRULIB)/lib - ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -marm -mfpu=vfp -mtp=soft CFLAGS += -mword-relocations \ @@ -149,7 +150,6 @@ LDFLAGS += -specs=ctr/3dsx_custom.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map) CFLAGS += -std=gnu99 -ffast-math - LIBS := $(WHOLE_START) -lretro_ctr $(WHOLE_END) -lm ifeq ($(DEBUG), 1) @@ -158,7 +158,6 @@ else LIBS += -lctru endif - ifeq ($(BUILD_3DSX), 1) TARGET_3DSX := $(TARGET).3dsx $(TARGET).smdh endif @@ -268,7 +267,6 @@ $(TARGET).3ds: $(TARGET).elf $(TARGET).bnr $(TARGET).icn $(APP_RSF) $(TARGET).cia: $(TARGET).elf $(TARGET).bnr $(TARGET).icn $(APP_RSF) $(MAKEROM) -f cia -o $@ $(MAKEROM_ARGS_COMMON) -DAPP_ENCRYPTED=false - clean: rm -f $(OBJ) rm -f $(TARGET).3dsx @@ -283,4 +281,3 @@ clean: .PHONY: clean - diff --git a/Makefile.ctr.salamander b/Makefile.ctr.salamander index 2c45a1bfe2..58f172aa94 100644 --- a/Makefile.ctr.salamander +++ b/Makefile.ctr.salamander @@ -94,10 +94,8 @@ LDFLAGS += -specs=ctr/3dsx_custom.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map) CFLAGS += -std=gnu99 -ffast-math - LIBS := -lctru -lm - ifeq ($(BUILD_3DSX), 1) TARGET_3DSX := $(TARGET).3dsx $(TARGET).smdh endif @@ -221,4 +219,3 @@ clean: .PHONY: clean - diff --git a/Makefile.emscripten b/Makefile.emscripten index c935759ab1..28d5698702 100644 --- a/Makefile.emscripten +++ b/Makefile.emscripten @@ -16,6 +16,7 @@ HAVE_OPENGLES = 1 HAVE_RJPEG = 0 HAVE_RPNG = 1 HAVE_EMSCRIPTEN = 1 +HAVE_MENU = 1 HAVE_RGUI = 1 HAVE_SDL = 0 HAVE_SDL2 = 0 @@ -57,7 +58,7 @@ endif include Makefile.common -CFLAGS += -Ideps/libz -Ideps -Ideps/stb +CFLAGS += $(DEF_FLAGS) -Ideps/libz -Ideps -Ideps/stb libretro = libretro_emscripten.bc ifneq ($(V), 1) diff --git a/Makefile.griffin b/Makefile.griffin index 03d6d22d8d..c77f6c73c1 100644 --- a/Makefile.griffin +++ b/Makefile.griffin @@ -158,8 +158,6 @@ else ifeq ($(libogc_platform), 1) endif endif - LIBS += -logc - ifeq ($(EXTERNAL_LIBOGC), 1) LIBS += -lfat endif @@ -176,6 +174,8 @@ else ifeq ($(libogc_platform), 1) endif endif + LIBS += -logc + CFLAGS += -DGEKKO -U__INT32_TYPE__ -U __UINT32_TYPE__ -D__INT32_TYPE__=int HAVE_RUNAHEAD := 1 @@ -430,8 +430,8 @@ else ifeq ($(platform), windows_msvc2005_x86) CXX = cl.exe LD = link.exe - PLATCFLAGS += -D_WIN32 -D_WIN32_WINNT=0x0410 -D__STDC_CONSTANT_MACROS -D_MBCS - LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib + PLATCFLAGS += -D_WIN32 -D_WIN32_WINNT=0x0410 -D__STDC_CONSTANT_MACROS -D_MBCS -DHAVE_EASTEREGG + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib msimg32.lib PATH := $(shell IFS=$$'\n'; cygpath "$(VS80COMNTOOLS)../../VC/bin"):$(PATH) PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS80COMNTOOLS)../IDE") @@ -479,7 +479,7 @@ else ifneq (,$(findstring windows_msvc2010,$(platform))) LD = link.exe PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS - PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 -DHAVE_EASTEREGG LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib PlatformSuffix = $(subst windows_msvc2010_,,$(platform)) @@ -550,7 +550,7 @@ else ifneq (,$(findstring windows_msvc2012,$(platform))) LD = link.exe PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS - PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 -DHAVE_EASTEREGG LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib PlatformSuffix = $(subst windows_msvc2012_,,$(platform)) @@ -625,7 +625,7 @@ else ifneq (,$(findstring windows_msvc2013,$(platform))) LD = link.exe PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS - PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 -DHAVE_EASTEREGG LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib PlatformSuffix = $(subst windows_msvc2013_,,$(platform)) @@ -700,7 +700,7 @@ else ifneq (,$(findstring windows_msvc2015,$(platform))) LD = link.exe PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS - PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 -DHAVE_EASTEREGG LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib PlatformSuffix = $(subst windows_msvc2015_,,$(platform)) @@ -1074,7 +1074,6 @@ overlays-checkout: $(GIT) clone git://github.com/libretro/common-overlays.git $(OVERLAY_DIR); \ fi - clean: rm -f $(EXT_TARGET) rm -f $(EXT_INTER_TARGET) diff --git a/Makefile.libnx b/Makefile.libnx index 7a087bdfa5..f2acd1712b 100644 --- a/Makefile.libnx +++ b/Makefile.libnx @@ -41,6 +41,7 @@ HAVE_NETWORKING = 1 HAVE_NETPLAYDISCOVERY = 1 HAVE_STB_FONT = 1 HAVE_CHEEVOS = 1 +HAVE_CHD = 1 # RetroArch libnx useful flags HAVE_THREADS = 1 diff --git a/Makefile.libogc b/Makefile.libogc index 77d3bf6c5f..70c846c461 100644 --- a/Makefile.libogc +++ b/Makefile.libogc @@ -45,7 +45,6 @@ export CXX := $(PREFIX)g++ export AR := $(PREFIX)ar export OBJCOPY := $(PREFIX)objcopy - ISVC=$(or $(VCBUILDHELPER_COMMAND),$(MSBUILDEXTENSIONSPATH32),$(MSBUILDEXTENSIONSPATH)) #--------------------------------------------------------------------------------- @@ -131,7 +130,6 @@ INCLUDES := $(DEFINCS) \ MACHDEP := -DBIGENDIAN -DGEKKO -mcpu=750 -meabi -msdata=eabi -mhard-float -ffunction-sections -fdata-sections - ifeq ($(PLATFORM),wii) MACHDEP += -DHW_RVL endif @@ -159,7 +157,6 @@ VPATH := $(LWIPDIR) \ $(LIBWIIKEYB) \ $(STUBSDIR) - #--------------------------------------------------------------------------------- SOURCES_LWIP := $(LWIPDIR)/network.c \ $(LWIPDIR)/netio.c \ @@ -264,7 +261,6 @@ SOURCES_OGC_ASM := $(OGCDIR)/cache_asm.S \ $(OGCDIR)/system_asm.S \ $(OGCDIR)/video_asm.S - ifneq ($(BUILD_LITE), 1) SOURCES_OGC += $(OGCDIR)/dvd.c endif diff --git a/Makefile.msvc b/Makefile.msvc index 3ece3af7a4..02361fe30e 100644 --- a/Makefile.msvc +++ b/Makefile.msvc @@ -7,7 +7,6 @@ ARCH = amd64 BUILD_DIR = objs/msvc CXX_BUILD = 0 - WindowsSdkDir = C:\Program Files (x86)\Windows Kits\10\$(NOTHING) WindowsSDKVersion := 10.0.14393.0\$(NOTHING) VCINSTALLDIR := C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\$(NOTHING) @@ -30,6 +29,7 @@ HAVE_WINMM := 1 HAVE_RPNG := 1 HAVE_ZLIB := 1 WANT_ZLIB := 1 +HAVE_MENU := 1 HAVE_RGUI := 1 HAVE_XMB := 1 HAVE_MATERIALUI := 1 @@ -59,7 +59,7 @@ HAVE_IMAGEVIEWER := 1 include Makefile.common INCLUDE_DIRS := $(patsubst -isystem%,-I%,$(INCLUDE_DIRS)) -CFLAGS := $(filter-out -Wno-unknown-pragmas,$(CFLAGS)) +CFLAGS := $(filter-out -Wno-unknown-pragmas,$(DEF_FLAGS)) CXXFLAGS := $(filter-out -fpermissive -Wno-switch -Wno-sign-compare -fno-strict-aliasing -Wno-maybe-uninitialized -Wno-reorder -Wno-parentheses,$(CXXFLAGS)) LIBS := $(filter-out -lstdc++,$(LIBS)) @@ -90,14 +90,12 @@ ifeq ($(ARCH),x86) CROSS = endif - INCLUDE := $(VCINSTALLDIR)include;$(VCINSTALLDIR)atlmfc\include;$(WindowsSdkDir)include\$(WindowsSDKVersion)ucrt;$(WindowsSdkDir)include\$(WindowsSDKVersion)shared;$(WindowsSdkDir)include\$(WindowsSDKVersion)um; LIB := $(VCINSTALLDIR)LIB\$(CROSS);$(VCINSTALLDIR)atlmfc\lib\$(CROSS);$(WindowsSdkDir)lib\$(WindowsSDKVersion)ucrt\$(TARGET_ARCH2);$(WindowsSdkDir)lib\$(WindowsSDKVersion)um\$(TARGET_ARCH2);C:\Program Files (x86)\NVIDIA Corporation\Cg\lib.$(TARGET_ARCH2);C:\Program Files (x86)\Microsoft DirectX SDK (February 2010)\Lib\$(TARGET_ARCH2); LIBPATH := $(VCINSTALLDIR)LIB\$(CROSS);$(VCINSTALLDIR)atlmfc\lib\$(CROSS); PATH := $(shell IFS=$$'\n'; cygpath "$(VCINSTALLDIR)bin\\$(CROSS)"):$(shell IFS=$$'\n'; cygpath "$(WindowsSdkDir)\bin\\$(ARCH2)"):$(PATH) - export INCLUDE := $(INCLUDE) export LIB := $(LIB) export LIBPATH := $(LIBPATH) @@ -144,7 +142,6 @@ RC = rc.exe LIBS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib LDFLAGS += -nologo -wx -nxcompat -machine:$(TARGET_ARCH2) - ifeq ($(DEBUG),1) FLAGS += -GS -Gy -Od -RTC1 -D_SECURE_SCL=1 -Zi FLAGS += -MDd @@ -155,7 +152,6 @@ else FLAGS += -MD endif - ifeq ($(DEBUG),1) BUILD_DIR := $(BUILD_DIR)-debug endif @@ -170,7 +166,6 @@ ifneq ($(V), 1) Q := @ endif - ifeq ($(GRIFFIN_BUILD), 1) OBJ := griffin/griffin.o griffin/griffin_cpp.o DEFINES += -DHAVE_GRIFFIN -DUSE_MATH_DEFINES @@ -188,9 +183,6 @@ OBJ := $(patsubst %rarch.o,%rarch.res,$(OBJ)) OBJ := $(addprefix $(BUILD_DIR)/,$(OBJ)) OBJ := $(OBJ:.o=.obj) - - - LDFLAGS += -WX -SUBSYSTEM:WINDOWS -ENTRY:mainCRTStartup DEFINES := $(patsubst -f%,,$(DEFINES)) @@ -198,7 +190,6 @@ LDFLAGS := $(patsubst -l%,%.lib,$(LDFLAGS)) LIBS := $(filter-out -lm,$(LIBS)) LIBS := $(patsubst -l%,%.lib,$(LIBS)) - #$(info INCLUDE_DIRS : $(INCLUDE_DIRS)) #$(info DEFINES : $(DEFINES)) #$(info CFLAGS : $(CFLAGS)) diff --git a/Makefile.orbis b/Makefile.orbis index 20f509c555..ee0e5a8a44 100644 --- a/Makefile.orbis +++ b/Makefile.orbis @@ -55,6 +55,7 @@ else endif include Makefile.common + CFLAGS += $(DEF_FLAGS) BLACKLIST := OBJ := $(filter-out $(BLACKLIST),$(OBJ)) @@ -64,7 +65,6 @@ else #OBJ += frontend/drivers/platform_orbis.o endif - ifeq ($(strip $(PS4SDK)),) $(error "Please set PS4SDK in your environment. export PS4SDK=ps4sdk") endif @@ -123,7 +123,6 @@ CXXFLAGS := $(CFLAGS) PS4_LIBS := -lps4link -ldebugnet -lorbisFile -lelfloader -lorbisKeyboard -lorbis2d -lpng -lz -lorbisGl -lorbisPad -lorbisAudio -lmod -lorbisFileBrowser -lorbisXbmFont -lSceNet_stub -lScePigletv2VSH_stub -lSceSystemService_stub -lSceUserService_stub -lScePad_stub -lSceAudioOut_stub -lSceIme_stub -lSceSysmodule_stub \ -lPs4_extension_kernel_call_standard -lPs4_extension_kernel_execute_dynlib_prepare_dlclose -lPs4_common_kernel -lPs4_common_user -lPs4_common_generic -lPs4LibCInternalAdaptive_stub -lPs4LibKernelAdaptive_stub -lSceLibcInternal_stub -lkernel_stub -lps4Kernel_stub -lPs4_base_stub_resolve_minimal -lPs4_base_kernel_dlsym_standard -lPs4_base_kernel_seek_elf_address_standard -lPs4_base_assembler_register_parameter_standard -lPs4_base_assembler_system_call_standard - LIBS := $(WHOLE_START) -lretro_orbis $(WHOLE_END) $(PS4_LIBS) TARGETS := $(TARGET).elf @@ -131,7 +130,6 @@ TARGETS := $(TARGET).elf DEPFLAGS = -MT $@ -MMD -MP -MF $*.Tdepend POSTCOMPILE = mv -f $*.Tdepend $*.depend - all: $(TARGETS) %.o: %.cpp @@ -144,7 +142,6 @@ all: $(TARGETS) $(CC) -c -o $@ $< $(CFLAGS) $(INCDIRS) $(DEPFLAGS) $(POSTCOMPILE) - %.o: %.S %.o: %.S %.depend $(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) @@ -167,4 +164,4 @@ clean: .PHONY: clean all .PRECIOUS: %.depend --include $(OBJ:.o=.depend) \ No newline at end of file +-include $(OBJ:.o=.depend) diff --git a/Makefile.ps2 b/Makefile.ps2 index cbd9a5c556..094536e00c 100644 --- a/Makefile.ps2 +++ b/Makefile.ps2 @@ -1,11 +1,11 @@ BUILD_PRX = 0 -DEBUG = 1 +DEBUG = 0 HAVE_KERNEL_PRX = 0 HAVE_LOGGER = 0 HAVE_FILE_LOGGER = 0 HAVE_THREADS = 0 BIG_STACK = 0 -WHOLE_ARCHIVE_LINK = 0 +MUTE_WARNINGS = 0 PS2_IP = 192.168.1.150 #Configuration for IRX @@ -13,38 +13,37 @@ EE_BIN2O = bin2o IRX_DIR = $(PS2SDK)/iop/irx TARGET = retroarchps2.elf +TARGET_RELEASE = retroarchps2-release.elf ifeq ($(DEBUG), 1) OPTIMIZE_LV := -O0 -g RARCH_DEFINES += -DDEBUG else OPTIMIZE_LV := -O2 + LDFLAGS := -s endif -ifeq ($(WHOLE_ARCHIVE_LINK), 1) - WHOLE_START := -Wl,--whole-archive - WHOLE_END := -Wl,--no-whole-archive +ifeq ($(MUTE_WARNINGS), 1) + DISABLE_WARNINGS := -Wno-sign-compare -Wno-unused -Wno-parentheses endif -INCDIR = -I$(PS2SDK)/ports/include -I$(PS2DEV)/gsKit/include -I$(PS2SDK)/iop/include -I$(PS2SDK)/ee/include -I$(PS2SDK)/common/include +INCDIR = -I$(PS2DEV)/gsKit/include -I$(PS2SDK)/ports/include INCDIR += -Ips2 -Ips2/include -Ilibretro-common/include INCDIR += -Ideps -Ideps/stb -Ideps/libz -Ideps/7zip -Ideps/pthreads -Ideps/pthreads/platform/ps2 -Ideps/pthreads/platform/helper GPVAL = -G0 -CFLAGS = $(OPTIMIZE_LV) -ffast-math -fsingle-precision-constant +CFLAGS = $(OPTIMIZE_LV) $(DISABLE_WARNINGS) -ffast-math -fsingle-precision-constant ASFLAGS = $(CFLAGS) RARCH_DEFINES += -DPS2 -DUSE_IOP_CTYPE_MACRO -D_MIPS_ARCH_R5900 -DHAVE_ZLIB -DHAVE_RPNG -DHAVE_RJPEG -DWANT_ZLIB RARCH_DEFINES += -DHAVE_GRIFFIN=1 -DRARCH_INTERNAL -DRARCH_CONSOLE -DHAVE_MENU -DHAVE_RGUI -DHAVE_FILTERS_BUILTIN -DHAVE_7ZIP -DHAVE_CC_RESAMPLER LIBDIR = -LDFLAGS = -L$(PS2SDK)/ports/lib -L$(PS2DEV)/gsKit/lib -L$(PS2SDK)/ee/lib -L. -#LIBS = $(WHOLE_START) -lretro_ps2 $(WHOLE_END) -lstdc++ -lm -lz -lgskit -ldmakit -lpng -laudsrv -lpad -lcdvd -lmad -lfileXio -lpatches -LIBS += $(WHOLE_START) -lretro_ps2 $(WHOLE_END) -LIBS += -lm -lg -lz -ldebug -lfileXio -laudsrv -lpatches -lpoweroff -ldma -lgskit -ldmakit -lpad -lsdl +LDFLAGS += -L$(PS2SDK)/ports/lib -L$(PS2DEV)/gsKit/lib -L$(PS2SDK)/ee/lib -L. +LIBS += -lretro_ps2 -lgskit -ldmakit -lgskit_toolkit -laudsrv -lpad -lmc -lhdd -lsdl -lfileXio -lpatches -lpoweroff #IRX modules # IRX modules - modules have to be in IRX_DIR -IRX = iomanX.irx fileXio.irx usbd.irx usbhdfsd.irx freesd.irx audsrv.irx poweroff.irx ps2dev9.irx ps2atad.irx ps2hdd.irx ps2fs.irx +IRX = iomanX.irx fileXio.irx mcman.irx mcserv.irx usbd.irx usbhdfsd.irx freesd.irx audsrv.irx poweroff.irx ps2dev9.irx ps2atad.irx ps2hdd.irx ps2fs.irx IRX_OBJ = $(IRX:.irx=.o) EE_OBJS += $(IRX_OBJ) @@ -67,12 +66,13 @@ endif CFLAGS += $(RARCH_DEFINES) # Missing objecst on the PS2SDK -EE_OBJS += ps2/compat_ctype.o +EE_OBJS += ps2/compat_files/compat_ctype.o ps2/compat_files/time.o #EE_OBJS = griffin/griffin.o bootstrap/ps2/kernel_functions.o EE_OBJS += griffin/griffin.o EE_CFLAGS = $(CFLAGS) +EE_CXXFLAGS = $(CFLAGS) EE_LDFLAGS = $(LDFLAGS) EE_LIBS = $(LIBS) EE_ASFLAGS = $(ASFLAGS) @@ -95,6 +95,11 @@ run: debug: clean prepare all run +package: + ps2-packer $(EE_BIN) $(TARGET_RELEASE) + +release: clean all package + #Specific file name and output per IRX Module $(EE_IRX_OBJ): $(EE_BIN2O) $(EE_GPVAL) $(IRX_DIR)/$(@:.o=.irx) $@ $(@:.o=_irx) @@ -102,4 +107,8 @@ $(EE_IRX_OBJ): #Include preferences include $(PS2SDK)/samples/Makefile.pref include $(PS2SDK)/samples/Makefile.eeglobal - \ No newline at end of file + +#Linking with C++ +$(EE_BIN): $(EE_OBJS) $(PS2SDK)/ee/startup/crt0.o + $(EE_CXX) $(EE_NO_CRT) -T$(PS2SDK)/ee/startup/linkfile $(EE_CXXFLAGS) \ + -o $(EE_BIN) $(PS2SDK)/ee/startup/crt0.o $(CRTI_OBJ) $(CRTBEGIN_OBJ) $(EE_OBJS) $(CRTEND_OBJ) $(CRTN_OBJ) $(EE_LDFLAGS) $(EE_LIBS) diff --git a/Makefile.psp1 b/Makefile.psp1 index be0ae8e25a..e239278e3c 100644 --- a/Makefile.psp1 +++ b/Makefile.psp1 @@ -49,7 +49,6 @@ endif CFLAGS += $(RARCH_DEFINES) - EXTRA_TARGETS = EBOOT.PBP PSP_EBOOT_TITLE = RetroArch PSP1 diff --git a/Makefile.switch b/Makefile.switch index 0e12f5a448..fb27990459 100644 --- a/Makefile.switch +++ b/Makefile.switch @@ -34,13 +34,13 @@ else HAVE_DYNAMIC = 1 include Makefile.common - BLACKLIST := + CFLAGS += $(DEF_FLAGS) + BLACKLIST := BLACKLIST += input/input_overlay.o - BLACKLIST += tasks/task_overlay.o + BLACKLIST += tasks/task_overlay.o OBJ := $(filter-out $(BLACKLIST),$(OBJ)) endif - ifeq ($(strip $(LIBTRANSISTOR_HOME)),) $(error "Please set LIBTRANSISTOR_HOME in your environment. export LIBTRANSISTOR_HOME=") endif diff --git a/Makefile.vita b/Makefile.vita index 5645c9cabd..abc953ccec 100644 --- a/Makefile.vita +++ b/Makefile.vita @@ -55,6 +55,7 @@ else endif include Makefile.common + CFLAGS += $(DEF_FLAGS) BLACKLIST := OBJ := $(filter-out $(BLACKLIST),$(OBJ)) @@ -64,7 +65,6 @@ else OBJ += frontend/drivers/platform_psp.o endif - ifeq ($(strip $(VITASDK)),) $(error "Please set VITASDK in your environment. export VITASDK=vitasdk") endif @@ -127,7 +127,6 @@ TARGETS := $(TARGET).vpk DEPFLAGS = -MT $@ -MMD -MP -MF $*.Tdepend POSTCOMPILE = mv -f $*.Tdepend $*.depend - all: $(TARGETS) %.o: %.cpp @@ -140,7 +139,6 @@ all: $(TARGETS) $(CC) -c -o $@ $< $(CFLAGS) $(INCDIRS) $(DEPFLAGS) $(POSTCOMPILE) - %.o: %.S %.o: %.S %.depend $(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) diff --git a/Makefile.wii.salamander b/Makefile.wii.salamander index e39c30bdc8..dc5249f832 100644 --- a/Makefile.wii.salamander +++ b/Makefile.wii.salamander @@ -42,12 +42,13 @@ endif MACHDEP := -DGEKKO -DHW_RVL -mrvl -mcpu=750 -meabi -mhard-float CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(INCLUDE) LDFLAGS := $(MACHDEP) -Wl,-Map,$(notdir $(ELF_TARGET)).map -LIBS := -lwiiuse -logc -lbte ifeq ($(EXTERNAL_LIBOGC), 1) -LIBS += -lfat +LIBS := -lfat endif +LIBS += -lwiiuse -logc -lbte + APP_BOOTER_DIR = wii/app_booter OBJ = frontend/frontend_salamander.o \ diff --git a/Makefile.wiiu b/Makefile.wiiu index e77be12ea9..1c75c3e431 100644 --- a/Makefile.wiiu +++ b/Makefile.wiiu @@ -115,6 +115,7 @@ endif HAVE_RPNG = 1 HAVE_RJPEG = 1 HAVE_RBMP = 1 + HAVE_MENU = 1 HAVE_RGUI = 1 HAVE_ZLIB = 1 HAVE_7ZIP = 1 @@ -241,7 +242,6 @@ ifneq ($(WANT_IOSUHAX), 1) LIBS += -liosuhax endif - RPX_OBJ = $(BUILD_DIR)/wiiu/system/stubs_rpl.o HBL_ELF_OBJ = $(BUILD_DIR)/wiiu/system/dynamic.o $(BUILD_DIR)/wiiu/system/stubs_elf.o @@ -263,13 +263,11 @@ endif DEPFLAGS = -MT $@ -MMD -MP -MF $(BUILD_DIR)/$*.depend - all: $(TARGETS) %: $(BUILD_DIR)/% cp $< $@ - $(BUILD_DIR)/%.o: %.cpp %.depend @$(if $(Q), echo CXX $<,) @mkdir -p $(dir $@) diff --git a/Makefile.win b/Makefile.win index 02d70bde7f..0896df2959 100644 --- a/Makefile.win +++ b/Makefile.win @@ -12,6 +12,7 @@ HAVE_NETPLAYDISCOVERY = 1 HAVE_STDIN_CMD = 1 HAVE_COMMAND = 1 HAVE_THREADS = 1 +HAVE_MENU = 1 HAVE_RGUI = 1 HAVE_MATERIALUI = 1 HAVE_7ZIP = 1 @@ -102,7 +103,6 @@ else WINDRES = windres endif - libretro ?= -lretro ifeq ($(DYNAMIC), 1) @@ -123,7 +123,7 @@ else CXXFLAGS += -O3 -ffast-math endif -CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -Ideps +CFLAGS += $(DEF_FLAGS) -Wall -Wno-unused-result -Wno-unused-variable -I. -Ideps CXXFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -Ideps -std=c++98 -D__STDC_CONSTANT_MACROS ifeq ($(CXX_BUILD), 1) CFLAGS += -std=c++98 -xc++ -D__STDC_CONSTANT_MACROS diff --git a/audio/audio_driver.c b/audio/audio_driver.c index 4ad3d13a77..28cf2eaa5e 100644 --- a/audio/audio_driver.c +++ b/audio/audio_driver.c @@ -122,6 +122,9 @@ static const audio_driver_t *audio_drivers[] = { #if defined(PSP) || defined(VITA) || defined(ORBIS) &audio_psp, #endif +#if defined(PS2) + &audio_ps2, +#endif #ifdef _3DS &audio_ctr_csnd, &audio_ctr_dsp, @@ -394,7 +397,6 @@ static void audio_driver_mixer_init(unsigned out_rate) audio_mixer_init(out_rate); } - static bool audio_driver_init_internal(bool audio_cb_inited) { unsigned new_rate = 0; @@ -633,7 +635,6 @@ static void audio_driver_flush(const int16_t *data, size_t samples) src_data.data_in = audio_driver_input_data; src_data.input_frames = samples >> 1; - if (audio_driver_dsp) { struct retro_dsp_data dsp_data; @@ -1501,7 +1502,6 @@ error: return false; } - bool audio_driver_stop(void) { if (!current_audio || !current_audio->stop @@ -1591,7 +1591,6 @@ void audio_set_bool(enum audio_action action, bool val) } } - void audio_set_float(enum audio_action action, float val) { switch (action) diff --git a/audio/drivers/alsa_qsa.c b/audio/drivers/alsa_qsa.c index 76d442db98..ddabe907a3 100644 --- a/audio/drivers/alsa_qsa.c +++ b/audio/drivers/alsa_qsa.c @@ -219,7 +219,6 @@ static int check_pcm_status(void *data, int channel_type) return ret; } - static ssize_t alsa_qsa_write(void *data, const void *buf, size_t size) { alsa_t *alsa = (alsa_t*)data; @@ -328,7 +327,6 @@ static void alsa_qsa_set_nonblock_state(void *data, bool state) alsa->nonblock = state; } - static bool alsa_qsa_use_float(void *data) { alsa_t *alsa = (alsa_t*)data; diff --git a/audio/drivers/coreaudio.c b/audio/drivers/coreaudio.c index 6f255bbc5b..30d6f7c1ca 100644 --- a/audio/drivers/coreaudio.c +++ b/audio/drivers/coreaudio.c @@ -15,7 +15,6 @@ */ #include - #if TARGET_OS_IPHONE #include #else diff --git a/audio/drivers/ctr_csnd_audio.c b/audio/drivers/ctr_csnd_audio.c index 8731706c32..019dd8a040 100644 --- a/audio/drivers/ctr_csnd_audio.c +++ b/audio/drivers/ctr_csnd_audio.c @@ -56,7 +56,6 @@ static void ctr_csnd_audio_update_playpos(ctr_csnd_audio_t* ctr) ctr->cpu_ticks_last += samples_played * CTR_CSND_CPU_TICKS_PER_SAMPLE; } - Result csndPlaySound_custom(int chn, u32 flags, float vol, float pan, void* data0, void* data1, u32 size) { @@ -289,7 +288,6 @@ static size_t ctr_csnd_audio_buffer_size(void *data) return CTR_CSND_AUDIO_COUNT; } - audio_driver_t audio_ctr_csnd = { ctr_csnd_audio_init, ctr_csnd_audio_write, diff --git a/audio/drivers/ctr_dsp_audio.c b/audio/drivers/ctr_dsp_audio.c index 1e0e83c5b4..48bf042e0c 100644 --- a/audio/drivers/ctr_dsp_audio.c +++ b/audio/drivers/ctr_dsp_audio.c @@ -195,7 +195,6 @@ static size_t ctr_dsp_audio_buffer_size(void *data) return CTR_DSP_AUDIO_COUNT; } - audio_driver_t audio_ctr_dsp = { ctr_dsp_audio_init, ctr_dsp_audio_write, diff --git a/audio/drivers/dsound.c b/audio/drivers/dsound.c index 396ff8a332..d74c0a2c0d 100644 --- a/audio/drivers/dsound.c +++ b/audio/drivers/dsound.c @@ -51,7 +51,6 @@ #pragma comment(lib, "dxguid") #endif - typedef struct dsound { LPDIRECTSOUND ds; @@ -174,7 +173,6 @@ static DWORD CALLBACK dsound_thread(PVOID data) /* No space to write, or we don't have data in our fifo, * but we can wait some time before it underruns ... */ - /* We could opt for using the notification interface, * but it is not guaranteed to work, so use high * priority sleeping patterns. diff --git a/audio/drivers/nullaudio.c b/audio/drivers/nullaudio.c index 39be26d4d0..c7dffc6f7e 100644 --- a/audio/drivers/nullaudio.c +++ b/audio/drivers/nullaudio.c @@ -21,7 +21,7 @@ static void *null_audio_init(const char *device, unsigned rate, unsigned latency unsigned block_frames, unsigned *new_rate) { - RARCH_ERR("Using the null audio driver. RetroArch will be silent."); + RARCH_ERR("Using the null audio driver. RetroArch will be silent.\n"); (void)device; (void)rate; diff --git a/audio/drivers/opensl.c b/audio/drivers/opensl.c index d1ae7446a5..c683fecd5c 100644 --- a/audio/drivers/opensl.c +++ b/audio/drivers/opensl.c @@ -232,7 +232,6 @@ static bool sl_start(void *data, bool is_shutdown) return sl->is_paused ? false : true; } - static ssize_t sl_write(void *data, const void *buf_, size_t size) { sl_t *sl = (sl_t*)data; diff --git a/audio/drivers/ps2_audio.c b/audio/drivers/ps2_audio.c new file mode 100644 index 0000000000..efae072a6a --- /dev/null +++ b/audio/drivers/ps2_audio.c @@ -0,0 +1,293 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2014-2017 - Francisco Javier Trujillo Mata + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#include +#include +#include +#include + +#include +#include + +#include "../audio_driver.h" + +typedef struct ps2_audio +{ + fifo_buffer_t* buffer; + bool nonblocking; + volatile bool running; + int worker_thread; + int lock; + int cond_lock; + +} ps2_audio_t; + +static ps2_audio_t *backup_ps2; +static u8 audioThreadStack[4 * 1024] __attribute__ ((aligned(16))); + +#define AUDIO_OUT_BUFFER 2 * 1024 +#define AUDIO_BUFFER 64 * 1024 +#define AUDIO_CHANNELS 2 +#define AUDIO_BITS 16 +#define AUDIO_PRIORITY 0x7F /* LOWER VALUE GRATHER PRIORITY*/ + +static void audioMainLoop(void *data) +{ + char out_tmp[AUDIO_OUT_BUFFER]; + ps2_audio_t* ps2 = backup_ps2; + + while (ps2->running) + { + size_t size; + + WaitSema(ps2->lock); + size = MIN(fifo_read_avail(ps2->buffer), sizeof(out_tmp)); + fifo_read(ps2->buffer, out_tmp, size); + iSignalSema(ps2->lock); + iSignalSema(ps2->cond_lock); + + audsrv_wait_audio(size); + audsrv_play_audio(out_tmp, size); + } + + audsrv_stop_audio(); + ExitDeleteThread(); +} + +static void audioCreateThread(ps2_audio_t *ps2) +{ + int ret; + ee_thread_t thread; + + thread.func=&audioMainLoop; + thread.stack=audioThreadStack; + thread.stack_size=sizeof(audioThreadStack); + thread.gp_reg=&_gp; + thread.initial_priority=AUDIO_PRIORITY; + thread.attr=thread.option=0; + + /*Backup the PS2 content to be used in the thread */ + backup_ps2 = ps2; + + ps2->running = true; + ps2->worker_thread = CreateThread(&thread); + + if (ps2->worker_thread >= 0) { + ret = StartThread(ps2->worker_thread, NULL); + if (ret < 0) { + printf("sound_init: StartThread returned %d\n", ret); + } + } else { + printf("CreateThread failed: %d\n", ps2->worker_thread); + } +} + +static void audioStopNDeleteThread(ps2_audio_t *ps2) +{ + ps2->running = false; + if (ps2->worker_thread) { + ps2->worker_thread = 0; + } +} + +static void audioConfigure(ps2_audio_t *ps2, unsigned rate) +{ + int err; + struct audsrv_fmt_t format; + + format.bits = AUDIO_BITS; + format.freq = rate; + format.channels = AUDIO_CHANNELS; + + err = audsrv_set_format(&format); + + if (err){ + printf("set format returned %d\n", err); + printf("audsrv returned error string: %s\n", audsrv_get_error_string()); + } + + audsrv_set_volume(MAX_VOLUME); +} + +static void audioCreateSemas(ps2_audio_t *ps2) +{ + ee_sema_t lock_info; + ee_sema_t cond_lock_info; + + lock_info.max_count = 1; + lock_info.init_count = 1; + lock_info.option = 0; + ps2->lock = CreateSema(&lock_info); + + cond_lock_info.init_count = 1; + cond_lock_info.max_count = 1; + cond_lock_info.option = 0; + + ps2->cond_lock = CreateSema(&cond_lock_info); +} + +static void *ps2_audio_init(const char *device, + unsigned rate, unsigned latency, + unsigned block_frames, + unsigned *new_rate) +{ + ps2_audio_t *ps2 = (ps2_audio_t*)calloc(1, sizeof(ps2_audio_t)); + + if (!ps2) + return NULL; + + ps2->buffer = fifo_new(AUDIO_BUFFER); + audioConfigure(ps2, rate); + audioCreateSemas(ps2); + audioCreateThread(ps2); + + return ps2; +} + +static void ps2_audio_free(void *data) +{ + ps2_audio_t* ps2 = (ps2_audio_t*)data; + if(!ps2) + return; + + if(ps2->running){ + audioStopNDeleteThread(ps2); + + if (ps2->lock){ + iDeleteSema(ps2->lock); + ps2->lock = 0; + } + + if (ps2->cond_lock){ + iDeleteSema(ps2->cond_lock); + ps2->cond_lock = 0; + } + + } + fifo_free(ps2->buffer); + free(ps2); +} + +static ssize_t ps2_audio_write(void *data, const void *buf, size_t size) +{ + ps2_audio_t* ps2 = (ps2_audio_t*)data; + + if (!ps2->running) + return -1; + + if (ps2->nonblocking){ + if (fifo_write_avail(ps2->buffer) < size) + return 0; + } + + while (fifo_write_avail(ps2->buffer) < size) { + WaitSema(ps2->cond_lock); + } + + WaitSema(ps2->lock); + fifo_write(ps2->buffer, buf, size); + iSignalSema(ps2->lock); + + return size; +} + +static bool ps2_audio_alive(void *data) +{ + bool alive = false; + + ps2_audio_t* ps2 = (ps2_audio_t*)data; + if (ps2) { + alive = ps2->running; + } + + return alive; +} + +static bool ps2_audio_stop(void *data) +{ + bool stop = true; + ps2_audio_t* ps2 = (ps2_audio_t*)data; + + if (ps2) { + audioStopNDeleteThread(ps2); + audsrv_stop_audio(); + } + + return stop; +} + +static bool ps2_audio_start(void *data, bool is_shutdown) +{ + ps2_audio_t* ps2 = (ps2_audio_t*)data; + bool start = true; + + if (ps2) { + if (!ps2->running && !ps2->worker_thread) { + audioCreateThread(ps2); + } + } + + return start; +} + +static void ps2_audio_set_nonblock_state(void *data, bool toggle) +{ + ps2_audio_t* ps2 = (ps2_audio_t*)data; + + if (ps2) { + ps2->nonblocking = toggle; + } +} + +static bool ps2_audio_use_float(void *data) +{ + return false; +} + +static size_t ps2_audio_write_avail(void *data) +{ + ps2_audio_t* ps2 = (ps2_audio_t*)data; + + if (ps2 && ps2->running) { + size_t size; + WaitSema(ps2->lock); + size = AUDIO_BUFFER - fifo_read_avail(ps2->buffer); + iSignalSema(ps2->lock); + return size; + } + + return 0; +} + +static size_t ps2_audio_buffer_size(void *data) +{ + return AUDIO_BUFFER; +} + +audio_driver_t audio_ps2 = { + ps2_audio_init, + ps2_audio_write, + ps2_audio_stop, + ps2_audio_start, + ps2_audio_alive, + ps2_audio_set_nonblock_state, + ps2_audio_free, + ps2_audio_use_float, + "ps2", + NULL, + NULL, + ps2_audio_write_avail, + ps2_audio_buffer_size +}; diff --git a/audio/drivers/psp_audio.c b/audio/drivers/psp_audio.c index e4716565f1..54e6d84a75 100644 --- a/audio/drivers/psp_audio.c +++ b/audio/drivers/psp_audio.c @@ -252,7 +252,6 @@ static bool psp_audio_alive(void *data) return psp->running; } - static bool psp_audio_stop(void *data) { psp_audio_t* psp = (psp_audio_t*)data; @@ -318,7 +317,6 @@ static size_t psp_buffer_size(void *data) return AUDIO_BUFFER_SIZE /** sizeof(uint32_t)*/; } - audio_driver_t audio_psp = { psp_audio_init, psp_audio_write, diff --git a/audio/drivers/switch_thread_audio.c b/audio/drivers/switch_thread_audio.c index 797bf77e6b..756a69ae90 100644 --- a/audio/drivers/switch_thread_audio.c +++ b/audio/drivers/switch_thread_audio.c @@ -80,7 +80,6 @@ static void mainLoop(void* data) RARCH_LOG("[Audio]: start mainLoop cpu %u tid %u\n", svcGetCurrentProcessorNumber(), swa->thread.handle); - while (swa->running) { size_t buf_avail, avail, to_write; diff --git a/audio/drivers/tinyalsa.c b/audio/drivers/tinyalsa.c index 50d66693d9..3443f049bf 100644 --- a/audio/drivers/tinyalsa.c +++ b/audio/drivers/tinyalsa.c @@ -296,7 +296,6 @@ #define SNDRV_PCM_MMAP_OFFSET_STATUS 0x80000000 #define SNDRV_PCM_MMAP_OFFSET_CONTROL 0x81000000 - /** Audio sample format of a PCM. * The first letter specifiers whether the sample is signed or unsigned. * The letter 'S' means signed. The letter 'U' means unsigned. diff --git a/audio/drivers/wasapi.c b/audio/drivers/wasapi.c index d711fd7141..d2144c584c 100644 --- a/audio/drivers/wasapi.c +++ b/audio/drivers/wasapi.c @@ -30,16 +30,12 @@ #include #ifdef _MSC_VER -/* IID_IAudioClient 1CB9AD4C-DBFA-4c32-B178-C2F568A703B2 */ -static const GUID IID_IAudioClient = { 0x1CB9AD4C, 0xDBFA, 0xB178, 0xC2, 0xF5, 0x68, 0xA7, 0x03, 0xB2 }; -/* IID_IAudioRenderClient F294ACFC-3146-4483-A7BF-ADDCA7C260E2 */ -static const GUID IID_IAudioRenderClient = { 0xF294ACFC, 0x3146, 0x4483, 0xA7BF, 0xAD, 0xDC, 0xA7, 0xC2, 0x60, 0xE2 }; -/* IID_IMMDeviceEnumerator A95664D2-9614-4F35-A746-DE8DB63617E6 */ -static const GUID IID_IMMDeviceEnumerator = { 0xA95664D2, 0x9614, 0x4F35, 0xA746, 0xDE, 0x8D, 0xB6, 0x36, 0x17, 0xE6 }; -/* CLSID_MMDeviceEnumerator BCDE0395-E52F-467C-8E3D-C4579291692E */ -static const GUID CLSID_MMDeviceEnumerator = { 0xBCDE0395, 0xE52F, 0x467C, 0x8E3D, 0xC4, 0x57, 0x92, 0x91, 0x69, 0x2E }; -/* KSDATAFORMAT_SUBTYPE_IEEE_FLOAT 00000003-0000-0010-8000-00aa00389b71 */ -static const GUID KSDATAFORMAT_SUBTYPE_IEEE_FLOAT = { 0x00000003, 0x0000, 0x0010, 0x8000, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 }; +DEFINE_GUID(IID_IAudioClient, 0x1CB9AD4C, 0xDBFA, 0x4C32, 0xB1, 0x78, 0xC2, 0xF5, 0x68, 0xA7, 0x03, 0xB2); +DEFINE_GUID(IID_IAudioRenderClient, 0xF294ACFC, 0x3146, 0x4483, 0xA7, 0xBF, 0xAD, 0xDC, 0xA7, 0xC2, 0x60, 0xE2); +DEFINE_GUID(IID_IMMDeviceEnumerator, 0xA95664D2, 0x9614, 0x4F35, 0xA7, 0x46, 0xDE, 0x8D, 0xB6, 0x36, 0x17, 0xE6); +DEFINE_GUID(CLSID_MMDeviceEnumerator, 0xBCDE0395, 0xE52F, 0x467C, 0x8E, 0x3D, 0xC4, 0x57, 0x92, 0x91, 0x69, 0x2E); +#undef KSDATAFORMAT_SUBTYPE_IEEE_FLOAT +DEFINE_GUID(KSDATAFORMAT_SUBTYPE_IEEE_FLOAT, 0x00000003, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xAA, 0x00, 0x38, 0x9B, 0x71); #endif #include diff --git a/audio/drivers/wiiu_audio.c b/audio/drivers/wiiu_audio.c index 0ea9106206..c13d7cf9bb 100644 --- a/audio/drivers/wiiu_audio.c +++ b/audio/drivers/wiiu_audio.c @@ -318,7 +318,6 @@ static size_t ax_audio_buffer_size(void* data) return AX_AUDIO_COUNT; } - audio_driver_t audio_ax = { ax_audio_init, diff --git a/audio/drivers/xaudio.c b/audio/drivers/xaudio.c index d344508b70..594d3124d4 100644 --- a/audio/drivers/xaudio.c +++ b/audio/drivers/xaudio.c @@ -201,9 +201,10 @@ static xaudio2_t *xaudio2_new(unsigned samplerate, unsigned channels, { xaudio2_t *handle = NULL; WAVEFORMATEX wfx = {0}; - -#ifndef _XBOX - CoInitializeEx(0, COINIT_MULTITHREADED); +#if !defined(_XBOX) && !defined(__WINRT__) + HRESULT hr = CoInitialize(NULL); + if (FAILED(hr)) + return NULL; #endif #if defined(__cplusplus) && !defined(CINTERFACE) @@ -222,8 +223,13 @@ static xaudio2_t *xaudio2_new(unsigned samplerate, unsigned channels, if (FAILED(XAudio2Create(&handle->pXAudio2, 0, XAUDIO2_DEFAULT_PROCESSOR))) goto error; +#if (_WIN32_WINNT >= 0x0602 /*_WIN32_WINNT_WIN8*/) + if (FAILED(IXAudio2_CreateMasteringVoice(handle->pXAudio2, &handle->pMasterVoice, channels, samplerate, 0, device, NULL, AudioCategory_GameEffects))) + goto error; +#else if (FAILED(IXAudio2_CreateMasteringVoice(handle->pXAudio2, &handle->pMasterVoice, channels, samplerate, 0, device, NULL))) goto error; +#endif xaudio2_set_wavefmt(&wfx, channels, samplerate); @@ -250,6 +256,9 @@ static xaudio2_t *xaudio2_new(unsigned samplerate, unsigned channels, error: xaudio2_free(handle); +#if !defined(_XBOX) && !defined(__WINRT__) + CoUninitialize(); +#endif return NULL; } @@ -399,6 +408,10 @@ static void xa_free(void *data) if (xa->xa) xaudio2_free(xa->xa); free(xa); + +#if !defined(_XBOX) && !defined(__WINRT__) + CoUninitialize(); +#endif } static size_t xa_write_avail(void *data) diff --git a/audio/drivers/xaudio.h b/audio/drivers/xaudio.h index 788fe16789..a16581807f 100644 --- a/audio/drivers/xaudio.h +++ b/audio/drivers/xaudio.h @@ -1,7 +1,5 @@ /* RetroArch - A frontend for libretro. - * Copyright (C) 2010-2014 - Hans-Kristian Arntzen - * Copyright (C) 2011-2017 - Daniel De Matteis - * Copyright (C) 2010-2014 - OV2 + * Copyright (C) 2018 - Krzysztof Haładyn * * RetroArch is free software: you can redistribute it and/or modify it under the terms * of the GNU General Public License as published by the Free Software Found- @@ -15,350 +13,14 @@ * If not, see . */ -/* Kinda stripped down. Only contains the bare essentials used in RetroArch. */ - -#ifndef XAUDIO2_STRIPPED_H -#define XAUDIO2_STRIPPED_H - -#include -#include - -/* All structures defined in this file use tight field packing */ -#pragma pack(push, 1) - -#if defined(__cplusplus) && !defined(CINTERFACE) -#define X2DEFAULT(x) = (x) +#if (_WIN32_WINNT >= 0x0602 /*_WIN32_WINNT_WIN8*/) +/* XAudio 2.7 it part of the old DirectX SDKs. XAudio 2.8+ is part of the + * Windows OS itself (starting from Windows 8). Since UWP lets you access + * only libraries that are built-in to the OS, the headers had to be + * upgraded to the newer version to get audio support working. */ +#include "xaudio29.h" #else -#define X2DEFAULT(x) +/* The old version still has to be there since XAudio 2.8 is not available + * on Windows 7 and earlier */ +#include "xaudio27.h" #endif - -#ifdef _XBOX -#include - -#ifndef __cplusplus -#define OPAQUE interface -#endif -#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ - DEFINE_GUID(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) -#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ - DEFINE_GUID(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) - -DEFINE_CLSID(XAudio2, 3eda9b49, 2085, 498b, 9b, b2, 39, a6, 77, 84, 93, de); -DEFINE_CLSID(XAudio2_Debug, 47199894, 7cc2, 444d, 98, 73, ce, d2, 56, 2c, c6, 0e); -DEFINE_IID(IXAudio2, 8bcf1f58, 9fe7, 4583, 8a, c6, e2, ad, c4, 65, c8, bb); - -#include /* Basic audio data types and constants */ - -#else - -#define WIN32_LEAN_AND_MEAN -#include -#include -#include -#include - -#ifndef __cplusplus -#undef OPAQUE -#define OPAQUE struct -#endif - -#define DEFINE_GUID_X(n, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ - static const GUID n = { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } } -#define DEFINE_CLSID_X(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ - DEFINE_GUID_X(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) -#define DEFINE_IID_X(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ - DEFINE_GUID_X(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) - -#ifndef __cplusplus -#ifndef INTERFACE -#define INTERFACE void -#endif -#endif - -DEFINE_CLSID_X(XAudio2, 5a508685, a254, 4fba, 9b, 82, 9a, 24, b0, 03, 06, af); /* 2.7 */ -DEFINE_IID_X(IXAudio2, 8bcf1f58, 9fe7, 4583, 8a, c6, e2, ad, c4, 65, c8, bb); - -#endif - -#ifdef _XBOX -#define XAUDIO2_DEFAULT_FREQ_RATIO 2.0f -#else -#define XAUDIO2_DEFAULT_FREQ_RATIO 4.0f -#endif - -#define XAUDIO2_COMMIT_NOW 0 -#define XAUDIO2_DEFAULT_CHANNELS 0 -#define XAUDIO2_DEFAULT_SAMPLERATE 0 - -#define XAUDIO2_DEBUG_ENGINE 0x0001 -#define XAUDIO2_VOICE_NOSRC 0x0004 - -typedef enum XAUDIO2_DEVICE_ROLE -{ - NotDefaultDevice = 0x0, - DefaultConsoleDevice = 0x1, - DefaultMultimediaDevice = 0x2, - DefaultCommunicationsDevice = 0x4, - DefaultGameDevice = 0x8, - GlobalDefaultDevice = 0xf, - InvalidDeviceRole = ~GlobalDefaultDevice -} XAUDIO2_DEVICE_ROLE; - -#ifdef _XBOX -typedef enum XAUDIO2_XBOX_HWTHREAD_SPECIFIER -{ - XboxThread0 = 0x01, - XboxThread1 = 0x02, - XboxThread2 = 0x04, - XboxThread3 = 0x08, - XboxThread4 = 0x10, - XboxThread5 = 0x20, - XAUDIO2_ANY_PROCESSOR = XboxThread4, - XAUDIO2_DEFAULT_PROCESSOR = XAUDIO2_ANY_PROCESSOR -} XAUDIO2_XBOX_HWTHREAD_SPECIFIER, XAUDIO2_PROCESSOR; -#else -typedef enum XAUDIO2_WINDOWS_PROCESSOR_SPECIFIER -{ -#if defined(__STDC_C89__) - XAUDIO2_ANY_PROCESSOR = 0xffff, -#else - XAUDIO2_ANY_PROCESSOR = 0xffffffff, -#endif - XAUDIO2_DEFAULT_PROCESSOR = XAUDIO2_ANY_PROCESSOR -} XAUDIO2_WINDOWS_PROCESSOR_SPECIFIER, XAUDIO2_PROCESSOR; -#endif - -typedef enum XAUDIO2_FILTER_TYPE { - LowPassFilter, - BandPassFilter, - HighPassFilter -} XAUDIO2_FILTER_TYPE; - -typedef struct XAUDIO2_DEVICE_DETAILS -{ - WCHAR DeviceID[256]; - WCHAR DisplayName[256]; - XAUDIO2_DEVICE_ROLE Role; - WAVEFORMATEXTENSIBLE OutputFormat; -} XAUDIO2_DEVICE_DETAILS; - -/* Forward declarations. */ -#ifdef __cplusplus -struct XAUDIO2_VOICE_DETAILS; -struct XAUDIO2_VOICE_SENDS; -struct XAUDIO2_EFFECT_DESCRIPTOR; -struct XAUDIO2_EFFECT_CHAIN; -struct XAUDIO2_FILTER_PARAMETERS; -struct XAUDIO2_BUFFER_WMA; -struct XAUDIO2_VOICE_STATE; -struct XAUDIO2_PERFORMANCE_DATA; -struct XAUDIO2_DEBUG_CONFIGURATION; -struct IXAudio2EngineCallback; -struct IXAudio2SubmixVoice; -#else -typedef OPAQUE XAUDIO2_VOICE_DETAILS XAUDIO2_VOICE_DETAILS; -typedef OPAQUE XAUDIO2_VOICE_SENDS XAUDIO2_VOICE_SENDS; -typedef OPAQUE XAUDIO2_EFFECT_DESCRIPTOR XAUDIO2_EFFECT_DESCRIPTOR; -typedef OPAQUE XAUDIO2_EFFECT_CHAIN XAUDIO2_EFFECT_CHAIN; -typedef OPAQUE XAUDIO2_FILTER_PARAMETERS XAUDIO2_FILTER_PARAMETERS; -typedef OPAQUE XAUDIO2_BUFFER_WMA XAUDIO2_BUFFER_WMA; -typedef OPAQUE XAUDIO2_VOICE_STATE XAUDIO2_VOICE_STATE; -typedef OPAQUE XAUDIO2_PERFORMANCE_DATA XAUDIO2_PERFORMANCE_DATA; -typedef OPAQUE XAUDIO2_DEBUG_CONFIGURATION XAUDIO2_DEBUG_CONFIGURATION; -typedef OPAQUE IXAudio2EngineCallback IXAudio2EngineCallback; -typedef OPAQUE IXAudio2SubmixVoice IXAudio2SubmixVoice; -#endif - - -typedef struct XAUDIO2_BUFFER -{ - UINT32 Flags; - UINT32 AudioBytes; - const BYTE* pAudioData; - UINT32 PlayBegin; - UINT32 PlayLength; - UINT32 LoopBegin; - UINT32 LoopLength; - UINT32 LoopCount; - void *pContext; -} XAUDIO2_BUFFER; - -#undef INTERFACE -#define INTERFACE IXAudio2VoiceCallback - -DECLARE_INTERFACE(IXAudio2VoiceCallback) -{ - STDMETHOD_(void, OnVoiceProcessingPassStart) (THIS_ UINT32 BytesRequired) PURE; - STDMETHOD_(void, OnVoiceProcessingPassEnd) (THIS) PURE; - STDMETHOD_(void, OnStreamEnd) (THIS) PURE; - STDMETHOD_(void, OnBufferStart) (THIS_ void *pBufferContext) PURE; - STDMETHOD_(void, OnBufferEnd) (THIS_ void *pBufferContext) PURE; - STDMETHOD_(void, OnLoopEnd) (THIS_ void *pBufferContext) PURE; - STDMETHOD_(void, OnVoiceError) (THIS_ void *pBufferContext, HRESULT Error) PURE; -}; - -#undef INTERFACE -#define INTERFACE IXAudio2Voice - -DECLARE_INTERFACE(IXAudio2Voice) -{ -#define Declare_IXAudio2Voice_Methods() \ - STDMETHOD_(void, GetVoiceDetails) (THIS_ XAUDIO2_VOICE_DETAILS* pVoiceDetails) PURE; \ - STDMETHOD(SetOutputVoices) (THIS_ const XAUDIO2_VOICE_SENDS* pSendList) PURE; \ - STDMETHOD(SetEffectChain) (THIS_ const XAUDIO2_EFFECT_CHAIN* pEffectChain) PURE; \ - STDMETHOD(EnableEffect) (THIS_ UINT32 EffectIndex, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD(DisableEffect) (THIS_ UINT32 EffectIndex, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetEffectState) (THIS_ UINT32 EffectIndex, BOOL* pEnabled) PURE; \ - STDMETHOD(SetEffectParameters) (THIS_ UINT32 EffectIndex, \ - const void *pParameters, \ - UINT32 ParametersByteSize, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD(GetEffectParameters) (THIS_ UINT32 EffectIndex, void *pParameters, \ - UINT32 ParametersByteSize) PURE; \ - STDMETHOD(SetFilterParameters) (THIS_ const XAUDIO2_FILTER_PARAMETERS* pParameters, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetFilterParameters) (THIS_ XAUDIO2_FILTER_PARAMETERS* pParameters) PURE; \ - STDMETHOD_(void, SetOutputFilterParameters) (THIS_ IXAudio2Voice *voice, const XAUDIO2_FILTER_PARAMETERS* param, \ - UINT32 op X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetOutputFilterParameters) (THIS_ IXAudio2Voice *voice, XAUDIO2_FILTER_PARAMETERS* param) PURE; \ - STDMETHOD(SetVolume) (THIS_ float Volume, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetVolume) (THIS_ float* pVolume) PURE; \ - STDMETHOD(SetChannelVolumes) (THIS_ UINT32 Channels, const float* pVolumes, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetChannelVolumes) (THIS_ UINT32 Channels, float* pVolumes) PURE; \ - STDMETHOD(SetOutputMatrix) (THIS_ IXAudio2Voice* pDestinationVoice, \ - UINT32 SourceChannels, UINT32 DestinationChannels, \ - const float* pLevelMatrix, \ - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ - STDMETHOD_(void, GetOutputMatrix) (THIS_ IXAudio2Voice* pDestinationVoice, \ - UINT32 SourceChannels, UINT32 DestinationChannels, \ - float* pLevelMatrix) PURE; \ - STDMETHOD_(void, DestroyVoice) (THIS) PURE - - Declare_IXAudio2Voice_Methods(); -}; - -#undef INTERFACE -#define INTERFACE IXAudio2MasteringVoice - -DECLARE_INTERFACE_(IXAudio2MasteringVoice, IXAudio2Voice) -{ - Declare_IXAudio2Voice_Methods(); -}; - -#undef INTERFACE -#define INTERFACE IXAudio2SourceVoice - -DECLARE_INTERFACE_(IXAudio2SourceVoice, IXAudio2Voice) -{ - Declare_IXAudio2Voice_Methods(); - STDMETHOD(Start) (THIS_ UINT32 Flags, UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; - STDMETHOD(Stop) (THIS_ UINT32 Flags, UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; - STDMETHOD(SubmitSourceBuffer) (THIS_ const XAUDIO2_BUFFER* pBuffer, const XAUDIO2_BUFFER_WMA* pBufferWMA X2DEFAULT(NULL)) PURE; - STDMETHOD(FlushSourceBuffers) (THIS) PURE; - STDMETHOD(Discontinuity) (THIS) PURE; - STDMETHOD(ExitLoop) (THIS_ UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; - STDMETHOD_(void, GetState) (THIS_ XAUDIO2_VOICE_STATE* pVoiceState) PURE; - STDMETHOD(SetFrequencyRatio) (THIS_ float Ratio, - UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; - STDMETHOD_(void, GetFrequencyRatio) (THIS_ float* pRatio) PURE; -}; - -#undef INTERFACE -#define INTERFACE IXAudio2 - -DECLARE_INTERFACE_(IXAudio2, IUnknown) -{ - STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvInterface) PURE; - STDMETHOD_(ULONG, AddRef) (THIS) PURE; - STDMETHOD_(ULONG, Release) (THIS) PURE; - STDMETHOD(GetDeviceCount) (THIS_ UINT32* pCount) PURE; - STDMETHOD(GetDeviceDetails) (THIS_ UINT32 Index, XAUDIO2_DEVICE_DETAILS* pDeviceDetails) PURE; - STDMETHOD(Initialize) (THIS_ UINT32 Flags X2DEFAULT(0), - XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)) PURE; - STDMETHOD(RegisterForCallbacks) (IXAudio2EngineCallback* pCallback) PURE; - STDMETHOD_(void, UnregisterForCallbacks) (IXAudio2EngineCallback* pCallback) PURE; - STDMETHOD(CreateSourceVoice) (THIS_ IXAudio2SourceVoice** ppSourceVoice, - const WAVEFORMATEX* pSourceFormat, - UINT32 Flags X2DEFAULT(0), - float MaxFrequencyRatio X2DEFAULT(XAUDIO2_DEFAULT_FREQ_RATIO), - IXAudio2VoiceCallback* pCallback X2DEFAULT(NULL), - const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), - const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; - STDMETHOD(CreateSubmixVoice) (THIS_ IXAudio2SubmixVoice** ppSubmixVoice, - UINT32 InputChannels, UINT32 InputSampleRate, - UINT32 Flags X2DEFAULT(0), UINT32 ProcessingStage X2DEFAULT(0), - const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), - const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; - STDMETHOD(CreateMasteringVoice) (THIS_ IXAudio2MasteringVoice** ppMasteringVoice, - UINT32 InputChannels X2DEFAULT(XAUDIO2_DEFAULT_CHANNELS), - UINT32 InputSampleRate X2DEFAULT(XAUDIO2_DEFAULT_SAMPLERATE), - UINT32 Flags X2DEFAULT(0), UINT32 DeviceIndex X2DEFAULT(0), - const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; - STDMETHOD(StartEngine) (THIS) PURE; - STDMETHOD_(void, StopEngine) (THIS) PURE; - STDMETHOD(CommitChanges) (THIS_ UINT32 OperationSet) PURE; - STDMETHOD_(void, GetPerformanceData) (THIS_ XAUDIO2_PERFORMANCE_DATA* pPerfData) PURE; - STDMETHOD_(void, SetDebugConfiguration) (THIS_ const XAUDIO2_DEBUG_CONFIGURATION* pDebugConfiguration, - void *pReserved X2DEFAULT(NULL)) PURE; -}; - -#if defined(__cplusplus) && !defined(CINTERFACE) -/* C++ hooks */ -#define IXAudio2_Initialize(handle,a,b) handle->Initialize(a, b) -#define IXAudio2SourceVoice_SubmitSourceBuffer(handle, a, b) handle->SubmitSourceBuffer(a, b) -#define IXAudio2SourceVoice_Stop(handle, a, b) handle->Stop(a, b) -#define IXAudio2SourceVoice_DestroyVoice(handle) handle->DestroyVoice() -#define IXAudio2MasteringVoice_DestroyVoice(handle) handle->DestroyVoice() -#define IXAudio2_Release(handle) handle->Release() -#define IXAudio2_CreateSourceVoice(handle, a, b, c, d, e, f, g) handle->CreateSourceVoice(a, b, c, d, e, f, g) -#define IXAudio2_CreateMasteringVoice(handle, a, b, c, d, e, f) handle->CreateMasteringVoice(a, b, c, d, e, f) -#define IXAudio2SourceVoice_Start(handle, a, b) handle->Start(a, b) -#else -/* C hooks */ -#define IXAudio2_Initialize(handle,a,b) (handle)->lpVtbl->Initialize(handle, a, b) -#define IXAudio2_Release(handle) (handle)->lpVtbl->Release(handle) -#define IXAudio2_CreateSourceVoice(handle,ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain) (handle)->lpVtbl->CreateSourceVoice(handle, ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain) -#define IXAudio2_CreateMasteringVoice(handle,ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceIndex,pEffectChain) (handle)->lpVtbl->CreateMasteringVoice(handle, ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceIndex,pEffectChain) -#define IXAudio2_GetDeviceCount(handle, puCount) (handle)->lpVtbl->GetDeviceCount(handle, puCount) -#define IXAudio2_GetDeviceDetails(handle, Index,pDeviceDetails) (handle)->lpVtbl->GetDeviceDetails(handle, Index, pDeviceDetails) -#define IXAudio2SourceVoice_Start(handle, Flags, OperationSet) (handle)->lpVtbl->Start(handle, Flags, OperationSet) -#define IXAudio2SourceVoice_Stop(handle, Flags, OperationSet) (handle)->lpVtbl->Stop(handle, Flags, OperationSet) -#define IXAudio2SourceVoice_SubmitSourceBuffer(handle, pBuffer, pBufferWMA) (handle)->lpVtbl->SubmitSourceBuffer(handle, pBuffer, pBufferWMA) -#define IXAudio2SourceVoice_DestroyVoice(handle) (handle)->lpVtbl->DestroyVoice(handle) -#define IXAudio2MasteringVoice_DestroyVoice(handle) (handle)->lpVtbl->DestroyVoice(handle) -#endif - -#ifdef _XBOX -STDAPI XAudio2Create(__deref_out IXAudio2** ppXAudio2, UINT32 Flags X2DEFAULT(0), - XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)); -#else -static INLINE HRESULT XAudio2Create(IXAudio2 **ppXAudio2, UINT32 flags, XAUDIO2_PROCESSOR proc) -{ - IXAudio2 *pXAudio2 = NULL; -#ifdef __cplusplus - HRESULT hr = CoCreateInstance(CLSID_XAudio2, NULL, CLSCTX_INPROC_SERVER, IID_IXAudio2, (void**)&pXAudio2); -#else - HRESULT hr = CoCreateInstance(&CLSID_XAudio2, NULL, CLSCTX_INPROC_SERVER, &IID_IXAudio2, (void**)&pXAudio2); -#endif - - if (SUCCEEDED(hr)) - { - hr = IXAudio2_Initialize(pXAudio2, 0, XAUDIO2_DEFAULT_PROCESSOR); - if (SUCCEEDED(hr)) - *ppXAudio2 = pXAudio2; - else - IXAudio2_Release(pXAudio2); - } - return hr; -} -#endif - -/* Undo the #pragma pack(push, 1) directive at the top of this file */ -#pragma pack(pop) - -#endif - diff --git a/audio/drivers/xaudio27.h b/audio/drivers/xaudio27.h new file mode 100644 index 0000000000..4b85b3b56e --- /dev/null +++ b/audio/drivers/xaudio27.h @@ -0,0 +1,363 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2014 - Hans-Kristian Arntzen + * Copyright (C) 2011-2017 - Daniel De Matteis + * Copyright (C) 2010-2014 - OV2 + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +/* Kinda stripped down. Only contains the bare essentials used in RetroArch. */ + +#ifndef XAUDIO2_STRIPPED_H +#define XAUDIO2_STRIPPED_H + +#include +#include + +/* All structures defined in this file use tight field packing */ +#pragma pack(push, 1) + +#if defined(__cplusplus) && !defined(CINTERFACE) +#define X2DEFAULT(x) = (x) +#else +#define X2DEFAULT(x) +#endif + +#ifdef _XBOX +#include + +#ifndef __cplusplus +#define OPAQUE interface +#endif +#define DEFINE_CLSID(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) +#define DEFINE_IID(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) + +DEFINE_CLSID(XAudio2, 3eda9b49, 2085, 498b, 9b, b2, 39, a6, 77, 84, 93, de); +DEFINE_CLSID(XAudio2_Debug, 47199894, 7cc2, 444d, 98, 73, ce, d2, 56, 2c, c6, 0e); +DEFINE_IID(IXAudio2, 8bcf1f58, 9fe7, 4583, 8a, c6, e2, ad, c4, 65, c8, bb); + +#include /* Basic audio data types and constants */ + +#else + +#define WIN32_LEAN_AND_MEAN +#include +#include +#include +#include + +#ifndef __cplusplus +#undef OPAQUE +#define OPAQUE struct +#endif + +#define DEFINE_GUID_X(n, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + static const GUID n = { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } } +#define DEFINE_CLSID_X(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID_X(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) +#define DEFINE_IID_X(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID_X(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) + +#ifndef __cplusplus +#ifndef INTERFACE +#define INTERFACE void +#endif +#endif + +DEFINE_CLSID_X(XAudio2, 5a508685, a254, 4fba, 9b, 82, 9a, 24, b0, 03, 06, af); /* 2.7 */ +DEFINE_IID_X(IXAudio2, 8bcf1f58, 9fe7, 4583, 8a, c6, e2, ad, c4, 65, c8, bb); + +#endif + +#ifdef _XBOX +#define XAUDIO2_DEFAULT_FREQ_RATIO 2.0f +#else +#define XAUDIO2_DEFAULT_FREQ_RATIO 4.0f +#endif + +#define XAUDIO2_COMMIT_NOW 0 +#define XAUDIO2_DEFAULT_CHANNELS 0 +#define XAUDIO2_DEFAULT_SAMPLERATE 0 + +#define XAUDIO2_DEBUG_ENGINE 0x0001 +#define XAUDIO2_VOICE_NOSRC 0x0004 + +typedef enum XAUDIO2_DEVICE_ROLE +{ + NotDefaultDevice = 0x0, + DefaultConsoleDevice = 0x1, + DefaultMultimediaDevice = 0x2, + DefaultCommunicationsDevice = 0x4, + DefaultGameDevice = 0x8, + GlobalDefaultDevice = 0xf, + InvalidDeviceRole = ~GlobalDefaultDevice +} XAUDIO2_DEVICE_ROLE; + +#ifdef _XBOX +typedef enum XAUDIO2_XBOX_HWTHREAD_SPECIFIER +{ + XboxThread0 = 0x01, + XboxThread1 = 0x02, + XboxThread2 = 0x04, + XboxThread3 = 0x08, + XboxThread4 = 0x10, + XboxThread5 = 0x20, + XAUDIO2_ANY_PROCESSOR = XboxThread4, + XAUDIO2_DEFAULT_PROCESSOR = XAUDIO2_ANY_PROCESSOR +} XAUDIO2_XBOX_HWTHREAD_SPECIFIER, XAUDIO2_PROCESSOR; +#else +typedef enum XAUDIO2_WINDOWS_PROCESSOR_SPECIFIER +{ +#if defined(__STDC_C89__) + XAUDIO2_ANY_PROCESSOR = 0xffff, +#else + XAUDIO2_ANY_PROCESSOR = 0xffffffff, +#endif + XAUDIO2_DEFAULT_PROCESSOR = XAUDIO2_ANY_PROCESSOR +} XAUDIO2_WINDOWS_PROCESSOR_SPECIFIER, XAUDIO2_PROCESSOR; +#endif + +typedef enum XAUDIO2_FILTER_TYPE { + LowPassFilter, + BandPassFilter, + HighPassFilter +} XAUDIO2_FILTER_TYPE; + +typedef struct XAUDIO2_DEVICE_DETAILS +{ + WCHAR DeviceID[256]; + WCHAR DisplayName[256]; + XAUDIO2_DEVICE_ROLE Role; + WAVEFORMATEXTENSIBLE OutputFormat; +} XAUDIO2_DEVICE_DETAILS; + +/* Forward declarations. */ +#ifdef __cplusplus +struct XAUDIO2_VOICE_DETAILS; +struct XAUDIO2_VOICE_SENDS; +struct XAUDIO2_EFFECT_DESCRIPTOR; +struct XAUDIO2_EFFECT_CHAIN; +struct XAUDIO2_FILTER_PARAMETERS; +struct XAUDIO2_BUFFER_WMA; +struct XAUDIO2_VOICE_STATE; +struct XAUDIO2_PERFORMANCE_DATA; +struct XAUDIO2_DEBUG_CONFIGURATION; +struct IXAudio2EngineCallback; +struct IXAudio2SubmixVoice; +#else +typedef OPAQUE XAUDIO2_VOICE_DETAILS XAUDIO2_VOICE_DETAILS; +typedef OPAQUE XAUDIO2_VOICE_SENDS XAUDIO2_VOICE_SENDS; +typedef OPAQUE XAUDIO2_EFFECT_DESCRIPTOR XAUDIO2_EFFECT_DESCRIPTOR; +typedef OPAQUE XAUDIO2_EFFECT_CHAIN XAUDIO2_EFFECT_CHAIN; +typedef OPAQUE XAUDIO2_FILTER_PARAMETERS XAUDIO2_FILTER_PARAMETERS; +typedef OPAQUE XAUDIO2_BUFFER_WMA XAUDIO2_BUFFER_WMA; +typedef OPAQUE XAUDIO2_VOICE_STATE XAUDIO2_VOICE_STATE; +typedef OPAQUE XAUDIO2_PERFORMANCE_DATA XAUDIO2_PERFORMANCE_DATA; +typedef OPAQUE XAUDIO2_DEBUG_CONFIGURATION XAUDIO2_DEBUG_CONFIGURATION; +typedef OPAQUE IXAudio2EngineCallback IXAudio2EngineCallback; +typedef OPAQUE IXAudio2SubmixVoice IXAudio2SubmixVoice; +#endif + +typedef struct XAUDIO2_BUFFER +{ + UINT32 Flags; + UINT32 AudioBytes; + const BYTE* pAudioData; + UINT32 PlayBegin; + UINT32 PlayLength; + UINT32 LoopBegin; + UINT32 LoopLength; + UINT32 LoopCount; + void *pContext; +} XAUDIO2_BUFFER; + +#undef INTERFACE +#define INTERFACE IXAudio2VoiceCallback + +DECLARE_INTERFACE(IXAudio2VoiceCallback) +{ + STDMETHOD_(void, OnVoiceProcessingPassStart) (THIS_ UINT32 BytesRequired) PURE; + STDMETHOD_(void, OnVoiceProcessingPassEnd) (THIS) PURE; + STDMETHOD_(void, OnStreamEnd) (THIS) PURE; + STDMETHOD_(void, OnBufferStart) (THIS_ void *pBufferContext) PURE; + STDMETHOD_(void, OnBufferEnd) (THIS_ void *pBufferContext) PURE; + STDMETHOD_(void, OnLoopEnd) (THIS_ void *pBufferContext) PURE; + STDMETHOD_(void, OnVoiceError) (THIS_ void *pBufferContext, HRESULT Error) PURE; +}; + +#undef INTERFACE +#define INTERFACE IXAudio2Voice + +DECLARE_INTERFACE(IXAudio2Voice) +{ +#define Declare_IXAudio2Voice_Methods() \ + STDMETHOD_(void, GetVoiceDetails) (THIS_ XAUDIO2_VOICE_DETAILS* pVoiceDetails) PURE; \ + STDMETHOD(SetOutputVoices) (THIS_ const XAUDIO2_VOICE_SENDS* pSendList) PURE; \ + STDMETHOD(SetEffectChain) (THIS_ const XAUDIO2_EFFECT_CHAIN* pEffectChain) PURE; \ + STDMETHOD(EnableEffect) (THIS_ UINT32 EffectIndex, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD(DisableEffect) (THIS_ UINT32 EffectIndex, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetEffectState) (THIS_ UINT32 EffectIndex, BOOL* pEnabled) PURE; \ + STDMETHOD(SetEffectParameters) (THIS_ UINT32 EffectIndex, \ + const void *pParameters, \ + UINT32 ParametersByteSize, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD(GetEffectParameters) (THIS_ UINT32 EffectIndex, void *pParameters, \ + UINT32 ParametersByteSize) PURE; \ + STDMETHOD(SetFilterParameters) (THIS_ const XAUDIO2_FILTER_PARAMETERS* pParameters, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetFilterParameters) (THIS_ XAUDIO2_FILTER_PARAMETERS* pParameters) PURE; \ + STDMETHOD_(void, SetOutputFilterParameters) (THIS_ IXAudio2Voice *voice, const XAUDIO2_FILTER_PARAMETERS* param, \ + UINT32 op X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetOutputFilterParameters) (THIS_ IXAudio2Voice *voice, XAUDIO2_FILTER_PARAMETERS* param) PURE; \ + STDMETHOD(SetVolume) (THIS_ float Volume, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetVolume) (THIS_ float* pVolume) PURE; \ + STDMETHOD(SetChannelVolumes) (THIS_ UINT32 Channels, const float* pVolumes, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetChannelVolumes) (THIS_ UINT32 Channels, float* pVolumes) PURE; \ + STDMETHOD(SetOutputMatrix) (THIS_ IXAudio2Voice* pDestinationVoice, \ + UINT32 SourceChannels, UINT32 DestinationChannels, \ + const float* pLevelMatrix, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + STDMETHOD_(void, GetOutputMatrix) (THIS_ IXAudio2Voice* pDestinationVoice, \ + UINT32 SourceChannels, UINT32 DestinationChannels, \ + float* pLevelMatrix) PURE; \ + STDMETHOD_(void, DestroyVoice) (THIS) PURE + + Declare_IXAudio2Voice_Methods(); +}; + +#undef INTERFACE +#define INTERFACE IXAudio2MasteringVoice + +DECLARE_INTERFACE_(IXAudio2MasteringVoice, IXAudio2Voice) +{ + Declare_IXAudio2Voice_Methods(); +}; + +#undef INTERFACE +#define INTERFACE IXAudio2SourceVoice + +DECLARE_INTERFACE_(IXAudio2SourceVoice, IXAudio2Voice) +{ + Declare_IXAudio2Voice_Methods(); + STDMETHOD(Start) (THIS_ UINT32 Flags, UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + STDMETHOD(Stop) (THIS_ UINT32 Flags, UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + STDMETHOD(SubmitSourceBuffer) (THIS_ const XAUDIO2_BUFFER* pBuffer, const XAUDIO2_BUFFER_WMA* pBufferWMA X2DEFAULT(NULL)) PURE; + STDMETHOD(FlushSourceBuffers) (THIS) PURE; + STDMETHOD(Discontinuity) (THIS) PURE; + STDMETHOD(ExitLoop) (THIS_ UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + STDMETHOD_(void, GetState) (THIS_ XAUDIO2_VOICE_STATE* pVoiceState) PURE; + STDMETHOD(SetFrequencyRatio) (THIS_ float Ratio, + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + STDMETHOD_(void, GetFrequencyRatio) (THIS_ float* pRatio) PURE; +}; + +#undef INTERFACE +#define INTERFACE IXAudio2 + +DECLARE_INTERFACE_(IXAudio2, IUnknown) +{ + STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvInterface) PURE; + STDMETHOD_(ULONG, AddRef) (THIS) PURE; + STDMETHOD_(ULONG, Release) (THIS) PURE; + STDMETHOD(GetDeviceCount) (THIS_ UINT32* pCount) PURE; + STDMETHOD(GetDeviceDetails) (THIS_ UINT32 Index, XAUDIO2_DEVICE_DETAILS* pDeviceDetails) PURE; + STDMETHOD(Initialize) (THIS_ UINT32 Flags X2DEFAULT(0), + XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)) PURE; + STDMETHOD(RegisterForCallbacks) (IXAudio2EngineCallback* pCallback) PURE; + STDMETHOD_(void, UnregisterForCallbacks) (IXAudio2EngineCallback* pCallback) PURE; + STDMETHOD(CreateSourceVoice) (THIS_ IXAudio2SourceVoice** ppSourceVoice, + const WAVEFORMATEX* pSourceFormat, + UINT32 Flags X2DEFAULT(0), + float MaxFrequencyRatio X2DEFAULT(XAUDIO2_DEFAULT_FREQ_RATIO), + IXAudio2VoiceCallback* pCallback X2DEFAULT(NULL), + const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), + const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; + STDMETHOD(CreateSubmixVoice) (THIS_ IXAudio2SubmixVoice** ppSubmixVoice, + UINT32 InputChannels, UINT32 InputSampleRate, + UINT32 Flags X2DEFAULT(0), UINT32 ProcessingStage X2DEFAULT(0), + const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), + const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; + STDMETHOD(CreateMasteringVoice) (THIS_ IXAudio2MasteringVoice** ppMasteringVoice, + UINT32 InputChannels X2DEFAULT(XAUDIO2_DEFAULT_CHANNELS), + UINT32 InputSampleRate X2DEFAULT(XAUDIO2_DEFAULT_SAMPLERATE), + UINT32 Flags X2DEFAULT(0), UINT32 DeviceIndex X2DEFAULT(0), + const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; + STDMETHOD(StartEngine) (THIS) PURE; + STDMETHOD_(void, StopEngine) (THIS) PURE; + STDMETHOD(CommitChanges) (THIS_ UINT32 OperationSet) PURE; + STDMETHOD_(void, GetPerformanceData) (THIS_ XAUDIO2_PERFORMANCE_DATA* pPerfData) PURE; + STDMETHOD_(void, SetDebugConfiguration) (THIS_ const XAUDIO2_DEBUG_CONFIGURATION* pDebugConfiguration, + void *pReserved X2DEFAULT(NULL)) PURE; +}; + +#if defined(__cplusplus) && !defined(CINTERFACE) +/* C++ hooks */ +#define IXAudio2_Initialize(handle,a,b) handle->Initialize(a, b) +#define IXAudio2SourceVoice_SubmitSourceBuffer(handle, a, b) handle->SubmitSourceBuffer(a, b) +#define IXAudio2SourceVoice_Stop(handle, a, b) handle->Stop(a, b) +#define IXAudio2SourceVoice_DestroyVoice(handle) handle->DestroyVoice() +#define IXAudio2MasteringVoice_DestroyVoice(handle) handle->DestroyVoice() +#define IXAudio2_Release(handle) handle->Release() +#define IXAudio2_CreateSourceVoice(handle, a, b, c, d, e, f, g) handle->CreateSourceVoice(a, b, c, d, e, f, g) +#define IXAudio2_CreateMasteringVoice(handle, a, b, c, d, e, f) handle->CreateMasteringVoice(a, b, c, d, e, f) +#define IXAudio2SourceVoice_Start(handle, a, b) handle->Start(a, b) +#else +/* C hooks */ +#define IXAudio2_Initialize(handle,a,b) (handle)->lpVtbl->Initialize(handle, a, b) +#define IXAudio2_Release(handle) (handle)->lpVtbl->Release(handle) +#define IXAudio2_CreateSourceVoice(handle,ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain) (handle)->lpVtbl->CreateSourceVoice(handle, ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain) +#define IXAudio2_CreateMasteringVoice(handle,ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceIndex,pEffectChain) (handle)->lpVtbl->CreateMasteringVoice(handle, ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceIndex,pEffectChain) +#define IXAudio2_GetDeviceCount(handle, puCount) (handle)->lpVtbl->GetDeviceCount(handle, puCount) +#define IXAudio2_GetDeviceDetails(handle, Index,pDeviceDetails) (handle)->lpVtbl->GetDeviceDetails(handle, Index, pDeviceDetails) +#define IXAudio2SourceVoice_Start(handle, Flags, OperationSet) (handle)->lpVtbl->Start(handle, Flags, OperationSet) +#define IXAudio2SourceVoice_Stop(handle, Flags, OperationSet) (handle)->lpVtbl->Stop(handle, Flags, OperationSet) +#define IXAudio2SourceVoice_SubmitSourceBuffer(handle, pBuffer, pBufferWMA) (handle)->lpVtbl->SubmitSourceBuffer(handle, pBuffer, pBufferWMA) +#define IXAudio2SourceVoice_DestroyVoice(handle) (handle)->lpVtbl->DestroyVoice(handle) +#define IXAudio2MasteringVoice_DestroyVoice(handle) (handle)->lpVtbl->DestroyVoice(handle) +#endif + +#ifdef _XBOX +STDAPI XAudio2Create(__deref_out IXAudio2** ppXAudio2, UINT32 Flags X2DEFAULT(0), + XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)); +#else +static INLINE HRESULT XAudio2Create(IXAudio2 **ppXAudio2, UINT32 flags, XAUDIO2_PROCESSOR proc) +{ + IXAudio2 *pXAudio2 = NULL; +#ifdef __cplusplus + HRESULT hr = CoCreateInstance(CLSID_XAudio2, NULL, CLSCTX_INPROC_SERVER, IID_IXAudio2, (void**)&pXAudio2); +#else + HRESULT hr = CoCreateInstance(&CLSID_XAudio2, NULL, CLSCTX_INPROC_SERVER, &IID_IXAudio2, (void**)&pXAudio2); +#endif + + if (SUCCEEDED(hr)) + { + hr = IXAudio2_Initialize(pXAudio2, 0, XAUDIO2_DEFAULT_PROCESSOR); + if (SUCCEEDED(hr)) + *ppXAudio2 = pXAudio2; + else + IXAudio2_Release(pXAudio2); + } + return hr; +} +#endif + +/* Undo the #pragma pack(push, 1) directive at the top of this file */ +#pragma pack(pop) + +#endif + diff --git a/audio/drivers/xaudio29.h b/audio/drivers/xaudio29.h new file mode 100644 index 0000000000..46f5d616ca --- /dev/null +++ b/audio/drivers/xaudio29.h @@ -0,0 +1,1306 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2018 - Krzysztof Haładyn + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + + /************************************************************************** + * + * Copyright (c) Microsoft Corporation. All rights reserved. + * + * File: xaudio2.h + * Content: Declarations for the XAudio2 game audio API. + * + **************************************************************************/ + + /* Modified slightly to build without requiring the WinRT compiler since that is only available in C++ sources */ + +#ifdef _MSC_VER +#pragma once +#endif + +#ifndef __XAUDIO2_INCLUDED__ +#define __XAUDIO2_INCLUDED__ + +#include + +#include + +#if(_WIN32_WINNT < _WIN32_WINNT_WIN8) +#error "This version of XAudio2 is available only in Windows 8 or later. Use the XAudio2 headers and libraries from the DirectX SDK with applications that target Windows 7 and earlier versions." +#endif // (_WIN32_WINNT < _WIN32_WINNT_WIN8) + +#include + +#pragma region Application Family +#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP | WINAPI_PARTITION_TV_APP | WINAPI_PARTITION_TV_TITLE) + +// Current name of the DLL shipped in the same SDK as this header. +// The name reflects the current version +#if(_WIN32_WINNT >= _WIN32_WINNT_WIN10) +#define XAUDIO2_DLL_A "xaudio2_9.dll" +#define XAUDIO2_DLL_W L"xaudio2_9.dll" +#define XAUDIO2D_DLL_A "xaudio2_9d.dll" +#define XAUDIO2D_DLL_W L"xaudio2_9d.dll" +#else +#define XAUDIO2_DLL_A "xaudio2_8.dll" +#define XAUDIO2_DLL_W L"xaudio2_8.dll" +#define XAUDIO2D_DLL_A "xaudio2_8.dll" +#define XAUDIO2D_DLL_W L"xaudio2_8.dll" +#endif + +#ifdef UNICODE +#define XAUDIO2_DLL XAUDIO2_DLL_W +#define XAUDIO2D_DLL XAUDIO2D_DLL_W +#else +#define XAUDIO2_DLL XAUDIO2_DLL_A +#define XAUDIO2D_DLL XAUDIO2D_DLL_A +#endif + + +/************************************************************************** + * + * XAudio2 COM object class and interface IDs. + * + **************************************************************************/ + +#include + +#if defined(__cplusplus__) && defined(__WINRT__) + +#if(_WIN32_WINNT >= _WIN32_WINNT_WIN10) + // XAudio 2.9 +interface __declspec(uuid("2B02E3CF-2E0B-4ec3-BE45-1B2A3FE7210D")) IXAudio2; +#else + // XAudio 2.8 +interface __declspec(uuid("60d8dac8-5aa1-4e8e-b597-2f5e2883d484")) IXAudio2; +#endif + +#else + + /* Modified for C support */ +#define DEFINE_GUID_X(n, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + static const GUID n = { l, w1, w2, { b1, b2, b3, b4, b5, b6, b7, b8 } } +#define DEFINE_CLSID_X(className, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID_X(CLSID_##className, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) +#define DEFINE_IID_X(interfaceName, l, w1, w2, b1, b2, b3, b4, b5, b6, b7, b8) \ + DEFINE_GUID_X(IID_##interfaceName, 0x##l, 0x##w1, 0x##w2, 0x##b1, 0x##b2, 0x##b3, 0x##b4, 0x##b5, 0x##b6, 0x##b7, 0x##b8) + +#if(_WIN32_WINNT >= _WIN32_WINNT_WIN10) +DEFINE_IID_X(IXAudio2, 2B02E3CF, 2E0B, 4ec3, BE, 45, 1B, 2A, 3F, E7, 21, 0D); +#else +DEFINE_IID_X(IXAudio2, 60d8dac8, 5aa1, 4e8e, b5, 97, 2f, 5e, 28, 83, d4, 84); +#endif + +#endif + + +// Ignore the rest of this header if only the GUID definitions were requested +#ifndef GUID_DEFS_ONLY + +#include // Windows COM declarations +#include // Markers for documenting API semantics +#include // Basic data types and constants for audio work +#include // For AUDIO_STREAM_CATEGORY + +// All structures defined in this file use tight field packing +#pragma pack(push, 1) + + +/************************************************************************** + * + * XAudio2 constants, flags and error codes. + * + **************************************************************************/ + + // Numeric boundary values +#define XAUDIO2_MAX_BUFFER_BYTES 0x80000000 // Maximum bytes allowed in a source buffer +#define XAUDIO2_MAX_QUEUED_BUFFERS 64 // Maximum buffers allowed in a voice queue +#define XAUDIO2_MAX_BUFFERS_SYSTEM 2 // Maximum buffers allowed for system threads (Xbox 360 only) +#define XAUDIO2_MAX_AUDIO_CHANNELS 64 // Maximum channels in an audio stream +#define XAUDIO2_MIN_SAMPLE_RATE 1000 // Minimum audio sample rate supported +#define XAUDIO2_MAX_SAMPLE_RATE 200000 // Maximum audio sample rate supported +#define XAUDIO2_MAX_VOLUME_LEVEL 16777216.0f // Maximum acceptable volume level (2^24) +#define XAUDIO2_MIN_FREQ_RATIO (1/1024.0f) // Minimum SetFrequencyRatio argument +#define XAUDIO2_MAX_FREQ_RATIO 1024.0f // Maximum MaxFrequencyRatio argument +#define XAUDIO2_DEFAULT_FREQ_RATIO 2.0f // Default MaxFrequencyRatio argument +#define XAUDIO2_MAX_FILTER_ONEOVERQ 1.5f // Maximum XAUDIO2_FILTER_PARAMETERS.OneOverQ +#define XAUDIO2_MAX_FILTER_FREQUENCY 1.0f // Maximum XAUDIO2_FILTER_PARAMETERS.Frequency +#define XAUDIO2_MAX_LOOP_COUNT 254 // Maximum non-infinite XAUDIO2_BUFFER.LoopCount +#define XAUDIO2_MAX_INSTANCES 8 // Maximum simultaneous XAudio2 objects on Xbox 360 + +// For XMA voices on Xbox 360 there is an additional restriction on the MaxFrequencyRatio +// argument and the voice's sample rate: the product of these numbers cannot exceed 600000 +// for one-channel voices or 300000 for voices with more than one channel. +#define XAUDIO2_MAX_RATIO_TIMES_RATE_XMA_MONO 600000 +#define XAUDIO2_MAX_RATIO_TIMES_RATE_XMA_MULTICHANNEL 300000 + +// Numeric values with special meanings +#define XAUDIO2_COMMIT_NOW 0 // Used as an OperationSet argument +#define XAUDIO2_COMMIT_ALL 0 // Used in IXAudio2::CommitChanges +#define XAUDIO2_INVALID_OPSET (UINT32)(-1) // Not allowed for OperationSet arguments +#define XAUDIO2_NO_LOOP_REGION 0 // Used in XAUDIO2_BUFFER.LoopCount +#define XAUDIO2_LOOP_INFINITE 255 // Used in XAUDIO2_BUFFER.LoopCount +#define XAUDIO2_DEFAULT_CHANNELS 0 // Used in CreateMasteringVoice +#define XAUDIO2_DEFAULT_SAMPLERATE 0 // Used in CreateMasteringVoice + +// Flags +#define XAUDIO2_DEBUG_ENGINE 0x0001 // Used in XAudio2Create +#define XAUDIO2_VOICE_NOPITCH 0x0002 // Used in IXAudio2::CreateSourceVoice +#define XAUDIO2_VOICE_NOSRC 0x0004 // Used in IXAudio2::CreateSourceVoice +#define XAUDIO2_VOICE_USEFILTER 0x0008 // Used in IXAudio2::CreateSource/SubmixVoice +#define XAUDIO2_PLAY_TAILS 0x0020 // Used in IXAudio2SourceVoice::Stop +#define XAUDIO2_END_OF_STREAM 0x0040 // Used in XAUDIO2_BUFFER.Flags +#define XAUDIO2_SEND_USEFILTER 0x0080 // Used in XAUDIO2_SEND_DESCRIPTOR.Flags +#define XAUDIO2_VOICE_NOSAMPLESPLAYED 0x0100 // Used in IXAudio2SourceVoice::GetState +#define XAUDIO2_STOP_ENGINE_WHEN_IDLE 0x2000 // Used in XAudio2Create to force the engine to Stop when no source voices are Started, and Start when a voice is Started +#define XAUDIO2_1024_QUANTUM 0x8000 // Used in XAudio2Create to specify nondefault processing quantum of 21.33 ms (1024 samples at 48KHz) +#define XAUDIO2_NO_VIRTUAL_AUDIO_CLIENT 0x10000 // Used in CreateMasteringVoice to create a virtual audio client + +// Default parameters for the built-in filter +#define XAUDIO2_DEFAULT_FILTER_TYPE LowPassFilter +#define XAUDIO2_DEFAULT_FILTER_FREQUENCY XAUDIO2_MAX_FILTER_FREQUENCY +#define XAUDIO2_DEFAULT_FILTER_ONEOVERQ 1.0f + +// Internal XAudio2 constants +// The audio frame quantum can be calculated by reducing the fraction: +// SamplesPerAudioFrame / SamplesPerSecond +#define XAUDIO2_QUANTUM_NUMERATOR 1 // On Windows, XAudio2 processes audio +#define XAUDIO2_QUANTUM_DENOMINATOR 100 // in 10ms chunks (= 1/100 seconds) +#define XAUDIO2_QUANTUM_MS (1000.0f * XAUDIO2_QUANTUM_NUMERATOR / XAUDIO2_QUANTUM_DENOMINATOR) + +// XAudio2 error codes +#define FACILITY_XAUDIO2 0x896 +#define XAUDIO2_E_INVALID_CALL 0x88960001 // An API call or one of its arguments was illegal +#define XAUDIO2_E_XMA_DECODER_ERROR 0x88960002 // The XMA hardware suffered an unrecoverable error +#define XAUDIO2_E_XAPO_CREATION_FAILED 0x88960003 // XAudio2 failed to initialize an XAPO effect +#define XAUDIO2_E_DEVICE_INVALIDATED 0x88960004 // An audio device became unusable (unplugged, etc) + +/************************************************************************** + * + * Forward declarations for the XAudio2 interfaces. + * + **************************************************************************/ + +#ifdef __cplusplus +#define FWD_DECLARE(x) interface x +#else +#define FWD_DECLARE(x) typedef interface x x +#endif + +FWD_DECLARE(IXAudio2); +FWD_DECLARE(IXAudio2Voice); +FWD_DECLARE(IXAudio2SourceVoice); +FWD_DECLARE(IXAudio2SubmixVoice); +FWD_DECLARE(IXAudio2MasteringVoice); +FWD_DECLARE(IXAudio2EngineCallback); +FWD_DECLARE(IXAudio2VoiceCallback); + + +/************************************************************************** + * + * XAudio2 structures and enumerations. + * + **************************************************************************/ + + // Used in XAudio2Create, specifies which CPU(s) to use. +typedef UINT32 XAUDIO2_PROCESSOR; +#define Processor1 0x00000001 +#define Processor2 0x00000002 +#define Processor3 0x00000004 +#define Processor4 0x00000008 +#define Processor5 0x00000010 +#define Processor6 0x00000020 +#define Processor7 0x00000040 +#define Processor8 0x00000080 +#define Processor9 0x00000100 +#define Processor10 0x00000200 +#define Processor11 0x00000400 +#define Processor12 0x00000800 +#define Processor13 0x00001000 +#define Processor14 0x00002000 +#define Processor15 0x00004000 +#define Processor16 0x00008000 +#define Processor17 0x00010000 +#define Processor18 0x00020000 +#define Processor19 0x00040000 +#define Processor20 0x00080000 +#define Processor21 0x00100000 +#define Processor22 0x00200000 +#define Processor23 0x00400000 +#define Processor24 0x00800000 +#define Processor25 0x01000000 +#define Processor26 0x02000000 +#define Processor27 0x04000000 +#define Processor28 0x08000000 +#define Processor29 0x10000000 +#define Processor30 0x20000000 +#define Processor31 0x40000000 +#define Processor32 0x80000000 +#define XAUDIO2_ANY_PROCESSOR 0xffffffff +#define XAUDIO2_DEFAULT_PROCESSOR Processor1 + +// Returned by IXAudio2Voice::GetVoiceDetails +typedef struct XAUDIO2_VOICE_DETAILS +{ + UINT32 CreationFlags; // Flags the voice was created with. + UINT32 ActiveFlags; // Flags currently active. + UINT32 InputChannels; // Channels in the voice's input audio. + UINT32 InputSampleRate; // Sample rate of the voice's input audio. +} XAUDIO2_VOICE_DETAILS; + +// Used in XAUDIO2_VOICE_SENDS below +typedef struct XAUDIO2_SEND_DESCRIPTOR +{ + UINT32 Flags; // Either 0 or XAUDIO2_SEND_USEFILTER. + IXAudio2Voice* pOutputVoice; // This send's destination voice. +} XAUDIO2_SEND_DESCRIPTOR; + +// Used in the voice creation functions and in IXAudio2Voice::SetOutputVoices +typedef struct XAUDIO2_VOICE_SENDS +{ + UINT32 SendCount; // Number of sends from this voice. + XAUDIO2_SEND_DESCRIPTOR* pSends; // Array of SendCount send descriptors. +} XAUDIO2_VOICE_SENDS; + +// Used in XAUDIO2_EFFECT_CHAIN below +typedef struct XAUDIO2_EFFECT_DESCRIPTOR +{ + IUnknown* pEffect; // Pointer to the effect object's IUnknown interface. + BOOL InitialState; // TRUE if the effect should begin in the enabled state. + UINT32 OutputChannels; // How many output channels the effect should produce. +} XAUDIO2_EFFECT_DESCRIPTOR; + +// Used in the voice creation functions and in IXAudio2Voice::SetEffectChain +typedef struct XAUDIO2_EFFECT_CHAIN +{ + UINT32 EffectCount; // Number of effects in this voice's effect chain. + XAUDIO2_EFFECT_DESCRIPTOR* pEffectDescriptors; // Array of effect descriptors. +} XAUDIO2_EFFECT_CHAIN; + +// Used in XAUDIO2_FILTER_PARAMETERS below +typedef enum XAUDIO2_FILTER_TYPE +{ + LowPassFilter, // Attenuates frequencies above the cutoff frequency (state-variable filter). + BandPassFilter, // Attenuates frequencies outside a given range (state-variable filter). + HighPassFilter, // Attenuates frequencies below the cutoff frequency (state-variable filter). + NotchFilter, // Attenuates frequencies inside a given range (state-variable filter). + LowPassOnePoleFilter, // Attenuates frequencies above the cutoff frequency (one-pole filter, XAUDIO2_FILTER_PARAMETERS.OneOverQ has no effect) + HighPassOnePoleFilter // Attenuates frequencies below the cutoff frequency (one-pole filter, XAUDIO2_FILTER_PARAMETERS.OneOverQ has no effect) +} XAUDIO2_FILTER_TYPE; + +// Used in IXAudio2Voice::Set/GetFilterParameters and Set/GetOutputFilterParameters +typedef struct XAUDIO2_FILTER_PARAMETERS +{ + XAUDIO2_FILTER_TYPE Type; // Filter type. + float Frequency; // Filter coefficient. + // must be >= 0 and <= XAUDIO2_MAX_FILTER_FREQUENCY + // See XAudio2CutoffFrequencyToRadians() for state-variable filter types and + // XAudio2CutoffFrequencyToOnePoleCoefficient() for one-pole filter types. + float OneOverQ; // Reciprocal of the filter's quality factor Q; + // must be > 0 and <= XAUDIO2_MAX_FILTER_ONEOVERQ. + // Has no effect for one-pole filters. +} XAUDIO2_FILTER_PARAMETERS; + +// Used in IXAudio2SourceVoice::SubmitSourceBuffer +typedef struct XAUDIO2_BUFFER +{ + UINT32 Flags; // Either 0 or XAUDIO2_END_OF_STREAM. + UINT32 AudioBytes; // Size of the audio data buffer in bytes. + const BYTE* pAudioData; // Pointer to the audio data buffer. + UINT32 PlayBegin; // First sample in this buffer to be played. + UINT32 PlayLength; // Length of the region to be played in samples, + // or 0 to play the whole buffer. + UINT32 LoopBegin; // First sample of the region to be looped. + UINT32 LoopLength; // Length of the desired loop region in samples, + // or 0 to loop the entire buffer. + UINT32 LoopCount; // Number of times to repeat the loop region, + // or XAUDIO2_LOOP_INFINITE to loop forever. + void* pContext; // Context value to be passed back in callbacks. +} XAUDIO2_BUFFER; + +// Used in IXAudio2SourceVoice::SubmitSourceBuffer when submitting XWMA data. +// NOTE: If an XWMA sound is submitted in more than one buffer, each buffer's +// pDecodedPacketCumulativeBytes[PacketCount-1] value must be subtracted from +// all the entries in the next buffer's pDecodedPacketCumulativeBytes array. +// And whether a sound is submitted in more than one buffer or not, the final +// buffer of the sound should use the XAUDIO2_END_OF_STREAM flag, or else the +// client must call IXAudio2SourceVoice::Discontinuity after submitting it. +typedef struct XAUDIO2_BUFFER_WMA +{ + const UINT32* pDecodedPacketCumulativeBytes; // Decoded packet's cumulative size array. + // Each element is the number of bytes accumulated + // when the corresponding XWMA packet is decoded in + // order. The array must have PacketCount elements. + UINT32 PacketCount; // Number of XWMA packets submitted. Must be >= 1 and + // divide evenly into XAUDIO2_BUFFER.AudioBytes. +} XAUDIO2_BUFFER_WMA; + +// Returned by IXAudio2SourceVoice::GetState +typedef struct XAUDIO2_VOICE_STATE +{ + void* pCurrentBufferContext; // The pContext value provided in the XAUDIO2_BUFFER + // that is currently being processed, or NULL if + // there are no buffers in the queue. + UINT32 BuffersQueued; // Number of buffers currently queued on the voice + // (including the one that is being processed). + UINT64 SamplesPlayed; // Total number of samples produced by the voice since + // it began processing the current audio stream. + // If XAUDIO2_VOICE_NOSAMPLESPLAYED is specified + // in the call to IXAudio2SourceVoice::GetState, + // this member will not be calculated, saving CPU. +} XAUDIO2_VOICE_STATE; + +// Returned by IXAudio2::GetPerformanceData +typedef struct XAUDIO2_PERFORMANCE_DATA +{ + // CPU usage information + UINT64 AudioCyclesSinceLastQuery; // CPU cycles spent on audio processing since the + // last call to StartEngine or GetPerformanceData. + UINT64 TotalCyclesSinceLastQuery; // Total CPU cycles elapsed since the last call + // (only counts the CPU XAudio2 is running on). + UINT32 MinimumCyclesPerQuantum; // Fewest CPU cycles spent processing any one + // audio quantum since the last call. + UINT32 MaximumCyclesPerQuantum; // Most CPU cycles spent processing any one + // audio quantum since the last call. + + // Memory usage information + UINT32 MemoryUsageInBytes; // Total heap space currently in use. + + // Audio latency and glitching information + UINT32 CurrentLatencyInSamples; // Minimum delay from when a sample is read from a + // source buffer to when it reaches the speakers. + UINT32 GlitchesSinceEngineStarted; // Audio dropouts since the engine was started. + + // Data about XAudio2's current workload + UINT32 ActiveSourceVoiceCount; // Source voices currently playing. + UINT32 TotalSourceVoiceCount; // Source voices currently existing. + UINT32 ActiveSubmixVoiceCount; // Submix voices currently playing/existing. + + UINT32 ActiveResamplerCount; // Resample xAPOs currently active. + UINT32 ActiveMatrixMixCount; // MatrixMix xAPOs currently active. + + // Usage of the hardware XMA decoder (Xbox 360 only) + UINT32 ActiveXmaSourceVoices; // Number of source voices decoding XMA data. + UINT32 ActiveXmaStreams; // A voice can use more than one XMA stream. +} XAUDIO2_PERFORMANCE_DATA; + +// Used in IXAudio2::SetDebugConfiguration +typedef struct XAUDIO2_DEBUG_CONFIGURATION +{ + UINT32 TraceMask; // Bitmap of enabled debug message types. + UINT32 BreakMask; // Message types that will break into the debugger. + BOOL LogThreadID; // Whether to log the thread ID with each message. + BOOL LogFileline; // Whether to log the source file and line number. + BOOL LogFunctionName; // Whether to log the function name. + BOOL LogTiming; // Whether to log message timestamps. +} XAUDIO2_DEBUG_CONFIGURATION; + +// Values for the TraceMask and BreakMask bitmaps. Only ERRORS and WARNINGS +// are valid in BreakMask. WARNINGS implies ERRORS, DETAIL implies INFO, and +// FUNC_CALLS implies API_CALLS. By default, TraceMask is ERRORS and WARNINGS +// and all the other settings are zero. +#define XAUDIO2_LOG_ERRORS 0x0001 // For handled errors with serious effects. +#define XAUDIO2_LOG_WARNINGS 0x0002 // For handled errors that may be recoverable. +#define XAUDIO2_LOG_INFO 0x0004 // Informational chit-chat (e.g. state changes). +#define XAUDIO2_LOG_DETAIL 0x0008 // More detailed chit-chat. +#define XAUDIO2_LOG_API_CALLS 0x0010 // Public API function entries and exits. +#define XAUDIO2_LOG_FUNC_CALLS 0x0020 // Internal function entries and exits. +#define XAUDIO2_LOG_TIMING 0x0040 // Delays detected and other timing data. +#define XAUDIO2_LOG_LOCKS 0x0080 // Usage of critical sections and mutexes. +#define XAUDIO2_LOG_MEMORY 0x0100 // Memory heap usage information. +#define XAUDIO2_LOG_STREAMING 0x1000 // Audio streaming information. + + +/************************************************************************** + * + * IXAudio2: Top-level XAudio2 COM interface. + * + **************************************************************************/ + + // Use default arguments if compiling as C++ +#ifdef __cplusplus +#define X2DEFAULT(x) =x +#else +#define X2DEFAULT(x) +#endif + +#undef INTERFACE +#define INTERFACE IXAudio2 +DECLARE_INTERFACE_(IXAudio2, IUnknown) +{ + // NAME: IXAudio2::QueryInterface + // DESCRIPTION: Queries for a given COM interface on the XAudio2 object. + // Only IID_IUnknown and IID_IXAudio2 are supported. + // + // ARGUMENTS: + // riid - IID of the interface to be obtained. + // ppvInterface - Returns a pointer to the requested interface. + // + STDMETHOD(QueryInterface) (THIS_ REFIID riid, _Outptr_ void** ppvInterface) PURE; + + // NAME: IXAudio2::AddRef + // DESCRIPTION: Adds a reference to the XAudio2 object. + // + STDMETHOD_(ULONG, AddRef) (THIS) PURE; + + // NAME: IXAudio2::Release + // DESCRIPTION: Releases a reference to the XAudio2 object. + // + STDMETHOD_(ULONG, Release) (THIS) PURE; + + // NAME: IXAudio2::RegisterForCallbacks + // DESCRIPTION: Adds a new client to receive XAudio2's engine callbacks. + // + // ARGUMENTS: + // pCallback - Callback interface to be called during each processing pass. + // + STDMETHOD(RegisterForCallbacks) (_In_ IXAudio2EngineCallback* pCallback) PURE; + + // NAME: IXAudio2::UnregisterForCallbacks + // DESCRIPTION: Removes an existing receiver of XAudio2 engine callbacks. + // + // ARGUMENTS: + // pCallback - Previously registered callback interface to be removed. + // + STDMETHOD_(void, UnregisterForCallbacks) (_In_ IXAudio2EngineCallback* pCallback) PURE; + + // NAME: IXAudio2::CreateSourceVoice + // DESCRIPTION: Creates and configures a source voice. + // + // ARGUMENTS: + // ppSourceVoice - Returns the new object's IXAudio2SourceVoice interface. + // pSourceFormat - Format of the audio that will be fed to the voice. + // Flags - XAUDIO2_VOICE flags specifying the source voice's behavior. + // MaxFrequencyRatio - Maximum SetFrequencyRatio argument to be allowed. + // pCallback - Optional pointer to a client-provided callback interface. + // pSendList - Optional list of voices this voice should send audio to. + // pEffectChain - Optional list of effects to apply to the audio data. + // + STDMETHOD(CreateSourceVoice) (THIS_ _Outptr_ IXAudio2SourceVoice** ppSourceVoice, + _In_ const WAVEFORMATEX* pSourceFormat, + UINT32 Flags X2DEFAULT(0), + float MaxFrequencyRatio X2DEFAULT(XAUDIO2_DEFAULT_FREQ_RATIO), + _In_opt_ IXAudio2VoiceCallback* pCallback X2DEFAULT(NULL), + _In_opt_ const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), + _In_opt_ const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; + + // NAME: IXAudio2::CreateSubmixVoice + // DESCRIPTION: Creates and configures a submix voice. + // + // ARGUMENTS: + // ppSubmixVoice - Returns the new object's IXAudio2SubmixVoice interface. + // InputChannels - Number of channels in this voice's input audio data. + // InputSampleRate - Sample rate of this voice's input audio data. + // Flags - XAUDIO2_VOICE flags specifying the submix voice's behavior. + // ProcessingStage - Arbitrary number that determines the processing order. + // pSendList - Optional list of voices this voice should send audio to. + // pEffectChain - Optional list of effects to apply to the audio data. + // + STDMETHOD(CreateSubmixVoice) (THIS_ _Outptr_ IXAudio2SubmixVoice** ppSubmixVoice, + UINT32 InputChannels, UINT32 InputSampleRate, + UINT32 Flags X2DEFAULT(0), UINT32 ProcessingStage X2DEFAULT(0), + _In_opt_ const XAUDIO2_VOICE_SENDS* pSendList X2DEFAULT(NULL), + _In_opt_ const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL)) PURE; + + + // NAME: IXAudio2::CreateMasteringVoice + // DESCRIPTION: Creates and configures a mastering voice. + // + // ARGUMENTS: + // ppMasteringVoice - Returns the new object's IXAudio2MasteringVoice interface. + // InputChannels - Number of channels in this voice's input audio data. + // InputSampleRate - Sample rate of this voice's input audio data. + // Flags - XAUDIO2_VOICE flags specifying the mastering voice's behavior. + // szDeviceId - Identifier of the device to receive the output audio. + // pEffectChain - Optional list of effects to apply to the audio data. + // StreamCategory - The audio stream category to use for this mastering voice + // + STDMETHOD(CreateMasteringVoice) (THIS_ _Outptr_ IXAudio2MasteringVoice** ppMasteringVoice, + UINT32 InputChannels X2DEFAULT(XAUDIO2_DEFAULT_CHANNELS), + UINT32 InputSampleRate X2DEFAULT(XAUDIO2_DEFAULT_SAMPLERATE), + UINT32 Flags X2DEFAULT(0), _In_opt_z_ LPCWSTR szDeviceId X2DEFAULT(NULL), + _In_opt_ const XAUDIO2_EFFECT_CHAIN* pEffectChain X2DEFAULT(NULL), + _In_ AUDIO_STREAM_CATEGORY StreamCategory X2DEFAULT(AudioCategory_GameEffects)) PURE; + + // NAME: IXAudio2::StartEngine + // DESCRIPTION: Creates and starts the audio processing thread. + // + STDMETHOD(StartEngine) (THIS) PURE; + + // NAME: IXAudio2::StopEngine + // DESCRIPTION: Stops and destroys the audio processing thread. + // + STDMETHOD_(void, StopEngine) (THIS) PURE; + + // NAME: IXAudio2::CommitChanges + // DESCRIPTION: Atomically applies a set of operations previously tagged + // with a given identifier. + // + // ARGUMENTS: + // OperationSet - Identifier of the set of operations to be applied. + // + STDMETHOD(CommitChanges) (THIS_ UINT32 OperationSet) PURE; + + // NAME: IXAudio2::GetPerformanceData + // DESCRIPTION: Returns current resource usage details: memory, CPU, etc. + // + // ARGUMENTS: + // pPerfData - Returns the performance data structure. + // + STDMETHOD_(void, GetPerformanceData) (THIS_ _Out_ XAUDIO2_PERFORMANCE_DATA* pPerfData) PURE; + + // NAME: IXAudio2::SetDebugConfiguration + // DESCRIPTION: Configures XAudio2's debug output (in debug builds only). + // + // ARGUMENTS: + // pDebugConfiguration - Structure describing the debug output behavior. + // pReserved - Optional parameter; must be NULL. + // + STDMETHOD_(void, SetDebugConfiguration) (THIS_ _In_opt_ const XAUDIO2_DEBUG_CONFIGURATION* pDebugConfiguration, + _Reserved_ void* pReserved X2DEFAULT(NULL)) PURE; +}; + + +/************************************************************************** + * + * IXAudio2Voice: Base voice management interface. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2Voice +DECLARE_INTERFACE(IXAudio2Voice) +{ + // These methods are declared in a macro so that the same declarations + // can be used in the derived voice types (IXAudio2SourceVoice, etc). + +#define Declare_IXAudio2Voice_Methods() \ + \ + /* NAME: IXAudio2Voice::GetVoiceDetails + // DESCRIPTION: Returns the basic characteristics of this voice. + // + // ARGUMENTS: + // pVoiceDetails - Returns the voice's details. + */\ + STDMETHOD_(void, GetVoiceDetails) (THIS_ _Out_ XAUDIO2_VOICE_DETAILS* pVoiceDetails) PURE; \ + \ + /* NAME: IXAudio2Voice::SetOutputVoices + // DESCRIPTION: Replaces the set of submix/mastering voices that receive + // this voice's output. + // + // ARGUMENTS: + // pSendList - Optional list of voices this voice should send audio to. + */\ + STDMETHOD(SetOutputVoices) (THIS_ _In_opt_ const XAUDIO2_VOICE_SENDS* pSendList) PURE; \ + \ + /* NAME: IXAudio2Voice::SetEffectChain + // DESCRIPTION: Replaces this voice's current effect chain with a new one. + // + // ARGUMENTS: + // pEffectChain - Structure describing the new effect chain to be used. + */\ + STDMETHOD(SetEffectChain) (THIS_ _In_opt_ const XAUDIO2_EFFECT_CHAIN* pEffectChain) PURE; \ + \ + /* NAME: IXAudio2Voice::EnableEffect + // DESCRIPTION: Enables an effect in this voice's effect chain. + // + // ARGUMENTS: + // EffectIndex - Index of an effect within this voice's effect chain. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(EnableEffect) (THIS_ UINT32 EffectIndex, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::DisableEffect + // DESCRIPTION: Disables an effect in this voice's effect chain. + // + // ARGUMENTS: + // EffectIndex - Index of an effect within this voice's effect chain. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(DisableEffect) (THIS_ UINT32 EffectIndex, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetEffectState + // DESCRIPTION: Returns the running state of an effect. + // + // ARGUMENTS: + // EffectIndex - Index of an effect within this voice's effect chain. + // pEnabled - Returns the enabled/disabled state of the given effect. + */\ + STDMETHOD_(void, GetEffectState) (THIS_ UINT32 EffectIndex, _Out_ BOOL* pEnabled) PURE; \ + \ + /* NAME: IXAudio2Voice::SetEffectParameters + // DESCRIPTION: Sets effect-specific parameters. + // + // REMARKS: Unlike IXAPOParameters::SetParameters, this method may + // be called from any thread. XAudio2 implements + // appropriate synchronization to copy the parameters to the + // realtime audio processing thread. + // + // ARGUMENTS: + // EffectIndex - Index of an effect within this voice's effect chain. + // pParameters - Pointer to an effect-specific parameters block. + // ParametersByteSize - Size of the pParameters array in bytes. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetEffectParameters) (THIS_ UINT32 EffectIndex, \ + _In_reads_bytes_(ParametersByteSize) const void* pParameters, \ + UINT32 ParametersByteSize, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetEffectParameters + // DESCRIPTION: Obtains the current effect-specific parameters. + // + // ARGUMENTS: + // EffectIndex - Index of an effect within this voice's effect chain. + // pParameters - Returns the current values of the effect-specific parameters. + // ParametersByteSize - Size of the pParameters array in bytes. + */\ + STDMETHOD(GetEffectParameters) (THIS_ UINT32 EffectIndex, \ + _Out_writes_bytes_(ParametersByteSize) void* pParameters, \ + UINT32 ParametersByteSize) PURE; \ + \ + /* NAME: IXAudio2Voice::SetFilterParameters + // DESCRIPTION: Sets this voice's filter parameters. + // + // ARGUMENTS: + // pParameters - Pointer to the filter's parameter structure. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetFilterParameters) (THIS_ _In_ const XAUDIO2_FILTER_PARAMETERS* pParameters, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetFilterParameters + // DESCRIPTION: Returns this voice's current filter parameters. + // + // ARGUMENTS: + // pParameters - Returns the filter parameters. + */\ + STDMETHOD_(void, GetFilterParameters) (THIS_ _Out_ XAUDIO2_FILTER_PARAMETERS* pParameters) PURE; \ + \ + /* NAME: IXAudio2Voice::SetOutputFilterParameters + // DESCRIPTION: Sets the filter parameters on one of this voice's sends. + // + // ARGUMENTS: + // pDestinationVoice - Destination voice of the send whose filter parameters will be set. + // pParameters - Pointer to the filter's parameter structure. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetOutputFilterParameters) (THIS_ _In_opt_ IXAudio2Voice* pDestinationVoice, \ + _In_ const XAUDIO2_FILTER_PARAMETERS* pParameters, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetOutputFilterParameters + // DESCRIPTION: Returns the filter parameters from one of this voice's sends. + // + // ARGUMENTS: + // pDestinationVoice - Destination voice of the send whose filter parameters will be read. + // pParameters - Returns the filter parameters. + */\ + STDMETHOD_(void, GetOutputFilterParameters) (THIS_ _In_opt_ IXAudio2Voice* pDestinationVoice, \ + _Out_ XAUDIO2_FILTER_PARAMETERS* pParameters) PURE; \ + \ + /* NAME: IXAudio2Voice::SetVolume + // DESCRIPTION: Sets this voice's overall volume level. + // + // ARGUMENTS: + // Volume - New overall volume level to be used, as an amplitude factor. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetVolume) (THIS_ float Volume, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetVolume + // DESCRIPTION: Obtains this voice's current overall volume level. + // + // ARGUMENTS: + // pVolume: Returns the voice's current overall volume level. + */\ + STDMETHOD_(void, GetVolume) (THIS_ _Out_ float* pVolume) PURE; \ + \ + /* NAME: IXAudio2Voice::SetChannelVolumes + // DESCRIPTION: Sets this voice's per-channel volume levels. + // + // ARGUMENTS: + // Channels - Used to confirm the voice's channel count. + // pVolumes - Array of per-channel volume levels to be used. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetChannelVolumes) (THIS_ UINT32 Channels, _In_reads_(Channels) const float* pVolumes, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetChannelVolumes + // DESCRIPTION: Returns this voice's current per-channel volume levels. + // + // ARGUMENTS: + // Channels - Used to confirm the voice's channel count. + // pVolumes - Returns an array of the current per-channel volume levels. + */\ + STDMETHOD_(void, GetChannelVolumes) (THIS_ UINT32 Channels, _Out_writes_(Channels) float* pVolumes) PURE; \ + \ + /* NAME: IXAudio2Voice::SetOutputMatrix + // DESCRIPTION: Sets the volume levels used to mix from each channel of this + // voice's output audio to each channel of a given destination + // voice's input audio. + // + // ARGUMENTS: + // pDestinationVoice - The destination voice whose mix matrix to change. + // SourceChannels - Used to confirm this voice's output channel count + // (the number of channels produced by the last effect in the chain). + // DestinationChannels - Confirms the destination voice's input channels. + // pLevelMatrix - Array of [SourceChannels * DestinationChannels] send + // levels. The level used to send from source channel S to destination + // channel D should be in pLevelMatrix[S + SourceChannels * D]. + // OperationSet - Used to identify this call as part of a deferred batch. + */\ + STDMETHOD(SetOutputMatrix) (THIS_ _In_opt_ IXAudio2Voice* pDestinationVoice, \ + UINT32 SourceChannels, UINT32 DestinationChannels, \ + _In_reads_(SourceChannels * DestinationChannels) const float* pLevelMatrix, \ + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; \ + \ + /* NAME: IXAudio2Voice::GetOutputMatrix + // DESCRIPTION: Obtains the volume levels used to send each channel of this + // voice's output audio to each channel of a given destination + // voice's input audio. + // + // ARGUMENTS: + // pDestinationVoice - The destination voice whose mix matrix to obtain. + // SourceChannels - Used to confirm this voice's output channel count + // (the number of channels produced by the last effect in the chain). + // DestinationChannels - Confirms the destination voice's input channels. + // pLevelMatrix - Array of send levels, as above. + */\ + STDMETHOD_(void, GetOutputMatrix) (THIS_ _In_opt_ IXAudio2Voice* pDestinationVoice, \ + UINT32 SourceChannels, UINT32 DestinationChannels, \ + _Out_writes_(SourceChannels * DestinationChannels) float* pLevelMatrix) PURE; \ + \ + /* NAME: IXAudio2Voice::DestroyVoice + // DESCRIPTION: Destroys this voice, stopping it if necessary and removing + // it from the XAudio2 graph. + */\ + STDMETHOD_(void, DestroyVoice) (THIS) PURE + + Declare_IXAudio2Voice_Methods(); +}; + + +/************************************************************************** + * + * IXAudio2SourceVoice: Source voice management interface. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2SourceVoice +DECLARE_INTERFACE_(IXAudio2SourceVoice, IXAudio2Voice) +{ + // Methods from IXAudio2Voice base interface + Declare_IXAudio2Voice_Methods(); + + // NAME: IXAudio2SourceVoice::Start + // DESCRIPTION: Makes this voice start consuming and processing audio. + // + // ARGUMENTS: + // Flags - Flags controlling how the voice should be started. + // OperationSet - Used to identify this call as part of a deferred batch. + // + STDMETHOD(Start) (THIS_ UINT32 Flags X2DEFAULT(0), UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + + // NAME: IXAudio2SourceVoice::Stop + // DESCRIPTION: Makes this voice stop consuming audio. + // + // ARGUMENTS: + // Flags - Flags controlling how the voice should be stopped. + // OperationSet - Used to identify this call as part of a deferred batch. + // + STDMETHOD(Stop) (THIS_ UINT32 Flags X2DEFAULT(0), UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + + // NAME: IXAudio2SourceVoice::SubmitSourceBuffer + // DESCRIPTION: Adds a new audio buffer to this voice's input queue. + // + // ARGUMENTS: + // pBuffer - Pointer to the buffer structure to be queued. + // pBufferWMA - Additional structure used only when submitting XWMA data. + // + STDMETHOD(SubmitSourceBuffer) (THIS_ _In_ const XAUDIO2_BUFFER* pBuffer, _In_opt_ const XAUDIO2_BUFFER_WMA* pBufferWMA X2DEFAULT(NULL)) PURE; + + // NAME: IXAudio2SourceVoice::FlushSourceBuffers + // DESCRIPTION: Removes all pending audio buffers from this voice's queue. + // + STDMETHOD(FlushSourceBuffers) (THIS) PURE; + + // NAME: IXAudio2SourceVoice::Discontinuity + // DESCRIPTION: Notifies the voice of an intentional break in the stream of + // audio buffers (e.g. the end of a sound), to prevent XAudio2 + // from interpreting an empty buffer queue as a glitch. + // + STDMETHOD(Discontinuity) (THIS) PURE; + + // NAME: IXAudio2SourceVoice::ExitLoop + // DESCRIPTION: Breaks out of the current loop when its end is reached. + // + // ARGUMENTS: + // OperationSet - Used to identify this call as part of a deferred batch. + // + STDMETHOD(ExitLoop) (THIS_ UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + + // NAME: IXAudio2SourceVoice::GetState + // DESCRIPTION: Returns the number of buffers currently queued on this voice, + // the pContext value associated with the currently processing + // buffer (if any), and other voice state information. + // + // ARGUMENTS: + // pVoiceState - Returns the state information. + // Flags - Flags controlling what voice state is returned. + // + STDMETHOD_(void, GetState) (THIS_ _Out_ XAUDIO2_VOICE_STATE* pVoiceState, UINT32 Flags X2DEFAULT(0)) PURE; + + // NAME: IXAudio2SourceVoice::SetFrequencyRatio + // DESCRIPTION: Sets this voice's frequency adjustment, i.e. its pitch. + // + // ARGUMENTS: + // Ratio - Frequency change, expressed as source frequency / target frequency. + // OperationSet - Used to identify this call as part of a deferred batch. + // + STDMETHOD(SetFrequencyRatio) (THIS_ float Ratio, + UINT32 OperationSet X2DEFAULT(XAUDIO2_COMMIT_NOW)) PURE; + + // NAME: IXAudio2SourceVoice::GetFrequencyRatio + // DESCRIPTION: Returns this voice's current frequency adjustment ratio. + // + // ARGUMENTS: + // pRatio - Returns the frequency adjustment. + // + STDMETHOD_(void, GetFrequencyRatio) (THIS_ _Out_ float* pRatio) PURE; + + // NAME: IXAudio2SourceVoice::SetSourceSampleRate + // DESCRIPTION: Reconfigures this voice to treat its source data as being + // at a different sample rate than the original one specified + // in CreateSourceVoice's pSourceFormat argument. + // + // ARGUMENTS: + // UINT32 - The intended sample rate of further submitted source data. + // + STDMETHOD(SetSourceSampleRate) (THIS_ UINT32 NewSourceSampleRate) PURE; +}; + + +/************************************************************************** + * + * IXAudio2SubmixVoice: Submixing voice management interface. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2SubmixVoice +DECLARE_INTERFACE_(IXAudio2SubmixVoice, IXAudio2Voice) +{ + // Methods from IXAudio2Voice base interface + Declare_IXAudio2Voice_Methods(); + + // There are currently no methods specific to submix voices. +}; + + +/************************************************************************** + * + * IXAudio2MasteringVoice: Mastering voice management interface. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2MasteringVoice +DECLARE_INTERFACE_(IXAudio2MasteringVoice, IXAudio2Voice) +{ + // Methods from IXAudio2Voice base interface + Declare_IXAudio2Voice_Methods(); + + // NAME: IXAudio2MasteringVoice::GetChannelMask + // DESCRIPTION: Returns the channel mask for this voice + // + // ARGUMENTS: + // pChannelMask - returns the channel mask for this voice. This corresponds + // to the dwChannelMask member of WAVEFORMATEXTENSIBLE. + // + STDMETHOD(GetChannelMask) (THIS_ _Out_ DWORD* pChannelmask) PURE; +}; + + +/************************************************************************** + * + * IXAudio2EngineCallback: Client notification interface for engine events. + * + * REMARKS: Contains methods to notify the client when certain events happen + * in the XAudio2 engine. This interface should be implemented by + * the client. XAudio2 will call these methods via the interface + * pointer provided by the client when it calls + * IXAudio2::RegisterForCallbacks. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2EngineCallback +DECLARE_INTERFACE(IXAudio2EngineCallback) +{ + // Called by XAudio2 just before an audio processing pass begins. + STDMETHOD_(void, OnProcessingPassStart) (THIS) PURE; + + // Called just after an audio processing pass ends. + STDMETHOD_(void, OnProcessingPassEnd) (THIS) PURE; + + // Called in the event of a critical system error which requires XAudio2 + // to be closed down and restarted. The error code is given in Error. + STDMETHOD_(void, OnCriticalError) (THIS_ HRESULT Error) PURE; +}; + + +/************************************************************************** + * + * IXAudio2VoiceCallback: Client notification interface for voice events. + * + * REMARKS: Contains methods to notify the client when certain events happen + * in an XAudio2 voice. This interface should be implemented by the + * client. XAudio2 will call these methods via an interface pointer + * provided by the client in the IXAudio2::CreateSourceVoice call. + * + **************************************************************************/ + +#undef INTERFACE +#define INTERFACE IXAudio2VoiceCallback +DECLARE_INTERFACE(IXAudio2VoiceCallback) +{ + // Called just before this voice's processing pass begins. + STDMETHOD_(void, OnVoiceProcessingPassStart) (THIS_ UINT32 BytesRequired) PURE; + + // Called just after this voice's processing pass ends. + STDMETHOD_(void, OnVoiceProcessingPassEnd) (THIS) PURE; + + // Called when this voice has just finished playing a buffer stream + // (as marked with the XAUDIO2_END_OF_STREAM flag on the last buffer). + STDMETHOD_(void, OnStreamEnd) (THIS) PURE; + + // Called when this voice is about to start processing a new buffer. + STDMETHOD_(void, OnBufferStart) (THIS_ void* pBufferContext) PURE; + + // Called when this voice has just finished processing a buffer. + // The buffer can now be reused or destroyed. + STDMETHOD_(void, OnBufferEnd) (THIS_ void* pBufferContext) PURE; + + // Called when this voice has just reached the end position of a loop. + STDMETHOD_(void, OnLoopEnd) (THIS_ void* pBufferContext) PURE; + + // Called in the event of a critical error during voice processing, + // such as a failing xAPO or an error from the hardware XMA decoder. + // The voice may have to be destroyed and re-created to recover from + // the error. The callback arguments report which buffer was being + // processed when the error occurred, and its HRESULT code. + STDMETHOD_(void, OnVoiceError) (THIS_ void* pBufferContext, HRESULT Error) PURE; +}; + + +/************************************************************************** + * + * Macros to make it easier to use the XAudio2 COM interfaces in C code. + * + **************************************************************************/ + +#ifndef __cplusplus + + // IXAudio2 +#define IXAudio2_QueryInterface(This,riid,ppvInterface) ((This)->lpVtbl->QueryInterface(This,riid,ppvInterface)) +#define IXAudio2_AddRef(This) ((This)->lpVtbl->AddRef(This)) +#define IXAudio2_Release(This) ((This)->lpVtbl->Release(This)) +#define IXAudio2_CreateSourceVoice(This,ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain) ((This)->lpVtbl->CreateSourceVoice(This,ppSourceVoice,pSourceFormat,Flags,MaxFrequencyRatio,pCallback,pSendList,pEffectChain)) +#define IXAudio2_CreateSubmixVoice(This,ppSubmixVoice,InputChannels,InputSampleRate,Flags,ProcessingStage,pSendList,pEffectChain) ((This)->lpVtbl->CreateSubmixVoice(This,ppSubmixVoice,InputChannels,InputSampleRate,Flags,ProcessingStage,pSendList,pEffectChain)) +#define IXAudio2_CreateMasteringVoice(This,ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceId,pEffectChain,StreamCategory) ((This)->lpVtbl->CreateMasteringVoice(This,ppMasteringVoice,InputChannels,InputSampleRate,Flags,DeviceId,pEffectChain,StreamCategory)) +#define IXAudio2_StartEngine(This) ((This)->lpVtbl->StartEngine(This)) +#define IXAudio2_StopEngine(This) ((This)->lpVtbl->StopEngine(This)) +#define IXAudio2_CommitChanges(This,OperationSet) ((This)->lpVtbl->CommitChanges(This,OperationSet)) +#define IXAudio2_GetPerformanceData(This,pPerfData) ((This)->lpVtbl->GetPerformanceData(This,pPerfData)) +#define IXAudio2_SetDebugConfiguration(This,pDebugConfiguration,pReserved) ((This)->lpVtbl->SetDebugConfiguration(This,pDebugConfiguration,pReserved)) + +// IXAudio2Voice +#define IXAudio2Voice_GetVoiceDetails(This,pVoiceDetails) ((This)->lpVtbl->GetVoiceDetails(This,pVoiceDetails)) +#define IXAudio2Voice_SetOutputVoices(This,pSendList) ((This)->lpVtbl->SetOutputVoices(This,pSendList)) +#define IXAudio2Voice_SetEffectChain(This,pEffectChain) ((This)->lpVtbl->SetEffectChain(This,pEffectChain)) +#define IXAudio2Voice_EnableEffect(This,EffectIndex,OperationSet) ((This)->lpVtbl->EnableEffect(This,EffectIndex,OperationSet)) +#define IXAudio2Voice_DisableEffect(This,EffectIndex,OperationSet) ((This)->lpVtbl->DisableEffect(This,EffectIndex,OperationSet)) +#define IXAudio2Voice_GetEffectState(This,EffectIndex,pEnabled) ((This)->lpVtbl->GetEffectState(This,EffectIndex,pEnabled)) +#define IXAudio2Voice_SetEffectParameters(This,EffectIndex,pParameters,ParametersByteSize, OperationSet) ((This)->lpVtbl->SetEffectParameters(This,EffectIndex,pParameters,ParametersByteSize,OperationSet)) +#define IXAudio2Voice_GetEffectParameters(This,EffectIndex,pParameters,ParametersByteSize) ((This)->lpVtbl->GetEffectParameters(This,EffectIndex,pParameters,ParametersByteSize)) +#define IXAudio2Voice_SetFilterParameters(This,pParameters,OperationSet) ((This)->lpVtbl->SetFilterParameters(This,pParameters,OperationSet)) +#define IXAudio2Voice_GetFilterParameters(This,pParameters) ((This)->lpVtbl->GetFilterParameters(This,pParameters)) +#define IXAudio2Voice_SetOutputFilterParameters(This,pDestinationVoice,pParameters,OperationSet) ((This)->lpVtbl->SetOutputFilterParameters(This,pDestinationVoice,pParameters,OperationSet)) +#define IXAudio2Voice_GetOutputFilterParameters(This,pDestinationVoice,pParameters) ((This)->lpVtbl->GetOutputFilterParameters(This,pDestinationVoice,pParameters)) +#define IXAudio2Voice_SetVolume(This,Volume,OperationSet) ((This)->lpVtbl->SetVolume(This,Volume,OperationSet)) +#define IXAudio2Voice_GetVolume(This,pVolume) ((This)->lpVtbl->GetVolume(This,pVolume)) +#define IXAudio2Voice_SetChannelVolumes(This,Channels,pVolumes,OperationSet) ((This)->lpVtbl->SetChannelVolumes(This,Channels,pVolumes,OperationSet)) +#define IXAudio2Voice_GetChannelVolumes(This,Channels,pVolumes) ((This)->lpVtbl->GetChannelVolumes(This,Channels,pVolumes)) +#define IXAudio2Voice_SetOutputMatrix(This,pDestinationVoice,SourceChannels,DestinationChannels,pLevelMatrix,OperationSet) ((This)->lpVtbl->SetOutputMatrix(This,pDestinationVoice,SourceChannels,DestinationChannels,pLevelMatrix,OperationSet)) +#define IXAudio2Voice_GetOutputMatrix(This,pDestinationVoice,SourceChannels,DestinationChannels,pLevelMatrix) ((This)->lpVtbl->GetOutputMatrix(This,pDestinationVoice,SourceChannels,DestinationChannels,pLevelMatrix)) +#define IXAudio2Voice_DestroyVoice(This) ((This)->lpVtbl->DestroyVoice(This)) + +// IXAudio2SourceVoice +#define IXAudio2SourceVoice_GetVoiceDetails IXAudio2Voice_GetVoiceDetails +#define IXAudio2SourceVoice_SetOutputVoices IXAudio2Voice_SetOutputVoices +#define IXAudio2SourceVoice_SetEffectChain IXAudio2Voice_SetEffectChain +#define IXAudio2SourceVoice_EnableEffect IXAudio2Voice_EnableEffect +#define IXAudio2SourceVoice_DisableEffect IXAudio2Voice_DisableEffect +#define IXAudio2SourceVoice_GetEffectState IXAudio2Voice_GetEffectState +#define IXAudio2SourceVoice_SetEffectParameters IXAudio2Voice_SetEffectParameters +#define IXAudio2SourceVoice_GetEffectParameters IXAudio2Voice_GetEffectParameters +#define IXAudio2SourceVoice_SetFilterParameters IXAudio2Voice_SetFilterParameters +#define IXAudio2SourceVoice_GetFilterParameters IXAudio2Voice_GetFilterParameters +#define IXAudio2SourceVoice_SetOutputFilterParameters IXAudio2Voice_SetOutputFilterParameters +#define IXAudio2SourceVoice_GetOutputFilterParameters IXAudio2Voice_GetOutputFilterParameters +#define IXAudio2SourceVoice_SetVolume IXAudio2Voice_SetVolume +#define IXAudio2SourceVoice_GetVolume IXAudio2Voice_GetVolume +#define IXAudio2SourceVoice_SetChannelVolumes IXAudio2Voice_SetChannelVolumes +#define IXAudio2SourceVoice_GetChannelVolumes IXAudio2Voice_GetChannelVolumes +#define IXAudio2SourceVoice_SetOutputMatrix IXAudio2Voice_SetOutputMatrix +#define IXAudio2SourceVoice_GetOutputMatrix IXAudio2Voice_GetOutputMatrix +#define IXAudio2SourceVoice_DestroyVoice IXAudio2Voice_DestroyVoice +#define IXAudio2SourceVoice_Start(This,Flags,OperationSet) ((This)->lpVtbl->Start(This,Flags,OperationSet)) +#define IXAudio2SourceVoice_Stop(This,Flags,OperationSet) ((This)->lpVtbl->Stop(This,Flags,OperationSet)) +#define IXAudio2SourceVoice_SubmitSourceBuffer(This,pBuffer,pBufferWMA) ((This)->lpVtbl->SubmitSourceBuffer(This,pBuffer,pBufferWMA)) +#define IXAudio2SourceVoice_FlushSourceBuffers(This) ((This)->lpVtbl->FlushSourceBuffers(This)) +#define IXAudio2SourceVoice_Discontinuity(This) ((This)->lpVtbl->Discontinuity(This)) +#define IXAudio2SourceVoice_ExitLoop(This,OperationSet) ((This)->lpVtbl->ExitLoop(This,OperationSet)) +#define IXAudio2SourceVoice_GetState(This,pVoiceState,Flags) ((This)->lpVtbl->GetState(This,pVoiceState,Flags)) +#define IXAudio2SourceVoice_SetFrequencyRatio(This,Ratio,OperationSet) ((This)->lpVtbl->SetFrequencyRatio(This,Ratio,OperationSet)) +#define IXAudio2SourceVoice_GetFrequencyRatio(This,pRatio) ((This)->lpVtbl->GetFrequencyRatio(This,pRatio)) +#define IXAudio2SourceVoice_SetSourceSampleRate(This,NewSourceSampleRate) ((This)->lpVtbl->SetSourceSampleRate(This,NewSourceSampleRate)) + +// IXAudio2SubmixVoice +#define IXAudio2SubmixVoice_GetVoiceDetails IXAudio2Voice_GetVoiceDetails +#define IXAudio2SubmixVoice_SetOutputVoices IXAudio2Voice_SetOutputVoices +#define IXAudio2SubmixVoice_SetEffectChain IXAudio2Voice_SetEffectChain +#define IXAudio2SubmixVoice_EnableEffect IXAudio2Voice_EnableEffect +#define IXAudio2SubmixVoice_DisableEffect IXAudio2Voice_DisableEffect +#define IXAudio2SubmixVoice_GetEffectState IXAudio2Voice_GetEffectState +#define IXAudio2SubmixVoice_SetEffectParameters IXAudio2Voice_SetEffectParameters +#define IXAudio2SubmixVoice_GetEffectParameters IXAudio2Voice_GetEffectParameters +#define IXAudio2SubmixVoice_SetFilterParameters IXAudio2Voice_SetFilterParameters +#define IXAudio2SubmixVoice_GetFilterParameters IXAudio2Voice_GetFilterParameters +#define IXAudio2SubmixVoice_SetOutputFilterParameters IXAudio2Voice_SetOutputFilterParameters +#define IXAudio2SubmixVoice_GetOutputFilterParameters IXAudio2Voice_GetOutputFilterParameters +#define IXAudio2SubmixVoice_SetVolume IXAudio2Voice_SetVolume +#define IXAudio2SubmixVoice_GetVolume IXAudio2Voice_GetVolume +#define IXAudio2SubmixVoice_SetChannelVolumes IXAudio2Voice_SetChannelVolumes +#define IXAudio2SubmixVoice_GetChannelVolumes IXAudio2Voice_GetChannelVolumes +#define IXAudio2SubmixVoice_SetOutputMatrix IXAudio2Voice_SetOutputMatrix +#define IXAudio2SubmixVoice_GetOutputMatrix IXAudio2Voice_GetOutputMatrix +#define IXAudio2SubmixVoice_DestroyVoice IXAudio2Voice_DestroyVoice + +/* IXAudio2MasteringVoice */ +#define IXAudio2MasteringVoice_GetVoiceDetails IXAudio2Voice_GetVoiceDetails +#define IXAudio2MasteringVoice_SetOutputVoices IXAudio2Voice_SetOutputVoices +#define IXAudio2MasteringVoice_SetEffectChain IXAudio2Voice_SetEffectChain +#define IXAudio2MasteringVoice_EnableEffect IXAudio2Voice_EnableEffect +#define IXAudio2MasteringVoice_DisableEffect IXAudio2Voice_DisableEffect +#define IXAudio2MasteringVoice_GetEffectState IXAudio2Voice_GetEffectState +#define IXAudio2MasteringVoice_SetEffectParameters IXAudio2Voice_SetEffectParameters +#define IXAudio2MasteringVoice_GetEffectParameters IXAudio2Voice_GetEffectParameters +#define IXAudio2MasteringVoice_SetFilterParameters IXAudio2Voice_SetFilterParameters +#define IXAudio2MasteringVoice_GetFilterParameters IXAudio2Voice_GetFilterParameters +#define IXAudio2MasteringVoice_SetOutputFilterParameters IXAudio2Voice_SetOutputFilterParameters +#define IXAudio2MasteringVoice_GetOutputFilterParameters IXAudio2Voice_GetOutputFilterParameters +#define IXAudio2MasteringVoice_SetVolume IXAudio2Voice_SetVolume +#define IXAudio2MasteringVoice_GetVolume IXAudio2Voice_GetVolume +#define IXAudio2MasteringVoice_SetChannelVolumes IXAudio2Voice_SetChannelVolumes +#define IXAudio2MasteringVoice_GetChannelVolumes IXAudio2Voice_GetChannelVolumes +#define IXAudio2MasteringVoice_SetOutputMatrix IXAudio2Voice_SetOutputMatrix +#define IXAudio2MasteringVoice_GetOutputMatrix IXAudio2Voice_GetOutputMatrix +#define IXAudio2MasteringVoice_DestroyVoice IXAudio2Voice_DestroyVoice +#define IXAudio2MasteringVoice_GetChannelMask(This,pChannelMask) ((This)->lpVtbl->GetChannelMask(This,pChannelMask)) + +#endif /* #ifndef __cplusplus */ + + +/************************************************************************** + * + * Utility functions used to convert from pitch in semitones and volume + * in decibels to the frequency and amplitude ratio units used by XAudio2. + * These are only defined if the client #defines XAUDIO2_HELPER_FUNCTIONS + * prior to #including xaudio2.h. + * + **************************************************************************/ + +#ifdef XAUDIO2_HELPER_FUNCTIONS + +#define _USE_MATH_DEFINES /* Make math.h define M_PI */ +#include /* For powf, log10f, sinf and asinf */ + +/* Calculate the argument to SetVolume from a decibel value */ +static INLINE float XAudio2DecibelsToAmplitudeRatio(float Decibels) +{ + return powf(10.0f, Decibels / 20.0f); +} + +/* Recover a volume in decibels from an amplitude factor */ +static INLINE float XAudio2AmplitudeRatioToDecibels(float Volume) +{ + if (Volume == 0) + return -3.402823466e+38f; /* Smallest float value (-FLT_MAX) */ + return 20.0f * log10f(Volume); +} + +/* Calculate the argument to SetFrequencyRatio from a semitone value */ +static INLINE float XAudio2SemitonesToFrequencyRatio(float Semitones) +{ + /* FrequencyRatio = 2 ^ Octaves + * = 2 ^ (Semitones / 12) + */ + return powf(2.0f, Semitones / 12.0f); +} + +/* Recover a pitch in semitones from a frequency ratio */ +static INLINE float XAudio2FrequencyRatioToSemitones(float FrequencyRatio) +{ + /* Semitones = 12 * log2(FrequencyRatio) + * = 12 * log2(10) * log10(FrequencyRatio) + */ + return 39.86313713864835f * log10f(FrequencyRatio); +} + +/* Convert from filter cutoff frequencies expressed in Hertz to the radian + * frequency values used in XAUDIO2_FILTER_PARAMETERS.Frequency, state-variable + * filter types only. Use XAudio2CutoffFrequencyToOnePoleCoefficient() for one-pole filter types. + * Note that the highest CutoffFrequency supported is SampleRate/6. + * Higher values of CutoffFrequency will return XAUDIO2_MAX_FILTER_FREQUENCY. + */ +static INLINE float XAudio2CutoffFrequencyToRadians(float CutoffFrequency, UINT32 SampleRate) +{ + if ((UINT32)(CutoffFrequency * 6.0f) >= SampleRate) + return XAUDIO2_MAX_FILTER_FREQUENCY; + return 2.0f * sinf((float)M_PI * CutoffFrequency / SampleRate); +} + +/* Convert from radian frequencies back to absolute frequencies in Hertz */ +static INLINE float XAudio2RadiansToCutoffFrequency(float Radians, float SampleRate) +{ + return SampleRate * asinf(Radians / 2.0f) / (float)M_PI; +} + +/* Convert from filter cutoff frequencies expressed in Hertz to the filter + * coefficients used with XAUDIO2_FILTER_PARAMETERS.Frequency, + * LowPassOnePoleFilter and HighPassOnePoleFilter filter types only. + * Use XAudio2CutoffFrequencyToRadians() for state-variable filter types. + */ +static INLINE float XAudio2CutoffFrequencyToOnePoleCoefficient(float CutoffFrequency, UINT32 SampleRate) +{ + if ((UINT32)CutoffFrequency >= SampleRate) + return XAUDIO2_MAX_FILTER_FREQUENCY; + return (1.0f - powf(1.0f - 2.0f * CutoffFrequency / SampleRate, 2.0f)); +} + + +#endif // #ifdef XAUDIO2_HELPER_FUNCTIONS + + +/************************************************************************** + * + * XAudio2Create: Top-level function that creates an XAudio2 instance. + * + * ARGUMENTS: + * + * Flags - Flags specifying the XAudio2 object's behavior. + * + * XAudio2Processor - An XAUDIO2_PROCESSOR value that specifies the + * hardware threads (Xbox) or processors (Windows) that XAudio2 + * will use. Note that XAudio2 supports concurrent processing on + * multiple threads, using any combination of XAUDIO2_PROCESSOR + * flags. The values are platform-specific; platform-independent + * code can use XAUDIO2_DEFAULT_PROCESSOR to use the default on + * each platform. + * + **************************************************************************/ + +#ifdef __cplusplus__ + +#if (defined XAUDIO2_EXPORT) + /* We're building xaudio2.dll */ +#define XAUDIO2_STDAPI extern "C" __declspec(dllexport) HRESULT __stdcall +#else + /* We're an xaudio2 client */ +#define XAUDIO2_STDAPI extern "C" __declspec(dllimport) HRESULT __stdcall +#endif + +#else + + /* Modified for C support */ + +#if (defined XAUDIO2_EXPORT) + /* We're building xaudio2.dll */ +#define XAUDIO2_STDAPI __declspec(dllexport) HRESULT __stdcall +#else + /* We're an xaudio2 client */ +#define XAUDIO2_STDAPI __declspec(dllimport) HRESULT __stdcall +#endif + +#endif + +#if (NTDDI_VERSION >= NTDDI_WIN10_RS5) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) +XAUDIO2_STDAPI XAudio2CreateWithVersionInfo(_Outptr_ IXAudio2** ppXAudio2, + UINT32 Flags X2DEFAULT(0), + XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR), + DWORD ntddiVersion X2DEFAULT(NTDDI_VERSION)); + +static INLINE HRESULT XAudio2Create(_Outptr_ IXAudio2** ppXAudio2, + UINT32 Flags X2DEFAULT(0), + XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)) +{ + /* When compiled for RS5 or later, try to invoke XAudio2CreateWithVersionInfo. + * Need to use LoadLibrary in case the app is running on an older OS. */ + typedef HRESULT(__stdcall *XAudio2CreateWithVersionInfoFunc)(_Outptr_ IXAudio2**, UINT32, XAUDIO2_PROCESSOR, DWORD); + typedef HRESULT(__stdcall *XAudio2CreateInfoFunc)(_Outptr_ IXAudio2**, UINT32, XAUDIO2_PROCESSOR); + + static HMODULE s_dllInstance = NULL; + static XAudio2CreateWithVersionInfoFunc s_pfnAudio2CreateWithVersion = NULL; + static XAudio2CreateInfoFunc s_pfnAudio2Create = NULL; + + if (s_dllInstance == NULL) + { + s_dllInstance = LoadLibraryEx(XAUDIO2_DLL, NULL, LOAD_LIBRARY_SEARCH_SYSTEM32); + if (s_dllInstance == NULL) + return HRESULT_FROM_WIN32(GetLastError()); + + s_pfnAudio2CreateWithVersion = (XAudio2CreateWithVersionInfoFunc)(void*)GetProcAddress(s_dllInstance, "XAudio2CreateWithVersionInfo"); + if (s_pfnAudio2CreateWithVersion == NULL) + { + s_pfnAudio2Create = (XAudio2CreateInfoFunc)(void*)GetProcAddress(s_dllInstance, "XAudio2Create"); + if (s_pfnAudio2Create == NULL) + return HRESULT_FROM_WIN32(GetLastError()); + } + } + + if (s_pfnAudio2CreateWithVersion != NULL) + return (*s_pfnAudio2CreateWithVersion)(ppXAudio2, Flags, XAudio2Processor, NTDDI_VERSION); + return (*s_pfnAudio2Create)(ppXAudio2, Flags, XAudio2Processor); +} +#else +/* RS4 or older, or not a desktop app */ +XAUDIO2_STDAPI XAudio2Create(_Outptr_ IXAudio2** ppXAudio2, UINT32 Flags X2DEFAULT(0), + XAUDIO2_PROCESSOR XAudio2Processor X2DEFAULT(XAUDIO2_DEFAULT_PROCESSOR)); +#endif + +/* Undo the #pragma pack(push, 1) directive at the top of this file */ +#pragma pack(pop) + +#endif /* #ifndef GUID_DEFS_ONLY */ + +#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP | WINAPI_PARTITION_TV_APP | WINAPI_PARTITION_TV_TITLE) */ +#pragma endregion + +#endif /* #ifndef __XAUDIO2_INCLUDED__ */ diff --git a/audio/drivers_resampler/cc_resampler.c b/audio/drivers_resampler/cc_resampler.c index 02e62a57be..b1136f1a16 100644 --- a/audio/drivers_resampler/cc_resampler.c +++ b/audio/drivers_resampler/cc_resampler.c @@ -55,7 +55,6 @@ typedef struct rarch_CC_resampler void (*process)(void *re, struct resampler_data *data); } rarch_CC_resampler_t; - #ifdef _MIPS_ARCH_ALLEGREX static void resampler_CC_process(void *re_, struct resampler_data *data) { @@ -115,7 +114,6 @@ static void resampler_CC_process(void *re_, struct resampler_data *data) "vadd.q c720, c720, c620 \n" - "vadd.s s730, s730, s730[1] \n" "mfv %0, s730 \n" @@ -216,7 +214,6 @@ static void resampler_CC_downsample(void *re_, struct resampler_data *data) vec_ww1 = _mm_mul_ps(vec_w1, vec_w1); vec_ww2 = _mm_mul_ps(vec_w2, vec_w2); - vec_ww1 = _mm_mul_ps(vec_ww1, _mm_sub_ps(_mm_set_ps1(3.0),vec_ww1)); vec_ww2 = _mm_mul_ps(vec_ww2, _mm_sub_ps(_mm_set_ps1(3.0),vec_ww2)); @@ -307,7 +304,6 @@ static void resampler_CC_upsample(void *re_, struct resampler_data *data) vec_ww1 = _mm_mul_ps(vec_w1, vec_w1); vec_ww2 = _mm_mul_ps(vec_w2, vec_w2); - vec_ww1 = _mm_mul_ps(vec_ww1,_mm_sub_ps(_mm_set_ps1(3.0),vec_ww1)); vec_ww2 = _mm_mul_ps(vec_ww2,_mm_sub_ps(_mm_set_ps1(3.0),vec_ww2)); @@ -349,7 +345,6 @@ static void resampler_CC_upsample(void *re_, struct resampler_data *data) data->output_frames = outp - (audio_frame_float_t*)data->data_out; } - #elif defined (__ARM_NEON__) && !defined(DONT_WANT_ARM_OPTIMIZATIONS) #define CC_RESAMPLER_IDENT "NEON" @@ -492,7 +487,6 @@ static void resampler_CC_process(void *re_, struct resampler_data *data) re->process(re_, data); } - static void *resampler_CC_init(const struct resampler_config *config, double bandwidth_mod, enum resampler_quality quality, diff --git a/audio/librsound.c b/audio/librsound.c index da2aaeaa86..df01eb24de 100644 --- a/audio/librsound.c +++ b/audio/librsound.c @@ -46,7 +46,6 @@ #define NETWORK_COMPAT_HEADERS 1 #endif - #ifdef NETWORK_COMPAT_HEADERS #include #include @@ -158,7 +157,6 @@ static int rsnd_poll(struct pollfd *fd, int numfd, int timeout); static void rsnd_cb_thread(void *thread_data); static void rsnd_thread(void *thread_data); - /* Determine whether we're running big- or little endian */ static INLINE int rsnd_is_little_endian(void) { @@ -242,7 +240,6 @@ static int rsnd_connect_server( rsound_t *rd ) rd->conn_type = RSD_CONN_TCP; - rd->conn.socket = net_socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); if ( rd->conn.socket < 0 ) goto error; @@ -312,7 +309,6 @@ static int rsnd_send_header_info(rsound_t *rd) #define FRAMESIZE 34 #define FORMAT 42 - uint32_t temp_rate = rd->rate; uint16_t temp_channels = rd->channels; @@ -980,7 +976,6 @@ static int rsnd_close_ctl(rsound_t *rd) return 0; } - // Sends delay info request to server on the ctl socket. This code section isn't critical, and will work if it works. // It will never block. static int rsnd_send_info_query(rsound_t *rd) @@ -1296,7 +1291,6 @@ static int rsnd_reset(rsound_t *rd) return 0; } - int rsd_stop(rsound_t *rd) { retro_assert(rd != NULL); @@ -1403,7 +1397,6 @@ int rsd_exec(rsound_t *rsound) return fd; } - /* ioctl()-ish param setting :D */ int rsd_set_param(rsound_t *rd, enum rsd_settings option, void* param) { @@ -1493,7 +1486,6 @@ void rsd_delay_wait(rsound_t *rd) /* Latency of stream in ms */ int latency_ms = rsd_delay_ms(rd); - /* Should we sleep for a while to keep the latency low? */ if ( rd->max_latency < latency_ms ) { diff --git a/bootstrap/vita/sbrk.c b/bootstrap/vita/sbrk.c index 051cae86b7..013ba9503d 100644 --- a/bootstrap/vita/sbrk.c +++ b/bootstrap/vita/sbrk.c @@ -46,7 +46,6 @@ void _init_vita_heap(void) { _newlib_vm_memblock = 0; } - // Create a mutex to use inside _sbrk_r if (sceKernelCreateLwMutex((struct SceKernelLwMutexWork*)_newlib_sbrk_mutex, "sbrk mutex", 0, 0, 0) < 0) { goto failure; diff --git a/cheevos/cheevos.c b/cheevos/cheevos.c index 18535b4232..1dab8ebe0c 100644 --- a/cheevos/cheevos.c +++ b/cheevos/cheevos.c @@ -2622,8 +2622,6 @@ static int cheevos_iterate(coro_t *coro) CORO_ENTER(); - - cheevos_locals.addrs_patched = false; coro->settings = config_get_ptr(); @@ -3395,7 +3393,7 @@ found: *coro->settings->arrays.cheevos_password = '\0'; strncpy( coro->settings->arrays.cheevos_token, - cheevos_locals.token, sizeof(cheevos_locals.token) + cheevos_locals.token, sizeof(coro->settings->arrays.cheevos_token) ); CORO_RET(); } diff --git a/command.c b/command.c index 0f0ad1969d..c7a927622c 100644 --- a/command.c +++ b/command.c @@ -244,8 +244,6 @@ static const struct cmd_map map[] = { }; #endif - - bool command_set_shader(const char *arg) { char msg[256]; @@ -273,7 +271,6 @@ bool command_set_shader(const char *arg) #endif } - #if defined(HAVE_COMMAND) && defined(HAVE_CHEEVOS) #define SMY_CMD_STR "READ_CORE_RAM" static bool command_read_ram(const char *arg) @@ -426,7 +423,6 @@ static bool command_network_init(command_t *handle, uint16_t port) msg_hash_to_str(MSG_BRINGING_UP_COMMAND_INTERFACE_ON_PORT), (unsigned short)port); - if (fd < 0) goto error; @@ -1150,7 +1146,6 @@ static void command_event_init_cheats(void) cheat_manager_alloc_if_empty() ; cheat_manager_load_game_specific_cheats() ; - if (settings != NULL && settings->bools.apply_cheats_after_load) cheat_manager_apply_cheats(); } @@ -1347,7 +1342,6 @@ static bool command_event_init_core(enum rarch_core_type *data) if(settings->bools.auto_shaders_enable) config_load_shader_preset(); - /* reset video format to libretro's default */ video_driver_set_pixel_format(RETRO_PIXEL_FORMAT_0RGB1555); @@ -1370,7 +1364,6 @@ static bool command_event_init_core(enum rarch_core_type *data) if (!core_load(settings->uints.input_poll_type_behavior)) return false; - rarch_ctl(RARCH_CTL_SET_FRAME_LIMIT, NULL); return true; } @@ -1634,7 +1627,6 @@ static void command_event_save_current_config(enum override_type type) break; } - if (!string_is_empty(msg)) runloop_msg_queue_push(msg, 1, 180, true); } @@ -1834,9 +1826,6 @@ void command_playlist_update_write( **/ bool command_event(enum event_command cmd, void *data) { -#ifdef HAVE_DISCORD - static bool discord_inited = false; -#endif bool boolean = false; switch (cmd) @@ -2986,26 +2975,24 @@ TODO: Add a setting for these tweaks */ if (!settings->bools.discord_enable) return false; - if (discord_inited) + if (discord_is_ready()) return true; discord_init(); - discord_inited = true; } #endif break; case CMD_EVENT_DISCORD_DEINIT: #ifdef HAVE_DISCORD - if (!discord_inited) + if (!discord_is_ready()) return false; discord_shutdown(); - discord_inited = false; #endif break; case CMD_EVENT_DISCORD_UPDATE: #ifdef HAVE_DISCORD - if (!data || !discord_inited) + if (!data || !discord_is_ready()) return false; { diff --git a/config.def.h b/config.def.h index 59fd0bc2c3..40918b49cb 100644 --- a/config.def.h +++ b/config.def.h @@ -302,6 +302,7 @@ static bool quick_menu_show_save_content_dir_overrides = true; static bool kiosk_mode_enable = false; +static bool menu_horizontal_animation = true; static bool menu_show_online_updater = true; static bool menu_show_load_core = true; static bool menu_show_load_content = true; @@ -400,6 +401,8 @@ static bool default_screenshots_in_content_dir = false; #if defined(__CELLOS_LV2__) || defined(_XBOX1) || defined(_XBOX360) static unsigned menu_toggle_gamepad_combo = INPUT_TOGGLE_L3_R3; +#elif defined(PS2) +static unsigned menu_toggle_gamepad_combo = INPUT_TOGGLE_HOLD_START; #elif defined(VITA) static unsigned menu_toggle_gamepad_combo = INPUT_TOGGLE_L1_R1_START_SELECT; #elif defined(SWITCH) || defined(ORBIS) @@ -804,7 +807,23 @@ static char buildbot_server_url[] = "http://bot.libretro.com/nightly/apple/osx/x static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/apple/osx/ppc/latest/"; #endif #elif defined(_WIN32) && !defined(_XBOX) -#if _MSC_VER == 1600 +#if _MSC_VER >= 1910 +#ifndef __WINRT__ +#if defined(__x86_64__) || defined(_M_X64) +static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2017-desktop/x86_64/latest/"; +#elif defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(_M_IX86) || defined(_M_IA64) +static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2017-desktop/x86/latest/"; +#endif +#else +#if defined(__x86_64__) || defined(_M_X64) +static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2017-uwp/x86_64/latest/"; +#elif defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(_M_IX86) || defined(_M_IA64) +static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2017-uwp/x86/latest/"; +#elif defined(__arm__) || defined(_M_ARM) +static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2017-uwp/arm/latest/"; +#endif +#endif +#elif _MSC_VER == 1600 #if defined(__x86_64__) || defined(_M_X64) static char buildbot_server_url[] = "http://buildbot.libretro.com/nightly/windows-msvc2010/x86_64/latest/"; #elif defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(_M_IX86) || defined(_M_IA64) diff --git a/configuration.c b/configuration.c index 6574177965..56828b39ac 100644 --- a/configuration.c +++ b/configuration.c @@ -56,6 +56,10 @@ #include "record/record_driver.h" +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#include "uwp/uwp_func.h" +#endif + static const char* invalid_filename_chars[] = { /* https://support.microsoft.com/en-us/help/905231/information-about-the-characters-that-you-cannot-use-in-site-names--fo */ "~", "#", "%", "&", "*", "{", "}", "\\", ":", "[", "]", "?", "/", "|", "\'", "\"", @@ -224,6 +228,7 @@ enum input_driver_enum INPUT_WII, INPUT_WIIU, INPUT_XINPUT, + INPUT_UWP, INPUT_UDEV, INPUT_LINUXRAW, INPUT_COCOA, @@ -321,6 +326,13 @@ static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_WII; static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_WIIU; #elif defined(XENON) static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_XENON360; +#elif defined(HAVE_D3D12) && false +/* FIXME: DX12 performance on Xbox is horrible for some reason, so use d3d11 as default */ +static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_D3D12; +#elif defined(HAVE_D3D11) +static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_D3D11; +#elif defined(HAVE_D3D10) +static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_D3D10; #elif defined(HAVE_D3D9) static enum video_driver_enum VIDEO_DEFAULT_DRIVER = VIDEO_D3D9; #elif defined(HAVE_D3D8) @@ -429,7 +441,9 @@ static enum midi_driver_enum MIDI_DEFAULT_DRIVER = MIDI_ALSA; static enum midi_driver_enum MIDI_DEFAULT_DRIVER = MIDI_NULL; #endif -#if defined(XENON) +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +static enum input_driver_enum INPUT_DEFAULT_DRIVER = INPUT_UWP; +#elif defined(XENON) static enum input_driver_enum INPUT_DEFAULT_DRIVER = INPUT_XENON360; #elif defined(_XBOX360) || defined(_XBOX) || defined(HAVE_XINPUT2) || defined(HAVE_XINPUT_XBOX1) static enum input_driver_enum INPUT_DEFAULT_DRIVER = INPUT_XINPUT; @@ -867,6 +881,8 @@ const char *config_get_default_input(void) return "xenon360"; case INPUT_XINPUT: return "xinput"; + case INPUT_UWP: + return "uwp"; case INPUT_WII: return "gx"; case INPUT_WIIU: @@ -958,7 +974,6 @@ const char *config_get_default_joypad(void) return "null"; } - /** * config_get_default_camera: * @@ -1391,11 +1406,11 @@ static struct config_bool_setting *populate_settings_bool(settings_t *settings, #ifdef GEKKO SETTING_BOOL("video_vfilter", &settings->bools.video_vfilter, true, video_vfilter, false); #endif -#ifdef HAVE_MENU - SETTING_BOOL("menu_unified_controls", &settings->bools.menu_unified_controls, true, false, false); #ifdef HAVE_THREADS SETTING_BOOL("threaded_data_runloop_enable", &settings->bools.threaded_data_runloop_enable, true, threaded_data_runloop_enable, false); #endif +#ifdef HAVE_MENU + SETTING_BOOL("menu_unified_controls", &settings->bools.menu_unified_controls, true, false, false); SETTING_BOOL("menu_throttle_framerate", &settings->bools.menu_throttle_framerate, true, true, false); SETTING_BOOL("menu_linear_filter", &settings->bools.menu_linear_filter, true, true, false); SETTING_BOOL("menu_horizontal_animation", &settings->bools.menu_horizontal_animation, true, true, false); @@ -2233,8 +2248,13 @@ static config_file_t *open_default_config_file(void) (void)path_size; -#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) - fill_pathname_application_path(app_path, path_size); +#if defined(_WIN32) && !defined(_XBOX) +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + /* On UWP, the app install directory is not writable so use the writable LocalState dir instead */ + fill_pathname_home_dir(app_path, path_size); +#else + fill_pathname_application_dir(app_path, path_size); +#endif fill_pathname_resolve_relative(conf_path, app_path, file_path_str(FILE_PATH_MAIN_CONFIG), path_size); @@ -2258,7 +2278,6 @@ static config_file_t *open_default_config_file(void) /* Try to create a new config file. */ conf = config_file_new(NULL); - if (conf) { /* Since this is a clean config file, we can @@ -2266,7 +2285,7 @@ static config_file_t *open_default_config_file(void) fill_pathname_resolve_relative(conf_path, app_path, file_path_str(FILE_PATH_MAIN_CONFIG), path_size); config_set_bool(conf, "config_save_on_exit", true); - saved = config_file_write(conf, conf_path); + saved = config_file_write(conf, conf_path, true); } if (!saved) @@ -2302,7 +2321,7 @@ static config_file_t *open_default_config_file(void) if (conf) { config_set_bool(conf, "config_save_on_exit", true); - saved = config_file_write(conf, conf_path); + saved = config_file_write(conf, conf_path, true); } if (!saved) @@ -2377,7 +2396,7 @@ static config_file_t *open_default_config_file(void) { /* Since this is a clean config file, we can safely use config_save_on_exit. */ config_set_bool(conf, "config_save_on_exit", true); - saved = config_file_write(conf, conf_path); + saved = config_file_write(conf, conf_path, true); } if (!saved) @@ -2624,7 +2643,6 @@ static void config_get_hex_base(config_file_t *conf, } #endif - /** * config_load: * @path : path to be read from. @@ -2831,7 +2849,6 @@ static bool config_load_file(const char *path, bool set_defaults, CONFIG_GET_INT_BASE(conf, settings, uints.led_map[i], buf); } - /* Hexadecimal settings */ if (config_get_hex(conf, "video_message_color", &msg_color)) @@ -3015,7 +3032,6 @@ static bool config_load_file(const char *path, bool set_defaults, } } - if (!string_is_empty(settings->paths.directory_screenshot)) { if (string_is_equal(settings->paths.directory_screenshot, "default")) @@ -3082,7 +3098,6 @@ static bool config_load_file(const char *path, bool set_defaults, if (settings->floats.fastforward_ratio < 0.0f) configuration_set_float(settings, settings->floats.fastforward_ratio, 0.0f); - #ifdef HAVE_LAKKA settings->bools.ssh_enable = filestream_exists(LAKKA_SSH_PATH); settings->bools.samba_enable = filestream_exists(LAKKA_SAMBA_PATH); @@ -3178,7 +3193,6 @@ static bool config_load_file(const char *path, bool set_defaults, ret = true; - end: if (conf) config_file_free(conf); @@ -3489,7 +3503,6 @@ bool config_load_remap(void) malloc(PATH_MAX_LENGTH * sizeof(char)); remap_directory[0] = core_path[0] = game_path[0] = '\0'; - strlcpy(remap_directory, settings->paths.directory_input_remapping, path_size); @@ -3556,7 +3569,6 @@ bool config_load_remap(void) input_remapping_set_defaults(false); } - /* Create a new config file from core_path */ new_conf = config_file_new(core_path); @@ -3782,8 +3794,6 @@ static void parse_config_file(void) path_get(RARCH_PATH_CONFIG)); } - - static void save_keybind_key(config_file_t *conf, const char *prefix, const char *base, const struct retro_keybind *bind) { @@ -4037,13 +4047,12 @@ static bool config_save_keybinds_file(const char *path) for (i = 0; i < MAX_USERS; i++) save_keybinds_user(conf, i); - ret = config_file_write(conf, path); + ret = config_file_write(conf, path, true); config_file_free(conf); return ret; } #endif - /** * config_save_autoconf_profile: * @path : Path that shall be written to. @@ -4146,7 +4155,7 @@ bool config_save_autoconf_profile(const char *path, unsigned user) &input_config_binds[user][i], false, false); } - ret = config_file_write(conf, autoconf_file); + ret = config_file_write(conf, autoconf_file, false); config_file_free(conf); free(buf); @@ -4161,7 +4170,6 @@ error: return false; } - /** * config_save_file: * @path : Path that shall be written to. @@ -4369,7 +4377,6 @@ bool config_save_file(const char *path) settings->uints.menu_border_light_color); #endif - video_driver_save_settings(conf); #ifdef HAVE_LAKKA @@ -4396,7 +4403,7 @@ bool config_save_file(const char *path) for (i = 0; i < MAX_USERS; i++) save_keybinds_user(conf, i); - ret = config_file_write(conf, path); + ret = config_file_write(conf, path, true); config_file_free(conf); return ret; @@ -4642,7 +4649,6 @@ bool config_save_overrides(int override_type) config_set_int(conf, cfg, overrides->uints.input_joypad_map[i]); } - /* blacklist these since they are handled by remaps */ /* to-do: add setting to control blacklisting if (settings->uints.input_libretro_device[i] @@ -4668,17 +4674,17 @@ bool config_save_overrides(int override_type) case OVERRIDE_CORE: /* Create a new config file from core_path */ RARCH_LOG ("[overrides] path %s\n", core_path); - ret = config_file_write(conf, core_path); + ret = config_file_write(conf, core_path, true); break; case OVERRIDE_GAME: /* Create a new config file from core_path */ RARCH_LOG ("[overrides] path %s\n", game_path); - ret = config_file_write(conf, game_path); + ret = config_file_write(conf, game_path, true); break; case OVERRIDE_CONTENT_DIR: /* Create a new config file from content_path */ RARCH_LOG ("[overrides] path %s\n", content_path); - ret = config_file_write(conf, content_path); + ret = config_file_write(conf, content_path, true); break; default: break; diff --git a/core_impl.c b/core_impl.c index a8a5acb949..01caeab3a9 100644 --- a/core_impl.c +++ b/core_impl.c @@ -134,7 +134,6 @@ bool core_set_default_callbacks(struct retro_callbacks *cbs) return true; } - bool core_deinit(void *data) { struct retro_callbacks *cbs = (struct retro_callbacks*)data; @@ -402,7 +401,6 @@ bool core_unload(void) return true; } - bool core_unload_game(void) { video_driver_free_hw_context(); diff --git a/core_info.c b/core_info.c index d7ea70ed91..5a33e9f107 100644 --- a/core_info.c +++ b/core_info.c @@ -32,6 +32,10 @@ #include "core_info.h" #include "file_path_special.h" +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#include "uwp/uwp_func.h" +#endif + static const char *core_info_tmp_path = NULL; static const struct string_list *core_info_tmp_list = NULL; static core_info_t *core_info_current = NULL; @@ -232,11 +236,31 @@ static core_info_list_t *core_info_list_new(const char *path, core_info_t *core_info = NULL; core_info_list_t *core_info_list = NULL; const char *path_basedir = libretro_info_dir; - struct string_list *contents = dir_list_new( - path, exts, - false, - show_hidden_files, - false, false); + struct string_list *contents = string_list_new(); + bool ok; + + ok = dir_list_append(contents, path, exts, + false, show_hidden_files, false, false); + +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + /* UWP: browse the optional packages for additional cores */ + struct string_list *core_packages = string_list_new(); + uwp_fill_installed_core_packages(core_packages); + for (i = 0; i < core_packages->size; i++) + { + dir_list_append(contents, core_packages->elems[i].data, exts, + false, show_hidden_files, false, false); + } + string_list_free(core_packages); +#else + /* Keep the old 'directory not found' behavior */ + if (!ok) + { + string_list_free(contents); + contents = NULL; + } +#endif + if (!contents) return NULL; @@ -430,12 +454,12 @@ static core_info_list_t *core_info_list_new(const char *path, core_info_list_resolve_all_firmware(core_info_list); } - dir_list_free(contents); + string_list_free(contents); return core_info_list; error: if (contents) - dir_list_free(contents); + string_list_free(contents); core_info_list_free(core_info_list); return NULL; } diff --git a/core_type.h b/core_type.h index e8933de6bd..40b2d8b16e 100644 --- a/core_type.h +++ b/core_type.h @@ -24,7 +24,8 @@ enum rarch_core_type CORE_TYPE_MPV, CORE_TYPE_IMAGEVIEWER, CORE_TYPE_NETRETROPAD, - CORE_TYPE_VIDEO_PROCESSOR + CORE_TYPE_VIDEO_PROCESSOR, + CORE_TYPE_GONG }; #endif diff --git a/cores/dynamic_dummy.c b/cores/dynamic_dummy.c index 21b8014a85..5859451b50 100644 --- a/cores/dynamic_dummy.c +++ b/cores/dynamic_dummy.c @@ -224,4 +224,3 @@ void libretro_dummy_retro_cheat_set(unsigned idx, (void)code; } - diff --git a/cores/internal_cores.h b/cores/internal_cores.h index 08e916d63e..ff20a5180a 100644 --- a/cores/internal_cores.h +++ b/cores/internal_cores.h @@ -360,6 +360,62 @@ size_t libretro_videoprocessor_retro_get_memory_size(unsigned id); #endif +#ifdef HAVE_EASTEREGG +/* Internal gong core. */ + +void libretro_gong_retro_init(void); + +void libretro_gong_retro_deinit(void); + +unsigned libretro_gong_retro_api_version(void); + +void libretro_gong_retro_get_system_info(struct retro_system_info *info); + +void libretro_gong_retro_get_system_av_info(struct retro_system_av_info *info); + +void libretro_gong_retro_set_environment(retro_environment_t cb); + +void libretro_gong_retro_set_video_refresh(retro_video_refresh_t cb); + +void libretro_gong_retro_set_audio_sample(retro_audio_sample_t cb); + +void libretro_gong_retro_set_audio_sample_batch(retro_audio_sample_batch_t cb); + +void libretro_gong_retro_set_input_poll(retro_input_poll_t cb); + +void libretro_gong_retro_set_input_state(retro_input_state_t cb); + +void libretro_gong_retro_set_controller_port_device(unsigned port, unsigned device); + +void libretro_gong_retro_reset(void); + +void libretro_gong_retro_run(void); + +size_t libretro_gong_retro_serialize_size(void); + +bool libretro_gong_retro_serialize(void *data, size_t size); + +bool libretro_gong_retro_unserialize(const void *data, size_t size); + +void libretro_gong_retro_cheat_reset(void); + +void libretro_gong_retro_cheat_set(unsigned index, bool enabled, const char *code); + +bool libretro_gong_retro_load_game(const struct retro_game_info *game); + +bool libretro_gong_retro_load_game_special(unsigned game_type, + const struct retro_game_info *info, size_t num_info); + +void libretro_gong_retro_unload_game(void); + +unsigned libretro_gong_retro_get_region(void); + +void *libretro_gong_retro_get_memory_data(unsigned id); + +size_t libretro_gong_retro_get_memory_size(unsigned id); + +#endif + RETRO_END_DECLS #endif diff --git a/cores/libretro-ffmpeg/Makefile b/cores/libretro-ffmpeg/Makefile index 6971ec6586..69ac5f0d7f 100644 --- a/cores/libretro-ffmpeg/Makefile +++ b/cores/libretro-ffmpeg/Makefile @@ -195,7 +195,7 @@ CFLAGS += -D__LIBRETRO__ include Makefile.common -CFLAGS += $(DEFINES) $(INCFLAGS) $(GLFLAGS) +CFLAGS += $(DEFINES) $(INCFLAGS) $(GLFLAGS) $(DEF_FLAGS) CFLAGS += -Wall $(fpic) ifeq ($(DEBUG), 1) diff --git a/cores/libretro-ffmpeg/Makefile.common b/cores/libretro-ffmpeg/Makefile.common index 6a71b58fe3..15b62b40e2 100644 --- a/cores/libretro-ffmpeg/Makefile.common +++ b/cores/libretro-ffmpeg/Makefile.common @@ -16,7 +16,6 @@ AVUTIL_DIR := $(BASE_DIR)/libavutil SWSCALE_DIR := $(BASE_DIR)/libswscale SWRESAMPLE_DIR := $(BASE_DIR)/libswresample - INCFLAGS += -I$(BASE_DIR) -I$(CORE_DIR) -I$(LIBRETRO_COMM_DIR)/include -I$(LIBRETRO_COMM_DIR)/include/compat LIBRETRO_SOURCE += $(CORE_DIR)/ffmpeg_core.c \ diff --git a/cores/libretro-ffmpeg/Makefile.ffmpeg b/cores/libretro-ffmpeg/Makefile.ffmpeg index 2ed09c31dd..c319cb8d26 100644 --- a/cores/libretro-ffmpeg/Makefile.ffmpeg +++ b/cores/libretro-ffmpeg/Makefile.ffmpeg @@ -134,7 +134,6 @@ endif LIBS += -lm - ifeq ($(HAVE_NEON),1) DEFINES += -DHAVE_NEON=1 else @@ -163,7 +162,6 @@ CPUOPTS += -DARCH_BFIN=0 #We can reasonably assume MMX will be there on all x86 CPUs from 1997 and up at least #SSE2 can be assumed from Pentium 4 and up - can be switched on or off with the switch HAVE_SSE2 - ifeq ($(ARCH_X86),1) CPUOPTS += -DHAVE_AMD3DNOW_INLINE=0 CPUOPTS += -DHAVE_AMD3DNOWEXT_EXTERNAL=0 @@ -756,7 +754,6 @@ else DEFINES += -DCONFIG_LIBSPEEX_ENCODER=0 endif - ifeq ($(HAVE_LIBOPUS),1) DEFINES += -DCONFIG_LIBOPUS_ENCODER=1 \ -DCONFIG_OPUS_PARSER=1 \ @@ -1265,7 +1262,6 @@ DEFINES += -DCONFIG_LIBOPUS_DECODER=0 DEFINES += -DCONFIG_OPUS_MUXER=0 endif - #libavutil ifeq ($(INTERNAL_LIBAVUTIL),1) DEFINES += -DHAVE_AV_CONFIG_H @@ -1336,7 +1332,6 @@ ifeq ($(ARCH_ARM),1) LIBAVUTIL_SOURCE += $(filter-out $(AVUTIL_BLACKLIST),$(wildcard $(AVUTIL_DIR)/arm/*.c)) endif - ifeq ($(ARCH_PPC),1) LIBAVUTIL_SOURCE += $(AVUTIL_DIR)/ppc/cpu.c \ $(AVUTIL_DIR)/ppc/float_dsp_init.c @@ -1468,7 +1463,6 @@ else DEFINES += -DCONFIG_XVMC=0 endif - AVCODEC_BLACKLIST := \ $(AVCODEC_DIR)/arm/neontest.c \ $(AVCODEC_DIR)/vda.c \ diff --git a/cores/libretro-ffmpeg/ffmpeg_core.c b/cores/libretro-ffmpeg/ffmpeg_core.c index d5c66667da..3a117c8566 100644 --- a/cores/libretro-ffmpeg/ffmpeg_core.c +++ b/cores/libretro-ffmpeg/ffmpeg_core.c @@ -693,7 +693,6 @@ void CORE_PREFIX(retro_run)(void) glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D, frames[0].tex); - glBindBuffer(GL_ARRAY_BUFFER, vbo); glVertexAttribPointer(vertex_loc, 2, GL_FLOAT, GL_FALSE, 4 * sizeof(GLfloat), (const GLvoid*)(0 * sizeof(GLfloat))); @@ -1664,7 +1663,6 @@ error: return false; } - unsigned CORE_PREFIX(retro_get_region)(void) { return RETRO_REGION_NTSC; diff --git a/cores/libretro-gong/gong.c b/cores/libretro-gong/gong.c new file mode 100644 index 0000000000..8c354e460e --- /dev/null +++ b/cores/libretro-gong/gong.c @@ -0,0 +1,696 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2014 - Hans-Kristian Arntzen + * Copyright (C) 2011-2017 - Daniel De Matteis + * Copyright (C) 2018 - Brad Parker + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +/* Libretro port by Brad Parker, + Original source code by Dan Zaidan: https://danzaidan.itch.io/ + Original license: + "You can do whatever you want with the code, but I am providing it as is without any warranty whatsoever." + */ + +#include +#include +#include +#include + +#ifdef RARCH_INTERNAL +#include "internal_cores.h" +#define GONG_CORE_PREFIX(s) libretro_gong_##s +#else +#define GONG_CORE_PREFIX(s) s +#endif + +#define WIDTH 356 +#define HEIGHT 200 +#define FPS (60000.0f / 1000.0f) + +static retro_log_printf_t GONG_CORE_PREFIX(log_cb); +static retro_video_refresh_t GONG_CORE_PREFIX(video_cb); +static retro_input_poll_t GONG_CORE_PREFIX(input_poll_cb); +static retro_input_state_t GONG_CORE_PREFIX(input_state_cb); +static retro_audio_sample_t GONG_CORE_PREFIX(audio_cb); +static retro_audio_sample_batch_t GONG_CORE_PREFIX(audio_batch_cb); +static retro_environment_t GONG_CORE_PREFIX(environ_cb); + +static const char *GONG_CORE_PREFIX(valid_extensions) = "gong"; + +static float player1_py = 0.0f; +static float player1_dpy = 0.0f; +static float player2_py = 0.0f; +static float player2_dpy = 0.0f; +static float player2_speed = 0.0f; +static float ball_px = 0.0f; +static float ball_py = 0.0f; +static float ball_dpx = 0.0f; +static float ball_dpy = 0.0f; +static float ball_speed = 0.0f; +static bool is_initialized = 0; +static unsigned player1_score = 0; +static unsigned player2_score = 0; +static float current_play_points = 0.0f; + +static unsigned char *video_buf = NULL; + +enum +{ + B_MOVE_UP, + B_MOVE_DOWN, + B_SPEED_UP, + B_COUNT /* This should always be in the bottom */ +}; + +typedef struct +{ + int half_transition_count; + bool ended_down; +} Game_Button_State; + +typedef struct +{ + Game_Button_State buttons[B_COUNT]; + float last_dt; +} Game_Input; + +static Game_Input g_input = {0}; + +typedef struct +{ + /* Pixels are always 32-bit wide, memory order XX BB GG RR */ + int width; + int height; + int pitch; + void *memory; +} Game_Offscreen_Buffer; + +static Game_Offscreen_Buffer game_buffer = {0}; + +static void game_update_and_render(Game_Input *input, Game_Offscreen_Buffer *draw_buffer); + +static const struct retro_controller_description pads[] = { + { "Joypad", RETRO_DEVICE_JOYPAD }, + { NULL, 0 }, +}; + +static const struct retro_controller_info ports[] = { + { pads, 1 }, + { 0 }, +}; + +struct retro_input_descriptor desc[] = { + { 0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_UP, "D-Pad Up" }, + { 0, RETRO_DEVICE_JOYPAD, 0, RETRO_DEVICE_ID_JOYPAD_DOWN, "D-Pad Down" }, + { 0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_LEFT, RETRO_DEVICE_ID_ANALOG_Y, "Left Analog Y" }, + { 0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_RIGHT, RETRO_DEVICE_ID_ANALOG_Y, "Right Analog Y" }, + + { 0 }, +}; + +static INLINE bool pressed(Game_Button_State state) +{ + return state.half_transition_count > 1 || + (state.half_transition_count == 1 && state.ended_down); +} + +static INLINE bool is_down(Game_Button_State state) +{ + return state.ended_down; +} + +void GONG_CORE_PREFIX(retro_get_system_info)(struct retro_system_info *info) +{ + info->library_name = "gong"; + info->library_version = "v1.0"; + info->need_fullpath = false; + info->block_extract = false; + info->valid_extensions = GONG_CORE_PREFIX(valid_extensions); +} + +void GONG_CORE_PREFIX(retro_get_system_av_info)(struct retro_system_av_info *info) +{ + info->geometry.base_width = WIDTH; + info->geometry.base_height = HEIGHT; + info->geometry.max_width = WIDTH; + info->geometry.max_height = HEIGHT; + info->geometry.aspect_ratio = 16.0f / 9.0f; + info->timing.fps = FPS; + info->timing.sample_rate = 44100.0; +} + +void GONG_CORE_PREFIX(retro_init)(void) +{ + struct retro_log_callback log; + + if (GONG_CORE_PREFIX(environ_cb)(RETRO_ENVIRONMENT_GET_LOG_INTERFACE, &log)) + GONG_CORE_PREFIX(log_cb) = log.log; + else + GONG_CORE_PREFIX(log_cb) = NULL; + + video_buf = (unsigned char*)calloc(1, WIDTH * HEIGHT * sizeof(unsigned)); + + game_buffer.width = WIDTH; + game_buffer.height = HEIGHT; + game_buffer.pitch = WIDTH * sizeof(unsigned); + game_buffer.memory = video_buf; + + g_input.last_dt = 1.0f / FPS; +} + +void GONG_CORE_PREFIX(retro_deinit)(void) +{ + if (video_buf) + free(video_buf); + + video_buf = NULL; + game_buffer.memory = NULL; +} + +void GONG_CORE_PREFIX(retro_set_environment)(retro_environment_t cb) +{ + bool no_content = true; + + static const struct retro_variable vars[] = { + { NULL, NULL }, + }; + + GONG_CORE_PREFIX(environ_cb) = cb; + + cb(RETRO_ENVIRONMENT_SET_SUPPORT_NO_GAME, &no_content); + cb(RETRO_ENVIRONMENT_SET_VARIABLES, (void*)vars); + cb(RETRO_ENVIRONMENT_SET_CONTROLLER_INFO, (void*)ports); +} + +void GONG_CORE_PREFIX(retro_set_video_refresh)(retro_video_refresh_t cb) +{ + GONG_CORE_PREFIX(video_cb) = cb; +} + +void GONG_CORE_PREFIX(retro_set_audio_sample)(retro_audio_sample_t cb) +{ + GONG_CORE_PREFIX(audio_cb) = cb; +} + +void GONG_CORE_PREFIX(retro_set_audio_sample_batch)(retro_audio_sample_batch_t cb) +{ + GONG_CORE_PREFIX(audio_batch_cb) = cb; +} + +void GONG_CORE_PREFIX(retro_set_input_poll)(retro_input_poll_t cb) +{ + GONG_CORE_PREFIX(input_poll_cb) = cb; +} + +void GONG_CORE_PREFIX(retro_set_input_state)(retro_input_state_t cb) +{ + GONG_CORE_PREFIX(input_state_cb) = cb; +} + +void GONG_CORE_PREFIX(retro_set_controller_port_device)(unsigned a, unsigned b) +{ +} + +void GONG_CORE_PREFIX(retro_reset)(void) +{ + player1_py = 0.0f; + player1_dpy = 0.0f; + player2_py = 0.0f; + player2_dpy = 0.0f; + player2_speed = 0.0f; + player1_score = 0; + player2_score = 0; + is_initialized = 0; +} + +size_t GONG_CORE_PREFIX(retro_serialize_size)(void) +{ + return 0; +} + +bool GONG_CORE_PREFIX(retro_serialize)(void *data, size_t size) +{ + (void)data; + (void)size; + return false; +} + +bool GONG_CORE_PREFIX(retro_unserialize)(const void *data, size_t size) +{ + (void)data; + (void)size; + return false; +} + +void GONG_CORE_PREFIX(retro_cheat_reset)(void) +{ +} + +void GONG_CORE_PREFIX(retro_cheat_set)(unsigned a, bool b, const char * c) +{ +} + +bool GONG_CORE_PREFIX(retro_load_game)(const struct retro_game_info *info) +{ + enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_XRGB8888; + + if (!GONG_CORE_PREFIX(environ_cb)(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt)) + { + if (GONG_CORE_PREFIX(log_cb)) + GONG_CORE_PREFIX(log_cb)(RETRO_LOG_INFO, "XRGB8888 is not supported.\n"); + return false; + } + + return true; +} + +bool GONG_CORE_PREFIX(retro_load_game_special)(unsigned a, const struct retro_game_info *b, size_t c) +{ + return false; +} + +void GONG_CORE_PREFIX(retro_unload_game)(void) +{ +} + +unsigned GONG_CORE_PREFIX(retro_get_region)(void) +{ + return RETRO_REGION_NTSC; +} + +void* GONG_CORE_PREFIX(retro_get_memory_data)(unsigned id) +{ + return NULL; +} + +size_t GONG_CORE_PREFIX(retro_get_memory_size)(unsigned id) +{ + return 0; +} + +static void process_joypad(Game_Button_State *new_state, bool is_down) +{ + if (new_state->ended_down != is_down) + { + new_state->ended_down = is_down; + new_state->half_transition_count += 1; + } +} + +static bool is_key_up_or_down(int16_t input, int16_t not_input, int key) +{ + if (input & (1 << key) || not_input & (1 << key)) + return true; + + return false; +} + +void GONG_CORE_PREFIX(retro_run)(void) +{ + uint16_t input = 0; + uint16_t not_input = 0; + static uint16_t previnput = 0; + uint16_t realinput = 0; + int i = 0; + int16_t analogYLeft1 = 0; + int16_t analogYRight1 = 0; + + GONG_CORE_PREFIX(input_poll_cb)(); + + for (i = 0; i < 16; i++) + { + if (GONG_CORE_PREFIX(input_state_cb)(0, RETRO_DEVICE_JOYPAD, 0, i)) + { + realinput |= 1 << i; + } + } + + analogYLeft1 = GONG_CORE_PREFIX(input_state_cb)(0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_LEFT, RETRO_DEVICE_ID_ANALOG_Y) / 5000.0f; + analogYRight1 = GONG_CORE_PREFIX(input_state_cb)(0, RETRO_DEVICE_ANALOG, RETRO_DEVICE_INDEX_ANALOG_RIGHT, RETRO_DEVICE_ID_ANALOG_Y) / 5000.0f; + + if (analogYLeft1 > 0) + realinput |= (1 << RETRO_DEVICE_ID_JOYPAD_DOWN); + else if (analogYRight1 > 0) + realinput |= (1 << RETRO_DEVICE_ID_JOYPAD_DOWN); + + if (analogYLeft1 < 0) + realinput |= (1 << RETRO_DEVICE_ID_JOYPAD_UP); + else if (analogYRight1 < 0) + realinput |= (1 << RETRO_DEVICE_ID_JOYPAD_UP); + + input = realinput & ~previnput; + not_input = previnput & ~realinput; + + if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_UP)) + process_joypad(&g_input.buttons[B_MOVE_UP], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_UP)); + else if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_DOWN)) + process_joypad(&g_input.buttons[B_MOVE_DOWN], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_DOWN)); + else if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_DOWN)) + process_joypad(&g_input.buttons[B_MOVE_DOWN], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_DOWN)); + + if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_A)) + process_joypad(&g_input.buttons[B_SPEED_UP], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_A)); + else if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_B)) + process_joypad(&g_input.buttons[B_SPEED_UP], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_B)); + else if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_X)) + process_joypad(&g_input.buttons[B_SPEED_UP], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_X)); + else if (is_key_up_or_down(input, not_input, RETRO_DEVICE_ID_JOYPAD_Y)) + process_joypad(&g_input.buttons[B_SPEED_UP], realinput & (1 << RETRO_DEVICE_ID_JOYPAD_Y)); + + previnput = realinput; + + game_update_and_render(&g_input, &game_buffer); + + GONG_CORE_PREFIX(video_cb)(video_buf, WIDTH, HEIGHT, WIDTH * sizeof(uint32_t)); +} + +unsigned GONG_CORE_PREFIX(retro_api_version)(void) +{ + return RETRO_API_VERSION; +} + +static void draw_rect_in_pixels(Game_Offscreen_Buffer *buffer, unsigned color, int min_x, int min_y, int max_x, int max_y) +{ + int y; + + min_x = MAX(min_x, 0); + min_y = MAX(min_y, 0); + max_x = MIN(max_x, buffer->width); + max_y = MIN(max_y, buffer->height); + + for (y = min_y; y < max_y; y++) + { + int x; + + for (x = min_x; x < max_x; x++) + { + unsigned *pixel = (unsigned*)((unsigned char*)buffer->memory + ((buffer->width * (buffer->height - y - 1) + x) * sizeof(unsigned))); + + *pixel++ = color; + } + } +} + +static void clear(Game_Offscreen_Buffer *buffer, unsigned color) +{ + draw_rect_in_pixels(buffer, color, 0, 0, buffer->width, buffer->height); +} + +static void draw_rect(Game_Offscreen_Buffer *buffer, unsigned color, float x, float y, float half_size_x, float half_size_y) +{ + /* @Hardcoded to always keep the playing field area on screen, no matter the aspect ratio */ + float scale = .01f; + float relative_axis = (float)buffer->height; + int min_x, min_y, max_x, max_y; + + if ((float)buffer->width / (float)buffer->height < 1.77f) + { + relative_axis = (float)buffer->width; + scale = .0056f; + } + + half_size_x *= relative_axis * scale; + half_size_y *= relative_axis * scale; + x *= relative_axis * scale; + y *= relative_axis * scale; + + x = x + buffer->width / 2; + y = y + buffer->height / 2; + + min_x = (unsigned)(x - half_size_x); + min_y = (unsigned)(y - half_size_y); + max_x = (unsigned)(x + half_size_x); + max_y = (unsigned)(y + half_size_y); + + draw_rect_in_pixels(buffer, color, min_x, min_y, max_x, max_y); +} + +static void draw_number(Game_Offscreen_Buffer *buffer, unsigned number, unsigned color, float x, float y) +{ + float at_x = x; + + do { + unsigned alg = number % 10; + + number /= 10; + + switch (alg) + { + case 0: + { + draw_rect(buffer, color, at_x - 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + } + + case 1: + { + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.5f); + break; + } + + case 2: + { + draw_rect(buffer, color, at_x - 2.f, y - 2.f, .5f, 2.f); + draw_rect(buffer, color, at_x + 2.f, y + 2.f, .5f, 2.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + } + + case 3: + { + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + }; + + case 4: + { + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.5f); + draw_rect(buffer, color, at_x - 2.f, y+2.5f, .5f, 2.f); + break; + }; + + case 5: + { + draw_rect(buffer, color, at_x + 2.f, y-2.f, .5f, 2.f); + draw_rect(buffer, color, at_x - 2.f, y+2.f, .5f, 2.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + }; + + case 6: + { + draw_rect(buffer, color, at_x + 2.f, y-2.f, .5f, 2.f); + draw_rect(buffer, color, at_x - 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + }; + + case 7: + { + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.5f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + break; + }; + + case 8: + { + draw_rect(buffer, color, at_x - 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + break; + }; + + case 9: + { + draw_rect(buffer, color, at_x - 2.f, y + 2.f, .5f, 2.f); + draw_rect(buffer, color, at_x + 2.f, y, .5f, 4.f); + draw_rect(buffer, color, at_x, y + 4.f, 2.5f, .5f); + draw_rect(buffer, color, at_x, y, 2.5f, .5f); + draw_rect(buffer, color, at_x, y - 4.f, 2.5f, .5f); + break; + }; + + default: + break; + } + + at_x -= 7.f; + } while(number > 0); +} + +static void game_update_and_render(Game_Input *input, Game_Offscreen_Buffer *draw_buffer) +{ + const float initial_ball_speed = 80.f; + float playing_field_x = 85.f; + float playing_field_y = 48.f; + float player_size_x = 2.5f; + float player_size_y = 10.f; + + if (!is_initialized) + { + is_initialized = 1; + ball_px = 0; + ball_py = 0; + ball_dpx = initial_ball_speed; + ball_dpy = 0; + current_play_points = 10.f; + player2_speed = 80.f; + } + + { + float speed = 80.f; + player1_dpy = 0.f; + + if (is_down(input->buttons[B_SPEED_UP])) + speed = 150.f; + + if (is_down(input->buttons[B_MOVE_UP])) + { + if (player1_py < playing_field_y - player_size_y) + { + player1_dpy = speed; + } + + if (player1_py < -playing_field_y + player_size_y) + { + player1_py = -playing_field_y + player_size_y; + player1_dpy = 0.f; + } + } + if (is_down(input->buttons[B_MOVE_DOWN])) + { + if (player1_py > -playing_field_y + player_size_y) + { + player1_dpy = -speed; + } + + if (player1_py < -playing_field_y + player_size_y) + { + player1_py = -playing_field_y + player_size_y; + player1_dpy = 0.f; + } + } + + player1_py += player1_dpy * input->last_dt; + } + + { + player2_dpy = (ball_py - player2_py) * 100.f; + player2_dpy = MIN(player2_dpy, player2_speed); + player2_dpy = MAX(player2_dpy, -player2_speed); + player2_py += player2_dpy * input->last_dt; + + if (player2_py < -playing_field_y + player_size_y) + { + player2_py = -playing_field_y + player_size_y; + player2_dpy = 0.f; + } + + if (player2_py > playing_field_y - player_size_y) + { + player2_py = playing_field_y - player_size_y; + player2_dpy = 0.f; + } + } + + ball_px += ball_dpx * input->last_dt; + + if (ball_dpx > 0) + { + ball_dpx += 10.f * input->last_dt; + } + else + { + ball_dpx -= 10.f * input->last_dt; + } + + ball_py += ball_dpy * input->last_dt; + + if (ball_py > playing_field_y - 1.f) + { + ball_py = playing_field_y - 1.f; + ball_dpy *= -1.f; + } + else if (ball_py < -playing_field_y + 1) + { + ball_py = -playing_field_y + 1.f; + ball_dpy *= -1; + } + + if (ball_px > 80.f - 2.5f - 1.f) /* @Hardcoded */ + { + if ((ball_py >= (player2_py - 10.f)) && (ball_py <= (player2_py + 10.f))) + { + ball_dpx *= -1.f; + ball_px = 80.f - 2.5f - 1.f; /* @Hardcoded */ + ball_dpy = (ball_py - player2_py) + player2_dpy; + ++current_play_points; + } + else if (ball_px >= playing_field_x - 1) + { + ball_px = 0; + ball_py = 0; + ball_dpy = 0; + ball_dpx = -initial_ball_speed; + player2_score += (unsigned)current_play_points; + current_play_points = 10.f; + } + } + else if (ball_px < -80 + 2.5f + 1.f) /* @Hardcoded */ + { + if ((ball_py >= (player1_py - 10.f)) && (ball_py <= (player1_py + 10.f))) + { + ball_dpx *= -1.f; + ball_px = -80 + 2.5f + 1.f; /* @Hardcoded */ + ball_dpy = (ball_py - player1_py) + player1_dpy; + ++current_play_points; + } + else if (ball_px <= -playing_field_x + 1) + { + ball_px = 0; + ball_py = 0; + ball_dpy = 0; + ball_dpx = initial_ball_speed; + player1_score += (unsigned)current_play_points; + current_play_points = 10.f; + player2_speed += current_play_points * 0.01f; + } + } + + clear(draw_buffer, 0x021077); + draw_rect(draw_buffer, 0x000530, 0.f, 0.f, playing_field_x, playing_field_y); + + draw_rect(draw_buffer, 0x00ffff, -80.f, player1_py, player_size_x, player_size_y); + draw_rect(draw_buffer, 0x00ffff, 80.f, player2_py, player_size_x, player_size_y); + + draw_rect(draw_buffer, 0xffff00, ball_px, ball_py, 1.f, 1.f); + + draw_number(draw_buffer, (unsigned)current_play_points, 0xaaaaaa, 0.f, 38.f); + draw_number(draw_buffer, player1_score, 0xff6611, 20.f, 38.f); + draw_number(draw_buffer, player2_score, 0xff6611, -20.f, 38.f); +} diff --git a/cores/libretro-gong/internal_cores.h b/cores/libretro-gong/internal_cores.h new file mode 100644 index 0000000000..7e1a2aab98 --- /dev/null +++ b/cores/libretro-gong/internal_cores.h @@ -0,0 +1 @@ +#include "../internal_cores.h" diff --git a/cores/libretro-gong/link.T b/cores/libretro-gong/link.T new file mode 100644 index 0000000000..b0c262db9e --- /dev/null +++ b/cores/libretro-gong/link.T @@ -0,0 +1,5 @@ +{ + global: retro_*; + local: *; +}; + diff --git a/cores/libretro-imageviewer/image_core.c b/cores/libretro-imageviewer/image_core.c index 761ffe5ecf..3150b13b81 100644 --- a/cores/libretro-imageviewer/image_core.c +++ b/cores/libretro-imageviewer/image_core.c @@ -275,7 +275,6 @@ static bool imageviewer_load(const char *path, int image_index) process_new_image = true; - return true; } @@ -293,7 +292,6 @@ bool IMAGE_CORE_PREFIX(retro_load_game)(const struct retro_game_info *info) dir_list_sort(file_list, false); free(dir); - if (!IMAGE_CORE_PREFIX(environ_cb)(RETRO_ENVIRONMENT_SET_PIXEL_FORMAT, &fmt)) { if (IMAGE_CORE_PREFIX(log_cb)) @@ -312,7 +310,6 @@ bool IMAGE_CORE_PREFIX(retro_load_game_special)(unsigned a, const struct retro_g return false; } - void IMAGE_CORE_PREFIX(retro_unload_game)(void) { imageviewer_free_image(); @@ -335,7 +332,6 @@ size_t IMAGE_CORE_PREFIX(retro_get_memory_size)(unsigned id) return 0; } - void IMAGE_CORE_PREFIX(retro_run)(void) { bool first_image = false; diff --git a/cores/libretro-net-retropad/Makefile b/cores/libretro-net-retropad/Makefile index fc620c28be..909c572c3f 100644 --- a/cores/libretro-net-retropad/Makefile +++ b/cores/libretro-net-retropad/Makefile @@ -103,7 +103,6 @@ else SHARED := -shared -static-libgcc -static-libstdc++ -s -Wl,--version-script=link.T -Wl,--no-undefined endif - LDFLAGS += $(LIBM) ifeq ($(platform), win) diff --git a/cores/libretro-net-retropad/net_retropad_core.c b/cores/libretro-net-retropad/net_retropad_core.c index 4962367861..bedf072ad0 100644 --- a/cores/libretro-net-retropad/net_retropad_core.c +++ b/cores/libretro-net-retropad/net_retropad_core.c @@ -276,7 +276,6 @@ void NETRETROPAD_CORE_PREFIX(retro_set_environment)(retro_environment_t cb) enum retro_pixel_format fmt = RETRO_PIXEL_FORMAT_RGB565; cb(RETRO_ENVIRONMENT_SET_VARIABLES, (void*)vars); - NETRETROPAD_CORE_PREFIX(environ_cb) = cb; bool no_content = true; cb(RETRO_ENVIRONMENT_SET_SUPPORT_NO_GAME, &no_content); @@ -379,7 +378,6 @@ void NETRETROPAD_CORE_PREFIX(retro_run)(void) pixel += 65; } - NETRETROPAD_CORE_PREFIX(video_cb)(frame_buf, 320, 240, 640); retro_sleep(4); diff --git a/cores/libretro-video-processor/video_processor_v4l2.c b/cores/libretro-video-processor/video_processor_v4l2.c index 15cbe0d02b..1d9012c11c 100644 --- a/cores/libretro-video-processor/video_processor_v4l2.c +++ b/cores/libretro-video-processor/video_processor_v4l2.c @@ -102,7 +102,6 @@ static uint32_t *frame_prev2; static uint32_t *frame_prev3; static uint32_t *frame_curr; - // Frametime debug messages struct timeval ft_prevtime = { 0 }, ft_prevtime2 = { 0 }; char *ft_info = NULL, *ft_info2 = NULL; @@ -660,7 +659,6 @@ void source_v4l2_normal(int width, int height) { v4l2_frame_times(bufcp); } - void source_v4l2_alternate_hack(int width, int height) { struct v4l2_buffer bufcp; struct v4l2_format fmt; diff --git a/ctr/ctr_linear.cpp b/ctr/ctr_linear.cpp index 86b56301f6..8a6e661553 100644 --- a/ctr/ctr_linear.cpp +++ b/ctr/ctr_linear.cpp @@ -1,7 +1,6 @@ /* from https://github.com/smealum/ctrulib * modified to allow reducing __linear_heap_size at runtime */ - #include <3ds.h> #include #include <3ds/util/rbtree.h> @@ -245,7 +244,6 @@ extern "C" u32 ctr_get_linear_unused(void) return __linear_heap + __linear_heap_size - sLinearPool_maxaddr; } - extern "C" void ctr_linear_free_pages(u32 pages) { if(sLinearPool.last->base + sLinearPool.last->size != (u8*)__linear_heap + __linear_heap_size) diff --git a/ctr/ctr_svchax.c b/ctr/ctr_svchax.c index b02fccf1d4..eb32183a36 100644 --- a/ctr/ctr_svchax.c +++ b/ctr/ctr_svchax.c @@ -379,7 +379,6 @@ static void do_memchunkhax2(void) APT_SetAppCpuTimeLimit(mch2.old_cpu_time_limit); } - static void gspwn(u32 dst, u32 src, u32 size, u8* flush_buffer) { extern Handle gspEvents[GSPGPU_EVENT_MAX]; diff --git a/ctr/ctr_system.c b/ctr/ctr_system.c index 9126ba009e..ba898c4ac7 100644 --- a/ctr/ctr_system.c +++ b/ctr/ctr_system.c @@ -93,7 +93,6 @@ void __attribute__((weak)) __libctru_init(void (*retAddr)(void)) __system_allocateHeaps(); } - Result __sync_fini(void) __attribute__((weak)); extern char** __system_argv; @@ -299,7 +298,6 @@ void wait_for_input(void) } } - long sysconf(int name) { switch (name) diff --git a/ctr/exec-3dsx/exec_3dsx.c b/ctr/exec-3dsx/exec_3dsx.c index 7de5b374e6..cdc95852b2 100644 --- a/ctr/exec-3dsx/exec_3dsx.c +++ b/ctr/exec-3dsx/exec_3dsx.c @@ -5,14 +5,12 @@ #include "mini-hb-menu/common.h" - extern const loaderFuncs_s loader_Ninjhax1; extern const loaderFuncs_s loader_Ninjhax2; extern const loaderFuncs_s loader_Rosalina; static void (*launch_3dsx)(const char* path, argData_s* args, executableMetadata_s* em); - static int exec_3dsx_actual(const char* path, const char** args, bool appendPath){ struct stat sBuff; argData_s newProgramArgs; diff --git a/ctr/exec-3dsx/exec_cia.c b/ctr/exec-3dsx/exec_cia.c index 7c4c19551d..79c7a537a5 100644 --- a/ctr/exec-3dsx/exec_cia.c +++ b/ctr/exec-3dsx/exec_cia.c @@ -4,16 +4,13 @@ #include #include <3ds.h> - #define FILE_CHUNK_SIZE 4096 - typedef struct{ u32 argc; char args[0x300 - 0x4]; }ciaParam; - char argvHmac[0x20] = {0x1d, 0x78, 0xff, 0xb9, 0xc5, 0xbc, 0x78, 0xb7, 0xac, 0x29, 0x1d, 0x3e, 0x16, 0xd0, 0xcf, 0x53, 0xef, 0x12, 0x58, 0x83, 0xb6, 0x9e, 0x2f, 0x79, 0x47, 0xf9, 0x35, 0x61, 0xeb, 0x50, 0xd7, 0x67}; diff --git a/ctr/gpu_old.c b/ctr/gpu_old.c index b8e117e685..b9c2b86d74 100644 --- a/ctr/gpu_old.c +++ b/ctr/gpu_old.c @@ -35,7 +35,6 @@ void GPU_SetFloatUniform(GPU_SHADER_TYPE type, u32 startreg, u32* data, u32 numr GPUCMD_AddWrites(GPUREG_VSH_FLOATUNIFORM_DATA+regOffset, data, numreg*4); } - //takes PAs as arguments void GPU_SetViewport(u32* depthBuffer, u32* colorBuffer, u32 x, u32 y, u32 w, u32 h) { @@ -307,7 +306,6 @@ void GPU_FinishDrawing() GPUCMD_AddWrite(GPUREG_EARLYDEPTH_CLEAR, 0x00000001); } - void GPU_Finalize(void) { GPUCMD_AddMaskedWrite(GPUREG_PRIMITIVE_CONFIG, 0x8, 0x00000000); diff --git a/database_info.c b/database_info.c index 96da1c48a9..36ea9049b8 100644 --- a/database_info.c +++ b/database_info.c @@ -148,7 +148,6 @@ char *bin_to_hex_alloc(const uint8_t *data, size_t len) return ret; } - static int database_cursor_iterate(libretrodb_cursor_t *cur, database_info_t *db_info) { diff --git a/deps/discord-rpc/examples/button-clicker/Assets/DiscordRpc.cs b/deps/discord-rpc/examples/button-clicker/Assets/DiscordRpc.cs index dec1ade0f5..af82c1c231 100644 --- a/deps/discord-rpc/examples/button-clicker/Assets/DiscordRpc.cs +++ b/deps/discord-rpc/examples/button-clicker/Assets/DiscordRpc.cs @@ -129,20 +129,20 @@ public class DiscordRpc FreeMem(); } - _presence.state = StrToPtr(state, 128); - _presence.details = StrToPtr(details, 128); + _presence.state = StrToPtr(state); + _presence.details = StrToPtr(details); _presence.startTimestamp = startTimestamp; _presence.endTimestamp = endTimestamp; - _presence.largeImageKey = StrToPtr(largeImageKey, 32); - _presence.largeImageText = StrToPtr(largeImageText, 128); - _presence.smallImageKey = StrToPtr(smallImageKey, 32); - _presence.smallImageText = StrToPtr(smallImageText, 128); - _presence.partyId = StrToPtr(partyId, 128); + _presence.largeImageKey = StrToPtr(largeImageKey); + _presence.largeImageText = StrToPtr(largeImageText); + _presence.smallImageKey = StrToPtr(smallImageKey); + _presence.smallImageText = StrToPtr(smallImageText); + _presence.partyId = StrToPtr(partyId); _presence.partySize = partySize; _presence.partyMax = partyMax; - _presence.matchSecret = StrToPtr(matchSecret, 128); - _presence.joinSecret = StrToPtr(joinSecret, 128); - _presence.spectateSecret = StrToPtr(spectateSecret, 128); + _presence.matchSecret = StrToPtr(matchSecret); + _presence.joinSecret = StrToPtr(joinSecret); + _presence.spectateSecret = StrToPtr(spectateSecret); _presence.instance = instance; return _presence; @@ -152,16 +152,18 @@ public class DiscordRpc /// Returns a pointer to a representation of the given string with a size of maxbytes /// /// String to convert - /// Max number of bytes to use /// Pointer to the UTF-8 representation of - private IntPtr StrToPtr(string input, int maxbytes) + private IntPtr StrToPtr(string input) { if (string.IsNullOrEmpty(input)) return IntPtr.Zero; - var convstr = StrClampBytes(input, maxbytes); - var convbytecnt = Encoding.UTF8.GetByteCount(convstr); - var buffer = Marshal.AllocHGlobal(convbytecnt); + var convbytecnt = Encoding.UTF8.GetByteCount(input); + var buffer = Marshal.AllocHGlobal(convbytecnt + 1); + for (int i = 0; i < convbytecnt + 1; i++) + { + Marshal.WriteByte(buffer, i , 0); + } _buffers.Add(buffer); - Marshal.Copy(Encoding.UTF8.GetBytes(convstr), 0, buffer, convbytecnt); + Marshal.Copy(Encoding.UTF8.GetBytes(input), 0, buffer, convbytecnt); return buffer; } @@ -181,30 +183,6 @@ public class DiscordRpc return Encoding.UTF8.GetString(Encoding.UTF8.GetBytes(str)); } - /// - /// Clamp the string to the given byte length preserving null termination - /// - /// string to clamp - /// max bytes the resulting string should have (including null termination) - /// null terminated string with a byte length less or equal to - private static string StrClampBytes(string toclamp, int maxbytes) - { - var str = StrToUtf8NullTerm(toclamp); - var strbytes = Encoding.UTF8.GetBytes(str); - - if (strbytes.Length <= maxbytes) - { - return str; - } - - var newstrbytes = new byte[] { }; - Array.Copy(strbytes, 0, newstrbytes, 0, maxbytes - 1); - newstrbytes[newstrbytes.Length - 1] = 0; - newstrbytes[newstrbytes.Length - 2] = 0; - - return Encoding.UTF8.GetString(newstrbytes); - } - /// /// Free the allocated memory for conversion to /// diff --git a/deps/discord-rpc/examples/unrealstatus/Plugins/discordrpc/Source/DiscordRpc/Public/DiscordRpcBlueprint.h b/deps/discord-rpc/examples/unrealstatus/Plugins/discordrpc/Source/DiscordRpc/Public/DiscordRpcBlueprint.h index 2d6521124b..17e2f9b29e 100644 --- a/deps/discord-rpc/examples/unrealstatus/Plugins/discordrpc/Source/DiscordRpc/Public/DiscordRpcBlueprint.h +++ b/deps/discord-rpc/examples/unrealstatus/Plugins/discordrpc/Source/DiscordRpc/Public/DiscordRpcBlueprint.h @@ -24,6 +24,16 @@ struct FDiscordUserData { FString avatar; }; +/** +* Valid response codes for Respond function +*/ +UENUM(BlueprintType) +enum class EDiscordJoinResponseCodes : uint8 +{ + DISCORD_REPLY_NO UMETA(DisplayName="No"), + DISCORD_REPLY_YES UMETA(DisplayName="Yes"), + DISCORD_REPLY_IGNORE UMETA(DisplayName="Ignore") +}; DECLARE_LOG_CATEGORY_EXTERN(Discord, Log, All); diff --git a/deps/discord-rpc/src/discord_register_linux.cpp b/deps/discord-rpc/src/discord_register_linux.cpp index b10f96db66..09911dcc6c 100644 --- a/deps/discord-rpc/src/discord_register_linux.cpp +++ b/deps/discord-rpc/src/discord_register_linux.cpp @@ -33,9 +33,11 @@ extern "C" DISCORD_EXPORT void Discord_Register(const char* applicationId, const char exePath[1024]; if (!command || !command[0]) { - if (readlink("/proc/self/exe", exePath, sizeof(exePath)) <= 0) { + ssize_t size = readlink("/proc/self/exe", exePath, sizeof(exePath)); + if (size <= 0 || size >= (ssize_t)sizeof(exePath)) { return; } + exePath[size] = '\0'; command = exePath; } diff --git a/deps/discord-rpc/src/discord_rpc.cpp b/deps/discord-rpc/src/discord_rpc.cpp index dedb3f1539..2e44c939ce 100644 --- a/deps/discord-rpc/src/discord_rpc.cpp +++ b/deps/discord-rpc/src/discord_rpc.cpp @@ -89,10 +89,11 @@ public: keepRunning.store(true); ioThread = std::thread([&]() { const std::chrono::duration maxWait{500LL}; + Discord_UpdateConnection(); while (keepRunning.load()) { - Discord_UpdateConnection(); std::unique_lock lock(waitForIOMutex); waitForIOActivity.wait_for(lock, maxWait); + Discord_UpdateConnection(); } }); } diff --git a/dirs.c b/dirs.c index e961a9c4e3..6fbd1aad9b 100644 --- a/dirs.c +++ b/dirs.c @@ -25,7 +25,6 @@ #include "dirs.h" #include "command.h" #include "configuration.h" -#include "command.h" #include "defaults.h" #include "list_special.h" #include "file_path_special.h" diff --git a/discord/discord.c b/discord/discord.c index 0efe85e036..24008ef10f 100644 --- a/discord/discord.c +++ b/discord/discord.c @@ -37,25 +37,112 @@ #include "../cheevos/cheevos.h" #endif -static int FrustrationLevel = 0; +#ifdef HAVE_MENU +#include "../../menu/widgets/menu_input_dialog.h" +#include "../../menu/menu_cbs.h" +#endif + +#include +#include "../network/net_http_special.h" +#include "../tasks/tasks_internal.h" +#include +#include +#include "../file_path_special.h" static int64_t start_time = 0; static int64_t pause_time = 0; static int64_t ellapsed_time = 0; static bool discord_ready = false; +static bool discord_avatar_ready = false; static unsigned discord_status = 0; struct netplay_room *room; +static char user_id[128]; +static char user_name[128]; +static char party_name[128]; +static char user_avatar[PATH_MAX_LENGTH]; + +static char cdn_url[] = "https://cdn.discordapp.com/avatars"; + DiscordRichPresence discord_presence; +char* discord_get_own_username(void) +{ + return user_name; +} + +char* discord_get_own_avatar(void) +{ + return user_avatar; +} + +bool discord_avatar_is_ready(void) +{ + return discord_avatar_ready; +} + +void discord_avatar_set_ready(bool ready) +{ + discord_avatar_ready = ready; +} + +bool discord_is_ready(void) +{ + return discord_ready; +} + +#ifdef HAVE_MENU +static bool discord_download_avatar( + const char* user_id, const char* avatar_id) +{ + static char url[PATH_MAX_LENGTH]; + static char url_encoded[PATH_MAX_LENGTH]; + static char full_path[PATH_MAX_LENGTH]; + + static char buf[PATH_MAX_LENGTH]; + + file_transfer_t *transf = NULL; + + fill_pathname_application_special(buf, + sizeof(buf), + APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_DISCORD_AVATARS); + fill_pathname_join(full_path, buf, avatar_id, sizeof(full_path)); + strlcpy(user_avatar, avatar_id, sizeof(user_avatar)); + + if(filestream_exists(full_path)) + return true; + + snprintf(url, sizeof(url), "%s/%s/%s.png", cdn_url, user_id, avatar_id); + net_http_urlencode_full(url_encoded, url, sizeof(url_encoded)); + snprintf(buf, sizeof(buf), "%s.png", avatar_id); + + transf = (file_transfer_t*)calloc(1, sizeof(*transf)); + transf->enum_idx = MENU_ENUM_LABEL_CB_DISCORD_AVATAR; + strlcpy(transf->path, buf, sizeof(transf->path)); + + RARCH_LOG("[Discord] downloading avatar from: %s\n", url_encoded); + task_push_http_transfer(url_encoded, true, NULL, cb_generic_download, transf); + + return false; +} +#endif + static void handle_discord_ready(const DiscordUser* connectedUser) { + strlcpy(user_name, connectedUser->username, sizeof(user_name)); + strlcpy(party_name, connectedUser->username, sizeof(user_name)); + strlcat(party_name, "|", sizeof(party_name)); + strlcat(party_name, connectedUser->discriminator, sizeof(party_name)); + RARCH_LOG("[Discord] connected to user: %s#%s - avatar id: %s\n", connectedUser->username, connectedUser->discriminator, connectedUser->userId); +#ifdef HAVE_MENU + discord_download_avatar(connectedUser->userId, connectedUser->avatar); +#endif } static void handle_discord_disconnected(int errcode, const char* message) @@ -68,24 +155,72 @@ static void handle_discord_error(int errcode, const char* message) RARCH_LOG("[Discord] error (%d: %s)\n", errcode, message); } +static void handle_discord_join_cb(void *task_data, void *user_data, const char *err) +{ + struct netplay_room *room; + char tmp_hostname[32]; + + http_transfer_data_t *data = (http_transfer_data_t*)task_data; + + if (!data || err) + goto finish; + + data->data = (char*)realloc(data->data, data->len + 1); + data->data[data->len] = '\0'; + + netplay_rooms_parse(data->data); + room = netplay_room_get(0); + + if (room) + { + if (netplay_driver_ctl(RARCH_NETPLAY_CTL_IS_DATA_INITED, NULL)) + deinit_netplay(); + netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_CLIENT, NULL); + + snprintf(tmp_hostname, sizeof(tmp_hostname), "%s|%d", + room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_address : room->address, + room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_port : room->port); + + RARCH_LOG("[Discord] joining lobby at: %s\n", tmp_hostname); + task_push_netplay_crc_scan(room->gamecrc, + room->gamename, tmp_hostname, room->corename); + + } + +finish: + + if (err) + RARCH_ERR("%s: %s\n", msg_hash_to_str(MSG_DOWNLOAD_FAILED), err); + + if (data) + { + if (data->data) + free(data->data); + free(data); + } + + if (user_data) + free(user_data); +} + static void handle_discord_join(const char* secret) { - RARCH_LOG("[Discord] join (%s)\n", secret); + char url [2048] = "http://lobby.libretro.com/"; + char tmp_hostname[32]; static struct string_list *list = NULL; + + RARCH_LOG("[Discord] join secret: (%s)\n", secret); list = string_split(secret, "|"); - char tmp_hostname[32]; + strlcat(url, list->elems[0].data, sizeof(url)); + strlcat(url, "/", sizeof(url)); + RARCH_LOG("[Discord] querying lobby id: %s at %s\n", list->elems[0].data, url); + snprintf(tmp_hostname, sizeof(tmp_hostname), "%s|%s", list->elems[0].data, list->elems[1].data); - if (netplay_driver_ctl(RARCH_NETPLAY_CTL_IS_DATA_INITED, NULL)) - deinit_netplay(); - netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_CLIENT, NULL); - - task_push_netplay_crc_scan(atoi(list->elems[3].data), - list->elems[2].data, - tmp_hostname, list->elems[4].data); + task_push_http_transfer(url, true, NULL, handle_discord_join_cb, NULL); } static void handle_discord_spectate(const char* secret) @@ -93,14 +228,54 @@ static void handle_discord_spectate(const char* secret) RARCH_LOG("[Discord] spectate (%s)\n", secret); } +static void handle_discord_join_response(void *ignore, const char *line) +{ + /* To-Do: needs in-game widgets + if (strstr(line, "yes")) + Discord_Respond(user_id, DISCORD_REPLY_YES); + +#ifdef HAVE_MENU + menu_input_dialog_end(); + rarch_menu_running_finished(); +#endif +*/ +} + static void handle_discord_join_request(const DiscordUser* request) { - int response = -1; - char yn[4]; - RARCH_LOG("[Discord] join request from %s#%s - %s\n", + static char url[PATH_MAX_LENGTH]; + static char url_encoded[PATH_MAX_LENGTH]; + static char filename[PATH_MAX_LENGTH]; + char buf[PATH_MAX_LENGTH]; +#ifdef HAVE_MENU + menu_input_ctx_line_t line; +#endif + + RARCH_LOG("[Discord] join request from %s#%s - %s %s\n", request->username, request->discriminator, - request->userId); + request->userId, + request->avatar); + +#ifdef HAVE_MENU + discord_download_avatar(request->userId, request->avatar); + /* To-Do: needs in-game widgets + rarch_menu_running(); + */ + + memset(&line, 0, sizeof(line)); + snprintf(buf, sizeof(buf), "%s %s?", msg_hash_to_str(MSG_DISCORD_CONNECTION_REQUEST), request->username); + line.label = buf; + line.label_setting = "no_setting"; + line.cb = handle_discord_join_response; + + /* To-Do: needs in-game widgets + To-Do: bespoke dialog, should show while in-game and have a hotkey to accept + To-Do: show avatar of the user connecting + if (!menu_input_dialog_start(&line)) + return; + */ +#endif } void discord_update(enum discord_presence presence) @@ -121,8 +296,8 @@ void discord_update(enum discord_presence presence) switch (presence) { case DISCORD_PRESENCE_MENU: - discord_presence.details = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISCORD_IN_MENU); - discord_presence.largeImageKey = "base"; + discord_presence.details = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISCORD_IN_MENU); + discord_presence.largeImageKey = "base"; discord_presence.largeImageText = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NO_CORE); discord_presence.instance = 0; break; @@ -137,9 +312,9 @@ void discord_update(enum discord_presence presence) case DISCORD_PRESENCE_GAME: if (core_info) { - const char *system_id = core_info->system_id ? core_info->system_id : "core"; - - char *label = NULL; + const char *system_id = core_info->system_id + ? core_info->system_id : "core"; + char *label = NULL; playlist_t *current_playlist = playlist_get_cached(); if (current_playlist) @@ -164,13 +339,13 @@ void discord_update(enum discord_presence presence) pause_time = 0; ellapsed_time = 0; - discord_presence.smallImageKey = "playing"; + discord_presence.smallImageKey = "playing"; discord_presence.smallImageText = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISCORD_STATUS_PLAYING); discord_presence.startTimestamp = start_time; - discord_presence.details = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISCORD_IN_GAME); + discord_presence.details = msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISCORD_IN_GAME); - discord_presence.state = label; - discord_presence.instance = 0; + discord_presence.state = label; + discord_presence.instance = 0; } break; case DISCORD_PRESENCE_NETPLAY_HOSTING: @@ -183,19 +358,18 @@ void discord_update(enum discord_presence presence) room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_address : room->address, room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_port : room->port); - char party_id[128]; - snprintf(party_id, sizeof(party_id), "%d|%s", room->id, room->nickname); - char join_secret[128]; - snprintf(join_secret, sizeof(join_secret), "%s|%d|%s|%u|%s", - room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_address : room->address, - room->host_method == NETPLAY_HOST_METHOD_MITM ? room->mitm_port : room->port, - room->gamename, room->gamecrc, room->corename); - RARCH_LOG("%s\n", join_secret); - discord_presence.joinSecret = strdup(join_secret); - discord_presence.spectateSecret = "SPECSPECSPEC"; - discord_presence.partyId = party_id; - discord_presence.partyMax = 0; - discord_presence.partySize = 0; + { + char join_secret[128]; + snprintf(join_secret, sizeof(join_secret), "%d|%s", room->id, room->nickname); + discord_presence.joinSecret = strdup(join_secret); + /* discord_presence.spectateSecret = "SPECSPECSPEC"; */ + discord_presence.partyId = strdup(party_name); + discord_presence.partyMax = 0; + discord_presence.partySize = 0; + + RARCH_LOG("[Discord] join secret: %s\n", join_secret); + RARCH_LOG("[Discord] party id: %s\n", party_name); + } break; case DISCORD_PRESENCE_NETPLAY_HOSTING_STOPPED: case DISCORD_PRESENCE_NETPLAY_CLIENT: @@ -212,7 +386,9 @@ void discord_update(enum discord_presence presence) void discord_init(void) { + char command[PATH_MAX_LENGTH]; settings_t *settings = config_get_ptr(); + DiscordEventHandlers handlers; RARCH_LOG("[Discord] initializing ..\n"); @@ -226,13 +402,13 @@ void discord_init(void) handlers.spectateGame = handle_discord_spectate; handlers.joinRequest = handle_discord_join_request; - /* To-Do: Add the arguments RetroArch was started with to the register URI*/ - const char command[256] = "retroarch"; - Discord_Initialize(settings->arrays.discord_app_id, &handlers, 0, NULL); - Discord_Register(settings->arrays.discord_app_id, NULL); - discord_ready = true; + strlcpy(command, get_retroarch_launch_arguments(), sizeof(command)); + + RARCH_LOG("[Discord] registering startup command: %s\n", command); + Discord_Register(settings->arrays.discord_app_id, command); + discord_ready = true; } void discord_shutdown(void) @@ -243,7 +419,7 @@ void discord_shutdown(void) discord_ready = false; } -void discord_run_callbacks() +void discord_run_callbacks(void) { Discord_RunCallbacks(); -} \ No newline at end of file +} diff --git a/discord/discord.h b/discord/discord.h index 8148482d54..34505dae59 100644 --- a/discord/discord.h +++ b/discord/discord.h @@ -55,4 +55,14 @@ void discord_update(enum discord_presence presence); void discord_run_callbacks(); +bool discord_is_ready(); + +void discord_avatar_set_ready(bool ready); + +bool discord_avatar_is_ready(); + +char* discord_get_own_username(void); + +char* discord_get_own_avatar(void); + #endif /* __RARCH_DISCORD_H */ diff --git a/dist-scripts/dist-cores.sh b/dist-scripts/dist-cores.sh index bb0c8cb1c7..46bda5e8d8 100755 --- a/dist-scripts/dist-cores.sh +++ b/dist-scripts/dist-cores.sh @@ -18,6 +18,13 @@ cd .. LDFLAGS=-L. ./configure --disable-dynamic cd dist-scripts +elif [ $PLATFORM = "ps2" ] ; then +platform=ps2 +SALAMANDER=NO +EXT=a + +mkdir -p ../pkg/${platform}/cores/ + elif [ $PLATFORM = "psp1" ] ; then platform=psp1 SALAMANDER=yes @@ -230,7 +237,9 @@ for f in `ls -v *_${platform}.${EXT}`; do fi # Do manual executable step - if [ $PLATFORM = "dex-ps3" ] ; then + if [ $PLATFORM = "ps2" ] ; then + make -C ../ -f Makefile.${platform} package -j3 + elif [ $PLATFORM = "dex-ps3" ] ; then $MAKE_FSELF_NPDRM -c ../retroarch_${platform}.elf ../CORE.SELF elif [ $PLATFORM = "cex-ps3" ] ; then $SCETOOL_PATH $SCETOOL_FLAGS_CORE ../retroarch_${platform}.elf ../CORE.SELF @@ -253,6 +262,8 @@ for f in `ls -v *_${platform}.${EXT}`; do cp -fv ../../dist/info/"${name}_libretro.info" ../pkg/${platform}/SSNE10000/USRDIR/cores/info/"${name}_libretro.info" fi fi + elif [ $PLATFORM = "ps2" ] ; then + mv -f ../retroarchps2-release.elf ../pkg/${platform}/cores/retroarchps2_${name}.elf elif [ $PLATFORM = "psp1" ] ; then mv -f ../EBOOT.PBP ../pkg/${platform}/cores/${name}_libretro.PBP elif [ $PLATFORM = "vita" ] ; then @@ -288,6 +299,8 @@ for f in `ls -v *_${platform}.${EXT}`; do # Remove executable files if [ $platform = "ps3" ] ; then rm -f ../retroarch_${platform}.elf ../retroarch_${platform}.self ../CORE.SELF + elif [ $PLATFORM = "ps2" ] ; then + rm -f ../retroarchps2.elf elif [ $PLATFORM = "psp1" ] ; then rm -f ../retroarchpsp.elf elif [ $PLATFORM = "vita" ] ; then diff --git a/driver.c b/driver.c index 7e7d609955..3877683bfd 100644 --- a/driver.c +++ b/driver.c @@ -35,6 +35,7 @@ #include "wifi/wifi_driver.h" #include "led/led_driver.h" #include "midi/midi_driver.h" +#include "command.h" #include "configuration.h" #include "core_info.h" #include "driver.h" @@ -385,6 +386,10 @@ void drivers_init(int flags) if (flags & DRIVER_MENU_MASK) menu_driver_init(video_is_threaded); } +#else + /* Qt uses core info, even if the menu is disabled */ + command_event(CMD_EVENT_CORE_INFO_INIT, NULL); + command_event(CMD_EVENT_LOAD_CORE_PERSIST, NULL); #endif if (flags & (DRIVER_VIDEO_MASK | DRIVER_AUDIO_MASK)) @@ -403,7 +408,6 @@ void drivers_init(int flags) midi_driver_init(); } - /** * uninit_drivers: * @flags : Bitmask of drivers to deinitialize. diff --git a/dynamic.c b/dynamic.c index 049aad7883..c43a9218db 100644 --- a/dynamic.c +++ b/dynamic.c @@ -108,6 +108,10 @@ static dylib_t lib_handle; #define SYMBOL_VIDEOPROCESSOR(x) current_core->x = libretro_videoprocessor_##x #endif +#ifdef HAVE_EASTEREGG +#define SYMBOL_GONG(x) current_core->x = libretro_gong_##x +#endif + static bool ignore_environment_cb = false; static bool core_set_shared_context = false; static bool *load_no_content_hook = NULL; @@ -173,7 +177,6 @@ void libretro_free_system_info(struct retro_system_info *info) memset(info, 0, sizeof(*info)); } - static bool environ_cb_get_system_info(unsigned cmd, void *data) { rarch_system_info_t *system = runloop_get_system_info(); @@ -236,7 +239,6 @@ static bool environ_cb_get_system_info(unsigned cmd, void *data) subsystem_data[i].roms = subsystem_data_roms[i]; } - subsystem_current_count = size <= SUBSYSTEM_MAX_SUBSYSTEMS ? size : SUBSYSTEM_MAX_SUBSYSTEMS; #if 0 RARCH_LOG("Subsystems: %d\n", subsystem_current_count); @@ -306,6 +308,9 @@ static void libretro_get_environment_info(void (*func)(retro_environment_t), static bool load_dynamic_core(void) { +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + /* Can't lookup symbols in itself on UWP */ +#else function_t sym = dylib_proc(NULL, "retro_init"); if (sym) @@ -319,6 +324,7 @@ static bool load_dynamic_core(void) RARCH_ERR("Proceeding could cause a crash. Aborting ...\n"); retroarch_fail(1, "init_libretro_sym()"); } +#endif if (string_is_empty(path_get(RARCH_PATH_CORE))) { @@ -773,6 +779,43 @@ bool init_libretro_sym_custom(enum rarch_core_type type, struct retro_core_t *cu SYMBOL_VIDEOPROCESSOR(retro_get_region); SYMBOL_VIDEOPROCESSOR(retro_get_memory_data); SYMBOL_VIDEOPROCESSOR(retro_get_memory_size); +#endif + break; + case CORE_TYPE_GONG: +#ifdef HAVE_EASTEREGG + SYMBOL_GONG(retro_init); + SYMBOL_GONG(retro_deinit); + + SYMBOL_GONG(retro_api_version); + SYMBOL_GONG(retro_get_system_info); + SYMBOL_GONG(retro_get_system_av_info); + + SYMBOL_GONG(retro_set_environment); + SYMBOL_GONG(retro_set_video_refresh); + SYMBOL_GONG(retro_set_audio_sample); + SYMBOL_GONG(retro_set_audio_sample_batch); + SYMBOL_GONG(retro_set_input_poll); + SYMBOL_GONG(retro_set_input_state); + + SYMBOL_GONG(retro_set_controller_port_device); + + SYMBOL_GONG(retro_reset); + SYMBOL_GONG(retro_run); + + SYMBOL_GONG(retro_serialize_size); + SYMBOL_GONG(retro_serialize); + SYMBOL_GONG(retro_unserialize); + + SYMBOL_GONG(retro_cheat_reset); + SYMBOL_GONG(retro_cheat_set); + + SYMBOL_GONG(retro_load_game); + SYMBOL_GONG(retro_load_game_special); + + SYMBOL_GONG(retro_unload_game); + SYMBOL_GONG(retro_get_region); + SYMBOL_GONG(retro_get_memory_data); + SYMBOL_GONG(retro_get_memory_size); #endif break; } @@ -1468,8 +1511,8 @@ bool rarch_environment_cb(unsigned cmd, void *data) { memcpy(hwr, cb, offsetof(struct retro_hw_render_callback, stencil)); - memset(hwr + offsetof(struct retro_hw_render_callback, stencil), - 0, sizeof(*cb) - offsetof(struct retro_hw_render_callback, stencil)); + memset((uint8_t*)hwr + offsetof(struct retro_hw_render_callback, stencil), + 0, sizeof(*cb) - offsetof(struct retro_hw_render_callback, stencil)); } else memcpy(hwr, cb, sizeof(*cb)); diff --git a/file_path_special.c b/file_path_special.c index fa6c3690a8..70769b97da 100644 --- a/file_path_special.c +++ b/file_path_special.c @@ -338,6 +338,31 @@ void fill_pathname_application_special(char *s, } #endif break; + case APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_DISCORD_AVATARS: + { + char *s1 = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); + char *s2 = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); + settings_t *settings = config_get_ptr(); + + s1[0] = s2[0] = '\0'; + + fill_pathname_join(s1, + settings->paths.directory_thumbnails, + "discord", + len); + fill_pathname_join(s2, + s1, "avatars", + PATH_MAX_LENGTH * sizeof(char) + ); + fill_pathname_slash(s2, + PATH_MAX_LENGTH * sizeof(char) + ); + strlcpy(s, s2, len); + free(s1); + free(s2); + } + break; + case APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_CHEEVOS_BADGES: { char *s1 = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); diff --git a/file_path_special.h b/file_path_special.h index 16455f2486..d98a6b3971 100644 --- a/file_path_special.h +++ b/file_path_special.h @@ -111,7 +111,8 @@ enum application_special_type APPLICATION_SPECIAL_DIRECTORY_ASSETS_ZARCH, APPLICATION_SPECIAL_DIRECTORY_ASSETS_ZARCH_FONT, APPLICATION_SPECIAL_DIRECTORY_ASSETS_ZARCH_ICONS, - APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_CHEEVOS_BADGES + APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_CHEEVOS_BADGES, + APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_DISCORD_AVATARS }; /** diff --git a/frontend/drivers/platform_gx.c b/frontend/drivers/platform_gx.c index f7462e0966..ff0c1e77d5 100644 --- a/frontend/drivers/platform_gx.c +++ b/frontend/drivers/platform_gx.c @@ -209,7 +209,21 @@ static void frontend_gx_get_environment_settings( chdir("carda:/retroarch"); #endif getcwd(g_defaults.dirs[DEFAULT_DIR_CORE], PATH_MAX_LENGTH); - +#if defined(HW_RVL) && !defined(IS_SALAMANDER) + /* When using external loaders(Wiiflow etc.), getcwd doesn't return the path correctly and + * as a result the cfg file is not found. */ + if (*argc > 2 && argv[1] != NULL && argv[2] != NULL) + { + if(gx_devices[GX_DEVICE_SD].mounted) + { + chdir("sd:/"); + } + else if(gx_devices[GX_DEVICE_USB].mounted) + { + chdir("usb:/"); + } + } +#endif last_slash = strrchr(g_defaults.dirs[DEFAULT_DIR_CORE], '/'); if (last_slash) *last_slash = 0; diff --git a/frontend/drivers/platform_orbis.c b/frontend/drivers/platform_orbis.c index 9e9fad29d1..66d3c02722 100644 --- a/frontend/drivers/platform_orbis.c +++ b/frontend/drivers/platform_orbis.c @@ -73,6 +73,28 @@ char user_path[512]; static enum frontend_fork orbis_fork_mode = FRONTEND_FORK_NONE; +#ifdef __cplusplus +extern "C" +#endif +int main(int argc, char *argv[]) +{ + int ret; + + sceSystemServiceHideSplashScreen(); + + uintptr_t intptr=0; + sscanf(argv[1],"%p",&intptr); + myConf=(OrbisGlobalConf *)intptr; + ret=ps4LinkInitWithConf(myConf->confLink); + if(!ret) + { + ps4LinkFinish(); + return -1; + } + + return rarch_main(argc, argv, NULL); +} + static void frontend_orbis_get_environment_settings(int *argc, char *argv[], void *args, void *params_data) { @@ -212,7 +234,6 @@ static void frontend_orbis_shutdown(bool unused) return; } - static void frontend_orbis_init(void *data) { diff --git a/frontend/drivers/platform_ps2.c b/frontend/drivers/platform_ps2.c index 93d389d889..0d69d7615c 100644 --- a/frontend/drivers/platform_ps2.c +++ b/frontend/drivers/platform_ps2.c @@ -1,6 +1,5 @@ /* RetroArch - A frontend for libretro. - * Copyright (C) 2010-2014 - Hans-Kristian Arntzen - * Copyright (C) 2011-2017 - Daniel De Matteis + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy * * RetroArch is free software: you can redistribute it and/or modify it under the terms * of the GNU General Public License as published by the Free Software Found- @@ -21,13 +20,11 @@ #include #include #include -#include -#include #include #include #include -#include - +#include +#include enum BootDeviceIDs{ BOOT_DEVICE_UNKNOWN = -1, @@ -74,6 +71,12 @@ extern unsigned int usbd_irx_size; extern unsigned char usbhdfsd_irx_start[]; extern unsigned int usbhdfsd_irx_size; +extern unsigned char mcman_irx_start[]; +extern unsigned int mcman_irx_size; + +extern unsigned char mcserv_irx_start[]; +extern unsigned int mcserv_irx_size; + static unsigned char HDDModulesLoaded=0; char eboot_path[512]; @@ -81,30 +84,47 @@ char user_path[512]; static enum frontend_fork ps2_fork_mode = FRONTEND_FORK_NONE; -//Only paths residing on "basic" devices (devices that don't require mounting) -//can be specified here, since this system doesn't perform mounting based on the path. +/* Only paths residing on "basic" devices + * (devices that don't require mounting) + * can be specified here, since this system + * doesn't perform mounting based on the path. + */ #define DEFAULT_PATH "mass:" -static int getBootDeviceID(char *path) { - int result = BOOT_DEVICE_HOST; +static int getBootDeviceID(char *path) +{ + if (!strncmp(path, "mc0:", 4)) + return BOOT_DEVICE_MC0; + else if (!strncmp(path, "mc1:", 4)) + return BOOT_DEVICE_MC1; + else if (!strncmp(path, "cdrom0:", 7)) + return BOOT_DEVICE_CDROM; + else if (!strncmp(path, "mass:", 5) || !strncmp(path, "mass0:", 6)) + return BOOT_DEVICE_MASS; + else if (!strncmp(path, "hdd:", 4) || !strncmp(path, "hdd0:", 5)) + return BOOT_DEVICE_HDD; + else if (!strncmp(path, "host", 4) && ((path[4]>='0' && path[4]<='9') || path[4]==':')) + return BOOT_DEVICE_HOST; + else + return BOOT_DEVICE_UNKNOWN; - if(!strncmp(path, "mc0:", 4)) result=BOOT_DEVICE_MC0; - else if(!strncmp(path, "mc1:", 4)) result=BOOT_DEVICE_MC1; - else if(!strncmp(path, "cdrom0:", 7)) result=BOOT_DEVICE_CDROM; - else if(!strncmp(path, "mass:", 5) || !strncmp(path, "mass0:", 6)) result=BOOT_DEVICE_MASS; - else if(!strncmp(path, "hdd:", 4) || !strncmp(path, "hdd0:", 5)) result=BOOT_DEVICE_HDD; - else if(!strncmp(path, "host", 4) && ((path[4]>='0' && path[4]<='9') || path[4]==':')) result=BOOT_DEVICE_HOST; - else result=BOOT_DEVICE_UNKNOWN; - - return result; + return BOOT_DEVICE_HOST; } -//HACK! If booting from a USB device, keep trying to open this program again until it succeeds. This will ensure that the emulator will be able to load its files. -static void waitUntilDeviceIsReady(const char *path) { +/* HACK! If booting from a USB device, keep trying to + * open this program again until it succeeds. + * + * This will ensure that the emulator will be able to load its files. + */ + +static void waitUntilDeviceIsReady(const char *path) +{ FILE *file; - while((file=fopen(path, "rb"))==NULL){ - //Wait for a while first, or the IOP will get swamped by requests from the EE. + while((file=fopen(path, "rb"))==NULL) + { + /* Wait for a while first, or the IOP + * will get swamped by requests from the EE. */ nopdelay(); nopdelay(); nopdelay(); @@ -118,47 +138,54 @@ static void waitUntilDeviceIsReady(const char *path) { fclose(file); } -void setPWDOnPFS(const char *FullCWD_path) { - int i; - char *path; - - path=NULL; - for(i=strlen(FullCWD_path); i>=0; i--){ /* Try to seperate the CWD from the path to this ELF. */ - if(FullCWD_path[i]==':'){ - if((path=malloc(i+6+2))!=NULL){ - strcpy(path, "pfs0:/"); - strncat(path, FullCWD_path, i+1); - path[i+1+6]='\0'; - } - break; - } - else if((FullCWD_path[i]=='\\')||(FullCWD_path[i]=='/')){ - if((path=malloc(i+6+1))!=NULL){ - strcpy(path, "pfs0:/"); - strncat(path, FullCWD_path, i); - path[i+6]='\0'; - } - break; - } - } - - if(path!=NULL){ - chdir(path); - free(path); - } +void setPWDOnPFS(const char *FullCWD_path) +{ + int i; + char *path=NULL; + for (i=strlen(FullCWD_path); i>=0; i--) + { + /* Try to seperate the CWD from the path to this ELF. */ + if (FullCWD_path[i]==':') + { + if ((path=malloc(i+6+2))!=NULL) + { + strcpy(path, "pfs0:/"); + strncat(path, FullCWD_path, i+1); + path[i+1+6]='\0'; + } + break; + } + else if ((FullCWD_path[i]=='\\')||(FullCWD_path[i]=='/')) + { + if ((path=malloc(i+6+1))!=NULL) + { + strcpy(path, "pfs0:/"); + strncat(path, FullCWD_path, i); + path[i+6]='\0'; + } + break; + } + } + + if (path!=NULL) + { + chdir(path); + free(path); + } } -static const char *getMountParams(const char *command, char *BlockDevice) { - const char *MountPath; +static const char *getMountParams(const char *command, char *BlockDevice) +{ int BlockDeviceNameLen; + const char *MountPath=NULL; - MountPath=NULL; - if(strlen(command)>6 && (MountPath=strchr(&command[5], ':'))!=NULL){ + if (strlen(command)>6 && (MountPath=strchr(&command[5], ':'))!=NULL) + { BlockDeviceNameLen=(unsigned int)MountPath-(unsigned int)command; strncpy(BlockDevice, command, BlockDeviceNameLen); BlockDevice[BlockDeviceNameLen]='\0'; - - MountPath++; //This is the location of the mount path; + + MountPath++; /* This is the location of the mount path; */ } return MountPath; @@ -166,13 +193,6 @@ static const char *getMountParams(const char *command, char *BlockDevice) { static void create_path_names(void) { -#ifndef IS_SALAMANDER -#if defined(HAVE_LOGGER) - -#elif defined(HAVE_FILE_LOGGER) - retro_main_log_file_init("ux0:/temp/retroarch-log.txt"); // It really depend from where we are executing this -#endif -#endif fill_pathname_join(g_defaults.dirs[DEFAULT_DIR_CORE], g_defaults.dirs[DEFAULT_DIR_PORT], "CORES", sizeof(g_defaults.dirs[DEFAULT_DIR_CORE])); @@ -212,14 +232,16 @@ static void create_path_names(void) static void poweroffCallback(void *arg) { - //Close all files and unmount all partitions. - //close(fd); +#if 0 + /* Close all files and unmount all partitions. */ + close(fd); - //If you use PFS, close all files and unmount all partitions. - //fileXioDevctl("pfs:", PDIOC_CLOSEALL, NULL, 0, NULL, 0) + /* If you use PFS, close all files and unmount all partitions. */ + fileXioDevctl("pfs:", PDIOC_CLOSEALL, NULL, 0, NULL, 0) - //Shut down DEV9, if you used it. - //while(fileXioDevctl("dev9x:", DDIOC_OFF, NULL, 0, NULL, 0) < 0){}; + /* Shut down DEV9, if you used it. */ + while(fileXioDevctl("dev9x:", DDIOC_OFF, NULL, 0, NULL, 0) < 0){}; +#endif printf("Shutdown!"); poweroffShutdown(); @@ -232,37 +254,39 @@ static void frontend_ps2_get_environment_settings(int *argc, char *argv[], const char *mountPoint; int bootDeviceID; - //TODO: I DONT KNOW YET, WHY IT CRASHES IF UNCOMENT THIS PART getcwd(cwd, sizeof(cwd)); bootDeviceID=getBootDeviceID(cwd); - //Mount the HDD partition, if required. - if(bootDeviceID==BOOT_DEVICE_HDD){ - /* Try not to adjust this unless you know what you are doing. The tricky part i keeping the NULL character in the middle of that argument list separated from the number 4. */ - static const char PS2HDD_args[]="-o\0""2"; - static const char PS2FS_args[]="-o\0""8"; - if(!HDDModulesLoaded){ - SifExecModuleBuffer(poweroff_irx_start, poweroff_irx_size, 0, NULL, NULL); - SifExecModuleBuffer(ps2dev9_irx_start, ps2dev9_irx_size, 0, NULL, NULL); - SifExecModuleBuffer(ps2atad_irx_start, ps2atad_irx_size, 0, NULL, NULL); - SifExecModuleBuffer(ps2hdd_irx_start, ps2hdd_irx_size, sizeof(PS2HDD_args), PS2HDD_args, NULL); - SifExecModuleBuffer(ps2fs_irx_start, ps2fs_irx_size, sizeof(PS2FS_args), PS2FS_args, NULL); - HDDModulesLoaded=1; - } - - //Attempt to mount the partition. - if((mountPoint=getMountParams(cwd, blockDevice))!=NULL && !strncmp(mountPoint, "pfs:", 4)){ + /* Mount the HDD partition, if required. */ + if (bootDeviceID==BOOT_DEVICE_HDD) + { + /* Try not to adjust this unless you know what you are doing. The tricky part i keeping the NULL character in the middle of that argument list separated from the number 4. */ + static const char PS2HDD_args[]="-o\0""2"; + static const char PS2FS_args[]="-o\0""8"; + + if (!HDDModulesLoaded) + { + SifExecModuleBuffer(poweroff_irx_start, poweroff_irx_size, 0, NULL, NULL); + SifExecModuleBuffer(ps2dev9_irx_start, ps2dev9_irx_size, 0, NULL, NULL); + SifExecModuleBuffer(ps2atad_irx_start, ps2atad_irx_size, 0, NULL, NULL); + SifExecModuleBuffer(ps2hdd_irx_start, ps2hdd_irx_size, sizeof(PS2HDD_args), PS2HDD_args, NULL); + SifExecModuleBuffer(ps2fs_irx_start, ps2fs_irx_size, sizeof(PS2FS_args), PS2FS_args, NULL); + HDDModulesLoaded=1; + } + + /* Attempt to mount the partition. */ + if ((mountPoint=getMountParams(cwd, blockDevice))!=NULL && !strncmp(mountPoint, "pfs:", 4)) + { fileXioMount("pfs0:", blockDevice, FIO_MT_RDWR); - + setPWDOnPFS(&mountPoint[4]); } - } else if(bootDeviceID==BOOT_DEVICE_CDROM){ - chdir(DEFAULT_PATH); - } else if(bootDeviceID==BOOT_DEVICE_MASS){ - waitUntilDeviceIsReady(argv[0]); - } else if (bootDeviceID==BOOT_DEVICE_UNKNOWN) { - } + else if (bootDeviceID==BOOT_DEVICE_CDROM) + chdir(DEFAULT_PATH); + else if (bootDeviceID==BOOT_DEVICE_MASS) + waitUntilDeviceIsReady(argv[0]); + else if (bootDeviceID==BOOT_DEVICE_UNKNOWN) { } create_path_names(); @@ -308,30 +332,49 @@ static void frontend_ps2_init(void *data) { SifInitRpc(0); #if !defined(DEBUG) - while(!SifIopReset(NULL, 0)){}; // Comment this line if you don't wanna debug the output + /* Comment this line if you don't wanna debug the output */ + while(!SifIopReset(NULL, 0)){}; #endif while(!SifIopSync()){}; SifInitRpc(0); sbv_patch_enable_lmb(); + /* Controllers */ + SifLoadModule("rom0:SIO2MAN", 0, NULL); + SifLoadModule("rom0:PADMAN", 0, NULL); + + /* I/O Files */ SifExecModuleBuffer(iomanX_irx_start, iomanX_irx_size, 0, NULL, NULL); SifExecModuleBuffer(fileXio_irx_start, fileXio_irx_size, 0, NULL, NULL); + + /* Memory Card */ + SifExecModuleBuffer(mcman_irx_start, mcman_irx_size, 0, NULL, NULL); + SifExecModuleBuffer(mcserv_irx_start, mcserv_irx_size, 0, NULL, NULL); - SifLoadModule("rom0:SIO2MAN", 0, NULL); - SifLoadModule("rom0:MCMAN", 0, NULL); - SifLoadModule("rom0:MCSERV", 0, NULL); - SifLoadModule("rom0:PADMAN", 0, NULL); - + /* USB */ SifExecModuleBuffer(usbd_irx_start, usbd_irx_size, 0, NULL, NULL); SifExecModuleBuffer(usbhdfsd_irx_start, usbhdfsd_irx_size, 0, NULL, NULL); + + /* Audio */ SifExecModuleBuffer(freesd_irx_start, freesd_irx_size, 0, NULL, NULL); SifExecModuleBuffer(audsrv_irx_start, audsrv_irx_size, 0, NULL, NULL); - fileXioInit(); - audsrv_init(); + /* Initializes audsrv library */ + if (audsrv_init()) { + RARCH_ERR("audsrv library not initalizated\n"); + } - SDL_Init(SDL_INIT_TIMER); + /* Initializes pad library + Must be init with 0 as parameter*/ + if (padInit(0) != 1) { + RARCH_ERR("padInit library not initalizated\n"); + } + +#if defined(HAVE_FILE_LOGGER) + retro_main_log_file_init("retroarch.log"); + verbosity_enable(); +#endif } static void frontend_ps2_deinit(void *data) @@ -344,6 +387,10 @@ static void frontend_ps2_deinit(void *data) #endif #endif + + padEnd(); + audsrv_quit(); + fileXioUmount("pfs0:"); fileXioExit(); @@ -369,7 +416,9 @@ static void frontend_ps2_exec(const char *path, bool should_load_game) #endif RARCH_LOG("Attempt to load executable: [%s].\n", path); - // exitspawn_kernel(path, args, argp); // I don't know what this is doing +#if 0 + exitspawn_kernel(path, args, argp); /* I don't know what this is doing */ +#endif #endif } @@ -424,7 +473,7 @@ static void frontend_ps2_exitspawn(char *core_path, size_t core_path_size) static void frontend_ps2_shutdown(bool unused) { poweroffInit(); - //Set callback function + /* Set callback function */ poweroffSetCallback(&poweroffCallback, NULL); } @@ -467,7 +516,7 @@ static int frontend_ps2_parse_drive_list(void *data, bool load_content) enum_idx, FILE_TYPE_DIRECTORY, 0, 0); menu_entries_append_enum(list, - "host:/", + "host:", msg_hash_to_str(MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR), enum_idx, FILE_TYPE_DIRECTORY, 0, 0); diff --git a/frontend/drivers/platform_switch.c b/frontend/drivers/platform_switch.c index 59e38b6d44..f63ee029be 100644 --- a/frontend/drivers/platform_switch.c +++ b/frontend/drivers/platform_switch.c @@ -656,7 +656,6 @@ static void frontend_switch_shutdown(bool unused) /* runloop_get_system_info isnt initialized that early.. */ extern void retro_get_system_info(struct retro_system_info *info); - static void frontend_switch_init(void *data) { diff --git a/frontend/drivers/platform_unix.c b/frontend/drivers/platform_unix.c index 440b336050..e916693663 100644 --- a/frontend/drivers/platform_unix.c +++ b/frontend/drivers/platform_unix.c @@ -1824,7 +1824,6 @@ static void frontend_unix_get_env(int *argc, else if (strstr(device_model, "JSS15J")) g_defaults.settings.video_refresh_rate = 59.65; - /* For gamepad-like/console devices: * * - Explicitly disable input overlay by default diff --git a/frontend/drivers/platform_unix.h b/frontend/drivers/platform_unix.h index 9c18c4c990..672f334d86 100644 --- a/frontend/drivers/platform_unix.h +++ b/frontend/drivers/platform_unix.h @@ -104,7 +104,6 @@ struct android_app * receive user input events. */ AInputQueue* inputQueue; - /* When non-NULL, this is the window surface that the app can draw in. */ ANativeWindow* window; @@ -165,7 +164,6 @@ struct android_app jmethodID setSustainedPerformanceMode; }; - enum { LOOPER_ID_MAIN = 1, diff --git a/frontend/drivers/platform_uwp.c b/frontend/drivers/platform_uwp.c new file mode 100644 index 0000000000..b6fa41002c --- /dev/null +++ b/frontend/drivers/platform_uwp.c @@ -0,0 +1,418 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2011-2017 - Daniel De Matteis + * Copyright (C) 2016-2017 - Brad Parker + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#include +#include +#include + +#include +#include + +#include +#include +#include +#include +#include +#include + +#ifdef HAVE_CONFIG_H +#include "../../config.h" +#endif + +#ifdef HAVE_MENU +#include "../../menu/menu_driver.h" +#endif + +#include "../frontend_driver.h" +#include "../../configuration.h" +#include "../../defaults.h" +#include "../../retroarch.h" +#include "../../verbosity.h" +#include "../../ui/drivers/ui_win32.h" + +#include "../../uwp/uwp_func.h" + +static void frontend_uwp_get_os(char *s, size_t len, int *major, int *minor) +{ + char buildStr[11] = {0}; + bool server = false; + const char *arch = ""; + +#if defined(_WIN32_WINNT) && _WIN32_WINNT >= 0x0500 + /* Windows 2000 and later */ + SYSTEM_INFO si = {{0}}; + OSVERSIONINFOEX vi = {0}; + vi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX); + + GetSystemInfo(&si); + + /* Available from NT 3.5 and Win95 */ + GetVersionEx((OSVERSIONINFO*)&vi); + + server = vi.wProductType != VER_NT_WORKSTATION; + + switch (si.wProcessorArchitecture) + { + case PROCESSOR_ARCHITECTURE_AMD64: + arch = "x64"; + break; + case PROCESSOR_ARCHITECTURE_INTEL: + arch = "x86"; + break; + case PROCESSOR_ARCHITECTURE_ARM: + arch = "ARM"; + break; + default: + break; + } +#else + OSVERSIONINFO vi = {0}; + vi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + + /* Available from NT 3.5 and Win95 */ + GetVersionEx(&vi); +#endif + + if (major) + *major = vi.dwMajorVersion; + + if (minor) + *minor = vi.dwMinorVersion; + + if (vi.dwMajorVersion == 4 && vi.dwMinorVersion == 0) + snprintf(buildStr, sizeof(buildStr), "%lu", (DWORD)(LOWORD(vi.dwBuildNumber))); /* Windows 95 build number is in the low-order word only */ + else + snprintf(buildStr, sizeof(buildStr), "%lu", vi.dwBuildNumber); + + switch (vi.dwMajorVersion) + { + case 10: + if (server) + strlcpy(s, "Windows Server 2016", len); + else + strlcpy(s, "Windows 10", len); + break; + case 6: + switch (vi.dwMinorVersion) + { + case 3: + if (server) + strlcpy(s, "Windows Server 2012 R2", len); + else + strlcpy(s, "Windows 8.1", len); + break; + case 2: + if (server) + strlcpy(s, "Windows Server 2012", len); + else + strlcpy(s, "Windows 8", len); + break; + case 1: + if (server) + strlcpy(s, "Windows Server 2008 R2", len); + else + strlcpy(s, "Windows 7", len); + break; + case 0: + if (server) + strlcpy(s, "Windows Server 2008", len); + else + strlcpy(s, "Windows Vista", len); + break; + default: + break; + } + break; + case 5: + switch (vi.dwMinorVersion) + { + case 2: + if (server) + strlcpy(s, "Windows Server 2003", len); + else + { + /* Yes, XP Pro x64 is a higher version number than XP x86 */ + if (string_is_equal(arch, "x64")) + strlcpy(s, "Windows XP", len); + } + break; + case 1: + strlcpy(s, "Windows XP", len); + break; + case 0: + strlcpy(s, "Windows 2000", len); + break; + } + break; + case 4: + switch (vi.dwMinorVersion) + { + case 0: + if (vi.dwPlatformId == VER_PLATFORM_WIN32_WINDOWS) + strlcpy(s, "Windows 95", len); + else if (vi.dwPlatformId == VER_PLATFORM_WIN32_NT) + strlcpy(s, "Windows NT 4.0", len); + else + strlcpy(s, "Unknown", len); + break; + case 90: + strlcpy(s, "Windows ME", len); + break; + case 10: + strlcpy(s, "Windows 98", len); + break; + } + break; + default: + snprintf(s, len, "Windows %i.%i", *major, *minor); + break; + } + + if (!string_is_empty(arch)) + { + strlcat(s, " ", len); + strlcat(s, arch, len); + } + + strlcat(s, " Build ", len); + strlcat(s, buildStr, len); + + if (!string_is_empty(vi.szCSDVersion)) + { + strlcat(s, " ", len); + strlcat(s, vi.szCSDVersion, len); + } + + if (!string_is_empty(uwp_device_family)) + { + strlcat(s, " ", len); + strlcat(s, uwp_device_family, len); + } +} + +static void frontend_uwp_init(void *data) +{ +} + +enum frontend_powerstate frontend_uwp_get_powerstate( + int *seconds, int *percent) +{ + SYSTEM_POWER_STATUS status; + enum frontend_powerstate ret = FRONTEND_POWERSTATE_NONE; + + if (!GetSystemPowerStatus(&status)) + return ret; + + if (status.BatteryFlag == 0xFF) + ret = FRONTEND_POWERSTATE_NONE; + if (status.BatteryFlag & (1 << 7)) + ret = FRONTEND_POWERSTATE_NO_SOURCE; + else if (status.BatteryFlag & (1 << 3)) + ret = FRONTEND_POWERSTATE_CHARGING; + else if (status.ACLineStatus == 1) + ret = FRONTEND_POWERSTATE_CHARGED; + else + ret = FRONTEND_POWERSTATE_ON_POWER_SOURCE; + + *percent = (int)status.BatteryLifePercent; + *seconds = (int)status.BatteryLifeTime; + +#ifdef _WIN32 + if (*percent == 255) + *percent = 0; +#endif + return ret; +} + +enum frontend_architecture frontend_uwp_get_architecture(void) +{ +#if defined(_WIN32_WINNT) && _WIN32_WINNT >= 0x0500 + /* Windows 2000 and later */ + SYSTEM_INFO si = {{0}}; + + GetSystemInfo(&si); + + switch (si.wProcessorArchitecture) + { + case PROCESSOR_ARCHITECTURE_AMD64: + return FRONTEND_ARCH_X86_64; + break; + case PROCESSOR_ARCHITECTURE_INTEL: + return FRONTEND_ARCH_X86; + break; + case PROCESSOR_ARCHITECTURE_ARM: + return FRONTEND_ARCH_ARM; + break; + default: + break; + } +#endif + + return FRONTEND_ARCH_NONE; +} + +static int frontend_uwp_parse_drive_list(void *data, bool load_content) +{ +#ifdef HAVE_MENU + file_list_t *list = (file_list_t*)data; + enum msg_hash_enums enum_idx = load_content ? + MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR : + MSG_UNKNOWN; + /* TODO (krzys_h): UWP storage sandboxing */ + char *home_dir = (char*)malloc( + PATH_MAX_LENGTH * sizeof(char)); + + fill_pathname_home_dir(home_dir, + PATH_MAX_LENGTH * sizeof(char)); + + menu_entries_append_enum(list, + home_dir, + msg_hash_to_str(MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR), + enum_idx, + FILE_TYPE_DIRECTORY, 0, 0); + + free(home_dir); +#endif + + return 0; +} + +static void frontend_uwp_environment_get(int *argc, char *argv[], + void *args, void *params_data) +{ + /* On UWP, we have to use the writable directory + * instead of the install directory. */ + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_ASSETS], + "~\\assets", sizeof(g_defaults.dirs[DEFAULT_DIR_ASSETS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_AUDIO_FILTER], + "~\\filters\\audio", sizeof(g_defaults.dirs[DEFAULT_DIR_AUDIO_FILTER])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_VIDEO_FILTER], + "~\\filters\\video", sizeof(g_defaults.dirs[DEFAULT_DIR_VIDEO_FILTER])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_CHEATS], + "~\\cheats", sizeof(g_defaults.dirs[DEFAULT_DIR_CHEATS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_DATABASE], + "~\\database\\rdb", sizeof(g_defaults.dirs[DEFAULT_DIR_DATABASE])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_CURSOR], + "~\\database\\cursors", sizeof(g_defaults.dirs[DEFAULT_DIR_CURSOR])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_PLAYLIST], + "~\\playlists", sizeof(g_defaults.dirs[DEFAULT_DIR_ASSETS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_RECORD_CONFIG], + "~\\config\\record", sizeof(g_defaults.dirs[DEFAULT_DIR_RECORD_CONFIG])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_RECORD_OUTPUT], + "~\\recordings", sizeof(g_defaults.dirs[DEFAULT_DIR_RECORD_OUTPUT])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_MENU_CONFIG], + "~\\config", sizeof(g_defaults.dirs[DEFAULT_DIR_MENU_CONFIG])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_REMAP], + "~\\config\\remaps", sizeof(g_defaults.dirs[DEFAULT_DIR_REMAP])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_WALLPAPERS], + "~\\assets\\wallpapers", sizeof(g_defaults.dirs[DEFAULT_DIR_WALLPAPERS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_THUMBNAILS], + "~\\thumbnails", sizeof(g_defaults.dirs[DEFAULT_DIR_THUMBNAILS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_OVERLAY], + "~\\overlays", sizeof(g_defaults.dirs[DEFAULT_DIR_OVERLAY])); + /* This one is an exception: cores have to be loaded from + * the install directory, + * since this is the only place UWP apps can take .dlls from */ + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_CORE], + ":\\cores", sizeof(g_defaults.dirs[DEFAULT_DIR_CORE])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_CORE_INFO], + "~\\info", sizeof(g_defaults.dirs[DEFAULT_DIR_CORE_INFO])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_AUTOCONFIG], + "~\\autoconfig", sizeof(g_defaults.dirs[DEFAULT_DIR_AUTOCONFIG])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_SHADER], + "~\\shaders", sizeof(g_defaults.dirs[DEFAULT_DIR_SHADER])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_CORE_ASSETS], + "~\\downloads", sizeof(g_defaults.dirs[DEFAULT_DIR_CORE_ASSETS])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_SCREENSHOT], + "~\\screenshots", sizeof(g_defaults.dirs[DEFAULT_DIR_SCREENSHOT])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_SRAM], + "~\\saves", sizeof(g_defaults.dirs[DEFAULT_DIR_SRAM])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_SAVESTATE], + "~\\states", sizeof(g_defaults.dirs[DEFAULT_DIR_SAVESTATE])); + fill_pathname_expand_special(g_defaults.dirs[DEFAULT_DIR_SYSTEM], + "~\\system", sizeof(g_defaults.dirs[DEFAULT_DIR_SYSTEM])); + +#ifdef HAVE_MENU +#if defined(HAVE_OPENGL) || defined(HAVE_OPENGLES) + snprintf(g_defaults.settings.menu, + sizeof(g_defaults.settings.menu), "xmb"); +#endif +#endif +} + +static uint64_t frontend_uwp_get_mem_total(void) +{ + /* OSes below 2000 don't have the Ex version, + * and non-Ex cannot work with >4GB RAM */ +#if _WIN32_WINNT >= 0x0500 + MEMORYSTATUSEX mem_info; + mem_info.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&mem_info); + return mem_info.ullTotalPhys; +#else + MEMORYSTATUS mem_info; + mem_info.dwLength = sizeof(MEMORYSTATUS); + GlobalMemoryStatus(&mem_info); + return mem_info.dwTotalPhys; +#endif +} + +static uint64_t frontend_uwp_get_mem_used(void) +{ + /* OSes below 2000 don't have the Ex version, + * and non-Ex cannot work with >4GB RAM */ +#if _WIN32_WINNT >= 0x0500 + MEMORYSTATUSEX mem_info; + mem_info.dwLength = sizeof(MEMORYSTATUSEX); + GlobalMemoryStatusEx(&mem_info); + return ((frontend_uwp_get_mem_total() - mem_info.ullAvailPhys)); +#else + MEMORYSTATUS mem_info; + mem_info.dwLength = sizeof(MEMORYSTATUS); + GlobalMemoryStatus(&mem_info); + return ((frontend_uwp_get_mem_total() - mem_info.dwAvailPhys)); +#endif +} + +frontend_ctx_driver_t frontend_ctx_uwp = { + frontend_uwp_environment_get, + frontend_uwp_init, + NULL, /* deinit */ + NULL, /* exitspawn */ + NULL, /* process_args */ + NULL, /* exec */ + NULL, /* set_fork */ + NULL, /* shutdown */ + NULL, /* get_name */ + frontend_uwp_get_os, + NULL, /* get_rating */ + NULL, /* load_content */ + frontend_uwp_get_architecture, + frontend_uwp_get_powerstate, + frontend_uwp_parse_drive_list, + frontend_uwp_get_mem_total, + frontend_uwp_get_mem_used, + NULL, /* install_signal_handler */ + NULL, /* get_sighandler_state */ + NULL, /* set_sighandler_state */ + NULL, /* destroy_sighandler_state */ + NULL, /* attach_console */ + NULL, /* detach_console */ + NULL, /* watch_path_for_changes */ + NULL, /* check_for_path_changes */ + NULL, /* set_sustained_performance_mode */ + "uwp" +}; diff --git a/frontend/drivers/platform_wiiu.c b/frontend/drivers/platform_wiiu.c index 69e9ffc7c4..36097fdabf 100644 --- a/frontend/drivers/platform_wiiu.c +++ b/frontend/drivers/platform_wiiu.c @@ -133,7 +133,6 @@ static void frontend_wiiu_init(void *data) DEBUG_LINE(); } - static int frontend_wiiu_get_rating(void) { return 10; @@ -168,7 +167,6 @@ static int frontend_wiiu_parse_drive_list(void *data, bool load_content) return 0; } - static void frontend_wiiu_exec(const char *path, bool should_load_game) { @@ -269,7 +267,6 @@ static void frontend_wiiu_exitspawn(char *s, size_t len) frontend_wiiu_exec(s, should_load_game); } - frontend_ctx_driver_t frontend_ctx_wiiu = { frontend_wiiu_get_environment_settings, diff --git a/frontend/drivers/platform_win32.c b/frontend/drivers/platform_win32.c index 59905c9884..afeecbeef5 100644 --- a/frontend/drivers/platform_win32.c +++ b/frontend/drivers/platform_win32.c @@ -43,6 +43,10 @@ #include "../../verbosity.h" #include "../../ui/drivers/ui_win32.h" +#ifndef SM_SERVERR2 +#define SM_SERVERR2 89 +#endif + /* We only load this library once, so we let it be * unloaded at application shutdown, since unloading * it early seems to cause issues on some systems. @@ -151,7 +155,6 @@ static void frontend_win32_get_os(char *s, size_t len, int *major, int *minor) char buildStr[11] = {0}; bool server = false; const char *arch = ""; - bool serverR2 = false; #if defined(_WIN32_WINNT) && _WIN32_WINNT >= 0x0500 /* Windows 2000 and later */ @@ -165,7 +168,6 @@ static void frontend_win32_get_os(char *s, size_t len, int *major, int *minor) GetVersionEx((OSVERSIONINFO*)&vi); server = vi.wProductType != VER_NT_WORKSTATION; - serverR2 = GetSystemMetrics(SM_SERVERR2); switch (si.wProcessorArchitecture) { @@ -189,7 +191,6 @@ static void frontend_win32_get_os(char *s, size_t len, int *major, int *minor) GetVersionEx(&vi); #endif - if (major) *major = vi.dwMajorVersion; @@ -245,10 +246,11 @@ static void frontend_win32_get_os(char *s, size_t len, int *major, int *minor) { case 2: if (server) - if (serverR2) - strlcpy(s, "Windows Server 2003 R2", len); - else - strlcpy(s, "Windows Server 2003", len); + { + strlcpy(s, "Windows Server 2003", len); + if (GetSystemMetrics(SM_SERVERR2)) + strlcat(s, " R2", len); + } else { /* Yes, XP Pro x64 is a higher version number than XP x86 */ @@ -302,6 +304,7 @@ static void frontend_win32_get_os(char *s, size_t len, int *major, int *minor) strlcat(s, " ", len); strlcat(s, vi.szCSDVersion, len); } + } static void frontend_win32_init(void *data) @@ -385,13 +388,13 @@ enum frontend_architecture frontend_win32_get_architecture(void) static int frontend_win32_parse_drive_list(void *data, bool load_content) { #ifdef HAVE_MENU + file_list_t *list = (file_list_t*)data; + enum msg_hash_enums enum_idx = load_content ? + MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR : + MSG_UNKNOWN; size_t i = 0; unsigned drives = GetLogicalDrives(); char drive[] = " :\\"; - file_list_t *list = (file_list_t*)data; - enum msg_hash_enums enum_idx = load_content ? - MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR : - MSG_UNKNOWN; for (i = 0; i < 32; i++) { @@ -506,7 +509,6 @@ static void frontend_win32_attach_console(void) { #ifdef _WIN32 #ifdef _WIN32_WINNT_WINXP - /* msys will start the process with FILE_TYPE_PIPE connected. * cmd will start the process with FILE_TYPE_UNKNOWN connected * (since this is subsystem windows application @@ -547,7 +549,6 @@ static void frontend_win32_detach_console(void) { #if defined(_WIN32) && !defined(_XBOX) #ifdef _WIN32_WINNT_WINXP - if(console_needs_free) { /* we don't reconnect stdout/stderr to anything here, @@ -556,7 +557,6 @@ static void frontend_win32_detach_console(void) FreeConsole(); console_needs_free = false; } - #endif #endif } diff --git a/frontend/frontend_driver.c b/frontend/frontend_driver.c index af5155aa7b..0a9d3fc5d2 100644 --- a/frontend/frontend_driver.c +++ b/frontend/frontend_driver.c @@ -29,6 +29,12 @@ #include "frontend_driver.h" +#ifndef __WINRT__ +#if defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#define __WINRT__ +#endif +#endif + static frontend_ctx_driver_t *frontend_ctx_drivers[] = { #if defined(EMSCRIPTEN) &frontend_ctx_emscripten, @@ -65,9 +71,12 @@ static frontend_ctx_driver_t *frontend_ctx_drivers[] = { #if defined(SWITCH) && defined(HAVE_LIBNX) &frontend_ctx_switch, #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) &frontend_ctx_win32, #endif +#if defined(__WINRT__) + &frontend_ctx_uwp, +#endif #ifdef XENON &frontend_ctx_xenon, #endif diff --git a/frontend/frontend_driver.h b/frontend/frontend_driver.h index 224a42ca70..3920a660f4 100644 --- a/frontend/frontend_driver.h +++ b/frontend/frontend_driver.h @@ -124,6 +124,7 @@ extern frontend_ctx_driver_t frontend_ctx_ps2; extern frontend_ctx_driver_t frontend_ctx_ctr; extern frontend_ctx_driver_t frontend_ctx_switch; extern frontend_ctx_driver_t frontend_ctx_win32; +extern frontend_ctx_driver_t frontend_ctx_uwp; extern frontend_ctx_driver_t frontend_ctx_xenon; extern frontend_ctx_driver_t frontend_ctx_emscripten; extern frontend_ctx_driver_t frontend_ctx_dos; diff --git a/frontend/frontend_salamander.c b/frontend/frontend_salamander.c index 52868ec0c8..42bf3f38b6 100644 --- a/frontend/frontend_salamander.c +++ b/frontend/frontend_salamander.c @@ -162,7 +162,7 @@ static void salamander_init(char *s, size_t len) if (conf) { config_set_string(conf, "libretro_path", s); - config_file_write(conf, g_defaults.path.config); + config_file_write(conf, g_defaults.path.config, true); config_file_free(conf); } } diff --git a/gfx/common/ctr_common.h b/gfx/common/ctr_common.h index daf001c3b3..ff8e2236b5 100644 --- a/gfx/common/ctr_common.h +++ b/gfx/common/ctr_common.h @@ -138,5 +138,4 @@ static INLINE void ctr_set_scale_vector(ctr_scale_vector_t* vec, vec->v = -1.0 / texture_height; } - #endif // CTR_COMMON_H__ diff --git a/gfx/common/d3d10_common.c b/gfx/common/d3d10_common.c index 1b145015f7..16a35b9c57 100644 --- a/gfx/common/d3d10_common.c +++ b/gfx/common/d3d10_common.c @@ -20,7 +20,7 @@ #include "d3d10_common.h" #include "d3dcompiler_common.h" -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) #include typedef HRESULT(WINAPI* PFN_D3D10_CREATE_DEVICE_AND_SWAP_CHAIN)( diff --git a/gfx/common/d3d10_common.h b/gfx/common/d3d10_common.h index ee8373ca57..112fdd4b41 100644 --- a/gfx/common/d3d10_common.h +++ b/gfx/common/d3d10_common.h @@ -54,7 +54,6 @@ typedef ID3D10Debug* D3D10Debug; typedef ID3D10SwitchToRef* D3D10SwitchToRef; typedef ID3D10InfoQueue* D3D10InfoQueue; - #if !defined(__cplusplus) || defined(CINTERFACE) static INLINE void D3D10SetResourceEvictionPriority(D3D10Resource resource, UINT eviction_priority) { diff --git a/gfx/common/d3d11_common.c b/gfx/common/d3d11_common.c index 16b32151e1..249033f2e7 100644 --- a/gfx/common/d3d11_common.c +++ b/gfx/common/d3d11_common.c @@ -20,9 +20,42 @@ #include "d3d11_common.h" #include "d3dcompiler_common.h" -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) #include +HRESULT WINAPI D3D11CreateDevice( + IDXGIAdapter* pAdapter, + D3D_DRIVER_TYPE DriverType, + HMODULE Software, + UINT Flags, + CONST D3D_FEATURE_LEVEL* pFeatureLevels, + UINT FeatureLevels, + UINT SDKVersion, + ID3D11Device** ppDevice, + D3D_FEATURE_LEVEL* pFeatureLevel, + ID3D11DeviceContext** ppImmediateContext) +{ + static dylib_t d3d11_dll; + static PFN_D3D11_CREATE_DEVICE fp; + + if (!d3d11_dll) + d3d11_dll = dylib_load("d3d11.dll"); + + if (!d3d11_dll) + return TYPE_E_CANTLOADLIBRARY; + + if (!fp) + fp = (PFN_D3D11_CREATE_DEVICE)dylib_proc( + d3d11_dll, "D3D11CreateDevice"); + + if (!fp) + return TYPE_E_DLLFUNCTIONNOTFOUND; + + return fp( + pAdapter, DriverType, Software, Flags, pFeatureLevels, FeatureLevels, SDKVersion, + ppDevice, pFeatureLevel, ppImmediateContext); +} + HRESULT WINAPI D3D11CreateDeviceAndSwapChain( IDXGIAdapter* pAdapter, D3D_DRIVER_TYPE DriverType, diff --git a/gfx/common/d3d11_common.h b/gfx/common/d3d11_common.h index 69128cd07a..db6254e8c1 100644 --- a/gfx/common/d3d11_common.h +++ b/gfx/common/d3d11_common.h @@ -2159,6 +2159,7 @@ static INLINE HRESULT D3D11ValidateContextForDispatch(D3D11Debug debug, D3D11Dev { return debug->lpVtbl->ValidateContextForDispatch(debug, context); } +#ifndef __WINRT__ static INLINE BOOL D3D11SetUseRef(D3D11SwitchToRef switch_to_ref, BOOL use_ref) { return switch_to_ref->lpVtbl->SetUseRef(switch_to_ref, use_ref); @@ -2167,6 +2168,7 @@ static INLINE BOOL D3D11GetUseRef(D3D11SwitchToRef switch_to_ref) { return switch_to_ref->lpVtbl->GetUseRef(switch_to_ref); } +#endif static INLINE HRESULT D3D11SetShaderTrackingOptionsByType( D3D11TracingDevice tracing_device, UINT resource_type_flags, UINT options) { @@ -2188,6 +2190,7 @@ static INLINE void D3D11ClearStoredMessages(D3D11InfoQueue info_queue) { info_queue->lpVtbl->ClearStoredMessages(info_queue); } +#ifndef __WINRT__ static INLINE HRESULT D3D11GetMessageA( D3D11InfoQueue info_queue, UINT64 message_index, @@ -2196,6 +2199,7 @@ static INLINE HRESULT D3D11GetMessageA( { return info_queue->lpVtbl->GetMessageA(info_queue, message_index, message, message_byte_length); } +#endif static INLINE UINT64 D3D11GetNumMessagesAllowedByStorageFilter(D3D11InfoQueue info_queue) { return info_queue->lpVtbl->GetNumMessagesAllowedByStorageFilter(info_queue); diff --git a/gfx/common/d3d12_common.c b/gfx/common/d3d12_common.c index 1b8d9478c5..e328af6a1b 100644 --- a/gfx/common/d3d12_common.c +++ b/gfx/common/d3d12_common.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2014-2018 - Ali Bouhlel * * RetroArch is free software: you can redistribute it and/or modify it under the terms @@ -65,7 +65,7 @@ DEFINE_GUIDW(IID_ID3D12DebugCommandList, 0x09e0bf36, 0x54ac, 0x484f, 0x88, 0x47, /* clang-format on */ #endif -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) static dylib_t d3d12_dll; static const char* d3d12_dll_name = "d3d12.dll"; @@ -159,15 +159,24 @@ bool d3d12_init_base(d3d12_video_t* d3d12) D3D12EnableDebugLayer(d3d12->debugController); #endif +#ifdef __WINRT__ + DXGICreateFactory2(&d3d12->factory); +#else DXGICreateFactory(&d3d12->factory); +#endif { int i = 0; while (true) { +#ifdef __WINRT__ + if (FAILED(DXGIEnumAdapters2(d3d12->factory, i++, &d3d12->adapter))) + return false; +#else if (FAILED(DXGIEnumAdapters(d3d12->factory, i++, &d3d12->adapter))) return false; +#endif if (SUCCEEDED(D3D12CreateDevice_(d3d12->adapter, D3D_FEATURE_LEVEL_11_0, &d3d12->device))) break; @@ -207,17 +216,28 @@ bool d3d12_init_queue(d3d12_video_t* d3d12) } bool d3d12_init_swapchain(d3d12_video_t* d3d12, - int width, int height, HWND hwnd) + int width, int height, void* corewindow) { unsigned i; +#ifdef __WINRT__ + DXGI_SWAP_CHAIN_DESC1 desc; + memset(&desc, 0, sizeof(DXGI_SWAP_CHAIN_DESC1)); +#else DXGI_SWAP_CHAIN_DESC desc; - + HWND hwnd = (HWND)corewindow; memset(&desc, 0, sizeof(DXGI_SWAP_CHAIN_DESC)); +#endif desc.BufferCount = countof(d3d12->chain.renderTargets); +#ifdef __WINRT__ + desc.Width = width; + desc.Height = height; + desc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; +#else desc.BufferDesc.Width = width; desc.BufferDesc.Height = height; desc.BufferDesc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; +#endif desc.SampleDesc.Count = 1; #if 0 desc.BufferDesc.RefreshRate.Numerator = 60; @@ -225,16 +245,25 @@ bool d3d12_init_swapchain(d3d12_video_t* d3d12, desc.SampleDesc.Quality = 0; #endif desc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT; +#ifdef HAVE_WINDOW desc.OutputWindow = hwnd; desc.Windowed = TRUE; +#endif #if 0 desc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_SEQUENTIAL; #else desc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_DISCARD; #endif - DXGICreateSwapChain(d3d12->factory, d3d12->queue.handle, &desc, &d3d12->chain.handle); +#ifdef __WINRT__ + DXGICreateSwapChainForCoreWindow(d3d12->factory, d3d12->queue.handle, corewindow, &desc, NULL, &d3d12->chain.handle); +#else + DXGICreateSwapChain(d3d12->factory, d3d12->queue.handle, &desc, &d3d12->chain.handle); +#endif + +#ifdef HAVE_WINDOW DXGIMakeWindowAssociation(d3d12->factory, hwnd, DXGI_MWA_NO_ALT_ENTER); +#endif d3d12->chain.frame_index = DXGIGetCurrentBackBufferIndex(d3d12->chain.handle); @@ -291,7 +320,7 @@ static D3D12_CPU_DESCRIPTOR_HANDLE d3d12_descriptor_heap_slot_alloc(d3d12_descri static void d3d12_descriptor_heap_slot_free(d3d12_descriptor_heap_t* heap, D3D12_CPU_DESCRIPTOR_HANDLE handle) { - int i; + unsigned i; if (!handle.ptr) return; @@ -303,7 +332,7 @@ d3d12_descriptor_heap_slot_free(d3d12_descriptor_heap_t* heap, D3D12_CPU_DESCRIP assert(heap->map[i]); heap->map[i] = false; - if (heap->start > i) + if (heap->start > (int)i) heap->start = i; } diff --git a/gfx/common/d3d12_common.h b/gfx/common/d3d12_common.h index 8bb2bca7d6..5d4e221a3d 100644 --- a/gfx/common/d3d12_common.h +++ b/gfx/common/d3d12_common.h @@ -1001,6 +1001,7 @@ static INLINE void D3D12ClearStoredMessages(D3D12InfoQueue info_queue) { info_queue->lpVtbl->ClearStoredMessages(info_queue); } +#ifndef __WINRT__ static INLINE HRESULT D3D12GetMessageA( D3D12InfoQueue info_queue, UINT64 message_index, @@ -1009,6 +1010,7 @@ static INLINE HRESULT D3D12GetMessageA( { return info_queue->lpVtbl->GetMessageA(info_queue, message_index, message, message_byte_length); } +#endif static INLINE UINT64 D3D12GetNumMessagesAllowedByStorageFilter(D3D12InfoQueue info_queue) { return info_queue->lpVtbl->GetNumMessagesAllowedByStorageFilter(info_queue); @@ -1341,7 +1343,11 @@ static_assert( typedef struct { unsigned cur_mon_id; +#ifdef __WINRT__ + DXGIFactory2 factory; +#else DXGIFactory factory; +#endif DXGIAdapter adapter; D3D12Device device; @@ -1499,7 +1505,7 @@ bool d3d12_init_pipeline( D3D12_GRAPHICS_PIPELINE_STATE_DESC* desc, D3D12PipelineState* out); -bool d3d12_init_swapchain(d3d12_video_t* d3d12, int width, int height, HWND hwnd); +bool d3d12_init_swapchain(d3d12_video_t* d3d12, int width, int height, void *corewindow); bool d3d12_init_queue(d3d12_video_t* d3d12); diff --git a/gfx/common/d3d8_common.c b/gfx/common/d3d8_common.c index f05ab1a18a..da21f1103f 100644 --- a/gfx/common/d3d8_common.c +++ b/gfx/common/d3d8_common.c @@ -75,7 +75,6 @@ typedef HRESULT (__stdcall LPD3DXFONT* ppFont); #endif - #ifdef HAVE_D3DX static D3DXCreateFontIndirect_t D3DCreateFontIndirect; static D3DCreateTextureFromFile_t D3DCreateTextureFromFile; diff --git a/gfx/common/d3d9_common.c b/gfx/common/d3d9_common.c index 21f279dc48..ac0b567011 100644 --- a/gfx/common/d3d9_common.c +++ b/gfx/common/d3d9_common.c @@ -99,7 +99,6 @@ typedef HRESULT (__stdcall LPD3DXFONT* ppFont); #endif - #ifdef HAVE_D3DX static D3D9XCreateFontIndirect_t D3D9CreateFontIndirect; static D3D9CreateTextureFromFile_t D3D9CreateTextureFromFile; diff --git a/gfx/common/d3d_common.c b/gfx/common/d3d_common.c index c026c3c9f2..8e8fff7099 100644 --- a/gfx/common/d3d_common.c +++ b/gfx/common/d3d_common.c @@ -12,6 +12,7 @@ * You should have received a copy of the GNU General Public License along with RetroArch. * If not, see . */ +#include #include "../../configuration.h" #include "../../verbosity.h" @@ -35,7 +36,6 @@ void *d3d_matrix_transpose(void *_pout, const void *_pm) return pout; } - void *d3d_matrix_identity(void *_pout) { struct d3d_matrix *pout = (struct d3d_matrix*)_pout; @@ -88,8 +88,10 @@ void *d3d_matrix_multiply(void *_pout, for (i = 0; i < 4; i++) { for (j = 0; j < 4; j++) - pout->m[i][j] = pm1->m[i][0] * pm2->m[0][j] + pm1->m[i][1] * pm2->m[1][j] + - pm1->m[i][2] * pm2->m[2][j] + pm1->m[i][3] * pm2->m[3][j]; + pout->m[i][j] = pm1->m[i][0] * + pm2->m[0][j] + pm1->m[i][1] * pm2->m[1][j] + + pm1->m[i][2] * pm2->m[2][j] + + pm1->m[i][3] * pm2->m[3][j]; } return pout; } @@ -125,3 +127,43 @@ int32_t d3d_translate_filter(unsigned type) return (int32_t)D3D_TEXTURE_FILTER_POINT; } + +void d3d_input_driver(const char* input_name, const char* joypad_name, const input_driver_t** input, void** input_data) +{ +#if defined(__WINRT__) + /* Plain xinput is supported on UWP, but it + * supports joypad only (uwp driver was added later) */ + if (string_is_equal(input_name, "xinput")) + { + void *xinput = input_xinput.init(joypad_name); + *input = xinput ? (const input_driver_t*)&input_xinput : NULL; + *input_data = xinput; + } + else + { + void *uwp = input_uwp.init(joypad_name); + *input = uwp ? (const input_driver_t*)&input_uwp : NULL; + *input_data = uwp; + } +#elif defined(_XBOX) + void *xinput = input_xinput.init(joypad_name); + *input = xinput ? (const input_driver_t*)&input_xinput : NULL; + *input_data = xinput; +#else +#if _WIN32_WINNT >= 0x0501 + /* winraw only available since XP */ + if (string_is_equal(input_name, "raw")) + { + *input_data = input_winraw.init(joypad_name); + if (*input_data) + { + *input = &input_winraw; + return; + } + } +#endif + + *input_data = input_dinput.init(joypad_name); + *input = *input_data ? &input_dinput : NULL; +#endif +} diff --git a/gfx/common/d3d_common.h b/gfx/common/d3d_common.h index 69c9ae6526..326a50705e 100644 --- a/gfx/common/d3d_common.h +++ b/gfx/common/d3d_common.h @@ -20,10 +20,18 @@ #include "../../config.h" #endif -#ifndef _XBOX +#if !defined(__WINRT__) && !defined(_XBOX) + +#ifndef HAVE_WINDOW #define HAVE_WINDOW #endif +#ifndef HAVE_MONITOR +#define HAVE_MONITOR +#endif + +#endif + #include #include @@ -46,7 +54,6 @@ struct d3d_matrix }; }; - typedef struct d3d_texture { void *data; @@ -97,6 +104,9 @@ void *d3d_matrix_rotation_z(void *_pout, float angle); int32_t d3d_translate_filter(unsigned type); +void d3d_input_driver(const char* input_name, + const char* joypad_name, const input_driver_t** input, void** input_data); + RETRO_END_DECLS #endif diff --git a/gfx/common/d3dcompiler_common.c b/gfx/common/d3dcompiler_common.c index 6da87c1ba4..22d17704a3 100644 --- a/gfx/common/d3dcompiler_common.c +++ b/gfx/common/d3dcompiler_common.c @@ -25,7 +25,7 @@ #include "d3dcompiler_common.h" #include "../../verbosity.h" -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) #include static dylib_t d3dcompiler_dll; diff --git a/gfx/common/dxgi_common.c b/gfx/common/dxgi_common.c index 3d935f41d2..86f4a7b987 100644 --- a/gfx/common/dxgi_common.c +++ b/gfx/common/dxgi_common.c @@ -30,7 +30,7 @@ #include "../video_driver.h" #include "win32_common.h" -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) #include HRESULT WINAPI CreateDXGIFactory1(REFIID riid, void** ppFactory) @@ -309,6 +309,7 @@ void dxgi_update_title(video_frame_info_t* video_info) if (settings->bools.video_memory_show) { +#ifndef __WINRT__ MEMORYSTATUS stat; char mem[128]; @@ -319,6 +320,7 @@ void dxgi_update_title(video_frame_info_t* video_info) mem, sizeof(mem), " || MEM: %.2f/%.2fMB", stat.dwAvailPhys / (1024.0f * 1024.0f), stat.dwTotalPhys / (1024.0f * 1024.0f)); strlcat(video_info->fps_text, mem, sizeof(video_info->fps_text)); +#endif } if (window) @@ -329,32 +331,11 @@ void dxgi_update_title(video_frame_info_t* video_info) video_driver_get_window_title(title, sizeof(title)); +#ifndef __WINRT__ if (title[0]) window->set_title(&main_window, title); - } -} - -void dxgi_input_driver(const char* name, const input_driver_t** input, void** input_data) -{ -#ifndef __WINRT__ - settings_t* settings = config_get_ptr(); - -#if _WIN32_WINNT >= 0x0501 - /* winraw only available since XP */ - if (string_is_equal(settings->arrays.input_driver, "raw")) - { - *input_data = input_winraw.init(name); - if (*input_data) - { - *input = &input_winraw; - return; - } - } -#endif - - *input_data = input_dinput.init(name); - *input = *input_data ? &input_dinput : NULL; #endif + } } DXGI_FORMAT glslang_format_to_dxgi(glslang_format fmt) diff --git a/gfx/common/dxgi_common.h b/gfx/common/dxgi_common.h index 0323b5d839..485142b099 100644 --- a/gfx/common/dxgi_common.h +++ b/gfx/common/dxgi_common.h @@ -270,6 +270,9 @@ typedef IDXGISurface1* DXGISurface; typedef IDXGIOutput* DXGIOutput; typedef IDXGIDevice* DXGIDevice; typedef IDXGIFactory1* DXGIFactory; +#ifdef __WINRT__ +typedef IDXGIFactory2* DXGIFactory2; +#endif typedef IDXGIAdapter1* DXGIAdapter; typedef IDXGIDisplayControl* DXGIDisplayControl; typedef IDXGIOutputDuplication* DXGIOutputDuplication; @@ -414,6 +417,14 @@ static INLINE HRESULT DXGICreateSwapChain( return factory->lpVtbl->CreateSwapChain( factory, (IUnknown*)device, desc, (IDXGISwapChain**)swap_chain); } +#ifdef __WINRT__ +static INLINE HRESULT DXGICreateSwapChainForCoreWindow( + DXGIFactory2 factory, void* device, void* corewindow, DXGI_SWAP_CHAIN_DESC1* desc, DXGIOutput restrict_to, DXGISwapChain* swap_chain) +{ + return factory->lpVtbl->CreateSwapChainForCoreWindow( + factory, (IUnknown*)device, (IUnknown*)corewindow, desc, restrict_to, (IDXGISwapChain1**)swap_chain); +} +#endif static INLINE HRESULT DXGICreateSoftwareAdapter(DXGIFactory factory, HMODULE module, DXGIAdapter* adapter) { @@ -423,6 +434,12 @@ static INLINE HRESULT DXGIEnumAdapters(DXGIFactory factory, UINT id, DXGIAdapter { return factory->lpVtbl->EnumAdapters1(factory, id, adapter); } +#ifdef __WINRT__ +static INLINE HRESULT DXGIEnumAdapters2(DXGIFactory2 factory, UINT id, DXGIAdapter* adapter) +{ + return factory->lpVtbl->EnumAdapters1(factory, id, adapter); +} +#endif static INLINE BOOL DXGIIsCurrent(DXGIFactory factory) { return factory->lpVtbl->IsCurrent(factory); @@ -444,6 +461,7 @@ static INLINE HRESULT DXGIGetAdapterDesc1(DXGIAdapter adapter, DXGI_ADAPTER_DESC { return adapter->lpVtbl->GetDesc1(adapter, desc); } +#ifndef __WINRT__ static INLINE ULONG DXGIReleaseDisplayControl(DXGIDisplayControl display_control) { return display_control->lpVtbl->Release(display_control); @@ -612,6 +630,7 @@ static INLINE HRESULT DXGICheckPresentDurationSupport( swap_chain_media, desired_present_duration, closest_smaller_present_duration, closest_larger_present_duration); } +#endif static INLINE ULONG DXGIReleaseSwapChain(DXGISwapChain swap_chain) { return swap_chain->lpVtbl->Release(swap_chain); @@ -758,6 +777,12 @@ static INLINE HRESULT DXGICreateFactory(DXGIFactory* factory) { return CreateDXGIFactory1(uuidof(IDXGIFactory1), (void**)factory); } +#ifdef __WINRT__ +static INLINE HRESULT DXGICreateFactory2(DXGIFactory2* factory) +{ + return CreateDXGIFactory1(uuidof(IDXGIFactory2), (void**)factory); +} +#endif /* internal */ @@ -793,7 +818,6 @@ void dxgi_copy( void* dst_data); void dxgi_update_title(video_frame_info_t* video_info); -void dxgi_input_driver(const char* name, const input_driver_t** input, void** input_data); DXGI_FORMAT glslang_format_to_dxgi(glslang_format fmt); diff --git a/gfx/common/metal_common.h b/gfx/common/metal_common.h index 4fbefa25ac..d8f934946a 100644 --- a/gfx/common/metal_common.h +++ b/gfx/common/metal_common.h @@ -44,7 +44,6 @@ extern MTLPixelFormat SelectOptimalPixelFormat(MTLPixelFormat fmt); @end - @interface MetalMenu : NSObject @property (nonatomic, readonly) bool hasFrame; @@ -59,7 +58,6 @@ extern MTLPixelFormat SelectOptimalPixelFormat(MTLPixelFormat fmt); filter:(RTextureFilter)filter; @end - @interface Overlay : NSObject @property (nonatomic, readwrite) bool enabled; @property (nonatomic, readwrite) bool fullscreen; diff --git a/gfx/common/vulkan_common.h b/gfx/common/vulkan_common.h index 69c9758819..1b6469525b 100644 --- a/gfx/common/vulkan_common.h +++ b/gfx/common/vulkan_common.h @@ -264,7 +264,6 @@ void vulkan_buffer_chain_free( VkDevice device, struct vk_buffer_chain *chain); - struct vk_descriptor_pool { VkDescriptorPool pool; @@ -444,7 +443,6 @@ uint32_t vulkan_find_memory_type_fallback( uint32_t device_reqs, uint32_t host_reqs_first, uint32_t host_reqs_second); - struct vk_texture vulkan_create_texture(vk_t *vk, struct vk_texture *old, unsigned width, unsigned height, diff --git a/gfx/common/wayland/generate_wayland_protos.sh b/gfx/common/wayland/generate_wayland_protos.sh index 8c0cc7f155..0c50161ed3 100755 --- a/gfx/common/wayland/generate_wayland_protos.sh +++ b/gfx/common/wayland/generate_wayland_protos.sh @@ -3,6 +3,11 @@ WAYSCAN=/usr/bin/wayland-scanner WAYLAND_PROTOS=/usr/share/wayland-protocols OUTPUT=gfx/common/wayland +if [ ! -d $WAYLAND_PROTOS ]; then + WAYSCAN=/usr/local/bin/wayland-scanner + WAYLAND_PROTOS=/usr/local/share/wayland-protocols +fi + if [ ! -d $OUTPUT ]; then mkdir $OUTPUT fi diff --git a/gfx/common/wayland_common.h b/gfx/common/wayland_common.h index 3cbedb9048..84d284cfd0 100644 --- a/gfx/common/wayland_common.h +++ b/gfx/common/wayland_common.h @@ -37,7 +37,6 @@ typedef struct int16_t y; } wayland_touch_data_t; - typedef struct input_ctx_wayland_data { /* Wayland uses Linux keysyms. */ diff --git a/gfx/common/win32_common.c b/gfx/common/win32_common.c index 567b524f31..fa78658a35 100644 --- a/gfx/common/win32_common.c +++ b/gfx/common/win32_common.c @@ -180,8 +180,6 @@ typedef struct DISPLAYCONFIG_PATH_TARGET_INFO_CUSTOM { UINT32 statusFlags; } DISPLAYCONFIG_PATH_TARGET_INFO_CUSTOM; - - typedef struct DISPLAYCONFIG_PATH_INFO_CUSTOM { DISPLAYCONFIG_PATH_SOURCE_INFO_CUSTOM sourceInfo; DISPLAYCONFIG_PATH_TARGET_INFO_CUSTOM targetInfo; @@ -345,7 +343,6 @@ INT_PTR_COMPAT CALLBACK PickCoreProc(HWND hDlg, UINT message, return FALSE; } - static BOOL CALLBACK win32_monitor_enum_proc(HMONITOR hMonitor, HDC hdcMonitor, LPRECT lprcMonitor, LPARAM dwData) { @@ -353,7 +350,6 @@ static BOOL CALLBACK win32_monitor_enum_proc(HMONITOR hMonitor, return TRUE; } - void win32_monitor_from_window(void) { #ifndef _XBOX @@ -593,11 +589,13 @@ static LRESULT win32_handle_keyboard_event(HWND hwnd, UINT message, keysym = (unsigned)wparam; else #endif +#ifdef HAVE_DINPUT { /* extended keys will map to dinput if the high bit is set */ if (input_get_ptr() == &input_dinput && (lparam >> 24 & 0x1)) keysym |= 0x80; } +#endif /* Key released? */ if (message == WM_KEYUP || message == WM_SYSKEYUP) keydown = false; @@ -1335,7 +1333,6 @@ bool win32_set_video_mode(void *data, &mon_rect, width, height, fullscreen)) return false; - win32_set_window(&width, &height, fullscreen, windowed_full, &rect); diff --git a/gfx/common/x11_common.c b/gfx/common/x11_common.c index 6007a9b794..b8814f9dde 100644 --- a/gfx/common/x11_common.c +++ b/gfx/common/x11_common.c @@ -55,7 +55,6 @@ #define MOVERESIZE_X_SHIFT 8 #define MOVERESIZE_Y_SHIFT 9 - static XF86VidModeModeInfo desktop_mode; static bool xdg_screensaver_available = true; bool g_x11_entered = false; diff --git a/gfx/display_servers/dispserv_win32.c b/gfx/display_servers/dispserv_win32.c index 6563441bd5..0a1a4513b0 100644 --- a/gfx/display_servers/dispserv_win32.c +++ b/gfx/display_servers/dispserv_win32.c @@ -82,6 +82,12 @@ static void* win32_display_server_init(void) return NULL; #ifdef HAS_TASKBAR_EXT + if (FAILED(CoInitialize(NULL))) + { + RARCH_ERR("COM initialization failed, ITaskbarList3 disabled\n"); + return dispserv; + } + #ifdef __cplusplus /* When compiling in C++ mode, GUIDs are references instead of pointers */ hr = CoCreateInstance(CLSID_TaskbarList, NULL, @@ -96,6 +102,7 @@ static void* win32_display_server_init(void) { g_taskbarList = NULL; RARCH_ERR("[dispserv]: CoCreateInstance of ITaskbarList3 failed.\n"); + CoUninitialize(); } #endif @@ -115,6 +122,7 @@ static void win32_display_server_destroy(void *data) { ITaskbarList3_Release(g_taskbarList); g_taskbarList = NULL; + CoUninitialize(); } #endif diff --git a/gfx/drivers/ctr_gfx.c b/gfx/drivers/ctr_gfx.c index 4857e09dd7..ee59e53baf 100644 --- a/gfx/drivers/ctr_gfx.c +++ b/gfx/drivers/ctr_gfx.c @@ -128,7 +128,6 @@ static INLINE void ctr_set_screen_coords(ctr_video_t * ctr) } } - static void ctr_update_viewport(ctr_video_t* ctr, video_frame_info_t *video_info) { int x = 0; @@ -203,7 +202,6 @@ static void ctr_update_viewport(ctr_video_t* ctr, video_frame_info_t *video_info } - static void ctr_lcd_aptHook(APT_HookType hook, void* param) { ctr_video_t *ctr = (ctr_video_t*)param; @@ -534,7 +532,6 @@ static bool ctr_frame(void* data, const void* frame, ctr_set_bottom_screen_enable(ctr, !ctr_bottom_screen_enabled); } - if (ctr->p3d_event_pending) { gspWaitForEvent(GSPGPU_EVENT_P3D, false); @@ -576,7 +573,6 @@ static bool ctr_frame(void* data, const void* frame, frames = 0; } - #ifdef CTR_INSPECT_MEMORY_USAGE uint32_t ctr_get_stack_usage(void); void ctr_linear_get_stats(void); @@ -821,7 +817,6 @@ static bool ctr_frame(void* data, const void* frame, CTRGU_RGBA8, gfxTopLeftFramebuffers[ctr->current_buffer_top], 240,CTRGU_RGB8, CTRGU_MULTISAMPLE_NONE); - if ((ctr->video_mode == CTR_VIDEO_MODE_400x240) || (ctr->video_mode == CTR_VIDEO_MODE_3D)) ctrGuDisplayTransfer(true, ctr->drawbuffers.top.right, 240, @@ -829,7 +824,6 @@ static bool ctr_frame(void* data, const void* frame, CTRGU_RGBA8, gfxTopRightFramebuffers[ctr->current_buffer_top], 240,CTRGU_RGB8, CTRGU_MULTISAMPLE_NONE); - /* Swap buffers : */ topFramebufferInfo. @@ -852,7 +846,6 @@ static bool ctr_frame(void* data, const void* frame, framebuf_widthbytesize = 240 * 3; } - topFramebufferInfo.format = (1<<8)|(1<<5)|GSP_BGR8_OES; topFramebufferInfo. framebuf_dispselect = ctr->current_buffer_top; @@ -979,7 +972,6 @@ static void ctr_set_texture_enable(void* data, bool state, bool full_screen) ctr->menu_texture_enable = state; } - static void ctr_set_rotation(void* data, unsigned rotation) { ctr_video_t* ctr = (ctr_video_t*)data; @@ -1069,7 +1061,6 @@ static uintptr_t ctr_load_texture(void *video_data, void *data, texture->data = linearAlloc(texture->width * texture->height * sizeof(uint32_t)); texture->type = filter_type; - if (!texture->data) { free(texture); @@ -1108,7 +1099,6 @@ static uintptr_t ctr_load_texture(void *video_data, void *data, src++; } - GSPGPU_FlushDataCache(tmpdata, image->width * image->height * sizeof(uint32_t)); ctrGuCopyImage(true, tmpdata, image->width, image->height, CTRGU_RGBA8, false, texture->data, texture->width, CTRGU_RGBA8, true); diff --git a/gfx/drivers/ctr_gu.h b/gfx/drivers/ctr_gu.h index 01f6dd1d49..0307604ddd 100644 --- a/gfx/drivers/ctr_gu.h +++ b/gfx/drivers/ctr_gu.h @@ -65,7 +65,6 @@ static INLINE Result ctr_set_parallax_layer(bool state) return GSPGPU_WriteHWRegs(0x202000, ®_state, 4); } - __attribute__((always_inline)) static INLINE void ctrGuSetTexture(GPU_TEXUNIT unit, u32* data, u16 width, u16 height, u32 param, GPU_TEXCOLOR colorType) @@ -198,7 +197,6 @@ static INLINE void ctrGuSetVertexShaderFloatUniform(int id, float* data, int cou GPUCMD_AddWrites(GPUREG_VSH_FLOATUNIFORM_DATA, (u32*)data, (u32)count * 4); } - #define CTRGU_ATTRIBFMT(f, n) ((((n)-1)<<2)|((f)&3)) __attribute__((always_inline)) @@ -243,7 +241,6 @@ static INLINE int ctrgu_swizzle_coords(int x, int y, int width) int pos = (x & 0x1) << 0 | ((x & 0x2) << 1) | ((x & 0x4) << 2) | (y & 0x1) << 1 | ((y & 0x2) << 2) | ((y & 0x4) << 3); - return ((x >> 3) << 6) + ((y >> 3) * ((width >> 3) << 6)) + pos; } diff --git a/gfx/drivers/d3d10.c b/gfx/drivers/d3d10.c index b123cda661..3bc731b11a 100644 --- a/gfx/drivers/d3d10.c +++ b/gfx/drivers/d3d10.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2014-2018 - Ali Bouhlel * * RetroArch is free software: you can redistribute it and/or modify it under the terms @@ -27,6 +27,7 @@ #include "../video_driver.h" #include "../font_driver.h" +#include "../common/d3d_common.h" #include "../common/win32_common.h" #include "../common/d3d10_common.h" #include "../common/dxgi_common.h" @@ -35,6 +36,10 @@ #include "../../menu/menu_driver.h" #endif +#ifdef __WINRT__ +#error "UWP does not support D3D10" +#endif + #ifdef HAVE_OVERLAY static void d3d10_free_overlays(d3d10_video_t* d3d10) { @@ -212,7 +217,6 @@ static void d3d10_set_filtering(void* data, unsigned index, bool smooth) } } - static void d3d10_gfx_set_rotation(void* data, unsigned rotation) { math_matrix_4x4 rot; @@ -556,8 +560,12 @@ static void d3d10_gfx_free(void* data) Release(d3d10->device); } +#ifdef HAVE_MONITOR win32_monitor_from_window(); +#endif +#ifdef HAVE_WINDOW win32_destroy_window(); +#endif free(d3d10); } @@ -566,31 +574,41 @@ d3d10_gfx_init(const video_info_t* video, const input_driver_t** input, void** input_data) { unsigned i; +#ifdef HAVE_MONITOR MONITORINFOEX current_mon; HMONITOR hm_to_use; WNDCLASSEX wndclass = { 0 }; +#endif settings_t* settings = config_get_ptr(); d3d10_video_t* d3d10 = (d3d10_video_t*)calloc(1, sizeof(*d3d10)); if (!d3d10) return NULL; +#ifdef HAVE_WINDOW win32_window_reset(); +#endif +#ifdef HAVE_MONITOR win32_monitor_init(); wndclass.lpfnWndProc = WndProcD3D; +#ifdef HAVE_WINDOW win32_window_init(&wndclass, true, NULL); +#endif win32_monitor_info(¤t_mon, &hm_to_use, &d3d10->cur_mon_id); +#endif d3d10->vp.full_width = video->width; d3d10->vp.full_height = video->height; +#ifdef HAVE_MONITOR if (!d3d10->vp.full_width) d3d10->vp.full_width = current_mon.rcMonitor.right - current_mon.rcMonitor.left; if (!d3d10->vp.full_height) d3d10->vp.full_height = current_mon.rcMonitor.bottom - current_mon.rcMonitor.top; +#endif if (!win32_set_video_mode(d3d10, d3d10->vp.full_width, d3d10->vp.full_height, video->fullscreen)) @@ -598,7 +616,7 @@ d3d10_gfx_init(const video_info_t* video, RARCH_ERR("[D3D10]: win32_set_video_mode failed.\n"); goto error; } - dxgi_input_driver(settings->arrays.input_joypad_driver, input, input_data); + d3d_input_driver(settings->arrays.input_driver, settings->arrays.input_joypad_driver, input, input_data); { UINT flags = 0; @@ -611,7 +629,9 @@ d3d10_gfx_init(const video_info_t* video, desc.BufferDesc.RefreshRate.Numerator = 60; desc.BufferDesc.RefreshRate.Denominator = 1; desc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT; +#ifdef HAVE_WINDOW desc.OutputWindow = main_window.hwnd; +#endif desc.SampleDesc.Count = 1; desc.SampleDesc.Quality = 0; desc.Windowed = TRUE; @@ -1598,7 +1618,12 @@ static const video_poke_interface_t d3d10_poke_interface = { d3d10_gfx_load_texture, d3d10_gfx_unload_texture, NULL, /* set_video_mode */ +#ifndef __WINRT__ win32_get_refresh_rate, +#else + /* UWP does not expose this information easily */ + NULL, +#endif d3d10_set_filtering, NULL, /* get_video_output_size */ NULL, /* get_video_output_prev */ diff --git a/gfx/drivers/d3d11.c b/gfx/drivers/d3d11.c index 137ad02525..6e0850b712 100644 --- a/gfx/drivers/d3d11.c +++ b/gfx/drivers/d3d11.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2014-2018 - Ali Bouhlel * * RetroArch is free software: you can redistribute it and/or modify it under the terms @@ -34,6 +34,7 @@ #include "../video_shader_parse.h" #include "../drivers_shader/slang_preprocess.h" +#include "../common/d3d_common.h" #include "../common/d3d11_common.h" #include "../common/dxgi_common.h" #include "../common/d3dcompiler_common.h" @@ -41,11 +42,14 @@ #include "../drivers_shader/slang_process.h" #endif +#ifdef __WINRT__ +#include "../../uwp/uwp_func.h" +#endif + static D3D11Device cached_device_d3d11; static D3D_FEATURE_LEVEL cached_supportedFeatureLevel; static D3D11DeviceContext cached_context; - #ifdef HAVE_OVERLAY static void d3d11_free_overlays(d3d11_video_t* d3d11) { @@ -566,8 +570,12 @@ static void d3d11_gfx_free(void* data) Release(d3d11->device); } +#ifdef HAVE_MONITOR win32_monitor_from_window(); +#endif +#ifdef HAVE_WINDOW win32_destroy_window(); +#endif free(d3d11); } @@ -575,29 +583,39 @@ static void d3d11_gfx_free(void* data) d3d11_gfx_init(const video_info_t* video, const input_driver_t** input, void** input_data) { unsigned i; +#ifdef HAVE_MONITOR MONITORINFOEX current_mon; HMONITOR hm_to_use; WNDCLASSEX wndclass = { 0 }; +#endif settings_t* settings = config_get_ptr(); d3d11_video_t* d3d11 = (d3d11_video_t*)calloc(1, sizeof(*d3d11)); if (!d3d11) return NULL; +#ifdef HAVE_WINDOW win32_window_reset(); +#endif +#ifdef HAVE_MONITOR win32_monitor_init(); wndclass.lpfnWndProc = WndProcD3D; +#ifdef HAVE_WINDOW win32_window_init(&wndclass, true, NULL); +#endif win32_monitor_info(¤t_mon, &hm_to_use, &d3d11->cur_mon_id); +#endif d3d11->vp.full_width = video->width; d3d11->vp.full_height = video->height; +#ifdef HAVE_MONITOR if (!d3d11->vp.full_width) d3d11->vp.full_width = current_mon.rcMonitor.right - current_mon.rcMonitor.left; if (!d3d11->vp.full_height) d3d11->vp.full_height = current_mon.rcMonitor.bottom - current_mon.rcMonitor.top; +#endif if (!win32_set_video_mode(d3d11, d3d11->vp.full_width, d3d11->vp.full_height, video->fullscreen)) { @@ -605,7 +623,7 @@ d3d11_gfx_init(const video_info_t* video, const input_driver_t** input, void** i goto error; } - dxgi_input_driver(settings->arrays.input_joypad_driver, input, input_data); + d3d_input_driver(settings->arrays.input_driver, settings->arrays.input_joypad_driver, input, input_data); { UINT flags = 0; @@ -617,26 +635,45 @@ d3d11_gfx_init(const video_info_t* video, const input_driver_t** input, void** i D3D_FEATURE_LEVEL_10_0, D3D_FEATURE_LEVEL_9_3 }; +#ifdef __WINRT__ + /* UWP requires the use of newer version of the factory which requires newer version of this struct */ + DXGI_SWAP_CHAIN_DESC1 desc = { 0 }; +#else DXGI_SWAP_CHAIN_DESC desc = { 0 }; +#endif UINT number_feature_levels = ARRAY_SIZE(requested_feature_levels); - desc.BufferCount = 1; +#ifdef __WINRT__ + /* UWP forces us to do double-buffering */ + desc.BufferCount = 2; + desc.Width = d3d11->vp.full_width; + desc.Height = d3d11->vp.full_height; + desc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; +#else + desc.BufferCount = 1; desc.BufferDesc.Width = d3d11->vp.full_width; desc.BufferDesc.Height = d3d11->vp.full_height; desc.BufferDesc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; desc.BufferDesc.RefreshRate.Numerator = 60; desc.BufferDesc.RefreshRate.Denominator = 1; +#endif desc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT; +#ifdef HAVE_WINDOW desc.OutputWindow = main_window.hwnd; +#endif desc.SampleDesc.Count = 1; desc.SampleDesc.Quality = 0; #if 0 desc.Scaling = DXGI_SCALING_STRETCH; #endif +#ifdef HAVE_WINDOW desc.Windowed = TRUE; +#endif #if defined(WINAPI_FAMILY) && (WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP) /* On phone, no swap effects are supported. */ desc.SwapEffect = DXGI_SWAP_EFFECT_DISCARD; +#elif defined(__WINRT__) + desc.SwapEffect = DXGI_SWAP_EFFECT_FLIP_SEQUENTIAL; #else desc.SwapEffect = DXGI_SWAP_EFFECT_SEQUENTIAL; #endif @@ -646,37 +683,47 @@ d3d11_gfx_init(const video_info_t* video, const input_driver_t** input, void** i #endif if(cached_device_d3d11 && cached_context) { - IDXGIFactory* dxgiFactory = NULL; - IDXGIDevice* dxgiDevice = NULL; - IDXGIAdapter* adapter = NULL; - d3d11->device = cached_device_d3d11; d3d11->context = cached_context; d3d11->supportedFeatureLevel = cached_supportedFeatureLevel; - - d3d11->device->lpVtbl->QueryInterface( - d3d11->device, uuidof(IDXGIDevice), (void**)&dxgiDevice); - dxgiDevice->lpVtbl->GetAdapter(dxgiDevice, &adapter); - adapter->lpVtbl->GetParent( - adapter, uuidof(IDXGIFactory1), (void**)&dxgiFactory); - dxgiFactory->lpVtbl->CreateSwapChain( - dxgiFactory, (IUnknown*)d3d11->device, - &desc, (IDXGISwapChain**)&d3d11->swapChain); - - dxgiFactory->lpVtbl->Release(dxgiFactory); - adapter->lpVtbl->Release(adapter); - dxgiDevice->lpVtbl->Release(dxgiDevice); } else { - if (FAILED(D3D11CreateDeviceAndSwapChain( + if (FAILED(D3D11CreateDevice( NULL, D3D_DRIVER_TYPE_HARDWARE, NULL, flags, requested_feature_levels, number_feature_levels, - D3D11_SDK_VERSION, &desc, - (IDXGISwapChain**)&d3d11->swapChain, &d3d11->device, + D3D11_SDK_VERSION, &d3d11->device, &d3d11->supportedFeatureLevel, &d3d11->context))) goto error; } + + IDXGIDevice* dxgiDevice = NULL; + IDXGIAdapter* adapter = NULL; + + d3d11->device->lpVtbl->QueryInterface( + d3d11->device, uuidof(IDXGIDevice), (void**)&dxgiDevice); + dxgiDevice->lpVtbl->GetAdapter(dxgiDevice, &adapter); +#ifndef __WINRT__ + IDXGIFactory* dxgiFactory = NULL; + adapter->lpVtbl->GetParent( + adapter, uuidof(IDXGIFactory1), (void**)&dxgiFactory); + if (FAILED(dxgiFactory->lpVtbl->CreateSwapChain( + dxgiFactory, (IUnknown*)d3d11->device, + &desc, (IDXGISwapChain**)&d3d11->swapChain))) + goto error; +#else + IDXGIFactory2* dxgiFactory = NULL; + adapter->lpVtbl->GetParent( + adapter, uuidof(IDXGIFactory2), (void**)&dxgiFactory); + if (FAILED(dxgiFactory->lpVtbl->CreateSwapChainForCoreWindow( + dxgiFactory, (IUnknown*)d3d11->device, uwp_get_corewindow(), + &desc, NULL, (IDXGISwapChain1**)&d3d11->swapChain))) + goto error; +#endif + + dxgiFactory->lpVtbl->Release(dxgiFactory); + adapter->lpVtbl->Release(adapter); + dxgiDevice->lpVtbl->Release(dxgiDevice); } { @@ -1142,6 +1189,11 @@ static bool d3d11_gfx_frame( video_driver_set_size(&video_info->width, &video_info->height); } +#ifdef __WINRT__ + /* UWP requires double-buffering, so make sure we bind to the appropariate backbuffer */ + D3D11SetRenderTargets(context, 1, &d3d11->renderTargetView, NULL); +#endif + PERF_START(); #if 0 /* custom viewport doesn't call apply_state_changes, so we can't rely on this for now */ @@ -1349,13 +1401,16 @@ static bool d3d11_gfx_frame( d3d11->sprites.enabled = true; +#ifdef HAVE_MENU if (d3d11->menu.enabled) { D3D11SetViewports(context, 1, &d3d11->viewport); D3D11SetVertexBuffer(context, 0, d3d11->sprites.vbo, sizeof(d3d11_sprite_t), 0); menu_driver_frame(video_info); } - else if (video_info->statistics_show) + else +#endif + if (video_info->statistics_show) { struct font_params* osd_params = (struct font_params*)&video_info->osd_stat_params; @@ -1622,7 +1677,12 @@ static const video_poke_interface_t d3d11_poke_interface = { d3d11_gfx_load_texture, d3d11_gfx_unload_texture, NULL, /* set_video_mode */ +#ifndef __WINRT__ win32_get_refresh_rate, +#else + /* UWP does not expose this information easily */ + NULL, +#endif d3d11_set_filtering, NULL, /* get_video_output_size */ NULL, /* get_video_output_prev */ diff --git a/gfx/drivers/d3d12.c b/gfx/drivers/d3d12.c index c4dab9fcc3..2251a428d4 100644 --- a/gfx/drivers/d3d12.c +++ b/gfx/drivers/d3d12.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2014-2018 - Ali Bouhlel * * RetroArch is free software: you can redistribute it and/or modify it under the terms @@ -22,6 +22,7 @@ #include "../video_driver.h" #include "../font_driver.h" +#include "../common/d3d_common.h" #include "../common/win32_common.h" #include "../common/dxgi_common.h" #include "../common/d3d12_common.h" @@ -864,8 +865,12 @@ static void d3d12_gfx_free(void* data) Release(d3d12->device); Release(d3d12->adapter); +#ifdef HAVE_MONITOR win32_monitor_from_window(); +#endif +#ifdef HAVE_WINDOW win32_destroy_window(); +#endif free(d3d12); } @@ -873,29 +878,39 @@ static void d3d12_gfx_free(void* data) static void* d3d12_gfx_init(const video_info_t* video, const input_driver_t** input, void** input_data) { +#ifdef HAVE_MONITOR MONITORINFOEX current_mon; HMONITOR hm_to_use; WNDCLASSEX wndclass = { 0 }; +#endif settings_t* settings = config_get_ptr(); d3d12_video_t* d3d12 = (d3d12_video_t*)calloc(1, sizeof(*d3d12)); if (!d3d12) return NULL; +#ifdef HAVE_WINDOW win32_window_reset(); +#endif +#ifdef HAVE_MONITOR win32_monitor_init(); wndclass.lpfnWndProc = WndProcD3D; +#ifdef HAVE_WINDOW win32_window_init(&wndclass, true, NULL); +#endif win32_monitor_info(¤t_mon, &hm_to_use, &d3d12->cur_mon_id); +#endif d3d12->vp.full_width = video->width; d3d12->vp.full_height = video->height; +#ifdef HAVE_MONITOR if (!d3d12->vp.full_width) d3d12->vp.full_width = current_mon.rcMonitor.right - current_mon.rcMonitor.left; if (!d3d12->vp.full_height) d3d12->vp.full_height = current_mon.rcMonitor.bottom - current_mon.rcMonitor.top; +#endif if (!win32_set_video_mode(d3d12, d3d12->vp.full_width, d3d12->vp.full_height, video->fullscreen)) { @@ -903,7 +918,7 @@ d3d12_gfx_init(const video_info_t* video, const input_driver_t** input, void** i goto error; } - dxgi_input_driver(settings->arrays.input_joypad_driver, input, input_data); + d3d_input_driver(settings->arrays.input_driver, settings->arrays.input_joypad_driver, input, input_data); if (!d3d12_init_base(d3d12)) goto error; @@ -917,8 +932,13 @@ d3d12_gfx_init(const video_info_t* video, const input_driver_t** input, void** i if (!d3d12_init_queue(d3d12)) goto error; +#ifdef __WINRT__ + if (!d3d12_init_swapchain(d3d12, d3d12->vp.full_width, d3d12->vp.full_height, uwp_get_corewindow())) + goto error; +#else if (!d3d12_init_swapchain(d3d12, d3d12->vp.full_width, d3d12->vp.full_height, main_window.hwnd)) goto error; +#endif d3d12_init_samplers(d3d12); d3d12_set_filtering(d3d12, 0, video->smooth); @@ -1450,6 +1470,7 @@ static bool d3d12_gfx_frame( d3d12->sprites.enabled = true; +#ifdef HAVE_MENU if (d3d12->menu.enabled) { D3D12RSSetViewports(d3d12->queue.cmd, 1, &d3d12->chain.viewport); @@ -1457,7 +1478,9 @@ static bool d3d12_gfx_frame( D3D12IASetVertexBuffers(d3d12->queue.cmd, 0, 1, &d3d12->sprites.vbo_view); menu_driver_frame(video_info); } - else if (video_info->statistics_show) + else +#endif + if (video_info->statistics_show) { struct font_params *osd_params = (struct font_params*) &video_info->osd_stat_params; @@ -1764,7 +1787,12 @@ static const video_poke_interface_t d3d12_poke_interface = { d3d12_gfx_load_texture, d3d12_gfx_unload_texture, NULL, /* set_video_mode */ +#ifndef __WINRT__ win32_get_refresh_rate, +#else + /* UWP does not expose this information easily */ + NULL, +#endif d3d12_set_filtering, NULL, /* get_video_output_size */ NULL, /* get_video_output_prev */ diff --git a/gfx/drivers/d3d8.c b/gfx/drivers/d3d8.c index a5dcf1b2a1..21830cd500 100644 --- a/gfx/drivers/d3d8.c +++ b/gfx/drivers/d3d8.c @@ -47,9 +47,6 @@ #ifdef _XBOX #define D3D8_PRESENTATIONINTERVAL D3DRS_PRESENTATIONINTERVAL -#else -#define HAVE_MONITOR -#define HAVE_WINDOW #endif #ifdef HAVE_MENU @@ -61,6 +58,10 @@ #include "../../core.h" #include "../../verbosity.h" +#ifdef __WINRT__ +#error "UWP does not support D3D8" +#endif + static LPDIRECT3D8 g_pD3D8; #ifdef _XBOX @@ -165,7 +166,6 @@ static void d3d8_renderchain_set_vertices( vert[0].y = 1.0f; vert[0].z = 1.0f; - vert[1].x = 1.0f; vert[1].y = 1.0f; vert[1].z = 1.0f; @@ -1003,7 +1003,6 @@ static bool d3d8_restore(void *data) return true; } - static void d3d8_set_nonblock_state(void *data, bool state) { int interval = 0; @@ -1137,37 +1136,6 @@ static void d3d8_set_osd_msg(void *data, d3d8_end_scene(d3d->dev); } -static void d3d8_input_driver( - const input_driver_t **input, void **input_data) -{ - settings_t *settings = config_get_ptr(); - const char *name = settings ? - settings->arrays.input_joypad_driver : NULL; -#ifdef _XBOX - void *xinput = input_xinput.init(name); - *input = xinput ? (const input_driver_t*)&input_xinput : NULL; - *input_data = xinput; -#else -#if _WIN32_WINNT >= 0x0501 - /* winraw only available since XP */ - if (string_is_equal(settings->arrays.input_driver, "raw")) - { - *input_data = input_winraw.init(name); - if (*input_data) - { - *input = &input_winraw; - dinput = NULL; - return; - } - } -#endif - - dinput = input_dinput.init(name); - *input = dinput ? &input_dinput : NULL; - *input_data = dinput; -#endif -} - static bool d3d8_init_internal(d3d8_video_t *d3d, const video_info_t *info, const input_driver_t **input, void **input_data) @@ -1255,7 +1223,7 @@ static bool d3d8_init_internal(d3d8_video_t *d3d, if (!d3d8_initialize(d3d, &d3d->video_info)) return false; - d3d8_input_driver(input, input_data); + d3d_input_driver(settings->arrays.input_driver, settings->arrays.input_joypad_driver, input, input_data); RARCH_LOG("[D3D8]: Init complete.\n"); return true; @@ -1622,7 +1590,6 @@ static bool d3d8_frame(void *data, const void *frame, return false; } - #ifdef HAVE_MENU if (d3d->menu && d3d->menu->enabled) { @@ -1763,7 +1730,6 @@ static void d3d8_set_menu_texture_frame(void *data, } } - if (d3d->menu) d3d8_unlock_rectangle(d3d->menu->tex); } @@ -1888,9 +1854,10 @@ static const video_poke_interface_t d3d_poke_interface = { d3d8_load_texture, d3d8_unload_texture, d3d8_set_video_mode, -#ifdef _XBOX +#if defined(_XBOX) || defined(__WINRT__) NULL, #else + /* UWP does not expose this information easily */ win32_get_refresh_rate, #endif NULL, diff --git a/gfx/drivers/d3d9.c b/gfx/drivers/d3d9.c index a383190b48..0c62a5bd83 100644 --- a/gfx/drivers/d3d9.c +++ b/gfx/drivers/d3d9.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2010-2014 - Hans-Kristian Arntzen * Copyright (C) 2011-2017 - Daniel De Matteis * Copyright (C) 2012-2014 - OV2 @@ -48,9 +48,6 @@ #ifdef _XBOX #define D3D9_PRESENTATIONINTERVAL D3DRS_PRESENTINTERVAL -#else -#define HAVE_MONITOR -#define HAVE_WINDOW #endif #define FS_PRESENTINTERVAL(pp) ((pp)->PresentationInterval) @@ -65,6 +62,10 @@ #include "../../verbosity.h" #include "../../retroarch.h" +#ifdef __WINRT__ +#error "UWP does not support D3D9" +#endif + static LPDIRECT3D9 g_pD3D9; void *dinput; @@ -1056,7 +1057,6 @@ static bool d3d9_restore(void *data) return true; } - static void d3d9_set_nonblock_state(void *data, bool state) { int interval = 0; @@ -1182,38 +1182,6 @@ static void d3d9_set_osd_msg(void *data, d3d9_end_scene(dev); } -static void d3d9_input_driver( - const input_driver_t **input, void **input_data) -{ - settings_t *settings = config_get_ptr(); - const char *name = settings ? - settings->arrays.input_joypad_driver : NULL; -#ifdef _XBOX - void *xinput = input_xinput.init(name); - *input = xinput ? (const input_driver_t*)&input_xinput : NULL; - *input_data = xinput; -#else - -#if _WIN32_WINNT >= 0x0501 - /* winraw only available since XP */ - if (string_is_equal(settings->arrays.input_driver, "raw")) - { - *input_data = input_winraw.init(name); - if (*input_data) - { - *input = &input_winraw; - dinput = NULL; - return; - } - } -#endif - - dinput = input_dinput.init(name); - *input = dinput ? &input_dinput : NULL; - *input_data = dinput; -#endif -} - static bool d3d9_init_internal(d3d9_video_t *d3d, const video_info_t *info, const input_driver_t **input, void **input_data) @@ -1325,7 +1293,8 @@ static bool d3d9_init_internal(d3d9_video_t *d3d, if (!d3d9_initialize(d3d, &d3d->video_info)) return false; - d3d9_input_driver(input, input_data); + d3d_input_driver(settings->arrays.input_joypad_driver, + settings->arrays.input_joypad_driver, input, input_data); RARCH_LOG("[D3D9]: Init complete.\n"); return true; @@ -1695,7 +1664,6 @@ static bool d3d9_frame(void *data, const void *frame, return false; } - #ifdef HAVE_MENU if (d3d->menu && d3d->menu->enabled) { @@ -1919,7 +1887,6 @@ static void d3d9_set_menu_texture_frame(void *data, } } - if (d3d->menu) d3d9_unlock_rectangle((LPDIRECT3DTEXTURE9)d3d->menu->tex); } @@ -2054,9 +2021,10 @@ static const video_poke_interface_t d3d9_poke_interface = { d3d9_load_texture, d3d9_unload_texture, d3d9_set_video_mode, -#ifdef _XBOX +#if defined(_XBOX) || defined(__WINRT__) NULL, #else + /* UWP does not expose this information easily */ win32_get_refresh_rate, #endif NULL, diff --git a/gfx/drivers/d3d_shaders/simple_snow_sm4.hlsl.h b/gfx/drivers/d3d_shaders/simple_snow_sm4.hlsl.h index ba919266fd..8f3a0ddf95 100644 --- a/gfx/drivers/d3d_shaders/simple_snow_sm4.hlsl.h +++ b/gfx/drivers/d3d_shaders/simple_snow_sm4.hlsl.h @@ -65,7 +65,6 @@ float snow(float2 pos, float time, float scale) return random_dots(pos / scale) * (scale * 0.5 + 0.5); } - float4 PSMain(PSInput input) : SV_TARGET { float tim = global.time * 0.4 * speed; diff --git a/gfx/drivers/d3d_shaders/snow_sm4.hlsl.h b/gfx/drivers/d3d_shaders/snow_sm4.hlsl.h index fd42e1425d..63ff2a1bc3 100644 --- a/gfx/drivers/d3d_shaders/snow_sm4.hlsl.h +++ b/gfx/drivers/d3d_shaders/snow_sm4.hlsl.h @@ -65,7 +65,6 @@ float snow(float2 pos, float time, float scale) return random_dots(pos / scale) * (scale * 0.5 + 0.5); } - float4 PSMain(PSInput input) : SV_TARGET { float tim = global.time * 0.4 * speed; diff --git a/gfx/drivers/d3d_shaders/snowflake_sm4.hlsl.h b/gfx/drivers/d3d_shaders/snowflake_sm4.hlsl.h index c02908e442..4be16e0b29 100644 --- a/gfx/drivers/d3d_shaders/snowflake_sm4.hlsl.h +++ b/gfx/drivers/d3d_shaders/snowflake_sm4.hlsl.h @@ -14,7 +14,6 @@ float4 VSMain(float4 position : POSITION, float2 texcoord : TEXCOORD0) : SV_POSI return mul(global.modelViewProj, position); } - static const float atime = (global.time + 1.0) / 4.0; float rand(float2 co) diff --git a/gfx/drivers/d3d_shaders/sprite_sm4.hlsl.h b/gfx/drivers/d3d_shaders/sprite_sm4.hlsl.h index 1a5feefbe7..c8e252462e 100644 --- a/gfx/drivers/d3d_shaders/sprite_sm4.hlsl.h +++ b/gfx/drivers/d3d_shaders/sprite_sm4.hlsl.h @@ -83,5 +83,4 @@ SRC( return float4(input.color.rgb , input.color.a * t0.Sample(s0, input.texcoord).a); }; - ) diff --git a/gfx/drivers/drm_gfx.c b/gfx/drivers/drm_gfx.c index cd43998614..acb26144a1 100644 --- a/gfx/drivers/drm_gfx.c +++ b/gfx/drivers/drm_gfx.c @@ -336,8 +336,6 @@ static void drm_surface_update(void *data, const void *frame, drm_page_flip(surface); } - - static uint32_t get_plane_prop_id(uint32_t obj_id, const char *name) { int i,j; @@ -626,7 +624,6 @@ static bool init_drm(void) else RARCH_LOG ("DRM: UNIVERSAL PLANES cap set\n"); - ret = drmSetClientCap(drm.fd, DRM_CLIENT_CAP_ATOMIC, 1); if (ret) { @@ -706,7 +703,6 @@ static bool init_drm(void) return true; } - static void *drm_gfx_init(const video_info_t *video, const input_driver_t **input, void **input_data) { diff --git a/gfx/drivers/exynos_gfx.c b/gfx/drivers/exynos_gfx.c index 2ce72de395..6e954bb5c6 100644 --- a/gfx/drivers/exynos_gfx.c +++ b/gfx/drivers/exynos_gfx.c @@ -88,7 +88,6 @@ static const struct exynos_config_default {400, 240, EXYNOS_BUFFER_AUX, G2D_COLOR_FMT_ARGB4444 | G2D_ORDER_RGBAX, 2} /* menu */ }; - struct exynos_data; #if (EXYNOS_GFX_DEBUG_PERF == 1) @@ -1043,7 +1042,6 @@ struct exynos_video bool aspect_changed; }; - static int exynos_init_font(struct exynos_video *vid) { struct exynos_data *pdata = vid->data; diff --git a/gfx/drivers/gl.c b/gfx/drivers/gl.c index d62bd67cf4..d870d98fb0 100644 --- a/gfx/drivers/gl.c +++ b/gfx/drivers/gl.c @@ -128,7 +128,6 @@ void context_bind_hw_render(void *data, bool enable) gl_context_bind_hw_render(gl, enable); } - #ifdef HAVE_OVERLAY static void gl_free_overlay(gl_t *gl) { @@ -247,7 +246,6 @@ static void gl_render_overlay(gl_t *gl, video_frame_info_t *video_info) } #endif - static void gl_set_projection(gl_t *gl, struct video_ortho *ortho, bool allow_rotate) { @@ -688,7 +686,6 @@ static void gl_set_texture_frame(void *data, if (!gl->menu_texture) glGenTextures(1, &gl->menu_texture); - gl_load_texture_data(gl->menu_texture, RARCH_WRAP_EDGE, menu_filter, video_pixel_get_alignment(width * base_size), @@ -940,7 +937,6 @@ static void gl_pbo_async_readback(gl_t *gl) gl->renderchain_driver->unbind_pbo(gl, gl->renderchain_data); } - static bool gl_frame(void *data, const void *frame, unsigned frame_width, unsigned frame_height, uint64_t frame_count, @@ -1234,7 +1230,6 @@ static bool gl_frame(void *data, const void *frame, return true; } - static void gl_destroy_resources(gl_t *gl) { if (gl) @@ -2357,8 +2352,6 @@ static bool gl_overlay_load(void *data, return true; } - - static void gl_overlay_enable(void *data, bool state) { gl_t *gl = (gl_t*)data; @@ -2395,7 +2388,6 @@ static void gl_overlay_set_alpha(void *data, unsigned image, float mod) color[12 + 3] = mod; } - static const video_overlay_interface_t gl_overlay_interface = { gl_overlay_enable, gl_overlay_load, @@ -2413,7 +2405,6 @@ static void gl_get_overlay_interface(void *data, } #endif - static retro_proc_address_t gl_get_proc_address(void *data, const char *sym) { gfx_ctx_proc_address_t proc_address; @@ -2458,7 +2449,6 @@ static void gl_set_aspect_ratio(void *data, unsigned aspect_ratio_idx) gl->should_resize = true; } - static void gl_apply_state_changes(void *data) { gl_t *gl = (gl_t*)data; @@ -2467,7 +2457,6 @@ static void gl_apply_state_changes(void *data) gl->should_resize = true; } - static void gl_get_video_output_size(void *data, unsigned *width, unsigned *height) { diff --git a/gfx/drivers/gx2_gfx.c b/gfx/drivers/gx2_gfx.c index cd34fb8760..bed3e8de8e 100644 --- a/gfx/drivers/gx2_gfx.c +++ b/gfx/drivers/gx2_gfx.c @@ -43,7 +43,6 @@ #include "../font_driver.h" - static const wiiu_render_mode_t wiiu_render_mode_map[] = { {0}, /* GX2_TV_SCAN_MODE_NONE */ @@ -484,7 +483,6 @@ static void gx2_overlay_vertex_geom(void *data, unsigned image, wiiu_video_t *gx2 = (wiiu_video_t *)data; struct gx2_overlay_data *o = NULL; - if (gx2) o = (struct gx2_overlay_data *)&gx2->overlay[image]; @@ -668,7 +666,6 @@ static void wiiu_gfx_free(void *data) if (!wiiu) return; - /* clear leftover image */ GX2ClearColor(&wiiu->color_buffer, 0.0f, 0.0f, 0.0f, 1.0f); GX2CopyColorBufferToScanBuffer(&wiiu->color_buffer, GX2_SCAN_TARGET_DRC); @@ -817,8 +814,6 @@ static bool wiiu_init_frame_textures(wiiu_video_t *wiiu, unsigned width, unsigne if (!height) height = wiiu->color_buffer.surface.height; - - memset(&wiiu->pass[i].texture, 0, sizeof(wiiu->pass[i].texture)); wiiu->pass[i].texture.surface.dim = GX2_SURFACE_DIM_TEXTURE_2D; wiiu->pass[i].texture.surface.width = width; @@ -837,7 +832,6 @@ static bool wiiu_init_frame_textures(wiiu_video_t *wiiu, unsigned width, unsigne GX2CalcSurfaceSizeAndAlignment(&wiiu->pass[i].texture.surface); GX2InitTextureRegs(&wiiu->pass[i].texture); - if ((i != (wiiu->shader_preset->passes - 1)) || (width != wiiu->vp.width) || (height != wiiu->vp.height)) { @@ -1001,7 +995,6 @@ static void wiiu_gfx_update_uniform_block(wiiu_video_t *wiiu, int pass, float *u continue; } - for (int k = 0; k < wiiu->shader_preset->num_parameters; k++) { if (string_is_equal(id, wiiu->shader_preset->parameters[k].id)) @@ -1128,7 +1121,6 @@ static bool wiiu_gfx_frame(void *data, const void *frame, } } - GX2Invalidate(GX2_INVALIDATE_MODE_CPU_TEXTURE, wiiu->texture.surface.image, wiiu->texture.surface.imageSize); @@ -1240,8 +1232,6 @@ static bool wiiu_gfx_frame(void *data, const void *frame, continue; } - - for (int k = 0; k < wiiu->shader_preset->luts; k++) { if (wiiu->luts[k].surface.image @@ -1528,7 +1518,6 @@ static bool wiiu_gfx_set_shader(void *data, } } - return true; } @@ -1543,7 +1532,6 @@ static struct video_shader *wiiu_gfx_get_current_shader(void *data) return wiiu->shader_preset; } - static void wiiu_gfx_set_rotation(void *data, unsigned rotation) { @@ -1626,7 +1614,6 @@ static void wiiu_gfx_set_filtering(void *data, unsigned index, bool smooth) wiiu->smooth = smooth; } - static void wiiu_gfx_apply_state_changes(void *data) { wiiu_video_t *wiiu = (wiiu_video_t *)data; diff --git a/gfx/drivers/gx2_shaders/bokeh.c b/gfx/drivers/gx2_shaders/bokeh.c index 5790f4d688..6ce7c43ff9 100644 --- a/gfx/drivers/gx2_shaders/bokeh.c +++ b/gfx/drivers/gx2_shaders/bokeh.c @@ -62,7 +62,6 @@ static struct }, }; - __attribute__((aligned(GX2_SHADER_ALIGNMENT))) static struct { @@ -739,7 +738,6 @@ static GX2UniformVar uniform_vars[] = { {"global.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 20, 0}, }; - GX2Shader bokeh_shader = { { diff --git a/gfx/drivers/gx2_shaders/frame.c b/gfx/drivers/gx2_shaders/frame.c index b82fe5033c..9bc5976a62 100644 --- a/gfx/drivers/gx2_shaders/frame.c +++ b/gfx/drivers/gx2_shaders/frame.c @@ -105,7 +105,6 @@ static GX2UniformVar uniform_vars[] = { {"global.MVP", GX2_SHADER_VAR_TYPE_MATRIX4X4, 1, 0, 0}, }; - GX2Shader frame_shader = { { diff --git a/gfx/drivers/gx2_shaders/menu_shaders.h b/gfx/drivers/gx2_shaders/menu_shaders.h index e3bd531e57..aab4aeda46 100644 --- a/gfx/drivers/gx2_shaders/menu_shaders.h +++ b/gfx/drivers/gx2_shaders/menu_shaders.h @@ -30,7 +30,6 @@ __attribute__((aligned (16))) float time; }menu_shader_uniform_t; - extern GX2Shader ribbon_shader; extern GX2Shader ribbon_simple_shader; extern GX2Shader snow_simple_shader; diff --git a/gfx/drivers/gx2_shaders/ribbon.c b/gfx/drivers/gx2_shaders/ribbon.c index e65aab8b70..a1207401a1 100644 --- a/gfx/drivers/gx2_shaders/ribbon.c +++ b/gfx/drivers/gx2_shaders/ribbon.c @@ -331,7 +331,6 @@ static GX2UniformVar uniform_vars[] = { {"constants.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 0, 0}, }; - GX2Shader ribbon_shader = { { diff --git a/gfx/drivers/gx2_shaders/ribbon_simple.c b/gfx/drivers/gx2_shaders/ribbon_simple.c index e5d90f1de7..214f6ab3d2 100644 --- a/gfx/drivers/gx2_shaders/ribbon_simple.c +++ b/gfx/drivers/gx2_shaders/ribbon_simple.c @@ -217,7 +217,6 @@ static GX2UniformVar uniform_vars[] = { {"global.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 20, 0}, }; - GX2Shader ribbon_simple_shader = { { diff --git a/gfx/drivers/gx2_shaders/snow.c b/gfx/drivers/gx2_shaders/snow.c index f89c76defa..7a4d5915b3 100644 --- a/gfx/drivers/gx2_shaders/snow.c +++ b/gfx/drivers/gx2_shaders/snow.c @@ -62,7 +62,6 @@ static struct }, }; - __attribute__((aligned(GX2_SHADER_ALIGNMENT))) static struct { @@ -1404,7 +1403,6 @@ static GX2UniformVar uniform_vars[] = { {"global.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 20, 0}, }; - GX2Shader snow_shader = { { diff --git a/gfx/drivers/gx2_shaders/snow_simple.c b/gfx/drivers/gx2_shaders/snow_simple.c index a7dfc1dbc0..7f6715f458 100644 --- a/gfx/drivers/gx2_shaders/snow_simple.c +++ b/gfx/drivers/gx2_shaders/snow_simple.c @@ -1374,7 +1374,6 @@ static struct }, }; - static GX2AttribVar attributes[] = { { "Position", GX2_SHADER_VAR_TYPE_FLOAT4, 0, 0}, @@ -1404,7 +1403,6 @@ static GX2UniformVar uniform_vars[] = { {"global.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 20, 0}, }; - GX2Shader snow_simple_shader = { { diff --git a/gfx/drivers/gx2_shaders/snowflake.c b/gfx/drivers/gx2_shaders/snowflake.c index 6312e625ce..b01bbcf1e6 100644 --- a/gfx/drivers/gx2_shaders/snowflake.c +++ b/gfx/drivers/gx2_shaders/snowflake.c @@ -20,7 +20,6 @@ #include "gx2_shader_inl.h" #include "menu_shaders.h" - __attribute__((aligned(GX2_SHADER_ALIGNMENT))) static struct { @@ -555,7 +554,6 @@ static struct }, }; - static GX2AttribVar attributes[] = { { "Position", GX2_SHADER_VAR_TYPE_FLOAT4, 0, 0}, @@ -585,7 +583,6 @@ static GX2UniformVar uniform_vars[] = { {"global.time", GX2_SHADER_VAR_TYPE_FLOAT, 1, 20, 0}, }; - GX2Shader snowflake_shader = { { diff --git a/gfx/drivers/gx2_shaders/sprite.c b/gfx/drivers/gx2_shaders/sprite.c index 9cb406d272..9cc25bd6c1 100644 --- a/gfx/drivers/gx2_shaders/sprite.c +++ b/gfx/drivers/gx2_shaders/sprite.c @@ -223,7 +223,6 @@ static GX2UniformBlock uniform_blocks[] = {"UBO_tex", 2, sizeof(GX2_vec2)}, }; - static GX2UniformVar uniform_vars[] = { {"vp_size", GX2_SHADER_VAR_TYPE_FLOAT2, 1, 0, 0}, diff --git a/gfx/drivers/gx_gfx.c b/gfx/drivers/gx_gfx.c index 788cb46a64..25c615e246 100644 --- a/gfx/drivers/gx_gfx.c +++ b/gfx/drivers/gx_gfx.c @@ -1540,7 +1540,6 @@ static bool gx_frame(void *data, const void *frame, g_draw_done = false; g_current_framebuf ^= 1; - if (frame) { if (gx->rgb32) diff --git a/gfx/drivers/omap_gfx.c b/gfx/drivers/omap_gfx.c index 5b4fcd0d70..992472eaa2 100644 --- a/gfx/drivers/omap_gfx.c +++ b/gfx/drivers/omap_gfx.c @@ -90,7 +90,6 @@ typedef struct omapfb_data bool sync; } omapfb_data_t; - static const char *omapfb_get_fb_device(void) { static char fbname[12] = {0}; @@ -786,7 +785,6 @@ static void omapfb_blit_frame(omapfb_data_t *pdata, const void *src, memcpy(dst + dst_pitch * i, src + src_pitch * i, dst_pitch); } - typedef struct omap_video { omapfb_data_t *omap; @@ -809,7 +807,6 @@ typedef struct omap_video } menu; } omap_video_t; - static void omap_gfx_free(void *data) { omap_video_t *vid = data; diff --git a/gfx/drivers/ps2_gfx.c b/gfx/drivers/ps2_gfx.c index cb921bbc68..d8c989db34 100644 --- a/gfx/drivers/ps2_gfx.c +++ b/gfx/drivers/ps2_gfx.c @@ -1,5 +1,5 @@ /* RetroArch - A frontend for libretro. - * Copyright (C) 2018 - Francisco Javier Trujillo Mata + * Copyright (C) 2018 - Francisco Javier Trujillo Mata - fjtrujy * * RetroArch is free software: you can redistribute it and/or modify it under the terms * of the GNU General Public License as published by the Free Software Found- @@ -18,7 +18,6 @@ #include "../../driver.h" #include "../../verbosity.h" -#include #include #include #include @@ -26,6 +25,9 @@ #define GS_TEXT GS_SETREG_RGBAQ(0x80,0x80,0x80,0x80,0x00) // turn white GS Screen #define GS_BLACK GS_SETREG_RGBAQ(0x00,0x00,0x00,0x00,0x00) // turn white GS Screen +#define NTSC_WIDTH 640 +#define NTSC_HEIGHT 448 + typedef struct ps2_video { GSGLOBAL *gsGlobal; @@ -43,34 +45,35 @@ typedef struct ps2_video // PRIVATE METHODS static GSGLOBAL *init_GSGlobal(void) { - GSGLOBAL *gsGlobal = gsKit_init_global(); + GSGLOBAL *gsGlobal = gsKit_init_global(); - gsGlobal->PSM = GS_PSM_CT16; - gsGlobal->PSMZ = GS_PSMZ_16S; - gsGlobal->DoubleBuffering = GS_SETTING_OFF; - gsGlobal->ZBuffering = GS_SETTING_OFF; - gsGlobal->PrimAlphaEnable = GS_SETTING_OFF; + gsGlobal->Mode = GS_MODE_NTSC; + gsGlobal->Interlace = GS_INTERLACED; + gsGlobal->Field = GS_FIELD; + gsGlobal->Width = NTSC_WIDTH; + gsGlobal->Height = NTSC_HEIGHT; + + gsGlobal->PSM = GS_PSM_CT16; + gsGlobal->PSMZ = GS_PSMZ_16; + gsGlobal->DoubleBuffering = GS_SETTING_OFF; + gsGlobal->ZBuffering = GS_SETTING_OFF; + gsGlobal->PrimAlphaEnable = GS_SETTING_OFF; - dmaKit_init(D_CTRL_RELE_OFF,D_CTRL_MFD_OFF, D_CTRL_STS_UNSPEC, - D_CTRL_STD_OFF, D_CTRL_RCYC_8, 1 << DMA_CHANNEL_GIF); + dmaKit_init(D_CTRL_RELE_OFF,D_CTRL_MFD_OFF, D_CTRL_STS_UNSPEC, + D_CTRL_STD_OFF, D_CTRL_RCYC_8, 1 << DMA_CHANNEL_GIF); - // Initialize the DMAC - dmaKit_chan_init(DMA_CHANNEL_GIF); + /* Initialize the DMAC */ + dmaKit_chan_init(DMA_CHANNEL_GIF); - gsKit_init_screen(gsGlobal); - gsKit_mode_switch(gsGlobal, GS_ONESHOT); + gsKit_init_screen(gsGlobal); + gsKit_mode_switch(gsGlobal, GS_ONESHOT); - gsKit_clear(gsGlobal, GS_BLACK); - - return gsGlobal; + return gsGlobal; } static GSTEXTURE * prepare_new_texture(void) { - GSTEXTURE *texture = malloc(sizeof *texture); - texture->Width = 0; - texture->Height = 0; - texture->Mem = NULL; - return texture; + GSTEXTURE *texture = calloc(1, sizeof(*texture)); + return texture; } static void init_ps2_video(ps2_video_t *ps2) { @@ -88,22 +91,22 @@ static void deinitTexture(GSTEXTURE *texture) { static void color_correction32(uint32_t *buffer, uint32_t dimensions) { - uint32_t i; - uint32_t x32; - for (i = 0; i < dimensions; i++) { + uint32_t i; + uint32_t x32; + for (i = 0; i < dimensions; i++) { x32 = buffer[i]; buffer[i] = ((x32 >> 16) & 0xFF) | ((x32 << 16) & 0xFF0000) | (x32 & 0xFF00FF00); - } + } } static void color_correction16(uint16_t *buffer, uint32_t dimensions) { - uint32_t i; - uint16_t x16; - for (i = 0; i < dimensions; i++) { + uint32_t i; + uint16_t x16; + for (i = 0; i < dimensions; i++) { x16 = buffer[i]; - buffer[i] = (x16 & 0x8000) | ((x16 << 10) & 0x7C00) | (x16 & 0x3E0) | ((x16 >> 10) & 0x1F); - } + buffer[i] = (x16 & 0x8000) | ((x16 << 10) & 0x7C00) | ((x16 >> 1) & 0x3E0) | ((x16 >> 11) & 0x1F); + } } static void transfer_texture(GSTEXTURE *texture, const void *frame, @@ -139,7 +142,7 @@ if (color_correction) { static void vram_alloc(GSGLOBAL *gsGlobal, GSTEXTURE *texture) { uint32_t size = gsKit_texture_size(texture->Width, texture->Height, texture->PSM); - texture->Vram=gsKit_vram_alloc(gsGlobal, size, GSKIT_ALLOC_USERBUFFER); + texture->Vram = gsKit_vram_alloc(gsGlobal, size, GSKIT_ALLOC_USERBUFFER); if(texture->Vram == GSKIT_ALLOC_ERROR) { printf("VRAM Allocation Failed. Will not upload texture.\n"); } @@ -147,31 +150,24 @@ static void vram_alloc(GSGLOBAL *gsGlobal, GSTEXTURE *texture) { static void prim_texture(GSGLOBAL *gsGlobal, GSTEXTURE *texture, int zPosition, bool force_aspect) { float x1, y1, x2, y2; - if (force_aspect) { - float delta = 1.0f; - float texture_aspect_ratio = texture->Width / texture->Height; - float gsGlobal_aspect_ratio = gsGlobal->Width / gsGlobal->Height; - if (texture_aspect_ratio < gsGlobal_aspect_ratio) { - //height - delta = gsGlobal->Height / texture->Height; - } else { - //width - delta = gsGlobal->Width / texture->Width; - } - float newWidth = texture->Width * delta; - float newHeight = texture->Height * delta; - - x1 = (gsGlobal->Width - newWidth) / 2.0f; - y1 = (gsGlobal->Height - newHeight) / 2.0f; - x2 = newWidth + x1; - y2 = newHeight + y1; + if (force_aspect) { + float width_proportion = (float)gsGlobal->Width / (float)texture->Width; + float height_proportion = (float)gsGlobal->Height / (float)texture->Height; + float delta = MIN(width_proportion, height_proportion); + float newWidth = texture->Width * delta; + float newHeight = texture->Height * delta; + + x1 = (gsGlobal->Width - newWidth) / 2.0f; + y1 = (gsGlobal->Height - newHeight) / 2.0f; + x2 = newWidth + x1; + y2 = newHeight + y1; - } else { - x1 = 0.0f; - y1 = 0.0f; - x2 = gsGlobal->Width; - y2 = gsGlobal->Height; - } + } else { + x1 = 0.0f; + y1 = 0.0f; + x2 = gsGlobal->Width; + y2 = gsGlobal->Height; + } gsKit_prim_sprite_texture( gsGlobal, texture, x1, //X1 @@ -186,7 +182,6 @@ static void prim_texture(GSGLOBAL *gsGlobal, GSTEXTURE *texture, int zPosition, GS_TEXT); } - static void *ps2_gfx_init(const video_info_t *video, const input_driver_t **input, void **input_data) { @@ -200,13 +195,15 @@ static void *ps2_gfx_init(const video_info_t *video, return NULL; init_ps2_video(ps2); + if (video->font_enable) { + font_driver_init_osd(ps2, false, video->is_threaded, FONT_DRIVER_RENDER_PS2); + } ps2->rgb32 = video->rgb32; ps2->fullscreen = video->fullscreen; ps2->core_filter = video->smooth ? GS_FILTER_LINEAR : GS_FILTER_NEAREST; ps2->force_aspect = video->force_aspect; - if (input && input_data) - { + if (input && input_data) { settings_t *settings = config_get_ptr(); ps2input = input_ps2.init(settings->arrays.input_joypad_driver); *input = ps2input ? &input_ps2 : NULL; @@ -232,8 +229,9 @@ static bool ps2_gfx_frame(void *data, const void *frame, return false; if (frame_count%120==0) { - printf("ps2_gfx_frame %i\n", frame_count); + printf("ps2_gfx_frame %lu\n", frame_count); } + gsKit_clear(ps2->gsGlobal, GS_BLACK); gsKit_vram_clear(ps2->gsGlobal); if (frame) { @@ -243,11 +241,25 @@ static bool ps2_gfx_frame(void *data, const void *frame, prim_texture(ps2->gsGlobal, ps2->coreTexture, 1, ps2->force_aspect); } - bool texture_empty = !ps2->menuTexture->Width || !ps2->menuTexture->Height; - if (ps2->menuVisible && !texture_empty) { - vram_alloc(ps2->gsGlobal, ps2->menuTexture); - gsKit_texture_upload(ps2->gsGlobal, ps2->menuTexture); - prim_texture(ps2->gsGlobal, ps2->menuTexture, 2, ps2->fullscreen); + if (ps2->menuVisible) { + bool texture_empty = !ps2->menuTexture->Width || !ps2->menuTexture->Height; + if (!texture_empty) { + vram_alloc(ps2->gsGlobal, ps2->menuTexture); + gsKit_texture_upload(ps2->gsGlobal, ps2->menuTexture); + prim_texture(ps2->gsGlobal, ps2->menuTexture, 2, ps2->fullscreen); + } + } else if (video_info->statistics_show) { + struct font_params *osd_params = (struct font_params*) + &video_info->osd_stat_params; + + if (osd_params) { + font_driver_render_msg(video_info, NULL, video_info->stat_text, + (const struct font_params*)&video_info->osd_stat_params); + } + } + + if(!string_is_empty(msg)) { + font_driver_render_msg(video_info, NULL, msg, NULL); } gsKit_sync_flip(ps2->gsGlobal); @@ -294,6 +306,8 @@ static void ps2_gfx_free(void *data) gsKit_clear(ps2->gsGlobal, GS_BLACK); gsKit_vram_clear(ps2->gsGlobal); + font_driver_free_osd(); + deinitTexture(ps2->menuTexture); deinitTexture(ps2->coreTexture); @@ -366,6 +380,14 @@ static void ps2_set_texture_enable(void *data, bool enable, bool fullscreen) ps2->fullscreen = fullscreen; } +static void ps2_set_osd_msg(void *data, + video_frame_info_t *video_info, + const char *msg, + const void *params, void *font) +{ + font_driver_render_msg(video_info, font, msg, params); +} + static const video_poke_interface_t ps2_poke_interface = { NULL, /* get_flags */ NULL, /* set_coords */ @@ -384,7 +406,7 @@ static const video_poke_interface_t ps2_poke_interface = { ps2_apply_state_changes, ps2_set_texture_frame, ps2_set_texture_enable, - NULL, /* set_osd_msg */ + ps2_set_osd_msg, /* set_osd_msg */ NULL, /* show_mouse */ NULL, /* grab_mouse_toggle */ NULL, /* get_current_shader */ @@ -392,7 +414,6 @@ static const video_poke_interface_t ps2_poke_interface = { NULL /* get_hw_render_interface */ }; - static void ps2_gfx_get_poke_interface(void *data, const video_poke_interface_t **iface) { diff --git a/gfx/drivers/psp1_gfx.c b/gfx/drivers/psp1_gfx.c index 57b38fe727..773fe26b7c 100644 --- a/gfx/drivers/psp1_gfx.c +++ b/gfx/drivers/psp1_gfx.c @@ -943,7 +943,6 @@ static bool psp_read_viewport(void *data, uint8_t *buffer, bool is_idle) return true; } - return false; } diff --git a/gfx/drivers/sdl2_gfx.c b/gfx/drivers/sdl2_gfx.c index baf468a369..ce8c69c938 100644 --- a/gfx/drivers/sdl2_gfx.c +++ b/gfx/drivers/sdl2_gfx.c @@ -421,7 +421,6 @@ static void *sdl2_gfx_init(const video_info_t *video, if (!video->fullscreen) RARCH_LOG("[SDL]: Creating window @ %ux%u\n", video->width, video->height); - if (video->fullscreen) flags = settings->bools.video_windowed_fullscreen ? SDL_WINDOW_FULLSCREEN_DESKTOP : SDL_WINDOW_FULLSCREEN; else diff --git a/gfx/drivers/sdl_gfx.c b/gfx/drivers/sdl_gfx.c index 931f96a926..18a54cdac5 100644 --- a/gfx/drivers/sdl_gfx.c +++ b/gfx/drivers/sdl_gfx.c @@ -500,7 +500,6 @@ static void sdl_set_texture_enable(void *data, bool state, bool full_screen) vid->menu.active = state; } - static void sdl_show_mouse(void *data, bool state) { (void)data; diff --git a/gfx/drivers/vita2d_gfx.c b/gfx/drivers/vita2d_gfx.c index 7f49756c5c..3e253ee8d4 100644 --- a/gfx/drivers/vita2d_gfx.c +++ b/gfx/drivers/vita2d_gfx.c @@ -92,7 +92,6 @@ static void *vita2d_gfx_init(const video_info_t *video, video_driver_set_size(&temp_width, &temp_height); vita2d_gfx_set_viewport(vita, temp_width, temp_height, false, true); - if (input && input_data) { settings_t *settings = config_get_ptr(); diff --git a/gfx/drivers/xenon360_gfx.c b/gfx/drivers/xenon360_gfx.c index 9101d047cc..019259a060 100644 --- a/gfx/drivers/xenon360_gfx.c +++ b/gfx/drivers/xenon360_gfx.c @@ -137,7 +137,6 @@ static void *xenon360_gfx_init(const video_info_t *video, const input_driver_t * edram_init(gl->gl_device); - /* enable filtering for now */ float x = -1.0f; diff --git a/gfx/drivers_context/android_ctx.c b/gfx/drivers_context/android_ctx.c index 116a6a9fdf..f45dd0e97f 100644 --- a/gfx/drivers_context/android_ctx.c +++ b/gfx/drivers_context/android_ctx.c @@ -536,7 +536,6 @@ static void android_gfx_ctx_set_swap_interval(void *data, int swap_interval) } } - static gfx_ctx_proc_t android_gfx_ctx_get_proc_address(const char *symbol) { switch (android_api) diff --git a/gfx/drivers_context/drm_ctx.c b/gfx/drivers_context/drm_ctx.c index d362bb745a..c89f788227 100644 --- a/gfx/drivers_context/drm_ctx.c +++ b/gfx/drivers_context/drm_ctx.c @@ -154,7 +154,6 @@ static void gfx_ctx_drm_check_window(void *data, bool *quit, *quit = (bool)frontend_driver_get_signal_handler_state(); } - static void drm_flip_handler(int fd, unsigned frame, unsigned sec, unsigned usec, void *data) { @@ -707,7 +706,6 @@ static bool gfx_ctx_drm_set_video_mode(void *data, goto error; } - switch (drm_api) { case GFX_CTX_OPENGL_API: @@ -746,7 +744,6 @@ error: return false; } - static void gfx_ctx_drm_destroy(void *data) { gfx_ctx_drm_data_t *drm = (gfx_ctx_drm_data_t*)data; diff --git a/gfx/drivers_context/emscriptenegl_ctx.c b/gfx/drivers_context/emscriptenegl_ctx.c index 46410ba68d..9351f7c499 100644 --- a/gfx/drivers_context/emscriptenegl_ctx.c +++ b/gfx/drivers_context/emscriptenegl_ctx.c @@ -280,7 +280,6 @@ static bool gfx_ctx_emscripten_bind_api(void *data, return false; } - static void gfx_ctx_emscripten_input_driver(void *data, const char *name, const input_driver_t **input, void **input_data) diff --git a/gfx/drivers_context/gdi_ctx.c b/gfx/drivers_context/gdi_ctx.c index e59a480601..574067fcc0 100644 --- a/gfx/drivers_context/gdi_ctx.c +++ b/gfx/drivers_context/gdi_ctx.c @@ -229,7 +229,6 @@ error: return false; } - static void gfx_ctx_gdi_input_driver(void *data, const char *joypad_name, const input_driver_t **input, void **input_data) diff --git a/gfx/drivers_context/opendingux_fbdev_ctx.c b/gfx/drivers_context/opendingux_fbdev_ctx.c index f774c9c34b..6c3532db04 100644 --- a/gfx/drivers_context/opendingux_fbdev_ctx.c +++ b/gfx/drivers_context/opendingux_fbdev_ctx.c @@ -234,7 +234,6 @@ static void gfx_ctx_opendingux_set_swap_interval( #endif } - static gfx_ctx_proc_t gfx_ctx_opendingux_get_proc_address(const char *symbol) { #ifdef HAVE_EGL diff --git a/gfx/drivers_context/orbis_ctx.c b/gfx/drivers_context/orbis_ctx.c index e97529c6c9..5bd1733b55 100644 --- a/gfx/drivers_context/orbis_ctx.c +++ b/gfx/drivers_context/orbis_ctx.c @@ -19,7 +19,6 @@ #include "../../config.h" #endif - #include "../common/orbis_common.h" #include "../../frontend/frontend_driver.h" diff --git a/gfx/drivers_context/osmesa_ctx.c b/gfx/drivers_context/osmesa_ctx.c index d78e7ec6c3..99b3c86c0d 100644 --- a/gfx/drivers_context/osmesa_ctx.c +++ b/gfx/drivers_context/osmesa_ctx.c @@ -14,7 +14,6 @@ * If not, see . */ - #include #include #include diff --git a/gfx/drivers_context/qnx_ctx.c b/gfx/drivers_context/qnx_ctx.c index f71c2f50b3..23e9e74452 100644 --- a/gfx/drivers_context/qnx_ctx.c +++ b/gfx/drivers_context/qnx_ctx.c @@ -131,7 +131,6 @@ static void *gfx_ctx_qnx_init(video_frame_info_t *video_info, void *video_driver } } - #ifdef HAVE_EGL if (!egl_init_context(&qnx->egl, EGL_NONE, EGL_DEFAULT_DISPLAY, &major, &minor, &n, attribs, NULL)) @@ -239,7 +238,6 @@ static void *gfx_ctx_qnx_init(video_frame_info_t *video_info, void *video_driver goto error; } - if (screen_set_window_property_iv(screen_win, SCREEN_PROPERTY_BUFFER_SIZE, buffer_size)) { @@ -321,7 +319,6 @@ static bool gfx_ctx_qnx_set_video_mode(void *data, return true; } - static void gfx_ctx_qnx_input_driver(void *data, const char *joypad_name, const input_driver_t **input, void **input_data) diff --git a/gfx/drivers_context/sixel_ctx.c b/gfx/drivers_context/sixel_ctx.c index 968f067dd3..d1562199bd 100644 --- a/gfx/drivers_context/sixel_ctx.c +++ b/gfx/drivers_context/sixel_ctx.c @@ -90,7 +90,6 @@ static bool gfx_ctx_sixel_set_video_mode(void *data, return true; } - static void gfx_ctx_sixel_input_driver(void *data, const char *joypad_name, const input_driver_t **input, void **input_data) diff --git a/gfx/drivers_context/switch_ctx.c b/gfx/drivers_context/switch_ctx.c index 6a8e075cd6..1bdfe71447 100644 --- a/gfx/drivers_context/switch_ctx.c +++ b/gfx/drivers_context/switch_ctx.c @@ -46,10 +46,20 @@ void switch_ctx_destroy(void *data) static void switch_ctx_get_video_size(void *data, unsigned *width, unsigned *height) { - switch_ctx_data_t *ctx_nx = (switch_ctx_data_t *)data; + switch_ctx_data_t *ctx_nx = (switch_ctx_data_t *)data; - *width = 1280; - *height = 720; + switch (appletGetOperationMode()) + { + default: + case AppletOperationMode_Handheld: + *width = 1280; + *height = 720; + break; + case AppletOperationMode_Docked: + *width = 1920; + *height = 1080; + break; + } } static void *switch_ctx_init(video_frame_info_t *video_info, void *video_driver) @@ -86,6 +96,10 @@ static void *switch_ctx_init(video_frame_info_t *video_info, void *video_driver) setenv("NV50_PROG_CHIPSET", "0x120", 1); #endif + // Needs to be here + gfxInitResolutionDefault(); // 1080p + gfxConfigureResolution(1920, 1080); + #ifdef HAVE_EGL if (!egl_init_context(&ctx_nx->egl, EGL_NONE, EGL_DEFAULT_DISPLAY, &major, &minor, &n, attribs, NULL)) @@ -114,7 +128,18 @@ static void switch_ctx_check_window(void *data, bool *quit, { *width = new_width; *height = new_height; + switch_ctx_data_t *ctx_nx = (switch_ctx_data_t *)data; + + ctx_nx->width = *width; + ctx_nx->height = *height; + + ctx_nx->native_window.width = ctx_nx->width; + ctx_nx->native_window.height = ctx_nx->height; + ctx_nx->resize = true; + *resize = true; + printf("[NXGL]: Resizing to %dx%d\n", *width, *height); + gfxConfigureCrop(0, 1080 - ctx_nx->height, ctx_nx->width, 1080); } *quit = (bool)false; @@ -133,8 +158,7 @@ static bool switch_ctx_set_video_mode(void *data, switch_ctx_data_t *ctx_nx = (switch_ctx_data_t *)data; - ctx_nx->width = 1280; - ctx_nx->height = 720; + switch_ctx_get_video_size(data, &ctx_nx->width, &ctx_nx->height); ctx_nx->native_window.width = ctx_nx->width; ctx_nx->native_window.height = ctx_nx->height; @@ -154,10 +178,12 @@ static bool switch_ctx_set_video_mode(void *data, goto error; #endif + gfxConfigureCrop(0, 1080 - ctx_nx->height, ctx_nx->width, 1080); + return true; error: - printf("[ctx_nx]: EGL error: %d.\n", eglGetError()); + printf("[NXGL]: EGL error: %d.\n", eglGetError()); switch_ctx_destroy(data); return false; diff --git a/gfx/drivers_context/vc_egl_ctx.c b/gfx/drivers_context/vc_egl_ctx.c index 183ab77557..0c9ec71a3a 100644 --- a/gfx/drivers_context/vc_egl_ctx.c +++ b/gfx/drivers_context/vc_egl_ctx.c @@ -49,7 +49,6 @@ #include #endif - #ifdef HAVE_CONFIG_H #include "../../config.h" #endif diff --git a/gfx/drivers_context/wayland_ctx.c b/gfx/drivers_context/wayland_ctx.c index 01a5e52133..c08d9baf8c 100644 --- a/gfx/drivers_context/wayland_ctx.c +++ b/gfx/drivers_context/wayland_ctx.c @@ -59,7 +59,6 @@ /* Generated from xdg-decoration-unstable-v1.h */ #include "../common/wayland/xdg-decoration-unstable-v1.h" - typedef struct touch_pos { bool active; @@ -71,7 +70,6 @@ typedef struct touch_pos static int num_active_touches; static touch_pos_t active_touch_positions[MAX_TOUCHES]; - typedef struct gfx_ctx_wayland_data { #ifdef HAVE_EGL @@ -131,7 +129,6 @@ typedef struct gfx_ctx_wayland_data #endif } gfx_ctx_wayland_data_t; - static enum gfx_ctx_api wl_api = GFX_CTX_NONE; #ifndef EGL_OPENGL_ES3_BIT_KHR @@ -327,14 +324,17 @@ static void pointer_handle_button(void *data, { wl->input.mouse.left = true; - if (BIT_GET(wl->input.key_state, KEY_LEFTALT) && wl->xdg_toplevel) { - if (wl->xdg_toplevel) - xdg_toplevel_move(wl->xdg_toplevel, wl->seat, serial); - else if (wl->zxdg_toplevel) - zxdg_toplevel_v6_move(wl->zxdg_toplevel, wl->seat, serial); - else if (wl->shell) - wl_shell_surface_move(wl->shell_surf, wl->seat, serial); + if (BIT_GET(wl->input.key_state, KEY_LEFTALT)) { + if (wl->xdg_toplevel) { + xdg_toplevel_move(wl->xdg_toplevel, wl->seat, serial); } + else if (wl->zxdg_toplevel) { + zxdg_toplevel_v6_move(wl->zxdg_toplevel, wl->seat, serial); + } + else if (wl->shell) { + wl_shell_surface_move(wl->shell_surf, wl->seat, serial); + } + } } else if (button == BTN_RIGHT) wl->input.mouse.right = true; @@ -505,7 +505,6 @@ static const struct wl_touch_listener touch_listener = { touch_handle_cancel, }; - static void seat_handle_capabilities(void *data, struct wl_seat *seat, unsigned caps) { @@ -570,8 +569,6 @@ bool wayland_context_gettouchpos(void *data, unsigned id, return active_touch_positions[id].active; } - - /* Shell surface callbacks. */ static void xdg_shell_ping(void *data, struct xdg_wm_base *shell, uint32_t serial) { @@ -870,8 +867,8 @@ static void gfx_ctx_wl_get_video_size(void *data, { gfx_ctx_wayland_data_t *wl = (gfx_ctx_wayland_data_t*)data; - *width = wl->width; - *height = wl->height; + *width = wl->width * wl->buffer_scale; + *height = wl->height * wl->buffer_scale; } static void gfx_ctx_wl_destroy_resources(gfx_ctx_wayland_data_t *wl) @@ -1058,8 +1055,8 @@ static bool gfx_ctx_wl_set_resize(void *data, unsigned width, unsigned height) break; case GFX_CTX_VULKAN_API: #ifdef HAVE_VULKAN - wl->width = width; - wl->height = height; + wl->width = width / wl->buffer_scale; + wl->height = height / wl->buffer_scale; if (vulkan_create_swapchain(&wl->vk, width, height, wl->swap_interval)) { @@ -1111,7 +1108,6 @@ static void gfx_ctx_wl_update_title(void *data, void *data2) } } - static bool gfx_ctx_wl_get_metrics(void *data, enum display_metric_types type, float *value) { @@ -1327,7 +1323,6 @@ static void *gfx_ctx_wl_init(video_frame_info_t *video_info, void *video_driver) break; } - wl->input.keyboard_focus = true; wl->input.mouse.focus = true; @@ -1618,7 +1613,7 @@ static bool gfx_ctx_wl_set_video_mode(void *data, #ifdef HAVE_VULKAN if (!vulkan_surface_create(&wl->vk, VULKAN_WSI_WAYLAND, wl->input.dpy, wl->surface, - wl->width, wl->height, wl->swap_interval)) + wl->width * wl->buffer_scale, wl->height * wl->buffer_scale, wl->swap_interval)) goto error; #endif break; diff --git a/gfx/drivers_context/wgl_ctx.c b/gfx/drivers_context/wgl_ctx.c index b90a8e40c3..4508f9ac9a 100644 --- a/gfx/drivers_context/wgl_ctx.c +++ b/gfx/drivers_context/wgl_ctx.c @@ -665,7 +665,6 @@ error: return false; } - static void gfx_ctx_wgl_input_driver(void *data, const char *joypad_name, const input_driver_t **input, void **input_data) @@ -710,7 +709,6 @@ static bool gfx_ctx_wgl_has_windowed(void *data) return true; } - static bool gfx_ctx_wgl_get_metrics(void *data, enum display_metric_types type, float *value) { diff --git a/gfx/drivers_context/x_ctx.c b/gfx/drivers_context/x_ctx.c index 0f6296b820..9aa2187a40 100644 --- a/gfx/drivers_context/x_ctx.c +++ b/gfx/drivers_context/x_ctx.c @@ -491,7 +491,6 @@ static void *gfx_ctx_x_init(video_frame_info_t *video_info, void *data) if (!x11_connect()) goto error; - switch (x_api) { case GFX_CTX_OPENGL_API: diff --git a/gfx/drivers_context/xegl_ctx.c b/gfx/drivers_context/xegl_ctx.c index 24d2546c53..a61fd3c552 100644 --- a/gfx/drivers_context/xegl_ctx.c +++ b/gfx/drivers_context/xegl_ctx.c @@ -450,7 +450,6 @@ error: return false; } - static void gfx_ctx_xegl_input_driver(void *data, const char *joypad_name, const input_driver_t **input, void **input_data) diff --git a/gfx/drivers_font/ctr_font.c b/gfx/drivers_font/ctr_font.c index 4eb656f625..08af4e75d6 100644 --- a/gfx/drivers_font/ctr_font.c +++ b/gfx/drivers_font/ctr_font.c @@ -215,7 +215,6 @@ static void ctr_font_render_line( width = glyph->width; height = glyph->height; - v->x0 = x + off_x + delta_x * scale; v->y0 = y + off_y + delta_y * scale; v->u0 = tex_x; diff --git a/gfx/drivers_font/d3d_w32_font.c b/gfx/drivers_font/d3d_w32_font.c index bd176b9762..28347e03e6 100644 --- a/gfx/drivers_font/d3d_w32_font.c +++ b/gfx/drivers_font/d3d_w32_font.c @@ -30,7 +30,6 @@ #include "../../configuration.h" - typedef struct d3dx_font_desc { INT Height; @@ -87,7 +86,6 @@ static void *d3dfonts_w32_init_font(void *video_data, &desc, (void**)&d3dfonts->font)) goto error; - d3d9x_font_get_text_metrics(d3dfonts->font, &metrics); d3dfonts->ascent = metrics.tmAscent; @@ -112,7 +110,6 @@ static void d3dfonts_w32_free_font(void *data, bool is_threaded) free(d3dfonts); } - static int d3dfonts_w32_get_message_width(void* data, const char* msg, unsigned msg_len, float scale) { @@ -128,7 +125,6 @@ static int d3dfonts_w32_get_message_width(void* data, const char* msg, return box.right - box.left; } - static void d3dfonts_w32_render_msg(video_frame_info_t *video_info, void *data, const char *msg, const struct font_params *params) { diff --git a/gfx/drivers_font/gl_raster_font.c b/gfx/drivers_font/gl_raster_font.c index a1442f8a9b..37336f7e16 100644 --- a/gfx/drivers_font/gl_raster_font.c +++ b/gfx/drivers_font/gl_raster_font.c @@ -214,7 +214,6 @@ error: return NULL; } - static int gl_get_message_width(void *data, const char *msg, unsigned msg_len, float scale) { diff --git a/gfx/drivers_font/ps2_font.c b/gfx/drivers_font/ps2_font.c new file mode 100644 index 0000000000..0da4b5d7a6 --- /dev/null +++ b/gfx/drivers_font/ps2_font.c @@ -0,0 +1,124 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2019 - Francisco Javier Trujillo Mata + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#include +#include +#include + +#include "../font_driver.h" + +#define FONTM_VRAM_SIZE 4096 +#define FONTM_TEXTURE_COLOR GS_SETREG_RGBAQ(0x80,0x80,0x80,0x80,0x00) +#define FONTM_TEXTURE_WIDTH 52 +#define FONTM_TEXTURE_HEIGHT 832 +#define FONTM_TEXTURE_SPACING 1.0f +#define FONTM_TEXTURE_SCALED 0.5f +#define FONTM_TEXTURE_LEFT_MARGIN 0 +#define FONTM_TEXTURE_BOTTOM_MARGIN 15 +#define FONTM_TEXTURE_ZPOSITION 3 + +typedef struct ps2_font_info +{ + GSGLOBAL *gsGlobal; + GSFONTM *gsFontM; +} ps2_font_info_t; + +/* Copied from GSKIT FONTM CLUT + FONTM Textures are GS_PSM_T4, and need a 16x16 CLUT + This is a greyscale ramp CLUT, with linear alpha. */ +static u32 gsKit_fontm_clut[16] = { 0x00000000, 0x11111111, 0x22222222, 0x33333333, \ + 0x44444444, 0x55555555, 0x66666666, 0x77777777, \ + 0x80888888, 0x80999999, 0x80AAAAAA, 0x80BBBBBB, \ + 0x80CCCCCC, 0x80DDDDDD, 0x80EEEEEE, 0x80FFFFFF }; + +static void ps2_prepare_font(GSGLOBAL *gsGlobal, GSFONTM *gsFontM) { + if(gsKit_fontm_unpack(gsFontM) == 0) { + gsFontM->Texture->Width = FONTM_TEXTURE_WIDTH; + gsFontM->Texture->Height = FONTM_TEXTURE_HEIGHT; + gsFontM->Texture->PSM = GS_PSM_T4; + gsFontM->Texture->ClutPSM = GS_PSM_CT32; + gsFontM->Texture->Filter = GS_FILTER_LINEAR; + gsKit_setup_tbw(gsFontM->Texture); + } +} + +static void ps2_upload_font(GSGLOBAL *gsGlobal, GSFONTM *gsFontM) { + int pgindx; + int TexSize = gsKit_texture_size(gsFontM->Texture->Width, gsFontM->Texture->Height, gsFontM->Texture->PSM); + + gsFontM->Texture->VramClut = gsKit_vram_alloc(gsGlobal, FONTM_VRAM_SIZE, GSKIT_ALLOC_USERBUFFER); + + for (pgindx = 0; pgindx < GS_FONTM_PAGE_COUNT; ++pgindx) { + gsFontM->Vram[pgindx] = gsKit_vram_alloc(gsGlobal, TexSize, GSKIT_ALLOC_USERBUFFER); + gsFontM->LastPage[pgindx] = (u32) -1; + } + + gsFontM->Texture->Vram = gsFontM->Vram[0]; + gsFontM->VramIdx = 0; + gsFontM->Spacing = FONTM_TEXTURE_SPACING; + gsFontM->Align = GSKIT_FALIGN_LEFT; + + gsFontM->Texture->Clut = memalign(GS_VRAM_TBWALIGN_CLUT, GS_VRAM_TBWALIGN); + memcpy(gsFontM->Texture->Clut, gsKit_fontm_clut, GS_VRAM_TBWALIGN); + gsKit_texture_send(gsFontM->Texture->Clut, 8, 2, gsFontM->Texture->VramClut, gsFontM->Texture->ClutPSM, 1, GS_CLUT_PALLETE); + free(gsFontM->Texture->Clut); +} + +static void *ps2_font_init_font(void *gl_data, const char *font_path, + float font_size, bool is_threaded) +{ + ps2_font_info_t *ps2 = (ps2_font_info_t*)calloc(1, sizeof(ps2_font_info_t)); + ps2_video_t *ps2_video = (ps2_video_t *)gl_data; + ps2->gsGlobal = ps2_video->gsGlobal; + ps2->gsFontM = gsKit_init_fontm(); + + ps2_prepare_font(ps2->gsGlobal, ps2->gsFontM); + + return ps2; +} + +static void ps2_font_free_font(void *data, bool is_threaded) +{ + ps2_font_info_t *ps2 = (ps2_font_info_t *)data; + free(ps2->gsFontM); + free(ps2); +} + +static void ps2_font_render_msg( + video_frame_info_t *video_info, + void *data, const char *msg, + const struct font_params *params) +{ + ps2_font_info_t *ps2 = (ps2_font_info_t *)data; + + if (ps2) { + int x = FONTM_TEXTURE_LEFT_MARGIN; + int y = ps2->gsGlobal->Height - FONTM_TEXTURE_BOTTOM_MARGIN; + ps2_upload_font(ps2->gsGlobal, ps2->gsFontM); + gsKit_fontm_print_scaled(ps2->gsGlobal, ps2->gsFontM, x, y, FONTM_TEXTURE_ZPOSITION, + FONTM_TEXTURE_SCALED , FONTM_TEXTURE_COLOR, msg); + } +} + +font_renderer_t ps2_font = { + ps2_font_init_font, + ps2_font_free_font, + ps2_font_render_msg, + "PS2 font", + NULL, /* get_glyph */ + NULL, /* bind_block */ + NULL, /* flush */ + NULL, /* get_message_width */ +}; diff --git a/gfx/drivers_font/vulkan_raster_font.c b/gfx/drivers_font/vulkan_raster_font.c index 5fe9a13abc..bfdfadbc4c 100644 --- a/gfx/drivers_font/vulkan_raster_font.c +++ b/gfx/drivers_font/vulkan_raster_font.c @@ -139,7 +139,6 @@ static int vulkan_get_message_width(void *data, const char *msg, if (!glyph) /* Do something smarter here ... */ glyph = font->font_driver->get_glyph(font->font_data, '?'); - if (glyph) { vulkan_raster_font_update_glyph(font, glyph); diff --git a/gfx/drivers_font/wiiu_font.c b/gfx/drivers_font/wiiu_font.c index 447360e582..74246e68ca 100644 --- a/gfx/drivers_font/wiiu_font.c +++ b/gfx/drivers_font/wiiu_font.c @@ -87,7 +87,6 @@ static void* wiiu_font_init_font(void* data, const char* font_path, GX2Invalidate(GX2_INVALIDATE_MODE_CPU_UNIFORM_BLOCK, font->ubo_tex, sizeof(*font->ubo_tex)); - return font; } @@ -215,7 +214,6 @@ static void wiiu_font_render_line( if (!count) return; - GX2Invalidate(GX2_INVALIDATE_MODE_CPU_ATTRIBUTE_BUFFER, wiiu->vertex_cache.v + wiiu->vertex_cache.current, count * sizeof(wiiu->vertex_cache.v)); if(font->atlas->dirty) @@ -229,7 +227,6 @@ static void wiiu_font_render_line( font->atlas->dirty = false; } - GX2SetPixelTexture(&font->texture, sprite_shader.ps.samplerVars[0].location); GX2SetVertexUniformBlock(sprite_shader.vs.uniformBlocks[1].offset, sprite_shader.vs.uniformBlocks[1].size, font->ubo_tex); diff --git a/gfx/drivers_font/xdk360_fonts.cpp b/gfx/drivers_font/xdk360_fonts.cpp index cc5472ff9b..b7bc9b6f1b 100644 --- a/gfx/drivers_font/xdk360_fonts.cpp +++ b/gfx/drivers_font/xdk360_fonts.cpp @@ -35,7 +35,6 @@ #define CALCFONTFILEHEADERSIZE(x) ( sizeof(uint32_t) + (sizeof(float)* 4) + sizeof(uint16_t) + (sizeof(wchar_t)*(x)) ) #define FONTFILEVERSION 5 - #ifdef _XBOX360 struct XPR_HEADER { diff --git a/gfx/drivers_font_renderer/stb_unicode.c b/gfx/drivers_font_renderer/stb_unicode.c index 8ed34eb61b..72c925b14a 100644 --- a/gfx/drivers_font_renderer/stb_unicode.c +++ b/gfx/drivers_font_renderer/stb_unicode.c @@ -145,7 +145,6 @@ static const struct font_glyph *font_renderer_stb_unicode_get_glyph( dst = (uint8_t*)self->atlas.buffer + atlas_slot->glyph.atlas_offset_x + atlas_slot->glyph.atlas_offset_y * self->atlas.width; - stbtt_MakeGlyphBitmap(&self->info, dst, self->max_glyph_width, self->max_glyph_height, self->atlas.width, self->scale_factor, self->scale_factor, glyph_index); @@ -159,7 +158,6 @@ static const struct font_glyph *font_renderer_stb_unicode_get_glyph( atlas_slot->glyph.draw_offset_x = x0 * self->scale_factor; atlas_slot->glyph.draw_offset_y = -y1 * self->scale_factor; - self->atlas.dirty = true; atlas_slot->last_used = self->usage_counter++; return &atlas_slot->glyph; @@ -262,7 +260,7 @@ static const char *font_renderer_stb_unicode_get_default_font(void) return ""; #else static const char *paths[] = { -#if defined(_WIN32) +#if defined(_WIN32) && !defined(__WINRT__) "C:\\Windows\\Fonts\\consola.ttf", "C:\\Windows\\Fonts\\verdana.ttf", #elif defined(__APPLE__) @@ -283,7 +281,7 @@ static const char *font_renderer_stb_unicode_get_default_font(void) "vs0:data/external/font/pvf/k006004ds.ttf", "vs0:data/external/font/pvf/n023055ms.ttf", "vs0:data/external/font/pvf/n023055ts.ttf", -#else +#elif !defined(__WINRT__) "/usr/share/fonts/TTF/DejaVuSansMono.ttf", "/usr/share/fonts/TTF/DejaVuSans.ttf", "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSansMono.ttf", diff --git a/gfx/drivers_renderchain/d3d9_hlsl_renderchain.c b/gfx/drivers_renderchain/d3d9_hlsl_renderchain.c index cfe05f895b..32627dfee2 100644 --- a/gfx/drivers_renderchain/d3d9_hlsl_renderchain.c +++ b/gfx/drivers_renderchain/d3d9_hlsl_renderchain.c @@ -319,7 +319,6 @@ static void hlsl_d3d9_renderchain_calc_and_set_shader_mvp( chain->chain.dev, "modelViewProj", (const void*)&matrix); } - static void hlsl_d3d9_renderchain_set_vertices( d3d9_video_t *d3d, hlsl_renderchain_t *chain, diff --git a/gfx/drivers_renderchain/d3d9_renderchain.h b/gfx/drivers_renderchain/d3d9_renderchain.h index a9c36b0e40..7e6274d0d6 100644 --- a/gfx/drivers_renderchain/d3d9_renderchain.h +++ b/gfx/drivers_renderchain/d3d9_renderchain.h @@ -414,7 +414,6 @@ static INLINE void d3d9_recompute_pass_sizes( link_info.tex_w = current_width; link_info.tex_h = current_height; - if (!d3d9_renderchain_set_pass_size(dev, (struct shader_pass*)&chain->passes->data[0], (struct shader_pass*)&chain->passes->data[ diff --git a/gfx/drivers_renderchain/gl2_renderchain.c b/gfx/drivers_renderchain/gl2_renderchain.c index 64a138218f..b93eab425c 100644 --- a/gfx/drivers_renderchain/gl2_renderchain.c +++ b/gfx/drivers_renderchain/gl2_renderchain.c @@ -142,7 +142,6 @@ typedef struct gl2_renderchain #endif - #ifndef GL_SYNC_GPU_COMMANDS_COMPLETE #define GL_SYNC_GPU_COMMANDS_COMPLETE 0x9117 #endif diff --git a/gfx/drivers_shader/glslang_util.cpp b/gfx/drivers_shader/glslang_util.cpp index d2e9a993f7..eb7dbfe41d 100644 --- a/gfx/drivers_shader/glslang_util.cpp +++ b/gfx/drivers_shader/glslang_util.cpp @@ -377,7 +377,6 @@ bool glslang_parse_meta(const vector &lines, glslang_meta *meta) return true; } - #if defined(HAVE_GLSLANG) bool glslang_compile_shader(const char *shader_path, glslang_output *output) { diff --git a/gfx/drivers_shader/shader_gl_cg.c b/gfx/drivers_shader/shader_gl_cg.c index 4e89540b63..966d11fb8a 100644 --- a/gfx/drivers_shader/shader_gl_cg.c +++ b/gfx/drivers_shader/shader_gl_cg.c @@ -131,7 +131,6 @@ struct uniform_cg cgGLEnableTextureParameter(param); \ } - #include "../drivers/gl_shaders/opaque.cg.h" static void gl_cg_set_uniform_parameter( @@ -207,7 +206,6 @@ static void gl_cg_set_uniform_parameter( } } - #ifdef RARCH_CG_DEBUG static void cg_error_handler(CGcontext ctx, CGerror error, void *data) { @@ -1169,7 +1167,6 @@ static void *gl_cg_init(void *data, const char *path) gl_cg_set_shaders(cg->prg[1].fprg, cg->prg[1].vprg); - gl_cg_reset_attrib(cg); return cg; diff --git a/gfx/drivers_shader/shader_glsl.c b/gfx/drivers_shader/shader_glsl.c index f9bed812e8..4cf1b64c41 100644 --- a/gfx/drivers_shader/shader_glsl.c +++ b/gfx/drivers_shader/shader_glsl.c @@ -99,7 +99,6 @@ struct shader_uniforms struct shader_uniforms_frame prev[PREV_TEXTURES]; }; - static const char *glsl_prefixes[] = { "", "ruby", @@ -401,7 +400,6 @@ static bool gl_glsl_link_program(GLuint prog) return true; } - static bool gl_glsl_compile_program( void *data, unsigned idx, @@ -1412,7 +1410,6 @@ static void gl_glsl_set_params(void *dat, void *shader_data) texunit++; } - if (uni->prev[i].texture_size >= 0) glUniform2fv(uni->prev[i].texture_size, 1, prev_info[i].tex_size); diff --git a/gfx/drivers_shader/shader_glsl.h b/gfx/drivers_shader/shader_glsl.h index 311bccdc95..8633a77f26 100644 --- a/gfx/drivers_shader/shader_glsl.h +++ b/gfx/drivers_shader/shader_glsl.h @@ -14,7 +14,6 @@ * If not, see . */ - #ifndef __RARCH_GLSL_H #define __RARCH_GLSL_H diff --git a/gfx/drivers_tracker/video_state_python.c b/gfx/drivers_tracker/video_state_python.c index 3e4e1afb99..8c95734771 100644 --- a/gfx/drivers_tracker/video_state_python.c +++ b/gfx/drivers_tracker/video_state_python.c @@ -104,7 +104,6 @@ static PyObject* py_read_vram(PyObject *self, PyObject *args) return PyLong_FromLong(data[addr]); } - static PyObject *py_read_input(PyObject *self, PyObject *args) { unsigned user, key, i; diff --git a/gfx/font_driver.c b/gfx/font_driver.c index 07ce2dd93c..64f92beb43 100644 --- a/gfx/font_driver.c +++ b/gfx/font_driver.c @@ -278,7 +278,7 @@ static bool vga_font_init_first( } #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) static const font_renderer_t *gdi_font_backends[] = { &gdi_font, NULL, @@ -464,6 +464,36 @@ static bool d3d12_font_init_first( } #endif +#ifdef PS2 +static const font_renderer_t *ps2_font_backends[] = { + &ps2_font +}; + +static bool ps2_font_init_first( + const void **font_driver, void **font_handle, + void *video_data, const char *font_path, + float font_size, bool is_threaded) +{ + unsigned i; + + for (i = 0; ps2_font_backends[i]; i++) + { + void *data = ps2_font_backends[i]->init( + video_data, font_path, font_size, + is_threaded); + + if (!data) + continue; + + *font_driver = ps2_font_backends[i]; + *font_handle = data; + return true; + } + + return false; +} +#endif + #ifdef HAVE_VITA2D static const font_renderer_t *vita2d_font_backends[] = { &vita2d_vita_font @@ -641,6 +671,11 @@ static bool font_init_first( return vita2d_font_init_first(font_driver, font_handle, video_data, font_path, font_size, is_threaded); #endif +#ifdef PS2 + case FONT_DRIVER_RENDER_PS2: + return ps2_font_init_first(font_driver, font_handle, + video_data, font_path, font_size, is_threaded); +#endif #ifdef _3DS case FONT_DRIVER_RENDER_CTR: return ctr_font_init_first(font_driver, font_handle, @@ -666,7 +701,7 @@ static bool font_init_first( return switch_font_init_first(font_driver, font_handle, video_data, font_path, font_size, is_threaded); #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) case FONT_DRIVER_RENDER_GDI: return gdi_font_init_first(font_driver, font_handle, video_data, font_path, font_size, is_threaded); @@ -958,7 +993,6 @@ void font_driver_flush(unsigned width, unsigned height, void *font_data, font->renderer->flush(width, height, font->renderer_data, video_info); } - int font_driver_get_message_width(void *font_data, const char *msg, unsigned len, float scale) { @@ -1023,7 +1057,6 @@ font_data_t *font_driver_init_first( return NULL; } - void font_driver_init_osd( void *video_data, bool threading_hint, diff --git a/gfx/font_driver.h b/gfx/font_driver.h index 03f08c6d54..499c0a16e1 100644 --- a/gfx/font_driver.h +++ b/gfx/font_driver.h @@ -161,6 +161,7 @@ extern font_renderer_t libdbg_font; extern font_renderer_t d3d_xbox360_font; extern font_renderer_t d3d_xdk1_font; extern font_renderer_t d3d_win32_font; +extern font_renderer_t ps2_font; extern font_renderer_t vita2d_vita_font; extern font_renderer_t ctr_font; extern font_renderer_t wiiu_font; diff --git a/gfx/include/GL/glext.h b/gfx/include/GL/glext.h index a0d2948292..2a38dad599 100644 --- a/gfx/include/GL/glext.h +++ b/gfx/include/GL/glext.h @@ -6138,7 +6138,6 @@ extern "C" { #define GL_TEXTURE_STORAGE_SPARSE_BIT_AMD 0x00000001 #endif - /*************************************************************/ #include @@ -12732,7 +12731,6 @@ typedef void (APIENTRYP PFNGLTEXSTORAGESPARSEAMDPROC) (GLenum target, GLenum int typedef void (APIENTRYP PFNGLTEXTURESTORAGESPARSEAMDPROC) (GLuint texture, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags); #endif - #ifdef __cplusplus } #endif diff --git a/gfx/include/d3d8/d3d8.h b/gfx/include/d3d8/d3d8.h index 4bfff6d4f0..cefb9d3137 100644 --- a/gfx/include/d3d8/d3d8.h +++ b/gfx/include/d3d8/d3d8.h @@ -25,7 +25,6 @@ #define D3D_SDK_VERSION 220 - #include #define COM_NO_WINDOWS_H @@ -116,7 +115,6 @@ interface IDirect3DSwapChain8; #endif - typedef interface IDirect3D8 IDirect3D8; typedef interface IDirect3DDevice8 IDirect3DDevice8; typedef interface IDirect3DResource8 IDirect3DResource8; @@ -133,7 +131,6 @@ typedef interface IDirect3DSwapChain8 IDirect3DSwapChain8; #include "d3d8types.h" #include "d3d8caps.h" - #ifdef __cplusplus extern "C" { #endif @@ -1130,7 +1127,6 @@ typedef struct IDirect3DVolume8 *LPDIRECT3DVOLUME8, *PDIRECT3DVOLUME8; #define D3DCREATE_DISABLE_DRIVER_MANAGEMENT 0x00000100L - /**************************************************************************** * * Parameter for IDirect3D8::CreateDevice's iAdapter diff --git a/gfx/include/d3d8/d3dx8core.h b/gfx/include/d3d8/d3dx8core.h index 7542f28924..b8f935ec00 100644 --- a/gfx/include/d3d8/d3dx8core.h +++ b/gfx/include/d3d8/d3dx8core.h @@ -11,8 +11,6 @@ #ifndef __D3DX8CORE_H__ #define __D3DX8CORE_H__ - - /* * ID3DXBuffer: * ------------ @@ -79,7 +77,6 @@ typedef interface ID3DXFont *LPD3DXFONT; DEFINE_GUID( IID_ID3DXFont, 0x89fad6a5, 0x24d, 0x49af, 0x8f, 0xe7, 0xf5, 0x11, 0x23, 0xb8, 0x5e, 0x25); - #undef INTERFACE #define INTERFACE ID3DXFont @@ -111,7 +108,6 @@ DECLARE_INTERFACE_(ID3DXFont, IUnknown) #endif #endif - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -122,7 +118,6 @@ HRESULT WINAPI HFONT hFont, LPD3DXFONT* ppFont); - HRESULT WINAPI D3DXCreateFontIndirect( LPDIRECT3DDEVICE8 pDevice, @@ -158,12 +153,10 @@ HRESULT WINAPI typedef interface ID3DXSprite ID3DXSprite; typedef interface ID3DXSprite *LPD3DXSPRITE; - /* {13D69D15-F9B0-4e0f-B39E-C91EB33F6CE7} */ DEFINE_GUID( IID_ID3DXSprite, 0x13d69d15, 0xf9b0, 0x4e0f, 0xb3, 0x9e, 0xc9, 0x1e, 0xb3, 0x3f, 0x6c, 0xe7); - #undef INTERFACE #define INTERFACE ID3DXSprite @@ -194,12 +187,10 @@ DECLARE_INTERFACE_(ID3DXSprite, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - HRESULT WINAPI D3DXCreateSprite( LPDIRECT3DDEVICE8 pDevice, @@ -209,9 +200,6 @@ HRESULT WINAPI } #endif /* __cplusplus */ - - - /* * ID3DXRenderToSurface: * --------------------- @@ -240,7 +228,6 @@ typedef struct _D3DXRTS_DESC } D3DXRTS_DESC; - typedef interface ID3DXRenderToSurface ID3DXRenderToSurface; typedef interface ID3DXRenderToSurface *LPD3DXRENDERTOSURFACE; @@ -269,7 +256,6 @@ DECLARE_INTERFACE_(ID3DXRenderToSurface, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -288,8 +274,6 @@ HRESULT WINAPI } #endif /* __cplusplus */ - - /* * ID3DXRenderToEnvMap: * -------------------- @@ -326,7 +310,6 @@ typedef struct _D3DXRTE_DESC D3DFORMAT DepthStencilFormat; } D3DXRTE_DESC; - typedef interface ID3DXRenderToEnvMap ID3DXRenderToEnvMap; typedef interface ID3DXRenderToEnvMap *LPD3DXRenderToEnvMap; @@ -334,7 +317,6 @@ typedef interface ID3DXRenderToEnvMap *LPD3DXRenderToEnvMap; DEFINE_GUID( IID_ID3DXRenderToEnvMap, 0x4e42c623, 0x9451, 0x44b7, 0x8c, 0x86, 0xab, 0xcc, 0xde, 0x5d, 0x52, 0xc8); - #undef INTERFACE #define INTERFACE ID3DXRenderToEnvMap @@ -370,7 +352,6 @@ DECLARE_INTERFACE_(ID3DXRenderToEnvMap, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -388,8 +369,6 @@ HRESULT WINAPI } #endif /* __cplusplus */ - - /* * Shader assemblers: */ @@ -410,7 +389,6 @@ HRESULT WINAPI #define D3DXASM_DEBUG (1 << 0) #define D3DXASM_SKIPVALIDATION (1 << 1) - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -497,13 +475,10 @@ HRESULT WINAPI LPD3DXBUFFER* ppCompiledShader, LPD3DXBUFFER* ppCompilationErrors); - #ifdef __cplusplus } #endif /* __cplusplus */ - - /* * Misc APIs: */ @@ -545,8 +520,6 @@ HRESULT WINAPI #define D3DXGetErrorString D3DXGetErrorStringA #endif - - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/gfx/include/d3d8/d3dx8effect.h b/gfx/include/d3d8/d3dx8effect.h index 45b4fc8be9..7fbb9991a7 100644 --- a/gfx/include/d3d8/d3dx8effect.h +++ b/gfx/include/d3d8/d3dx8effect.h @@ -11,10 +11,8 @@ #ifndef __D3DX8EFFECT_H__ #define __D3DX8EFFECT_H__ - #define D3DXFX_DONOTSAVESTATE (1 << 0) - typedef enum _D3DXPARAMETERTYPE { D3DXPT_DWORD = 0, @@ -30,7 +28,6 @@ typedef enum _D3DXPARAMETERTYPE } D3DXPARAMETERTYPE; - typedef struct _D3DXEFFECT_DESC { UINT Parameters; @@ -38,7 +35,6 @@ typedef struct _D3DXEFFECT_DESC } D3DXEFFECT_DESC; - typedef struct _D3DXPARAMETER_DESC { LPCSTR Name; @@ -47,7 +43,6 @@ typedef struct _D3DXPARAMETER_DESC } D3DXPARAMETER_DESC; - typedef struct _D3DXTECHNIQUE_DESC { LPCSTR Name; @@ -56,7 +51,6 @@ typedef struct _D3DXTECHNIQUE_DESC } D3DXTECHNIQUE_DESC; - typedef struct _D3DXPASS_DESC { LPCSTR Name; @@ -64,8 +58,6 @@ typedef struct _D3DXPASS_DESC } D3DXPASS_DESC; - - /* * ID3DXEffect */ @@ -77,7 +69,6 @@ typedef interface ID3DXEffect *LPD3DXEFFECT; DEFINE_GUID( IID_ID3DXEffect, 0x648b1ceb, 0x8d4e, 0x4d66, 0xb6, 0xfa, 0xe4, 0x49, 0x69, 0xe8, 0x2e, 0x89); - #undef INTERFACE #define INTERFACE ID3DXEffect @@ -127,18 +118,14 @@ DECLARE_INTERFACE_(ID3DXEffect, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - - /* * APIs */ - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - /* * D3DXCreateEffect: * ----------------- @@ -185,7 +172,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromFile D3DXCreateEffectFromFileA #endif - HRESULT WINAPI D3DXCreateEffectFromResourceA( LPDIRECT3DDEVICE8 pDevice, @@ -208,7 +194,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromResource D3DXCreateEffectFromResourceA #endif - HRESULT WINAPI D3DXCreateEffect( LPDIRECT3DDEVICE8 pDevice, @@ -217,7 +202,6 @@ HRESULT WINAPI LPD3DXEFFECT* ppEffect, LPD3DXBUFFER* ppCompilationErrors); - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/gfx/include/d3d8/d3dx8math.h b/gfx/include/d3d8/d3dx8math.h index c126258db3..b4764488b6 100644 --- a/gfx/include/d3d8/d3dx8math.h +++ b/gfx/include/d3d8/d3dx8math.h @@ -26,8 +26,6 @@ #define D3DXToRadian( degree ) ((degree) * (D3DX_PI / 180.0f)) #define D3DXToDegree( radian ) ((radian) * (180.0f / D3DX_PI)) - - /* * * Vectors @@ -70,13 +68,11 @@ public: BOOL operator == ( CONST D3DXVECTOR2& ) const; BOOL operator != ( CONST D3DXVECTOR2& ) const; - public: #endif /* __cplusplus */ FLOAT x, y; } D3DXVECTOR2, *LPD3DXVECTOR2; - /* * 3D Vector */ @@ -120,7 +116,6 @@ public: typedef struct _D3DVECTOR D3DXVECTOR3, *LPD3DXVECTOR3; #endif /* !__cplusplus */ - /* * 4D Vector */ @@ -162,7 +157,6 @@ public: FLOAT x, y, z, w; } D3DXVECTOR4, *LPD3DXVECTOR4; - /* * * Matrices @@ -180,7 +174,6 @@ public: FLOAT _31, FLOAT _32, FLOAT _33, FLOAT _34, FLOAT _41, FLOAT _42, FLOAT _43, FLOAT _44 ); - /* access grants */ FLOAT& operator () ( UINT Row, UINT Col ); FLOAT operator () ( UINT Row, UINT Col ) const; @@ -362,7 +355,6 @@ public: FLOAT x, y, z, w; } D3DXQUATERNION, *LPD3DXQUATERNION; - /* * * Planes @@ -392,7 +384,6 @@ public: FLOAT a, b, c, d; } D3DXPLANE, *LPD3DXPLANE; - /* * * Colors @@ -446,8 +437,6 @@ public: FLOAT r, g, b, a; } D3DXCOLOR, *LPD3DXCOLOR; - - /* * * D3DX math functions: @@ -707,7 +696,6 @@ D3DXVECTOR4* WINAPI D3DXVec4Transform } #endif - /* * 4D Matrix */ @@ -720,7 +708,6 @@ D3DXMATRIX* D3DXMatrixIdentity BOOL D3DXMatrixIsIdentity ( CONST D3DXMATRIX *pM ); - /* non-inline */ #ifdef __cplusplus extern "C" { @@ -780,7 +767,6 @@ D3DXMATRIX* WINAPI D3DXMatrixRotationQuaternion D3DXMATRIX* WINAPI D3DXMatrixRotationYawPitchRoll ( D3DXMATRIX *pOut, FLOAT Yaw, FLOAT Pitch, FLOAT Roll ); - /* Build transformation matrix. NULL arguments are treated as identity. * Mout = Msc-1 * Msr-1 * Ms * Msr * Msc * Mrc-1 * Mr * Mrc * Mt */ D3DXMATRIX* WINAPI D3DXMatrixTransformation @@ -863,7 +849,6 @@ D3DXMATRIX* WINAPI D3DXMatrixReflect } #endif - /* * Quaternion */ @@ -891,7 +876,6 @@ BOOL D3DXQuaternionIsIdentity D3DXQUATERNION* D3DXQuaternionConjugate ( D3DXQUATERNION *pOut, CONST D3DXQUATERNION *pQ ); - /* non-inline */ #ifdef __cplusplus extern "C" { @@ -969,7 +953,6 @@ D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric } #endif - /* * Plane */ @@ -1021,7 +1004,6 @@ D3DXPLANE* WINAPI D3DXPlaneTransform } #endif - /* * Color */ @@ -1097,7 +1079,6 @@ typedef interface ID3DXMatrixStack *LPD3DXMATRIXSTACK; DEFINE_GUID( IID_ID3DXMatrixStack, 0xe3357330, 0xcc5e, 0x11d2, 0xa4, 0x34, 0x0, 0xa0, 0xc9, 0x6, 0x29, 0xa8); - #undef INTERFACE #define INTERFACE ID3DXMatrixStack diff --git a/gfx/include/d3d8/d3dx8mesh.h b/gfx/include/d3d8/d3dx8mesh.h index 41e623cabf..40da3a1147 100644 --- a/gfx/include/d3d8/d3dx8mesh.h +++ b/gfx/include/d3d8/d3dx8mesh.h @@ -140,7 +140,6 @@ typedef struct _D3DXWELDEPSILONS typedef D3DXWELDEPSILONS* LPD3DXWELDEPSILONS; - #undef INTERFACE #define INTERFACE ID3DXBaseMesh @@ -177,7 +176,6 @@ DECLARE_INTERFACE_(ID3DXBaseMesh, IUnknown) STDMETHOD(GenerateAdjacency)(THIS_ FLOAT Epsilon, DWORD* pAdjacency) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXMesh @@ -224,7 +222,6 @@ DECLARE_INTERFACE_(ID3DXMesh, ID3DXBaseMesh) }; - #undef INTERFACE #define INTERFACE ID3DXPMesh @@ -284,7 +281,6 @@ DECLARE_INTERFACE_(ID3DXPMesh, ID3DXBaseMesh) STDMETHOD(GetAdjacency)(THIS_ DWORD* pAdjacency) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXSPMesh @@ -343,7 +339,6 @@ typedef struct _D3DXBONECOMBINATION DWORD* BoneId; } D3DXBONECOMBINATION, *LPD3DXBONECOMBINATION; - #undef INTERFACE #define INTERFACE ID3DXSkinMesh @@ -498,7 +493,6 @@ HRESULT WINAPI DWORD NumBytes, LPD3DXBUFFER *ppBuffer); - HRESULT WINAPI D3DXLoadMeshFromX( LPSTR pFilename, @@ -638,7 +632,6 @@ typedef struct _D3DXINTERSECTINFO FLOAT Dist; /* Ray-Intersection Parameter Distance */ } D3DXINTERSECTINFO, *LPD3DXINTERSECTINFO; - HRESULT WINAPI D3DXIntersect( LPD3DXBASEMESH pMesh, @@ -666,7 +659,6 @@ HRESULT WINAPI LPD3DXBUFFER *ppAllHits, /* Array of D3DXINTERSECTINFOs for all hits (not just closest) */ DWORD *pCountOfHits); /* Number of entries in AllHits array */ - HRESULT WINAPI D3DXSplitMesh ( CONST LPD3DXMESH pMeshIn, @@ -715,7 +707,6 @@ enum _D3DXERR { D3DXERR_LOADEDMESHASNODATA = MAKE_DDHRESULT(2906), }; - #define D3DX_COMP_TANGENT_NONE 0xFFFFFFFF HRESULT WINAPI D3DXComputeTangent(LPD3DXMESH InMesh, @@ -748,11 +739,9 @@ D3DXConvertMeshSubsetToStrips DWORD *pNumStrips ); - #ifdef __cplusplus } #endif /* __cplusplus */ #endif /* __D3DX8MESH_H__ */ - diff --git a/gfx/include/d3d8/d3dx8shape.h b/gfx/include/d3d8/d3dx8shape.h index c8b982dc8c..545c82583d 100644 --- a/gfx/include/d3d8/d3dx8shape.h +++ b/gfx/include/d3d8/d3dx8shape.h @@ -43,7 +43,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /* * D3DXCreateBox: * -------------- @@ -68,7 +67,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /* * D3DXCreateCylinder: * ------------------- @@ -98,7 +96,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /*------------------------------------------------------------------------- * D3DXCreateSphere: * ----------------- @@ -124,7 +121,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /*------------------------------------------------------------------------- * D3DXCreateTorus: * ---------------- @@ -152,7 +148,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /*------------------------------------------------------------------------- * D3DXCreateTeapot: * ----------------- @@ -171,7 +166,6 @@ HRESULT WINAPI LPD3DXMESH* ppMesh, LPD3DXBUFFER* ppAdjacency); - /*------------------------------------------------------------------------- * D3DXCreateText: * --------------- @@ -217,7 +211,6 @@ HRESULT WINAPI #define D3DXCreateText D3DXCreateTextA #endif - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/gfx/include/d3d8/d3dx8tex.h b/gfx/include/d3d8/d3dx8tex.h index 0a2526996f..70ed0583af 100644 --- a/gfx/include/d3d8/d3dx8tex.h +++ b/gfx/include/d3d8/d3dx8tex.h @@ -121,9 +121,6 @@ #define D3DX_CHANNEL_ALPHA (1 << 3) #define D3DX_CHANNEL_LUMINANCE (1 << 4) - - - /* * D3DXIMAGE_FILEFORMAT: * --------------------- @@ -144,7 +141,6 @@ typedef enum _D3DXIMAGE_FILEFORMAT } D3DXIMAGE_FILEFORMAT; - /* * LPD3DXFILL2D and LPD3DXFILL3D: * ------------------------------ @@ -251,7 +247,6 @@ HRESULT WINAPI #define D3DXGetImageInfoFromFile D3DXGetImageInfoFromFileA #endif - HRESULT WINAPI D3DXGetImageInfoFromResourceA( HMODULE hSrcModule, @@ -270,7 +265,6 @@ HRESULT WINAPI #define D3DXGetImageInfoFromResource D3DXGetImageInfoFromResourceA #endif - HRESULT WINAPI D3DXGetImageInfoFromFileInMemory( LPCVOID pSrcData, @@ -348,8 +342,6 @@ HRESULT WINAPI #define D3DXLoadSurfaceFromFile D3DXLoadSurfaceFromFileA #endif - - HRESULT WINAPI D3DXLoadSurfaceFromResourceA( LPDIRECT3DSURFACE8 pDestSurface, @@ -374,15 +366,12 @@ HRESULT WINAPI D3DCOLOR ColorKey, D3DXIMAGE_INFO* pSrcInfo); - #ifdef UNICODE #define D3DXLoadSurfaceFromResource D3DXLoadSurfaceFromResourceW #else #define D3DXLoadSurfaceFromResource D3DXLoadSurfaceFromResourceA #endif - - HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory( LPDIRECT3DSURFACE8 pDestSurface, @@ -482,7 +471,6 @@ HRESULT WINAPI DWORD Filter, D3DCOLOR ColorKey); - /* * D3DXSaveSurfaceToFile: * ---------------------- @@ -595,7 +583,6 @@ HRESULT WINAPI #define D3DXLoadVolumeFromFile D3DXLoadVolumeFromFileA #endif - HRESULT WINAPI D3DXLoadVolumeFromResourceA( LPDIRECT3DVOLUME8 pDestVolume, @@ -626,8 +613,6 @@ HRESULT WINAPI #define D3DXLoadVolumeFromResource D3DXLoadVolumeFromResourceA #endif - - HRESULT WINAPI D3DXLoadVolumeFromFileInMemory( LPDIRECT3DVOLUME8 pDestVolume, @@ -829,7 +814,6 @@ HRESULT WINAPI D3DFORMAT* pFormat, D3DPOOL Pool); - /* * D3DXCreateTexture: * ------------------ @@ -961,7 +945,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromFile D3DXCreateTextureFromFileA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromFileA( LPDIRECT3DDEVICE8 pDevice, @@ -980,7 +963,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromFile D3DXCreateCubeTextureFromFileA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromFileA( LPDIRECT3DDEVICE8 pDevice, @@ -1021,7 +1003,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromResource D3DXCreateTextureFromResourceA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromResourceA( LPDIRECT3DDEVICE8 pDevice, @@ -1042,7 +1023,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromResource D3DXCreateCubeTextureFromResourceA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromResourceA( LPDIRECT3DDEVICE8 pDevice, @@ -1105,7 +1085,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromFileEx D3DXCreateTextureFromFileExA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromFileExA( LPDIRECT3DDEVICE8 pDevice, @@ -1144,7 +1123,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromFileEx D3DXCreateCubeTextureFromFileExA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromFileExA( LPDIRECT3DDEVICE8 pDevice, @@ -1231,7 +1209,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromResourceEx D3DXCreateTextureFromResourceExA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromResourceExA( LPDIRECT3DDEVICE8 pDevice, @@ -1272,7 +1249,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromResourceEx D3DXCreateCubeTextureFromResourceExA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromResourceExA( LPDIRECT3DDEVICE8 pDevice, @@ -1340,7 +1316,6 @@ HRESULT WINAPI UINT SrcDataSize, LPDIRECT3DVOLUMETEXTURE8* ppVolumeTexture); - /* FromFileInMemoryEx */ HRESULT WINAPI @@ -1531,9 +1506,6 @@ HRESULT WINAPI DWORD Channel, FLOAT Amplitude); - - - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/gfx/include/d3d9.h b/gfx/include/d3d9.h index 5dc0e93015..6b2db5ab93 100644 --- a/gfx/include/d3d9.h +++ b/gfx/include/d3d9.h @@ -17,7 +17,6 @@ /* include this file content only if compiling for DX9 interfaces */ #if(DIRECT3D_VERSION >= 0x0900) - /* This identifier is passed to Direct3DCreate9 in order to ensure that an * application was built against the correct header files. This number is * incremented whenever a header (or other) change would require applications @@ -26,7 +25,6 @@ #define D3D_SDK_VERSION 31 - #include #define COM_NO_WINDOWS_H @@ -114,7 +112,6 @@ DEFINE_GUID(IID_IDirect3DStateBlock9, 0xb07c4fe5, 0x310d, 0x4ba8, 0xa2, 0x3c, 0x /* {d9771460-a695-4f26-bbd3-27b840b541cc} */ DEFINE_GUID(IID_IDirect3DQuery9, 0xd9771460, 0xa695, 0x4f26, 0xbb, 0xd3, 0x27, 0xb8, 0x40, 0xb5, 0x41, 0xcc); - #endif #ifdef __cplusplus @@ -149,7 +146,6 @@ interface DECLSPEC_UUID("24F416E6-1F67-4aa7-B88E-D33F6F3128A1") IDirect3DVolume9 interface DECLSPEC_UUID("794950F2-ADFC-458a-905E-10A10B0B503B") IDirect3DSwapChain9; interface DECLSPEC_UUID("d9771460-a695-4f26-bbd3-27b840b541cc") IDirect3DQuery9; - #if defined(_COM_SMARTPTR_TYPEDEF) _COM_SMARTPTR_TYPEDEF(IDirect3D9, __uuidof(IDirect3D9)); _COM_SMARTPTR_TYPEDEF(IDirect3DDevice9, __uuidof(IDirect3DDevice9)); @@ -176,7 +172,6 @@ _COM_SMARTPTR_TYPEDEF(IDirect3DQuery9, __uuidof(IDirect3DQuery9)); #endif #endif - typedef interface IDirect3D9 IDirect3D9; typedef interface IDirect3DDevice9 IDirect3DDevice9; typedef interface IDirect3DStateBlock9 IDirect3DStateBlock9; @@ -212,15 +207,10 @@ extern "C" { IDirect3D9 * WINAPI Direct3DCreate9(UINT SDKVersion); - /* * Direct3D interfaces */ - - - - #undef INTERFACE #define INTERFACE IDirect3D9 @@ -288,28 +278,8 @@ typedef struct IDirect3D9 *LPDIRECT3D9, *PDIRECT3D9; #define IDirect3D9_CreateDevice(p,a,b,c,d,e,f) (p)->CreateDevice(a,b,c,d,e,f) #endif - - - - - - /* SwapChain */ - - - - - - - - - - - - - - #undef INTERFACE #define INTERFACE IDirect3DDevice9 @@ -683,7 +653,6 @@ typedef struct IDirect3DDevice9 *LPDIRECT3DDEVICE9, *PDIRECT3DDEVICE9; #define IDirect3DDevice9_CreateQuery(p,a,b) (p)->CreateQuery(a,b) #endif - #undef INTERFACE #define INTERFACE IDirect3DStateBlock9 @@ -718,8 +687,6 @@ typedef struct IDirect3DStateBlock9 *LPDIRECT3DSTATEBLOCK9, *PDIRECT3DSTATEBLOCK #define IDirect3DStateBlock9_Apply(p) (p)->Apply() #endif - - #undef INTERFACE #define INTERFACE IDirect3DSwapChain9 @@ -766,8 +733,6 @@ typedef struct IDirect3DSwapChain9 *LPDIRECT3DSWAPCHAIN9, *PDIRECT3DSWAPCHAIN9; #define IDirect3DSwapChain9_GetPresentParameters(p,a) (p)->GetPresentParameters(a) #endif - - #undef INTERFACE #define INTERFACE IDirect3DResource9 @@ -817,8 +782,6 @@ typedef struct IDirect3DResource9 *LPDIRECT3DRESOURCE9, *PDIRECT3DRESOURCE9; #define IDirect3DResource9_GetType(p) (p)->GetType() #endif - - #undef INTERFACE #define INTERFACE IDirect3DVertexDeclaration9 @@ -850,8 +813,6 @@ typedef struct IDirect3DVertexDeclaration9 *LPDIRECT3DVERTEXDECLARATION9, *PDIRE #define IDirect3DVertexDeclaration9_GetDeclaration(p,a,b) (p)->GetDeclaration(a,b) #endif - - #undef INTERFACE #define INTERFACE IDirect3DVertexShader9 @@ -883,8 +844,6 @@ typedef struct IDirect3DVertexShader9 *LPDIRECT3DVERTEXSHADER9, *PDIRECT3DVERTEX #define IDirect3DVertexShader9_GetFunction(p,a,b) (p)->GetFunction(a,b) #endif - - #undef INTERFACE #define INTERFACE IDirect3DPixelShader9 @@ -916,9 +875,6 @@ typedef struct IDirect3DPixelShader9 *LPDIRECT3DPIXELSHADER9, *PDIRECT3DPIXELSHA #define IDirect3DPixelShader9_GetFunction(p,a,b) (p)->GetFunction(a,b) #endif - - - #undef INTERFACE #define INTERFACE IDirect3DBaseTexture9 @@ -986,10 +942,6 @@ typedef struct IDirect3DBaseTexture9 *LPDIRECT3DBASETEXTURE9, *PDIRECT3DBASETEXT #define IDirect3DBaseTexture9_GenerateMipSubLevels(p) (p)->GenerateMipSubLevels() #endif - - - - #undef INTERFACE #define INTERFACE IDirect3DTexture9 @@ -1072,10 +1024,6 @@ typedef struct IDirect3DTexture9 *LPDIRECT3DTEXTURE9, *PDIRECT3DTEXTURE9; #define IDirect3DTexture9_AddDirtyRect(p,a) (p)->AddDirtyRect(a) #endif - - - - #undef INTERFACE #define INTERFACE IDirect3DVolumeTexture9 @@ -1158,10 +1106,6 @@ typedef struct IDirect3DVolumeTexture9 *LPDIRECT3DVOLUMETEXTURE9, *PDIRECT3DVOLU #define IDirect3DVolumeTexture9_AddDirtyBox(p,a) (p)->AddDirtyBox(a) #endif - - - - #undef INTERFACE #define INTERFACE IDirect3DCubeTexture9 @@ -1244,9 +1188,6 @@ typedef struct IDirect3DCubeTexture9 *LPDIRECT3DCUBETEXTURE9, *PDIRECT3DCUBETEXT #define IDirect3DCubeTexture9_AddDirtyRect(p,a,b) (p)->AddDirtyRect(a,b) #endif - - - #undef INTERFACE #define INTERFACE IDirect3DVertexBuffer9 @@ -1305,9 +1246,6 @@ typedef struct IDirect3DVertexBuffer9 *LPDIRECT3DVERTEXBUFFER9, *PDIRECT3DVERTEX #define IDirect3DVertexBuffer9_GetDesc(p,a) (p)->GetDesc(a) #endif - - - #undef INTERFACE #define INTERFACE IDirect3DIndexBuffer9 @@ -1366,9 +1304,6 @@ typedef struct IDirect3DIndexBuffer9 *LPDIRECT3DINDEXBUFFER9, *PDIRECT3DINDEXBUF #define IDirect3DIndexBuffer9_GetDesc(p,a) (p)->GetDesc(a) #endif - - - #undef INTERFACE #define INTERFACE IDirect3DSurface9 @@ -1436,9 +1371,6 @@ typedef struct IDirect3DSurface9 *LPDIRECT3DSURFACE9, *PDIRECT3DSURFACE9; #define IDirect3DSurface9_ReleaseDC(p,a) (p)->ReleaseDC(a) #endif - - - #undef INTERFACE #define INTERFACE IDirect3DVolume9 @@ -1488,8 +1420,6 @@ typedef struct IDirect3DVolume9 *LPDIRECT3DVOLUME9, *PDIRECT3DVOLUME9; #define IDirect3DVolume9_UnlockBox(p) (p)->UnlockBox() #endif - - #undef INTERFACE #define INTERFACE IDirect3DQuery9 @@ -1530,7 +1460,6 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define IDirect3DQuery9_GetData(p,a,b,c) (p)->GetData(a,b,c) #endif - /**************************************************************************** * Flags for SetPrivateData method on all D3D9 interfaces * @@ -1559,7 +1488,6 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define D3DCREATE_DISABLE_DRIVER_MANAGEMENT 0x00000100L #define D3DCREATE_ADAPTERGROUP_DEVICE 0x00000200L - /**************************************************************************** * * Parameter for IDirect3D9::CreateDevice's iAdapter @@ -1617,7 +1545,6 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; * Also valid for VertexBuffer::CreateVertexBuffer ****************************************************************************/ - /* * DirectDraw error codes */ @@ -1655,7 +1582,6 @@ typedef struct IDirect3DQuery9 *LPDIRECT3DQUERY9, *PDIRECT3DQUERY9; #define D3DERR_WASSTILLDRAWING MAKE_D3DHRESULT(540) #define D3DOK_NOAUTOGEN MAKE_D3DSTATUS(2159) - #ifdef __cplusplus }; #endif diff --git a/gfx/include/d3d9/d3dx9.h b/gfx/include/d3d9/d3dx9.h index 514020f549..d11faeccee 100644 --- a/gfx/include/d3d9/d3dx9.h +++ b/gfx/include/d3d9/d3dx9.h @@ -68,5 +68,4 @@ enum _D3DXERR { D3DXERR_CANNOTREMOVELASTITEM = MAKE_DDHRESULT(2908) }; - #endif /*__D3DX9_H__ */ diff --git a/gfx/include/d3d9/d3dx9anim.h b/gfx/include/d3d9/d3dx9anim.h index 653f762fcb..afa7391d3b 100644 --- a/gfx/include/d3d9/d3dx9anim.h +++ b/gfx/include/d3d9/d3dx9anim.h @@ -320,7 +320,6 @@ DECLARE_INTERFACE_(ID3DXKeyframedAnimationSet, ID3DXAnimationSet) STDMETHOD(UnregisterAnimation)(THIS_ UINT Index) PURE; }; - /* * ID3DXCompressedAnimationSet: * ---------------------------- @@ -677,7 +676,6 @@ D3DXFrameCalculateBoundingSphere FLOAT *pObjectRadius ); - /* * D3DXCreateKeyframedAnimationSet: * -------------------------------- @@ -713,7 +711,6 @@ D3DXCreateKeyframedAnimationSet LPD3DXKEYFRAMEDANIMATIONSET *ppAnimationSet ); - /* * D3DXCreateCompressedAnimationSet: * -------------------------------- @@ -760,7 +757,6 @@ D3DXCreateAnimationController LPD3DXANIMATIONCONTROLLER *ppAnimController ); - #ifdef __cplusplus } #endif /*__cplusplus */ diff --git a/gfx/include/d3d9/d3dx9core.h b/gfx/include/d3d9/d3dx9core.h index 92ac586356..60596f6a08 100644 --- a/gfx/include/d3d9/d3dx9core.h +++ b/gfx/include/d3d9/d3dx9core.h @@ -68,12 +68,10 @@ DECLARE_INTERFACE_(ID3DXBuffer, IUnknown) typedef interface ID3DXSprite ID3DXSprite; typedef interface ID3DXSprite *LPD3DXSPRITE; - /* {BA0B762D-7D28-43ec-B9DC-2F84443B0614} */ DEFINE_GUID(IID_ID3DXSprite, 0xba0b762d, 0x7d28, 0x43ec, 0xb9, 0xdc, 0x2f, 0x84, 0x44, 0x3b, 0x6, 0x14); - #undef INTERFACE #define INTERFACE ID3DXSprite @@ -102,7 +100,6 @@ DECLARE_INTERFACE_(ID3DXSprite, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -154,7 +151,6 @@ typedef D3DXFONT_DESCA D3DXFONT_DESC; typedef LPD3DXFONT_DESCA LPD3DXFONT_DESC; #endif - typedef interface ID3DXFont ID3DXFont; typedef interface ID3DXFont *LPD3DXFONT; @@ -162,7 +158,6 @@ typedef interface ID3DXFont *LPD3DXFONT; DEFINE_GUID(IID_ID3DXFont, 0xd79dbb70, 0x5f21, 0x4d36, 0xbb, 0xc2, 0xff, 0x52, 0x5c, 0x21, 0x3c, 0xdc); - #undef INTERFACE #define INTERFACE ID3DXFont @@ -221,12 +216,10 @@ DECLARE_INTERFACE_(ID3DXFont, IUnknown) #endif #endif - #ifdef __cplusplus extern "C" { #endif /*__cplusplus */ - HRESULT WINAPI D3DXCreateFontA( LPDIRECT3DDEVICE9 pDevice, @@ -263,7 +256,6 @@ HRESULT WINAPI #define D3DXCreateFont D3DXCreateFontA #endif - HRESULT WINAPI D3DXCreateFontIndirectA( LPDIRECT3DDEVICE9 pDevice, @@ -282,7 +274,6 @@ HRESULT WINAPI #define D3DXCreateFontIndirect D3DXCreateFontIndirectA #endif - #ifdef __cplusplus } #endif /*__cplusplus */ @@ -297,7 +288,6 @@ typedef struct _D3DXRTS_DESC } D3DXRTS_DESC, *LPD3DXRTS_DESC; - typedef interface ID3DXRenderToSurface ID3DXRenderToSurface; typedef interface ID3DXRenderToSurface *LPD3DXRENDERTOSURFACE; @@ -305,7 +295,6 @@ typedef interface ID3DXRenderToSurface *LPD3DXRENDERTOSURFACE; DEFINE_GUID(IID_ID3DXRenderToSurface, 0x6985f346, 0x2c3d, 0x43b3, 0xbe, 0x8b, 0xda, 0xae, 0x8a, 0x3, 0xd8, 0x94); - #undef INTERFACE #define INTERFACE ID3DXRenderToSurface @@ -327,7 +316,6 @@ DECLARE_INTERFACE_(ID3DXRenderToSurface, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -356,7 +344,6 @@ typedef struct _D3DXRTE_DESC } D3DXRTE_DESC, *LPD3DXRTE_DESC; - typedef interface ID3DXRenderToEnvMap ID3DXRenderToEnvMap; typedef interface ID3DXRenderToEnvMap *LPD3DXRenderToEnvMap; @@ -364,7 +351,6 @@ typedef interface ID3DXRenderToEnvMap *LPD3DXRenderToEnvMap; DEFINE_GUID(IID_ID3DXRenderToEnvMap, 0x313f1b4b, 0xc7b0, 0x4fa2, 0x9d, 0x9d, 0x8d, 0x38, 0xb, 0x64, 0x38, 0x5e); - #undef INTERFACE #define INTERFACE ID3DXRenderToEnvMap @@ -400,7 +386,6 @@ DECLARE_INTERFACE_(ID3DXRenderToEnvMap, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /*__cplusplus */ @@ -469,12 +454,10 @@ DECLARE_INTERFACE_(ID3DXLine, IUnknown) STDMETHOD(OnResetDevice)(THIS) PURE; }; - #ifdef __cplusplus extern "C" { #endif /*__cplusplus */ - HRESULT WINAPI D3DXCreateLine( LPDIRECT3DDEVICE9 pDevice, diff --git a/gfx/include/d3d9/d3dx9effect.h b/gfx/include/d3d9/d3dx9effect.h index 0d68aa8637..2d14ebdd61 100644 --- a/gfx/include/d3d9/d3dx9effect.h +++ b/gfx/include/d3d9/d3dx9effect.h @@ -37,7 +37,6 @@ typedef struct _D3DXEFFECT_DESC } D3DXEFFECT_DESC; - /* * D3DXPARAMETER_DESC: */ @@ -58,7 +57,6 @@ typedef struct _D3DXPARAMETER_DESC } D3DXPARAMETER_DESC; - /* * D3DXTECHNIQUE_DESC: */ @@ -71,7 +69,6 @@ typedef struct _D3DXTECHNIQUE_DESC } D3DXTECHNIQUE_DESC; - /* * D3DXPASS_DESC: */ @@ -86,7 +83,6 @@ typedef struct _D3DXPASS_DESC } D3DXPASS_DESC; - /* * D3DXFUNCTION_DESC: */ @@ -98,7 +94,6 @@ typedef struct _D3DXFUNCTION_DESC } D3DXFUNCTION_DESC; - /* * ID3DXEffectPool */ @@ -110,7 +105,6 @@ typedef interface ID3DXEffectPool *LPD3DXEFFECTPOOL; DEFINE_GUID(IID_ID3DXEffectPool, 0x9537ab04, 0x3250, 0x412e, 0x82, 0x13, 0xfc, 0xd2, 0xf8, 0x67, 0x79, 0x33); - #undef INTERFACE #define INTERFACE ID3DXEffectPool @@ -124,7 +118,6 @@ DECLARE_INTERFACE_(ID3DXEffectPool, IUnknown) /* No public methods */ }; - /* * ID3DXBaseEffect */ @@ -136,7 +129,6 @@ typedef interface ID3DXBaseEffect *LPD3DXBASEEFFECT; DEFINE_GUID(IID_ID3DXBaseEffect, 0x17c18ac, 0x103f, 0x4417, 0x8c, 0x51, 0x6b, 0xf6, 0xef, 0x1e, 0x56, 0xbe); - #undef INTERFACE #define INTERFACE ID3DXBaseEffect @@ -268,7 +260,6 @@ DECLARE_INTERFACE_(ID3DXEffectStateManager, IUnknown) STDMETHOD(SetPixelShaderConstantB)(THIS_ UINT RegisterIndex, CONST BOOL *pConstantData, UINT RegisterCount) PURE; }; - /* * ID3DXEffect */ @@ -411,7 +402,6 @@ typedef interface ID3DXEffectCompiler *LPD3DXEFFECTCOMPILER; DEFINE_GUID(IID_ID3DXEffectCompiler, 0x51b8a949, 0x1a31, 0x47e6, 0xbe, 0xa0, 0x4b, 0x30, 0xdb, 0x53, 0xf1, 0xe0); - #undef INTERFACE #define INTERFACE ID3DXEffectCompiler @@ -498,7 +488,6 @@ DECLARE_INTERFACE_(ID3DXEffectCompiler, ID3DXBaseEffect) LPD3DXBUFFER* ppShader, LPD3DXBUFFER* ppErrorMsgs, LPD3DXCONSTANTTABLE* ppConstantTable) PURE; }; - /* * APIs */ @@ -539,7 +528,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromFile D3DXCreateEffectFromFileA #endif - HRESULT WINAPI D3DXCreateEffectFromResourceA( LPDIRECT3DDEVICE9 pDevice, @@ -570,7 +558,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromResource D3DXCreateEffectFromResourceA #endif - HRESULT WINAPI D3DXCreateEffect( LPDIRECT3DDEVICE9 pDevice, @@ -613,7 +600,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromFileEx D3DXCreateEffectFromFileExA #endif - HRESULT WINAPI D3DXCreateEffectFromResourceExA( LPDIRECT3DDEVICE9 pDevice, @@ -646,7 +632,6 @@ HRESULT WINAPI #define D3DXCreateEffectFromResourceEx D3DXCreateEffectFromResourceExA #endif - HRESULT WINAPI D3DXCreateEffectEx( LPDIRECT3DDEVICE9 pDevice, @@ -684,7 +669,6 @@ HRESULT WINAPI #define D3DXCreateEffectCompilerFromFile D3DXCreateEffectCompilerFromFileA #endif - HRESULT WINAPI D3DXCreateEffectCompilerFromResourceA( HMODULE hSrcModule, @@ -711,7 +695,6 @@ HRESULT WINAPI #define D3DXCreateEffectCompilerFromResource D3DXCreateEffectCompilerFromResourceA #endif - HRESULT WINAPI D3DXCreateEffectCompiler( LPCSTR pSrcData, diff --git a/gfx/include/d3d9/d3dx9math.h b/gfx/include/d3d9/d3dx9math.h index 914d9536f0..06ed776127 100644 --- a/gfx/include/d3d9/d3dx9math.h +++ b/gfx/include/d3d9/d3dx9math.h @@ -44,7 +44,6 @@ #define D3DX_16F_RADIX 2 /* exponent radix */ #define D3DX_16F_ROUNDS 1 /* addition rounding: near */ - typedef struct D3DXFLOAT16 { #ifdef __cplusplus @@ -65,8 +64,6 @@ protected: WORD value; } D3DXFLOAT16, *LPD3DXFLOAT16; - - /*=========================================================================== * * Vectors @@ -74,7 +71,6 @@ protected: *=========================================================================== */ - /* * 2D Vector */ @@ -112,7 +108,6 @@ public: BOOL operator == ( CONST D3DXVECTOR2& ) const; BOOL operator != ( CONST D3DXVECTOR2& ) const; - public: #endif /*__cplusplus */ FLOAT x, y; @@ -263,7 +258,6 @@ public: FLOAT x, y, z, w; } D3DXVECTOR4, *LPD3DXVECTOR4; - /*-------------------------- * 4D Vector (16 bit) *-------------------------- @@ -311,7 +305,6 @@ public: FLOAT _31, FLOAT _32, FLOAT _33, FLOAT _34, FLOAT _41, FLOAT _42, FLOAT _43, FLOAT _44 ); - /* access grants */ FLOAT& operator () ( UINT Row, UINT Col ); FLOAT operator () ( UINT Row, UINT Col ) const; @@ -349,7 +342,6 @@ public: typedef struct _D3DMATRIX D3DXMATRIX, *LPD3DXMATRIX; #endif /* !__cplusplus */ - /*--------------------------------------------------------------------------- * Aligned Matrices * @@ -487,7 +479,6 @@ public: FLOAT a, b, c, d; } D3DXPLANE, *LPD3DXPLANE; - /* * * Colors @@ -663,8 +654,6 @@ D3DXVECTOR2* WINAPI D3DXVec2TransformCoordArray D3DXVECTOR2* WINAPI D3DXVec2TransformNormalArray ( D3DXVECTOR2 *pOut, UINT OutStride, CONST D3DXVECTOR2 *pV, UINT VStride, CONST D3DXMATRIX *pM, UINT n ); - - #ifdef __cplusplus } #endif @@ -748,7 +737,6 @@ D3DXVECTOR3* WINAPI D3DXVec3TransformCoord D3DXVECTOR3* WINAPI D3DXVec3TransformNormal ( D3DXVECTOR3 *pOut, CONST D3DXVECTOR3 *pV, CONST D3DXMATRIX *pM ); - /* Transform Array (x, y, z, 1) by matrix. */ D3DXVECTOR4* WINAPI D3DXVec3TransformArray ( D3DXVECTOR4 *pOut, UINT OutStride, CONST D3DXVECTOR3 *pV, UINT VStride, CONST D3DXMATRIX *pM, UINT n ); @@ -784,7 +772,6 @@ D3DXVECTOR3* WINAPI D3DXVec3UnprojectArray ( D3DXVECTOR3 *pOut, UINT OutStride, CONST D3DXVECTOR3 *pV, UINT VStride, CONST D3DVIEWPORT9 *pViewport, CONST D3DXMATRIX *pProjection, CONST D3DXMATRIX *pView, CONST D3DXMATRIX *pWorld, UINT n); - #ifdef __cplusplus } #endif @@ -867,7 +854,6 @@ D3DXVECTOR4* WINAPI D3DXVec4TransformArray } #endif - /* * 4D Matrix */ @@ -880,7 +866,6 @@ D3DXMATRIX* D3DXMatrixIdentity BOOL D3DXMatrixIsIdentity ( CONST D3DXMATRIX *pM ); - /* non-inline */ #ifdef __cplusplus extern "C" { @@ -1144,7 +1129,6 @@ D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric } #endif - /* * Plane */ @@ -1278,7 +1262,6 @@ typedef interface ID3DXMatrixStack *LPD3DXMATRIXSTACK; DEFINE_GUID(IID_ID3DXMatrixStack, 0xc7885ba7, 0xf990, 0x4fe7, 0x92, 0x2d, 0x85, 0x15, 0xe4, 0x77, 0xdd, 0x85); - #undef INTERFACE #define INTERFACE ID3DXMatrixStack @@ -1478,7 +1461,6 @@ HRESULT WINAPI D3DXSHProjectCubeMap ( UINT uOrder, LPDIRECT3DCUBETEXTURE9 pCubeMap, FLOAT *pROut, FLOAT *pGOut, FLOAT *pBOut ); - #ifdef __cplusplus } #endif diff --git a/gfx/include/d3d9/d3dx9mesh.h b/gfx/include/d3d9/d3dx9mesh.h index 3d15c50542..6a43483607 100644 --- a/gfx/include/d3d9/d3dx9mesh.h +++ b/gfx/include/d3d9/d3dx9mesh.h @@ -151,7 +151,6 @@ typedef struct ID3DXPatchMesh *LPD3DXPATCHMESH; typedef interface ID3DXTextureGutterHelper *LPD3DXTEXTUREGUTTERHELPER; typedef interface ID3DXPRTBuffer *LPD3DXPRTBUFFER; - typedef struct _D3DXATTRIBUTERANGE { DWORD AttribId; @@ -244,7 +243,6 @@ typedef struct _D3DXWELDEPSILONS typedef D3DXWELDEPSILONS* LPD3DXWELDEPSILONS; - #undef INTERFACE #define INTERFACE ID3DXBaseMesh @@ -284,7 +282,6 @@ DECLARE_INTERFACE_(ID3DXBaseMesh, IUnknown) STDMETHOD(UpdateSemantics)(THIS_ D3DVERTEXELEMENT9 Declaration[MAX_FVF_DECL_SIZE]) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXMesh @@ -334,7 +331,6 @@ DECLARE_INTERFACE_(ID3DXMesh, ID3DXBaseMesh) STDMETHOD(SetAttributeTable)(THIS_ CONST D3DXATTRIBUTERANGE *pAttribTable, DWORD cAttribTableSize) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXPMesh @@ -401,7 +397,6 @@ DECLARE_INTERFACE_(ID3DXPMesh, ID3DXBaseMesh) STDMETHOD(GenerateVertexHistory)(THIS_ DWORD* pVertexHistory) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXSPMesh @@ -753,7 +748,6 @@ HRESULT WINAPI DWORD NumBytes, LPD3DXBUFFER *ppBuffer); - HRESULT WINAPI D3DXLoadMeshFromXA( LPCSTR pFilename, @@ -835,7 +829,6 @@ HRESULT WINAPI #define D3DXSaveMeshToX D3DXSaveMeshToXA #endif - HRESULT WINAPI D3DXCreatePMeshFromStream( IStream *pStream, @@ -895,7 +888,6 @@ HRESULT WINAPI LPD3DXSKININFO* ppSkinInfo, LPD3DXMESH* ppMesh); - /* The inverse of D3DXConvertTo{Indexed}BlendedMesh() functions. It figures out the skinning info from * the mesh and the bone combination table and populates a skin info object with that data. The bone * names and initial bone transforms are not filled in the skin info object by this method. This works @@ -918,7 +910,6 @@ HRESULT WINAPI LPD3DXMESH *ppMeshOut, LPD3DXBUFFER *ppAdjacencyOut); - /* generates implied outputdecl from input decl * the decl generated from this should be used to generate the output decl for * the tessellator subroutines. @@ -958,7 +949,6 @@ HRESULT WINAPI DWORD *pdwTriangles, /* output number of triangles */ DWORD *pdwVertices); /* output number of vertices */ - /*tessellates a patch into a created mesh *similar to D3D RT patch */ HRESULT WINAPI @@ -969,7 +959,6 @@ HRESULT WINAPI CONST D3DRECTPATCH_INFO *pRectPatchInfo, LPD3DXMESH pMesh); - HRESULT WINAPI D3DXTessellateTriPatch( LPDIRECT3DVERTEXBUFFER9 pVB, @@ -995,7 +984,6 @@ HRESULT WINAPI LPDIRECT3DDEVICE9 pD3DDevice, LPD3DXPATCHMESH *pPatchMesh); - /*returns the number of degenerates in a patch mesh - *text output put in string. */ HRESULT WINAPI @@ -1041,7 +1029,6 @@ typedef struct _D3DXINTERSECTINFO FLOAT Dist; /* Ray-Intersection Parameter Distance */ } D3DXINTERSECTINFO, *LPD3DXINTERSECTINFO; - HRESULT WINAPI D3DXIntersect( LPD3DXBASEMESH pMesh, @@ -1069,7 +1056,6 @@ HRESULT WINAPI LPD3DXBUFFER *ppAllHits, /* Array of D3DXINTERSECTINFOs for all hits (not just closest) */ DWORD *pCountOfHits); /* Number of entries in AllHits array */ - HRESULT WINAPI D3DXSplitMesh ( LPD3DXMESH pMeshIn, @@ -1108,7 +1094,6 @@ BOOL WINAPI CONST D3DXVECTOR3 *pRayPosition, CONST D3DXVECTOR3 *pRayDirection); - HRESULT WINAPI D3DXComputeTangentFrame(ID3DXMesh *pMesh, DWORD dwOptions); @@ -1129,7 +1114,6 @@ HRESULT WINAPI D3DXComputeTangentFrameEx(ID3DXMesh *pMesh, ID3DXMesh **ppMeshOut, ID3DXBuffer **ppVertexMapping); - /*D3DXComputeTangent * *Computes the Tangent vectors for the TexStage texture coordinates @@ -1325,7 +1309,6 @@ HRESULT WINAPI D3DXUVAtlasPack(ID3DXMesh *pMesh, DWORD dwOptions, LPD3DXBUFFER pFacePartitioning); - /* * * IMT Calculation apis @@ -1480,7 +1463,6 @@ HRESULT WINAPI LPD3DXBUFFER *ppStripLengths, DWORD *pNumStrips); - /* * * D3DXOptimizeFaces: @@ -1547,7 +1529,6 @@ HRESULT WINAPI } #endif /* __cplusplus */ - /* * * Data structures for Spherical Harmonic Precomputation @@ -1773,7 +1754,6 @@ DECLARE_INTERFACE_(ID3DXPRTCompBuffer, IUnknown) LPD3DXMESH pScene) PURE; }; - #undef INTERFACE #define INTERFACE ID3DXTextureGutterHelper @@ -1809,7 +1789,6 @@ DECLARE_INTERFACE_(ID3DXTextureGutterHelper, IUnknown) STDMETHOD_(UINT, GetWidth)(THIS) PURE; STDMETHOD_(UINT, GetHeight)(THIS) PURE; - /* Applying gutters recomputes all of the gutter texels of class "2" * based on texels of class "1" or "4" */ @@ -1911,7 +1890,6 @@ DECLARE_INTERFACE_(ID3DXTextureGutterHelper, IUnknown) STDMETHOD(SetGutterMap)(THIS_ BYTE *pGutterData) PURE; }; - typedef interface ID3DXPRTEngine ID3DXPRTEngine; typedef interface ID3DXPRTEngine *LPD3DXPRTENGINE; @@ -2124,7 +2102,6 @@ DECLARE_INTERFACE_(ID3DXPRTEngine, IUnknown) FLOAT ZAngleBias, LPD3DXPRTBUFFER pDataOut) PURE; - /* Functions that computes subsurface scattering (using material properties) * Albedo is not multiplied by result. This only works for per-vertex data * use ResampleBuffer to move per-vertex data into a texture and back. @@ -2255,7 +2232,6 @@ DECLARE_INTERFACE_(ID3DXPRTEngine, IUnknown) CONST D3DXVECTOR3 *pSampleNorms, LPD3DXPRTBUFFER pDataOut) PURE; - /* given the solution for PRT or light maps, computes transfer vector at arbitrary * position/normal pairs in space * @@ -2361,7 +2337,6 @@ DECLARE_INTERFACE_(ID3DXPRTEngine, IUnknown) DWORD *pFaceIndex, FLOAT *pU, FLOAT *pV, FLOAT *pDist) PURE; }; - /* API functions for creating interfaces */ #ifdef __cplusplus @@ -2455,7 +2430,6 @@ HRESULT WINAPI #define D3DXLoadPRTBufferFromFile D3DXLoadPRTBufferFromFileA #endif - /* * * D3DXSavePRTBufferToFile: @@ -2486,7 +2460,6 @@ HRESULT WINAPI #define D3DXSavePRTBufferToFile D3DXSavePRTBufferToFileA #endif - /* * * D3DXLoadPRTCompBufferFromFile: @@ -2572,7 +2545,6 @@ HRESULT WINAPI * */ - HRESULT WINAPI D3DXCreatePRTCompBuffer( D3DXSHCOMPRESSQUALITYTYPE Quality, @@ -2607,7 +2579,6 @@ HRESULT WINAPI * */ - HRESULT WINAPI D3DXCreateTextureGutterHelper( UINT Width, @@ -2616,7 +2587,6 @@ HRESULT WINAPI FLOAT GutterSize, LPD3DXTEXTUREGUTTERHELPER* ppBuffer); - /* * * D3DXCreatePRTEngine: @@ -2640,7 +2610,6 @@ HRESULT WINAPI * */ - HRESULT WINAPI D3DXCreatePRTEngine( LPD3DXMESH pMesh, @@ -2682,7 +2651,6 @@ HRESULT WINAPI * */ - HRESULT WINAPI D3DXConcatenateMeshes( LPD3DXMESH *ppMeshes, @@ -2803,7 +2771,6 @@ HRESULT WINAPI UINT *pSCClusterList, D3DXSHPRTSPLITMESHCLUSTERDATA *pSCData); - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/gfx/include/d3d9/d3dx9shader.h b/gfx/include/d3d9/d3dx9shader.h index a700b5244f..d972c9a075 100644 --- a/gfx/include/d3d9/d3dx9shader.h +++ b/gfx/include/d3d9/d3dx9shader.h @@ -55,7 +55,6 @@ typedef struct _D3DXMACRO } D3DXMACRO, *LPD3DXMACRO; - /* * D3DXSEMANTIC: */ @@ -67,8 +66,6 @@ typedef struct _D3DXSEMANTIC } D3DXSEMANTIC, *LPD3DXSEMANTIC; - - /* * D3DXREGISTER_SET: */ @@ -85,7 +82,6 @@ typedef enum _D3DXREGISTER_SET } D3DXREGISTER_SET, *LPD3DXREGISTER_SET; - /* * D3DXPARAMETER_CLASS: */ @@ -104,7 +100,6 @@ typedef enum _D3DXPARAMETER_CLASS } D3DXPARAMETER_CLASS, *LPD3DXPARAMETER_CLASS; - /* * D3DXPARAMETER_TYPE: */ @@ -137,7 +132,6 @@ typedef enum _D3DXPARAMETER_TYPE } D3DXPARAMETER_TYPE, *LPD3DXPARAMETER_TYPE; - /* * D3DXCONSTANTTABLE_DESC: */ @@ -150,7 +144,6 @@ typedef struct _D3DXCONSTANTTABLE_DESC } D3DXCONSTANTTABLE_DESC, *LPD3DXCONSTANTTABLE_DESC; - /* * D3DXCONSTANT_DESC: */ @@ -176,8 +169,6 @@ typedef struct _D3DXCONSTANT_DESC } D3DXCONSTANT_DESC, *LPD3DXCONSTANT_DESC; - - /* * ID3DXConstantTable: */ @@ -189,7 +180,6 @@ typedef interface ID3DXConstantTable *LPD3DXCONSTANTTABLE; DEFINE_GUID(IID_ID3DXConstantTable, 0xab3c758f, 0x93e, 0x4356, 0xb7, 0x62, 0x4d, 0xb1, 0x8f, 0x1b, 0x3a, 0x1); - #undef INTERFACE #define INTERFACE ID3DXConstantTable @@ -308,7 +298,6 @@ DECLARE_INTERFACE(ID3DXInclude) STDMETHOD(Close)(THIS_ LPCVOID pData) PURE; }; - /* * APIs */ @@ -341,7 +330,6 @@ HRESULT WINAPI #define D3DXAssembleShaderFromFile D3DXAssembleShaderFromFileA #endif - HRESULT WINAPI D3DXAssembleShaderFromResourceA( HMODULE hSrcModule, @@ -368,7 +356,6 @@ HRESULT WINAPI #define D3DXAssembleShaderFromResource D3DXAssembleShaderFromResourceA #endif - HRESULT WINAPI D3DXAssembleShader( LPCSTR pSrcData, @@ -409,7 +396,6 @@ HRESULT WINAPI #define D3DXCompileShaderFromFile D3DXCompileShaderFromFileA #endif - HRESULT WINAPI D3DXCompileShaderFromResourceA( HMODULE hSrcModule, @@ -442,7 +428,6 @@ HRESULT WINAPI #define D3DXCompileShaderFromResource D3DXCompileShaderFromResourceA #endif - HRESULT WINAPI D3DXCompileShader( LPCSTR pSrcData, @@ -575,12 +560,10 @@ HRESULT WINAPI LPD3DXBUFFER* ppShaderText, LPD3DXBUFFER* ppErrorMsgs); - #ifdef __cplusplus } #endif - /* * Shader comment block layouts */ @@ -605,7 +588,6 @@ typedef struct _D3DXSHADER_CONSTANTTABLE } D3DXSHADER_CONSTANTTABLE, *LPD3DXSHADER_CONSTANTTABLE; - typedef struct _D3DXSHADER_CONSTANTINFO { DWORD Name; /* LPCSTR offset */ @@ -618,7 +600,6 @@ typedef struct _D3DXSHADER_CONSTANTINFO } D3DXSHADER_CONSTANTINFO, *LPD3DXSHADER_CONSTANTINFO; - typedef struct _D3DXSHADER_TYPEINFO { WORD Class; /* D3DXPARAMETER_CLASS */ @@ -631,7 +612,6 @@ typedef struct _D3DXSHADER_TYPEINFO } D3DXSHADER_TYPEINFO, *LPD3DXSHADER_TYPEINFO; - typedef struct _D3DXSHADER_STRUCTMEMBERINFO { DWORD Name; /* LPCSTR offset */ @@ -639,6 +619,4 @@ typedef struct _D3DXSHADER_STRUCTMEMBERINFO } D3DXSHADER_STRUCTMEMBERINFO, *LPD3DXSHADER_STRUCTMEMBERINFO; - - #endif /* __D3DX9SHADER_H__ */ diff --git a/gfx/include/d3d9/d3dx9tex.h b/gfx/include/d3d9/d3dx9tex.h index f34574d25f..757f4f65c3 100644 --- a/gfx/include/d3d9/d3dx9tex.h +++ b/gfx/include/d3d9/d3dx9tex.h @@ -99,7 +99,6 @@ HRESULT WINAPI #define D3DXGetImageInfoFromFile D3DXGetImageInfoFromFileA #endif - HRESULT WINAPI D3DXGetImageInfoFromResourceA( HMODULE hSrcModule, @@ -118,7 +117,6 @@ HRESULT WINAPI #define D3DXGetImageInfoFromResource D3DXGetImageInfoFromResourceA #endif - HRESULT WINAPI D3DXGetImageInfoFromFileInMemory( LPCVOID pSrcData, @@ -153,8 +151,6 @@ HRESULT WINAPI #define D3DXLoadSurfaceFromFile D3DXLoadSurfaceFromFileA #endif - - HRESULT WINAPI D3DXLoadSurfaceFromResourceA( LPDIRECT3DSURFACE9 pDestSurface, @@ -179,15 +175,12 @@ HRESULT WINAPI D3DCOLOR ColorKey, D3DXIMAGE_INFO* pSrcInfo); - #ifdef UNICODE #define D3DXLoadSurfaceFromResource D3DXLoadSurfaceFromResourceW #else #define D3DXLoadSurfaceFromResource D3DXLoadSurfaceFromResourceA #endif - - HRESULT WINAPI D3DXLoadSurfaceFromFileInMemory( LPDIRECT3DSURFACE9 pDestSurface, @@ -200,7 +193,6 @@ HRESULT WINAPI D3DCOLOR ColorKey, D3DXIMAGE_INFO* pSrcInfo); - HRESULT WINAPI D3DXLoadSurfaceFromSurface( LPDIRECT3DSURFACE9 pDestSurface, @@ -255,7 +247,6 @@ HRESULT WINAPI CONST PALETTEENTRY* pSrcPalette, CONST RECT* pSrcRect); - /* * Load/Save Volume APIs */ @@ -288,7 +279,6 @@ HRESULT WINAPI #define D3DXLoadVolumeFromFile D3DXLoadVolumeFromFileA #endif - HRESULT WINAPI D3DXLoadVolumeFromResourceA( LPDIRECT3DVOLUME9 pDestVolume, @@ -319,8 +309,6 @@ HRESULT WINAPI #define D3DXLoadVolumeFromResource D3DXLoadVolumeFromResourceA #endif - - HRESULT WINAPI D3DXLoadVolumeFromFileInMemory( LPDIRECT3DVOLUME9 pDestVolume, @@ -333,7 +321,6 @@ HRESULT WINAPI D3DCOLOR ColorKey, D3DXIMAGE_INFO* pSrcInfo); - HRESULT WINAPI D3DXLoadVolumeFromVolume( LPDIRECT3DVOLUME9 pDestVolume, @@ -474,7 +461,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromFile D3DXCreateTextureFromFileA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromFileA( LPDIRECT3DDEVICE9 pDevice, @@ -493,7 +479,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromFile D3DXCreateCubeTextureFromFileA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromFileA( LPDIRECT3DDEVICE9 pDevice, @@ -532,7 +517,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromResource D3DXCreateTextureFromResourceA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromResourceA( LPDIRECT3DDEVICE9 pDevice, @@ -553,7 +537,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromResource D3DXCreateCubeTextureFromResourceA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromResourceA( LPDIRECT3DDEVICE9 pDevice, @@ -616,7 +599,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromFileEx D3DXCreateTextureFromFileExA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromFileExA( LPDIRECT3DDEVICE9 pDevice, @@ -655,7 +637,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromFileEx D3DXCreateCubeTextureFromFileExA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromFileExA( LPDIRECT3DDEVICE9 pDevice, @@ -742,7 +723,6 @@ HRESULT WINAPI #define D3DXCreateTextureFromResourceEx D3DXCreateTextureFromResourceExA #endif - HRESULT WINAPI D3DXCreateCubeTextureFromResourceExA( LPDIRECT3DDEVICE9 pDevice, @@ -783,7 +763,6 @@ HRESULT WINAPI #define D3DXCreateCubeTextureFromResourceEx D3DXCreateCubeTextureFromResourceExA #endif - HRESULT WINAPI D3DXCreateVolumeTextureFromResourceExA( LPDIRECT3DDEVICE9 pDevice, @@ -851,7 +830,6 @@ HRESULT WINAPI UINT SrcDataSize, LPDIRECT3DVOLUMETEXTURE9* ppVolumeTexture); - /* FromFileInMemoryEx */ HRESULT WINAPI @@ -935,9 +913,6 @@ HRESULT WINAPI LPDIRECT3DBASETEXTURE9 pSrcTexture, CONST PALETTEENTRY* pSrcPalette); - - - /* * Misc Texture APIs */ @@ -975,13 +950,11 @@ HRESULT WINAPI LPDIRECT3DTEXTURE9 pTexture, LPD3DXTEXTURESHADER pTextureShader); - HRESULT WINAPI D3DXFillCubeTextureTX( LPDIRECT3DCUBETEXTURE9 pCubeTexture, LPD3DXTEXTURESHADER pTextureShader); - HRESULT WINAPI D3DXFillVolumeTextureTX( LPDIRECT3DVOLUMETEXTURE9 pVolumeTexture, diff --git a/gfx/include/d3d9caps.h b/gfx/include/d3d9caps.h index cd89f29450..2821e3f152 100644 --- a/gfx/include/d3d9caps.h +++ b/gfx/include/d3d9caps.h @@ -17,8 +17,6 @@ /* include this file content only if compiling for DX9 interfaces */ #if(DIRECT3D_VERSION >= 0x0900) - - #if defined(_X86_) || defined(_IA64_) #pragma pack(4) #endif @@ -86,7 +84,6 @@ typedef struct _D3DOVERLAYCAPS #define D3DOVERLAYCAPS_STRETCHX 0x00000040 #define D3DOVERLAYCAPS_STRETCHY 0x00000080 - typedef struct _D3DCONTENTPROTECTIONCAPS { DWORD Caps; @@ -326,7 +323,6 @@ typedef struct _D3DCAPS9 #endif /* !D3D_DISABLE_9EX */ /* -- D3D9Ex only */ - /* * LineCaps */ @@ -554,9 +550,7 @@ typedef struct _D3DCAPS9 #define D3DDTCAPS_FLOAT16_2 0x00000100L #define D3DDTCAPS_FLOAT16_4 0x00000200L - #pragma pack() - #endif /* (DIRECT3D_VERSION >= 0x0900) */ #endif /* _d3d9CAPS_H_ */ diff --git a/gfx/include/d3d9types.h b/gfx/include/d3d9types.h index c1c5573baa..cb02742a5d 100644 --- a/gfx/include/d3d9types.h +++ b/gfx/include/d3d9types.h @@ -10,7 +10,6 @@ #ifndef _d3d9TYPES_H_ #define _d3d9TYPES_H_ - #ifndef DIRECT3D_VERSION #define DIRECT3D_VERSION 0x0900 #endif @@ -47,7 +46,6 @@ typedef DWORD D3DCOLOR; #define D3DCOLOR_COLORVALUE(r,g,b,a) \ D3DCOLOR_RGBA((DWORD)((r)*255.f),(DWORD)((g)*255.f),(DWORD)((b)*255.f),(DWORD)((a)*255.f)) - #ifndef D3DVECTOR_DEFINED typedef struct _D3DVECTOR { float x; @@ -77,8 +75,6 @@ typedef struct _D3DRECT { #define D3DRECT_DEFINED #endif - - #ifndef D3DMATRIX_DEFINED typedef struct _D3DMATRIX { union { @@ -95,8 +91,6 @@ typedef struct _D3DMATRIX { #define D3DMATRIX_DEFINED #endif - - typedef struct _D3DVIEWPORT9 { DWORD X; DWORD Y; /* Viewport Top left */ @@ -439,7 +433,6 @@ typedef enum _D3DRENDERSTATETYPE { D3DRS_DESTBLENDALPHA = 208, /* DST blend factor for the alpha channel when D3DRS_SEPARATEDESTALPHAENABLE is TRUE */ D3DRS_BLENDOPALPHA = 209, /* Blending operation for the alpha channel when D3DRS_SEPARATEDESTALPHAENABLE is TRUE */ - D3DRS_FORCE_DWORD = 0x7fffffff /* force 32-bit size enum */ } D3DRENDERSTATETYPE; @@ -500,7 +493,6 @@ typedef enum _D3DTEXTURESTAGESTATETYPE D3DTSS_RESULTARG = 28, /* D3DTA_* arg for result (CURRENT or TEMP) */ D3DTSS_CONSTANT = 32, /* Per-stage constant D3DTA_CONSTANT */ - D3DTSS_FORCE_DWORD = 0x7fffffff /* force 32-bit size enum */ } D3DTEXTURESTAGESTATETYPE; @@ -782,8 +774,6 @@ typedef struct _D3DVERTEXELEMENT9 #define D3DSTREAMSOURCE_INDEXEDDATA (1<<30) #define D3DSTREAMSOURCE_INSTANCEDATA (2<<30) - - /*--------------------------------------------------------------------- * * The internal format of Pixel Shader (PS) & Vertex Shader (VS) @@ -1203,7 +1193,6 @@ typedef enum _D3DSHADER_MIN_PRECISION #define D3DPS_END() 0x0000FFFF #define D3DVS_END() 0x0000FFFF - /*--------------------------------------------------------------------- */ /* High order surfaces */ @@ -1273,7 +1262,6 @@ typedef enum _D3DTEXTURETRANSFORMFLAGS { #define D3DFVF_TEXCOORDSIZE4(CoordIndex) (D3DFVF_TEXTUREFORMAT4 << (CoordIndex*2 + 16)) #define D3DFVF_TEXCOORDSIZE1(CoordIndex) (D3DFVF_TEXTUREFORMAT1 << (CoordIndex*2 + 16)) - /*--------------------------------------------------------------------- */ /* Direct3D9 Device types */ @@ -1351,7 +1339,6 @@ typedef enum _D3DMULTISAMPLE_TYPE ((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24 )) #endif /* defined(MAKEFOURCC) */ - typedef enum _D3DFORMAT { D3DFMT_UNKNOWN = 0, @@ -1419,7 +1406,6 @@ typedef enum _D3DFORMAT #endif /* !D3D_DISABLE_9EX */ /* -- D3D9Ex only */ - D3DFMT_L16 = 81, D3DFMT_VERTEXDATA =100, @@ -1453,14 +1439,12 @@ typedef enum _D3DFORMAT /* 2.8 biased fixed point */ D3DFMT_A2B10G10R10_XR_BIAS = 119, - /* Binary format indicating that the data has no inherent type */ D3DFMT_BINARYBUFFER = 199, #endif /* !D3D_DISABLE_9EX */ /* -- D3D9Ex only */ - D3DFMT_FORCE_DWORD =0x7fffffff } D3DFORMAT; @@ -1482,7 +1466,6 @@ typedef struct _D3DDEVICE_CREATION_PARAMETERS DWORD BehaviorFlags; } D3DDEVICE_CREATION_PARAMETERS; - /* SwapEffects */ typedef enum _D3DSWAPEFFECT { @@ -1510,11 +1493,9 @@ typedef enum _D3DPOOL { D3DPOOL_FORCE_DWORD = 0x7fffffff } D3DPOOL; - /* RefreshRate pre-defines */ #define D3DPRESENT_RATE_DEFAULT 0x00000000 - /* Resize Optional Parameters */ typedef struct _D3DPRESENT_PARAMETERS_ { @@ -1578,7 +1559,6 @@ typedef enum _D3DBACKBUFFER_TYPE D3DBACKBUFFER_TYPE_FORCE_DWORD = 0x7fffffff } D3DBACKBUFFER_TYPE; - /* Types */ typedef enum _D3DRESOURCETYPE { D3DRTYPE_SURFACE = 1, @@ -1589,7 +1569,6 @@ typedef enum _D3DRESOURCETYPE { D3DRTYPE_VERTEXBUFFER = 6, D3DRTYPE_INDEXBUFFER = 7, /* if this changes, change _D3DDEVINFO_RESOURCEMANAGER definition */ - D3DRTYPE_FORCE_DWORD = 0x7fffffff } D3DRESOURCETYPE; @@ -1655,7 +1634,6 @@ typedef enum _D3DCUBEMAP_FACES D3DCUBEMAP_FACE_FORCE_DWORD = 0x7fffffff } D3DCUBEMAP_FACES; - /* Lock flags */ #define D3DLOCK_READONLY 0x00000010L @@ -1666,12 +1644,6 @@ typedef enum _D3DCUBEMAP_FACES #define D3DLOCK_NO_DIRTY_UPDATE 0x00008000L - - - - - - /* Vertex Buffer Description */ typedef struct _D3DVERTEXBUFFER_DESC { @@ -1695,7 +1667,6 @@ typedef struct _D3DINDEXBUFFER_DESC UINT Size; } D3DINDEXBUFFER_DESC; - /* Surface Description */ typedef struct _D3DSURFACE_DESC { @@ -1801,7 +1772,6 @@ typedef struct _D3DADAPTER_IDENTIFIER9 } D3DADAPTER_IDENTIFIER9; - /* Raster Status structure returned by GetRasterStatus */ typedef struct _D3DRASTER_STATUS { @@ -1809,8 +1779,6 @@ typedef struct _D3DRASTER_STATUS UINT ScanLine; } D3DRASTER_STATUS; - - /* Debug monitor tokens (DEBUG only) Note that if D3DRS_DEBUGMONITORTOKEN is set, the call is treated as @@ -1860,7 +1828,6 @@ typedef enum _D3DQUERYTYPE { /* Flags field for GetData */ #define D3DGETDATA_FLUSH (1 << 0) /* Tells the runtime to flush if the query is outstanding. */ - typedef struct _D3DRESOURCESTATS { /* Data collected since last Present() */ @@ -1895,7 +1862,6 @@ typedef struct _D3DDEVINFO_D3DVERTEXSTATS DWORD NumExtraClippingTriangles; /* Number of new triangles generated by clipping */ } D3DDEVINFO_D3DVERTEXSTATS, *LPD3DDEVINFO_D3DVERTEXSTATS; - typedef struct _D3DDEVINFO_VCACHE { DWORD Pattern; /* bit pattern, return value must be FOUR_CC('C', 'A', 'C', 'H') */ DWORD OptMethod; /* optimization method 0 means longest strips, 1 means vertex cache based */ @@ -1978,7 +1944,6 @@ typedef struct _D3DCOMPOSERECTDESTINATION #define D3DFMT_A1_SURFACE_MAXWIDTH 8192 #define D3DFMT_A1_SURFACE_MAXHEIGHT 2048 - typedef struct _D3DPRESENTSTATS { UINT PresentCount; UINT PresentRefreshCount; @@ -1994,7 +1959,6 @@ typedef enum D3DSCANLINEORDERING D3DSCANLINEORDERING_INTERLACED = 2 } D3DSCANLINEORDERING; - typedef struct D3DDISPLAYMODEEX { UINT Size; @@ -2012,7 +1976,6 @@ typedef struct D3DDISPLAYMODEFILTER D3DSCANLINEORDERING ScanLineOrdering; } D3DDISPLAYMODEFILTER; - typedef enum D3DDISPLAYROTATION { D3DDISPLAYROTATION_IDENTITY = 1, /* No rotation. */ @@ -2084,7 +2047,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYPROTECTION_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYPROTECTION_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_CHANNELTYPE, 0xbc1b18a5, 0xb1fb, 0x42ab, 0xbd, 0x94, 0xb5, 0x82, 0x8b, 0x4b, 0xf7, 0xbe); @@ -2096,7 +2058,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYCHANNELTYPE_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYCHANNELTYPE_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_DEVICEHANDLE, 0xec1c539d, 0x8cff, 0x4e2a, 0xbc, 0xc4, 0xf5, 0x69, 0x2f, 0x99, 0xf4, 0x80); @@ -2108,7 +2069,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYDEVICEHANDLE_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYDEVICEHANDLE_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_CRYPTOSESSION, 0x2634499e, 0xd018, 0x4d74, 0xac, 0x17, 0x7f, 0x72, 0x40, 0x59, 0x52, 0x8d); @@ -2130,7 +2090,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYCRYPTOSESSION_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_RESTRICTEDSHAREDRESOURCEPROCESSCOUNT, 0xdb207b3, 0x9450, 0x46a6, 0x82, 0xde, 0x1b, 0x96, 0xd4, 0x4f, 0x9c, 0xf2); @@ -2142,7 +2101,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESSCOUN } D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESSCOUNT_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_RESTRICTEDSHAREDRESOURCEPROCESS, 0x649bbadb, 0xf0f4, 0x4639, 0xa1, 0x5b, 0x24, 0x39, 0x3f, 0xc3, 0xab, 0xac); @@ -2171,7 +2129,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_OUT } D3DAUTHENTICATEDCHANNEL_QUERYRESTRICTEDSHAREDRESOURCEPROCESS_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_UNRESTRICTEDPROTECTEDSHAREDRESOURCECOUNT, 0x12f0bd6, 0xe662, 0x4474, 0xbe, 0xfd, 0xaa, 0x53, 0xe5, 0x14, 0x3c, 0x6d); @@ -2183,7 +2140,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYUNRESTRICTEDPROTECTEDSHAREDRESOURCE } D3DAUTHENTICATEDCHANNEL_QUERYUNRESTRICTEDPROTECTEDSHAREDRESOURCECOUNT_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_OUTPUTIDCOUNT, 0x2c042b5e, 0x8c07, 0x46d5, 0xaa, 0xbe, 0x8f, 0x75, 0xcb, 0xad, 0x4c, 0x31); @@ -2206,7 +2162,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTIDCOUNT_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_OUTPUTID, 0x839ddca3, 0x9b4e, 0x41e4, 0xb0, 0x53, 0x89, 0x2b, 0xd2, 0xa1, 0x1e, 0xe7); @@ -2231,7 +2186,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYOUTPUTID_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_ACCESSIBILITYATTRIBUTES, 0x6214d9d2, 0x432c, 0x4abb, 0x9f, 0xce, 0x21, 0x6e, 0xea, 0x26, 0x9e, 0x3b); @@ -2260,7 +2214,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYINFOBUSTYPE_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYINFOBUSTYPE_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_ENCRYPTIONWHENACCESSIBLEGUIDCOUNT, 0xb30f7066, 0x203c, 0x4b07, 0x93, 0xfc, 0xce, 0xaa, 0xfd, 0x61, 0x24, 0x1e); @@ -2272,7 +2225,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUIDCOUNT_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUIDCOUNT_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_ENCRYPTIONWHENACCESSIBLEGUID, 0xf83a5958, 0xe986, 0x4bda, 0xbe, 0xb0, 0x41, 0x1f, 0x6a, 0x7a, 0x1, 0xb7); @@ -2293,7 +2245,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYEVICTIONENCRYPTIONGUID_OUTPUT; - DEFINE_GUID(D3DAUTHENTICATEDQUERY_CURRENTENCRYPTIONWHENACCESSIBLE, 0xec1791c7, 0xdad3, 0x4f15, 0x9e, 0xc3, 0xfa, 0xa9, 0x3d, 0x60, 0xd4, 0xf0); @@ -2305,7 +2256,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_QUERYUNCOMPRESSEDENCRYPTIONLEVEL_OUTPUT } D3DAUTHENTICATEDCHANNEL_QUERYUNCOMPRESSEDENCRYPTIONLEVEL_OUTPUT; - typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURE_INPUT { D3D_OMAC omac; @@ -2337,7 +2287,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGUREINITIALIZE } D3DAUTHENTICATEDCHANNEL_CONFIGUREINITIALIZE; - DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_PROTECTION, 0x50455658, 0x3f47, 0x4362, 0xbf, 0x99, 0xbf, 0xdf, 0xcd, 0xe9, 0xed, 0x29); @@ -2349,7 +2298,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGUREPROTECTION } D3DAUTHENTICATEDCHANNEL_CONFIGUREPROTECTION; - DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_CRYPTOSESSION, 0x6346cc54, 0x2cfc, 0x4ad4, 0x82, 0x24, 0xd1, 0x58, 0x37, 0xde, 0x77, 0x0); @@ -2363,7 +2311,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURECRYPTOSESSION } D3DAUTHENTICATEDCHANNEL_CONFIGURECRYPTOSESSION; - DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_SHAREDRESOURCE, 0x772d047, 0x1b40, 0x48e8, 0x9c, 0xa6, 0xb5, 0xf5, 0x10, 0xde, 0x9f, 0x1); @@ -2377,7 +2324,6 @@ typedef struct _D3DAUTHENTICATEDCHANNEL_CONFIGURESHAREDRESOURCE } D3DAUTHENTICATEDCHANNEL_CONFIGURESHAREDRESOURCE; - DEFINE_GUID(D3DAUTHENTICATEDCONFIGURE_ENCRYPTIONWHENACCESSIBLE, 0x41fff286, 0x6ae0, 0x4d43, 0x9d, 0x55, 0xa4, 0x6e, 0x9e, 0xfd, 0x15, 0x8a); @@ -2402,8 +2348,6 @@ typedef struct _D3DAES_CTR_IV UINT64 Count; /* Big-Endian Block Count */ } D3DAES_CTR_IV; - - #endif /* !D3D_DISABLE_9EX */ /* -- D3D9Ex only */ @@ -2412,6 +2356,5 @@ typedef struct _D3DAES_CTR_IV #pragma warning(pop) #endif - #endif /* (DIRECT3D_VERSION >= 0x0900) */ #endif /* _d3d9TYPES(P)_H_ */ diff --git a/gfx/include/dxsdk/audiodefs.h b/gfx/include/dxsdk/audiodefs.h index 089612758a..a4da92c050 100644 --- a/gfx/include/dxsdk/audiodefs.h +++ b/gfx/include/dxsdk/audiodefs.h @@ -25,7 +25,6 @@ #pragma pack(push, 1) // Pack structures to 1-byte boundaries - /************************************************************************** * * WAVEFORMATEX: Base structure for many audio formats. Format-specific @@ -56,7 +55,6 @@ typedef WAVEFORMATEX *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX; typedef const WAVEFORMATEX *PCWAVEFORMATEX, *LPCWAVEFORMATEX; - /************************************************************************** * * WAVEFORMATEXTENSIBLE: Extended version of WAVEFORMATEX that should be @@ -90,8 +88,6 @@ typedef const WAVEFORMATEX *PCWAVEFORMATEX, *LPCWAVEFORMATEX; typedef WAVEFORMATEXTENSIBLE *PWAVEFORMATEXTENSIBLE, *LPWAVEFORMATEXTENSIBLE; typedef const WAVEFORMATEXTENSIBLE *PCWAVEFORMATEXTENSIBLE, *LPCWAVEFORMATEXTENSIBLE; - - /************************************************************************** * * Define the most common wave format tags used in WAVEFORMATEX formats. @@ -184,7 +180,6 @@ typedef const WAVEFORMATEXTENSIBLE *PCWAVEFORMATEXTENSIBLE, *LPCWAVEFORMATEXTENS #define WAVE_FORMAT_EXTENSIBLE 0xFFFE // All WAVEFORMATEXTENSIBLE formats #endif - /************************************************************************** * * Define the most common wave format GUIDs used in WAVEFORMATEXTENSIBLE @@ -213,7 +208,6 @@ typedef const WAVEFORMATEXTENSIBLE *PCWAVEFORMATEXTENSIBLE, *LPCWAVEFORMATEXTENS #endif - /************************************************************************** * * Speaker positions used in the WAVEFORMATEXTENSIBLE dwChannelMask field. @@ -257,7 +251,6 @@ typedef const WAVEFORMATEXTENSIBLE *PCWAVEFORMATEXTENSIBLE, *LPCWAVEFORMATEXTENS #define SPEAKER_7POINT1_SURROUND (SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | SPEAKER_FRONT_CENTER | SPEAKER_LOW_FREQUENCY | SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT | SPEAKER_SIDE_LEFT | SPEAKER_SIDE_RIGHT) #endif - #pragma pack(pop) #endif // #ifndef __AUDIODEFS_INCLUDED__ diff --git a/gfx/include/dxsdk/d2d1.h b/gfx/include/dxsdk/d2d1.h index 6891e9b394..adc43ff476 100644 --- a/gfx/include/dxsdk/d2d1.h +++ b/gfx/include/dxsdk/d2d1.h @@ -81,7 +81,6 @@ typedef interface ID2D1Brush ID2D1Brush; #define D2D1_INVALID_TAG ULONGLONG_MAX #define D2D1_DEFAULT_FLATTENING_TOLERANCE (0.25f) - /// /// This defines the superset of interpolation mode supported by D2D APIs /// and built-in effects @@ -99,7 +98,6 @@ enum }; - /// /// This determines what gamma is used for interpolation/blending. /// @@ -119,7 +117,6 @@ typedef enum D2D1_GAMMA } D2D1_GAMMA; - /// /// Specifies what the contents are of an opacity mask. /// @@ -144,7 +141,6 @@ typedef enum D2D1_OPACITY_MASK_CONTENT } D2D1_OPACITY_MASK_CONTENT; - /// /// Enum which describes how to sample from a source outside its base tile. /// @@ -172,7 +168,6 @@ typedef enum D2D1_EXTEND_MODE } D2D1_EXTEND_MODE; - /// /// Enum which describes the manner in which we render edges of non-text primitives. /// @@ -192,7 +187,6 @@ typedef enum D2D1_ANTIALIAS_MODE } D2D1_ANTIALIAS_MODE; - /// /// Describes the antialiasing mode used for drawing text. /// @@ -222,7 +216,6 @@ typedef enum D2D1_TEXT_ANTIALIAS_MODE } D2D1_TEXT_ANTIALIAS_MODE; - /// /// Specifies the algorithm that is used when images are scaled or rotated. Note /// Starting in Windows 8, more interpolations modes are available. See @@ -245,7 +238,6 @@ typedef enum D2D1_BITMAP_INTERPOLATION_MODE } D2D1_BITMAP_INTERPOLATION_MODE; - /// /// Modifications made to the draw text call that influence how the text is /// rendered. @@ -300,7 +292,6 @@ typedef struct D2D1_BITMAP_PROPERTIES } D2D1_BITMAP_PROPERTIES; - /// /// Contains the position and color of a gradient stop. /// @@ -311,7 +302,6 @@ typedef struct D2D1_GRADIENT_STOP } D2D1_GRADIENT_STOP; - /// /// Describes the opacity and transformation of a brush. /// @@ -322,7 +312,6 @@ typedef struct D2D1_BRUSH_PROPERTIES } D2D1_BRUSH_PROPERTIES; - /// /// Describes the extend modes and the interpolation mode of an ID2D1BitmapBrush. /// @@ -334,7 +323,6 @@ typedef struct D2D1_BITMAP_BRUSH_PROPERTIES } D2D1_BITMAP_BRUSH_PROPERTIES; - /// /// Contains the starting point and endpoint of the gradient axis for an /// ID2D1LinearGradientBrush. @@ -346,7 +334,6 @@ typedef struct D2D1_LINEAR_GRADIENT_BRUSH_PROPERTIES } D2D1_LINEAR_GRADIENT_BRUSH_PROPERTIES; - /// /// Contains the gradient origin offset and the size and position of the gradient /// ellipse for an ID2D1RadialGradientBrush. @@ -360,7 +347,6 @@ typedef struct D2D1_RADIAL_GRADIENT_BRUSH_PROPERTIES } D2D1_RADIAL_GRADIENT_BRUSH_PROPERTIES; - /// /// Differentiates which of the two possible arcs could match the given arc /// parameters. @@ -373,7 +359,6 @@ typedef enum D2D1_ARC_SIZE } D2D1_ARC_SIZE; - /// /// Enum which describes the drawing of the ends of a line. /// @@ -403,7 +388,6 @@ typedef enum D2D1_CAP_STYLE } D2D1_CAP_STYLE; - /// /// Describes the sequence of dashes and gaps in a stroke. /// @@ -419,7 +403,6 @@ typedef enum D2D1_DASH_STYLE } D2D1_DASH_STYLE; - /// /// Enum which describes the drawing of the corners on the line. /// @@ -449,7 +432,6 @@ typedef enum D2D1_LINE_JOIN } D2D1_LINE_JOIN; - /// /// This enumeration describes the type of combine operation to be performed. /// @@ -483,7 +465,6 @@ typedef enum D2D1_COMBINE_MODE } D2D1_COMBINE_MODE; - /// /// Describes how one geometry object is spatially related to another geometry /// object. @@ -520,7 +501,6 @@ typedef enum D2D1_GEOMETRY_RELATION } D2D1_GEOMETRY_RELATION; - /// /// Specifies how simple the output of a simplified geometry sink should be. /// @@ -532,7 +512,6 @@ typedef enum D2D1_GEOMETRY_SIMPLIFICATION_OPTION } D2D1_GEOMETRY_SIMPLIFICATION_OPTION; - /// /// Indicates whether the given figure is filled or hollow. /// @@ -544,7 +523,6 @@ typedef enum D2D1_FIGURE_BEGIN } D2D1_FIGURE_BEGIN; - /// /// Indicates whether the figure is open or closed on its end point. /// @@ -556,7 +534,6 @@ typedef enum D2D1_FIGURE_END } D2D1_FIGURE_END; - /// /// Describes a cubic bezier in a path. /// @@ -568,7 +545,6 @@ typedef struct D2D1_BEZIER_SEGMENT } D2D1_BEZIER_SEGMENT; - /// /// Describes a triangle. /// @@ -580,7 +556,6 @@ typedef struct D2D1_TRIANGLE } D2D1_TRIANGLE; - /// /// Indicates whether the given segment should be stroked, or, if the join between /// this segment and the previous one should be smooth. @@ -596,7 +571,6 @@ typedef enum D2D1_PATH_SEGMENT DEFINE_ENUM_FLAG_OPERATORS(D2D1_PATH_SEGMENT); - /// /// Defines the direction that an elliptical arc is drawn. /// @@ -608,7 +582,6 @@ typedef enum D2D1_SWEEP_DIRECTION } D2D1_SWEEP_DIRECTION; - /// /// Specifies how the intersecting areas of geometries or figures are combined to /// form the area of the composite geometry. @@ -621,7 +594,6 @@ typedef enum D2D1_FILL_MODE } D2D1_FILL_MODE; - /// /// Describes an arc that is defined as part of a path. /// @@ -635,7 +607,6 @@ typedef struct D2D1_ARC_SEGMENT } D2D1_ARC_SEGMENT; - /// /// Contains the control point and end point for a quadratic Bezier segment. /// @@ -646,7 +617,6 @@ typedef struct D2D1_QUADRATIC_BEZIER_SEGMENT } D2D1_QUADRATIC_BEZIER_SEGMENT; - /// /// Contains the center point, x-radius, and y-radius of an ellipse. /// @@ -658,7 +628,6 @@ typedef struct D2D1_ELLIPSE } D2D1_ELLIPSE; - /// /// Contains the dimensions and corner radii of a rounded rectangle. /// @@ -670,7 +639,6 @@ typedef struct D2D1_ROUNDED_RECT } D2D1_ROUNDED_RECT; - /// /// Properties, aside from the width, that allow geometric penning to be specified. /// @@ -686,7 +654,6 @@ typedef struct D2D1_STROKE_STYLE_PROPERTIES } D2D1_STROKE_STYLE_PROPERTIES; - /// /// Specified options that can be applied when a layer resource is applied to create /// a layer. @@ -710,7 +677,6 @@ typedef enum D2D1_LAYER_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_LAYER_OPTIONS); - /// /// Contains the content bounds, mask information, opacity settings, and other /// options for a layer resource. @@ -761,7 +727,6 @@ typedef struct D2D1_LAYER_PARAMETERS } D2D1_LAYER_PARAMETERS; - /// /// Describes whether a window is occluded. /// @@ -775,7 +740,6 @@ typedef enum D2D1_WINDOW_STATE DEFINE_ENUM_FLAG_OPERATORS(D2D1_WINDOW_STATE); - /// /// Describes whether a render target uses hardware or software rendering, or if /// Direct2D should select the rendering mode. @@ -801,7 +765,6 @@ typedef enum D2D1_RENDER_TARGET_TYPE } D2D1_RENDER_TARGET_TYPE; - /// /// Describes the minimum DirectX support required for hardware rendering by a /// render target. @@ -827,7 +790,6 @@ typedef enum D2D1_FEATURE_LEVEL } D2D1_FEATURE_LEVEL; - /// /// Describes how a render target is remoted and whether it should be /// GDI-compatible. This enumeration allows a bitwise combination of its member @@ -854,7 +816,6 @@ typedef enum D2D1_RENDER_TARGET_USAGE DEFINE_ENUM_FLAG_OPERATORS(D2D1_RENDER_TARGET_USAGE); - /// /// Describes how present should behave. /// @@ -877,7 +838,6 @@ typedef enum D2D1_PRESENT_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_PRESENT_OPTIONS); - /// /// Contains rendering options (hardware or software), pixel format, DPI /// information, remoting options, and Direct3D support requirements for a render @@ -894,7 +854,6 @@ typedef struct D2D1_RENDER_TARGET_PROPERTIES } D2D1_RENDER_TARGET_PROPERTIES; - /// /// Contains the HWND, pixel size, and presentation options for an /// ID2D1HwndRenderTarget. @@ -907,7 +866,6 @@ typedef struct D2D1_HWND_RENDER_TARGET_PROPERTIES } D2D1_HWND_RENDER_TARGET_PROPERTIES; - /// /// Specifies additional features supportable by a compatible render target when it /// is created. This enumeration allows a bitwise combination of its member values. @@ -928,7 +886,6 @@ typedef enum D2D1_COMPATIBLE_RENDER_TARGET_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_COMPATIBLE_RENDER_TARGET_OPTIONS); - /// /// Allows the drawing state to be atomically created. This also specifies the /// drawing state that is saved into an IDrawingStateBlock object. @@ -943,7 +900,6 @@ typedef struct D2D1_DRAWING_STATE_DESCRIPTION } D2D1_DRAWING_STATE_DESCRIPTION; - /// /// Specifies how a device context is initialized for GDI rendering when it is /// retrieved from the render target. @@ -964,7 +920,6 @@ typedef enum D2D1_DC_INITIALIZE_MODE } D2D1_DC_INITIALIZE_MODE; - /// /// Indicates the debug level to be output by the debug layer. /// @@ -978,7 +933,6 @@ typedef enum D2D1_DEBUG_LEVEL } D2D1_DEBUG_LEVEL; - /// /// Specifies the threading model of the created factory and all of its derived /// resources. @@ -1002,7 +956,6 @@ typedef enum D2D1_FACTORY_TYPE } D2D1_FACTORY_TYPE; - /// /// Allows additional parameters for factory creation. /// @@ -1017,15 +970,12 @@ typedef struct D2D1_FACTORY_OPTIONS } D2D1_FACTORY_OPTIONS; - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ - /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ - EXTERN_C CONST IID IID_ID2D1Resource; EXTERN_C CONST IID IID_ID2D1Image; EXTERN_C CONST IID IID_ID2D1Bitmap; @@ -1055,24 +1005,19 @@ EXTERN_C CONST IID IID_ID2D1HwndRenderTarget; EXTERN_C CONST IID IID_ID2D1DCRenderTarget; EXTERN_C CONST IID IID_ID2D1Factory; - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ - EXTERN_C CONST IID IID_ID2D1GdiInteropRenderTarget; - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ /*#pragma endregion*/ - #ifndef D2D_USE_C_DEFINITIONS - /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ @@ -1090,7 +1035,6 @@ interface DX_DECLARE_INTERFACE("2cd90691-12e2-11dc-9fed-001143a055f9") ID2D1Reso ) CONST PURE; }; // interface ID2D1Resource - /// /// Represents a producer of pixels that can fill an arbitrary 2D plane. /// @@ -1098,7 +1042,6 @@ interface DX_DECLARE_INTERFACE("65019f75-8da2-497c-b32c-dfa34e48ede6") ID2D1Imag { }; // interface ID2D1Image - /// /// Root bitmap resource, linearly scaled on a draw call. /// @@ -1150,7 +1093,6 @@ interface DX_DECLARE_INTERFACE("a2296057-ea42-4099-983b-539fb6505426") ID2D1Bitm ) PURE; }; // interface ID2D1Bitmap - /// /// Represents an collection of gradient stops that can then be the source resource /// for either a linear or radial gradient brush. @@ -1183,7 +1125,6 @@ interface DX_DECLARE_INTERFACE("2cd906a7-12e2-11dc-9fed-001143a055f9") ID2D1Grad ) CONST PURE; }; // interface ID2D1GradientStopCollection - /// /// The root brush interface. All brushes can be used to fill or pen a geometry. /// @@ -1221,7 +1162,6 @@ interface DX_DECLARE_INTERFACE("2cd906a8-12e2-11dc-9fed-001143a055f9") ID2D1Brus } }; // interface ID2D1Brush - /// /// A bitmap brush allows a bitmap to be used to fill a geometry. /// @@ -1272,7 +1212,6 @@ interface DX_DECLARE_INTERFACE("2cd906aa-12e2-11dc-9fed-001143a055f9") ID2D1Bitm ) CONST PURE; }; // interface ID2D1BitmapBrush - /// /// Paints an area with a solid color. /// @@ -1296,7 +1235,6 @@ interface DX_DECLARE_INTERFACE("2cd906a9-12e2-11dc-9fed-001143a055f9") ID2D1Soli } }; // interface ID2D1SolidColorBrush - /// /// Paints an area with a linear gradient. /// @@ -1326,7 +1264,6 @@ interface DX_DECLARE_INTERFACE("2cd906ab-12e2-11dc-9fed-001143a055f9") ID2D1Line ) CONST PURE; }; // interface ID2D1LinearGradientBrush - /// /// Paints an area with a radial gradient. /// @@ -1373,7 +1310,6 @@ interface DX_DECLARE_INTERFACE("2cd906ac-12e2-11dc-9fed-001143a055f9") ID2D1Radi ) CONST PURE; }; // interface ID2D1RadialGradientBrush - /// /// Resource interface that holds pen style properties. /// @@ -1414,7 +1350,6 @@ interface DX_DECLARE_INTERFACE("2cd9069d-12e2-11dc-9fed-001143a055f9") ID2D1Stro ) CONST PURE; }; // interface ID2D1StrokeStyle - /// /// Represents a geometry resource and defines a set of helper methods for /// manipulating and measuring geometric shapes. Interfaces that inherit from @@ -2095,7 +2030,6 @@ interface DX_DECLARE_INTERFACE("2cd906a1-12e2-11dc-9fed-001143a055f9") ID2D1Geom } }; // interface ID2D1Geometry - /// /// Describes a two-dimensional rectangle. /// @@ -2107,7 +2041,6 @@ interface DX_DECLARE_INTERFACE("2cd906a2-12e2-11dc-9fed-001143a055f9") ID2D1Rect ) CONST PURE; }; // interface ID2D1RectangleGeometry - /// /// Describes a rounded rectangle. /// @@ -2119,7 +2052,6 @@ interface DX_DECLARE_INTERFACE("2cd906a3-12e2-11dc-9fed-001143a055f9") ID2D1Roun ) CONST PURE; }; // interface ID2D1RoundedRectangleGeometry - /// /// Represents an ellipse. /// @@ -2131,7 +2063,6 @@ interface DX_DECLARE_INTERFACE("2cd906a4-12e2-11dc-9fed-001143a055f9") ID2D1Elli ) CONST PURE; }; // interface ID2D1EllipseGeometry - /// /// Represents a composite geometry, composed of other ID2D1Geometry objects. /// @@ -2150,7 +2081,6 @@ interface DX_DECLARE_INTERFACE("2cd906a6-12e2-11dc-9fed-001143a055f9") ID2D1Geom ) CONST PURE; }; // interface ID2D1GeometryGroup - /// /// Represents a geometry that has been transformed. /// @@ -2166,7 +2096,6 @@ interface DX_DECLARE_INTERFACE("2cd906bb-12e2-11dc-9fed-001143a055f9") ID2D1Tran ) CONST PURE; }; // interface ID2D1TransformedGeometry - /// /// Describes a geometric path that does not contain quadratic bezier curves or /// arcs. @@ -2205,7 +2134,6 @@ interface DX_DECLARE_INTERFACE("2cd9069e-12e2-11dc-9fed-001143a055f9") ID2D1Simp ) PURE; }; // interface ID2D1SimplifiedGeometrySink - /// /// Describes a geometric path that can contain lines, arcs, cubic Bezier curves, /// and quadratic Bezier curves. @@ -2262,7 +2190,6 @@ interface DX_DECLARE_INTERFACE("2cd9069f-12e2-11dc-9fed-001143a055f9") ID2D1Geom } }; // interface ID2D1GeometrySink - /// /// Populates an ID2D1Mesh object with triangles. /// @@ -2278,7 +2205,6 @@ interface DX_DECLARE_INTERFACE("2cd906c1-12e2-11dc-9fed-001143a055f9") ID2D1Tess ) PURE; }; // interface ID2D1TessellationSink - /// /// Represents a complex shape that may be composed of arcs, curves, and lines. /// @@ -2309,7 +2235,6 @@ interface DX_DECLARE_INTERFACE("2cd906a5-12e2-11dc-9fed-001143a055f9") ID2D1Path ) CONST PURE; }; // interface ID2D1PathGeometry - /// /// Represents a set of vertices that form a list of triangles. /// @@ -2324,7 +2249,6 @@ interface DX_DECLARE_INTERFACE("2cd906c2-12e2-11dc-9fed-001143a055f9") ID2D1Mesh ) PURE; }; // interface ID2D1Mesh - /// /// Represents the backing store required to render a layer. /// @@ -2335,7 +2259,6 @@ interface DX_DECLARE_INTERFACE("2cd9069b-12e2-11dc-9fed-001143a055f9") ID2D1Laye ) CONST PURE; }; // interface ID2D1Layer - /// /// Represents the drawing state of a render target: the antialiasing mode, /// transform, tags, and text-rendering options. @@ -2383,7 +2306,6 @@ interface DX_DECLARE_INTERFACE("28506e39-ebf6-46a1-bb47-fd85565ab957") ID2D1Draw } }; // interface ID2D1DrawingStateBlock - /// /// Represents an object that can receive drawing commands. Interfaces that inherit /// from ID2D1RenderTarget render the drawing commands they receive in different @@ -3242,7 +3164,6 @@ interface DX_DECLARE_INTERFACE("2cd90694-12e2-11dc-9fed-001143a055f9") ID2D1Rend } }; // interface ID2D1RenderTarget - /// /// Renders to an intermediate texture created by the CreateCompatibleRenderTarget /// method. @@ -3255,7 +3176,6 @@ interface DX_DECLARE_INTERFACE("2cd90695-12e2-11dc-9fed-001143a055f9") ID2D1Bitm ) PURE; }; // interface ID2D1BitmapRenderTarget - /// /// Renders drawing instructions to a window. /// @@ -3290,8 +3210,6 @@ interface DX_DECLARE_INTERFACE("2cd90698-12e2-11dc-9fed-001143a055f9") ID2D1Hwnd } }; // interface ID2D1HwndRenderTarget - - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ @@ -3314,8 +3232,6 @@ interface DX_DECLARE_INTERFACE("e0db51c3-6f77-4bae-b3d5-e47509b35838") ID2D1GdiI ) PURE; }; // interface ID2D1GdiInteropRenderTarget - - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ /*#pragma endregion*/ @@ -3334,7 +3250,6 @@ interface DX_DECLARE_INTERFACE("1c51bc64-de61-46fd-9899-63a5d8f03950") ID2D1DCRe ) PURE; }; // interface ID2D1DCRenderTarget - /// /// The root factory interface for all of D2D's objects. /// @@ -3558,18 +3473,13 @@ interface DX_DECLARE_INTERFACE("06152247-6f50-465a-9245-118bfd3b6007") ID2D1Fact } }; // interface ID2D1Factory - - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ - #endif - #ifdef D2D_USE_C_DEFINITIONS - /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ @@ -3646,10 +3556,8 @@ typedef interface ID2D1Factory ID2D1Factory; /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ - #endif - /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ @@ -3670,7 +3578,6 @@ extern "C" _Out_ void **ppIFactory ); - void WINAPI D2D1MakeRotateMatrix( _In_ FLOAT angle, @@ -3707,7 +3614,6 @@ extern "C" #include - #ifndef D2D_USE_C_DEFINITIONS COM_DECLSPEC_NOTHROW @@ -3727,7 +3633,6 @@ D2D1CreateFactory( factory); } - template COM_DECLSPEC_NOTHROW HRESULT diff --git a/gfx/include/dxsdk/d2d1_1.h b/gfx/include/dxsdk/d2d1_1.h index 359f05c052..f6d909e9eb 100644 --- a/gfx/include/dxsdk/d2d1_1.h +++ b/gfx/include/dxsdk/d2d1_1.h @@ -86,7 +86,6 @@ typedef enum D2D1_PROPERTY_TYPE } D2D1_PROPERTY_TYPE; - /// /// This defines the list of system properties present on the root effect property /// interface. @@ -107,7 +106,6 @@ typedef enum D2D1_PROPERTY } D2D1_PROPERTY; - /// /// This defines the indices of sub-properties that may be present on any parent /// property. @@ -125,7 +123,6 @@ typedef enum D2D1_SUBPROPERTY } D2D1_SUBPROPERTY; - /// /// Specifies how the bitmap can be used. /// @@ -163,7 +160,6 @@ typedef enum D2D1_BITMAP_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_BITMAP_OPTIONS); - /// /// Specifies the composite mode that will be applied. /// @@ -186,7 +182,6 @@ typedef enum D2D1_COMPOSITE_MODE } D2D1_COMPOSITE_MODE; - /// /// This specifies the precision that should be used in buffers allocated by D2D. /// @@ -202,7 +197,6 @@ typedef enum D2D1_BUFFER_PRECISION } D2D1_BUFFER_PRECISION; - /// /// This describes how the individual mapping operation should be performed. /// @@ -234,7 +228,6 @@ typedef enum D2D1_MAP_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_MAP_OPTIONS); - /// /// This is used to specify the quality of image scaling with /// ID2D1DeviceContext::DrawImage and with the 2D Affine Transform Effect. @@ -251,7 +244,6 @@ typedef enum D2D1_INTERPOLATION_MODE } D2D1_INTERPOLATION_MODE; - /// /// This specifies what units should be accepted by the D2D API. /// @@ -263,7 +255,6 @@ typedef enum D2D1_UNIT_MODE } D2D1_UNIT_MODE; - /// /// Defines a color space. /// @@ -288,7 +279,6 @@ typedef enum D2D1_COLOR_SPACE } D2D1_COLOR_SPACE; - /// /// This specifies options that apply to the device context for its lifetime. /// @@ -307,7 +297,6 @@ typedef enum D2D1_DEVICE_CONTEXT_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_DEVICE_CONTEXT_OPTIONS); - /// /// Defines how the world transform, dots per inch (dpi), and stroke width affect /// the shape of the pen used to stroke a primitive. @@ -334,7 +323,6 @@ typedef enum D2D1_STROKE_TRANSFORM_TYPE } D2D1_STROKE_TRANSFORM_TYPE; - /// /// A blend mode that applies to all primitives drawn on the context. /// @@ -349,7 +337,6 @@ typedef enum D2D1_PRIMITIVE_BLEND } D2D1_PRIMITIVE_BLEND; - /// /// This specifies the threading mode used while simultaneously creating the device, /// factory, and device context. @@ -373,7 +360,6 @@ typedef enum D2D1_THREADING_MODE } D2D1_THREADING_MODE; - /// /// This specifies how colors are interpolated. /// @@ -414,7 +400,6 @@ typedef struct D2D1_BITMAP_PROPERTIES1 } D2D1_BITMAP_PROPERTIES1; - /// /// Describes mapped memory from the ID2D1Bitmap1::Map API. /// @@ -425,7 +410,6 @@ typedef struct D2D1_MAPPED_RECT } D2D1_MAPPED_RECT; - /// /// This controls advanced settings of the Direct2D imaging pipeline. /// @@ -444,7 +428,6 @@ typedef struct D2D1_RENDERING_CONTROLS } D2D1_RENDERING_CONTROLS; - /// /// This identifies a certain input connection of a certain effect. /// @@ -486,7 +469,6 @@ typedef struct D2D1_POINT_DESCRIPTION } D2D1_POINT_DESCRIPTION; - /// /// Creation properties for an image brush. /// @@ -499,7 +481,6 @@ typedef struct D2D1_IMAGE_BRUSH_PROPERTIES } D2D1_IMAGE_BRUSH_PROPERTIES; - /// /// Describes the extend modes and the interpolation mode of an ID2D1BitmapBrush. /// @@ -511,7 +492,6 @@ typedef struct D2D1_BITMAP_BRUSH_PROPERTIES1 } D2D1_BITMAP_BRUSH_PROPERTIES1; - /// /// This defines how geometries should be drawn and widened. /// @@ -532,7 +512,6 @@ typedef struct D2D1_STROKE_STYLE_PROPERTIES1 } D2D1_STROKE_STYLE_PROPERTIES1; - /// /// Specifies how the layer contents should be prepared. /// @@ -547,7 +526,6 @@ typedef enum D2D1_LAYER_OPTIONS1 DEFINE_ENUM_FLAG_OPERATORS(D2D1_LAYER_OPTIONS1); - /// /// All parameters related to pushing a layer. /// @@ -563,7 +541,6 @@ typedef struct D2D1_LAYER_PARAMETERS1 } D2D1_LAYER_PARAMETERS1; - /// /// Defines when font resources should be subset during printing. /// @@ -588,7 +565,6 @@ typedef enum D2D1_PRINT_FONT_SUBSET_MODE } D2D1_PRINT_FONT_SUBSET_MODE; - /// /// This describes the drawing state. /// @@ -604,7 +580,6 @@ typedef struct D2D1_DRAWING_STATE_DESCRIPTION1 } D2D1_DRAWING_STATE_DESCRIPTION1; - /// /// The creation properties for a ID2D1PrintControl object. /// @@ -625,7 +600,6 @@ typedef struct D2D1_PRINT_CONTROL_PROPERTIES } D2D1_PRINT_CONTROL_PROPERTIES; - /// /// This specifies the options while simultaneously creating the device, factory, /// and device context. @@ -642,7 +616,6 @@ typedef struct D2D1_CREATION_PROPERTIES } D2D1_CREATION_PROPERTIES; - EXTERN_C CONST IID IID_ID2D1GdiMetafileSink; EXTERN_C CONST IID IID_ID2D1GdiMetafile; EXTERN_C CONST IID IID_ID2D1CommandSink; @@ -663,10 +636,8 @@ EXTERN_C CONST IID IID_ID2D1Device; EXTERN_C CONST IID IID_ID2D1Factory1; EXTERN_C CONST IID IID_ID2D1Multithread; - #ifndef D2D_USE_C_DEFINITIONS - /// /// User-implementable interface for introspecting on a metafile. /// @@ -683,7 +654,6 @@ interface DX_DECLARE_INTERFACE("82237326-8111-4f7c-bcf4-b5c1175564fe") ID2D1GdiM ) PURE; }; // interface ID2D1GdiMetafileSink - /// /// Interface encapsulating a GDI/GDI+ metafile. /// @@ -705,7 +675,6 @@ interface DX_DECLARE_INTERFACE("2f543dc3-cfc1-4211-864f-cfd91c6f3395") ID2D1GdiM ) PURE; }; // interface ID2D1GdiMetafile - /// /// Caller-supplied implementation of an interface to receive the recorded command /// list. @@ -844,7 +813,6 @@ interface DX_DECLARE_INTERFACE("54d7898a-a061-40a7-bec7-e465bcba2c4f") ID2D1Comm ) PURE; }; // interface ID2D1CommandSink - /// /// The commandList interface. /// @@ -865,7 +833,6 @@ interface DX_DECLARE_INTERFACE("b4f34a19-2383-4d76-94f6-ec343657c3dc") ID2D1Comm ) PURE; }; // interface ID2D1CommandList - /// /// Converts Direct2D primitives stored in an ID2D1CommandList into a fixed page /// representation. The print sub-system then consumes the primitives. @@ -885,7 +852,6 @@ interface DX_DECLARE_INTERFACE("2c1d867d-c290-41c8-ae7e-34a98702e9a5") ID2D1Prin ) PURE; }; // interface ID2D1PrintControl - /// /// Provides a brush that can take any effect, command list or bitmap and use it to /// fill a 2D shape. @@ -931,7 +897,6 @@ interface DX_DECLARE_INTERFACE("fe9e984d-3f95-407c-b5db-cb94d4e8f87c") ID2D1Imag ) CONST PURE; }; // interface ID2D1ImageBrush - /// /// A bitmap brush allows a bitmap to be used to fill a geometry. Interpolation /// mode is specified with D2D1_INTERPOLATION_MODE @@ -950,7 +915,6 @@ interface DX_DECLARE_INTERFACE("41343a53-e41a-49a2-91cd-21793bbb62e5") ID2D1Bitm ) CONST PURE; }; // interface ID2D1BitmapBrush1 - /// /// Extends a stroke style to allow nominal width strokes. /// @@ -961,7 +925,6 @@ interface DX_DECLARE_INTERFACE("10a72a66-e91c-43f4-993f-ddf4b82b0b4a") ID2D1Stro ) CONST PURE; }; // interface ID2D1StrokeStyle1 - /// /// The ID2D1PathGeometry1 interface adds functionality to ID2D1PathGeometry. In /// particular, it provides the path geometry-specific @@ -1016,7 +979,6 @@ interface DX_DECLARE_INTERFACE("62baa2d2-ab54-41b7-b872-787e0106a421") ID2D1Path } }; // interface ID2D1PathGeometry1 - /// /// Represents a set of run-time bindable and discoverable properties that allow a /// data-driven application to modify the state of a Direct2D effect. @@ -1291,7 +1253,6 @@ interface DX_DECLARE_INTERFACE("483473d7-cd46-4f9d-9d3a-3112aa80159d") ID2D1Prop } }; // interface ID2D1Properties - /// /// The effect interface. Properties control how the effect is rendered. The effect /// is Drawn with the DrawImage call. @@ -1362,7 +1323,6 @@ interface DX_DECLARE_INTERFACE("28211a43-7d89-476f-8181-2d6159b220ad") ID2D1Effe } }; // interface ID2D1Effect - /// /// Represents a bitmap that can be used as a surface for an ID2D1DeviceContext or /// mapped into system memory, and can contain additional color context information. @@ -1407,7 +1367,6 @@ interface DX_DECLARE_INTERFACE("a898a84c-3873-4588-b08b-ebbf978df041") ID2D1Bitm ) PURE; }; // interface ID2D1Bitmap1 - /// /// Represents a color context that can be used with an ID2D1Bitmap1 object. /// @@ -1435,7 +1394,6 @@ interface DX_DECLARE_INTERFACE("1c4820bb-5771-4518-a581-2fe4dd0ec657") ID2D1Colo ) CONST PURE; }; // interface ID2D1ColorContext - /// /// Represents an collection of gradient stops that can then be the source resource /// for either a linear or radial gradient brush. @@ -1488,7 +1446,6 @@ interface DX_DECLARE_INTERFACE("ae1572f4-5dd0-4777-998b-9279472ae63b") ID2D1Grad ) CONST PURE; }; // interface ID2D1GradientStopCollection1 - /// /// Represents drawing state. /// @@ -1514,7 +1471,6 @@ interface DX_DECLARE_INTERFACE("689f1f85-c72e-4e33-8f19-85754efd5ace") ID2D1Draw using ID2D1DrawingStateBlock::SetDescription; }; // interface ID2D1DrawingStateBlock1 - /// /// The device context represents a set of state and a command buffer that is used /// to render to a target bitmap. @@ -2156,7 +2112,6 @@ interface DX_DECLARE_INTERFACE("e8f7fe7a-191c-466d-ad95-975678bda998") ID2D1Devi } }; // interface ID2D1DeviceContext - /// /// The device defines a resource domain whose objects and device contexts can be /// used together. @@ -2216,7 +2171,6 @@ interface DX_DECLARE_INTERFACE("47dd575d-ac05-4cdd-8049-9b02cd16f44c") ID2D1Devi } }; // interface ID2D1Device - /// /// Creates Direct2D resources. /// @@ -2363,7 +2317,6 @@ interface DX_DECLARE_INTERFACE("bb12d362-daee-4b9a-aa1d-14ba401cfa1f") ID2D1Fact } }; // interface ID2D1Factory1 - /// /// A locking mechanism from a Direct2D factory that Direct2D uses to control /// exclusive resource access in an app that is uses multiple threads. @@ -2391,14 +2344,10 @@ interface DX_DECLARE_INTERFACE("31e6e7bc-e0ff-4d46-8c64-a0a8c41c15d3") ID2D1Mult ) PURE; }; // interface ID2D1Multithread - - #endif - #ifdef D2D_USE_C_DEFINITIONS - typedef interface ID2D1GdiMetafileSink ID2D1GdiMetafileSink; typedef interface ID2D1GdiMetafile ID2D1GdiMetafile; @@ -2491,7 +2440,6 @@ extern "C" #include - #ifndef D2D_USE_C_DEFINITIONS inline HRESULT diff --git a/gfx/include/dxsdk/d2d1_1helper.h b/gfx/include/dxsdk/d2d1_1helper.h index 9e680b8f7e..8e13e2dbf7 100644 --- a/gfx/include/dxsdk/d2d1_1helper.h +++ b/gfx/include/dxsdk/d2d1_1helper.h @@ -359,7 +359,6 @@ namespace D2D1 return skewY; } - static COM_DECLSPEC_NOTHROW inline @@ -468,7 +467,6 @@ namespace D2D1 } }; - class Matrix5x4F : public D2D1_MATRIX_5X4_F { public: diff --git a/gfx/include/dxsdk/d2d1_2.h b/gfx/include/dxsdk/d2d1_2.h index 2441769ab8..69bf3be627 100644 --- a/gfx/include/dxsdk/d2d1_2.h +++ b/gfx/include/dxsdk/d2d1_2.h @@ -44,17 +44,14 @@ typedef enum D2D1_RENDERING_PRIORITY } D2D1_RENDERING_PRIORITY; - EXTERN_C CONST IID IID_ID2D1GeometryRealization; EXTERN_C CONST IID IID_ID2D1DeviceContext1; EXTERN_C CONST IID IID_ID2D1Device1; EXTERN_C CONST IID IID_ID2D1Factory2; EXTERN_C CONST IID IID_ID2D1CommandSink1; - #ifndef D2D_USE_C_DEFINITIONS - /// /// Encapsulates a device- and transform-dependent representation of a filled or /// stroked geometry. @@ -63,7 +60,6 @@ interface DX_DECLARE_INTERFACE("a16907d7-bc02-4801-99e8-8cf7f485f774") ID2D1Geom { }; // interface ID2D1GeometryRealization - /// /// Enables creation and drawing of geometry realization objects. /// @@ -90,7 +86,6 @@ interface DX_DECLARE_INTERFACE("d37f57e4-6908-459f-a199-e72f24f79987") ID2D1Devi ) PURE; }; // interface ID2D1DeviceContext1 - /// /// Represents a resource domain whose objects and device contexts can be used /// together. @@ -122,7 +117,6 @@ interface DX_DECLARE_INTERFACE("d21768e1-23a4-4823-a14b-7c3eba85d658") ID2D1Devi using ID2D1Device::CreateDeviceContext; }; // interface ID2D1Device1 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device1 objects. @@ -141,7 +135,6 @@ interface DX_DECLARE_INTERFACE("94f81a73-9212-4376-9c58-b16a3a0d3992") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory2 - /// /// This interface performs all the same functions as the existing ID2D1CommandSink /// interface. It also enables access to the new primitive blend modes, MIN and ADD, @@ -159,14 +152,10 @@ interface DX_DECLARE_INTERFACE("9eb767fd-4269-4467-b8c2-eb30cb305743") ID2D1Comm ) PURE; }; // interface ID2D1CommandSink1 - - #endif - #ifdef D2D_USE_C_DEFINITIONS - typedef interface ID2D1GeometryRealization ID2D1GeometryRealization; typedef interface ID2D1DeviceContext1 ID2D1DeviceContext1; @@ -197,7 +186,6 @@ extern "C" #endif - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ #include diff --git a/gfx/include/dxsdk/d2d1_3.h b/gfx/include/dxsdk/d2d1_3.h index eaf33b073e..d1028077a3 100644 --- a/gfx/include/dxsdk/d2d1_3.h +++ b/gfx/include/dxsdk/d2d1_3.h @@ -42,7 +42,6 @@ typedef enum D2D1_INK_NIB_SHAPE } D2D1_INK_NIB_SHAPE; - /// /// Specifies the orientation of an image. /// @@ -60,7 +59,6 @@ typedef enum D2D1_ORIENTATION } D2D1_ORIENTATION; - /// /// Option flags controlling how images sources are loaded during /// CreateImageSourceFromWic. @@ -76,7 +74,6 @@ typedef enum D2D1_IMAGE_SOURCE_LOADING_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_IMAGE_SOURCE_LOADING_OPTIONS); - /// /// Option flags controlling primary conversion performed by /// CreateImageSourceFromDxgi, if any. @@ -91,7 +88,6 @@ typedef enum D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_IMAGE_SOURCE_FROM_DXGI_OPTIONS); - /// /// Option flags for transformed image sources. /// @@ -110,7 +106,6 @@ typedef enum D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_TRANSFORMED_IMAGE_SOURCE_OPTIONS); - /// /// Properties of a transformed image source. /// @@ -145,7 +140,6 @@ typedef struct D2D1_TRANSFORMED_IMAGE_SOURCE_PROPERTIES } D2D1_TRANSFORMED_IMAGE_SOURCE_PROPERTIES; - /// /// Represents a point, radius pair that makes up part of a D2D1_INK_BEZIER_SEGMENT. /// @@ -157,7 +151,6 @@ typedef struct D2D1_INK_POINT } D2D1_INK_POINT; - /// /// Represents a Bezier segment to be used in the creation of an ID2D1Ink object. /// This structure differs from D2D1_BEZIER_SEGMENT in that it is composed of @@ -171,7 +164,6 @@ typedef struct D2D1_INK_BEZIER_SEGMENT } D2D1_INK_BEZIER_SEGMENT; - /// /// Defines the general pen tip shape and the transform used in an ID2D1InkStyle /// object. @@ -191,7 +183,6 @@ typedef struct D2D1_INK_STYLE_PROPERTIES } D2D1_INK_STYLE_PROPERTIES; - /// /// Specifies how to render gradient mesh edges. /// @@ -216,7 +207,6 @@ typedef enum D2D1_PATCH_EDGE_MODE } D2D1_PATCH_EDGE_MODE; - /// /// Represents a tensor patch with 16 control points, 4 corner colors, and boundary /// flags. An ID2D1GradientMesh is made up of 1 or more gradient mesh patches. Use @@ -366,7 +356,6 @@ typedef enum D2D1_SPRITE_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_SPRITE_OPTIONS); - /// /// Specifies the pixel snapping policy when rendering color bitmap glyphs. /// @@ -387,7 +376,6 @@ typedef enum D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION } D2D1_COLOR_BITMAP_GLYPH_SNAP_OPTION; - /// /// This determines what gamma is used for interpolation/blending. /// @@ -412,7 +400,6 @@ typedef enum D2D1_GAMMA1 } D2D1_GAMMA1; - /// /// Simple description of a color space. /// @@ -447,7 +434,6 @@ typedef struct D2D1_SIMPLE_COLOR_PROFILE } D2D1_SIMPLE_COLOR_PROFILE; - /// /// Specifies which way a color profile is defined. /// @@ -460,7 +446,6 @@ typedef enum D2D1_COLOR_CONTEXT_TYPE } D2D1_COLOR_CONTEXT_TYPE; - EXTERN_C CONST IID IID_ID2D1InkStyle; EXTERN_C CONST IID IID_ID2D1Ink; EXTERN_C CONST IID IID_ID2D1GradientMesh; @@ -493,10 +478,8 @@ EXTERN_C CONST IID IID_ID2D1DeviceContext6; EXTERN_C CONST IID IID_ID2D1Device6; EXTERN_C CONST IID IID_ID2D1Factory7; - #ifndef D2D_USE_C_DEFINITIONS - /// /// Represents a collection of style properties to be used by methods like /// ID2D1DeviceContext2::DrawInk when rendering ink. The ink style defines the nib @@ -530,7 +513,6 @@ interface DX_DECLARE_INTERFACE("bae8b344-23fc-4071-8cb5-d05d6f073848") ID2D1InkS } }; // interface ID2D1InkStyle - /// /// Represents a single continuous stroke of variable-width ink, as defined by a /// series of Bezier segments and widths. @@ -681,7 +663,6 @@ interface DX_DECLARE_INTERFACE("b499923b-7029-478f-a8b3-432c7c5f5312") ID2D1Ink } }; // interface ID2D1Ink - /// /// Represents a device-dependent representation of a gradient mesh composed of /// patches. Use the ID2D1DeviceContext2::CreateGradientMesh method to create an @@ -706,7 +687,6 @@ interface DX_DECLARE_INTERFACE("f292e401-c050-4cde-83d7-04962d3b23c2") ID2D1Grad ) CONST PURE; }; // interface ID2D1GradientMesh - /// /// Represents a producer of pixels that can fill an arbitrary 2D plane. /// @@ -721,7 +701,6 @@ interface DX_DECLARE_INTERFACE("c9b664e5-74a1-4378-9ac2-eefc37a3f4d8") ID2D1Imag ) PURE; }; // interface ID2D1ImageSource - /// /// Produces 2D pixel data that has been sourced from WIC. /// @@ -759,7 +738,6 @@ interface DX_DECLARE_INTERFACE("77395441-1c8f-4555-8683-f50dab0fe792") ID2D1Imag } }; // interface ID2D1ImageSourceFromWic - /// /// Represents an image source which shares resources with an original image source. /// @@ -775,7 +753,6 @@ interface DX_DECLARE_INTERFACE("7f1f79e5-2796-416c-8f55-700f911445e5") ID2D1Tran ) CONST PURE; }; // interface ID2D1TransformedImageSource - /// /// A container for 3D lookup table data that can be passed to the LookupTable3D /// effect. @@ -784,7 +761,6 @@ interface DX_DECLARE_INTERFACE("53dd9855-a3b0-4d5b-82e1-26e25c5e5797") ID2D1Look { }; // interface ID2D1LookupTable3D - /// /// This interface performs all the same functions as the ID2D1DeviceContext1 /// interface, plus it enables functionality such as ink rendering, gradient mesh @@ -952,7 +928,6 @@ interface DX_DECLARE_INTERFACE("394ea6a3-0c34-4321-950b-6ca20f0be6c7") ID2D1Devi } }; // interface ID2D1DeviceContext2 - /// /// Represents a resource domain whose objects and device contexts can be used /// together. This interface performs all the same functions as the existing @@ -989,7 +964,6 @@ interface DX_DECLARE_INTERFACE("a44472e1-8dfb-4e60-8492-6e2861c9ca8b") ID2D1Devi ) PURE; }; // interface ID2D1Device2 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device2 objects. @@ -1010,7 +984,6 @@ interface DX_DECLARE_INTERFACE("0869759f-4f00-413f-b03e-2bda45404d0f") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory3 - /// /// This interface performs all the same functions as the existing ID2D1CommandSink1 /// interface. It also enables access to ink rendering and gradient mesh rendering. @@ -1037,7 +1010,6 @@ interface DX_DECLARE_INTERFACE("3bab440e-417e-47df-a2e2-bc0be6a00916") ID2D1Comm using ID2D1CommandSink::DrawGdiMetafile; }; // interface ID2D1CommandSink2 - /// /// Interface encapsulating a GDI/GDI+ metafile. /// @@ -1061,7 +1033,6 @@ interface DX_DECLARE_INTERFACE("2e69f9e8-dd3f-4bf9-95ba-c04f49d788df") ID2D1GdiM ) PURE; }; // interface ID2D1GdiMetafile1 - /// /// User-implementable interface for introspecting on a metafile. /// @@ -1081,7 +1052,6 @@ interface DX_DECLARE_INTERFACE("fd0ecb6b-91e6-411e-8655-395e760f91b4") ID2D1GdiM using ID2D1GdiMetafileSink::ProcessRecord; }; // interface ID2D1GdiMetafileSink1 - #if NTDDI_VERSION >= NTDDI_WIN10_TH2 interface DX_DECLARE_INTERFACE("4dc583bf-3a10-438a-8722-e9765224f1f1") ID2D1SpriteBatch : public ID2D1Resource @@ -1144,7 +1114,6 @@ interface DX_DECLARE_INTERFACE("4dc583bf-3a10-438a-8722-e9765224f1f1") ID2D1Spri ) PURE; }; // interface ID2D1SpriteBatch - interface DX_DECLARE_INTERFACE("235a7496-8351-414c-bcd4-6672ab2d8e00") ID2D1DeviceContext3 : public ID2D1DeviceContext2 { @@ -1183,7 +1152,6 @@ interface DX_DECLARE_INTERFACE("235a7496-8351-414c-bcd4-6672ab2d8e00") ID2D1Devi } }; // interface ID2D1DeviceContext3 - interface DX_DECLARE_INTERFACE("852f2087-802c-4037-ab60-ff2e7ee6fc01") ID2D1Device3 : public ID2D1Device2 { @@ -1202,7 +1170,6 @@ interface DX_DECLARE_INTERFACE("852f2087-802c-4037-ab60-ff2e7ee6fc01") ID2D1Devi using ID2D1Device::CreateDeviceContext; }; // interface ID2D1Device3 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device3 objects. @@ -1225,7 +1192,6 @@ interface DX_DECLARE_INTERFACE("bd4ec2d2-0662-4bee-ba8e-6f29f032e096") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory4 - interface DX_DECLARE_INTERFACE("18079135-4cf3-4868-bc8e-06067e6d242d") ID2D1CommandSink3 : public ID2D1CommandSink2 { @@ -1239,7 +1205,6 @@ interface DX_DECLARE_INTERFACE("18079135-4cf3-4868-bc8e-06067e6d242d") ID2D1Comm ) PURE; }; // interface ID2D1CommandSink3 - #endif // #if NTDDI_VERSION >= NTDDI_WIN10_TH2 #if NTDDI_VERSION >= NTDDI_WIN10_RS1 @@ -1309,7 +1274,6 @@ interface DX_DECLARE_INTERFACE("af671749-d241-4db8-8e41-dcc2e5c1a438") ID2D1SvgG ) PURE; }; // interface ID2D1SvgGlyphStyle - interface DX_DECLARE_INTERFACE("8c427831-3d90-4476-b647-c4fae349e4db") ID2D1DeviceContext4 : public ID2D1DeviceContext3 { @@ -1475,7 +1439,6 @@ interface DX_DECLARE_INTERFACE("8c427831-3d90-4476-b647-c4fae349e4db") ID2D1Devi } }; // interface ID2D1DeviceContext4 - interface DX_DECLARE_INTERFACE("d7bdb159-5683-4a46-bc9c-72dc720b858b") ID2D1Device4 : public ID2D1Device3 { @@ -1513,7 +1476,6 @@ interface DX_DECLARE_INTERFACE("d7bdb159-5683-4a46-bc9c-72dc720b858b") ID2D1Devi ) CONST PURE; }; // interface ID2D1Device4 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device4 objects. @@ -1538,7 +1500,6 @@ interface DX_DECLARE_INTERFACE("c4349994-838e-4b0f-8cab-44997d9eeacc") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory5 - #endif // #if NTDDI_VERSION >= NTDDI_WIN10_RS1 #if NTDDI_VERSION >= NTDDI_WIN10_RS2 @@ -1562,7 +1523,6 @@ interface DX_DECLARE_INTERFACE("c78a6519-40d6-4218-b2de-beeeb744bb3e") ID2D1Comm ) PURE; }; // interface ID2D1CommandSink4 - /// /// Represents a color context to be used with the Color Management Effect. /// @@ -1590,7 +1550,6 @@ interface DX_DECLARE_INTERFACE("1ab42875-c57f-4be9-bd85-9cd78d6f55ee") ID2D1Colo ) CONST PURE; }; // interface ID2D1ColorContext1 - interface DX_DECLARE_INTERFACE("7836d248-68cc-4df6-b9e8-de991bf62eb7") ID2D1DeviceContext5 : public ID2D1DeviceContext4 { @@ -1647,7 +1606,6 @@ interface DX_DECLARE_INTERFACE("7836d248-68cc-4df6-b9e8-de991bf62eb7") ID2D1Devi } }; // interface ID2D1DeviceContext5 - interface DX_DECLARE_INTERFACE("d55ba0a4-6405-4694-aef5-08ee1a4358b4") ID2D1Device5 : public ID2D1Device4 { @@ -1670,7 +1628,6 @@ interface DX_DECLARE_INTERFACE("d55ba0a4-6405-4694-aef5-08ee1a4358b4") ID2D1Devi using ID2D1Device::CreateDeviceContext; }; // interface ID2D1Device5 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device5 objects. @@ -1697,7 +1654,6 @@ interface DX_DECLARE_INTERFACE("f9976f46-f642-44c1-97ca-da32ea2a2635") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory6 - #endif #if NTDDI_VERSION >= NTDDI_WIN10_RS3 @@ -1713,7 +1669,6 @@ interface DX_DECLARE_INTERFACE("7047dd26-b1e7-44a7-959a-8349e2144fa8") ID2D1Comm ) PURE; }; // interface ID2D1CommandSink5 - interface DX_DECLARE_INTERFACE("985f7e37-4ed0-4a19-98a3-15b0edfde306") ID2D1DeviceContext6 : public ID2D1DeviceContext5 { @@ -1729,7 +1684,6 @@ interface DX_DECLARE_INTERFACE("985f7e37-4ed0-4a19-98a3-15b0edfde306") ID2D1Devi ) PURE; }; // interface ID2D1DeviceContext6 - interface DX_DECLARE_INTERFACE("7bfef914-2d75-4bad-be87-e18ddb077b6d") ID2D1Device6 : public ID2D1Device5 { @@ -1754,7 +1708,6 @@ interface DX_DECLARE_INTERFACE("7bfef914-2d75-4bad-be87-e18ddb077b6d") ID2D1Devi using ID2D1Device::CreateDeviceContext; }; // interface ID2D1Device6 - /// /// Creates Direct2D resources. This interface also enables the creation of /// ID2D1Device6 objects. @@ -1783,15 +1736,12 @@ interface DX_DECLARE_INTERFACE("bdc2bdd3-b96c-4de6-bdf7-99d4745454de") ID2D1Fact using ID2D1Factory1::CreateDevice; }; // interface ID2D1Factory7 - #endif #endif - #ifdef D2D_USE_C_DEFINITIONS - typedef interface ID2D1InkStyle ID2D1InkStyle; typedef interface ID2D1Ink ID2D1Ink; @@ -1853,7 +1803,6 @@ extern "C" #endif - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ #include diff --git a/gfx/include/dxsdk/d2d1effectauthor.h b/gfx/include/dxsdk/d2d1effectauthor.h index 9b4dc7996a..36821c6742 100644 --- a/gfx/include/dxsdk/d2d1effectauthor.h +++ b/gfx/include/dxsdk/d2d1effectauthor.h @@ -16,7 +16,6 @@ #include #endif // #ifndef _D2D1_1_H_ - /// /// Function pointer that sets a property on an effect. /// @@ -48,7 +47,6 @@ typedef interface ID2D1TransformNode ID2D1TransformNode; #endif - /// /// Indicates what has changed since the last time the effect was asked to prepare /// to render. @@ -81,7 +79,6 @@ typedef enum D2D1_CHANGE_TYPE DEFINE_ENUM_FLAG_OPERATORS(D2D1_CHANGE_TYPE); - /// /// Indicates options for drawing using a pixel shader. /// @@ -105,7 +102,6 @@ typedef enum D2D1_PIXEL_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_PIXEL_OPTIONS); - /// /// Indicates options for drawing custom vertices set by transforms. /// @@ -140,7 +136,6 @@ typedef enum D2D1_VERTEX_OPTIONS DEFINE_ENUM_FLAG_OPERATORS(D2D1_VERTEX_OPTIONS); - /// /// Describes how a vertex buffer is to be managed. /// @@ -160,7 +155,6 @@ typedef enum D2D1_VERTEX_USAGE } D2D1_VERTEX_USAGE; - /// /// Describes a particular blend in the D2D1_BLEND_DESCRIPTION structure. /// @@ -175,7 +169,6 @@ typedef enum D2D1_BLEND_OPERATION } D2D1_BLEND_OPERATION; - /// /// Describes a particular blend in the D2D1_BLEND_DESCRIPTION structure. /// @@ -198,7 +191,6 @@ typedef enum D2D1_BLEND } D2D1_BLEND; - /// /// Allows a caller to control the channel depth of a stage in the rendering /// pipeline. @@ -212,7 +204,6 @@ typedef enum D2D1_CHANNEL_DEPTH } D2D1_CHANNEL_DEPTH; - /// /// Represents filtering modes transforms may select to use on their input textures. /// @@ -231,7 +222,6 @@ typedef enum D2D1_FILTER } D2D1_FILTER; - /// /// Defines capabilities of the underlying D3D device which may be queried using /// CheckFeatureSupport. @@ -244,7 +234,6 @@ typedef enum D2D1_FEATURE } D2D1_FEATURE; - /// /// Defines a property binding to a function. The name must match the property /// defined in the registration schema. @@ -269,7 +258,6 @@ typedef struct D2D1_PROPERTY_BINDING } D2D1_PROPERTY_BINDING; - /// /// This is used to define a resource texture when that resource texture is created. /// @@ -284,7 +272,6 @@ typedef struct D2D1_RESOURCE_TEXTURE_PROPERTIES } D2D1_RESOURCE_TEXTURE_PROPERTIES; - /// /// This defines a single element of the vertex layout. /// @@ -298,14 +285,12 @@ typedef struct D2D1_INPUT_ELEMENT_DESC } D2D1_INPUT_ELEMENT_DESC; - // // Set to alignedByteOffset within D2D1_INPUT_ELEMENT_DESC for elements that // immediately follow preceding elements in memory // #define D2D1_APPEND_ALIGNED_ELEMENT ( 0xffffffff ) - /// /// This defines the properties of a vertex buffer which uses the default vertex /// layout. @@ -319,7 +304,6 @@ typedef struct D2D1_VERTEX_BUFFER_PROPERTIES } D2D1_VERTEX_BUFFER_PROPERTIES; - /// /// This defines the input layout of vertices and the vertex shader which processes /// them. @@ -334,7 +318,6 @@ typedef struct D2D1_CUSTOM_VERTEX_BUFFER_PROPERTIES } D2D1_CUSTOM_VERTEX_BUFFER_PROPERTIES; - /// /// This defines the range of vertices from a vertex buffer to draw. /// @@ -345,7 +328,6 @@ typedef struct D2D1_VERTEX_RANGE } D2D1_VERTEX_RANGE; - /// /// Blend description which configures a blend transform object. /// @@ -361,7 +343,6 @@ typedef struct D2D1_BLEND_DESCRIPTION } D2D1_BLEND_DESCRIPTION; - /// /// Describes options transforms may select to use on their input textures. /// @@ -372,7 +353,6 @@ typedef struct D2D1_INPUT_DESCRIPTION } D2D1_INPUT_DESCRIPTION; - /// /// Indicates whether shader support for doubles is present on the underlying /// hardware. This may be populated using CheckFeatureSupport. @@ -383,7 +363,6 @@ typedef struct D2D1_FEATURE_DATA_DOUBLES } D2D1_FEATURE_DATA_DOUBLES; - /// /// Indicates support for features which are optional on D3D10 feature levels. This /// may be populated using CheckFeatureSupport. @@ -394,7 +373,6 @@ typedef struct D2D1_FEATURE_DATA_D3D10_X_HARDWARE_OPTIONS } D2D1_FEATURE_DATA_D3D10_X_HARDWARE_OPTIONS; - EXTERN_C CONST IID IID_ID2D1VertexBuffer; EXTERN_C CONST IID IID_ID2D1ResourceTexture; EXTERN_C CONST IID IID_ID2D1RenderInfo; @@ -415,10 +393,8 @@ EXTERN_C CONST IID IID_ID2D1BoundsAdjustmentTransform; EXTERN_C CONST IID IID_ID2D1EffectImpl; EXTERN_C CONST IID IID_ID2D1EffectContext; - #ifndef D2D_USE_C_DEFINITIONS - /// /// A transform uses this interface to write new vertices to a vertex buffer. /// @@ -434,7 +410,6 @@ interface DX_DECLARE_INTERFACE("9b8b1336-00a5-4668-92b7-ced5d8bf9b7b") ID2D1Vert ) PURE; }; // interface ID2D1VertexBuffer - interface DX_DECLARE_INTERFACE("688d15c3-02b0-438d-b13a-d1b44c32c39a") ID2D1ResourceTexture : public IUnknown { @@ -451,7 +426,6 @@ interface DX_DECLARE_INTERFACE("688d15c3-02b0-438d-b13a-d1b44c32c39a") ID2D1Reso ) PURE; }; // interface ID2D1ResourceTexture - /// /// A transform uses this interface to specify how to render a particular pass in /// D2D. @@ -492,7 +466,6 @@ interface DX_DECLARE_INTERFACE("519ae1bd-d19a-420d-b849-364f594776b7") ID2D1Rend ) PURE; }; // interface ID2D1RenderInfo - /// /// A transform uses this interface to specify how to render a particular pass using /// pixel and vertex shaders. @@ -545,7 +518,6 @@ interface DX_DECLARE_INTERFACE("693ce632-7f2f-45de-93fe-18d88b37aa21") ID2D1Draw ) PURE; }; // interface ID2D1DrawInfo - /// /// A transform uses this interface to specify how to render a particular pass using /// compute shader. @@ -577,7 +549,6 @@ interface DX_DECLARE_INTERFACE("5598b14b-9fd7-48b7-9bdb-8f0964eb38bc") ID2D1Comp ) PURE; }; // interface ID2D1ComputeInfo - /// /// A base object which can be inserted into a transform graph. /// @@ -591,7 +562,6 @@ interface DX_DECLARE_INTERFACE("b2efe1e7-729f-4102-949f-505fa21bf666") ID2D1Tran ) CONST PURE; }; // interface ID2D1TransformNode - /// /// The implementation of the actual graph. /// @@ -667,7 +637,6 @@ interface DX_DECLARE_INTERFACE("13d29038-c3e6-4034-9081-13b53a417992") ID2D1Tran ) PURE; }; // interface ID2D1TransformGraph - /// /// The interface implemented by a transform author. /// @@ -695,7 +664,6 @@ interface DX_DECLARE_INTERFACE("ef1a287d-342a-4f76-8fdb-da0d6ea9f92b") ID2D1Tran ) CONST PURE; }; // interface ID2D1Transform - /// /// The interface implemented by a transform author to provide a GPU-based effect. /// @@ -707,7 +675,6 @@ interface DX_DECLARE_INTERFACE("36bfdcb6-9739-435d-a30d-a653beff6a6f") ID2D1Draw ) PURE; }; // interface ID2D1DrawTransform - /// /// The interface implemented by a transform author to provide a Compute Shader /// based effect. @@ -727,7 +694,6 @@ interface DX_DECLARE_INTERFACE("0d85573c-01e3-4f7d-bfd9-0d60608bf3c3") ID2D1Comp ) PURE; }; // interface ID2D1ComputeTransform - /// /// The interface implemented by a transform author to indicate that it should /// receive an analysis result callback. @@ -741,7 +707,6 @@ interface DX_DECLARE_INTERFACE("0359dc30-95e6-4568-9055-27720d130e93") ID2D1Anal ) PURE; }; // interface ID2D1AnalysisTransform - /// /// The interface implemented by a transform author to provide a CPU based source /// effect. @@ -760,7 +725,6 @@ interface DX_DECLARE_INTERFACE("db1800dd-0c34-4cf9-be90-31cc0a5653e1") ID2D1Sour ) PURE; }; // interface ID2D1SourceTransform - /// /// Base interface for built-in transforms on which precision and caching may be /// controlled. @@ -784,7 +748,6 @@ interface DX_DECLARE_INTERFACE("1a799d8a-69f7-4e4c-9fed-437ccc6684cc") ID2D1Conc ) PURE; }; // interface ID2D1ConcreteTransform - /// /// An effect uses this interface to configure a blending operation. /// @@ -800,7 +763,6 @@ interface DX_DECLARE_INTERFACE("63ac0b32-ba44-450f-8806-7f4ca1ff2f1b") ID2D1Blen ) CONST PURE; }; // interface ID2D1BlendTransform - /// /// An effect uses this interface to configure border generation. /// @@ -822,7 +784,6 @@ interface DX_DECLARE_INTERFACE("4998735c-3a19-473c-9781-656847e3a347") ID2D1Bord ) CONST PURE; }; // interface ID2D1BorderTransform - /// /// An effect uses this interface to offset an image without inserting a rendering /// pass. @@ -838,7 +799,6 @@ interface DX_DECLARE_INTERFACE("3fe6adea-7643-4f53-bd14-a0ce63f24042") ID2D1Offs ) CONST PURE; }; // interface ID2D1OffsetTransform - /// /// An effect uses this interface to alter the image rectangle of its input. /// @@ -854,7 +814,6 @@ interface DX_DECLARE_INTERFACE("90f732e2-5092-4606-a819-8651970baccd") ID2D1Boun ) CONST PURE; }; // interface ID2D1BoundsAdjustmentTransform - /// /// This is the interface implemented by an effect author, along with the /// constructor and registration information. @@ -888,7 +847,6 @@ interface DX_DECLARE_INTERFACE("a248fd3f-3e6c-4e63-9f03-7f68ecc91db9") ID2D1Effe ) PURE; }; // interface ID2D1EffectImpl - /// /// The internal context handed to effect authors to create transforms from effects /// and any other operation tied to context which is not useful to the application @@ -1032,14 +990,10 @@ interface DX_DECLARE_INTERFACE("3d9f916b-27dc-4ad7-b4f1-64945340f563") ID2D1Effe ) CONST PURE; }; // interface ID2D1EffectContext - - #endif - #ifdef D2D_USE_C_DEFINITIONS - typedef interface ID2D1VertexBuffer ID2D1VertexBuffer; typedef interface ID2D1ResourceTexture ID2D1ResourceTexture; diff --git a/gfx/include/dxsdk/d2d1effectauthor_1.h b/gfx/include/dxsdk/d2d1effectauthor_1.h index d1da35e889..9ee6167f8f 100644 --- a/gfx/include/dxsdk/d2d1effectauthor_1.h +++ b/gfx/include/dxsdk/d2d1effectauthor_1.h @@ -22,10 +22,8 @@ EXTERN_C CONST IID IID_ID2D1EffectContext1; EXTERN_C CONST IID IID_ID2D1EffectContext2; - #ifndef D2D_USE_C_DEFINITIONS - /// /// The internal context handed to effect authors to create transforms from effects /// and any other operation tied to context which is not useful to the application @@ -48,7 +46,6 @@ interface DX_DECLARE_INTERFACE("84ab595a-fc81-4546-bacd-e8ef4d8abe7a") ID2D1Effe ) PURE; }; // interface ID2D1EffectContext1 - #if NTDDI_VERSION >= NTDDI_WIN10_RS2 /// @@ -78,15 +75,12 @@ interface DX_DECLARE_INTERFACE("577ad2a0-9fc7-4dda-8b18-dab810140052") ID2D1Effe ) PURE; }; // interface ID2D1EffectContext2 - #endif #endif - #ifdef D2D_USE_C_DEFINITIONS - typedef interface ID2D1EffectContext1 ID2D1EffectContext1; #if NTDDI_VERSION >= NTDDI_WIN10_RS2 diff --git a/gfx/include/dxsdk/d2d1effects.h b/gfx/include/dxsdk/d2d1effects.h index 0903c91e06..225119e921 100644 --- a/gfx/include/dxsdk/d2d1effects.h +++ b/gfx/include/dxsdk/d2d1effects.h @@ -12,7 +12,6 @@ #ifndef _D2D1_EFFECTS_ #define _D2D1_EFFECTS_ - /*#include */ @@ -62,7 +61,6 @@ DEFINE_GUID(CLSID_D2D1Tile, 0xB0784138, 0x3B76, 0x4bc5, 0xB1 DEFINE_GUID(CLSID_D2D1Turbulence, 0xCF2BB6AE, 0x889A, 0x4ad7, 0xBA, 0x29, 0xA2, 0xFD, 0x73, 0x2C, 0x9F, 0xC9); DEFINE_GUID(CLSID_D2D1UnPremultiply, 0xfb9ac489, 0xad8d, 0x41ed, 0x99, 0x99, 0xbb, 0x63, 0x47, 0xd1, 0x10, 0xf7); - /// /// Specifies how the Crop effect handles the crop rectangle falling on fractional /// pixel coordinates. @@ -75,7 +73,6 @@ typedef enum D2D1_BORDER_MODE } D2D1_BORDER_MODE; - /// /// Specifies the color channel the Displacement map effect extracts the intensity /// from and uses it to spatially displace the image in the X or Y direction. @@ -90,7 +87,6 @@ typedef enum D2D1_CHANNEL_SELECTOR } D2D1_CHANNEL_SELECTOR; - /// /// Speficies whether a flip and/or rotation operation should be performed by the /// Bitmap source effect @@ -109,7 +105,6 @@ typedef enum D2D1_BITMAPSOURCE_ORIENTATION } D2D1_BITMAPSOURCE_ORIENTATION; - /// /// The enumeration of the Gaussian Blur effect's top level properties. /// @@ -146,7 +141,6 @@ typedef enum D2D1_GAUSSIANBLUR_OPTIMIZATION } D2D1_GAUSSIANBLUR_OPTIMIZATION; - /// /// The enumeration of the Directional Blur effect's top level properties. /// @@ -189,7 +183,6 @@ typedef enum D2D1_DIRECTIONALBLUR_OPTIMIZATION } D2D1_DIRECTIONALBLUR_OPTIMIZATION; - /// /// The enumeration of the Shadow effect's top level properties. /// @@ -226,7 +219,6 @@ typedef enum D2D1_SHADOW_OPTIMIZATION } D2D1_SHADOW_OPTIMIZATION; - /// /// The enumeration of the Blend effect's top level properties. /// @@ -274,7 +266,6 @@ typedef enum D2D1_BLEND_MODE } D2D1_BLEND_MODE; - /// /// The enumeration of the Saturation effect's top level properties. /// @@ -290,7 +281,6 @@ typedef enum D2D1_SATURATION_PROP } D2D1_SATURATION_PROP; - /// /// The enumeration of the Hue Rotation effect's top level properties. /// @@ -306,7 +296,6 @@ typedef enum D2D1_HUEROTATION_PROP } D2D1_HUEROTATION_PROP; - /// /// The enumeration of the Color Matrix effect's top level properties. /// @@ -342,7 +331,6 @@ typedef enum D2D1_COLORMATRIX_ALPHA_MODE } D2D1_COLORMATRIX_ALPHA_MODE; - /// /// The enumeration of the Bitmap Source effect's top level properties. /// @@ -407,7 +395,6 @@ typedef enum D2D1_BITMAPSOURCE_ALPHA_MODE } D2D1_BITMAPSOURCE_ALPHA_MODE; - /// /// The enumeration of the Composite effect's top level properties. /// @@ -423,7 +410,6 @@ typedef enum D2D1_COMPOSITE_PROP } D2D1_COMPOSITE_PROP; - /// /// The enumeration of the 3D Transform effect's top level properties. /// @@ -462,7 +448,6 @@ typedef enum D2D1_3DTRANSFORM_INTERPOLATION_MODE } D2D1_3DTRANSFORM_INTERPOLATION_MODE; - /// /// The enumeration of the 3D Perspective Transform effect's top level properties. /// @@ -531,7 +516,6 @@ typedef enum D2D1_3DPERSPECTIVETRANSFORM_INTERPOLATION_MODE } D2D1_3DPERSPECTIVETRANSFORM_INTERPOLATION_MODE; - /// /// The enumeration of the 2D Affine Transform effect's top level properties. /// @@ -577,7 +561,6 @@ typedef enum D2D1_2DAFFINETRANSFORM_INTERPOLATION_MODE } D2D1_2DAFFINETRANSFORM_INTERPOLATION_MODE; - /// /// The enumeration of the DPI Compensation effect's top level properties. /// @@ -617,7 +600,6 @@ typedef enum D2D1_DPICOMPENSATION_INTERPOLATION_MODE } D2D1_DPICOMPENSATION_INTERPOLATION_MODE; - /// /// The enumeration of the Scale effect's top level properties. /// @@ -669,7 +651,6 @@ typedef enum D2D1_SCALE_INTERPOLATION_MODE } D2D1_SCALE_INTERPOLATION_MODE; - /// /// The enumeration of the Turbulence effect's top level properties. /// @@ -729,7 +710,6 @@ typedef enum D2D1_TURBULENCE_NOISE } D2D1_TURBULENCE_NOISE; - /// /// The enumeration of the Displacement Map effect's top level properties. /// @@ -757,7 +737,6 @@ typedef enum D2D1_DISPLACEMENTMAP_PROP } D2D1_DISPLACEMENTMAP_PROP; - /// /// The enumeration of the Color Management effect's top level properties. /// @@ -820,7 +799,6 @@ typedef enum D2D1_COLORMANAGEMENT_QUALITY } D2D1_COLORMANAGEMENT_QUALITY; - /// /// Specifies which ICC rendering intent the Color management effect should use. /// @@ -834,7 +812,6 @@ typedef enum D2D1_COLORMANAGEMENT_RENDERING_INTENT } D2D1_COLORMANAGEMENT_RENDERING_INTENT; - /// /// The enumeration of the Histogram effect's top level properties. /// @@ -862,7 +839,6 @@ typedef enum D2D1_HISTOGRAM_PROP } D2D1_HISTOGRAM_PROP; - /// /// The enumeration of the Point-Specular effect's top level properties. /// @@ -926,7 +902,6 @@ typedef enum D2D1_POINTSPECULAR_SCALE_MODE } D2D1_POINTSPECULAR_SCALE_MODE; - /// /// The enumeration of the Spot-Specular effect's top level properties. /// @@ -1008,7 +983,6 @@ typedef enum D2D1_SPOTSPECULAR_SCALE_MODE } D2D1_SPOTSPECULAR_SCALE_MODE; - /// /// The enumeration of the Distant-Specular effect's top level properties. /// @@ -1078,7 +1052,6 @@ typedef enum D2D1_DISTANTSPECULAR_SCALE_MODE } D2D1_DISTANTSPECULAR_SCALE_MODE; - /// /// The enumeration of the Point-Diffuse effect's top level properties. /// @@ -1136,7 +1109,6 @@ typedef enum D2D1_POINTDIFFUSE_SCALE_MODE } D2D1_POINTDIFFUSE_SCALE_MODE; - /// /// The enumeration of the Spot-Diffuse effect's top level properties. /// @@ -1212,7 +1184,6 @@ typedef enum D2D1_SPOTDIFFUSE_SCALE_MODE } D2D1_SPOTDIFFUSE_SCALE_MODE; - /// /// The enumeration of the Distant-Diffuse effect's top level properties. /// @@ -1276,7 +1247,6 @@ typedef enum D2D1_DISTANTDIFFUSE_SCALE_MODE } D2D1_DISTANTDIFFUSE_SCALE_MODE; - /// /// The enumeration of the Flood effect's top level properties. /// @@ -1292,7 +1262,6 @@ typedef enum D2D1_FLOOD_PROP } D2D1_FLOOD_PROP; - /// /// The enumeration of the Linear Transfer effect's top level properties. /// @@ -1380,7 +1349,6 @@ typedef enum D2D1_LINEARTRANSFER_PROP } D2D1_LINEARTRANSFER_PROP; - /// /// The enumeration of the Gamma Transfer effect's top level properties. /// @@ -1492,7 +1460,6 @@ typedef enum D2D1_GAMMATRANSFER_PROP } D2D1_GAMMATRANSFER_PROP; - /// /// The enumeration of the Table Transfer effect's top level properties. /// @@ -1556,7 +1523,6 @@ typedef enum D2D1_TABLETRANSFER_PROP } D2D1_TABLETRANSFER_PROP; - /// /// The enumeration of the Discrete Transfer effect's top level properties. /// @@ -1620,7 +1586,6 @@ typedef enum D2D1_DISCRETETRANSFER_PROP } D2D1_DISCRETETRANSFER_PROP; - /// /// The enumeration of the Convolve Matrix effect's top level properties. /// @@ -1708,7 +1673,6 @@ typedef enum D2D1_CONVOLVEMATRIX_SCALE_MODE } D2D1_CONVOLVEMATRIX_SCALE_MODE; - /// /// The enumeration of the Brightness effect's top level properties. /// @@ -1730,7 +1694,6 @@ typedef enum D2D1_BRIGHTNESS_PROP } D2D1_BRIGHTNESS_PROP; - /// /// The enumeration of the Arithmetic Composite effect's top level properties. /// @@ -1752,7 +1715,6 @@ typedef enum D2D1_ARITHMETICCOMPOSITE_PROP } D2D1_ARITHMETICCOMPOSITE_PROP; - /// /// The enumeration of the Crop effect's top level properties. /// @@ -1774,7 +1736,6 @@ typedef enum D2D1_CROP_PROP } D2D1_CROP_PROP; - /// /// The enumeration of the Border effect's top level properties. /// @@ -1796,7 +1757,6 @@ typedef enum D2D1_BORDER_PROP } D2D1_BORDER_PROP; - /// /// The edge mode for the Border effect. /// @@ -1809,7 +1769,6 @@ typedef enum D2D1_BORDER_EDGE_MODE } D2D1_BORDER_EDGE_MODE; - /// /// The enumeration of the Morphology effect's top level properties. /// @@ -1845,7 +1804,6 @@ typedef enum D2D1_MORPHOLOGY_MODE } D2D1_MORPHOLOGY_MODE; - /// /// The enumeration of the Tile effect's top level properties. /// @@ -1861,7 +1819,6 @@ typedef enum D2D1_TILE_PROP } D2D1_TILE_PROP; - /// /// The enumeration of the Atlas effect's top level properties. /// @@ -1883,7 +1840,6 @@ typedef enum D2D1_ATLAS_PROP } D2D1_ATLAS_PROP; - /// /// The enumeration of the Opacity Metadata effect's top level properties. /// @@ -1899,7 +1855,6 @@ typedef enum D2D1_OPACITYMETADATA_PROP } D2D1_OPACITYMETADATA_PROP; - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ diff --git a/gfx/include/dxsdk/d2d1effects_1.h b/gfx/include/dxsdk/d2d1effects_1.h index bbeee6fb07..083834338c 100644 --- a/gfx/include/dxsdk/d2d1effects_1.h +++ b/gfx/include/dxsdk/d2d1effects_1.h @@ -75,7 +75,6 @@ typedef enum D2D1_YCBCR_INTERPOLATION_MODE } D2D1_YCBCR_INTERPOLATION_MODE; - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ diff --git a/gfx/include/dxsdk/d2d1effects_2.h b/gfx/include/dxsdk/d2d1effects_2.h index a8083b7f15..64944ea15d 100644 --- a/gfx/include/dxsdk/d2d1effects_2.h +++ b/gfx/include/dxsdk/d2d1effects_2.h @@ -71,7 +71,6 @@ typedef enum D2D1_CONTRAST_PROP } D2D1_CONTRAST_PROP; - /// /// The enumeration of the RgbToHue effect's top level properties. /// @@ -95,7 +94,6 @@ typedef enum D2D1_RGBTOHUE_OUTPUT_COLOR_SPACE } D2D1_RGBTOHUE_OUTPUT_COLOR_SPACE; - /// /// The enumeration of the HueToRgb effect's top level properties. /// @@ -119,7 +117,6 @@ typedef enum D2D1_HUETORGB_INPUT_COLOR_SPACE } D2D1_HUETORGB_INPUT_COLOR_SPACE; - /// /// The enumeration of the Chroma Key effect's top level properties. /// @@ -153,7 +150,6 @@ typedef enum D2D1_CHROMAKEY_PROP } D2D1_CHROMAKEY_PROP; - /// /// The enumeration of the Emboss effect's top level properties. /// @@ -175,7 +171,6 @@ typedef enum D2D1_EMBOSS_PROP } D2D1_EMBOSS_PROP; - /// /// The enumeration of the Exposure effect's top level properties. /// @@ -191,7 +186,6 @@ typedef enum D2D1_EXPOSURE_PROP } D2D1_EXPOSURE_PROP; - /// /// The enumeration of the Posterize effect's top level properties. /// @@ -219,7 +213,6 @@ typedef enum D2D1_POSTERIZE_PROP } D2D1_POSTERIZE_PROP; - /// /// The enumeration of the Sepia effect's top level properties. /// @@ -241,7 +234,6 @@ typedef enum D2D1_SEPIA_PROP } D2D1_SEPIA_PROP; - /// /// The enumeration of the Sharpen effect's top level properties. /// @@ -263,7 +255,6 @@ typedef enum D2D1_SHARPEN_PROP } D2D1_SHARPEN_PROP; - /// /// The enumeration of the Straighten effect's top level properties. /// @@ -302,7 +293,6 @@ typedef enum D2D1_STRAIGHTEN_SCALE_MODE } D2D1_STRAIGHTEN_SCALE_MODE; - /// /// The enumeration of the Temperature And Tint effect's top level properties. /// @@ -324,7 +314,6 @@ typedef enum D2D1_TEMPERATUREANDTINT_PROP } D2D1_TEMPERATUREANDTINT_PROP; - /// /// The enumeration of the Vignette effect's top level properties. /// @@ -352,7 +341,6 @@ typedef enum D2D1_VIGNETTE_PROP } D2D1_VIGNETTE_PROP; - /// /// The enumeration of the Edge Detection effect's top level properties. /// @@ -400,7 +388,6 @@ typedef enum D2D1_EDGEDETECTION_MODE } D2D1_EDGEDETECTION_MODE; - /// /// The enumeration of the Highlights and Shadows effect's top level properties. /// @@ -448,7 +435,6 @@ typedef enum D2D1_HIGHLIGHTSANDSHADOWS_INPUT_GAMMA } D2D1_HIGHLIGHTSANDSHADOWS_INPUT_GAMMA; - /// /// The enumeration of the Lookup Table 3D effect's top level properties. /// @@ -470,7 +456,6 @@ typedef enum D2D1_LOOKUPTABLE3D_PROP } D2D1_LOOKUPTABLE3D_PROP; - #if NTDDI_VERSION >= NTDDI_WIN10_RS1 /// @@ -488,7 +473,6 @@ typedef enum D2D1_OPACITY_PROP } D2D1_OPACITY_PROP; - /// /// The enumeration of the Cross Fade effect's top level properties. /// @@ -504,7 +488,6 @@ typedef enum D2D1_CROSSFADE_PROP } D2D1_CROSSFADE_PROP; - /// /// The enumeration of the Tint effect's top level properties. /// @@ -526,7 +509,6 @@ typedef enum D2D1_TINT_PROP } D2D1_TINT_PROP; - #endif // #if NTDDI_VERSION >= NTDDI_WIN10_RS1 /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ diff --git a/gfx/include/dxsdk/d2d1helper.h b/gfx/include/dxsdk/d2d1helper.h index 46bcbd12e7..d18403429a 100644 --- a/gfx/include/dxsdk/d2d1helper.h +++ b/gfx/include/dxsdk/d2d1helper.h @@ -809,7 +809,6 @@ namespace D2D1 return Translation(SizeF(x, y)); } - static COM_DECLSPEC_NOTHROW D2D1FORCEINLINE diff --git a/gfx/include/dxsdk/d2d1svg.h b/gfx/include/dxsdk/d2d1svg.h index 5611d3cdb1..6abb0b9777 100644 --- a/gfx/include/dxsdk/d2d1svg.h +++ b/gfx/include/dxsdk/d2d1svg.h @@ -72,7 +72,6 @@ typedef enum D2D1_SVG_PAINT_TYPE } D2D1_SVG_PAINT_TYPE; - /// /// Specifies the units for an SVG length. /// @@ -92,7 +91,6 @@ typedef enum D2D1_SVG_LENGTH_UNITS } D2D1_SVG_LENGTH_UNITS; - /// /// Specifies a value for the SVG display property. /// @@ -112,7 +110,6 @@ typedef enum D2D1_SVG_DISPLAY } D2D1_SVG_DISPLAY; - /// /// Specifies a value for the SVG visibility property. /// @@ -132,7 +129,6 @@ typedef enum D2D1_SVG_VISIBILITY } D2D1_SVG_VISIBILITY; - /// /// Specifies a value for the SVG overflow property. /// @@ -152,7 +148,6 @@ typedef enum D2D1_SVG_OVERFLOW } D2D1_SVG_OVERFLOW; - /// /// Specifies a value for the SVG stroke-linecap property. /// @@ -177,7 +172,6 @@ typedef enum D2D1_SVG_LINE_CAP } D2D1_SVG_LINE_CAP; - /// /// Specifies a value for the SVG stroke-linejoin property. /// @@ -203,7 +197,6 @@ typedef enum D2D1_SVG_LINE_JOIN } D2D1_SVG_LINE_JOIN; - /// /// The alignment portion of the SVG preserveAspectRatio attribute. /// @@ -263,7 +256,6 @@ typedef enum D2D1_SVG_ASPECT_ALIGN } D2D1_SVG_ASPECT_ALIGN; - /// /// The meetOrSlice portion of the SVG preserveAspectRatio attribute. /// @@ -285,7 +277,6 @@ typedef enum D2D1_SVG_ASPECT_SCALING } D2D1_SVG_ASPECT_SCALING; - /// /// Represents a path commmand. Each command may reference floats from the segment /// data. Commands ending in _ABSOLUTE interpret data as absolute coordinate. @@ -407,7 +398,6 @@ typedef enum D2D1_SVG_PATH_COMMAND } D2D1_SVG_PATH_COMMAND; - /// /// Defines the coordinate system used for SVG gradient or clipPath elements. /// @@ -427,7 +417,6 @@ typedef enum D2D1_SVG_UNIT_TYPE } D2D1_SVG_UNIT_TYPE; - /// /// Defines the type of SVG string attribute to set or get. /// @@ -451,7 +440,6 @@ typedef enum D2D1_SVG_ATTRIBUTE_STRING_TYPE } D2D1_SVG_ATTRIBUTE_STRING_TYPE; - /// /// Defines the type of SVG POD attribute to set or get. /// @@ -531,7 +519,6 @@ typedef enum D2D1_SVG_ATTRIBUTE_POD_TYPE } D2D1_SVG_ATTRIBUTE_POD_TYPE; - /// /// Represents an SVG length. /// @@ -542,7 +529,6 @@ typedef struct D2D1_SVG_LENGTH } D2D1_SVG_LENGTH; - /// /// Represents all SVG preserveAspectRatio settings. /// @@ -568,7 +554,6 @@ typedef struct D2D1_SVG_PRESERVE_ASPECT_RATIO } D2D1_SVG_PRESERVE_ASPECT_RATIO; - /// /// Represents an SVG viewBox. /// @@ -581,7 +566,6 @@ typedef struct D2D1_SVG_VIEWBOX } D2D1_SVG_VIEWBOX; - EXTERN_C CONST IID IID_ID2D1SvgAttribute; EXTERN_C CONST IID IID_ID2D1SvgPaint; EXTERN_C CONST IID IID_ID2D1SvgStrokeDashArray; @@ -590,7 +574,6 @@ EXTERN_C CONST IID IID_ID2D1SvgPathData; EXTERN_C CONST IID IID_ID2D1SvgElement; EXTERN_C CONST IID IID_ID2D1SvgDocument; - #ifndef D2D_USE_C_DEFINITIONS #if NTDDI_VERSION >= NTDDI_WIN10_RS2 @@ -618,7 +601,6 @@ interface DX_DECLARE_INTERFACE("c9cdb0dd-f8c9-4e70-b7c2-301c80292c5e") ID2D1SvgA ) PURE; }; // interface ID2D1SvgAttribute - /// /// Interface describing an SVG 'fill' or 'stroke' value. /// @@ -693,7 +675,6 @@ interface DX_DECLARE_INTERFACE("d59bab0a-68a2-455b-a5dc-9eb2854e2490") ID2D1SvgP } }; // interface ID2D1SvgPaint - /// /// Interface describing an SVG 'stroke-dasharray' value. /// @@ -767,7 +748,6 @@ interface DX_DECLARE_INTERFACE("f1c0ca52-92a3-4f00-b4ce-f35691efd9d9") ID2D1SvgS ) PURE; }; // interface ID2D1SvgStrokeDashArray - /// /// Interface describing an SVG 'points' value in a 'polyline' or 'polygon' element. /// @@ -816,7 +796,6 @@ interface DX_DECLARE_INTERFACE("9dbe4c0d-3572-4dd9-9825-5530813bb712") ID2D1SvgP ) PURE; }; // interface ID2D1SvgPointCollection - /// /// Interface describing SVG path data. Path data can be set as the 'd' attribute on /// a 'path' element. @@ -924,7 +903,6 @@ interface DX_DECLARE_INTERFACE("c095e4f4-bb98-43d6-9745-4d1b84ec9888") ID2D1SvgP ) PURE; }; // interface ID2D1SvgPathData - /// /// Interface for all SVG elements. /// @@ -1679,7 +1657,6 @@ interface DX_DECLARE_INTERFACE("ac7b67a6-183e-49c1-a823-0ebe40b0db29") ID2D1SvgE } }; // interface ID2D1SvgElement - interface DX_DECLARE_INTERFACE("86b88e4d-afa4-4d7b-88e4-68a51c4a0aec") ID2D1SvgDocument : public ID2D1Resource { @@ -1814,19 +1791,14 @@ interface DX_DECLARE_INTERFACE("86b88e4d-afa4-4d7b-88e4-68a51c4a0aec") ID2D1SvgD } }; // interface ID2D1SvgDocument - #endif #endif - #ifdef D2D_USE_C_DEFINITIONS - #endif - - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ #endif // #ifndef _D2D1_SVG_ diff --git a/gfx/include/dxsdk/d2derr.h b/gfx/include/dxsdk/d2derr.h index 86924be4e1..de94ec53f8 100644 --- a/gfx/include/dxsdk/d2derr.h +++ b/gfx/include/dxsdk/d2derr.h @@ -23,7 +23,6 @@ #define MAKE_D2DHR_ERR( code )\ MAKE_D2DHR( 1, code ) - //+---------------------------------------------------------------------------- // // D2D error codes @@ -53,13 +52,11 @@ // #define D2DERR_INSUFFICIENT_BUFFER HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) - // // The file specified was not found. // #define D2DERR_FILE_NOT_FOUND HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) - #ifndef D2DERR_WRONG_STATE // diff --git a/gfx/include/dxsdk/d3d10.h b/gfx/include/dxsdk/d3d10.h index c0d91ad9ec..b6bdd03864 100644 --- a/gfx/include/dxsdk/d3d10.h +++ b/gfx/include/dxsdk/d3d10.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,168 +46,144 @@ typedef interface ID3D10DeviceChild ID3D10DeviceChild; #endif /* __ID3D10DeviceChild_FWD_DEFINED__ */ - #ifndef __ID3D10DepthStencilState_FWD_DEFINED__ #define __ID3D10DepthStencilState_FWD_DEFINED__ typedef interface ID3D10DepthStencilState ID3D10DepthStencilState; #endif /* __ID3D10DepthStencilState_FWD_DEFINED__ */ - #ifndef __ID3D10BlendState_FWD_DEFINED__ #define __ID3D10BlendState_FWD_DEFINED__ typedef interface ID3D10BlendState ID3D10BlendState; #endif /* __ID3D10BlendState_FWD_DEFINED__ */ - #ifndef __ID3D10RasterizerState_FWD_DEFINED__ #define __ID3D10RasterizerState_FWD_DEFINED__ typedef interface ID3D10RasterizerState ID3D10RasterizerState; #endif /* __ID3D10RasterizerState_FWD_DEFINED__ */ - #ifndef __ID3D10Resource_FWD_DEFINED__ #define __ID3D10Resource_FWD_DEFINED__ typedef interface ID3D10Resource ID3D10Resource; #endif /* __ID3D10Resource_FWD_DEFINED__ */ - #ifndef __ID3D10Buffer_FWD_DEFINED__ #define __ID3D10Buffer_FWD_DEFINED__ typedef interface ID3D10Buffer ID3D10Buffer; #endif /* __ID3D10Buffer_FWD_DEFINED__ */ - #ifndef __ID3D10Texture1D_FWD_DEFINED__ #define __ID3D10Texture1D_FWD_DEFINED__ typedef interface ID3D10Texture1D ID3D10Texture1D; #endif /* __ID3D10Texture1D_FWD_DEFINED__ */ - #ifndef __ID3D10Texture2D_FWD_DEFINED__ #define __ID3D10Texture2D_FWD_DEFINED__ typedef interface ID3D10Texture2D ID3D10Texture2D; #endif /* __ID3D10Texture2D_FWD_DEFINED__ */ - #ifndef __ID3D10Texture3D_FWD_DEFINED__ #define __ID3D10Texture3D_FWD_DEFINED__ typedef interface ID3D10Texture3D ID3D10Texture3D; #endif /* __ID3D10Texture3D_FWD_DEFINED__ */ - #ifndef __ID3D10View_FWD_DEFINED__ #define __ID3D10View_FWD_DEFINED__ typedef interface ID3D10View ID3D10View; #endif /* __ID3D10View_FWD_DEFINED__ */ - #ifndef __ID3D10ShaderResourceView_FWD_DEFINED__ #define __ID3D10ShaderResourceView_FWD_DEFINED__ typedef interface ID3D10ShaderResourceView ID3D10ShaderResourceView; #endif /* __ID3D10ShaderResourceView_FWD_DEFINED__ */ - #ifndef __ID3D10RenderTargetView_FWD_DEFINED__ #define __ID3D10RenderTargetView_FWD_DEFINED__ typedef interface ID3D10RenderTargetView ID3D10RenderTargetView; #endif /* __ID3D10RenderTargetView_FWD_DEFINED__ */ - #ifndef __ID3D10DepthStencilView_FWD_DEFINED__ #define __ID3D10DepthStencilView_FWD_DEFINED__ typedef interface ID3D10DepthStencilView ID3D10DepthStencilView; #endif /* __ID3D10DepthStencilView_FWD_DEFINED__ */ - #ifndef __ID3D10VertexShader_FWD_DEFINED__ #define __ID3D10VertexShader_FWD_DEFINED__ typedef interface ID3D10VertexShader ID3D10VertexShader; #endif /* __ID3D10VertexShader_FWD_DEFINED__ */ - #ifndef __ID3D10GeometryShader_FWD_DEFINED__ #define __ID3D10GeometryShader_FWD_DEFINED__ typedef interface ID3D10GeometryShader ID3D10GeometryShader; #endif /* __ID3D10GeometryShader_FWD_DEFINED__ */ - #ifndef __ID3D10PixelShader_FWD_DEFINED__ #define __ID3D10PixelShader_FWD_DEFINED__ typedef interface ID3D10PixelShader ID3D10PixelShader; #endif /* __ID3D10PixelShader_FWD_DEFINED__ */ - #ifndef __ID3D10InputLayout_FWD_DEFINED__ #define __ID3D10InputLayout_FWD_DEFINED__ typedef interface ID3D10InputLayout ID3D10InputLayout; #endif /* __ID3D10InputLayout_FWD_DEFINED__ */ - #ifndef __ID3D10SamplerState_FWD_DEFINED__ #define __ID3D10SamplerState_FWD_DEFINED__ typedef interface ID3D10SamplerState ID3D10SamplerState; #endif /* __ID3D10SamplerState_FWD_DEFINED__ */ - #ifndef __ID3D10Asynchronous_FWD_DEFINED__ #define __ID3D10Asynchronous_FWD_DEFINED__ typedef interface ID3D10Asynchronous ID3D10Asynchronous; #endif /* __ID3D10Asynchronous_FWD_DEFINED__ */ - #ifndef __ID3D10Query_FWD_DEFINED__ #define __ID3D10Query_FWD_DEFINED__ typedef interface ID3D10Query ID3D10Query; #endif /* __ID3D10Query_FWD_DEFINED__ */ - #ifndef __ID3D10Predicate_FWD_DEFINED__ #define __ID3D10Predicate_FWD_DEFINED__ typedef interface ID3D10Predicate ID3D10Predicate; #endif /* __ID3D10Predicate_FWD_DEFINED__ */ - #ifndef __ID3D10Counter_FWD_DEFINED__ #define __ID3D10Counter_FWD_DEFINED__ typedef interface ID3D10Counter ID3D10Counter; #endif /* __ID3D10Counter_FWD_DEFINED__ */ - #ifndef __ID3D10Device_FWD_DEFINED__ #define __ID3D10Device_FWD_DEFINED__ typedef interface ID3D10Device ID3D10Device; #endif /* __ID3D10Device_FWD_DEFINED__ */ - #ifndef __ID3D10Multithread_FWD_DEFINED__ #define __ID3D10Multithread_FWD_DEFINED__ typedef interface ID3D10Multithread ID3D10Multithread; #endif /* __ID3D10Multithread_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -222,7 +194,6 @@ typedef interface ID3D10Multithread ID3D10Multithread; extern "C"{ #endif - /* interface __MIDL_itf_d3d10_0000_0000 */ /* [local] */ @@ -807,9 +778,6 @@ typedef struct D3D10_BOX UINT back; } D3D10_BOX; - - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0000_v0_0_s_ifspec; @@ -819,7 +787,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0000_v0_0_s_ifspec; /* interface ID3D10DeviceChild */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10DeviceChild; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -917,7 +884,6 @@ EXTERN_C const IID IID_ID3D10DeviceChild; #ifdef COBJMACROS - #define ID3D10DeviceChild_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -927,7 +893,6 @@ EXTERN_C const IID IID_ID3D10DeviceChild; #define ID3D10DeviceChild_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10DeviceChild_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -942,15 +907,10 @@ EXTERN_C const IID IID_ID3D10DeviceChild; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10DeviceChild_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0001 */ /* [local] */ @@ -1007,8 +967,6 @@ typedef struct D3D10_DEPTH_STENCIL_DESC D3D10_DEPTH_STENCILOP_DESC BackFace; } D3D10_DEPTH_STENCIL_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0001_v0_0_s_ifspec; @@ -1018,7 +976,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0001_v0_0_s_ifspec; /* interface ID3D10DepthStencilState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10DepthStencilState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1099,7 +1056,6 @@ EXTERN_C const IID IID_ID3D10DepthStencilState; #ifdef COBJMACROS - #define ID3D10DepthStencilState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1109,7 +1065,6 @@ EXTERN_C const IID IID_ID3D10DepthStencilState; #define ID3D10DepthStencilState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10DepthStencilState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1122,21 +1077,15 @@ EXTERN_C const IID IID_ID3D10DepthStencilState; #define ID3D10DepthStencilState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10DepthStencilState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10DepthStencilState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0002 */ /* [local] */ @@ -1195,8 +1144,6 @@ typedef struct D3D10_BLEND_DESC UINT8 RenderTargetWriteMask[ 8 ]; } D3D10_BLEND_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0002_v0_0_s_ifspec; @@ -1206,7 +1153,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0002_v0_0_s_ifspec; /* interface ID3D10BlendState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10BlendState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1287,7 +1233,6 @@ EXTERN_C const IID IID_ID3D10BlendState; #ifdef COBJMACROS - #define ID3D10BlendState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1297,7 +1242,6 @@ EXTERN_C const IID IID_ID3D10BlendState; #define ID3D10BlendState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10BlendState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1310,21 +1254,15 @@ EXTERN_C const IID IID_ID3D10BlendState; #define ID3D10BlendState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10BlendState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10BlendState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0003 */ /* [local] */ @@ -1342,8 +1280,6 @@ typedef struct D3D10_RASTERIZER_DESC BOOL AntialiasedLineEnable; } D3D10_RASTERIZER_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0003_v0_0_s_ifspec; @@ -1353,7 +1289,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0003_v0_0_s_ifspec; /* interface ID3D10RasterizerState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10RasterizerState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1434,7 +1369,6 @@ EXTERN_C const IID IID_ID3D10RasterizerState; #ifdef COBJMACROS - #define ID3D10RasterizerState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1444,7 +1378,6 @@ EXTERN_C const IID IID_ID3D10RasterizerState; #define ID3D10RasterizerState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10RasterizerState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1457,21 +1390,15 @@ EXTERN_C const IID IID_ID3D10RasterizerState; #define ID3D10RasterizerState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10RasterizerState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10RasterizerState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0004 */ /* [local] */ @@ -1486,8 +1413,6 @@ typedef struct D3D10_SUBRESOURCE_DATA UINT SysMemSlicePitch; } D3D10_SUBRESOURCE_DATA; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0004_v0_0_s_ifspec; @@ -1497,7 +1422,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0004_v0_0_s_ifspec; /* interface ID3D10Resource */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Resource; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1592,7 +1516,6 @@ EXTERN_C const IID IID_ID3D10Resource; #ifdef COBJMACROS - #define ID3D10Resource_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1602,7 +1525,6 @@ EXTERN_C const IID IID_ID3D10Resource; #define ID3D10Resource_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Resource_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1615,7 +1537,6 @@ EXTERN_C const IID IID_ID3D10Resource; #define ID3D10Resource_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Resource_GetType(This,rType) \ ( (This)->lpVtbl -> GetType(This,rType) ) @@ -1627,15 +1548,10 @@ EXTERN_C const IID IID_ID3D10Resource; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Resource_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0005 */ /* [local] */ @@ -1674,7 +1590,6 @@ struct CD3D10_BUFFER_DESC : public D3D10_BUFFER_DESC }; #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0005_v0_0_s_ifspec; @@ -1684,7 +1599,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0005_v0_0_s_ifspec; /* interface ID3D10Buffer */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Buffer; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1800,7 +1714,6 @@ EXTERN_C const IID IID_ID3D10Buffer; #ifdef COBJMACROS - #define ID3D10Buffer_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1810,7 +1723,6 @@ EXTERN_C const IID IID_ID3D10Buffer; #define ID3D10Buffer_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Buffer_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1823,7 +1735,6 @@ EXTERN_C const IID IID_ID3D10Buffer; #define ID3D10Buffer_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Buffer_GetType(This,rType) \ ( (This)->lpVtbl -> GetType(This,rType) ) @@ -1833,7 +1744,6 @@ EXTERN_C const IID IID_ID3D10Buffer; #define ID3D10Buffer_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D10Buffer_Map(This,MapType,MapFlags,ppData) \ ( (This)->lpVtbl -> Map(This,MapType,MapFlags,ppData) ) @@ -1845,15 +1755,10 @@ EXTERN_C const IID IID_ID3D10Buffer; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Buffer_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0006 */ /* [local] */ @@ -1901,7 +1806,6 @@ struct CD3D10_TEXTURE1D_DESC : public D3D10_TEXTURE1D_DESC }; #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0006_v0_0_s_ifspec; @@ -1911,7 +1815,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0006_v0_0_s_ifspec; /* interface ID3D10Texture1D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Texture1D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2035,7 +1938,6 @@ EXTERN_C const IID IID_ID3D10Texture1D; #ifdef COBJMACROS - #define ID3D10Texture1D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2045,7 +1947,6 @@ EXTERN_C const IID IID_ID3D10Texture1D; #define ID3D10Texture1D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Texture1D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2058,7 +1959,6 @@ EXTERN_C const IID IID_ID3D10Texture1D; #define ID3D10Texture1D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Texture1D_GetType(This,rType) \ ( (This)->lpVtbl -> GetType(This,rType) ) @@ -2068,7 +1968,6 @@ EXTERN_C const IID IID_ID3D10Texture1D; #define ID3D10Texture1D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D10Texture1D_Map(This,Subresource,MapType,MapFlags,ppData) \ ( (This)->lpVtbl -> Map(This,Subresource,MapType,MapFlags,ppData) ) @@ -2080,15 +1979,10 @@ EXTERN_C const IID IID_ID3D10Texture1D; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Texture1D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0007 */ /* [local] */ @@ -2149,8 +2043,6 @@ typedef struct D3D10_MAPPED_TEXTURE2D UINT RowPitch; } D3D10_MAPPED_TEXTURE2D; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0007_v0_0_s_ifspec; @@ -2160,7 +2052,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0007_v0_0_s_ifspec; /* interface ID3D10Texture2D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Texture2D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2284,7 +2175,6 @@ EXTERN_C const IID IID_ID3D10Texture2D; #ifdef COBJMACROS - #define ID3D10Texture2D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2294,7 +2184,6 @@ EXTERN_C const IID IID_ID3D10Texture2D; #define ID3D10Texture2D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Texture2D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2307,7 +2196,6 @@ EXTERN_C const IID IID_ID3D10Texture2D; #define ID3D10Texture2D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Texture2D_GetType(This,rType) \ ( (This)->lpVtbl -> GetType(This,rType) ) @@ -2317,7 +2205,6 @@ EXTERN_C const IID IID_ID3D10Texture2D; #define ID3D10Texture2D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D10Texture2D_Map(This,Subresource,MapType,MapFlags,pMappedTex2D) \ ( (This)->lpVtbl -> Map(This,Subresource,MapType,MapFlags,pMappedTex2D) ) @@ -2329,15 +2216,10 @@ EXTERN_C const IID IID_ID3D10Texture2D; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Texture2D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0008 */ /* [local] */ @@ -2394,8 +2276,6 @@ typedef struct D3D10_MAPPED_TEXTURE3D UINT DepthPitch; } D3D10_MAPPED_TEXTURE3D; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0008_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0008_v0_0_s_ifspec; @@ -2405,7 +2285,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0008_v0_0_s_ifspec; /* interface ID3D10Texture3D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Texture3D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2529,7 +2408,6 @@ EXTERN_C const IID IID_ID3D10Texture3D; #ifdef COBJMACROS - #define ID3D10Texture3D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2539,7 +2417,6 @@ EXTERN_C const IID IID_ID3D10Texture3D; #define ID3D10Texture3D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Texture3D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2552,7 +2429,6 @@ EXTERN_C const IID IID_ID3D10Texture3D; #define ID3D10Texture3D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Texture3D_GetType(This,rType) \ ( (This)->lpVtbl -> GetType(This,rType) ) @@ -2562,7 +2438,6 @@ EXTERN_C const IID IID_ID3D10Texture3D; #define ID3D10Texture3D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D10Texture3D_Map(This,Subresource,MapType,MapFlags,pMappedTex3D) \ ( (This)->lpVtbl -> Map(This,Subresource,MapType,MapFlags,pMappedTex3D) ) @@ -2574,15 +2449,10 @@ EXTERN_C const IID IID_ID3D10Texture3D; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Texture3D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0009 */ /* [local] */ @@ -2597,8 +2467,6 @@ enum D3D10_TEXTURECUBE_FACE D3D10_TEXTURECUBE_FACE_NEGATIVE_Z = 5 } D3D10_TEXTURECUBE_FACE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0009_v0_0_s_ifspec; @@ -2608,7 +2476,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0009_v0_0_s_ifspec; /* interface ID3D10View */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10View; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2689,7 +2556,6 @@ EXTERN_C const IID IID_ID3D10View; #ifdef COBJMACROS - #define ID3D10View_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2699,7 +2565,6 @@ EXTERN_C const IID IID_ID3D10View; #define ID3D10View_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10View_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2712,21 +2577,15 @@ EXTERN_C const IID IID_ID3D10View; #define ID3D10View_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10View_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10View_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0010 */ /* [local] */ @@ -2813,8 +2672,6 @@ typedef struct D3D10_SHADER_RESOURCE_VIEW_DESC } ; } D3D10_SHADER_RESOURCE_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0010_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0010_v0_0_s_ifspec; @@ -2824,7 +2681,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0010_v0_0_s_ifspec; /* interface ID3D10ShaderResourceView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10ShaderResourceView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2910,7 +2766,6 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView; #ifdef COBJMACROS - #define ID3D10ShaderResourceView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2920,7 +2775,6 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView; #define ID3D10ShaderResourceView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10ShaderResourceView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2933,25 +2787,18 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView; #define ID3D10ShaderResourceView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10ShaderResourceView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D10ShaderResourceView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10ShaderResourceView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0011 */ /* [local] */ @@ -3028,8 +2875,6 @@ typedef struct D3D10_RENDER_TARGET_VIEW_DESC } ; } D3D10_RENDER_TARGET_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0011_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0011_v0_0_s_ifspec; @@ -3039,7 +2884,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0011_v0_0_s_ifspec; /* interface ID3D10RenderTargetView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10RenderTargetView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3125,7 +2969,6 @@ EXTERN_C const IID IID_ID3D10RenderTargetView; #ifdef COBJMACROS - #define ID3D10RenderTargetView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3135,7 +2978,6 @@ EXTERN_C const IID IID_ID3D10RenderTargetView; #define ID3D10RenderTargetView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10RenderTargetView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3148,25 +2990,18 @@ EXTERN_C const IID IID_ID3D10RenderTargetView; #define ID3D10RenderTargetView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10RenderTargetView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D10RenderTargetView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10RenderTargetView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0012 */ /* [local] */ @@ -3220,8 +3055,6 @@ typedef struct D3D10_DEPTH_STENCIL_VIEW_DESC } ; } D3D10_DEPTH_STENCIL_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0012_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0012_v0_0_s_ifspec; @@ -3231,7 +3064,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0012_v0_0_s_ifspec; /* interface ID3D10DepthStencilView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10DepthStencilView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3317,7 +3149,6 @@ EXTERN_C const IID IID_ID3D10DepthStencilView; #ifdef COBJMACROS - #define ID3D10DepthStencilView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3327,7 +3158,6 @@ EXTERN_C const IID IID_ID3D10DepthStencilView; #define ID3D10DepthStencilView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10DepthStencilView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3340,32 +3170,24 @@ EXTERN_C const IID IID_ID3D10DepthStencilView; #define ID3D10DepthStencilView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10DepthStencilView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D10DepthStencilView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10DepthStencilView_INTERFACE_DEFINED__ */ - #ifndef __ID3D10VertexShader_INTERFACE_DEFINED__ #define __ID3D10VertexShader_INTERFACE_DEFINED__ /* interface ID3D10VertexShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10VertexShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3437,7 +3259,6 @@ EXTERN_C const IID IID_ID3D10VertexShader; #ifdef COBJMACROS - #define ID3D10VertexShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3447,7 +3268,6 @@ EXTERN_C const IID IID_ID3D10VertexShader; #define ID3D10VertexShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10VertexShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3460,25 +3280,18 @@ EXTERN_C const IID IID_ID3D10VertexShader; #define ID3D10VertexShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10VertexShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D10GeometryShader_INTERFACE_DEFINED__ #define __ID3D10GeometryShader_INTERFACE_DEFINED__ /* interface ID3D10GeometryShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10GeometryShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3550,7 +3363,6 @@ EXTERN_C const IID IID_ID3D10GeometryShader; #ifdef COBJMACROS - #define ID3D10GeometryShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3560,7 +3372,6 @@ EXTERN_C const IID IID_ID3D10GeometryShader; #define ID3D10GeometryShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10GeometryShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3573,25 +3384,18 @@ EXTERN_C const IID IID_ID3D10GeometryShader; #define ID3D10GeometryShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10GeometryShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D10PixelShader_INTERFACE_DEFINED__ #define __ID3D10PixelShader_INTERFACE_DEFINED__ /* interface ID3D10PixelShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10PixelShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3663,7 +3467,6 @@ EXTERN_C const IID IID_ID3D10PixelShader; #ifdef COBJMACROS - #define ID3D10PixelShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3673,7 +3476,6 @@ EXTERN_C const IID IID_ID3D10PixelShader; #define ID3D10PixelShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10PixelShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3686,25 +3488,18 @@ EXTERN_C const IID IID_ID3D10PixelShader; #define ID3D10PixelShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10PixelShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D10InputLayout_INTERFACE_DEFINED__ #define __ID3D10InputLayout_INTERFACE_DEFINED__ /* interface ID3D10InputLayout */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10InputLayout; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3776,7 +3571,6 @@ EXTERN_C const IID IID_ID3D10InputLayout; #ifdef COBJMACROS - #define ID3D10InputLayout_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3786,7 +3580,6 @@ EXTERN_C const IID IID_ID3D10InputLayout; #define ID3D10InputLayout_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10InputLayout_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3799,18 +3592,12 @@ EXTERN_C const IID IID_ID3D10InputLayout; #define ID3D10InputLayout_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10InputLayout_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0017 */ /* [local] */ @@ -3914,8 +3701,6 @@ typedef struct D3D10_SAMPLER_DESC FLOAT MaxLOD; } D3D10_SAMPLER_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0017_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0017_v0_0_s_ifspec; @@ -3925,7 +3710,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0017_v0_0_s_ifspec; /* interface ID3D10SamplerState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10SamplerState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4006,7 +3790,6 @@ EXTERN_C const IID IID_ID3D10SamplerState; #ifdef COBJMACROS - #define ID3D10SamplerState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4016,7 +3799,6 @@ EXTERN_C const IID IID_ID3D10SamplerState; #define ID3D10SamplerState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10SamplerState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4029,21 +3811,15 @@ EXTERN_C const IID IID_ID3D10SamplerState; #define ID3D10SamplerState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10SamplerState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10SamplerState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0018 */ /* [local] */ @@ -4077,8 +3853,6 @@ enum D3D10_FORMAT_SUPPORT D3D10_FORMAT_SUPPORT_BACK_BUFFER_CAST = 0x1000000 } D3D10_FORMAT_SUPPORT; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0018_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0018_v0_0_s_ifspec; @@ -4088,7 +3862,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0018_v0_0_s_ifspec; /* interface ID3D10Asynchronous */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Asynchronous; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4192,7 +3965,6 @@ EXTERN_C const IID IID_ID3D10Asynchronous; #ifdef COBJMACROS - #define ID3D10Asynchronous_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4202,7 +3974,6 @@ EXTERN_C const IID IID_ID3D10Asynchronous; #define ID3D10Asynchronous_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Asynchronous_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4215,7 +3986,6 @@ EXTERN_C const IID IID_ID3D10Asynchronous; #define ID3D10Asynchronous_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Asynchronous_Begin(This) \ ( (This)->lpVtbl -> Begin(This) ) @@ -4230,15 +4000,10 @@ EXTERN_C const IID IID_ID3D10Asynchronous; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Asynchronous_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0019 */ /* [local] */ @@ -4273,8 +4038,6 @@ typedef struct D3D10_QUERY_DESC UINT MiscFlags; } D3D10_QUERY_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0019_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0019_v0_0_s_ifspec; @@ -4284,7 +4047,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0019_v0_0_s_ifspec; /* interface ID3D10Query */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Query; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4383,7 +4145,6 @@ EXTERN_C const IID IID_ID3D10Query; #ifdef COBJMACROS - #define ID3D10Query_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4393,7 +4154,6 @@ EXTERN_C const IID IID_ID3D10Query; #define ID3D10Query_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Query_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4406,7 +4166,6 @@ EXTERN_C const IID IID_ID3D10Query; #define ID3D10Query_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Query_Begin(This) \ ( (This)->lpVtbl -> Begin(This) ) @@ -4419,28 +4178,21 @@ EXTERN_C const IID IID_ID3D10Query; #define ID3D10Query_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D10Query_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Query_INTERFACE_DEFINED__ */ - #ifndef __ID3D10Predicate_INTERFACE_DEFINED__ #define __ID3D10Predicate_INTERFACE_DEFINED__ /* interface ID3D10Predicate */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Predicate; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4535,7 +4287,6 @@ EXTERN_C const IID IID_ID3D10Predicate; #ifdef COBJMACROS - #define ID3D10Predicate_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4545,7 +4296,6 @@ EXTERN_C const IID IID_ID3D10Predicate; #define ID3D10Predicate_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Predicate_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4558,7 +4308,6 @@ EXTERN_C const IID IID_ID3D10Predicate; #define ID3D10Predicate_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Predicate_Begin(This) \ ( (This)->lpVtbl -> Begin(This) ) @@ -4571,22 +4320,15 @@ EXTERN_C const IID IID_ID3D10Predicate; #define ID3D10Predicate_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D10Predicate_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Predicate_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0021 */ /* [local] */ @@ -4660,8 +4402,6 @@ typedef struct D3D10_COUNTER_INFO UINT8 NumDetectableParallelUnits; } D3D10_COUNTER_INFO; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0021_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0021_v0_0_s_ifspec; @@ -4671,7 +4411,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0021_v0_0_s_ifspec; /* interface ID3D10Counter */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Counter; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4770,7 +4509,6 @@ EXTERN_C const IID IID_ID3D10Counter; #ifdef COBJMACROS - #define ID3D10Counter_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4780,7 +4518,6 @@ EXTERN_C const IID IID_ID3D10Counter; #define ID3D10Counter_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Counter_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4793,7 +4530,6 @@ EXTERN_C const IID IID_ID3D10Counter; #define ID3D10Counter_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10Counter_Begin(This) \ ( (This)->lpVtbl -> Begin(This) ) @@ -4806,28 +4542,21 @@ EXTERN_C const IID IID_ID3D10Counter; #define ID3D10Counter_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D10Counter_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Counter_INTERFACE_DEFINED__ */ - #ifndef __ID3D10Device_INTERFACE_DEFINED__ #define __ID3D10Device_INTERFACE_DEFINED__ /* interface ID3D10Device */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Device; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6318,7 +6047,6 @@ EXTERN_C const IID IID_ID3D10Device; #ifdef COBJMACROS - #define ID3D10Device_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6328,7 +6056,6 @@ EXTERN_C const IID IID_ID3D10Device; #define ID3D10Device_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Device_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -6616,15 +6343,10 @@ EXTERN_C const IID IID_ID3D10Device; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Device_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0023 */ /* [local] */ @@ -6634,7 +6356,6 @@ EXTERN_C const IID IID_ID3D10Device; /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0023_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0023_v0_0_s_ifspec; @@ -6644,7 +6365,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0023_v0_0_s_ifspec; /* interface ID3D10Multithread */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Multithread; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6710,7 +6430,6 @@ EXTERN_C const IID IID_ID3D10Multithread; #ifdef COBJMACROS - #define ID3D10Multithread_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6720,7 +6439,6 @@ EXTERN_C const IID IID_ID3D10Multithread; #define ID3D10Multithread_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Multithread_Enter(This) \ ( (This)->lpVtbl -> Enter(This) ) @@ -6735,15 +6453,10 @@ EXTERN_C const IID IID_ID3D10Multithread; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Multithread_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_0000_0024 */ /* [local] */ @@ -6766,7 +6479,6 @@ enum D3D10_CREATE_DEVICE_FLAG D3D10_CREATE_DEVICE_DEBUGGABLE = 0x400 } D3D10_CREATE_DEVICE_FLAG; - #define D3D10_SDK_VERSION ( 29 ) #if !defined( D3D10_IGNORE_SDK_LAYERS ) @@ -6802,7 +6514,6 @@ DEFINE_GUID(IID_ID3D10Counter,0x9B7E4C11,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04, DEFINE_GUID(IID_ID3D10Device,0x9B7E4C0F,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); DEFINE_GUID(IID_ID3D10Multithread,0x9B7E4E00,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); - extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0024_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0024_v0_0_s_ifspec; @@ -6816,4 +6527,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_0000_0024_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d10_1.h b/gfx/include/dxsdk/d3d10_1.h index cf959831c2..02b5c74028 100644 --- a/gfx/include/dxsdk/d3d10_1.h +++ b/gfx/include/dxsdk/d3d10_1.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,21 +46,18 @@ typedef interface ID3D10BlendState1 ID3D10BlendState1; #endif /* __ID3D10BlendState1_FWD_DEFINED__ */ - #ifndef __ID3D10ShaderResourceView1_FWD_DEFINED__ #define __ID3D10ShaderResourceView1_FWD_DEFINED__ typedef interface ID3D10ShaderResourceView1 ID3D10ShaderResourceView1; #endif /* __ID3D10ShaderResourceView1_FWD_DEFINED__ */ - #ifndef __ID3D10Device1_FWD_DEFINED__ #define __ID3D10Device1_FWD_DEFINED__ typedef interface ID3D10Device1 ID3D10Device1; #endif /* __ID3D10Device1_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -73,7 +66,6 @@ typedef interface ID3D10Device1 ID3D10Device1; extern "C"{ #endif - /* interface __MIDL_itf_d3d10_1_0000_0000 */ /* [local] */ @@ -158,8 +150,6 @@ typedef struct D3D10_BLEND_DESC1 D3D10_RENDER_TARGET_BLEND_DESC1 RenderTarget[ 8 ]; } D3D10_BLEND_DESC1; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0000_v0_0_s_ifspec; @@ -169,7 +159,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0000_v0_0_s_ifspec; /* interface ID3D10BlendState1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10BlendState1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -255,7 +244,6 @@ EXTERN_C const IID IID_ID3D10BlendState1; #ifdef COBJMACROS - #define ID3D10BlendState1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -265,7 +253,6 @@ EXTERN_C const IID IID_ID3D10BlendState1; #define ID3D10BlendState1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10BlendState1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -278,25 +265,18 @@ EXTERN_C const IID IID_ID3D10BlendState1; #define ID3D10BlendState1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10BlendState1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D10BlendState1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10BlendState1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_1_0000_0001 */ /* [local] */ @@ -329,8 +309,6 @@ typedef struct D3D10_SHADER_RESOURCE_VIEW_DESC1 } ; } D3D10_SHADER_RESOURCE_VIEW_DESC1; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0001_v0_0_s_ifspec; @@ -340,7 +318,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0001_v0_0_s_ifspec; /* interface ID3D10ShaderResourceView1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10ShaderResourceView1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -431,7 +408,6 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView1; #ifdef COBJMACROS - #define ID3D10ShaderResourceView1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -441,7 +417,6 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView1; #define ID3D10ShaderResourceView1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10ShaderResourceView1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -454,29 +429,21 @@ EXTERN_C const IID IID_ID3D10ShaderResourceView1; #define ID3D10ShaderResourceView1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D10ShaderResourceView1_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D10ShaderResourceView1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D10ShaderResourceView1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10ShaderResourceView1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_1_0000_0002 */ /* [local] */ @@ -487,8 +454,6 @@ enum D3D10_STANDARD_MULTISAMPLE_QUALITY_LEVELS D3D10_CENTER_MULTISAMPLE_PATTERN = 0xfffffffe } D3D10_STANDARD_MULTISAMPLE_QUALITY_LEVELS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0002_v0_0_s_ifspec; @@ -498,7 +463,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0002_v0_0_s_ifspec; /* interface ID3D10Device1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Device1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1347,7 +1311,6 @@ EXTERN_C const IID IID_ID3D10Device1; #ifdef COBJMACROS - #define ID3D10Device1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1357,7 +1320,6 @@ EXTERN_C const IID IID_ID3D10Device1; #define ID3D10Device1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Device1_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -1643,7 +1605,6 @@ EXTERN_C const IID IID_ID3D10Device1; #define ID3D10Device1_GetTextFilterSize(This,pWidth,pHeight) \ ( (This)->lpVtbl -> GetTextFilterSize(This,pWidth,pHeight) ) - #define ID3D10Device1_CreateShaderResourceView1(This,pResource,pDesc,ppSRView) \ ( (This)->lpVtbl -> CreateShaderResourceView1(This,pResource,pDesc,ppSRView) ) @@ -1655,15 +1616,10 @@ EXTERN_C const IID IID_ID3D10Device1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Device1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10_1_0000_0003 */ /* [local] */ @@ -1776,7 +1732,6 @@ DEFINE_GUID(IID_ID3D10BlendState1,0xEDAD8D99,0x8A35,0x4d6d,0x85,0x66,0x2E,0xA2,0 DEFINE_GUID(IID_ID3D10ShaderResourceView1,0x9B7E4C87,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); DEFINE_GUID(IID_ID3D10Device1,0x9B7E4C8F,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); - extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0003_v0_0_s_ifspec; @@ -1790,4 +1745,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10_1_0000_0003_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d10_1shader.h b/gfx/include/dxsdk/d3d10_1shader.h index 7da84274c3..bdb9c6a3d9 100644 --- a/gfx/include/dxsdk/d3d10_1shader.h +++ b/gfx/include/dxsdk/d3d10_1shader.h @@ -14,8 +14,6 @@ /*#include */ - - //---------------------------------------------------------------------------- // Shader debugging structures //---------------------------------------------------------------------------- @@ -249,7 +247,6 @@ typedef struct _D3D10_SHADER_DEBUG_INFO // Interface definitions // - typedef interface ID3D10ShaderReflection1 ID3D10ShaderReflection1; typedef interface ID3D10ShaderReflection1 *LPD3D10SHADERREFLECTION1; diff --git a/gfx/include/dxsdk/d3d10effect.h b/gfx/include/dxsdk/d3d10effect.h index 67582bd36f..5493115752 100644 --- a/gfx/include/dxsdk/d3d10effect.h +++ b/gfx/include/dxsdk/d3d10effect.h @@ -230,7 +230,6 @@ HRESULT WINAPI D3D10CreateStateBlock(_In_ ID3D10Device *pDevice, _In_ D3D10_STAT #define D3D10_EFFECT_COMPILE_ALLOW_SLOW_OPS (1 << 1) #define D3D10_EFFECT_SINGLE_THREADED (1 << 3) - //---------------------------------------------------------------------------- // D3D10_EFFECT_VARIABLE flags: // ---------------------------- @@ -661,7 +660,6 @@ typedef interface ID3D10EffectShaderResourceVariable *LPD3D10EFFECTSHADERRESOURC DEFINE_GUID(IID_ID3D10EffectShaderResourceVariable, 0xc0a7157b, 0xd872, 0x4b1d, 0x80, 0x73, 0xef, 0xc2, 0xac, 0xd4, 0xb1, 0xfc); - #undef INTERFACE #define INTERFACE ID3D10EffectShaderResourceVariable @@ -899,7 +897,6 @@ typedef struct _D3D10_EFFECT_SHADER_DESC UINT NumOutputSignatureEntries; // Number of entries in the output signature } D3D10_EFFECT_SHADER_DESC; - typedef interface ID3D10EffectShaderVariable ID3D10EffectShaderVariable; typedef interface ID3D10EffectShaderVariable *LPD3D10EFFECTSHADERVARIABLE; @@ -1434,7 +1431,6 @@ HRESULT WINAPI D3D10CreateEffectFromMemory(_In_reads_bytes_(DataLength) void *pD HRESULT WINAPI D3D10CreateEffectPoolFromMemory(_In_reads_bytes_(DataLength) void *pData, SIZE_T DataLength, UINT FXFlags, _In_ ID3D10Device *pDevice, _Out_ ID3D10EffectPool **ppEffectPool); - //---------------------------------------------------------------------------- // D3D10DisassembleEffect: // ----------------------- @@ -1460,4 +1456,3 @@ HRESULT WINAPI D3D10DisassembleEffect(_In_ ID3D10Effect *pEffect, BOOL EnableCol #endif //__D3D10EFFECT_H__ - diff --git a/gfx/include/dxsdk/d3d10misc.h b/gfx/include/dxsdk/d3d10misc.h index 59da4e1c00..65f6abf6bb 100644 --- a/gfx/include/dxsdk/d3d10misc.h +++ b/gfx/include/dxsdk/d3d10misc.h @@ -130,7 +130,6 @@ HRESULT WINAPI D3D10CreateDeviceAndSwapChain( _Out_opt_ IDXGISwapChain **ppSwapChain, _Out_opt_ ID3D10Device **ppDevice); - /////////////////////////////////////////////////////////////////////////// // D3D10CreateBlob: // ----------------- @@ -148,4 +147,3 @@ HRESULT WINAPI D3D10CreateBlob(SIZE_T NumBytes, _Out_ LPD3D10BLOB *ppBuffer); #endif //__D3D10EFFECT_H__ - diff --git a/gfx/include/dxsdk/d3d10sdklayers.h b/gfx/include/dxsdk/d3d10sdklayers.h index c2ee81e700..62325ba6a8 100644 --- a/gfx/include/dxsdk/d3d10sdklayers.h +++ b/gfx/include/dxsdk/d3d10sdklayers.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,21 +46,18 @@ typedef interface ID3D10Debug ID3D10Debug; #endif /* __ID3D10Debug_FWD_DEFINED__ */ - #ifndef __ID3D10SwitchToRef_FWD_DEFINED__ #define __ID3D10SwitchToRef_FWD_DEFINED__ typedef interface ID3D10SwitchToRef ID3D10SwitchToRef; #endif /* __ID3D10SwitchToRef_FWD_DEFINED__ */ - #ifndef __ID3D10InfoQueue_FWD_DEFINED__ #define __ID3D10InfoQueue_FWD_DEFINED__ typedef interface ID3D10InfoQueue ID3D10InfoQueue; #endif /* __ID3D10InfoQueue_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -74,7 +67,6 @@ typedef interface ID3D10InfoQueue ID3D10InfoQueue; extern "C"{ #endif - /* interface __MIDL_itf_d3d10sdklayers_0000_0000 */ /* [local] */ @@ -89,8 +81,6 @@ extern "C"{ #define D3D10_DEBUG_FEATURE_PRESENT_PER_RENDER_OP ( 0x4 ) - - extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0000_v0_0_s_ifspec; @@ -100,7 +90,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0000_v0_0_s_ifspec; /* interface ID3D10Debug */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Debug; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -189,7 +178,6 @@ EXTERN_C const IID IID_ID3D10Debug; #ifdef COBJMACROS - #define ID3D10Debug_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -199,7 +187,6 @@ EXTERN_C const IID IID_ID3D10Debug; #define ID3D10Debug_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Debug_SetFeatureMask(This,Mask) \ ( (This)->lpVtbl -> SetFeatureMask(This,Mask) ) @@ -223,22 +210,16 @@ EXTERN_C const IID IID_ID3D10Debug; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Debug_INTERFACE_DEFINED__ */ - #ifndef __ID3D10SwitchToRef_INTERFACE_DEFINED__ #define __ID3D10SwitchToRef_INTERFACE_DEFINED__ /* interface ID3D10SwitchToRef */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10SwitchToRef; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -292,7 +273,6 @@ EXTERN_C const IID IID_ID3D10SwitchToRef; #ifdef COBJMACROS - #define ID3D10SwitchToRef_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -302,7 +282,6 @@ EXTERN_C const IID IID_ID3D10SwitchToRef; #define ID3D10SwitchToRef_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10SwitchToRef_SetUseRef(This,UseRef) \ ( (This)->lpVtbl -> SetUseRef(This,UseRef) ) @@ -311,15 +290,10 @@ EXTERN_C const IID IID_ID3D10SwitchToRef; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10SwitchToRef_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10sdklayers_0000_0002 */ /* [local] */ @@ -908,7 +882,6 @@ typedef struct D3D10_INFO_QUEUE_FILTER #define D3D10_INFO_QUEUE_DEFAULT_MESSAGE_COUNT_LIMIT 1024 - extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0002_v0_0_s_ifspec; @@ -918,7 +891,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0002_v0_0_s_ifspec; /* interface ID3D10InfoQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10InfoQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1247,7 +1219,6 @@ EXTERN_C const IID IID_ID3D10InfoQueue; #ifdef COBJMACROS - #define ID3D10InfoQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1257,7 +1228,6 @@ EXTERN_C const IID IID_ID3D10InfoQueue; #define ID3D10InfoQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10InfoQueue_SetMessageCountLimit(This,MessageCountLimit) \ ( (This)->lpVtbl -> SetMessageCountLimit(This,MessageCountLimit) ) @@ -1365,15 +1335,10 @@ EXTERN_C const IID IID_ID3D10InfoQueue; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10InfoQueue_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d10sdklayers_0000_0003 */ /* [local] */ @@ -1383,7 +1348,6 @@ DEFINE_GUID(IID_ID3D10Debug,0x9B7E4E01,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0x DEFINE_GUID(IID_ID3D10SwitchToRef,0x9B7E4E02,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); DEFINE_GUID(IID_ID3D10InfoQueue,0x1b940b17,0x2642,0x4d1f,0xab,0x1f,0xb9,0x9b,0xad,0x0c,0x39,0x5f); - extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0003_v0_0_s_ifspec; @@ -1397,4 +1361,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d10sdklayers_0000_0003_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d10shader.h b/gfx/include/dxsdk/d3d10shader.h index c4a6227656..142b2b95f7 100644 --- a/gfx/include/dxsdk/d3d10shader.h +++ b/gfx/include/dxsdk/d3d10shader.h @@ -10,7 +10,6 @@ #ifndef __D3D10SHADER_H__ #define __D3D10SHADER_H__ - #include "d3d10.h" /*#include */ @@ -18,7 +17,6 @@ /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ - //--------------------------------------------------------------------------- // D3D10_TX_VERSION: // -------------- @@ -27,7 +25,6 @@ //--------------------------------------------------------------------------- #define D3D10_TX_VERSION(_Major,_Minor) (('T' << 24) | ('X' << 16) | ((_Major) << 8) | (_Minor)) - //---------------------------------------------------------------------------- // D3D10SHADER flags: // ----------------- @@ -111,26 +108,20 @@ #define D3D10_SHADER_DEBUG_NAME_FOR_SOURCE (1 << 22) #define D3D10_SHADER_DEBUG_NAME_FOR_BINARY (1 << 23) - // optimization level flags #define D3D10_SHADER_OPTIMIZATION_LEVEL0 (1 << 14) #define D3D10_SHADER_OPTIMIZATION_LEVEL1 0 #define D3D10_SHADER_OPTIMIZATION_LEVEL2 ((1 << 14) | (1 << 15)) #define D3D10_SHADER_OPTIMIZATION_LEVEL3 (1 << 15) - // Force root signature flags. (Passed in Flags2) #define D3D10_SHADER_FLAGS2_FORCE_ROOT_SIGNATURE_LATEST 0 #define D3D10_SHADER_FLAGS2_FORCE_ROOT_SIGNATURE_1_0 (1 << 4) #define D3D10_SHADER_FLAGS2_FORCE_ROOT_SIGNATURE_1_1 (1 << 5) - - - typedef D3D_SHADER_MACRO D3D10_SHADER_MACRO; typedef D3D10_SHADER_MACRO* LPD3D10_SHADER_MACRO; - typedef D3D_SHADER_VARIABLE_CLASS D3D10_SHADER_VARIABLE_CLASS; typedef D3D10_SHADER_VARIABLE_CLASS* LPD3D10_SHADER_VARIABLE_CLASS; @@ -165,7 +156,6 @@ typedef interface ID3DInclude ID3D10Include; typedef interface ID3DInclude* LPD3D10INCLUDE; #define IID_ID3D10Include IID_ID3DInclude - //---------------------------------------------------------------------------- // ID3D10ShaderReflection: //---------------------------------------------------------------------------- @@ -266,14 +256,10 @@ typedef struct _D3D10_SIGNATURE_PARAMETER_DESC } D3D10_SIGNATURE_PARAMETER_DESC; - // // Interface definitions // - - - typedef interface ID3D10ShaderReflectionType ID3D10ShaderReflectionType; typedef interface ID3D10ShaderReflectionType *LPD3D10SHADERREFLECTIONTYPE; @@ -430,7 +416,6 @@ HRESULT WINAPI D3D10CompileShader(_In_reads_bytes_(SrcDataSize) LPCSTR pSrcData, HRESULT WINAPI D3D10DisassembleShader(_In_reads_bytes_(BytecodeLength) CONST void *pShader, SIZE_T BytecodeLength, BOOL EnableColorCode, _In_opt_ LPCSTR pComments, _Out_ ID3D10Blob** ppDisassembly); - //---------------------------------------------------------------------------- // D3D10GetPixelShaderProfile/D3D10GetVertexShaderProfile/D3D10GetGeometryShaderProfile: // ----------------------------------------------------- diff --git a/gfx/include/dxsdk/d3d11.h b/gfx/include/dxsdk/d3d11.h index b597d4e850..7f1e39ae23 100644 --- a/gfx/include/dxsdk/d3d11.h +++ b/gfx/include/dxsdk/d3d11.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,287 +46,246 @@ typedef interface ID3D11DeviceChild ID3D11DeviceChild; #endif /* __ID3D11DeviceChild_FWD_DEFINED__ */ - #ifndef __ID3D11DepthStencilState_FWD_DEFINED__ #define __ID3D11DepthStencilState_FWD_DEFINED__ typedef interface ID3D11DepthStencilState ID3D11DepthStencilState; #endif /* __ID3D11DepthStencilState_FWD_DEFINED__ */ - #ifndef __ID3D11BlendState_FWD_DEFINED__ #define __ID3D11BlendState_FWD_DEFINED__ typedef interface ID3D11BlendState ID3D11BlendState; #endif /* __ID3D11BlendState_FWD_DEFINED__ */ - #ifndef __ID3D11RasterizerState_FWD_DEFINED__ #define __ID3D11RasterizerState_FWD_DEFINED__ typedef interface ID3D11RasterizerState ID3D11RasterizerState; #endif /* __ID3D11RasterizerState_FWD_DEFINED__ */ - #ifndef __ID3D11Resource_FWD_DEFINED__ #define __ID3D11Resource_FWD_DEFINED__ typedef interface ID3D11Resource ID3D11Resource; #endif /* __ID3D11Resource_FWD_DEFINED__ */ - #ifndef __ID3D11Buffer_FWD_DEFINED__ #define __ID3D11Buffer_FWD_DEFINED__ typedef interface ID3D11Buffer ID3D11Buffer; #endif /* __ID3D11Buffer_FWD_DEFINED__ */ - #ifndef __ID3D11Texture1D_FWD_DEFINED__ #define __ID3D11Texture1D_FWD_DEFINED__ typedef interface ID3D11Texture1D ID3D11Texture1D; #endif /* __ID3D11Texture1D_FWD_DEFINED__ */ - #ifndef __ID3D11Texture2D_FWD_DEFINED__ #define __ID3D11Texture2D_FWD_DEFINED__ typedef interface ID3D11Texture2D ID3D11Texture2D; #endif /* __ID3D11Texture2D_FWD_DEFINED__ */ - #ifndef __ID3D11Texture3D_FWD_DEFINED__ #define __ID3D11Texture3D_FWD_DEFINED__ typedef interface ID3D11Texture3D ID3D11Texture3D; #endif /* __ID3D11Texture3D_FWD_DEFINED__ */ - #ifndef __ID3D11View_FWD_DEFINED__ #define __ID3D11View_FWD_DEFINED__ typedef interface ID3D11View ID3D11View; #endif /* __ID3D11View_FWD_DEFINED__ */ - #ifndef __ID3D11ShaderResourceView_FWD_DEFINED__ #define __ID3D11ShaderResourceView_FWD_DEFINED__ typedef interface ID3D11ShaderResourceView ID3D11ShaderResourceView; #endif /* __ID3D11ShaderResourceView_FWD_DEFINED__ */ - #ifndef __ID3D11RenderTargetView_FWD_DEFINED__ #define __ID3D11RenderTargetView_FWD_DEFINED__ typedef interface ID3D11RenderTargetView ID3D11RenderTargetView; #endif /* __ID3D11RenderTargetView_FWD_DEFINED__ */ - #ifndef __ID3D11DepthStencilView_FWD_DEFINED__ #define __ID3D11DepthStencilView_FWD_DEFINED__ typedef interface ID3D11DepthStencilView ID3D11DepthStencilView; #endif /* __ID3D11DepthStencilView_FWD_DEFINED__ */ - #ifndef __ID3D11UnorderedAccessView_FWD_DEFINED__ #define __ID3D11UnorderedAccessView_FWD_DEFINED__ typedef interface ID3D11UnorderedAccessView ID3D11UnorderedAccessView; #endif /* __ID3D11UnorderedAccessView_FWD_DEFINED__ */ - #ifndef __ID3D11VertexShader_FWD_DEFINED__ #define __ID3D11VertexShader_FWD_DEFINED__ typedef interface ID3D11VertexShader ID3D11VertexShader; #endif /* __ID3D11VertexShader_FWD_DEFINED__ */ - #ifndef __ID3D11HullShader_FWD_DEFINED__ #define __ID3D11HullShader_FWD_DEFINED__ typedef interface ID3D11HullShader ID3D11HullShader; #endif /* __ID3D11HullShader_FWD_DEFINED__ */ - #ifndef __ID3D11DomainShader_FWD_DEFINED__ #define __ID3D11DomainShader_FWD_DEFINED__ typedef interface ID3D11DomainShader ID3D11DomainShader; #endif /* __ID3D11DomainShader_FWD_DEFINED__ */ - #ifndef __ID3D11GeometryShader_FWD_DEFINED__ #define __ID3D11GeometryShader_FWD_DEFINED__ typedef interface ID3D11GeometryShader ID3D11GeometryShader; #endif /* __ID3D11GeometryShader_FWD_DEFINED__ */ - #ifndef __ID3D11PixelShader_FWD_DEFINED__ #define __ID3D11PixelShader_FWD_DEFINED__ typedef interface ID3D11PixelShader ID3D11PixelShader; #endif /* __ID3D11PixelShader_FWD_DEFINED__ */ - #ifndef __ID3D11ComputeShader_FWD_DEFINED__ #define __ID3D11ComputeShader_FWD_DEFINED__ typedef interface ID3D11ComputeShader ID3D11ComputeShader; #endif /* __ID3D11ComputeShader_FWD_DEFINED__ */ - #ifndef __ID3D11InputLayout_FWD_DEFINED__ #define __ID3D11InputLayout_FWD_DEFINED__ typedef interface ID3D11InputLayout ID3D11InputLayout; #endif /* __ID3D11InputLayout_FWD_DEFINED__ */ - #ifndef __ID3D11SamplerState_FWD_DEFINED__ #define __ID3D11SamplerState_FWD_DEFINED__ typedef interface ID3D11SamplerState ID3D11SamplerState; #endif /* __ID3D11SamplerState_FWD_DEFINED__ */ - #ifndef __ID3D11Asynchronous_FWD_DEFINED__ #define __ID3D11Asynchronous_FWD_DEFINED__ typedef interface ID3D11Asynchronous ID3D11Asynchronous; #endif /* __ID3D11Asynchronous_FWD_DEFINED__ */ - #ifndef __ID3D11Query_FWD_DEFINED__ #define __ID3D11Query_FWD_DEFINED__ typedef interface ID3D11Query ID3D11Query; #endif /* __ID3D11Query_FWD_DEFINED__ */ - #ifndef __ID3D11Predicate_FWD_DEFINED__ #define __ID3D11Predicate_FWD_DEFINED__ typedef interface ID3D11Predicate ID3D11Predicate; #endif /* __ID3D11Predicate_FWD_DEFINED__ */ - #ifndef __ID3D11Counter_FWD_DEFINED__ #define __ID3D11Counter_FWD_DEFINED__ typedef interface ID3D11Counter ID3D11Counter; #endif /* __ID3D11Counter_FWD_DEFINED__ */ - #ifndef __ID3D11ClassInstance_FWD_DEFINED__ #define __ID3D11ClassInstance_FWD_DEFINED__ typedef interface ID3D11ClassInstance ID3D11ClassInstance; #endif /* __ID3D11ClassInstance_FWD_DEFINED__ */ - #ifndef __ID3D11ClassLinkage_FWD_DEFINED__ #define __ID3D11ClassLinkage_FWD_DEFINED__ typedef interface ID3D11ClassLinkage ID3D11ClassLinkage; #endif /* __ID3D11ClassLinkage_FWD_DEFINED__ */ - #ifndef __ID3D11CommandList_FWD_DEFINED__ #define __ID3D11CommandList_FWD_DEFINED__ typedef interface ID3D11CommandList ID3D11CommandList; #endif /* __ID3D11CommandList_FWD_DEFINED__ */ - #ifndef __ID3D11DeviceContext_FWD_DEFINED__ #define __ID3D11DeviceContext_FWD_DEFINED__ typedef interface ID3D11DeviceContext ID3D11DeviceContext; #endif /* __ID3D11DeviceContext_FWD_DEFINED__ */ - #ifndef __ID3D11VideoDecoder_FWD_DEFINED__ #define __ID3D11VideoDecoder_FWD_DEFINED__ typedef interface ID3D11VideoDecoder ID3D11VideoDecoder; #endif /* __ID3D11VideoDecoder_FWD_DEFINED__ */ - #ifndef __ID3D11VideoProcessorEnumerator_FWD_DEFINED__ #define __ID3D11VideoProcessorEnumerator_FWD_DEFINED__ typedef interface ID3D11VideoProcessorEnumerator ID3D11VideoProcessorEnumerator; #endif /* __ID3D11VideoProcessorEnumerator_FWD_DEFINED__ */ - #ifndef __ID3D11VideoProcessor_FWD_DEFINED__ #define __ID3D11VideoProcessor_FWD_DEFINED__ typedef interface ID3D11VideoProcessor ID3D11VideoProcessor; #endif /* __ID3D11VideoProcessor_FWD_DEFINED__ */ - #ifndef __ID3D11AuthenticatedChannel_FWD_DEFINED__ #define __ID3D11AuthenticatedChannel_FWD_DEFINED__ typedef interface ID3D11AuthenticatedChannel ID3D11AuthenticatedChannel; #endif /* __ID3D11AuthenticatedChannel_FWD_DEFINED__ */ - #ifndef __ID3D11CryptoSession_FWD_DEFINED__ #define __ID3D11CryptoSession_FWD_DEFINED__ typedef interface ID3D11CryptoSession ID3D11CryptoSession; #endif /* __ID3D11CryptoSession_FWD_DEFINED__ */ - #ifndef __ID3D11VideoDecoderOutputView_FWD_DEFINED__ #define __ID3D11VideoDecoderOutputView_FWD_DEFINED__ typedef interface ID3D11VideoDecoderOutputView ID3D11VideoDecoderOutputView; #endif /* __ID3D11VideoDecoderOutputView_FWD_DEFINED__ */ - #ifndef __ID3D11VideoProcessorInputView_FWD_DEFINED__ #define __ID3D11VideoProcessorInputView_FWD_DEFINED__ typedef interface ID3D11VideoProcessorInputView ID3D11VideoProcessorInputView; #endif /* __ID3D11VideoProcessorInputView_FWD_DEFINED__ */ - #ifndef __ID3D11VideoProcessorOutputView_FWD_DEFINED__ #define __ID3D11VideoProcessorOutputView_FWD_DEFINED__ typedef interface ID3D11VideoProcessorOutputView ID3D11VideoProcessorOutputView; #endif /* __ID3D11VideoProcessorOutputView_FWD_DEFINED__ */ - #ifndef __ID3D11VideoContext_FWD_DEFINED__ #define __ID3D11VideoContext_FWD_DEFINED__ typedef interface ID3D11VideoContext ID3D11VideoContext; #endif /* __ID3D11VideoContext_FWD_DEFINED__ */ - #ifndef __ID3D11VideoDevice_FWD_DEFINED__ #define __ID3D11VideoDevice_FWD_DEFINED__ typedef interface ID3D11VideoDevice ID3D11VideoDevice; #endif /* __ID3D11VideoDevice_FWD_DEFINED__ */ - #ifndef __ID3D11Device_FWD_DEFINED__ #define __ID3D11Device_FWD_DEFINED__ typedef interface ID3D11Device ID3D11Device; #endif /* __ID3D11Device_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -341,7 +296,6 @@ typedef interface ID3D11Device ID3D11Device; extern "C"{ #endif - /* interface __MIDL_itf_d3d11_0000_0000 */ /* [local] */ @@ -1364,9 +1318,6 @@ inline bool operator!=( const D3D11_BOX& l, const D3D11_BOX& r ) extern "C"{ #endif - - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0000_v0_0_s_ifspec; @@ -1376,7 +1327,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0000_v0_0_s_ifspec; /* interface ID3D11DeviceChild */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceChild; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1474,7 +1424,6 @@ EXTERN_C const IID IID_ID3D11DeviceChild; #ifdef COBJMACROS - #define ID3D11DeviceChild_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1484,7 +1433,6 @@ EXTERN_C const IID IID_ID3D11DeviceChild; #define ID3D11DeviceChild_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceChild_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1499,15 +1447,10 @@ EXTERN_C const IID IID_ID3D11DeviceChild; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceChild_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0001 */ /* [local] */ @@ -1623,7 +1566,6 @@ struct CD3D11_DEPTH_STENCIL_DESC : public D3D11_DEPTH_STENCIL_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0001_v0_0_s_ifspec; @@ -1633,7 +1575,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0001_v0_0_s_ifspec; /* interface ID3D11DepthStencilState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DepthStencilState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1714,7 +1655,6 @@ EXTERN_C const IID IID_ID3D11DepthStencilState; #ifdef COBJMACROS - #define ID3D11DepthStencilState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1724,7 +1664,6 @@ EXTERN_C const IID IID_ID3D11DepthStencilState; #define ID3D11DepthStencilState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DepthStencilState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1737,21 +1676,15 @@ EXTERN_C const IID IID_ID3D11DepthStencilState; #define ID3D11DepthStencilState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DepthStencilState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DepthStencilState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0002 */ /* [local] */ @@ -1847,7 +1780,6 @@ struct CD3D11_BLEND_DESC : public D3D11_BLEND_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0002_v0_0_s_ifspec; @@ -1857,7 +1789,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0002_v0_0_s_ifspec; /* interface ID3D11BlendState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11BlendState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1938,7 +1869,6 @@ EXTERN_C const IID IID_ID3D11BlendState; #ifdef COBJMACROS - #define ID3D11BlendState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1948,7 +1878,6 @@ EXTERN_C const IID IID_ID3D11BlendState; #define ID3D11BlendState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11BlendState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1961,21 +1890,15 @@ EXTERN_C const IID IID_ID3D11BlendState; #define ID3D11BlendState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11BlendState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11BlendState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0003 */ /* [local] */ @@ -2044,7 +1967,6 @@ struct CD3D11_RASTERIZER_DESC : public D3D11_RASTERIZER_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0003_v0_0_s_ifspec; @@ -2054,7 +1976,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0003_v0_0_s_ifspec; /* interface ID3D11RasterizerState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RasterizerState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2135,7 +2056,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState; #ifdef COBJMACROS - #define ID3D11RasterizerState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2145,7 +2065,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState; #define ID3D11RasterizerState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RasterizerState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2158,21 +2077,15 @@ EXTERN_C const IID IID_ID3D11RasterizerState; #define ID3D11RasterizerState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11RasterizerState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RasterizerState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0004 */ /* [local] */ @@ -2196,8 +2109,6 @@ typedef struct D3D11_MAPPED_SUBRESOURCE UINT DepthPitch; } D3D11_MAPPED_SUBRESOURCE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0004_v0_0_s_ifspec; @@ -2207,7 +2118,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0004_v0_0_s_ifspec; /* interface ID3D11Resource */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Resource; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2302,7 +2212,6 @@ EXTERN_C const IID IID_ID3D11Resource; #ifdef COBJMACROS - #define ID3D11Resource_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2312,7 +2221,6 @@ EXTERN_C const IID IID_ID3D11Resource; #define ID3D11Resource_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Resource_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2325,7 +2233,6 @@ EXTERN_C const IID IID_ID3D11Resource; #define ID3D11Resource_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Resource_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -2337,15 +2244,10 @@ EXTERN_C const IID IID_ID3D11Resource; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Resource_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0005 */ /* [local] */ @@ -2389,7 +2291,6 @@ struct CD3D11_BUFFER_DESC : public D3D11_BUFFER_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0005_v0_0_s_ifspec; @@ -2399,7 +2300,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0005_v0_0_s_ifspec; /* interface ID3D11Buffer */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Buffer; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2493,7 +2393,6 @@ EXTERN_C const IID IID_ID3D11Buffer; #ifdef COBJMACROS - #define ID3D11Buffer_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2503,7 +2402,6 @@ EXTERN_C const IID IID_ID3D11Buffer; #define ID3D11Buffer_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Buffer_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2516,7 +2414,6 @@ EXTERN_C const IID IID_ID3D11Buffer; #define ID3D11Buffer_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Buffer_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -2526,21 +2423,15 @@ EXTERN_C const IID IID_ID3D11Buffer; #define ID3D11Buffer_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Buffer_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Buffer_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0006 */ /* [local] */ @@ -2590,7 +2481,6 @@ struct CD3D11_TEXTURE1D_DESC : public D3D11_TEXTURE1D_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0006_v0_0_s_ifspec; @@ -2600,7 +2490,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0006_v0_0_s_ifspec; /* interface ID3D11Texture1D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Texture1D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2694,7 +2583,6 @@ EXTERN_C const IID IID_ID3D11Texture1D; #ifdef COBJMACROS - #define ID3D11Texture1D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2704,7 +2592,6 @@ EXTERN_C const IID IID_ID3D11Texture1D; #define ID3D11Texture1D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Texture1D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2717,7 +2604,6 @@ EXTERN_C const IID IID_ID3D11Texture1D; #define ID3D11Texture1D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Texture1D_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -2727,21 +2613,15 @@ EXTERN_C const IID IID_ID3D11Texture1D; #define ID3D11Texture1D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Texture1D_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Texture1D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0007 */ /* [local] */ @@ -2799,7 +2679,6 @@ struct CD3D11_TEXTURE2D_DESC : public D3D11_TEXTURE2D_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0007_v0_0_s_ifspec; @@ -2809,7 +2688,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0007_v0_0_s_ifspec; /* interface ID3D11Texture2D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Texture2D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2903,7 +2781,6 @@ EXTERN_C const IID IID_ID3D11Texture2D; #ifdef COBJMACROS - #define ID3D11Texture2D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2913,7 +2790,6 @@ EXTERN_C const IID IID_ID3D11Texture2D; #define ID3D11Texture2D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Texture2D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2926,7 +2802,6 @@ EXTERN_C const IID IID_ID3D11Texture2D; #define ID3D11Texture2D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Texture2D_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -2936,21 +2811,15 @@ EXTERN_C const IID IID_ID3D11Texture2D; #define ID3D11Texture2D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Texture2D_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Texture2D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0008 */ /* [local] */ @@ -3003,7 +2872,6 @@ struct CD3D11_TEXTURE3D_DESC : public D3D11_TEXTURE3D_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0008_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0008_v0_0_s_ifspec; @@ -3013,7 +2881,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0008_v0_0_s_ifspec; /* interface ID3D11Texture3D */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Texture3D; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3107,7 +2974,6 @@ EXTERN_C const IID IID_ID3D11Texture3D; #ifdef COBJMACROS - #define ID3D11Texture3D_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3117,7 +2983,6 @@ EXTERN_C const IID IID_ID3D11Texture3D; #define ID3D11Texture3D_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Texture3D_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3130,7 +2995,6 @@ EXTERN_C const IID IID_ID3D11Texture3D; #define ID3D11Texture3D_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Texture3D_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -3140,21 +3004,15 @@ EXTERN_C const IID IID_ID3D11Texture3D; #define ID3D11Texture3D_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Texture3D_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Texture3D_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0009 */ /* [local] */ @@ -3169,8 +3027,6 @@ enum D3D11_TEXTURECUBE_FACE D3D11_TEXTURECUBE_FACE_NEGATIVE_Z = 5 } D3D11_TEXTURECUBE_FACE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0009_v0_0_s_ifspec; @@ -3180,7 +3036,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0009_v0_0_s_ifspec; /* interface ID3D11View */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11View; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3261,7 +3116,6 @@ EXTERN_C const IID IID_ID3D11View; #ifdef COBJMACROS - #define ID3D11View_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3271,7 +3125,6 @@ EXTERN_C const IID IID_ID3D11View; #define ID3D11View_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11View_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3284,21 +3137,15 @@ EXTERN_C const IID IID_ID3D11View; #define ID3D11View_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11View_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11View_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0010 */ /* [local] */ @@ -3615,7 +3462,6 @@ struct CD3D11_SHADER_RESOURCE_VIEW_DESC : public D3D11_SHADER_RESOURCE_VIEW_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0010_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0010_v0_0_s_ifspec; @@ -3625,7 +3471,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0010_v0_0_s_ifspec; /* interface ID3D11ShaderResourceView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ShaderResourceView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3711,7 +3556,6 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView; #ifdef COBJMACROS - #define ID3D11ShaderResourceView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3721,7 +3565,6 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView; #define ID3D11ShaderResourceView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ShaderResourceView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3734,25 +3577,18 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView; #define ID3D11ShaderResourceView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11ShaderResourceView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11ShaderResourceView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ShaderResourceView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0011 */ /* [local] */ @@ -3990,7 +3826,6 @@ struct CD3D11_RENDER_TARGET_VIEW_DESC : public D3D11_RENDER_TARGET_VIEW_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0011_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0011_v0_0_s_ifspec; @@ -4000,7 +3835,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0011_v0_0_s_ifspec; /* interface ID3D11RenderTargetView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RenderTargetView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4086,7 +3920,6 @@ EXTERN_C const IID IID_ID3D11RenderTargetView; #ifdef COBJMACROS - #define ID3D11RenderTargetView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4096,7 +3929,6 @@ EXTERN_C const IID IID_ID3D11RenderTargetView; #define ID3D11RenderTargetView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RenderTargetView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4109,25 +3941,18 @@ EXTERN_C const IID IID_ID3D11RenderTargetView; #define ID3D11RenderTargetView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11RenderTargetView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11RenderTargetView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RenderTargetView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0012 */ /* [local] */ @@ -4463,7 +4288,6 @@ struct CD3D11_DEPTH_STENCIL_VIEW_DESC : public D3D11_DEPTH_STENCIL_VIEW_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0012_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0012_v0_0_s_ifspec; @@ -4473,7 +4297,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0012_v0_0_s_ifspec; /* interface ID3D11DepthStencilView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DepthStencilView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4559,7 +4382,6 @@ EXTERN_C const IID IID_ID3D11DepthStencilView; #ifdef COBJMACROS - #define ID3D11DepthStencilView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4569,7 +4391,6 @@ EXTERN_C const IID IID_ID3D11DepthStencilView; #define ID3D11DepthStencilView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DepthStencilView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4582,25 +4403,18 @@ EXTERN_C const IID IID_ID3D11DepthStencilView; #define ID3D11DepthStencilView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DepthStencilView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11DepthStencilView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DepthStencilView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0013 */ /* [local] */ @@ -4816,7 +4630,6 @@ struct CD3D11_UNORDERED_ACCESS_VIEW_DESC : public D3D11_UNORDERED_ACCESS_VIEW_DE extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0013_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0013_v0_0_s_ifspec; @@ -4826,7 +4639,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0013_v0_0_s_ifspec; /* interface ID3D11UnorderedAccessView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11UnorderedAccessView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4912,7 +4724,6 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView; #ifdef COBJMACROS - #define ID3D11UnorderedAccessView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4922,7 +4733,6 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView; #define ID3D11UnorderedAccessView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11UnorderedAccessView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4935,32 +4745,24 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView; #define ID3D11UnorderedAccessView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11UnorderedAccessView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11UnorderedAccessView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11UnorderedAccessView_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VertexShader_INTERFACE_DEFINED__ #define __ID3D11VertexShader_INTERFACE_DEFINED__ /* interface ID3D11VertexShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VertexShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5032,7 +4834,6 @@ EXTERN_C const IID IID_ID3D11VertexShader; #ifdef COBJMACROS - #define ID3D11VertexShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5042,7 +4843,6 @@ EXTERN_C const IID IID_ID3D11VertexShader; #define ID3D11VertexShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VertexShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5055,25 +4855,18 @@ EXTERN_C const IID IID_ID3D11VertexShader; #define ID3D11VertexShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VertexShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11HullShader_INTERFACE_DEFINED__ #define __ID3D11HullShader_INTERFACE_DEFINED__ /* interface ID3D11HullShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11HullShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5145,7 +4938,6 @@ EXTERN_C const IID IID_ID3D11HullShader; #ifdef COBJMACROS - #define ID3D11HullShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5155,7 +4947,6 @@ EXTERN_C const IID IID_ID3D11HullShader; #define ID3D11HullShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11HullShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5168,25 +4959,18 @@ EXTERN_C const IID IID_ID3D11HullShader; #define ID3D11HullShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11HullShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11DomainShader_INTERFACE_DEFINED__ #define __ID3D11DomainShader_INTERFACE_DEFINED__ /* interface ID3D11DomainShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DomainShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5258,7 +5042,6 @@ EXTERN_C const IID IID_ID3D11DomainShader; #ifdef COBJMACROS - #define ID3D11DomainShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5268,7 +5051,6 @@ EXTERN_C const IID IID_ID3D11DomainShader; #define ID3D11DomainShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DomainShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5281,25 +5063,18 @@ EXTERN_C const IID IID_ID3D11DomainShader; #define ID3D11DomainShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DomainShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11GeometryShader_INTERFACE_DEFINED__ #define __ID3D11GeometryShader_INTERFACE_DEFINED__ /* interface ID3D11GeometryShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11GeometryShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5371,7 +5146,6 @@ EXTERN_C const IID IID_ID3D11GeometryShader; #ifdef COBJMACROS - #define ID3D11GeometryShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5381,7 +5155,6 @@ EXTERN_C const IID IID_ID3D11GeometryShader; #define ID3D11GeometryShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11GeometryShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5394,25 +5167,18 @@ EXTERN_C const IID IID_ID3D11GeometryShader; #define ID3D11GeometryShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11GeometryShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11PixelShader_INTERFACE_DEFINED__ #define __ID3D11PixelShader_INTERFACE_DEFINED__ /* interface ID3D11PixelShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11PixelShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5484,7 +5250,6 @@ EXTERN_C const IID IID_ID3D11PixelShader; #ifdef COBJMACROS - #define ID3D11PixelShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5494,7 +5259,6 @@ EXTERN_C const IID IID_ID3D11PixelShader; #define ID3D11PixelShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11PixelShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5507,25 +5271,18 @@ EXTERN_C const IID IID_ID3D11PixelShader; #define ID3D11PixelShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11PixelShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11ComputeShader_INTERFACE_DEFINED__ #define __ID3D11ComputeShader_INTERFACE_DEFINED__ /* interface ID3D11ComputeShader */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ComputeShader; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5597,7 +5354,6 @@ EXTERN_C const IID IID_ID3D11ComputeShader; #ifdef COBJMACROS - #define ID3D11ComputeShader_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5607,7 +5363,6 @@ EXTERN_C const IID IID_ID3D11ComputeShader; #define ID3D11ComputeShader_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ComputeShader_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5620,25 +5375,18 @@ EXTERN_C const IID IID_ID3D11ComputeShader; #define ID3D11ComputeShader_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ComputeShader_INTERFACE_DEFINED__ */ - #ifndef __ID3D11InputLayout_INTERFACE_DEFINED__ #define __ID3D11InputLayout_INTERFACE_DEFINED__ /* interface ID3D11InputLayout */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11InputLayout; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5710,7 +5458,6 @@ EXTERN_C const IID IID_ID3D11InputLayout; #ifdef COBJMACROS - #define ID3D11InputLayout_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5720,7 +5467,6 @@ EXTERN_C const IID IID_ID3D11InputLayout; #define ID3D11InputLayout_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11InputLayout_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5733,18 +5479,12 @@ EXTERN_C const IID IID_ID3D11InputLayout; #define ID3D11InputLayout_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11InputLayout_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0021 */ /* [local] */ @@ -5939,7 +5679,6 @@ struct CD3D11_SAMPLER_DESC : public D3D11_SAMPLER_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0021_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0021_v0_0_s_ifspec; @@ -5949,7 +5688,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0021_v0_0_s_ifspec; /* interface ID3D11SamplerState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11SamplerState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6030,7 +5768,6 @@ EXTERN_C const IID IID_ID3D11SamplerState; #ifdef COBJMACROS - #define ID3D11SamplerState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6040,7 +5777,6 @@ EXTERN_C const IID IID_ID3D11SamplerState; #define ID3D11SamplerState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11SamplerState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6053,21 +5789,15 @@ EXTERN_C const IID IID_ID3D11SamplerState; #define ID3D11SamplerState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11SamplerState_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11SamplerState_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0022 */ /* [local] */ @@ -6124,8 +5854,6 @@ enum D3D11_FORMAT_SUPPORT2 D3D11_FORMAT_SUPPORT2_MULTIPLANE_OVERLAY = 0x4000 } D3D11_FORMAT_SUPPORT2; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0022_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0022_v0_0_s_ifspec; @@ -6135,7 +5863,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0022_v0_0_s_ifspec; /* interface ID3D11Asynchronous */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Asynchronous; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6212,7 +5939,6 @@ EXTERN_C const IID IID_ID3D11Asynchronous; #ifdef COBJMACROS - #define ID3D11Asynchronous_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6222,7 +5948,6 @@ EXTERN_C const IID IID_ID3D11Asynchronous; #define ID3D11Asynchronous_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Asynchronous_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6235,21 +5960,15 @@ EXTERN_C const IID IID_ID3D11Asynchronous; #define ID3D11Asynchronous_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Asynchronous_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Asynchronous_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0023 */ /* [local] */ @@ -6314,7 +6033,6 @@ struct CD3D11_QUERY_DESC : public D3D11_QUERY_DESC extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0023_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0023_v0_0_s_ifspec; @@ -6324,7 +6042,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0023_v0_0_s_ifspec; /* interface ID3D11Query */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Query; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6408,7 +6125,6 @@ EXTERN_C const IID IID_ID3D11Query; #ifdef COBJMACROS - #define ID3D11Query_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6418,7 +6134,6 @@ EXTERN_C const IID IID_ID3D11Query; #define ID3D11Query_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Query_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6431,32 +6146,24 @@ EXTERN_C const IID IID_ID3D11Query; #define ID3D11Query_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Query_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D11Query_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Query_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Predicate_INTERFACE_DEFINED__ #define __ID3D11Predicate_INTERFACE_DEFINED__ /* interface ID3D11Predicate */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Predicate; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6536,7 +6243,6 @@ EXTERN_C const IID IID_ID3D11Predicate; #ifdef COBJMACROS - #define ID3D11Predicate_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6546,7 +6252,6 @@ EXTERN_C const IID IID_ID3D11Predicate; #define ID3D11Predicate_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Predicate_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6559,26 +6264,18 @@ EXTERN_C const IID IID_ID3D11Predicate; #define ID3D11Predicate_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Predicate_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D11Predicate_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Predicate_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0025 */ /* [local] */ @@ -6658,8 +6355,6 @@ typedef struct D3D11_COUNTER_INFO UINT8 NumDetectableParallelUnits; } D3D11_COUNTER_INFO; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0025_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0025_v0_0_s_ifspec; @@ -6669,7 +6364,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0025_v0_0_s_ifspec; /* interface ID3D11Counter */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Counter; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6753,7 +6447,6 @@ EXTERN_C const IID IID_ID3D11Counter; #ifdef COBJMACROS - #define ID3D11Counter_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6763,7 +6456,6 @@ EXTERN_C const IID IID_ID3D11Counter; #define ID3D11Counter_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Counter_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6776,25 +6468,18 @@ EXTERN_C const IID IID_ID3D11Counter; #define ID3D11Counter_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Counter_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D11Counter_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Counter_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0026 */ /* [local] */ @@ -6824,8 +6509,6 @@ typedef struct D3D11_CLASS_INSTANCE_DESC BOOL Created; } D3D11_CLASS_INSTANCE_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0026_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0026_v0_0_s_ifspec; @@ -6835,7 +6518,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0026_v0_0_s_ifspec; /* interface ID3D11ClassInstance */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ClassInstance; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6951,7 +6633,6 @@ EXTERN_C const IID IID_ID3D11ClassInstance; #ifdef COBJMACROS - #define ID3D11ClassInstance_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6961,7 +6642,6 @@ EXTERN_C const IID IID_ID3D11ClassInstance; #define ID3D11ClassInstance_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ClassInstance_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -6974,7 +6654,6 @@ EXTERN_C const IID IID_ID3D11ClassInstance; #define ID3D11ClassInstance_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11ClassInstance_GetClassLinkage(This,ppLinkage) \ ( (This)->lpVtbl -> GetClassLinkage(This,ppLinkage) ) @@ -6989,22 +6668,16 @@ EXTERN_C const IID IID_ID3D11ClassInstance; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ClassInstance_INTERFACE_DEFINED__ */ - #ifndef __ID3D11ClassLinkage_INTERFACE_DEFINED__ #define __ID3D11ClassLinkage_INTERFACE_DEFINED__ /* interface ID3D11ClassLinkage */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ClassLinkage; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -7122,7 +6795,6 @@ EXTERN_C const IID IID_ID3D11ClassLinkage; #ifdef COBJMACROS - #define ID3D11ClassLinkage_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -7132,7 +6804,6 @@ EXTERN_C const IID IID_ID3D11ClassLinkage; #define ID3D11ClassLinkage_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ClassLinkage_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -7145,7 +6816,6 @@ EXTERN_C const IID IID_ID3D11ClassLinkage; #define ID3D11ClassLinkage_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11ClassLinkage_GetClassInstance(This,pClassInstanceName,InstanceIndex,ppInstance) \ ( (This)->lpVtbl -> GetClassInstance(This,pClassInstanceName,InstanceIndex,ppInstance) ) @@ -7154,22 +6824,16 @@ EXTERN_C const IID IID_ID3D11ClassLinkage; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ClassLinkage_INTERFACE_DEFINED__ */ - #ifndef __ID3D11CommandList_INTERFACE_DEFINED__ #define __ID3D11CommandList_INTERFACE_DEFINED__ /* interface ID3D11CommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11CommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -7246,7 +6910,6 @@ EXTERN_C const IID IID_ID3D11CommandList; #ifdef COBJMACROS - #define ID3D11CommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -7256,7 +6919,6 @@ EXTERN_C const IID IID_ID3D11CommandList; #define ID3D11CommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11CommandList_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -7269,21 +6931,15 @@ EXTERN_C const IID IID_ID3D11CommandList; #define ID3D11CommandList_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11CommandList_GetContextFlags(This) \ ( (This)->lpVtbl -> GetContextFlags(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11CommandList_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0029 */ /* [local] */ @@ -7478,8 +7134,6 @@ typedef struct D3D11_FEATURE_DATA_SHADER_CACHE UINT SupportFlags; } D3D11_FEATURE_DATA_SHADER_CACHE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0029_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0029_v0_0_s_ifspec; @@ -7489,7 +7143,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0029_v0_0_s_ifspec; /* interface ID3D11DeviceContext */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceContext; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -9271,7 +8924,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext; #ifdef COBJMACROS - #define ID3D11DeviceContext_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -9281,7 +8933,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext; #define ID3D11DeviceContext_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceContext_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -9294,7 +8945,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext; #define ID3D11DeviceContext_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DeviceContext_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -9621,15 +9271,10 @@ EXTERN_C const IID IID_ID3D11DeviceContext; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceContext_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0030 */ /* [local] */ @@ -9640,7 +9285,6 @@ extern const DECLSPEC_SELECTANY CD3D11_VIDEO_DEFAULT D3D11_VIDEO_DEFAULT; extern "C"{ #endif - #if !defined(APP_DEPRECATED_HRESULT) && !defined(APP_DEPRECATED_HRESULT_TYPEDEF) #define APP_DEPRECATED_HRESULT_TYPEDEF typedef HRESULT APP_DEPRECATED_HRESULT; @@ -9768,8 +9412,6 @@ typedef struct D3D11_VIDEO_DECODER_EXTENSION _Field_size_opt_(ResourceCount) ID3D11Resource **ppResourceList; } D3D11_VIDEO_DECODER_EXTENSION; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0030_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0030_v0_0_s_ifspec; @@ -9779,7 +9421,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0030_v0_0_s_ifspec; /* interface ID3D11VideoDecoder */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoDecoder; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -9873,7 +9514,6 @@ EXTERN_C const IID IID_ID3D11VideoDecoder; #ifdef COBJMACROS - #define ID3D11VideoDecoder_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -9883,7 +9523,6 @@ EXTERN_C const IID IID_ID3D11VideoDecoder; #define ID3D11VideoDecoder_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoDecoder_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -9896,7 +9535,6 @@ EXTERN_C const IID IID_ID3D11VideoDecoder; #define ID3D11VideoDecoder_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoDecoder_GetCreationParameters(This,pVideoDesc,pConfig) \ ( (This)->lpVtbl -> GetCreationParameters(This,pVideoDesc,pConfig) ) @@ -9905,15 +9543,10 @@ EXTERN_C const IID IID_ID3D11VideoDecoder; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoDecoder_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0031 */ /* [local] */ @@ -10132,8 +9765,6 @@ typedef struct D3D11_VIDEO_PROCESSOR_CONTENT_DESC D3D11_VIDEO_USAGE Usage; } D3D11_VIDEO_PROCESSOR_CONTENT_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0031_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0031_v0_0_s_ifspec; @@ -10143,7 +9774,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0031_v0_0_s_ifspec; /* interface ID3D11VideoProcessorEnumerator */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -10289,7 +9919,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator; #ifdef COBJMACROS - #define ID3D11VideoProcessorEnumerator_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -10299,7 +9928,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator; #define ID3D11VideoProcessorEnumerator_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoProcessorEnumerator_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -10312,7 +9940,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator; #define ID3D11VideoProcessorEnumerator_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoProcessorEnumerator_GetVideoProcessorContentDesc(This,pContentDesc) \ ( (This)->lpVtbl -> GetVideoProcessorContentDesc(This,pContentDesc) ) @@ -10333,15 +9960,10 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoProcessorEnumerator_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0032 */ /* [local] */ @@ -10454,8 +10076,6 @@ typedef struct D3D11_VIDEO_PROCESSOR_STREAM _Field_size_(FutureFrames) ID3D11VideoProcessorInputView **ppFutureSurfacesRight; } D3D11_VIDEO_PROCESSOR_STREAM; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0032_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0032_v0_0_s_ifspec; @@ -10465,7 +10085,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0032_v0_0_s_ifspec; /* interface ID3D11VideoProcessor */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoProcessor; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -10555,7 +10174,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessor; #ifdef COBJMACROS - #define ID3D11VideoProcessor_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -10565,7 +10183,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessor; #define ID3D11VideoProcessor_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoProcessor_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -10578,7 +10195,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessor; #define ID3D11VideoProcessor_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoProcessor_GetContentDesc(This,pDesc) \ ( (This)->lpVtbl -> GetContentDesc(This,pDesc) ) @@ -10587,15 +10203,10 @@ EXTERN_C const IID IID_ID3D11VideoProcessor; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoProcessor_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0033 */ /* [local] */ @@ -10612,8 +10223,6 @@ enum D3D11_AUTHENTICATED_CHANNEL_TYPE D3D11_AUTHENTICATED_CHANNEL_DRIVER_HARDWARE = 3 } D3D11_AUTHENTICATED_CHANNEL_TYPE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0033_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0033_v0_0_s_ifspec; @@ -10623,7 +10232,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0033_v0_0_s_ifspec; /* interface ID3D11AuthenticatedChannel */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11AuthenticatedChannel; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -10726,7 +10334,6 @@ EXTERN_C const IID IID_ID3D11AuthenticatedChannel; #ifdef COBJMACROS - #define ID3D11AuthenticatedChannel_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -10736,7 +10343,6 @@ EXTERN_C const IID IID_ID3D11AuthenticatedChannel; #define ID3D11AuthenticatedChannel_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11AuthenticatedChannel_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -10749,7 +10355,6 @@ EXTERN_C const IID IID_ID3D11AuthenticatedChannel; #define ID3D11AuthenticatedChannel_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11AuthenticatedChannel_GetCertificateSize(This,pCertificateSize) \ ( (This)->lpVtbl -> GetCertificateSize(This,pCertificateSize) ) @@ -10761,15 +10366,10 @@ EXTERN_C const IID IID_ID3D11AuthenticatedChannel; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11AuthenticatedChannel_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0034 */ /* [local] */ @@ -11019,7 +10619,6 @@ typedef struct D3D11_AUTHENTICATED_CONFIGURE_ACCESSIBLE_ENCRYPTION_INPUT DEFINE_GUID(D3D11_KEY_EXCHANGE_RSAES_OAEP, 0xc1949895, 0xd72a, 0x4a1d, 0x8e, 0x5d, 0xed, 0x85, 0x7d, 0x17, 0x15, 0x20); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0034_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0034_v0_0_s_ifspec; @@ -11029,7 +10628,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0034_v0_0_s_ifspec; /* interface ID3D11CryptoSession */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11CryptoSession; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -11150,7 +10748,6 @@ EXTERN_C const IID IID_ID3D11CryptoSession; #ifdef COBJMACROS - #define ID3D11CryptoSession_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -11160,7 +10757,6 @@ EXTERN_C const IID IID_ID3D11CryptoSession; #define ID3D11CryptoSession_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11CryptoSession_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -11173,7 +10769,6 @@ EXTERN_C const IID IID_ID3D11CryptoSession; #define ID3D11CryptoSession_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11CryptoSession_GetCryptoType(This,pCryptoType) \ ( (This)->lpVtbl -> GetCryptoType(This,pCryptoType) ) @@ -11191,15 +10786,10 @@ EXTERN_C const IID IID_ID3D11CryptoSession; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11CryptoSession_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0035 */ /* [local] */ @@ -11225,8 +10815,6 @@ typedef struct D3D11_VIDEO_DECODER_OUTPUT_VIEW_DESC } ; } D3D11_VIDEO_DECODER_OUTPUT_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0035_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0035_v0_0_s_ifspec; @@ -11236,7 +10824,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0035_v0_0_s_ifspec; /* interface ID3D11VideoDecoderOutputView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoDecoderOutputView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -11322,7 +10909,6 @@ EXTERN_C const IID IID_ID3D11VideoDecoderOutputView; #ifdef COBJMACROS - #define ID3D11VideoDecoderOutputView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -11332,7 +10918,6 @@ EXTERN_C const IID IID_ID3D11VideoDecoderOutputView; #define ID3D11VideoDecoderOutputView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoDecoderOutputView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -11345,25 +10930,18 @@ EXTERN_C const IID IID_ID3D11VideoDecoderOutputView; #define ID3D11VideoDecoderOutputView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoDecoderOutputView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11VideoDecoderOutputView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoDecoderOutputView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0036 */ /* [local] */ @@ -11390,8 +10968,6 @@ typedef struct D3D11_VIDEO_PROCESSOR_INPUT_VIEW_DESC } ; } D3D11_VIDEO_PROCESSOR_INPUT_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0036_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0036_v0_0_s_ifspec; @@ -11401,7 +10977,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0036_v0_0_s_ifspec; /* interface ID3D11VideoProcessorInputView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoProcessorInputView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -11487,7 +11062,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorInputView; #ifdef COBJMACROS - #define ID3D11VideoProcessorInputView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -11497,7 +11071,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorInputView; #define ID3D11VideoProcessorInputView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoProcessorInputView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -11510,25 +11083,18 @@ EXTERN_C const IID IID_ID3D11VideoProcessorInputView; #define ID3D11VideoProcessorInputView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoProcessorInputView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11VideoProcessorInputView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoProcessorInputView_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0037 */ /* [local] */ @@ -11562,8 +11128,6 @@ typedef struct D3D11_VIDEO_PROCESSOR_OUTPUT_VIEW_DESC } ; } D3D11_VIDEO_PROCESSOR_OUTPUT_VIEW_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0037_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0037_v0_0_s_ifspec; @@ -11573,7 +11137,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0037_v0_0_s_ifspec; /* interface ID3D11VideoProcessorOutputView */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoProcessorOutputView; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -11659,7 +11222,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorOutputView; #ifdef COBJMACROS - #define ID3D11VideoProcessorOutputView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -11669,7 +11231,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorOutputView; #define ID3D11VideoProcessorOutputView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoProcessorOutputView_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -11682,32 +11243,24 @@ EXTERN_C const IID IID_ID3D11VideoProcessorOutputView; #define ID3D11VideoProcessorOutputView_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoProcessorOutputView_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11VideoProcessorOutputView_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoProcessorOutputView_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VideoContext_INTERFACE_DEFINED__ #define __ID3D11VideoContext_INTERFACE_DEFINED__ /* interface ID3D11VideoContext */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoContext; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -12945,7 +12498,6 @@ EXTERN_C const IID IID_ID3D11VideoContext; #ifdef COBJMACROS - #define ID3D11VideoContext_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -12955,7 +12507,6 @@ EXTERN_C const IID IID_ID3D11VideoContext; #define ID3D11VideoContext_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoContext_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -12968,7 +12519,6 @@ EXTERN_C const IID IID_ID3D11VideoContext; #define ID3D11VideoContext_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoContext_GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) \ ( (This)->lpVtbl -> GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) ) @@ -13145,22 +12695,16 @@ EXTERN_C const IID IID_ID3D11VideoContext; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoContext_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VideoDevice_INTERFACE_DEFINED__ #define __ID3D11VideoDevice_INTERFACE_DEFINED__ /* interface ID3D11VideoDevice */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoDevice; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -13475,7 +13019,6 @@ EXTERN_C const IID IID_ID3D11VideoDevice; #ifdef COBJMACROS - #define ID3D11VideoDevice_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -13485,7 +13028,6 @@ EXTERN_C const IID IID_ID3D11VideoDevice; #define ID3D11VideoDevice_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoDevice_CreateVideoDecoder(This,pVideoDesc,pConfig,ppDecoder) \ ( (This)->lpVtbl -> CreateVideoDecoder(This,pVideoDesc,pConfig,ppDecoder) ) @@ -13539,21 +13081,15 @@ EXTERN_C const IID IID_ID3D11VideoDevice; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoDevice_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0040 */ /* [local] */ /*#include */ - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0040_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0040_v0_0_s_ifspec; @@ -13563,7 +13099,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0040_v0_0_s_ifspec; /* interface ID3D11Device */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -14237,7 +13772,6 @@ EXTERN_C const IID IID_ID3D11Device; #ifdef COBJMACROS - #define ID3D11Device_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -14247,7 +13781,6 @@ EXTERN_C const IID IID_ID3D11Device; #define ID3D11Device_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -14370,15 +13903,10 @@ EXTERN_C const IID IID_ID3D11Device; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_0000_0041 */ /* [local] */ @@ -14588,7 +14116,6 @@ DEFINE_GUID(IID_ID3D11VideoContext,0x61F21C45,0x3C0E,0x4a74,0x9C,0xEA,0x67,0x10, DEFINE_GUID(IID_ID3D11VideoDevice,0x10EC4D5B,0x975A,0x4689,0xB9,0xE4,0xD0,0xAA,0xC3,0x0F,0xE3,0x33); DEFINE_GUID(IID_ID3D11Device,0xdb6f6ddb,0xac77,0x4e88,0x82,0x53,0x81,0x9d,0xf9,0xbb,0xf1,0x40); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0041_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0041_v0_0_s_ifspec; @@ -14602,4 +14129,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_0000_0041_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11_1.h b/gfx/include/dxsdk/d3d11_1.h index 3d3bf303f1..fc7f378165 100644 --- a/gfx/include/dxsdk/d3d11_1.h +++ b/gfx/include/dxsdk/d3d11_1.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,63 +46,54 @@ typedef interface ID3D11BlendState1 ID3D11BlendState1; #endif /* __ID3D11BlendState1_FWD_DEFINED__ */ - #ifndef __ID3D11RasterizerState1_FWD_DEFINED__ #define __ID3D11RasterizerState1_FWD_DEFINED__ typedef interface ID3D11RasterizerState1 ID3D11RasterizerState1; #endif /* __ID3D11RasterizerState1_FWD_DEFINED__ */ - #ifndef __ID3DDeviceContextState_FWD_DEFINED__ #define __ID3DDeviceContextState_FWD_DEFINED__ typedef interface ID3DDeviceContextState ID3DDeviceContextState; #endif /* __ID3DDeviceContextState_FWD_DEFINED__ */ - #ifndef __ID3D11DeviceContext1_FWD_DEFINED__ #define __ID3D11DeviceContext1_FWD_DEFINED__ typedef interface ID3D11DeviceContext1 ID3D11DeviceContext1; #endif /* __ID3D11DeviceContext1_FWD_DEFINED__ */ - #ifndef __ID3D11VideoContext1_FWD_DEFINED__ #define __ID3D11VideoContext1_FWD_DEFINED__ typedef interface ID3D11VideoContext1 ID3D11VideoContext1; #endif /* __ID3D11VideoContext1_FWD_DEFINED__ */ - #ifndef __ID3D11VideoDevice1_FWD_DEFINED__ #define __ID3D11VideoDevice1_FWD_DEFINED__ typedef interface ID3D11VideoDevice1 ID3D11VideoDevice1; #endif /* __ID3D11VideoDevice1_FWD_DEFINED__ */ - #ifndef __ID3D11VideoProcessorEnumerator1_FWD_DEFINED__ #define __ID3D11VideoProcessorEnumerator1_FWD_DEFINED__ typedef interface ID3D11VideoProcessorEnumerator1 ID3D11VideoProcessorEnumerator1; #endif /* __ID3D11VideoProcessorEnumerator1_FWD_DEFINED__ */ - #ifndef __ID3D11Device1_FWD_DEFINED__ #define __ID3D11Device1_FWD_DEFINED__ typedef interface ID3D11Device1 ID3D11Device1; #endif /* __ID3D11Device1_FWD_DEFINED__ */ - #ifndef __ID3DUserDefinedAnnotation_FWD_DEFINED__ #define __ID3DUserDefinedAnnotation_FWD_DEFINED__ typedef interface ID3DUserDefinedAnnotation ID3DUserDefinedAnnotation; #endif /* __ID3DUserDefinedAnnotation_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -117,7 +104,6 @@ typedef interface ID3DUserDefinedAnnotation ID3DUserDefinedAnnotation; extern "C"{ #endif - /* interface __MIDL_itf_d3d11_1_0000_0000 */ /* [local] */ @@ -209,7 +195,6 @@ struct CD3D11_BLEND_DESC1 : public D3D11_BLEND_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0000_v0_0_s_ifspec; @@ -219,7 +204,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0000_v0_0_s_ifspec; /* interface ID3D11BlendState1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11BlendState1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -305,7 +289,6 @@ EXTERN_C const IID IID_ID3D11BlendState1; #ifdef COBJMACROS - #define ID3D11BlendState1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -315,7 +298,6 @@ EXTERN_C const IID IID_ID3D11BlendState1; #define ID3D11BlendState1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11BlendState1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -328,25 +310,18 @@ EXTERN_C const IID IID_ID3D11BlendState1; #define ID3D11BlendState1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11BlendState1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11BlendState1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11BlendState1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_1_0000_0001 */ /* [local] */ @@ -419,7 +394,6 @@ struct CD3D11_RASTERIZER_DESC1 : public D3D11_RASTERIZER_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0001_v0_0_s_ifspec; @@ -429,7 +403,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0001_v0_0_s_ifspec; /* interface ID3D11RasterizerState1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RasterizerState1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -515,7 +488,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState1; #ifdef COBJMACROS - #define ID3D11RasterizerState1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -525,7 +497,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState1; #define ID3D11RasterizerState1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RasterizerState1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -538,25 +509,18 @@ EXTERN_C const IID IID_ID3D11RasterizerState1; #define ID3D11RasterizerState1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11RasterizerState1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11RasterizerState1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RasterizerState1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_1_0000_0002 */ /* [local] */ @@ -566,8 +530,6 @@ enum D3D11_1_CREATE_DEVICE_CONTEXT_STATE_FLAG D3D11_1_CREATE_DEVICE_CONTEXT_STATE_SINGLETHREADED = 0x1 } D3D11_1_CREATE_DEVICE_CONTEXT_STATE_FLAG; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0002_v0_0_s_ifspec; @@ -577,7 +539,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0002_v0_0_s_ifspec; /* interface ID3DDeviceContextState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3DDeviceContextState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -649,7 +610,6 @@ EXTERN_C const IID IID_ID3DDeviceContextState; #ifdef COBJMACROS - #define ID3DDeviceContextState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -659,7 +619,6 @@ EXTERN_C const IID IID_ID3DDeviceContextState; #define ID3DDeviceContextState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3DDeviceContextState_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -672,25 +631,18 @@ EXTERN_C const IID IID_ID3DDeviceContextState; #define ID3DDeviceContextState_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3DDeviceContextState_INTERFACE_DEFINED__ */ - #ifndef __ID3D11DeviceContext1_INTERFACE_DEFINED__ #define __ID3D11DeviceContext1_INTERFACE_DEFINED__ /* interface ID3D11DeviceContext1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceContext1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2110,7 +2062,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext1; #ifdef COBJMACROS - #define ID3D11DeviceContext1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2120,7 +2071,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext1; #define ID3D11DeviceContext1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceContext1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2133,7 +2083,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext1; #define ID3D11DeviceContext1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DeviceContext1_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -2458,7 +2407,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext1; #define ID3D11DeviceContext1_FinishCommandList(This,RestoreDeferredContextState,ppCommandList) \ ( (This)->lpVtbl -> FinishCommandList(This,RestoreDeferredContextState,ppCommandList) ) - #define ID3D11DeviceContext1_CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) \ ( (This)->lpVtbl -> CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) ) @@ -2518,15 +2466,10 @@ EXTERN_C const IID IID_ID3D11DeviceContext1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceContext1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_1_0000_0004 */ /* [local] */ @@ -2629,8 +2572,6 @@ typedef struct D3D11_VIDEO_SAMPLE_DESC DXGI_COLOR_SPACE_TYPE ColorSpace; } D3D11_VIDEO_SAMPLE_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0004_v0_0_s_ifspec; @@ -2640,7 +2581,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0004_v0_0_s_ifspec; /* interface ID3D11VideoContext1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoContext1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3578,7 +3518,6 @@ EXTERN_C const IID IID_ID3D11VideoContext1; #ifdef COBJMACROS - #define ID3D11VideoContext1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3588,7 +3527,6 @@ EXTERN_C const IID IID_ID3D11VideoContext1; #define ID3D11VideoContext1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoContext1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3601,7 +3539,6 @@ EXTERN_C const IID IID_ID3D11VideoContext1; #define ID3D11VideoContext1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoContext1_GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) \ ( (This)->lpVtbl -> GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) ) @@ -3776,7 +3713,6 @@ EXTERN_C const IID IID_ID3D11VideoContext1; #define ID3D11VideoContext1_VideoProcessorGetStreamRotation(This,pVideoProcessor,StreamIndex,pEnable,pRotation) \ ( (This)->lpVtbl -> VideoProcessorGetStreamRotation(This,pVideoProcessor,StreamIndex,pEnable,pRotation) ) - #define ID3D11VideoContext1_SubmitDecoderBuffers1(This,pDecoder,NumBuffers,pBufferDesc) \ ( (This)->lpVtbl -> SubmitDecoderBuffers1(This,pDecoder,NumBuffers,pBufferDesc) ) @@ -3821,22 +3757,16 @@ EXTERN_C const IID IID_ID3D11VideoContext1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoContext1_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VideoDevice1_INTERFACE_DEFINED__ #define __ID3D11VideoDevice1_INTERFACE_DEFINED__ /* interface ID3D11VideoDevice1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoDevice1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4139,7 +4069,6 @@ EXTERN_C const IID IID_ID3D11VideoDevice1; #ifdef COBJMACROS - #define ID3D11VideoDevice1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4149,7 +4078,6 @@ EXTERN_C const IID IID_ID3D11VideoDevice1; #define ID3D11VideoDevice1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoDevice1_CreateVideoDecoder(This,pVideoDesc,pConfig,ppDecoder) \ ( (This)->lpVtbl -> CreateVideoDecoder(This,pVideoDesc,pConfig,ppDecoder) ) @@ -4201,7 +4129,6 @@ EXTERN_C const IID IID_ID3D11VideoDevice1; #define ID3D11VideoDevice1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoDevice1_GetCryptoSessionPrivateDataSize(This,pCryptoType,pDecoderProfile,pKeyExchangeType,pPrivateInputSize,pPrivateOutputSize) \ ( (This)->lpVtbl -> GetCryptoSessionPrivateDataSize(This,pCryptoType,pDecoderProfile,pKeyExchangeType,pPrivateInputSize,pPrivateOutputSize) ) @@ -4216,22 +4143,16 @@ EXTERN_C const IID IID_ID3D11VideoDevice1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoDevice1_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VideoProcessorEnumerator1_INTERFACE_DEFINED__ #define __ID3D11VideoProcessorEnumerator1_INTERFACE_DEFINED__ /* interface ID3D11VideoProcessorEnumerator1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4368,7 +4289,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator1; #ifdef COBJMACROS - #define ID3D11VideoProcessorEnumerator1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4378,7 +4298,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator1; #define ID3D11VideoProcessorEnumerator1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoProcessorEnumerator1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4391,7 +4310,6 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator1; #define ID3D11VideoProcessorEnumerator1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoProcessorEnumerator1_GetVideoProcessorContentDesc(This,pContentDesc) \ ( (This)->lpVtbl -> GetVideoProcessorContentDesc(This,pContentDesc) ) @@ -4410,28 +4328,21 @@ EXTERN_C const IID IID_ID3D11VideoProcessorEnumerator1; #define ID3D11VideoProcessorEnumerator1_GetVideoProcessorFilterRange(This,Filter,pRange) \ ( (This)->lpVtbl -> GetVideoProcessorFilterRange(This,Filter,pRange) ) - #define ID3D11VideoProcessorEnumerator1_CheckVideoProcessorFormatConversion(This,InputFormat,InputColorSpace,OutputFormat,OutputColorSpace,pSupported) \ ( (This)->lpVtbl -> CheckVideoProcessorFormatConversion(This,InputFormat,InputColorSpace,OutputFormat,OutputColorSpace,pSupported) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoProcessorEnumerator1_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Device1_INTERFACE_DEFINED__ #define __ID3D11Device1_INTERFACE_DEFINED__ /* interface ID3D11Device1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4918,7 +4829,6 @@ EXTERN_C const IID IID_ID3D11Device1; #ifdef COBJMACROS - #define ID3D11Device1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4928,7 +4838,6 @@ EXTERN_C const IID IID_ID3D11Device1; #define ID3D11Device1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device1_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -5049,7 +4958,6 @@ EXTERN_C const IID IID_ID3D11Device1; #define ID3D11Device1_GetExceptionMode(This) \ ( (This)->lpVtbl -> GetExceptionMode(This) ) - #define ID3D11Device1_GetImmediateContext1(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext1(This,ppImmediateContext) ) @@ -5073,22 +4981,16 @@ EXTERN_C const IID IID_ID3D11Device1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device1_INTERFACE_DEFINED__ */ - #ifndef __ID3DUserDefinedAnnotation_INTERFACE_DEFINED__ #define __ID3DUserDefinedAnnotation_INTERFACE_DEFINED__ /* interface ID3DUserDefinedAnnotation */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3DUserDefinedAnnotation; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5158,7 +5060,6 @@ EXTERN_C const IID IID_ID3DUserDefinedAnnotation; #ifdef COBJMACROS - #define ID3DUserDefinedAnnotation_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5168,7 +5069,6 @@ EXTERN_C const IID IID_ID3DUserDefinedAnnotation; #define ID3DUserDefinedAnnotation_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3DUserDefinedAnnotation_BeginEvent(This,Name) \ ( (This)->lpVtbl -> BeginEvent(This,Name) ) @@ -5183,15 +5083,10 @@ EXTERN_C const IID IID_ID3DUserDefinedAnnotation; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3DUserDefinedAnnotation_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_1_0000_0009 */ /* [local] */ @@ -5205,7 +5100,6 @@ DEFINE_GUID(IID_ID3D11VideoProcessorEnumerator1,0x465217F2,0x5568,0x43CF,0xB5,0x DEFINE_GUID(IID_ID3D11Device1,0xa04bfb29,0x08ef,0x43d6,0xa4,0x9c,0xa9,0xbd,0xbd,0xcb,0xe6,0x86); DEFINE_GUID(IID_ID3DUserDefinedAnnotation,0xb2daad8b,0x03d4,0x4dbf,0x95,0xeb,0x32,0xab,0x4b,0x63,0xd0,0xab); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0009_v0_0_s_ifspec; @@ -5219,4 +5113,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_1_0000_0009_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11_2.h b/gfx/include/dxsdk/d3d11_2.h index e8a07a9af0..b0476911ae 100644 --- a/gfx/include/dxsdk/d3d11_2.h +++ b/gfx/include/dxsdk/d3d11_2.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,14 +46,12 @@ typedef interface ID3D11DeviceContext2 ID3D11DeviceContext2; #endif /* __ID3D11DeviceContext2_FWD_DEFINED__ */ - #ifndef __ID3D11Device2_FWD_DEFINED__ #define __ID3D11Device2_FWD_DEFINED__ typedef interface ID3D11Device2 ID3D11Device2; #endif /* __ID3D11Device2_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -69,7 +63,6 @@ typedef interface ID3D11Device2 ID3D11Device2; extern "C"{ #endif - /* interface __MIDL_itf_d3d11_2_0000_0000 */ /* [local] */ @@ -150,8 +143,6 @@ enum D3D11_TILE_COPY_FLAG D3D11_TILE_COPY_SWIZZLED_TILED_RESOURCE_TO_LINEAR_BUFFER = 0x4 } D3D11_TILE_COPY_FLAG; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0000_v0_0_s_ifspec; @@ -161,7 +152,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0000_v0_0_s_ifspec; /* interface ID3D11DeviceContext2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceContext2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1557,7 +1547,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #ifdef COBJMACROS - #define ID3D11DeviceContext2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1567,7 +1556,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #define ID3D11DeviceContext2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceContext2_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1580,7 +1568,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #define ID3D11DeviceContext2_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DeviceContext2_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -1905,7 +1892,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #define ID3D11DeviceContext2_FinishCommandList(This,RestoreDeferredContextState,ppCommandList) \ ( (This)->lpVtbl -> FinishCommandList(This,RestoreDeferredContextState,ppCommandList) ) - #define ID3D11DeviceContext2_CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) \ ( (This)->lpVtbl -> CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) ) @@ -1963,7 +1949,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #define ID3D11DeviceContext2_DiscardView1(This,pResourceView,pRects,NumRects) \ ( (This)->lpVtbl -> DiscardView1(This,pResourceView,pRects,NumRects) ) - #define ID3D11DeviceContext2_UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) \ ( (This)->lpVtbl -> UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) ) @@ -1996,22 +1981,16 @@ EXTERN_C const IID IID_ID3D11DeviceContext2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceContext2_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Device2_INTERFACE_DEFINED__ #define __ID3D11Device2_INTERFACE_DEFINED__ /* interface ID3D11Device2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2521,7 +2500,6 @@ EXTERN_C const IID IID_ID3D11Device2; #ifdef COBJMACROS - #define ID3D11Device2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2531,7 +2509,6 @@ EXTERN_C const IID IID_ID3D11Device2; #define ID3D11Device2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device2_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -2652,7 +2629,6 @@ EXTERN_C const IID IID_ID3D11Device2; #define ID3D11Device2_GetExceptionMode(This) \ ( (This)->lpVtbl -> GetExceptionMode(This) ) - #define ID3D11Device2_GetImmediateContext1(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext1(This,ppImmediateContext) ) @@ -2674,7 +2650,6 @@ EXTERN_C const IID IID_ID3D11Device2; #define ID3D11Device2_OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) \ ( (This)->lpVtbl -> OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) ) - #define ID3D11Device2_GetImmediateContext2(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext2(This,ppImmediateContext) ) @@ -2689,22 +2664,16 @@ EXTERN_C const IID IID_ID3D11Device2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_2_0000_0002 */ /* [local] */ DEFINE_GUID(IID_ID3D11DeviceContext2,0x420d5b32,0xb90c,0x4da4,0xbe,0xf0,0x35,0x9f,0x6a,0x24,0xa8,0x3a); DEFINE_GUID(IID_ID3D11Device2,0x9d06dffa,0xd1e5,0x4d07,0x83,0xa8,0x1b,0xb1,0x23,0xf2,0xf8,0x41); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0002_v0_0_s_ifspec; @@ -2718,4 +2687,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_2_0000_0002_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11_3.h b/gfx/include/dxsdk/d3d11_3.h index 402a0e58bd..553c19897d 100644 --- a/gfx/include/dxsdk/d3d11_3.h +++ b/gfx/include/dxsdk/d3d11_3.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,77 +46,66 @@ typedef interface ID3D11Texture2D1 ID3D11Texture2D1; #endif /* __ID3D11Texture2D1_FWD_DEFINED__ */ - #ifndef __ID3D11Texture3D1_FWD_DEFINED__ #define __ID3D11Texture3D1_FWD_DEFINED__ typedef interface ID3D11Texture3D1 ID3D11Texture3D1; #endif /* __ID3D11Texture3D1_FWD_DEFINED__ */ - #ifndef __ID3D11RasterizerState2_FWD_DEFINED__ #define __ID3D11RasterizerState2_FWD_DEFINED__ typedef interface ID3D11RasterizerState2 ID3D11RasterizerState2; #endif /* __ID3D11RasterizerState2_FWD_DEFINED__ */ - #ifndef __ID3D11ShaderResourceView1_FWD_DEFINED__ #define __ID3D11ShaderResourceView1_FWD_DEFINED__ typedef interface ID3D11ShaderResourceView1 ID3D11ShaderResourceView1; #endif /* __ID3D11ShaderResourceView1_FWD_DEFINED__ */ - #ifndef __ID3D11RenderTargetView1_FWD_DEFINED__ #define __ID3D11RenderTargetView1_FWD_DEFINED__ typedef interface ID3D11RenderTargetView1 ID3D11RenderTargetView1; #endif /* __ID3D11RenderTargetView1_FWD_DEFINED__ */ - #ifndef __ID3D11UnorderedAccessView1_FWD_DEFINED__ #define __ID3D11UnorderedAccessView1_FWD_DEFINED__ typedef interface ID3D11UnorderedAccessView1 ID3D11UnorderedAccessView1; #endif /* __ID3D11UnorderedAccessView1_FWD_DEFINED__ */ - #ifndef __ID3D11Query1_FWD_DEFINED__ #define __ID3D11Query1_FWD_DEFINED__ typedef interface ID3D11Query1 ID3D11Query1; #endif /* __ID3D11Query1_FWD_DEFINED__ */ - #ifndef __ID3D11DeviceContext3_FWD_DEFINED__ #define __ID3D11DeviceContext3_FWD_DEFINED__ typedef interface ID3D11DeviceContext3 ID3D11DeviceContext3; #endif /* __ID3D11DeviceContext3_FWD_DEFINED__ */ - #ifndef __ID3D11Fence_FWD_DEFINED__ #define __ID3D11Fence_FWD_DEFINED__ typedef interface ID3D11Fence ID3D11Fence; #endif /* __ID3D11Fence_FWD_DEFINED__ */ - #ifndef __ID3D11DeviceContext4_FWD_DEFINED__ #define __ID3D11DeviceContext4_FWD_DEFINED__ typedef interface ID3D11DeviceContext4 ID3D11DeviceContext4; #endif /* __ID3D11DeviceContext4_FWD_DEFINED__ */ - #ifndef __ID3D11Device3_FWD_DEFINED__ #define __ID3D11Device3_FWD_DEFINED__ typedef interface ID3D11Device3 ID3D11Device3; #endif /* __ID3D11Device3_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -132,7 +117,6 @@ typedef interface ID3D11Device3 ID3D11Device3; extern "C"{ #endif - /* interface __MIDL_itf_d3d11_3_0000_0000 */ /* [local] */ @@ -235,7 +219,6 @@ struct CD3D11_TEXTURE2D_DESC1 : public D3D11_TEXTURE2D_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0000_v0_0_s_ifspec; @@ -245,7 +228,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0000_v0_0_s_ifspec; /* interface ID3D11Texture2D1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Texture2D1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -344,7 +326,6 @@ EXTERN_C const IID IID_ID3D11Texture2D1; #ifdef COBJMACROS - #define ID3D11Texture2D1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -354,7 +335,6 @@ EXTERN_C const IID IID_ID3D11Texture2D1; #define ID3D11Texture2D1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Texture2D1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -367,7 +347,6 @@ EXTERN_C const IID IID_ID3D11Texture2D1; #define ID3D11Texture2D1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Texture2D1_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -377,25 +356,18 @@ EXTERN_C const IID IID_ID3D11Texture2D1; #define ID3D11Texture2D1_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Texture2D1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11Texture2D1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Texture2D1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0001 */ /* [local] */ @@ -466,7 +438,6 @@ struct CD3D11_TEXTURE3D_DESC1 : public D3D11_TEXTURE3D_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0001_v0_0_s_ifspec; @@ -476,7 +447,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0001_v0_0_s_ifspec; /* interface ID3D11Texture3D1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Texture3D1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -575,7 +545,6 @@ EXTERN_C const IID IID_ID3D11Texture3D1; #ifdef COBJMACROS - #define ID3D11Texture3D1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -585,7 +554,6 @@ EXTERN_C const IID IID_ID3D11Texture3D1; #define ID3D11Texture3D1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Texture3D1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -598,7 +566,6 @@ EXTERN_C const IID IID_ID3D11Texture3D1; #define ID3D11Texture3D1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Texture3D1_GetType(This,pResourceDimension) \ ( (This)->lpVtbl -> GetType(This,pResourceDimension) ) @@ -608,25 +575,18 @@ EXTERN_C const IID IID_ID3D11Texture3D1; #define ID3D11Texture3D1_GetEvictionPriority(This) \ ( (This)->lpVtbl -> GetEvictionPriority(This) ) - #define ID3D11Texture3D1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11Texture3D1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Texture3D1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0002 */ /* [local] */ @@ -710,7 +670,6 @@ struct CD3D11_RASTERIZER_DESC2 : public D3D11_RASTERIZER_DESC2 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0002_v0_0_s_ifspec; @@ -720,7 +679,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0002_v0_0_s_ifspec; /* interface ID3D11RasterizerState2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RasterizerState2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -811,7 +769,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState2; #ifdef COBJMACROS - #define ID3D11RasterizerState2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -821,7 +778,6 @@ EXTERN_C const IID IID_ID3D11RasterizerState2; #define ID3D11RasterizerState2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RasterizerState2_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -834,29 +790,21 @@ EXTERN_C const IID IID_ID3D11RasterizerState2; #define ID3D11RasterizerState2_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11RasterizerState2_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11RasterizerState2_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) - #define ID3D11RasterizerState2_GetDesc2(This,pDesc) \ ( (This)->lpVtbl -> GetDesc2(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RasterizerState2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0003 */ /* [local] */ @@ -1109,7 +1057,6 @@ struct CD3D11_SHADER_RESOURCE_VIEW_DESC1 : public D3D11_SHADER_RESOURCE_VIEW_DES extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0003_v0_0_s_ifspec; @@ -1119,7 +1066,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0003_v0_0_s_ifspec; /* interface ID3D11ShaderResourceView1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ShaderResourceView1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1210,7 +1156,6 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView1; #ifdef COBJMACROS - #define ID3D11ShaderResourceView1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1220,7 +1165,6 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView1; #define ID3D11ShaderResourceView1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ShaderResourceView1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1233,29 +1177,21 @@ EXTERN_C const IID IID_ID3D11ShaderResourceView1; #define ID3D11ShaderResourceView1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11ShaderResourceView1_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11ShaderResourceView1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11ShaderResourceView1_GetDesc1(This,pDesc1) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc1) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ShaderResourceView1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0004 */ /* [local] */ @@ -1457,7 +1393,6 @@ struct CD3D11_RENDER_TARGET_VIEW_DESC1 : public D3D11_RENDER_TARGET_VIEW_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0004_v0_0_s_ifspec; @@ -1467,7 +1402,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0004_v0_0_s_ifspec; /* interface ID3D11RenderTargetView1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RenderTargetView1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1558,7 +1492,6 @@ EXTERN_C const IID IID_ID3D11RenderTargetView1; #ifdef COBJMACROS - #define ID3D11RenderTargetView1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1568,7 +1501,6 @@ EXTERN_C const IID IID_ID3D11RenderTargetView1; #define ID3D11RenderTargetView1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RenderTargetView1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1581,29 +1513,21 @@ EXTERN_C const IID IID_ID3D11RenderTargetView1; #define ID3D11RenderTargetView1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11RenderTargetView1_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11RenderTargetView1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11RenderTargetView1_GetDesc1(This,pDesc1) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc1) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RenderTargetView1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0005 */ /* [local] */ @@ -1793,7 +1717,6 @@ struct CD3D11_UNORDERED_ACCESS_VIEW_DESC1 : public D3D11_UNORDERED_ACCESS_VIEW_D extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0005_v0_0_s_ifspec; @@ -1803,7 +1726,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0005_v0_0_s_ifspec; /* interface ID3D11UnorderedAccessView1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11UnorderedAccessView1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1894,7 +1816,6 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView1; #ifdef COBJMACROS - #define ID3D11UnorderedAccessView1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1904,7 +1825,6 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView1; #define ID3D11UnorderedAccessView1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11UnorderedAccessView1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -1917,29 +1837,21 @@ EXTERN_C const IID IID_ID3D11UnorderedAccessView1; #define ID3D11UnorderedAccessView1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11UnorderedAccessView1_GetResource(This,ppResource) \ ( (This)->lpVtbl -> GetResource(This,ppResource) ) - #define ID3D11UnorderedAccessView1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11UnorderedAccessView1_GetDesc1(This,pDesc1) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc1) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11UnorderedAccessView1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0006 */ /* [local] */ @@ -1974,7 +1886,6 @@ struct CD3D11_QUERY_DESC1 : public D3D11_QUERY_DESC1 extern "C"{ #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0006_v0_0_s_ifspec; @@ -1984,7 +1895,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0006_v0_0_s_ifspec; /* interface ID3D11Query1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Query1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2073,7 +1983,6 @@ EXTERN_C const IID IID_ID3D11Query1; #ifdef COBJMACROS - #define ID3D11Query1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2083,7 +1992,6 @@ EXTERN_C const IID IID_ID3D11Query1; #define ID3D11Query1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Query1_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2096,29 +2004,21 @@ EXTERN_C const IID IID_ID3D11Query1; #define ID3D11Query1_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Query1_GetDataSize(This) \ ( (This)->lpVtbl -> GetDataSize(This) ) - #define ID3D11Query1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) - #define ID3D11Query1_GetDesc1(This,pDesc1) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc1) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Query1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0007 */ /* [local] */ @@ -2132,7 +2032,6 @@ enum D3D11_FENCE_FLAG DEFINE_ENUM_FLAG_OPERATORS(D3D11_FENCE_FLAG); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0007_v0_0_s_ifspec; @@ -2142,7 +2041,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0007_v0_0_s_ifspec; /* interface ID3D11DeviceContext3 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceContext3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3479,7 +3377,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #ifdef COBJMACROS - #define ID3D11DeviceContext3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3489,7 +3386,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #define ID3D11DeviceContext3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceContext3_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -3502,7 +3398,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #define ID3D11DeviceContext3_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DeviceContext3_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -3827,7 +3722,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #define ID3D11DeviceContext3_FinishCommandList(This,RestoreDeferredContextState,ppCommandList) \ ( (This)->lpVtbl -> FinishCommandList(This,RestoreDeferredContextState,ppCommandList) ) - #define ID3D11DeviceContext3_CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) \ ( (This)->lpVtbl -> CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) ) @@ -3885,7 +3779,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #define ID3D11DeviceContext3_DiscardView1(This,pResourceView,pRects,NumRects) \ ( (This)->lpVtbl -> DiscardView1(This,pResourceView,pRects,NumRects) ) - #define ID3D11DeviceContext3_UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) \ ( (This)->lpVtbl -> UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) ) @@ -3916,7 +3809,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #define ID3D11DeviceContext3_EndEvent(This) \ ( (This)->lpVtbl -> EndEvent(This) ) - #define ID3D11DeviceContext3_Flush1(This,ContextType,hEvent) \ ( (This)->lpVtbl -> Flush1(This,ContextType,hEvent) ) @@ -3928,22 +3820,16 @@ EXTERN_C const IID IID_ID3D11DeviceContext3; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceContext3_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Fence_INTERFACE_DEFINED__ #define __ID3D11Fence_INTERFACE_DEFINED__ /* interface ID3D11Fence */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Fence; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4054,7 +3940,6 @@ EXTERN_C const IID IID_ID3D11Fence; #ifdef COBJMACROS - #define ID3D11Fence_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4064,7 +3949,6 @@ EXTERN_C const IID IID_ID3D11Fence; #define ID3D11Fence_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Fence_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -4077,7 +3961,6 @@ EXTERN_C const IID IID_ID3D11Fence; #define ID3D11Fence_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11Fence_CreateSharedHandle(This,pAttributes,dwAccess,lpName,pHandle) \ ( (This)->lpVtbl -> CreateSharedHandle(This,pAttributes,dwAccess,lpName,pHandle) ) @@ -4089,22 +3972,16 @@ EXTERN_C const IID IID_ID3D11Fence; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Fence_INTERFACE_DEFINED__ */ - #ifndef __ID3D11DeviceContext4_INTERFACE_DEFINED__ #define __ID3D11DeviceContext4_INTERFACE_DEFINED__ /* interface ID3D11DeviceContext4 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11DeviceContext4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5454,7 +5331,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #ifdef COBJMACROS - #define ID3D11DeviceContext4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5464,7 +5340,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11DeviceContext4_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -5477,7 +5352,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11DeviceContext4_VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) \ ( (This)->lpVtbl -> VSSetConstantBuffers(This,StartSlot,NumBuffers,ppConstantBuffers) ) @@ -5802,7 +5676,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_FinishCommandList(This,RestoreDeferredContextState,ppCommandList) \ ( (This)->lpVtbl -> FinishCommandList(This,RestoreDeferredContextState,ppCommandList) ) - #define ID3D11DeviceContext4_CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) \ ( (This)->lpVtbl -> CopySubresourceRegion1(This,pDstResource,DstSubresource,DstX,DstY,DstZ,pSrcResource,SrcSubresource,pSrcBox,CopyFlags) ) @@ -5860,7 +5733,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_DiscardView1(This,pResourceView,pRects,NumRects) \ ( (This)->lpVtbl -> DiscardView1(This,pResourceView,pRects,NumRects) ) - #define ID3D11DeviceContext4_UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) \ ( (This)->lpVtbl -> UpdateTileMappings(This,pTiledResource,NumTiledResourceRegions,pTiledResourceRegionStartCoordinates,pTiledResourceRegionSizes,pTilePool,NumRanges,pRangeFlags,pTilePoolStartOffsets,pRangeTileCounts,Flags) ) @@ -5891,7 +5763,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_EndEvent(This) \ ( (This)->lpVtbl -> EndEvent(This) ) - #define ID3D11DeviceContext4_Flush1(This,ContextType,hEvent) \ ( (This)->lpVtbl -> Flush1(This,ContextType,hEvent) ) @@ -5901,7 +5772,6 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #define ID3D11DeviceContext4_GetHardwareProtectionState(This,pHwProtectionEnable) \ ( (This)->lpVtbl -> GetHardwareProtectionState(This,pHwProtectionEnable) ) - #define ID3D11DeviceContext4_Signal(This,pFence,Value) \ ( (This)->lpVtbl -> Signal(This,pFence,Value) ) @@ -5910,22 +5780,16 @@ EXTERN_C const IID IID_ID3D11DeviceContext4; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11DeviceContext4_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Device3_INTERFACE_DEFINED__ #define __ID3D11Device3_INTERFACE_DEFINED__ /* interface ID3D11Device3 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6589,7 +6453,6 @@ EXTERN_C const IID IID_ID3D11Device3; #ifdef COBJMACROS - #define ID3D11Device3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6599,7 +6462,6 @@ EXTERN_C const IID IID_ID3D11Device3; #define ID3D11Device3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device3_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -6720,7 +6582,6 @@ EXTERN_C const IID IID_ID3D11Device3; #define ID3D11Device3_GetExceptionMode(This) \ ( (This)->lpVtbl -> GetExceptionMode(This) ) - #define ID3D11Device3_GetImmediateContext1(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext1(This,ppImmediateContext) ) @@ -6742,7 +6603,6 @@ EXTERN_C const IID IID_ID3D11Device3; #define ID3D11Device3_OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) \ ( (This)->lpVtbl -> OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) ) - #define ID3D11Device3_GetImmediateContext2(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext2(This,ppImmediateContext) ) @@ -6755,7 +6615,6 @@ EXTERN_C const IID IID_ID3D11Device3; #define ID3D11Device3_CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) \ ( (This)->lpVtbl -> CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) ) - #define ID3D11Device3_CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) \ ( (This)->lpVtbl -> CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) ) @@ -6791,15 +6650,10 @@ EXTERN_C const IID IID_ID3D11Device3; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_3_0000_0011 */ /* [local] */ @@ -6815,7 +6669,6 @@ DEFINE_GUID(IID_ID3D11Fence,0xaffde9d1,0x1df7,0x4bb7,0x8a,0x34,0x0f,0x46,0x25,0x DEFINE_GUID(IID_ID3D11DeviceContext4,0x917600da,0xf58c,0x4c33,0x98,0xd8,0x3e,0x15,0xb3,0x90,0xfa,0x24); DEFINE_GUID(IID_ID3D11Device3,0xA05C8C37,0xD2C6,0x4732,0xB3,0xA0,0x9C,0xE0,0xB0,0xDC,0x9A,0xE6); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0011_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0011_v0_0_s_ifspec; @@ -6829,4 +6682,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_3_0000_0011_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11_4.h b/gfx/include/dxsdk/d3d11_4.h index 97592638d4..17890af310 100644 --- a/gfx/include/dxsdk/d3d11_4.h +++ b/gfx/include/dxsdk/d3d11_4.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,28 +46,24 @@ typedef interface ID3D11Device4 ID3D11Device4; #endif /* __ID3D11Device4_FWD_DEFINED__ */ - #ifndef __ID3D11Device5_FWD_DEFINED__ #define __ID3D11Device5_FWD_DEFINED__ typedef interface ID3D11Device5 ID3D11Device5; #endif /* __ID3D11Device5_FWD_DEFINED__ */ - #ifndef __ID3D11Multithread_FWD_DEFINED__ #define __ID3D11Multithread_FWD_DEFINED__ typedef interface ID3D11Multithread ID3D11Multithread; #endif /* __ID3D11Multithread_FWD_DEFINED__ */ - #ifndef __ID3D11VideoContext2_FWD_DEFINED__ #define __ID3D11VideoContext2_FWD_DEFINED__ typedef interface ID3D11VideoContext2 ID3D11VideoContext2; #endif /* __ID3D11VideoContext2_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -83,7 +75,6 @@ typedef interface ID3D11VideoContext2 ID3D11VideoContext2; extern "C"{ #endif - /* interface __MIDL_itf_d3d11_4_0000_0000 */ /* [local] */ @@ -97,7 +88,6 @@ extern "C"{ /*#pragma region App Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ - extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0000_v0_0_s_ifspec; @@ -107,7 +97,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0000_v0_0_s_ifspec; /* interface ID3D11Device4 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -704,7 +693,6 @@ EXTERN_C const IID IID_ID3D11Device4; #ifdef COBJMACROS - #define ID3D11Device4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -714,7 +702,6 @@ EXTERN_C const IID IID_ID3D11Device4; #define ID3D11Device4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device4_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -835,7 +822,6 @@ EXTERN_C const IID IID_ID3D11Device4; #define ID3D11Device4_GetExceptionMode(This) \ ( (This)->lpVtbl -> GetExceptionMode(This) ) - #define ID3D11Device4_GetImmediateContext1(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext1(This,ppImmediateContext) ) @@ -857,7 +843,6 @@ EXTERN_C const IID IID_ID3D11Device4; #define ID3D11Device4_OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) \ ( (This)->lpVtbl -> OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) ) - #define ID3D11Device4_GetImmediateContext2(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext2(This,ppImmediateContext) ) @@ -870,7 +855,6 @@ EXTERN_C const IID IID_ID3D11Device4; #define ID3D11Device4_CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) \ ( (This)->lpVtbl -> CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) ) - #define ID3D11Device4_CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) \ ( (This)->lpVtbl -> CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) ) @@ -904,7 +888,6 @@ EXTERN_C const IID IID_ID3D11Device4; #define ID3D11Device4_ReadFromSubresource(This,pDstData,DstRowPitch,DstDepthPitch,pSrcResource,SrcSubresource,pSrcBox) \ ( (This)->lpVtbl -> ReadFromSubresource(This,pDstData,DstRowPitch,DstDepthPitch,pSrcResource,SrcSubresource,pSrcBox) ) - #define ID3D11Device4_RegisterDeviceRemovedEvent(This,hEvent,pdwCookie) \ ( (This)->lpVtbl -> RegisterDeviceRemovedEvent(This,hEvent,pdwCookie) ) @@ -913,22 +896,16 @@ EXTERN_C const IID IID_ID3D11Device4; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device4_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Device5_INTERFACE_DEFINED__ #define __ID3D11Device5_INTERFACE_DEFINED__ /* interface ID3D11Device5 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Device5; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1553,7 +1530,6 @@ EXTERN_C const IID IID_ID3D11Device5; #ifdef COBJMACROS - #define ID3D11Device5_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1563,7 +1539,6 @@ EXTERN_C const IID IID_ID3D11Device5; #define ID3D11Device5_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Device5_CreateBuffer(This,pDesc,pInitialData,ppBuffer) \ ( (This)->lpVtbl -> CreateBuffer(This,pDesc,pInitialData,ppBuffer) ) @@ -1684,7 +1659,6 @@ EXTERN_C const IID IID_ID3D11Device5; #define ID3D11Device5_GetExceptionMode(This) \ ( (This)->lpVtbl -> GetExceptionMode(This) ) - #define ID3D11Device5_GetImmediateContext1(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext1(This,ppImmediateContext) ) @@ -1706,7 +1680,6 @@ EXTERN_C const IID IID_ID3D11Device5; #define ID3D11Device5_OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) \ ( (This)->lpVtbl -> OpenSharedResourceByName(This,lpName,dwDesiredAccess,returnedInterface,ppResource) ) - #define ID3D11Device5_GetImmediateContext2(This,ppImmediateContext) \ ( (This)->lpVtbl -> GetImmediateContext2(This,ppImmediateContext) ) @@ -1719,7 +1692,6 @@ EXTERN_C const IID IID_ID3D11Device5; #define ID3D11Device5_CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) \ ( (This)->lpVtbl -> CheckMultisampleQualityLevels1(This,Format,SampleCount,Flags,pNumQualityLevels) ) - #define ID3D11Device5_CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) \ ( (This)->lpVtbl -> CreateTexture2D1(This,pDesc1,pInitialData,ppTexture2D) ) @@ -1753,14 +1725,12 @@ EXTERN_C const IID IID_ID3D11Device5; #define ID3D11Device5_ReadFromSubresource(This,pDstData,DstRowPitch,DstDepthPitch,pSrcResource,SrcSubresource,pSrcBox) \ ( (This)->lpVtbl -> ReadFromSubresource(This,pDstData,DstRowPitch,DstDepthPitch,pSrcResource,SrcSubresource,pSrcBox) ) - #define ID3D11Device5_RegisterDeviceRemovedEvent(This,hEvent,pdwCookie) \ ( (This)->lpVtbl -> RegisterDeviceRemovedEvent(This,hEvent,pdwCookie) ) #define ID3D11Device5_UnregisterDeviceRemoved(This,dwCookie) \ ( (This)->lpVtbl -> UnregisterDeviceRemoved(This,dwCookie) ) - #define ID3D11Device5_OpenSharedFence(This,hFence,ReturnedInterface,ppFence) \ ( (This)->lpVtbl -> OpenSharedFence(This,hFence,ReturnedInterface,ppFence) ) @@ -1769,22 +1739,16 @@ EXTERN_C const IID IID_ID3D11Device5; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Device5_INTERFACE_DEFINED__ */ - #ifndef __ID3D11Multithread_INTERFACE_DEFINED__ #define __ID3D11Multithread_INTERFACE_DEFINED__ /* interface ID3D11Multithread */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Multithread; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1850,7 +1814,6 @@ EXTERN_C const IID IID_ID3D11Multithread; #ifdef COBJMACROS - #define ID3D11Multithread_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1860,7 +1823,6 @@ EXTERN_C const IID IID_ID3D11Multithread; #define ID3D11Multithread_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Multithread_Enter(This) \ ( (This)->lpVtbl -> Enter(This) ) @@ -1875,22 +1837,16 @@ EXTERN_C const IID IID_ID3D11Multithread; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Multithread_INTERFACE_DEFINED__ */ - #ifndef __ID3D11VideoContext2_INTERFACE_DEFINED__ #define __ID3D11VideoContext2_INTERFACE_DEFINED__ /* interface ID3D11VideoContext2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11VideoContext2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2800,7 +2756,6 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #ifdef COBJMACROS - #define ID3D11VideoContext2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2810,7 +2765,6 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #define ID3D11VideoContext2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11VideoContext2_GetDevice(This,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,ppDevice) ) @@ -2823,7 +2777,6 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #define ID3D11VideoContext2_SetPrivateDataInterface(This,guid,pData) \ ( (This)->lpVtbl -> SetPrivateDataInterface(This,guid,pData) ) - #define ID3D11VideoContext2_GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) \ ( (This)->lpVtbl -> GetDecoderBuffer(This,pDecoder,Type,pBufferSize,ppBuffer) ) @@ -2998,7 +2951,6 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #define ID3D11VideoContext2_VideoProcessorGetStreamRotation(This,pVideoProcessor,StreamIndex,pEnable,pRotation) \ ( (This)->lpVtbl -> VideoProcessorGetStreamRotation(This,pVideoProcessor,StreamIndex,pEnable,pRotation) ) - #define ID3D11VideoContext2_SubmitDecoderBuffers1(This,pDecoder,NumBuffers,pBufferDesc) \ ( (This)->lpVtbl -> SubmitDecoderBuffers1(This,pDecoder,NumBuffers,pBufferDesc) ) @@ -3041,7 +2993,6 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #define ID3D11VideoContext2_VideoProcessorGetBehaviorHints(This,pVideoProcessor,OutputWidth,OutputHeight,OutputFormat,StreamCount,pStreams,pBehaviorHints) \ ( (This)->lpVtbl -> VideoProcessorGetBehaviorHints(This,pVideoProcessor,OutputWidth,OutputHeight,OutputFormat,StreamCount,pStreams,pBehaviorHints) ) - #define ID3D11VideoContext2_VideoProcessorSetOutputHDRMetaData(This,pVideoProcessor,Type,Size,pHDRMetaData) \ ( (This)->lpVtbl -> VideoProcessorSetOutputHDRMetaData(This,pVideoProcessor,Type,Size,pHDRMetaData) ) @@ -3056,15 +3007,10 @@ EXTERN_C const IID IID_ID3D11VideoContext2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11VideoContext2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11_4_0000_0004 */ /* [local] */ @@ -3080,7 +3026,6 @@ DEFINE_GUID(IID_ID3D11Device5,0x8ffde202,0xa0e7,0x45df,0x9e,0x01,0xe8,0x37,0x80, DEFINE_GUID(IID_ID3D11Multithread,0x9B7E4E00,0x342C,0x4106,0xA1,0x9F,0x4F,0x27,0x04,0xF6,0x89,0xF0); DEFINE_GUID(IID_ID3D11VideoContext2,0xC4E7374C,0x6243,0x4D1B,0xAE,0x87,0x52,0xB4,0xF7,0x40,0xE2,0x61); - extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0004_v0_0_s_ifspec; @@ -3094,4 +3039,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11_4_0000_0004_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11on12.h b/gfx/include/dxsdk/d3d11on12.h index d0046e0d55..916f3599ba 100644 --- a/gfx/include/dxsdk/d3d11on12.h +++ b/gfx/include/dxsdk/d3d11on12.h @@ -4,14 +4,10 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -49,7 +45,6 @@ typedef interface ID3D11On12Device ID3D11On12Device; #endif /* __ID3D11On12Device_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -60,7 +55,6 @@ typedef interface ID3D11On12Device ID3D11On12Device; extern "C"{ #endif - /* interface __MIDL_itf_d3d11on12_0000_0000 */ /* [local] */ @@ -141,8 +135,6 @@ typedef struct D3D11_RESOURCE_FLAGS UINT StructureByteStride; } D3D11_RESOURCE_FLAGS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0000_v0_0_s_ifspec; @@ -152,7 +144,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0000_v0_0_s_ifspec; /* interface ID3D11On12Device */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11On12Device; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -228,7 +219,6 @@ EXTERN_C const IID IID_ID3D11On12Device; #ifdef COBJMACROS - #define ID3D11On12Device_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -238,7 +228,6 @@ EXTERN_C const IID IID_ID3D11On12Device; #define ID3D11On12Device_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11On12Device_CreateWrappedResource(This,pResource12,pFlags11,InState,OutState,riid,ppResource11) \ ( (This)->lpVtbl -> CreateWrappedResource(This,pResource12,pFlags11,InState,OutState,riid,ppResource11) ) @@ -250,15 +239,10 @@ EXTERN_C const IID IID_ID3D11On12Device; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11On12Device_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11on12_0000_0001 */ /* [local] */ @@ -266,7 +250,6 @@ EXTERN_C const IID IID_ID3D11On12Device; /*#pragma endregion*/ DEFINE_GUID(IID_ID3D11On12Device,0x85611e73,0x70a9,0x490e,0x96,0x14,0xa9,0xe3,0x02,0x77,0x79,0x04); - extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0001_v0_0_s_ifspec; @@ -280,4 +263,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11on12_0000_0001_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11sdklayers.h b/gfx/include/dxsdk/d3d11sdklayers.h index 8e0ef78e53..f5983bdae1 100644 --- a/gfx/include/dxsdk/d3d11sdklayers.h +++ b/gfx/include/dxsdk/d3d11sdklayers.h @@ -4,15 +4,11 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -50,42 +46,36 @@ typedef interface ID3D11Debug ID3D11Debug; #endif /* __ID3D11Debug_FWD_DEFINED__ */ - #ifndef __ID3D11SwitchToRef_FWD_DEFINED__ #define __ID3D11SwitchToRef_FWD_DEFINED__ typedef interface ID3D11SwitchToRef ID3D11SwitchToRef; #endif /* __ID3D11SwitchToRef_FWD_DEFINED__ */ - #ifndef __ID3D11TracingDevice_FWD_DEFINED__ #define __ID3D11TracingDevice_FWD_DEFINED__ typedef interface ID3D11TracingDevice ID3D11TracingDevice; #endif /* __ID3D11TracingDevice_FWD_DEFINED__ */ - #ifndef __ID3D11RefTrackingOptions_FWD_DEFINED__ #define __ID3D11RefTrackingOptions_FWD_DEFINED__ typedef interface ID3D11RefTrackingOptions ID3D11RefTrackingOptions; #endif /* __ID3D11RefTrackingOptions_FWD_DEFINED__ */ - #ifndef __ID3D11RefDefaultTrackingOptions_FWD_DEFINED__ #define __ID3D11RefDefaultTrackingOptions_FWD_DEFINED__ typedef interface ID3D11RefDefaultTrackingOptions ID3D11RefDefaultTrackingOptions; #endif /* __ID3D11RefDefaultTrackingOptions_FWD_DEFINED__ */ - #ifndef __ID3D11InfoQueue_FWD_DEFINED__ #define __ID3D11InfoQueue_FWD_DEFINED__ typedef interface ID3D11InfoQueue ID3D11InfoQueue; #endif /* __ID3D11InfoQueue_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -95,7 +85,6 @@ typedef interface ID3D11InfoQueue ID3D11InfoQueue; extern "C"{ #endif - /* interface __MIDL_itf_d3d11sdklayers_0000_0000 */ /* [local] */ @@ -129,7 +118,6 @@ enum D3D11_RLDO_FLAGS DEFINE_ENUM_FLAG_OPERATORS(D3D11_RLDO_FLAGS) - extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0000_v0_0_s_ifspec; @@ -139,7 +127,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0000_v0_0_s_ifspec; /* interface ID3D11Debug */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11Debug; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -248,7 +235,6 @@ EXTERN_C const IID IID_ID3D11Debug; #ifdef COBJMACROS - #define ID3D11Debug_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -258,7 +244,6 @@ EXTERN_C const IID IID_ID3D11Debug; #define ID3D11Debug_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11Debug_SetFeatureMask(This,Mask) \ ( (This)->lpVtbl -> SetFeatureMask(This,Mask) ) @@ -288,15 +273,10 @@ EXTERN_C const IID IID_ID3D11Debug; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11Debug_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11sdklayers_0000_0001 */ /* [local] */ @@ -306,7 +286,6 @@ EXTERN_C const IID IID_ID3D11Debug; /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ - extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0001_v0_0_s_ifspec; @@ -316,7 +295,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0001_v0_0_s_ifspec; /* interface ID3D11SwitchToRef */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11SwitchToRef; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -370,7 +348,6 @@ EXTERN_C const IID IID_ID3D11SwitchToRef; #ifdef COBJMACROS - #define ID3D11SwitchToRef_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -380,7 +357,6 @@ EXTERN_C const IID IID_ID3D11SwitchToRef; #define ID3D11SwitchToRef_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11SwitchToRef_SetUseRef(This,UseRef) \ ( (This)->lpVtbl -> SetUseRef(This,UseRef) ) @@ -389,15 +365,10 @@ EXTERN_C const IID IID_ID3D11SwitchToRef; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11SwitchToRef_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11sdklayers_0000_0002 */ /* [local] */ @@ -439,8 +410,6 @@ enum D3D11_SHADER_TRACKING_OPTION D3D11_SHADER_TRACKING_OPTION_ALL_OPTIONS = ( D3D11_SHADER_TRACKING_OPTION_ALL_HAZARDS_ALLOWING_SAME | D3D11_SHADER_TRACKING_OPTION_TRACK_UNINITIALIZED ) } D3D11_SHADER_TRACKING_OPTIONS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0002_v0_0_s_ifspec; @@ -450,7 +419,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0002_v0_0_s_ifspec; /* interface ID3D11TracingDevice */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11TracingDevice; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -518,7 +486,6 @@ EXTERN_C const IID IID_ID3D11TracingDevice; #ifdef COBJMACROS - #define ID3D11TracingDevice_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -528,7 +495,6 @@ EXTERN_C const IID IID_ID3D11TracingDevice; #define ID3D11TracingDevice_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11TracingDevice_SetShaderTrackingOptionsByType(This,ResourceTypeFlags,Options) \ ( (This)->lpVtbl -> SetShaderTrackingOptionsByType(This,ResourceTypeFlags,Options) ) @@ -537,22 +503,16 @@ EXTERN_C const IID IID_ID3D11TracingDevice; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11TracingDevice_INTERFACE_DEFINED__ */ - #ifndef __ID3D11RefTrackingOptions_INTERFACE_DEFINED__ #define __ID3D11RefTrackingOptions_INTERFACE_DEFINED__ /* interface ID3D11RefTrackingOptions */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RefTrackingOptions; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -601,7 +561,6 @@ EXTERN_C const IID IID_ID3D11RefTrackingOptions; #ifdef COBJMACROS - #define ID3D11RefTrackingOptions_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -611,28 +570,21 @@ EXTERN_C const IID IID_ID3D11RefTrackingOptions; #define ID3D11RefTrackingOptions_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RefTrackingOptions_SetTrackingOptions(This,uOptions) \ ( (This)->lpVtbl -> SetTrackingOptions(This,uOptions) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RefTrackingOptions_INTERFACE_DEFINED__ */ - #ifndef __ID3D11RefDefaultTrackingOptions_INTERFACE_DEFINED__ #define __ID3D11RefDefaultTrackingOptions_INTERFACE_DEFINED__ /* interface ID3D11RefDefaultTrackingOptions */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11RefDefaultTrackingOptions; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -683,7 +635,6 @@ EXTERN_C const IID IID_ID3D11RefDefaultTrackingOptions; #ifdef COBJMACROS - #define ID3D11RefDefaultTrackingOptions_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -693,21 +644,15 @@ EXTERN_C const IID IID_ID3D11RefDefaultTrackingOptions; #define ID3D11RefDefaultTrackingOptions_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11RefDefaultTrackingOptions_SetTrackingOptions(This,ResourceTypeFlags,Options) \ ( (This)->lpVtbl -> SetTrackingOptions(This,ResourceTypeFlags,Options) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11RefDefaultTrackingOptions_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11sdklayers_0000_0005 */ /* [local] */ @@ -2102,7 +2047,6 @@ typedef struct D3D11_INFO_QUEUE_FILTER #define D3D11_INFO_QUEUE_DEFAULT_MESSAGE_COUNT_LIMIT 1024 - extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0005_v0_0_s_ifspec; @@ -2112,7 +2056,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0005_v0_0_s_ifspec; /* interface ID3D11InfoQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11InfoQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2441,7 +2384,6 @@ EXTERN_C const IID IID_ID3D11InfoQueue; #ifdef COBJMACROS - #define ID3D11InfoQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2451,7 +2393,6 @@ EXTERN_C const IID IID_ID3D11InfoQueue; #define ID3D11InfoQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11InfoQueue_SetMessageCountLimit(This,MessageCountLimit) \ ( (This)->lpVtbl -> SetMessageCountLimit(This,MessageCountLimit) ) @@ -2559,15 +2500,10 @@ EXTERN_C const IID IID_ID3D11InfoQueue; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11InfoQueue_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11sdklayers_0000_0006 */ /* [local] */ @@ -2581,7 +2517,6 @@ DEFINE_GUID(IID_ID3D11RefTrackingOptions,0x193dacdf,0x0db2,0x4c05,0xa5,0x5c,0xef DEFINE_GUID(IID_ID3D11RefDefaultTrackingOptions,0x03916615,0xc644,0x418c,0x9b,0xf4,0x75,0xdb,0x5b,0xe6,0x3c,0xa0); DEFINE_GUID(IID_ID3D11InfoQueue,0x6543dbb6,0x1b48,0x42f5,0xab,0x82,0xe9,0x7e,0xc7,0x43,0x26,0xf6); - extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0006_v0_0_s_ifspec; @@ -2595,4 +2530,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11sdklayers_0000_0006_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d11shader.h b/gfx/include/dxsdk/d3d11shader.h index 84c36cf64c..c30bac8485 100644 --- a/gfx/include/dxsdk/d3d11shader.h +++ b/gfx/include/dxsdk/d3d11shader.h @@ -12,7 +12,6 @@ #include "d3dcommon.h" - typedef enum D3D11_SHADER_VERSION_TYPE { D3D11_SHVER_PIXEL_SHADER = 0, @@ -41,7 +40,6 @@ typedef D3D_RESOURCE_RETURN_TYPE D3D11_RESOURCE_RETURN_TYPE; typedef D3D_CBUFFER_TYPE D3D11_CBUFFER_TYPE; - typedef struct _D3D11_SIGNATURE_PARAMETER_DESC { LPCSTR SemanticName; // Name of the semantic @@ -167,7 +165,6 @@ typedef struct _D3D11_SHADER_INPUT_BIND_DESC #define D3D_SHADER_REQUIRES_LEVEL_9_COMPARISON_FILTERING 0x00000080 #define D3D_SHADER_REQUIRES_TILED_RESOURCES 0x00000100 - typedef struct _D3D11_LIBRARY_DESC { LPCSTR Creator; // The name of the originator of the library. @@ -232,7 +229,6 @@ typedef struct _D3D11_PARAMETER_DESC UINT FirstOutComponent; // The first output register component for this parameter. } D3D11_PARAMETER_DESC; - ////////////////////////////////////////////////////////////////////////////// // Interfaces //////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -454,7 +450,6 @@ DECLARE_INTERFACE_(ID3D11Module, IUnknown) _COM_Outptr_ interface ID3D11ModuleInstance ** ppModuleInstance) PURE; }; - // {469E07F7-045A-48D5-AA12-68A478CDF75D} interface DECLSPEC_UUID("469E07F7-045A-48D5-AA12-68A478CDF75D") ID3D11ModuleInstance; DEFINE_GUID(IID_ID3D11ModuleInstance, @@ -488,7 +483,6 @@ DECLARE_INTERFACE_(ID3D11ModuleInstance, IUnknown) STDMETHOD(BindResourceAsUnorderedAccessViewByName)(THIS_ _In_ LPCSTR pSrvName, _In_ UINT uDstUavSlot, _In_ UINT uCount) PURE; }; - // {59A6CD0E-E10D-4C1F-88C0-63ABA1DAF30E} interface DECLSPEC_UUID("59A6CD0E-E10D-4C1F-88C0-63ABA1DAF30E") ID3D11Linker; DEFINE_GUID(IID_ID3D11Linker, @@ -518,7 +512,6 @@ DECLARE_INTERFACE_(ID3D11Linker, IUnknown) STDMETHOD(AddClipPlaneFromCBuffer)(THIS_ _In_ UINT uCBufferSlot, _In_ UINT uCBufferEntry) PURE; }; - // {D80DD70C-8D2F-4751-94A1-03C79B3556DB} interface DECLSPEC_UUID("D80DD70C-8D2F-4751-94A1-03C79B3556DB") ID3D11LinkingNode; DEFINE_GUID(IID_ID3D11LinkingNode, @@ -534,7 +527,6 @@ DECLARE_INTERFACE_(ID3D11LinkingNode, IUnknown) STDMETHOD_(ULONG, Release)(THIS) PURE; }; - // {54133220-1CE8-43D3-8236-9855C5CEECFF} interface DECLSPEC_UUID("54133220-1CE8-43D3-8236-9855C5CEECFF") ID3D11FunctionLinkingGraph; DEFINE_GUID(IID_ID3D11FunctionLinkingGraph, @@ -584,7 +576,6 @@ DECLARE_INTERFACE_(ID3D11FunctionLinkingGraph, IUnknown) _COM_Outptr_ ID3DBlob ** ppBuffer) PURE; }; - ////////////////////////////////////////////////////////////////////////////// // APIs ////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// diff --git a/gfx/include/dxsdk/d3d11shadertracing.h b/gfx/include/dxsdk/d3d11shadertracing.h index 1291ec82f1..8c6b7a91b0 100644 --- a/gfx/include/dxsdk/d3d11shadertracing.h +++ b/gfx/include/dxsdk/d3d11shadertracing.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,14 +41,12 @@ typedef interface ID3D11ShaderTrace ID3D11ShaderTrace; #endif /* __ID3D11ShaderTrace_FWD_DEFINED__ */ - #ifndef __ID3D11ShaderTraceFactory_FWD_DEFINED__ #define __ID3D11ShaderTraceFactory_FWD_DEFINED__ typedef interface ID3D11ShaderTraceFactory ID3D11ShaderTraceFactory; #endif /* __ID3D11ShaderTraceFactory_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -61,7 +55,6 @@ typedef interface ID3D11ShaderTraceFactory ID3D11ShaderTraceFactory; extern "C"{ #endif - /* interface __MIDL_itf_d3d11ShaderTracing_0000_0000 */ /* [local] */ @@ -252,8 +245,6 @@ typedef struct D3D11_TRACE_STEP UINT64 CurrentGlobalCycle; } D3D11_TRACE_STEP; - - extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0000_v0_0_s_ifspec; @@ -263,7 +254,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0000_v0_0_s_ifspec; /* interface ID3D11ShaderTrace */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ShaderTrace; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -405,7 +395,6 @@ EXTERN_C const IID IID_ID3D11ShaderTrace; #ifdef COBJMACROS - #define ID3D11ShaderTrace_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -415,7 +404,6 @@ EXTERN_C const IID IID_ID3D11ShaderTrace; #define ID3D11ShaderTrace_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ShaderTrace_TraceReady(This,pTestCount) \ ( (This)->lpVtbl -> TraceReady(This,pTestCount) ) @@ -442,22 +430,16 @@ EXTERN_C const IID IID_ID3D11ShaderTrace; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ShaderTrace_INTERFACE_DEFINED__ */ - #ifndef __ID3D11ShaderTraceFactory_INTERFACE_DEFINED__ #define __ID3D11ShaderTraceFactory_INTERFACE_DEFINED__ /* interface ID3D11ShaderTraceFactory */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D11ShaderTraceFactory; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -516,7 +498,6 @@ EXTERN_C const IID IID_ID3D11ShaderTraceFactory; #ifdef COBJMACROS - #define ID3D11ShaderTraceFactory_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -526,21 +507,15 @@ EXTERN_C const IID IID_ID3D11ShaderTraceFactory; #define ID3D11ShaderTraceFactory_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D11ShaderTraceFactory_CreateShaderTrace(This,pShader,pTraceDesc,ppShaderTrace) \ ( (This)->lpVtbl -> CreateShaderTrace(This,pShader,pTraceDesc,ppShaderTrace) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D11ShaderTraceFactory_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d11ShaderTracing_0000_0002 */ /* [local] */ @@ -553,7 +528,6 @@ D3DDisassemble11Trace(_In_reads_bytes_(SrcDataSize) LPCVOID pSrcData, _In_ UINT Flags, _COM_Outptr_ interface ID3D10Blob** ppDisassembly); - extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0002_v0_0_s_ifspec; @@ -567,4 +541,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d11ShaderTracing_0000_0002_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d12.h b/gfx/include/dxsdk/d3d12.h index 1946eb3d03..881d16c993 100644 --- a/gfx/include/dxsdk/d3d12.h +++ b/gfx/include/dxsdk/d3d12.h @@ -4,14 +4,10 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -49,189 +45,162 @@ typedef interface ID3D12Object ID3D12Object; #endif /* __ID3D12Object_FWD_DEFINED__ */ - #ifndef __ID3D12DeviceChild_FWD_DEFINED__ #define __ID3D12DeviceChild_FWD_DEFINED__ typedef interface ID3D12DeviceChild ID3D12DeviceChild; #endif /* __ID3D12DeviceChild_FWD_DEFINED__ */ - #ifndef __ID3D12RootSignature_FWD_DEFINED__ #define __ID3D12RootSignature_FWD_DEFINED__ typedef interface ID3D12RootSignature ID3D12RootSignature; #endif /* __ID3D12RootSignature_FWD_DEFINED__ */ - #ifndef __ID3D12RootSignatureDeserializer_FWD_DEFINED__ #define __ID3D12RootSignatureDeserializer_FWD_DEFINED__ typedef interface ID3D12RootSignatureDeserializer ID3D12RootSignatureDeserializer; #endif /* __ID3D12RootSignatureDeserializer_FWD_DEFINED__ */ - #ifndef __ID3D12VersionedRootSignatureDeserializer_FWD_DEFINED__ #define __ID3D12VersionedRootSignatureDeserializer_FWD_DEFINED__ typedef interface ID3D12VersionedRootSignatureDeserializer ID3D12VersionedRootSignatureDeserializer; #endif /* __ID3D12VersionedRootSignatureDeserializer_FWD_DEFINED__ */ - #ifndef __ID3D12Pageable_FWD_DEFINED__ #define __ID3D12Pageable_FWD_DEFINED__ typedef interface ID3D12Pageable ID3D12Pageable; #endif /* __ID3D12Pageable_FWD_DEFINED__ */ - #ifndef __ID3D12Heap_FWD_DEFINED__ #define __ID3D12Heap_FWD_DEFINED__ typedef interface ID3D12Heap ID3D12Heap; #endif /* __ID3D12Heap_FWD_DEFINED__ */ - #ifndef __ID3D12Resource_FWD_DEFINED__ #define __ID3D12Resource_FWD_DEFINED__ typedef interface ID3D12Resource ID3D12Resource; #endif /* __ID3D12Resource_FWD_DEFINED__ */ - #ifndef __ID3D12CommandAllocator_FWD_DEFINED__ #define __ID3D12CommandAllocator_FWD_DEFINED__ typedef interface ID3D12CommandAllocator ID3D12CommandAllocator; #endif /* __ID3D12CommandAllocator_FWD_DEFINED__ */ - #ifndef __ID3D12Fence_FWD_DEFINED__ #define __ID3D12Fence_FWD_DEFINED__ typedef interface ID3D12Fence ID3D12Fence; #endif /* __ID3D12Fence_FWD_DEFINED__ */ - #ifndef __ID3D12Fence1_FWD_DEFINED__ #define __ID3D12Fence1_FWD_DEFINED__ typedef interface ID3D12Fence1 ID3D12Fence1; #endif /* __ID3D12Fence1_FWD_DEFINED__ */ - #ifndef __ID3D12PipelineState_FWD_DEFINED__ #define __ID3D12PipelineState_FWD_DEFINED__ typedef interface ID3D12PipelineState ID3D12PipelineState; #endif /* __ID3D12PipelineState_FWD_DEFINED__ */ - #ifndef __ID3D12DescriptorHeap_FWD_DEFINED__ #define __ID3D12DescriptorHeap_FWD_DEFINED__ typedef interface ID3D12DescriptorHeap ID3D12DescriptorHeap; #endif /* __ID3D12DescriptorHeap_FWD_DEFINED__ */ - #ifndef __ID3D12QueryHeap_FWD_DEFINED__ #define __ID3D12QueryHeap_FWD_DEFINED__ typedef interface ID3D12QueryHeap ID3D12QueryHeap; #endif /* __ID3D12QueryHeap_FWD_DEFINED__ */ - #ifndef __ID3D12CommandSignature_FWD_DEFINED__ #define __ID3D12CommandSignature_FWD_DEFINED__ typedef interface ID3D12CommandSignature ID3D12CommandSignature; #endif /* __ID3D12CommandSignature_FWD_DEFINED__ */ - #ifndef __ID3D12CommandList_FWD_DEFINED__ #define __ID3D12CommandList_FWD_DEFINED__ typedef interface ID3D12CommandList ID3D12CommandList; #endif /* __ID3D12CommandList_FWD_DEFINED__ */ - #ifndef __ID3D12GraphicsCommandList_FWD_DEFINED__ #define __ID3D12GraphicsCommandList_FWD_DEFINED__ typedef interface ID3D12GraphicsCommandList ID3D12GraphicsCommandList; #endif /* __ID3D12GraphicsCommandList_FWD_DEFINED__ */ - #ifndef __ID3D12GraphicsCommandList1_FWD_DEFINED__ #define __ID3D12GraphicsCommandList1_FWD_DEFINED__ typedef interface ID3D12GraphicsCommandList1 ID3D12GraphicsCommandList1; #endif /* __ID3D12GraphicsCommandList1_FWD_DEFINED__ */ - #ifndef __ID3D12GraphicsCommandList2_FWD_DEFINED__ #define __ID3D12GraphicsCommandList2_FWD_DEFINED__ typedef interface ID3D12GraphicsCommandList2 ID3D12GraphicsCommandList2; #endif /* __ID3D12GraphicsCommandList2_FWD_DEFINED__ */ - #ifndef __ID3D12CommandQueue_FWD_DEFINED__ #define __ID3D12CommandQueue_FWD_DEFINED__ typedef interface ID3D12CommandQueue ID3D12CommandQueue; #endif /* __ID3D12CommandQueue_FWD_DEFINED__ */ - #ifndef __ID3D12Device_FWD_DEFINED__ #define __ID3D12Device_FWD_DEFINED__ typedef interface ID3D12Device ID3D12Device; #endif /* __ID3D12Device_FWD_DEFINED__ */ - #ifndef __ID3D12PipelineLibrary_FWD_DEFINED__ #define __ID3D12PipelineLibrary_FWD_DEFINED__ typedef interface ID3D12PipelineLibrary ID3D12PipelineLibrary; #endif /* __ID3D12PipelineLibrary_FWD_DEFINED__ */ - #ifndef __ID3D12PipelineLibrary1_FWD_DEFINED__ #define __ID3D12PipelineLibrary1_FWD_DEFINED__ typedef interface ID3D12PipelineLibrary1 ID3D12PipelineLibrary1; #endif /* __ID3D12PipelineLibrary1_FWD_DEFINED__ */ - #ifndef __ID3D12Device1_FWD_DEFINED__ #define __ID3D12Device1_FWD_DEFINED__ typedef interface ID3D12Device1 ID3D12Device1; #endif /* __ID3D12Device1_FWD_DEFINED__ */ - #ifndef __ID3D12Device2_FWD_DEFINED__ #define __ID3D12Device2_FWD_DEFINED__ typedef interface ID3D12Device2 ID3D12Device2; #endif /* __ID3D12Device2_FWD_DEFINED__ */ - #ifndef __ID3D12Device3_FWD_DEFINED__ #define __ID3D12Device3_FWD_DEFINED__ typedef interface ID3D12Device3 ID3D12Device3; #endif /* __ID3D12Device3_FWD_DEFINED__ */ - #ifndef __ID3D12Tools_FWD_DEFINED__ #define __ID3D12Tools_FWD_DEFINED__ typedef interface ID3D12Tools ID3D12Tools; #endif /* __ID3D12Tools_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -243,7 +212,6 @@ typedef interface ID3D12Tools ID3D12Tools; extern "C"{ #endif - /* interface __MIDL_itf_d3d12_0000_0000 */ /* [local] */ @@ -1299,8 +1267,6 @@ typedef struct D3D12_RASTERIZER_DESC D3D12_CONSERVATIVE_RASTERIZATION_MODE ConservativeRaster; } D3D12_RASTERIZER_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0000_v0_0_s_ifspec; @@ -1310,7 +1276,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0000_v0_0_s_ifspec; /* interface ID3D12Object */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Object; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1389,7 +1354,6 @@ EXTERN_C const IID IID_ID3D12Object; #ifdef COBJMACROS - #define ID3D12Object_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1399,7 +1363,6 @@ EXTERN_C const IID IID_ID3D12Object; #define ID3D12Object_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Object_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1414,22 +1377,16 @@ EXTERN_C const IID IID_ID3D12Object; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Object_INTERFACE_DEFINED__ */ - #ifndef __ID3D12DeviceChild_INTERFACE_DEFINED__ #define __ID3D12DeviceChild_INTERFACE_DEFINED__ /* interface ID3D12DeviceChild */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DeviceChild; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1500,7 +1457,6 @@ EXTERN_C const IID IID_ID3D12DeviceChild; #ifdef COBJMACROS - #define ID3D12DeviceChild_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1510,7 +1466,6 @@ EXTERN_C const IID IID_ID3D12DeviceChild; #define ID3D12DeviceChild_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DeviceChild_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1523,28 +1478,21 @@ EXTERN_C const IID IID_ID3D12DeviceChild; #define ID3D12DeviceChild_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12DeviceChild_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DeviceChild_INTERFACE_DEFINED__ */ - #ifndef __ID3D12RootSignature_INTERFACE_DEFINED__ #define __ID3D12RootSignature_INTERFACE_DEFINED__ /* interface ID3D12RootSignature */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12RootSignature; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1611,7 +1559,6 @@ EXTERN_C const IID IID_ID3D12RootSignature; #ifdef COBJMACROS - #define ID3D12RootSignature_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1621,7 +1568,6 @@ EXTERN_C const IID IID_ID3D12RootSignature; #define ID3D12RootSignature_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12RootSignature_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1634,22 +1580,15 @@ EXTERN_C const IID IID_ID3D12RootSignature; #define ID3D12RootSignature_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12RootSignature_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12RootSignature_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0001 */ /* [local] */ @@ -2342,7 +2281,6 @@ enum D3D12_RESOURCE_BARRIER_TYPE D3D12_RESOURCE_BARRIER_TYPE_UAV = ( D3D12_RESOURCE_BARRIER_TYPE_ALIASING + 1 ) } D3D12_RESOURCE_BARRIER_TYPE; - typedef struct D3D12_RESOURCE_TRANSITION_BARRIER { ID3D12Resource *pResource; @@ -3193,8 +3131,6 @@ typedef struct D3D12_VERSIONED_ROOT_SIGNATURE_DESC } ; } D3D12_VERSIONED_ROOT_SIGNATURE_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0001_v0_0_s_ifspec; @@ -3204,7 +3140,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0001_v0_0_s_ifspec; /* interface ID3D12RootSignatureDeserializer */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12RootSignatureDeserializer; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3250,7 +3185,6 @@ EXTERN_C const IID IID_ID3D12RootSignatureDeserializer; #ifdef COBJMACROS - #define ID3D12RootSignatureDeserializer_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3260,28 +3194,21 @@ EXTERN_C const IID IID_ID3D12RootSignatureDeserializer; #define ID3D12RootSignatureDeserializer_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12RootSignatureDeserializer_GetRootSignatureDesc(This) \ ( (This)->lpVtbl -> GetRootSignatureDesc(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12RootSignatureDeserializer_INTERFACE_DEFINED__ */ - #ifndef __ID3D12VersionedRootSignatureDeserializer_INTERFACE_DEFINED__ #define __ID3D12VersionedRootSignatureDeserializer_INTERFACE_DEFINED__ /* interface ID3D12VersionedRootSignatureDeserializer */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VersionedRootSignatureDeserializer; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3336,7 +3263,6 @@ EXTERN_C const IID IID_ID3D12VersionedRootSignatureDeserializer; #ifdef COBJMACROS - #define ID3D12VersionedRootSignatureDeserializer_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3346,7 +3272,6 @@ EXTERN_C const IID IID_ID3D12VersionedRootSignatureDeserializer; #define ID3D12VersionedRootSignatureDeserializer_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VersionedRootSignatureDeserializer_GetRootSignatureDescAtVersion(This,convertToVersion,ppDesc) \ ( (This)->lpVtbl -> GetRootSignatureDescAtVersion(This,convertToVersion,ppDesc) ) @@ -3355,15 +3280,10 @@ EXTERN_C const IID IID_ID3D12VersionedRootSignatureDeserializer; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12VersionedRootSignatureDeserializer_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0003 */ /* [local] */ @@ -3590,9 +3510,6 @@ typedef struct D3D12_COMMAND_SIGNATURE_DESC UINT NodeMask; } D3D12_COMMAND_SIGNATURE_DESC; - - - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0003_v0_0_s_ifspec; @@ -3602,7 +3519,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0003_v0_0_s_ifspec; /* interface ID3D12Pageable */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Pageable; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3669,7 +3585,6 @@ EXTERN_C const IID IID_ID3D12Pageable; #ifdef COBJMACROS - #define ID3D12Pageable_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3679,7 +3594,6 @@ EXTERN_C const IID IID_ID3D12Pageable; #define ID3D12Pageable_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Pageable_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -3692,29 +3606,21 @@ EXTERN_C const IID IID_ID3D12Pageable; #define ID3D12Pageable_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Pageable_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Pageable_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Heap_INTERFACE_DEFINED__ #define __ID3D12Heap_INTERFACE_DEFINED__ /* interface ID3D12Heap */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Heap; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3786,7 +3692,6 @@ EXTERN_C const IID IID_ID3D12Heap; #ifdef COBJMACROS - #define ID3D12Heap_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3796,7 +3701,6 @@ EXTERN_C const IID IID_ID3D12Heap; #define ID3D12Heap_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Heap_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -3809,37 +3713,24 @@ EXTERN_C const IID IID_ID3D12Heap; #define ID3D12Heap_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Heap_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12Heap_GetDesc(This) \ ( (This)->lpVtbl -> GetDesc(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12Heap_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Resource_INTERFACE_DEFINED__ #define __ID3D12Resource_INTERFACE_DEFINED__ /* interface ID3D12Resource */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Resource; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -3975,7 +3866,6 @@ EXTERN_C const IID IID_ID3D12Resource; #ifdef COBJMACROS - #define ID3D12Resource_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -3985,7 +3875,6 @@ EXTERN_C const IID IID_ID3D12Resource; #define ID3D12Resource_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Resource_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -3998,12 +3887,9 @@ EXTERN_C const IID IID_ID3D12Resource; #define ID3D12Resource_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Resource_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12Resource_Map(This,Subresource,pReadRange,ppData) \ ( (This)->lpVtbl -> Map(This,Subresource,pReadRange,ppData) ) @@ -4027,26 +3913,16 @@ EXTERN_C const IID IID_ID3D12Resource; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12Resource_INTERFACE_DEFINED__ */ - #ifndef __ID3D12CommandAllocator_INTERFACE_DEFINED__ #define __ID3D12CommandAllocator_INTERFACE_DEFINED__ /* interface ID3D12CommandAllocator */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12CommandAllocator; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4118,7 +3994,6 @@ EXTERN_C const IID IID_ID3D12CommandAllocator; #ifdef COBJMACROS - #define ID3D12CommandAllocator_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4128,7 +4003,6 @@ EXTERN_C const IID IID_ID3D12CommandAllocator; #define ID3D12CommandAllocator_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12CommandAllocator_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4141,33 +4015,24 @@ EXTERN_C const IID IID_ID3D12CommandAllocator; #define ID3D12CommandAllocator_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12CommandAllocator_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12CommandAllocator_Reset(This) \ ( (This)->lpVtbl -> Reset(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12CommandAllocator_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Fence_INTERFACE_DEFINED__ #define __ID3D12Fence_INTERFACE_DEFINED__ /* interface ID3D12Fence */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Fence; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4255,7 +4120,6 @@ EXTERN_C const IID IID_ID3D12Fence; #ifdef COBJMACROS - #define ID3D12Fence_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4265,7 +4129,6 @@ EXTERN_C const IID IID_ID3D12Fence; #define ID3D12Fence_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Fence_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4278,12 +4141,9 @@ EXTERN_C const IID IID_ID3D12Fence; #define ID3D12Fence_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Fence_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12Fence_GetCompletedValue(This) \ ( (This)->lpVtbl -> GetCompletedValue(This) ) @@ -4295,22 +4155,16 @@ EXTERN_C const IID IID_ID3D12Fence; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Fence_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Fence1_INTERFACE_DEFINED__ #define __ID3D12Fence1_INTERFACE_DEFINED__ /* interface ID3D12Fence1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Fence1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4394,7 +4248,6 @@ EXTERN_C const IID IID_ID3D12Fence1; #ifdef COBJMACROS - #define ID3D12Fence1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4404,7 +4257,6 @@ EXTERN_C const IID IID_ID3D12Fence1; #define ID3D12Fence1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Fence1_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4417,12 +4269,9 @@ EXTERN_C const IID IID_ID3D12Fence1; #define ID3D12Fence1_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Fence1_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12Fence1_GetCompletedValue(This) \ ( (This)->lpVtbl -> GetCompletedValue(This) ) @@ -4432,28 +4281,21 @@ EXTERN_C const IID IID_ID3D12Fence1; #define ID3D12Fence1_Signal(This,Value) \ ( (This)->lpVtbl -> Signal(This,Value) ) - #define ID3D12Fence1_GetCreationFlags(This) \ ( (This)->lpVtbl -> GetCreationFlags(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Fence1_INTERFACE_DEFINED__ */ - #ifndef __ID3D12PipelineState_INTERFACE_DEFINED__ #define __ID3D12PipelineState_INTERFACE_DEFINED__ /* interface ID3D12PipelineState */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12PipelineState; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4527,7 +4369,6 @@ EXTERN_C const IID IID_ID3D12PipelineState; #ifdef COBJMACROS - #define ID3D12PipelineState_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4537,7 +4378,6 @@ EXTERN_C const IID IID_ID3D12PipelineState; #define ID3D12PipelineState_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12PipelineState_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4550,33 +4390,24 @@ EXTERN_C const IID IID_ID3D12PipelineState; #define ID3D12PipelineState_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12PipelineState_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12PipelineState_GetCachedBlob(This,ppBlob) \ ( (This)->lpVtbl -> GetCachedBlob(This,ppBlob) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12PipelineState_INTERFACE_DEFINED__ */ - #ifndef __ID3D12DescriptorHeap_INTERFACE_DEFINED__ #define __ID3D12DescriptorHeap_INTERFACE_DEFINED__ /* interface ID3D12DescriptorHeap */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DescriptorHeap; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4658,7 +4489,6 @@ EXTERN_C const IID IID_ID3D12DescriptorHeap; #ifdef COBJMACROS - #define ID3D12DescriptorHeap_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4668,7 +4498,6 @@ EXTERN_C const IID IID_ID3D12DescriptorHeap; #define ID3D12DescriptorHeap_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DescriptorHeap_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4681,12 +4510,9 @@ EXTERN_C const IID IID_ID3D12DescriptorHeap; #define ID3D12DescriptorHeap_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12DescriptorHeap_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12DescriptorHeap_GetDesc(This) \ ( (This)->lpVtbl -> GetDesc(This) ) @@ -4698,34 +4524,16 @@ EXTERN_C const IID IID_ID3D12DescriptorHeap; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - - - - - - - - - #endif /* __ID3D12DescriptorHeap_INTERFACE_DEFINED__ */ - #ifndef __ID3D12QueryHeap_INTERFACE_DEFINED__ #define __ID3D12QueryHeap_INTERFACE_DEFINED__ /* interface ID3D12QueryHeap */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12QueryHeap; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4792,7 +4600,6 @@ EXTERN_C const IID IID_ID3D12QueryHeap; #ifdef COBJMACROS - #define ID3D12QueryHeap_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4802,7 +4609,6 @@ EXTERN_C const IID IID_ID3D12QueryHeap; #define ID3D12QueryHeap_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12QueryHeap_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4815,30 +4621,21 @@ EXTERN_C const IID IID_ID3D12QueryHeap; #define ID3D12QueryHeap_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12QueryHeap_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12QueryHeap_INTERFACE_DEFINED__ */ - #ifndef __ID3D12CommandSignature_INTERFACE_DEFINED__ #define __ID3D12CommandSignature_INTERFACE_DEFINED__ /* interface ID3D12CommandSignature */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12CommandSignature; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -4905,7 +4702,6 @@ EXTERN_C const IID IID_ID3D12CommandSignature; #ifdef COBJMACROS - #define ID3D12CommandSignature_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -4915,7 +4711,6 @@ EXTERN_C const IID IID_ID3D12CommandSignature; #define ID3D12CommandSignature_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12CommandSignature_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -4928,30 +4723,21 @@ EXTERN_C const IID IID_ID3D12CommandSignature; #define ID3D12CommandSignature_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12CommandSignature_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12CommandSignature_INTERFACE_DEFINED__ */ - #ifndef __ID3D12CommandList_INTERFACE_DEFINED__ #define __ID3D12CommandList_INTERFACE_DEFINED__ /* interface ID3D12CommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12CommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5023,7 +4809,6 @@ EXTERN_C const IID IID_ID3D12CommandList; #ifdef COBJMACROS - #define ID3D12CommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5033,7 +4818,6 @@ EXTERN_C const IID IID_ID3D12CommandList; #define ID3D12CommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12CommandList_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -5046,32 +4830,24 @@ EXTERN_C const IID IID_ID3D12CommandList; #define ID3D12CommandList_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12CommandList_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12CommandList_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12CommandList_INTERFACE_DEFINED__ */ - #ifndef __ID3D12GraphicsCommandList_INTERFACE_DEFINED__ #define __ID3D12GraphicsCommandList_INTERFACE_DEFINED__ /* interface ID3D12GraphicsCommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12GraphicsCommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -5688,7 +5464,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList; #ifdef COBJMACROS - #define ID3D12GraphicsCommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -5698,7 +5473,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList; #define ID3D12GraphicsCommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12GraphicsCommandList_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -5711,15 +5485,12 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList; #define ID3D12GraphicsCommandList_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12GraphicsCommandList_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12GraphicsCommandList_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) - #define ID3D12GraphicsCommandList_Close(This) \ ( (This)->lpVtbl -> Close(This) ) @@ -5875,22 +5646,16 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12GraphicsCommandList_INTERFACE_DEFINED__ */ - #ifndef __ID3D12GraphicsCommandList1_INTERFACE_DEFINED__ #define __ID3D12GraphicsCommandList1_INTERFACE_DEFINED__ /* interface ID3D12GraphicsCommandList1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -6347,7 +6112,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #ifdef COBJMACROS - #define ID3D12GraphicsCommandList1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -6357,7 +6121,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #define ID3D12GraphicsCommandList1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12GraphicsCommandList1_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -6370,15 +6133,12 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #define ID3D12GraphicsCommandList1_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12GraphicsCommandList1_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12GraphicsCommandList1_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) - #define ID3D12GraphicsCommandList1_Close(This) \ ( (This)->lpVtbl -> Close(This) ) @@ -6532,7 +6292,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #define ID3D12GraphicsCommandList1_ExecuteIndirect(This,pCommandSignature,MaxCommandCount,pArgumentBuffer,ArgumentBufferOffset,pCountBuffer,CountBufferOffset) \ ( (This)->lpVtbl -> ExecuteIndirect(This,pCommandSignature,MaxCommandCount,pArgumentBuffer,ArgumentBufferOffset,pCountBuffer,CountBufferOffset) ) - #define ID3D12GraphicsCommandList1_AtomicCopyBufferUINT(This,pDstBuffer,DstOffset,pSrcBuffer,SrcOffset,Dependencies,ppDependentResources,pDependentSubresourceRanges) \ ( (This)->lpVtbl -> AtomicCopyBufferUINT(This,pDstBuffer,DstOffset,pSrcBuffer,SrcOffset,Dependencies,ppDependentResources,pDependentSubresourceRanges) ) @@ -6553,15 +6312,10 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12GraphicsCommandList1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0018 */ /* [local] */ @@ -6579,8 +6333,6 @@ enum D3D12_WRITEBUFFERIMMEDIATE_MODE D3D12_WRITEBUFFERIMMEDIATE_MODE_MARKER_OUT = 0x2 } D3D12_WRITEBUFFERIMMEDIATE_MODE; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0018_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0018_v0_0_s_ifspec; @@ -6590,7 +6342,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0018_v0_0_s_ifspec; /* interface ID3D12GraphicsCommandList2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -7017,7 +6768,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #ifdef COBJMACROS - #define ID3D12GraphicsCommandList2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -7027,7 +6777,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #define ID3D12GraphicsCommandList2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12GraphicsCommandList2_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -7040,15 +6789,12 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #define ID3D12GraphicsCommandList2_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12GraphicsCommandList2_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12GraphicsCommandList2_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) - #define ID3D12GraphicsCommandList2_Close(This) \ ( (This)->lpVtbl -> Close(This) ) @@ -7202,7 +6948,6 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #define ID3D12GraphicsCommandList2_ExecuteIndirect(This,pCommandSignature,MaxCommandCount,pArgumentBuffer,ArgumentBufferOffset,pCountBuffer,CountBufferOffset) \ ( (This)->lpVtbl -> ExecuteIndirect(This,pCommandSignature,MaxCommandCount,pArgumentBuffer,ArgumentBufferOffset,pCountBuffer,CountBufferOffset) ) - #define ID3D12GraphicsCommandList2_AtomicCopyBufferUINT(This,pDstBuffer,DstOffset,pSrcBuffer,SrcOffset,Dependencies,ppDependentResources,pDependentSubresourceRanges) \ ( (This)->lpVtbl -> AtomicCopyBufferUINT(This,pDstBuffer,DstOffset,pSrcBuffer,SrcOffset,Dependencies,ppDependentResources,pDependentSubresourceRanges) ) @@ -7221,28 +6966,21 @@ EXTERN_C const IID IID_ID3D12GraphicsCommandList2; #define ID3D12GraphicsCommandList2_SetViewInstanceMask(This,Mask) \ ( (This)->lpVtbl -> SetViewInstanceMask(This,Mask) ) - #define ID3D12GraphicsCommandList2_WriteBufferImmediate(This,Count,pParams,pModes) \ ( (This)->lpVtbl -> WriteBufferImmediate(This,Count,pParams,pModes) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12GraphicsCommandList2_INTERFACE_DEFINED__ */ - #ifndef __ID3D12CommandQueue_INTERFACE_DEFINED__ #define __ID3D12CommandQueue_INTERFACE_DEFINED__ /* interface ID3D12CommandQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12CommandQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -7426,7 +7164,6 @@ EXTERN_C const IID IID_ID3D12CommandQueue; #ifdef COBJMACROS - #define ID3D12CommandQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -7436,7 +7173,6 @@ EXTERN_C const IID IID_ID3D12CommandQueue; #define ID3D12CommandQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12CommandQueue_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -7449,12 +7185,9 @@ EXTERN_C const IID IID_ID3D12CommandQueue; #define ID3D12CommandQueue_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12CommandQueue_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12CommandQueue_UpdateTileMappings(This,pResource,NumResourceRegions,pResourceRegionStartCoordinates,pResourceRegionSizes,pHeap,NumRanges,pRangeFlags,pHeapRangeStartOffsets,pRangeTileCounts,Flags) \ ( (This)->lpVtbl -> UpdateTileMappings(This,pResource,NumResourceRegions,pResourceRegionStartCoordinates,pResourceRegionSizes,pHeap,NumRanges,pRangeFlags,pHeapRangeStartOffsets,pRangeTileCounts,Flags) ) @@ -7490,19 +7223,10 @@ EXTERN_C const IID IID_ID3D12CommandQueue; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12CommandQueue_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0020 */ /* [local] */ @@ -7520,7 +7244,6 @@ typedef struct __LUID *PLUID; #endif #endif - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0020_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0020_v0_0_s_ifspec; @@ -7530,7 +7253,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0020_v0_0_s_ifspec; /* interface ID3D12Device */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Device; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -8033,7 +7755,6 @@ EXTERN_C const IID IID_ID3D12Device; #ifdef COBJMACROS - #define ID3D12Device_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -8043,7 +7764,6 @@ EXTERN_C const IID IID_ID3D12Device; #define ID3D12Device_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Device_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -8056,7 +7776,6 @@ EXTERN_C const IID IID_ID3D12Device; #define ID3D12Device_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Device_GetNodeCount(This) \ ( (This)->lpVtbl -> GetNodeCount(This) ) @@ -8170,34 +7889,16 @@ EXTERN_C const IID IID_ID3D12Device; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - - - - - - - - - #endif /* __ID3D12Device_INTERFACE_DEFINED__ */ - #ifndef __ID3D12PipelineLibrary_INTERFACE_DEFINED__ #define __ID3D12PipelineLibrary_INTERFACE_DEFINED__ /* interface ID3D12PipelineLibrary */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12PipelineLibrary; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -8313,7 +8014,6 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary; #ifdef COBJMACROS - #define ID3D12PipelineLibrary_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -8323,7 +8023,6 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary; #define ID3D12PipelineLibrary_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12PipelineLibrary_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -8336,11 +8035,9 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary; #define ID3D12PipelineLibrary_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12PipelineLibrary_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12PipelineLibrary_StorePipeline(This,pName,pPipeline) \ ( (This)->lpVtbl -> StorePipeline(This,pName,pPipeline) ) @@ -8358,22 +8055,16 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12PipelineLibrary_INTERFACE_DEFINED__ */ - #ifndef __ID3D12PipelineLibrary1_INTERFACE_DEFINED__ #define __ID3D12PipelineLibrary1_INTERFACE_DEFINED__ /* interface ID3D12PipelineLibrary1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12PipelineLibrary1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -8480,7 +8171,6 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary1; #ifdef COBJMACROS - #define ID3D12PipelineLibrary1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -8490,7 +8180,6 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary1; #define ID3D12PipelineLibrary1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12PipelineLibrary1_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -8503,11 +8192,9 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary1; #define ID3D12PipelineLibrary1_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12PipelineLibrary1_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12PipelineLibrary1_StorePipeline(This,pName,pPipeline) \ ( (This)->lpVtbl -> StorePipeline(This,pName,pPipeline) ) @@ -8523,21 +8210,15 @@ EXTERN_C const IID IID_ID3D12PipelineLibrary1; #define ID3D12PipelineLibrary1_Serialize(This,pData,DataSizeInBytes) \ ( (This)->lpVtbl -> Serialize(This,pData,DataSizeInBytes) ) - #define ID3D12PipelineLibrary1_LoadPipeline(This,pName,pDesc,riid,ppPipelineState) \ ( (This)->lpVtbl -> LoadPipeline(This,pName,pDesc,riid,ppPipelineState) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12PipelineLibrary1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0023 */ /* [local] */ @@ -8560,8 +8241,6 @@ enum D3D12_RESIDENCY_PRIORITY D3D12_RESIDENCY_PRIORITY_MAXIMUM = 0xc8000000 } D3D12_RESIDENCY_PRIORITY; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0023_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0023_v0_0_s_ifspec; @@ -8571,7 +8250,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0023_v0_0_s_ifspec; /* interface ID3D12Device1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Device1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -8911,7 +8589,6 @@ EXTERN_C const IID IID_ID3D12Device1; #ifdef COBJMACROS - #define ID3D12Device1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -8921,7 +8598,6 @@ EXTERN_C const IID IID_ID3D12Device1; #define ID3D12Device1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Device1_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -8934,7 +8610,6 @@ EXTERN_C const IID IID_ID3D12Device1; #define ID3D12Device1_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Device1_GetNodeCount(This) \ ( (This)->lpVtbl -> GetNodeCount(This) ) @@ -9046,7 +8721,6 @@ EXTERN_C const IID IID_ID3D12Device1; #define ID3D12Device1_GetAdapterLuid(This) \ ( (This)->lpVtbl -> GetAdapterLuid(This) ) - #define ID3D12Device1_CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) \ ( (This)->lpVtbl -> CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) ) @@ -9058,22 +8732,16 @@ EXTERN_C const IID IID_ID3D12Device1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Device1_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Device2_INTERFACE_DEFINED__ #define __ID3D12Device2_INTERFACE_DEFINED__ /* interface ID3D12Device2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Device2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -9406,7 +9074,6 @@ EXTERN_C const IID IID_ID3D12Device2; #ifdef COBJMACROS - #define ID3D12Device2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -9416,7 +9083,6 @@ EXTERN_C const IID IID_ID3D12Device2; #define ID3D12Device2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Device2_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -9429,7 +9095,6 @@ EXTERN_C const IID IID_ID3D12Device2; #define ID3D12Device2_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Device2_GetNodeCount(This) \ ( (This)->lpVtbl -> GetNodeCount(This) ) @@ -9541,7 +9206,6 @@ EXTERN_C const IID IID_ID3D12Device2; #define ID3D12Device2_GetAdapterLuid(This) \ ( (This)->lpVtbl -> GetAdapterLuid(This) ) - #define ID3D12Device2_CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) \ ( (This)->lpVtbl -> CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) ) @@ -9551,21 +9215,15 @@ EXTERN_C const IID IID_ID3D12Device2; #define ID3D12Device2_SetResidencyPriority(This,NumObjects,ppObjects,pPriorities) \ ( (This)->lpVtbl -> SetResidencyPriority(This,NumObjects,ppObjects,pPriorities) ) - #define ID3D12Device2_CreatePipelineState(This,pDesc,riid,ppPipelineState) \ ( (This)->lpVtbl -> CreatePipelineState(This,pDesc,riid,ppPipelineState) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Device2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0025 */ /* [local] */ @@ -9578,7 +9236,6 @@ enum D3D12_RESIDENCY_FLAGS DEFINE_ENUM_FLAG_OPERATORS( D3D12_RESIDENCY_FLAGS ); - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0025_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0025_v0_0_s_ifspec; @@ -9588,7 +9245,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0025_v0_0_s_ifspec; /* interface ID3D12Device3 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Device3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -9953,7 +9609,6 @@ EXTERN_C const IID IID_ID3D12Device3; #ifdef COBJMACROS - #define ID3D12Device3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -9963,7 +9618,6 @@ EXTERN_C const IID IID_ID3D12Device3; #define ID3D12Device3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Device3_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -9976,7 +9630,6 @@ EXTERN_C const IID IID_ID3D12Device3; #define ID3D12Device3_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12Device3_GetNodeCount(This) \ ( (This)->lpVtbl -> GetNodeCount(This) ) @@ -10088,7 +9741,6 @@ EXTERN_C const IID IID_ID3D12Device3; #define ID3D12Device3_GetAdapterLuid(This) \ ( (This)->lpVtbl -> GetAdapterLuid(This) ) - #define ID3D12Device3_CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) \ ( (This)->lpVtbl -> CreatePipelineLibrary(This,pLibraryBlob,BlobLength,riid,ppPipelineLibrary) ) @@ -10098,11 +9750,9 @@ EXTERN_C const IID IID_ID3D12Device3; #define ID3D12Device3_SetResidencyPriority(This,NumObjects,ppObjects,pPriorities) \ ( (This)->lpVtbl -> SetResidencyPriority(This,NumObjects,ppObjects,pPriorities) ) - #define ID3D12Device3_CreatePipelineState(This,pDesc,riid,ppPipelineState) \ ( (This)->lpVtbl -> CreatePipelineState(This,pDesc,riid,ppPipelineState) ) - #define ID3D12Device3_OpenExistingHeapFromAddress(This,pAddress,riid,ppvHeap) \ ( (This)->lpVtbl -> OpenExistingHeapFromAddress(This,pAddress,riid,ppvHeap) ) @@ -10114,22 +9764,16 @@ EXTERN_C const IID IID_ID3D12Device3; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Device3_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Tools_INTERFACE_DEFINED__ #define __ID3D12Tools_INTERFACE_DEFINED__ /* interface ID3D12Tools */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Tools; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -10182,7 +9826,6 @@ EXTERN_C const IID IID_ID3D12Tools; #ifdef COBJMACROS - #define ID3D12Tools_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -10192,7 +9835,6 @@ EXTERN_C const IID IID_ID3D12Tools; #define ID3D12Tools_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Tools_EnableShaderInstrumentation(This,bEnable) \ ( (This)->lpVtbl -> EnableShaderInstrumentation(This,bEnable) ) @@ -10201,15 +9843,10 @@ EXTERN_C const IID IID_ID3D12Tools; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Tools_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12_0000_0027 */ /* [local] */ @@ -10262,7 +9899,6 @@ HRESULT WINAPI D3D12CreateDevice( _In_ REFIID riid, // Expected: ID3D12Device _COM_Outptr_opt_ void** ppDevice ); - typedef HRESULT (WINAPI* PFN_D3D12_GET_DEBUG_INTERFACE)( _In_ REFIID, _COM_Outptr_opt_ void** ); HRESULT WINAPI D3D12GetDebugInterface( _In_ REFIID riid, _COM_Outptr_opt_ void** ppvDebug ); @@ -10342,7 +9978,6 @@ DEFINE_GUID(IID_ID3D12Device2,0x30baa41e,0xb15b,0x475c,0xa0,0xbb,0x1a,0xf5,0xc5, DEFINE_GUID(IID_ID3D12Device3,0x81dadc15,0x2bad,0x4392,0x93,0xc5,0x10,0x13,0x45,0xc4,0xaa,0x98); DEFINE_GUID(IID_ID3D12Tools,0x7071e1f0,0xe84b,0x4b33,0x97,0x4f,0x12,0xfa,0x49,0xde,0x65,0xc5); - extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0027_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0027_v0_0_s_ifspec; @@ -10356,4 +9991,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12_0000_0027_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d12sdklayers.h b/gfx/include/dxsdk/d3d12sdklayers.h index 841c3f7b2e..d236379ab3 100644 --- a/gfx/include/dxsdk/d3d12sdklayers.h +++ b/gfx/include/dxsdk/d3d12sdklayers.h @@ -4,14 +4,10 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -49,70 +45,60 @@ typedef interface ID3D12Debug ID3D12Debug; #endif /* __ID3D12Debug_FWD_DEFINED__ */ - #ifndef __ID3D12Debug1_FWD_DEFINED__ #define __ID3D12Debug1_FWD_DEFINED__ typedef interface ID3D12Debug1 ID3D12Debug1; #endif /* __ID3D12Debug1_FWD_DEFINED__ */ - #ifndef __ID3D12Debug2_FWD_DEFINED__ #define __ID3D12Debug2_FWD_DEFINED__ typedef interface ID3D12Debug2 ID3D12Debug2; #endif /* __ID3D12Debug2_FWD_DEFINED__ */ - #ifndef __ID3D12DebugDevice1_FWD_DEFINED__ #define __ID3D12DebugDevice1_FWD_DEFINED__ typedef interface ID3D12DebugDevice1 ID3D12DebugDevice1; #endif /* __ID3D12DebugDevice1_FWD_DEFINED__ */ - #ifndef __ID3D12DebugDevice_FWD_DEFINED__ #define __ID3D12DebugDevice_FWD_DEFINED__ typedef interface ID3D12DebugDevice ID3D12DebugDevice; #endif /* __ID3D12DebugDevice_FWD_DEFINED__ */ - #ifndef __ID3D12DebugCommandQueue_FWD_DEFINED__ #define __ID3D12DebugCommandQueue_FWD_DEFINED__ typedef interface ID3D12DebugCommandQueue ID3D12DebugCommandQueue; #endif /* __ID3D12DebugCommandQueue_FWD_DEFINED__ */ - #ifndef __ID3D12DebugCommandList1_FWD_DEFINED__ #define __ID3D12DebugCommandList1_FWD_DEFINED__ typedef interface ID3D12DebugCommandList1 ID3D12DebugCommandList1; #endif /* __ID3D12DebugCommandList1_FWD_DEFINED__ */ - #ifndef __ID3D12DebugCommandList_FWD_DEFINED__ #define __ID3D12DebugCommandList_FWD_DEFINED__ typedef interface ID3D12DebugCommandList ID3D12DebugCommandList; #endif /* __ID3D12DebugCommandList_FWD_DEFINED__ */ - #ifndef __ID3D12SharingContract_FWD_DEFINED__ #define __ID3D12SharingContract_FWD_DEFINED__ typedef interface ID3D12SharingContract ID3D12SharingContract; #endif /* __ID3D12SharingContract_FWD_DEFINED__ */ - #ifndef __ID3D12InfoQueue_FWD_DEFINED__ #define __ID3D12InfoQueue_FWD_DEFINED__ typedef interface ID3D12InfoQueue ID3D12InfoQueue; #endif /* __ID3D12InfoQueue_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -122,7 +108,6 @@ typedef interface ID3D12InfoQueue ID3D12InfoQueue; extern "C"{ #endif - /* interface __MIDL_itf_d3d12sdklayers_0000_0000 */ /* [local] */ @@ -130,7 +115,6 @@ extern "C"{ /*#pragma region App Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0000_v0_0_s_ifspec; @@ -140,7 +124,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0000_v0_0_s_ifspec; /* interface ID3D12Debug */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Debug; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -186,7 +169,6 @@ EXTERN_C const IID IID_ID3D12Debug; #ifdef COBJMACROS - #define ID3D12Debug_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -196,28 +178,21 @@ EXTERN_C const IID IID_ID3D12Debug; #define ID3D12Debug_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Debug_EnableDebugLayer(This) \ ( (This)->lpVtbl -> EnableDebugLayer(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Debug_INTERFACE_DEFINED__ */ - #ifndef __ID3D12Debug1_INTERFACE_DEFINED__ #define __ID3D12Debug1_INTERFACE_DEFINED__ /* interface ID3D12Debug1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Debug1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -277,7 +252,6 @@ EXTERN_C const IID IID_ID3D12Debug1; #ifdef COBJMACROS - #define ID3D12Debug1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -287,7 +261,6 @@ EXTERN_C const IID IID_ID3D12Debug1; #define ID3D12Debug1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Debug1_EnableDebugLayer(This) \ ( (This)->lpVtbl -> EnableDebugLayer(This) ) @@ -299,15 +272,10 @@ EXTERN_C const IID IID_ID3D12Debug1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Debug1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0002 */ /* [local] */ @@ -320,7 +288,6 @@ enum D3D12_GPU_BASED_VALIDATION_FLAGS DEFINE_ENUM_FLAG_OPERATORS(D3D12_GPU_BASED_VALIDATION_FLAGS) - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0002_v0_0_s_ifspec; @@ -330,7 +297,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0002_v0_0_s_ifspec; /* interface ID3D12Debug2 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12Debug2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -378,7 +344,6 @@ EXTERN_C const IID IID_ID3D12Debug2; #ifdef COBJMACROS - #define ID3D12Debug2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -388,21 +353,15 @@ EXTERN_C const IID IID_ID3D12Debug2; #define ID3D12Debug2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12Debug2_SetGPUBasedValidationFlags(This,Flags) \ ( (This)->lpVtbl -> SetGPUBasedValidationFlags(This,Flags) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12Debug2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0003 */ /* [local] */ @@ -468,8 +427,6 @@ typedef struct D3D12_DEBUG_DEVICE_GPU_SLOWDOWN_PERFORMANCE_FACTOR FLOAT SlowdownFactor; } D3D12_DEBUG_DEVICE_GPU_SLOWDOWN_PERFORMANCE_FACTOR; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0003_v0_0_s_ifspec; @@ -479,7 +436,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0003_v0_0_s_ifspec; /* interface ID3D12DebugDevice1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DebugDevice1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -549,7 +505,6 @@ EXTERN_C const IID IID_ID3D12DebugDevice1; #ifdef COBJMACROS - #define ID3D12DebugDevice1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -559,7 +514,6 @@ EXTERN_C const IID IID_ID3D12DebugDevice1; #define ID3D12DebugDevice1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DebugDevice1_SetDebugParameter(This,Type,pData,DataSize) \ ( (This)->lpVtbl -> SetDebugParameter(This,Type,pData,DataSize) ) @@ -571,22 +525,16 @@ EXTERN_C const IID IID_ID3D12DebugDevice1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DebugDevice1_INTERFACE_DEFINED__ */ - #ifndef __ID3D12DebugDevice_INTERFACE_DEFINED__ #define __ID3D12DebugDevice_INTERFACE_DEFINED__ /* interface ID3D12DebugDevice */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DebugDevice; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -646,7 +594,6 @@ EXTERN_C const IID IID_ID3D12DebugDevice; #ifdef COBJMACROS - #define ID3D12DebugDevice_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -656,7 +603,6 @@ EXTERN_C const IID IID_ID3D12DebugDevice; #define ID3D12DebugDevice_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DebugDevice_SetFeatureMask(This,Mask) \ ( (This)->lpVtbl -> SetFeatureMask(This,Mask) ) @@ -668,21 +614,15 @@ EXTERN_C const IID IID_ID3D12DebugDevice; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DebugDevice_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0005 */ /* [local] */ DEFINE_GUID(DXGI_DEBUG_D3D12, 0xcf59a98c, 0xa950, 0x4326, 0x91, 0xef, 0x9b, 0xba, 0xa1, 0x7b, 0xfd, 0x95); - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0005_v0_0_s_ifspec; @@ -692,7 +632,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0005_v0_0_s_ifspec; /* interface ID3D12DebugCommandQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DebugCommandQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -744,7 +683,6 @@ EXTERN_C const IID IID_ID3D12DebugCommandQueue; #ifdef COBJMACROS - #define ID3D12DebugCommandQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -754,21 +692,15 @@ EXTERN_C const IID IID_ID3D12DebugCommandQueue; #define ID3D12DebugCommandQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DebugCommandQueue_AssertResourceState(This,pResource,Subresource,State) \ ( (This)->lpVtbl -> AssertResourceState(This,pResource,Subresource,State) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DebugCommandQueue_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0006 */ /* [local] */ @@ -783,8 +715,6 @@ typedef struct D3D12_DEBUG_COMMAND_LIST_GPU_BASED_VALIDATION_SETTINGS D3D12_GPU_BASED_VALIDATION_SHADER_PATCH_MODE ShaderPatchMode; } D3D12_DEBUG_COMMAND_LIST_GPU_BASED_VALIDATION_SETTINGS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0006_v0_0_s_ifspec; @@ -794,7 +724,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0006_v0_0_s_ifspec; /* interface ID3D12DebugCommandList1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DebugCommandList1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -868,7 +797,6 @@ EXTERN_C const IID IID_ID3D12DebugCommandList1; #ifdef COBJMACROS - #define ID3D12DebugCommandList1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -878,7 +806,6 @@ EXTERN_C const IID IID_ID3D12DebugCommandList1; #define ID3D12DebugCommandList1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DebugCommandList1_AssertResourceState(This,pResource,Subresource,State) \ ( (This)->lpVtbl -> AssertResourceState(This,pResource,Subresource,State) ) @@ -890,22 +817,16 @@ EXTERN_C const IID IID_ID3D12DebugCommandList1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DebugCommandList1_INTERFACE_DEFINED__ */ - #ifndef __ID3D12DebugCommandList_INTERFACE_DEFINED__ #define __ID3D12DebugCommandList_INTERFACE_DEFINED__ /* interface ID3D12DebugCommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12DebugCommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -969,7 +890,6 @@ EXTERN_C const IID IID_ID3D12DebugCommandList; #ifdef COBJMACROS - #define ID3D12DebugCommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -979,7 +899,6 @@ EXTERN_C const IID IID_ID3D12DebugCommandList; #define ID3D12DebugCommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12DebugCommandList_AssertResourceState(This,pResource,Subresource,State) \ ( (This)->lpVtbl -> AssertResourceState(This,pResource,Subresource,State) ) @@ -991,22 +910,16 @@ EXTERN_C const IID IID_ID3D12DebugCommandList; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12DebugCommandList_INTERFACE_DEFINED__ */ - #ifndef __ID3D12SharingContract_INTERFACE_DEFINED__ #define __ID3D12SharingContract_INTERFACE_DEFINED__ /* interface ID3D12SharingContract */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12SharingContract; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1065,7 +978,6 @@ EXTERN_C const IID IID_ID3D12SharingContract; #ifdef COBJMACROS - #define ID3D12SharingContract_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1075,7 +987,6 @@ EXTERN_C const IID IID_ID3D12SharingContract; #define ID3D12SharingContract_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12SharingContract_Present(This,pResource,Subresource) \ ( (This)->lpVtbl -> Present(This,pResource,Subresource) ) @@ -1084,15 +995,10 @@ EXTERN_C const IID IID_ID3D12SharingContract; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12SharingContract_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0009 */ /* [local] */ @@ -2266,7 +2172,6 @@ typedef struct D3D12_INFO_QUEUE_FILTER #define D3D12_INFO_QUEUE_DEFAULT_MESSAGE_COUNT_LIMIT 1024 - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0009_v0_0_s_ifspec; @@ -2276,7 +2181,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0009_v0_0_s_ifspec; /* interface ID3D12InfoQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12InfoQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2548,7 +2452,6 @@ EXTERN_C const IID IID_ID3D12InfoQueue; #ifdef COBJMACROS - #define ID3D12InfoQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2558,7 +2461,6 @@ EXTERN_C const IID IID_ID3D12InfoQueue; #define ID3D12InfoQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12InfoQueue_SetMessageCountLimit(This,MessageCountLimit) \ ( (This)->lpVtbl -> SetMessageCountLimit(This,MessageCountLimit) ) @@ -2666,15 +2568,10 @@ EXTERN_C const IID IID_ID3D12InfoQueue; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12InfoQueue_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12sdklayers_0000_0010 */ /* [local] */ @@ -2691,7 +2588,6 @@ DEFINE_GUID(IID_ID3D12DebugCommandList,0x09e0bf36,0x54ac,0x484f,0x88,0x47,0x4b,0 DEFINE_GUID(IID_ID3D12SharingContract,0xa251ff70,0xcdeb,0x49fa,0x9b,0xcf,0x5e,0xbd,0xf4,0xdb,0xac,0xa9); DEFINE_GUID(IID_ID3D12InfoQueue,0x0742a90b,0xc387,0x483f,0xb9,0x46,0x30,0xa7,0xe4,0xe6,0x14,0x58); - extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0010_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0010_v0_0_s_ifspec; @@ -2705,4 +2601,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12sdklayers_0000_0010_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3d12shader.h b/gfx/include/dxsdk/d3d12shader.h index fbeb7633d2..14ada61f24 100644 --- a/gfx/include/dxsdk/d3d12shader.h +++ b/gfx/include/dxsdk/d3d12shader.h @@ -40,7 +40,6 @@ typedef D3D_RESOURCE_RETURN_TYPE D3D12_RESOURCE_RETURN_TYPE; typedef D3D_CBUFFER_TYPE D3D12_CBUFFER_TYPE; - typedef struct _D3D12_SIGNATURE_PARAMETER_DESC { LPCSTR SemanticName; // Name of the semantic @@ -173,7 +172,6 @@ typedef struct _D3D12_SHADER_INPUT_BIND_DESC #define D3D_SHADER_REQUIRES_ROVS 0x00001000 #define D3D_SHADER_REQUIRES_VIEWPORT_AND_RT_ARRAY_INDEX_FROM_ANY_SHADER_FEEDING_RASTERIZER 0x00002000 - typedef struct _D3D12_LIBRARY_DESC { LPCSTR Creator; // The name of the originator of the library. @@ -238,7 +236,6 @@ typedef struct _D3D12_PARAMETER_DESC UINT FirstOutComponent; // The first output register component for this parameter. } D3D12_PARAMETER_DESC; - ////////////////////////////////////////////////////////////////////////////// // Interfaces //////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -264,7 +261,6 @@ typedef interface ID3D12FunctionReflection *LPD3D12FUNCTIONREFLECTION; typedef interface ID3D12FunctionParameterReflection ID3D12FunctionParameterReflection; typedef interface ID3D12FunctionParameterReflection *LPD3D12FUNCTIONPARAMETERREFLECTION; - // {E913C351-783D-48CA-A1D1-4F306284AD56} interface DECLSPEC_UUID("E913C351-783D-48CA-A1D1-4F306284AD56") ID3D12ShaderReflectionType; DEFINE_GUID(IID_ID3D12ShaderReflectionType, @@ -442,7 +438,6 @@ DECLARE_INTERFACE(ID3D12FunctionParameterReflection) STDMETHOD(GetDesc)(THIS_ _Out_ D3D12_PARAMETER_DESC * pDesc) PURE; }; - ////////////////////////////////////////////////////////////////////////////// // APIs ////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// diff --git a/gfx/include/dxsdk/d3d12video.h b/gfx/include/dxsdk/d3d12video.h index daa4bdd1f7..fd8bc27ac5 100644 --- a/gfx/include/dxsdk/d3d12video.h +++ b/gfx/include/dxsdk/d3d12video.h @@ -4,14 +4,10 @@ * *-------------------------------------------------------------------------------------*/ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -49,42 +45,36 @@ typedef interface ID3D12VideoDecoderHeap ID3D12VideoDecoderHeap; #endif /* __ID3D12VideoDecoderHeap_FWD_DEFINED__ */ - #ifndef __ID3D12VideoDevice_FWD_DEFINED__ #define __ID3D12VideoDevice_FWD_DEFINED__ typedef interface ID3D12VideoDevice ID3D12VideoDevice; #endif /* __ID3D12VideoDevice_FWD_DEFINED__ */ - #ifndef __ID3D12VideoDecoder_FWD_DEFINED__ #define __ID3D12VideoDecoder_FWD_DEFINED__ typedef interface ID3D12VideoDecoder ID3D12VideoDecoder; #endif /* __ID3D12VideoDecoder_FWD_DEFINED__ */ - #ifndef __ID3D12VideoProcessor_FWD_DEFINED__ #define __ID3D12VideoProcessor_FWD_DEFINED__ typedef interface ID3D12VideoProcessor ID3D12VideoProcessor; #endif /* __ID3D12VideoProcessor_FWD_DEFINED__ */ - #ifndef __ID3D12VideoDecodeCommandList_FWD_DEFINED__ #define __ID3D12VideoDecodeCommandList_FWD_DEFINED__ typedef interface ID3D12VideoDecodeCommandList ID3D12VideoDecodeCommandList; #endif /* __ID3D12VideoDecodeCommandList_FWD_DEFINED__ */ - #ifndef __ID3D12VideoProcessCommandList_FWD_DEFINED__ #define __ID3D12VideoProcessCommandList_FWD_DEFINED__ typedef interface ID3D12VideoProcessCommandList ID3D12VideoProcessCommandList; #endif /* __ID3D12VideoProcessCommandList_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -95,7 +85,6 @@ typedef interface ID3D12VideoProcessCommandList ID3D12VideoProcessCommandList; extern "C"{ #endif - /* interface __MIDL_itf_d3d12video_0000_0000 */ /* [local] */ @@ -287,8 +276,6 @@ typedef struct D3D12_VIDEO_PROCESS_OUTPUT_STREAM_DESC BOOL EnableStereo; } D3D12_VIDEO_PROCESS_OUTPUT_STREAM_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0000_v0_0_s_ifspec; @@ -298,7 +285,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0000_v0_0_s_ifspec; /* interface ID3D12VideoDecoderHeap */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoDecoderHeap; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -370,7 +356,6 @@ EXTERN_C const IID IID_ID3D12VideoDecoderHeap; #ifdef COBJMACROS - #define ID3D12VideoDecoderHeap_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -380,7 +365,6 @@ EXTERN_C const IID IID_ID3D12VideoDecoderHeap; #define ID3D12VideoDecoderHeap_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoDecoderHeap_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -393,37 +377,24 @@ EXTERN_C const IID IID_ID3D12VideoDecoderHeap; #define ID3D12VideoDecoderHeap_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12VideoDecoderHeap_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12VideoDecoderHeap_GetDesc(This) \ ( (This)->lpVtbl -> GetDesc(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12VideoDecoderHeap_INTERFACE_DEFINED__ */ - #ifndef __ID3D12VideoDevice_INTERFACE_DEFINED__ #define __ID3D12VideoDevice_INTERFACE_DEFINED__ /* interface ID3D12VideoDevice */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoDevice; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -514,7 +485,6 @@ EXTERN_C const IID IID_ID3D12VideoDevice; #ifdef COBJMACROS - #define ID3D12VideoDevice_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -524,7 +494,6 @@ EXTERN_C const IID IID_ID3D12VideoDevice; #define ID3D12VideoDevice_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoDevice_CheckFeatureSupport(This,FeatureVideo,pFeatureSupportData,FeatureSupportDataSize) \ ( (This)->lpVtbl -> CheckFeatureSupport(This,FeatureVideo,pFeatureSupportData,FeatureSupportDataSize) ) @@ -539,22 +508,16 @@ EXTERN_C const IID IID_ID3D12VideoDevice; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12VideoDevice_INTERFACE_DEFINED__ */ - #ifndef __ID3D12VideoDecoder_INTERFACE_DEFINED__ #define __ID3D12VideoDecoder_INTERFACE_DEFINED__ /* interface ID3D12VideoDecoder */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoDecoder; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -626,7 +589,6 @@ EXTERN_C const IID IID_ID3D12VideoDecoder; #ifdef COBJMACROS - #define ID3D12VideoDecoder_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -636,7 +598,6 @@ EXTERN_C const IID IID_ID3D12VideoDecoder; #define ID3D12VideoDecoder_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoDecoder_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -649,30 +610,18 @@ EXTERN_C const IID IID_ID3D12VideoDecoder; #define ID3D12VideoDecoder_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12VideoDecoder_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12VideoDecoder_GetDesc(This) \ ( (This)->lpVtbl -> GetDesc(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12VideoDecoder_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12video_0000_0003 */ /* [local] */ @@ -882,8 +831,6 @@ typedef struct D3D12_VIDEO_DECODE_OUTPUT_STREAM_ARGUMENTS D3D12_VIDEO_DECODE_CONVERSION_ARGUMENTS ConversionArguments; } D3D12_VIDEO_DECODE_OUTPUT_STREAM_ARGUMENTS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0003_v0_0_s_ifspec; @@ -893,7 +840,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0003_v0_0_s_ifspec; /* interface ID3D12VideoProcessor */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoProcessor; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -984,7 +930,6 @@ EXTERN_C const IID IID_ID3D12VideoProcessor; #ifdef COBJMACROS - #define ID3D12VideoProcessor_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -994,7 +939,6 @@ EXTERN_C const IID IID_ID3D12VideoProcessor; #define ID3D12VideoProcessor_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoProcessor_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1007,12 +951,9 @@ EXTERN_C const IID IID_ID3D12VideoProcessor; #define ID3D12VideoProcessor_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12VideoProcessor_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - - #define ID3D12VideoProcessor_GetNodeMask(This) \ ( (This)->lpVtbl -> GetNodeMask(This) ) @@ -1027,19 +968,10 @@ EXTERN_C const IID IID_ID3D12VideoProcessor; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - - - - - #endif /* __ID3D12VideoProcessor_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12video_0000_0004 */ /* [local] */ @@ -1201,8 +1133,6 @@ typedef struct D3D12_VIDEO_PROCESS_OUTPUT_STREAM_ARGUMENTS D3D12_RECT TargetRectangle; } D3D12_VIDEO_PROCESS_OUTPUT_STREAM_ARGUMENTS; - - extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0004_v0_0_s_ifspec; @@ -1212,7 +1142,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0004_v0_0_s_ifspec; /* interface ID3D12VideoDecodeCommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoDecodeCommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1416,7 +1345,6 @@ EXTERN_C const IID IID_ID3D12VideoDecodeCommandList; #ifdef COBJMACROS - #define ID3D12VideoDecodeCommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1426,7 +1354,6 @@ EXTERN_C const IID IID_ID3D12VideoDecodeCommandList; #define ID3D12VideoDecodeCommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoDecodeCommandList_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1439,15 +1366,12 @@ EXTERN_C const IID IID_ID3D12VideoDecodeCommandList; #define ID3D12VideoDecodeCommandList_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12VideoDecodeCommandList_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12VideoDecodeCommandList_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) - #define ID3D12VideoDecodeCommandList_Close(This) \ ( (This)->lpVtbl -> Close(This) ) @@ -1492,22 +1416,16 @@ EXTERN_C const IID IID_ID3D12VideoDecodeCommandList; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12VideoDecodeCommandList_INTERFACE_DEFINED__ */ - #ifndef __ID3D12VideoProcessCommandList_INTERFACE_DEFINED__ #define __ID3D12VideoProcessCommandList_INTERFACE_DEFINED__ /* interface ID3D12VideoProcessCommandList */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D12VideoProcessCommandList; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1713,7 +1631,6 @@ EXTERN_C const IID IID_ID3D12VideoProcessCommandList; #ifdef COBJMACROS - #define ID3D12VideoProcessCommandList_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1723,7 +1640,6 @@ EXTERN_C const IID IID_ID3D12VideoProcessCommandList; #define ID3D12VideoProcessCommandList_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D12VideoProcessCommandList_GetPrivateData(This,guid,pDataSize,pData) \ ( (This)->lpVtbl -> GetPrivateData(This,guid,pDataSize,pData) ) @@ -1736,15 +1652,12 @@ EXTERN_C const IID IID_ID3D12VideoProcessCommandList; #define ID3D12VideoProcessCommandList_SetName(This,Name) \ ( (This)->lpVtbl -> SetName(This,Name) ) - #define ID3D12VideoProcessCommandList_GetDevice(This,riid,ppvDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppvDevice) ) - #define ID3D12VideoProcessCommandList_GetType(This) \ ( (This)->lpVtbl -> GetType(This) ) - #define ID3D12VideoProcessCommandList_Close(This) \ ( (This)->lpVtbl -> Close(This) ) @@ -1789,15 +1702,10 @@ EXTERN_C const IID IID_ID3D12VideoProcessCommandList; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D12VideoProcessCommandList_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3d12video_0000_0006 */ /* [local] */ @@ -1825,7 +1733,6 @@ DEFINE_GUID(IID_ID3D12VideoProcessor,0x304FDB32,0xBEDE,0x410A,0x85,0x45,0x94,0x3 DEFINE_GUID(IID_ID3D12VideoDecodeCommandList,0x3B60536E,0xAD29,0x4E64,0xA2,0x69,0xF8,0x53,0x83,0x7E,0x5E,0x53); DEFINE_GUID(IID_ID3D12VideoProcessCommandList,0xAEB2543A,0x167F,0x4682,0xAC,0xC8,0xD1,0x59,0xED,0x4A,0x62,0x09); - extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0006_v0_0_s_ifspec; @@ -1839,4 +1746,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3d12video_0000_0006_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3dcommon.h b/gfx/include/dxsdk/d3dcommon.h index 02630c9b02..1506130aa1 100644 --- a/gfx/include/dxsdk/d3dcommon.h +++ b/gfx/include/dxsdk/d3dcommon.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,14 +41,12 @@ typedef interface ID3D10Blob ID3D10Blob; #endif /* __ID3D10Blob_FWD_DEFINED__ */ - #ifndef __ID3DDestructionNotifier_FWD_DEFINED__ #define __ID3DDestructionNotifier_FWD_DEFINED__ typedef interface ID3DDestructionNotifier ID3DDestructionNotifier; #endif /* __ID3DDestructionNotifier_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -61,7 +55,6 @@ typedef interface ID3DDestructionNotifier ID3DDestructionNotifier; extern "C"{ #endif - /* interface __MIDL_itf_d3dcommon_0000_0000 */ /* [local] */ @@ -351,7 +344,6 @@ typedef struct _D3D_SHADER_MACRO *LPD3D_SHADER_MACRO; DEFINE_GUID(IID_ID3D10Blob, 0x8ba5fb08, 0x5195, 0x40e2, 0xac, 0x58, 0xd, 0x98, 0x9c, 0x3a, 0x1, 0x2); - extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0000_v0_0_s_ifspec; @@ -361,7 +353,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0000_v0_0_s_ifspec; /* interface ID3D10Blob */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3D10Blob; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -413,7 +404,6 @@ EXTERN_C const IID IID_ID3D10Blob; #ifdef COBJMACROS - #define ID3D10Blob_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -423,7 +413,6 @@ EXTERN_C const IID IID_ID3D10Blob; #define ID3D10Blob_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3D10Blob_GetBufferPointer(This) \ ( (This)->lpVtbl -> GetBufferPointer(This) ) @@ -432,15 +421,10 @@ EXTERN_C const IID IID_ID3D10Blob; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3D10Blob_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3dcommon_0000_0001 */ /* [local] */ @@ -452,8 +436,6 @@ typedef ID3DBlob* LPD3DBLOB; typedef void ( __stdcall *PFN_DESTRUCTION_CALLBACK )( void *pData); - - extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0001_v0_0_s_ifspec; @@ -463,7 +445,6 @@ extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0001_v0_0_s_ifspec; /* interface ID3DDestructionNotifier */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_ID3DDestructionNotifier; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -531,7 +512,6 @@ EXTERN_C const IID IID_ID3DDestructionNotifier; #ifdef COBJMACROS - #define ID3DDestructionNotifier_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -541,7 +521,6 @@ EXTERN_C const IID IID_ID3DDestructionNotifier; #define ID3DDestructionNotifier_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define ID3DDestructionNotifier_RegisterDestructionCallback(This,callbackFn,pData,pCallbackID) \ ( (This)->lpVtbl -> RegisterDestructionCallback(This,callbackFn,pData,pCallbackID) ) @@ -550,15 +529,10 @@ EXTERN_C const IID IID_ID3DDestructionNotifier; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __ID3DDestructionNotifier_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_d3dcommon_0000_0002 */ /* [local] */ @@ -987,7 +961,6 @@ DEFINE_GUID(WKPDID_CommentStringW,0xd0149dc0,0x90e8,0x4ec8,0x81, 0x44, 0xe9, 0x0 #define D3D_COMPONENT_MASK_Z 4 #define D3D_COMPONENT_MASK_W 8 - extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0002_v0_0_s_ifspec; @@ -1001,4 +974,3 @@ extern RPC_IF_HANDLE __MIDL_itf_d3dcommon_0000_0002_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/d3dcompiler.h b/gfx/include/dxsdk/d3dcompiler.h index 632c3da9cf..3cb367ab19 100644 --- a/gfx/include/dxsdk/d3dcompiler.h +++ b/gfx/include/dxsdk/d3dcompiler.h @@ -14,8 +14,6 @@ // Current name of the DLL shipped in the same SDK as this header. - - #define D3DCOMPILER_DLL_W L"d3dcompiler_47.dll" #define D3DCOMPILER_DLL_A "d3dcompiler_47.dll" @@ -40,7 +38,6 @@ extern "C" { #endif //__cplusplus - /*#pragma region Application Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ @@ -559,7 +556,6 @@ D3DDecompressShaders(_In_reads_bytes_(SrcDataSize) LPCVOID pSrcData, /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP) */ /*#pragma endregion*/ - /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ @@ -578,7 +574,6 @@ D3DDisassemble10Effect(_In_ interface ID3D10Effect *pEffect, /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ /*#pragma endregion*/ - #ifdef __cplusplus } #endif //__cplusplus diff --git a/gfx/include/dxsdk/d3dcsx.h b/gfx/include/dxsdk/d3dcsx.h index bab5bbca30..4d2adf0877 100644 --- a/gfx/include/dxsdk/d3dcsx.h +++ b/gfx/include/dxsdk/d3dcsx.h @@ -20,7 +20,6 @@ // Current name of the DLL shipped in the same SDK as this header. - #define D3DCSX_DLL_W L"d3dcsx_47.dll" #define D3DCSX_DLL_A "d3dcsx_47.dll" @@ -30,16 +29,10 @@ #define D3DCSX_DLL D3DCSX_DLL_A #endif - #ifdef __cplusplus extern "C" { #endif //__cplusplus - - - - - ////////////////////////////////////////////////////////////////////////////// typedef enum D3DX11_SCAN_DATA_TYPE @@ -66,7 +59,6 @@ typedef enum D3DX11_SCAN_DIRECTION D3DX11_SCAN_DIRECTION_BACKWARD, } D3DX11_SCAN_DIRECTION; - ////////////////////////////////////////////////////////////////////////////// // ID3DX11Scan: ////////////////////////////////////////////////////////////////////////////// @@ -127,7 +119,6 @@ DECLARE_INTERFACE_(ID3DX11Scan, IUnknown) ) PURE; }; - //============================================================================= // Creates a scan context // pDevice the device context @@ -141,8 +132,6 @@ HRESULT WINAPI D3DX11CreateScan( UINT MaxScanCount, _Out_ ID3DX11Scan** ppScan ); - - ////////////////////////////////////////////////////////////////////////////// // ID3DX11SegmentedScan: ////////////////////////////////////////////////////////////////////////////// @@ -185,7 +174,6 @@ DECLARE_INTERFACE_(ID3DX11SegmentedScan, IUnknown) ) PURE; }; - //============================================================================= // Creates a segmented scan context // pDevice the device context @@ -197,16 +185,12 @@ HRESULT WINAPI D3DX11CreateSegmentedScan( UINT MaxElementScanSize, _Out_ ID3DX11SegmentedScan** ppScan ); - - ////////////////////////////////////////////////////////////////////////////// #define D3DX11_FFT_MAX_PRECOMPUTE_BUFFERS 4 #define D3DX11_FFT_MAX_TEMP_BUFFERS 4 #define D3DX11_FFT_MAX_DIMENSIONS 32 - - ////////////////////////////////////////////////////////////////////////////// // ID3DX11FFT: ////////////////////////////////////////////////////////////////////////////// @@ -272,7 +256,6 @@ DECLARE_INTERFACE_(ID3DX11FFT, IUnknown) _Inout_ ID3D11UnorderedAccessView** ppOutputBuffer ) PURE; }; - ////////////////////////////////////////////////////////////////////////////// // ID3DX11FFT Creation Routines ////////////////////////////////////////////////////////////////////////////// @@ -299,7 +282,6 @@ typedef struct D3DX11_FFT_DESC D3DX11_FFT_DATA_TYPE Type; // type of the elements in spatial domain } D3DX11_FFT_DESC; - //------------------------------------------------------------------------------ // NumTempBufferSizes Number of temporary buffers needed // pTempBufferSizes Minimum sizes (in FLOATs) of temporary buffers @@ -315,13 +297,11 @@ typedef struct D3DX11_FFT_BUFFER_INFO UINT PrecomputeBufferFloatSizes[D3DX11_FFT_MAX_PRECOMPUTE_BUFFERS]; } D3DX11_FFT_BUFFER_INFO; - typedef enum D3DX11_FFT_CREATE_FLAG { D3DX11_FFT_CREATE_FLAG_NO_PRECOMPUTE_BUFFERS = 0x01L, // do not precompute values and store into buffers } D3DX11_FFT_CREATE_FLAG; - //------------------------------------------------------------------------------ // Creates an ID3DX11FFT COM interface object and returns a pointer to it at *ppFFT. // The descriptor describes the shape of the data as well as the scaling factors @@ -404,7 +384,6 @@ HRESULT WINAPI D3DX11CreateFFT3DComplex( _Out_ ID3DX11FFT** ppFFT ); - #ifdef __cplusplus } #endif //__cplusplus diff --git a/gfx/include/dxsdk/d3dx10.h b/gfx/include/dxsdk/d3dx10.h index 5cdcd51d96..ad49589a59 100644 --- a/gfx/include/dxsdk/d3dx10.h +++ b/gfx/include/dxsdk/d3dx10.h @@ -14,7 +14,6 @@ #ifndef __D3DX10_H__ #define __D3DX10_H__ - // Defines #include #include @@ -39,8 +38,6 @@ #endif #endif - - // Includes #include "d3d10.h" #include "d3dx10.h" @@ -50,7 +47,6 @@ #include "d3dx10mesh.h" #include "d3dx10async.h" - // Errors #define _FACDD 0x876 #define MAKE_DDHRESULT( code ) MAKE_HRESULT( 1, _FACDD, code ) @@ -67,6 +63,5 @@ enum _D3DX10_ERR { D3DX10_ERR_CANNOT_REMOVE_LAST_ITEM = MAKE_DDHRESULT(2908), }; - #endif //__D3DX10_H__ diff --git a/gfx/include/dxsdk/d3dx10async.h b/gfx/include/dxsdk/d3dx10async.h index d1b1fc53b5..f0ae685c76 100644 --- a/gfx/include/dxsdk/d3dx10async.h +++ b/gfx/include/dxsdk/d3dx10async.h @@ -17,7 +17,6 @@ extern "C" { #endif //__cplusplus - //---------------------------------------------------------------------------- // D3DX10Compile: // ------------------ @@ -157,7 +156,6 @@ HRESULT WINAPI D3DX10CompileFromMemory(LPCSTR pSrcData, SIZE_T SrcDataLen, LPCST // the asynchronous execution completes. //---------------------------------------------------------------------------- - HRESULT WINAPI D3DX10CreateEffectFromFileA(LPCSTR pFileName, CONST D3D10_SHADER_MACRO *pDefines, ID3D10Include *pInclude, LPCSTR pProfile, UINT HLSLFlags, UINT FXFlags, ID3D10Device *pDevice, ID3D10EffectPool *pEffectPool, ID3DX10ThreadPump* pPump, ID3D10Effect **ppEffect, ID3D10Blob **ppErrors, HRESULT* pHResult); @@ -178,7 +176,6 @@ HRESULT WINAPI D3DX10CreateEffectFromResourceW(HMODULE hModule, LPCWSTR pResourc ID3D10Include *pInclude, LPCSTR pProfile, UINT HLSLFlags, UINT FXFlags, ID3D10Device *pDevice, ID3D10EffectPool *pEffectPool, ID3DX10ThreadPump* pPump, ID3D10Effect **ppEffect, ID3D10Blob **ppErrors, HRESULT* pHResult); - #ifdef UNICODE #define D3DX10CreateEffectFromFile D3DX10CreateEffectFromFileW #define D3DX10CreateEffectFromResource D3DX10CreateEffectFromResourceW @@ -257,8 +254,6 @@ HRESULT WINAPI D3DX10CreateAsyncEffectPoolCreateProcessor(LPCSTR pFileName, CONS HRESULT WINAPI D3DX10CreateAsyncShaderPreprocessProcessor(LPCSTR pFileName, CONST D3D10_SHADER_MACRO* pDefines, LPD3D10INCLUDE pInclude, ID3D10Blob** ppShaderText, ID3D10Blob **ppErrorBuffer, ID3DX10DataProcessor **ppProcessor); - - //---------------------------------------------------------------------------- // D3DX10 Asynchronous texture I/O (advanced mode) //---------------------------------------------------------------------------- @@ -287,4 +282,3 @@ HRESULT WINAPI D3DX10CreateAsyncShaderResourceViewProcessor(ID3D10Device *pDevic #endif //__D3DX10ASYNC_H__ - diff --git a/gfx/include/dxsdk/d3dx10core.h b/gfx/include/dxsdk/d3dx10core.h index 290a00421e..641f7e854d 100644 --- a/gfx/include/dxsdk/d3dx10core.h +++ b/gfx/include/dxsdk/d3dx10core.h @@ -14,7 +14,6 @@ // Current name of the DLL shipped in the same SDK as this header. - #define D3DX10_DLL_W L"d3dx10_43.dll" #define D3DX10_DLL_A "d3dx10_43.dll" @@ -38,10 +37,8 @@ extern "C" { // D3DX10CreateVersion will return FALSE. (The number itself has no meaning.) /////////////////////////////////////////////////////////////////////////// - #define D3DX10_SDK_VERSION 43 - /////////////////////////////////////////////////////////////////////////// // D3DX10CreateDevice // D3DX10CreateDeviceAndSwapChain @@ -64,7 +61,6 @@ HRESULT WINAPI D3DX10CreateDeviceAndSwapChain(IDXGIAdapter *pAdapter, typedef interface ID3D10Device1 ID3D10Device1; HRESULT WINAPI D3DX10GetFeatureLevel1(ID3D10Device *pDevice, ID3D10Device1 **ppDevice1); - #ifdef D3D_DIAG_DLL BOOL WINAPI D3DX10DebugMute(BOOL Mute); #endif @@ -74,7 +70,6 @@ HRESULT WINAPI D3DX10CheckVersion(UINT D3DSdkVersion, UINT D3DX10SdkVersion); } #endif //__cplusplus - ////////////////////////////////////////////////////////////////////////////// // D3DX10_SPRITE flags: // ----------------- @@ -116,7 +111,6 @@ typedef struct _D3DX10_SPRITE UINT TextureIndex; } D3DX10_SPRITE; - ////////////////////////////////////////////////////////////////////////////// // ID3DX10Sprite: // ------------ @@ -139,12 +133,10 @@ typedef struct _D3DX10_SPRITE typedef interface ID3DX10Sprite ID3DX10Sprite; typedef interface ID3DX10Sprite *LPD3DX10SPRITE; - // {BA0B762D-8D28-43ec-B9DC-2F84443B0614} DEFINE_GUID(IID_ID3DX10Sprite, 0xba0b762d, 0x8d28, 0x43ec, 0xb9, 0xdc, 0x2f, 0x84, 0x44, 0x3b, 0x6, 0x14); - #undef INTERFACE #define INTERFACE ID3DX10Sprite @@ -172,7 +164,6 @@ DECLARE_INTERFACE_(ID3DX10Sprite, IUnknown) STDMETHOD(GetDevice)(THIS_ ID3D10Device** ppDevice) PURE; }; - #ifdef __cplusplus extern "C" { #endif //__cplusplus @@ -187,7 +178,6 @@ HRESULT WINAPI } #endif //__cplusplus - ////////////////////////////////////////////////////////////////////////////// // ID3DX10ThreadPump: ////////////////////////////////////////////////////////////////////////////// @@ -240,7 +230,6 @@ DECLARE_INTERFACE_(ID3DX10ThreadPump, IUnknown) HRESULT WINAPI D3DX10CreateThreadPump(UINT cIoThreads, UINT cProcThreads, ID3DX10ThreadPump **ppThreadPump); - ////////////////////////////////////////////////////////////////////////////// // ID3DX10Font: // ---------- @@ -299,16 +288,13 @@ typedef D3DX10_FONT_DESCA D3DX10_FONT_DESC; typedef LPD3DX10_FONT_DESCA LPD3DX10_FONT_DESC; #endif - typedef interface ID3DX10Font ID3DX10Font; typedef interface ID3DX10Font *LPD3DX10FONT; - // {D79DBB70-5F21-4d36-BBC2-FF525C213CDC} DEFINE_GUID(IID_ID3DX10Font, 0xd79dbb70, 0x5f21, 0x4d36, 0xbb, 0xc2, 0xff, 0x52, 0x5c, 0x21, 0x3c, 0xdc); - #undef INTERFACE #define INTERFACE ID3DX10Font @@ -364,12 +350,10 @@ DECLARE_INTERFACE_(ID3DX10Font, IUnknown) #endif #endif - #ifdef __cplusplus extern "C" { #endif //__cplusplus - HRESULT WINAPI D3DX10CreateFontA( ID3D10Device* pDevice, @@ -406,7 +390,6 @@ HRESULT WINAPI #define D3DX10CreateFont D3DX10CreateFontA #endif - HRESULT WINAPI D3DX10CreateFontIndirectA( ID3D10Device* pDevice, diff --git a/gfx/include/dxsdk/d3dx10math.h b/gfx/include/dxsdk/d3dx10math.h index 84e0141006..c5425884f2 100644 --- a/gfx/include/dxsdk/d3dx10math.h +++ b/gfx/include/dxsdk/d3dx10math.h @@ -62,8 +62,6 @@ typedef struct _D3DMATRIX { #define D3DXToRadian( degree ) ((degree) * (D3DX_PI / 180.0)) #define D3DXToDegree( radian ) ((radian) * (180.0 / D3DX_PI)) - - //=========================================================================== // // 16 bit floating point numbers @@ -105,15 +103,12 @@ protected: WORD value; } D3DXFLOAT16, *LPD3DXFLOAT16; - - //=========================================================================== // // Vectors // //=========================================================================== - //-------------------------- // 2D Vector //-------------------------- @@ -151,14 +146,11 @@ public: BOOL operator == ( CONST D3DXVECTOR2& ) const; BOOL operator != ( CONST D3DXVECTOR2& ) const; - public: #endif //__cplusplus FLOAT x, y; } D3DXVECTOR2, *LPD3DXVECTOR2; - - //-------------------------- // 2D Vector (16 bit) //-------------------------- @@ -186,8 +178,6 @@ public: } D3DXVECTOR2_16F, *LPD3DXVECTOR2_16F; - - //-------------------------- // 3D Vector //-------------------------- @@ -232,8 +222,6 @@ public: typedef struct _D3DVECTOR D3DXVECTOR3, *LPD3DXVECTOR3; #endif //!__cplusplus - - //-------------------------- // 3D Vector (16 bit) //-------------------------- @@ -261,8 +249,6 @@ public: } D3DXVECTOR3_16F, *LPD3DXVECTOR3_16F; - - //-------------------------- // 4D Vector //-------------------------- @@ -306,7 +292,6 @@ public: FLOAT x, y, z, w; } D3DXVECTOR4, *LPD3DXVECTOR4; - //-------------------------- // 4D Vector (16 bit) //-------------------------- @@ -334,8 +319,6 @@ public: } D3DXVECTOR4_16F, *LPD3DXVECTOR4_16F; - - //=========================================================================== // // Matrices @@ -354,7 +337,6 @@ public: FLOAT _31, FLOAT _32, FLOAT _33, FLOAT _34, FLOAT _41, FLOAT _42, FLOAT _43, FLOAT _44 ); - // access grants FLOAT& operator () ( UINT Row, UINT Col ); FLOAT operator () ( UINT Row, UINT Col ) const; @@ -392,7 +374,6 @@ public: typedef struct _D3DMATRIX D3DXMATRIX, *LPD3DXMATRIX; #endif //!__cplusplus - //--------------------------------------------------------------------------- // Aligned Matrices // @@ -438,8 +419,6 @@ typedef struct _D3DXMATRIXA16 : public D3DXMATRIX typedef D3DXMATRIX _D3DXMATRIXA16; #endif //!__cplusplus - - #if _MSC_VER >= 1300 // VC7 #define D3DX_ALIGN16 __declspec(align(16)) #else @@ -448,8 +427,6 @@ typedef D3DXMATRIX _D3DXMATRIXA16; typedef D3DX_ALIGN16 _D3DXMATRIXA16 D3DXMATRIXA16, *LPD3DXMATRIXA16; - - //=========================================================================== // // Quaternions @@ -495,7 +472,6 @@ public: FLOAT x, y, z, w; } D3DXQUATERNION, *LPD3DXQUATERNION; - //=========================================================================== // // Planes @@ -535,7 +511,6 @@ public: FLOAT a, b, c, d; } D3DXPLANE, *LPD3DXPLANE; - //=========================================================================== // // Colors @@ -583,8 +558,6 @@ public: FLOAT r, g, b, a; } D3DXCOLOR, *LPD3DXCOLOR; - - //=========================================================================== // // D3DX math functions: @@ -618,7 +591,6 @@ FLOAT* WINAPI D3DXFloat16To32Array } #endif - //-------------------------- // 2D Vector //-------------------------- @@ -714,7 +686,6 @@ D3DXVECTOR2* WINAPI D3DXVec2TransformNormalArray } #endif - //-------------------------- // 3D Vector //-------------------------- @@ -828,13 +799,10 @@ D3DXVECTOR3* WINAPI D3DXVec3UnprojectArray ( D3DXVECTOR3 *pOut, UINT OutStride, CONST D3DXVECTOR3 *pV, UINT VStride, CONST D3D10_VIEWPORT *pViewport, CONST D3DXMATRIX *pProjection, CONST D3DXMATRIX *pView, CONST D3DXMATRIX *pWorld, UINT n); - #ifdef __cplusplus } #endif - - //-------------------------- // 4D Vector //-------------------------- @@ -913,7 +881,6 @@ D3DXVECTOR4* WINAPI D3DXVec4TransformArray } #endif - //-------------------------- // 4D Matrix //-------------------------- @@ -926,7 +893,6 @@ D3DXMATRIX* D3DXMatrixIdentity BOOL D3DXMatrixIsIdentity ( CONST D3DXMATRIX *pM ); - // non-inline #ifdef __cplusplus extern "C" { @@ -1086,7 +1052,6 @@ D3DXMATRIX* WINAPI D3DXMatrixReflect } #endif - //-------------------------- // Quaternion //-------------------------- @@ -1114,7 +1079,6 @@ BOOL D3DXQuaternionIsIdentity D3DXQUATERNION* D3DXQuaternionConjugate ( D3DXQUATERNION *pOut, CONST D3DXQUATERNION *pQ ); - // non-inline #ifdef __cplusplus extern "C" { @@ -1192,7 +1156,6 @@ D3DXQUATERNION* WINAPI D3DXQuaternionBaryCentric } #endif - //-------------------------- // Plane //-------------------------- @@ -1252,7 +1215,6 @@ D3DXPLANE* WINAPI D3DXPlaneTransformArray } #endif - //-------------------------- // Color //-------------------------- @@ -1298,9 +1260,6 @@ D3DXCOLOR* WINAPI D3DXColorAdjustContrast } #endif - - - //-------------------------- // Misc //-------------------------- @@ -1318,8 +1277,6 @@ FLOAT WINAPI D3DXFresnelTerm } #endif - - //=========================================================================== // // Matrix Stack @@ -1333,7 +1290,6 @@ typedef interface ID3DXMatrixStack *LPD3DXMATRIXSTACK; DEFINE_GUID(IID_ID3DXMatrixStack, 0xc7885ba7, 0xf990, 0x4fe7, 0x92, 0x2d, 0x85, 0x15, 0xe4, 0x77, 0xdd, 0x85); - #undef INTERFACE #define INTERFACE ID3DXMatrixStack @@ -1510,7 +1466,6 @@ FLOAT* WINAPI D3DXSHRotate // //============================================================================ - FLOAT* WINAPI D3DXSHRotateZ ( FLOAT *pOut, UINT Order, FLOAT Angle, CONST FLOAT *pIn ); @@ -1607,7 +1562,6 @@ __out_ecount(16) FLOAT* WINAPI D3DXSHMultiply4(__out_ecount(16) FLOAT *pOut,__in __out_ecount(25) FLOAT* WINAPI D3DXSHMultiply5(__out_ecount(25) FLOAT *pOut,__in_ecount(25) CONST FLOAT *pF,__in_ecount(25) CONST FLOAT *pG); __out_ecount(36) FLOAT* WINAPI D3DXSHMultiply6(__out_ecount(36) FLOAT *pOut,__in_ecount(36) CONST FLOAT *pF,__in_ecount(36) CONST FLOAT *pG); - //============================================================================ // // Basic Spherical Harmonic lighting routines @@ -1811,7 +1765,6 @@ HRESULT WINAPI D3DXVECTOR3 *pMin, D3DXVECTOR3 *pMax); - /////////////////////////////////////////////////////////////////////////// // CPU Optimization: /////////////////////////////////////////////////////////////////////////// @@ -1825,7 +1778,6 @@ HRESULT WINAPI // D3DX_SSE2_OPTIMIZED Use Intel Pentium IV SSE2 optimizations //------------------------------------------------------------------------- - typedef enum _D3DX_CPU_OPTIMIZATION { D3DX_NOT_OPTIMIZED = 0, @@ -1834,7 +1786,6 @@ typedef enum _D3DX_CPU_OPTIMIZATION D3DX_SSE_OPTIMIZED } D3DX_CPU_OPTIMIZATION; - //------------------------------------------------------------------------- // D3DXCpuOptimizations: // --------------------- @@ -1853,7 +1804,6 @@ D3DX_CPU_OPTIMIZATION WINAPI } #endif - #include "d3dx10math.inl" #if _MSC_VER >= 1200 diff --git a/gfx/include/dxsdk/d3dx10mesh.h b/gfx/include/dxsdk/d3dx10mesh.h index e5fed8fc93..adbdfc9874 100644 --- a/gfx/include/dxsdk/d3dx10mesh.h +++ b/gfx/include/dxsdk/d3dx10mesh.h @@ -36,7 +36,6 @@ DEFINE_GUID(IID_ID3DX10SPMesh, DEFINE_GUID(IID_ID3DX10PatchMesh, 0x3ce6cc22, 0xdbf2, 0x44f4, 0x89, 0x4d, 0xf9, 0xc3, 0x4a, 0x33, 0x71, 0x39); - // Mesh options - lower 3 bytes only, upper byte used by _D3DX10MESHOPT option flags enum _D3DX10_MESH { D3DX10_MESH_32_BIT = 0x001, // If set, then use 32 bit indices, if not set use 16 bit indices. @@ -166,7 +165,6 @@ DECLARE_INTERFACE_(ID3DX10Mesh, IUnknown) STDMETHOD(GetDeviceIndexBuffer)(THIS_ ID3D10Buffer **ppIndexBuffer) PURE; }; - // Flat API #ifdef __cplusplus extern "C" { @@ -187,7 +185,6 @@ HRESULT WINAPI } #endif //__cplusplus - // ID3DX10Mesh::Optimize options - upper byte only, lower 3 bytes used from _D3DX10MESH option flags enum _D3DX10_MESHOPT { D3DX10_MESHOPT_COMPACT = 0x01000000, @@ -202,7 +199,6 @@ enum _D3DX10_MESHOPT { }; - ////////////////////////////////////////////////////////////////////////// // ID3DXSkinInfo ////////////////////////////////////////////////////////////////////////// @@ -283,4 +279,3 @@ typedef struct _D3DX10_ATTRIBUTE_WEIGHTS #endif //__D3DX10MESH_H__ - diff --git a/gfx/include/dxsdk/d3dx10tex.h b/gfx/include/dxsdk/d3dx10tex.h index a6d8bb958b..6f5f2cdd0c 100644 --- a/gfx/include/dxsdk/d3dx10tex.h +++ b/gfx/include/dxsdk/d3dx10tex.h @@ -12,7 +12,6 @@ #ifndef __D3DX10TEX_H__ #define __D3DX10TEX_H__ - //---------------------------------------------------------------------------- // D3DX10_FILTER flags: // ------------------ @@ -144,8 +143,6 @@ typedef enum D3DX10_CHANNEL_FLAG D3DX10_CHANNEL_LUMINANCE = (1 << 4), } D3DX10_CHANNEL_FLAG; - - //---------------------------------------------------------------------------- // D3DX10_IMAGE_FILE_FORMAT: // --------------------- @@ -166,7 +163,6 @@ typedef enum D3DX10_IMAGE_FILE_FORMAT } D3DX10_IMAGE_FILE_FORMAT; - //---------------------------------------------------------------------------- // D3DX10_SAVE_TEXTURE_FLAG: // --------------------- @@ -179,8 +175,6 @@ typedef enum D3DX10_SAVE_TEXTURE_FLAG D3DX10_STF_USEINPUTBLOB = 0x0001, } D3DX10_SAVE_TEXTURE_FLAG; - - //---------------------------------------------------------------------------- // D3DX10_IMAGE_INFO: // --------------- @@ -221,16 +215,10 @@ typedef struct D3DX10_IMAGE_INFO D3DX10_IMAGE_FILE_FORMAT ImageFileFormat; } D3DX10_IMAGE_INFO; - - - - #ifdef __cplusplus extern "C" { #endif //__cplusplus - - ////////////////////////////////////////////////////////////////////////////// // Image File APIs /////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -272,7 +260,6 @@ extern "C" { // populated with source image information //---------------------------------------------------------------------------- - typedef struct D3DX10_IMAGE_LOAD_INFO { UINT Width; @@ -359,7 +346,6 @@ HRESULT WINAPI #define D3DX10GetImageInfoFromFile D3DX10GetImageInfoFromFileA #endif - HRESULT WINAPI D3DX10GetImageInfoFromResourceA( HMODULE hSrcModule, @@ -382,7 +368,6 @@ HRESULT WINAPI #define D3DX10GetImageInfoFromResource D3DX10GetImageInfoFromResourceA #endif - HRESULT WINAPI D3DX10GetImageInfoFromMemory( LPCVOID pSrcData, @@ -391,7 +376,6 @@ HRESULT WINAPI D3DX10_IMAGE_INFO* pSrcInfo, HRESULT* pHResult); - ////////////////////////////////////////////////////////////////////////////// // Create/Save Texture APIs ////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -433,7 +417,6 @@ HRESULT WINAPI // //---------------------------------------------------------------------------- - // FromFile HRESULT WINAPI @@ -484,7 +467,6 @@ HRESULT WINAPI #define D3DX10CreateTextureFromFile D3DX10CreateTextureFromFileA #endif - // FromResource (resources in dll/exes) HRESULT WINAPI @@ -539,7 +521,6 @@ HRESULT WINAPI #define D3DX10CreateTextureFromResource D3DX10CreateTextureFromResourceA #endif - // FromFileInMemory HRESULT WINAPI @@ -562,7 +543,6 @@ HRESULT WINAPI ID3D10Resource** ppTexture, HRESULT* pHResult); - ////////////////////////////////////////////////////////////////////////////// // Misc Texture APIs ///////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -604,7 +584,6 @@ typedef struct _D3DX10_TEXTURE_LOAD_INFO } D3DX10_TEXTURE_LOAD_INFO; - //---------------------------------------------------------------------------- // D3DX10LoadTextureFromTexture: // ---------------------------- @@ -614,14 +593,12 @@ typedef struct _D3DX10_TEXTURE_LOAD_INFO // //---------------------------------------------------------------------------- - HRESULT WINAPI D3DX10LoadTextureFromTexture( ID3D10Resource *pSrcTexture, D3DX10_TEXTURE_LOAD_INFO *pLoadInfo, ID3D10Resource *pDstTexture); - //---------------------------------------------------------------------------- // D3DX10FilterTexture: // ------------------ @@ -644,7 +621,6 @@ HRESULT WINAPI UINT SrcLevel, UINT MipFilter); - //---------------------------------------------------------------------------- // D3DX10SaveTextureToFile: // ---------------------- @@ -678,7 +654,6 @@ HRESULT WINAPI #define D3DX10SaveTextureToFile D3DX10SaveTextureToFileA #endif - //---------------------------------------------------------------------------- // D3DX10SaveTextureToMemory: // ---------------------- @@ -702,7 +677,6 @@ HRESULT WINAPI LPD3D10BLOB* ppDestBuf, UINT Flags); - //---------------------------------------------------------------------------- // D3DX10ComputeNormalMap: // --------------------- @@ -730,7 +704,6 @@ HRESULT WINAPI FLOAT Amplitude, ID3D10Texture2D *pDestTexture); - //---------------------------------------------------------------------------- // D3DX10SHProjectCubeMap: // ---------------------- diff --git a/gfx/include/dxsdk/d3dx11.h b/gfx/include/dxsdk/d3dx11.h index 103c782f17..f11744d95e 100644 --- a/gfx/include/dxsdk/d3dx11.h +++ b/gfx/include/dxsdk/d3dx11.h @@ -14,7 +14,6 @@ #ifndef __D3DX11_H__ #define __D3DX11_H__ - // Defines #include #include @@ -43,8 +42,6 @@ #endif #endif - - // Includes #include "d3d11.h" #include "d3dx11.h" @@ -52,7 +49,6 @@ #include "d3dx11tex.h" #include "d3dx11async.h" - // Errors #define _FACDD 0x876 #define MAKE_DDHRESULT( code ) MAKE_HRESULT( 1, _FACDD, code ) @@ -69,6 +65,5 @@ enum _D3DX11_ERR { D3DX11_ERR_CANNOT_REMOVE_LAST_ITEM = MAKE_DDHRESULT(2908), }; - #endif //__D3DX11_H__ diff --git a/gfx/include/dxsdk/d3dx11async.h b/gfx/include/dxsdk/d3dx11async.h index 4586c55ecd..6835112e30 100644 --- a/gfx/include/dxsdk/d3dx11async.h +++ b/gfx/include/dxsdk/d3dx11async.h @@ -17,7 +17,6 @@ extern "C" { #endif //__cplusplus - //---------------------------------------------------------------------------- // D3DX11Compile: // ------------------ @@ -161,4 +160,3 @@ HRESULT WINAPI D3DX11CreateAsyncShaderResourceViewProcessor(ID3D11Device *pDevic #endif //__D3DX11ASYNC_H__ - diff --git a/gfx/include/dxsdk/d3dx11core.h b/gfx/include/dxsdk/d3dx11core.h index 18e99351e0..d1979078ac 100644 --- a/gfx/include/dxsdk/d3dx11core.h +++ b/gfx/include/dxsdk/d3dx11core.h @@ -14,7 +14,6 @@ // Current name of the DLL shipped in the same SDK as this header. - #define D3DX11_DLL_W L"d3dx11_43.dll" #define D3DX11_DLL_A "d3dx11_43.dll" @@ -38,10 +37,8 @@ extern "C" { // D3DX11CreateVersion will return FALSE. (The number itself has no meaning.) /////////////////////////////////////////////////////////////////////////// - #define D3DX11_SDK_VERSION 43 - #ifdef D3D_DIAG_DLL BOOL WINAPI D3DX11DebugMute(BOOL Mute); #endif @@ -51,8 +48,6 @@ HRESULT WINAPI D3DX11CheckVersion(UINT D3DSdkVersion, UINT D3DX11SdkVersion); } #endif //__cplusplus - - ////////////////////////////////////////////////////////////////////////////// // ID3DX11ThreadPump: ////////////////////////////////////////////////////////////////////////////// diff --git a/gfx/include/dxsdk/d3dx11tex.h b/gfx/include/dxsdk/d3dx11tex.h index 16c0409136..dda1594e0a 100644 --- a/gfx/include/dxsdk/d3dx11tex.h +++ b/gfx/include/dxsdk/d3dx11tex.h @@ -12,7 +12,6 @@ #ifndef __D3DX11TEX_H__ #define __D3DX11TEX_H__ - //---------------------------------------------------------------------------- // D3DX11_FILTER flags: // ------------------ @@ -144,8 +143,6 @@ typedef enum D3DX11_CHANNEL_FLAG D3DX11_CHANNEL_LUMINANCE = (1 << 4), } D3DX11_CHANNEL_FLAG; - - //---------------------------------------------------------------------------- // D3DX11_IMAGE_FILE_FORMAT: // --------------------- @@ -166,7 +163,6 @@ typedef enum D3DX11_IMAGE_FILE_FORMAT } D3DX11_IMAGE_FILE_FORMAT; - //---------------------------------------------------------------------------- // D3DX11_SAVE_TEXTURE_FLAG: // --------------------- @@ -179,7 +175,6 @@ typedef enum D3DX11_SAVE_TEXTURE_FLAG D3DX11_STF_USEINPUTBLOB = 0x0001, } D3DX11_SAVE_TEXTURE_FLAG; - //---------------------------------------------------------------------------- // D3DX11_IMAGE_INFO: // --------------- @@ -220,16 +215,10 @@ typedef struct D3DX11_IMAGE_INFO D3DX11_IMAGE_FILE_FORMAT ImageFileFormat; } D3DX11_IMAGE_INFO; - - - - #ifdef __cplusplus extern "C" { #endif //__cplusplus - - ////////////////////////////////////////////////////////////////////////////// // Image File APIs /////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -271,7 +260,6 @@ extern "C" { // populated with source image information //---------------------------------------------------------------------------- - typedef struct D3DX11_IMAGE_LOAD_INFO { UINT Width; @@ -358,7 +346,6 @@ HRESULT WINAPI #define D3DX11GetImageInfoFromFile D3DX11GetImageInfoFromFileA #endif - HRESULT WINAPI D3DX11GetImageInfoFromResourceA( HMODULE hSrcModule, @@ -381,7 +368,6 @@ HRESULT WINAPI #define D3DX11GetImageInfoFromResource D3DX11GetImageInfoFromResourceA #endif - HRESULT WINAPI D3DX11GetImageInfoFromMemory( LPCVOID pSrcData, @@ -390,7 +376,6 @@ HRESULT WINAPI D3DX11_IMAGE_INFO* pSrcInfo, HRESULT* pHResult); - ////////////////////////////////////////////////////////////////////////////// // Create/Save Texture APIs ////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -432,7 +417,6 @@ HRESULT WINAPI // //---------------------------------------------------------------------------- - // FromFile HRESULT WINAPI @@ -483,7 +467,6 @@ HRESULT WINAPI #define D3DX11CreateTextureFromFile D3DX11CreateTextureFromFileA #endif - // FromResource (resources in dll/exes) HRESULT WINAPI @@ -538,7 +521,6 @@ HRESULT WINAPI #define D3DX11CreateTextureFromResource D3DX11CreateTextureFromResourceA #endif - // FromFileInMemory HRESULT WINAPI @@ -561,7 +543,6 @@ HRESULT WINAPI ID3D11Resource** ppTexture, HRESULT* pHResult); - ////////////////////////////////////////////////////////////////////////////// // Misc Texture APIs ///////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// @@ -603,7 +584,6 @@ typedef struct _D3DX11_TEXTURE_LOAD_INFO } D3DX11_TEXTURE_LOAD_INFO; - //---------------------------------------------------------------------------- // D3DX11LoadTextureFromTexture: // ---------------------------- @@ -613,7 +593,6 @@ typedef struct _D3DX11_TEXTURE_LOAD_INFO // //---------------------------------------------------------------------------- - HRESULT WINAPI D3DX11LoadTextureFromTexture( ID3D11DeviceContext *pContext, @@ -621,7 +600,6 @@ HRESULT WINAPI D3DX11_TEXTURE_LOAD_INFO *pLoadInfo, ID3D11Resource *pDstTexture); - //---------------------------------------------------------------------------- // D3DX11FilterTexture: // ------------------ @@ -645,7 +623,6 @@ HRESULT WINAPI UINT SrcLevel, UINT MipFilter); - //---------------------------------------------------------------------------- // D3DX11SaveTextureToFile: // ---------------------- @@ -681,7 +658,6 @@ HRESULT WINAPI #define D3DX11SaveTextureToFile D3DX11SaveTextureToFileA #endif - //---------------------------------------------------------------------------- // D3DX11SaveTextureToMemory: // ---------------------- @@ -706,7 +682,6 @@ HRESULT WINAPI ID3D10Blob** ppDestBuf, UINT Flags); - //---------------------------------------------------------------------------- // D3DX11ComputeNormalMap: // --------------------- @@ -735,7 +710,6 @@ HRESULT WINAPI FLOAT Amplitude, ID3D11Texture2D *pDestTexture); - //---------------------------------------------------------------------------- // D3DX11SHProjectCubeMap: // ---------------------- diff --git a/gfx/include/dxsdk/dcommon.h b/gfx/include/dxsdk/dcommon.h index 543dab13f4..70774522d7 100644 --- a/gfx/include/dxsdk/dcommon.h +++ b/gfx/include/dxsdk/dcommon.h @@ -191,7 +191,6 @@ typedef struct D2D_VECTOR_2F } D2D_VECTOR_2F; - /// /// A vector of 3 FLOAT values (x, y, z). /// @@ -203,7 +202,6 @@ typedef struct D2D_VECTOR_3F } D2D_VECTOR_3F; - /// /// A vector of 4 FLOAT values (x, y, z, w). /// @@ -216,7 +214,6 @@ typedef struct D2D_VECTOR_4F } D2D_VECTOR_4F; - /// /// Represents a rectangle defined by the coordinates of the upper-left corner /// (left, top) and the coordinates of the lower-right corner (right, bottom). @@ -230,7 +227,6 @@ typedef struct D2D_RECT_F } D2D_RECT_F; - /// /// Represents a rectangle defined by the coordinates of the upper-left corner /// (left, top) and the coordinates of the lower-right corner (right, bottom). @@ -256,7 +252,6 @@ typedef struct D2D_SIZE_F } D2D_SIZE_F; - /// /// Stores an ordered pair of integers, typically the width and height of a /// rectangle. @@ -268,7 +263,6 @@ typedef struct D2D_SIZE_U } D2D_SIZE_U; - /// /// Represents a 3-by-2 matrix. /// @@ -321,8 +315,6 @@ typedef struct D2D_MATRIX_3X2_F } D2D_MATRIX_3X2_F; - - /// /// Represents a 4-by-3 matrix. /// @@ -343,7 +335,6 @@ typedef struct D2D_MATRIX_4X3_F } D2D_MATRIX_4X3_F; - /// /// Represents a 4-by-4 matrix. /// @@ -364,7 +355,6 @@ typedef struct D2D_MATRIX_4X4_F } D2D_MATRIX_4X4_F; - /// /// Represents a 5-by-4 matrix. /// @@ -386,7 +376,6 @@ typedef struct D2D_MATRIX_5X4_F } D2D_MATRIX_5X4_F; - typedef D2D_POINT_2F D2D1_POINT_2F; typedef D2D_POINT_2U D2D1_POINT_2U; typedef D2D_POINT_2L D2D1_POINT_2L; @@ -397,7 +386,6 @@ typedef D2D_SIZE_F D2D1_SIZE_F; typedef D2D_SIZE_U D2D1_SIZE_U; typedef D2D_MATRIX_3X2_F D2D1_MATRIX_3X2_F; - #pragma warning(pop) #endif /* DCOMMON_H_INCLUDED */ diff --git a/gfx/include/dxsdk/dsconf.h b/gfx/include/dxsdk/dsconf.h index 25a321a9f7..c04e1aea41 100644 --- a/gfx/include/dxsdk/dsconf.h +++ b/gfx/include/dxsdk/dsconf.h @@ -14,7 +14,6 @@ /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ - #ifndef __DSOUND_INCLUDED__ #error dsound.h not included #endif // __DSOUND_INCLUDED__ @@ -23,11 +22,9 @@ extern "C" { #endif // __cplusplus - // DirectSound Configuration Component GUID {11AB3EC0-25EC-11d1-A4D8-00C04FC28ACA} DEFINE_GUID(CLSID_DirectSoundPrivate, 0x11ab3ec0, 0x25ec, 0x11d1, 0xa4, 0xd8, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca); - // // DirectSound Device Properties {84624F82-25EC-11d1-A4D8-00C04FC28ACA} // @@ -75,7 +72,6 @@ typedef enum DIRECTSOUNDDEVICE_DATAFLOW_CAPTURE } DIRECTSOUNDDEVICE_DATAFLOW; - typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA { LPSTR DeviceName; // waveIn/waveOut device name @@ -191,12 +187,10 @@ typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA #define PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA #endif // DIRECTSOUND_VERSION >= 0x0700 - #ifdef __cplusplus } #endif // __cplusplus - /*#endif*/ /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ /*#pragma endregion*/ diff --git a/gfx/include/dxsdk/dsetup.h b/gfx/include/dxsdk/dsetup.h index ebada13fd3..8cd464e811 100644 --- a/gfx/include/dxsdk/dsetup.h +++ b/gfx/include/dxsdk/dsetup.h @@ -60,8 +60,6 @@ extern "C" { #define DSETUP_PROMPTFORDRIVERS 0x10000000 /* OBSOLETE. prompt when replacing display/audio drivers */ #define DSETUP_RESTOREDRIVERS 0x20000000 /* OBSOLETE. restore display/audio drivers */ - - //****************************************************************** // DirectX Setup Callback mechanism //****************************************************************** @@ -74,11 +72,6 @@ extern "C" { #define DSETUP_CB_MSG_PROGRESS 18 #define DSETUP_CB_MSG_WARNING_DISABLED_COMPONENT 19 - - - - - typedef struct _DSETUP_CB_PROGRESS { DWORD dwPhase; @@ -97,7 +90,6 @@ enum _DSETUP_CB_PROGRESS_PHASE DSETUP_FINALIZING }; - #ifdef _WIN32 // // Data Structures @@ -169,7 +161,6 @@ typedef PDIRECTXREGISTERAPP2A PDIRECTXREGISTERAPP2; typedef LPDIRECTXREGISTERAPP2A LPDIRECTXREGISTERAPP2; #endif // UNICODE - // // API // @@ -275,7 +266,6 @@ typedef UINT (WINAPI * LPDIRECTXSETUPGETEULA)(LPSTR, UINT, WORD); #endif // WIN32 - #ifdef __cplusplus }; #endif diff --git a/gfx/include/dxsdk/dwrite.h b/gfx/include/dxsdk/dwrite.h index 22b18b9568..ea887fdbf3 100644 --- a/gfx/include/dxsdk/dwrite.h +++ b/gfx/include/dxsdk/dwrite.h @@ -464,7 +464,6 @@ enum DWRITE_INFORMATIONAL_STRING_ID DWRITE_INFORMATIONAL_STRING_WWS_FAMILY_NAME = DWRITE_INFORMATIONAL_STRING_WEIGHT_STRETCH_STYLE_FAMILY_NAME, }; - /// /// The DWRITE_FONT_METRICS structure specifies the metrics of a font face that /// are applicable to all glyphs within the font face. @@ -1295,7 +1294,6 @@ interface DWRITE_DECLARE_INTERFACE("5f49804d-7024-4d43-bfa9-d25984f53849") IDWri ) PURE; }; - interface IDWriteFactory; interface IDWriteFontFileEnumerator; @@ -2036,7 +2034,6 @@ struct DWRITE_TRIMMING UINT32 delimiterCount; }; - interface IDWriteTypography; interface IDWriteInlineObject; @@ -2288,7 +2285,6 @@ interface DWRITE_DECLARE_INTERFACE("9c906818-31d7-4fd3-a151-7c5e225db55a") IDWri ) PURE; }; - /// /// Font typography setting. /// @@ -3257,7 +3253,6 @@ struct DWRITE_LINE_METRICS BOOL isTrimmed; }; - /// /// The DWRITE_CLUSTER_METRICS structure contains information about a glyph cluster. /// @@ -3301,7 +3296,6 @@ struct DWRITE_CLUSTER_METRICS UINT16 padding : 11; }; - /// /// Overall metrics associated with text after layout. /// All coordinates are in device independent pixels (DIPs). @@ -3365,7 +3359,6 @@ struct DWRITE_TEXT_METRICS UINT32 lineCount; }; - /// /// Properties describing the geometric measurement of an /// application-defined inline object. @@ -3395,7 +3388,6 @@ struct DWRITE_INLINE_OBJECT_METRICS BOOL supportsSideways; }; - /// /// The DWRITE_OVERHANG_METRICS structure holds how much any visible pixels /// (in DIPs) overshoot each side of the layout or inline objects. @@ -3430,7 +3422,6 @@ struct DWRITE_OVERHANG_METRICS FLOAT bottom; }; - /// /// Geometry enclosing of text positions. /// @@ -3482,10 +3473,8 @@ struct DWRITE_HIT_TEST_METRICS BOOL isTrimmed; }; - interface IDWriteTextRenderer; - /// /// The IDWriteInlineObject interface wraps an application defined inline graphic, /// allowing DWrite to query metrics as if it was a glyph inline with the text. @@ -4400,7 +4389,6 @@ interface DWRITE_DECLARE_INTERFACE("53737037-6d14-410b-9bfe-0b182bb70961") IDWri using IDWriteTextFormat::GetLocaleName; }; - /// /// Encapsulates a 32-bit device independent bitmap and device context, which can be used for rendering glyphs. /// @@ -5083,7 +5071,6 @@ interface DWRITE_DECLARE_INTERFACE("b859ee5a-d838-4b5b-a2e8-1adc7d93db48") IDWri }; // interface IDWriteFactory - /// /// Creates a DirectWrite factory object that is used for subsequent creation of individual DirectWrite objects. /// @@ -5117,5 +5104,4 @@ EXTERN_C HRESULT DWRITE_EXPORT DWriteCreateFactory( // DWrite errors have moved to winerror.h - #endif /* DWRITE_H_INCLUDED */ diff --git a/gfx/include/dxsdk/dwrite_1.h b/gfx/include/dxsdk/dwrite_1.h index 301d30dce4..c7bc62e6d0 100644 --- a/gfx/include/dxsdk/dwrite_1.h +++ b/gfx/include/dxsdk/dwrite_1.h @@ -14,8 +14,6 @@ #include - - /// /// The overall kind of family. /// @@ -623,7 +621,6 @@ enum DWRITE_GLYPH_ORIENTATION_ANGLE DWRITE_GLYPH_ORIENTATION_ANGLE_270_DEGREES, }; - struct DWRITE_FONT_METRICS1 : public DWRITE_FONT_METRICS { /// @@ -715,7 +712,6 @@ struct DWRITE_FONT_METRICS1 : public DWRITE_FONT_METRICS BOOL hasTypographicMetrics; }; - /// /// Metrics for caret placement in a font. /// @@ -740,7 +736,6 @@ struct DWRITE_CARET_METRICS INT16 offset; }; - /// /// Typeface classification values, used for font selection and matching. /// @@ -812,7 +807,6 @@ union DWRITE_PANOSE } symbol; }; - /// /// Range of Unicode codepoints. /// @@ -829,7 +823,6 @@ struct DWRITE_UNICODE_RANGE UINT32 last; }; - /// /// Script-specific properties for caret navigation and justification. /// @@ -937,7 +930,6 @@ struct DWRITE_SCRIPT_PROPERTIES UINT32 reserved : 25; }; - /// /// Justification information per glyph. /// @@ -1007,7 +999,6 @@ struct DWRITE_JUSTIFICATION_OPPORTUNITY UINT32 reserved : 12; }; - interface IDWriteTextAnalysisSource1; interface IDWriteTextAnalysisSink1; interface IDWriteRenderingParams1; @@ -1081,7 +1072,6 @@ interface DWRITE_DECLARE_INTERFACE("30572f99-dac6-41db-a16e-0486307e606a") IDWri using IDWriteFactory::CreateCustomRenderingParams; }; - /// /// The interface that represents an absolute reference to a font face. /// It contains font face type, appropriate file references and face identification data. @@ -1341,7 +1331,6 @@ interface DWRITE_DECLARE_INTERFACE("a71efdb4-9fdb-4838-ad90-cfc3be8c3daf") IDWri using IDWriteFontFace::GetRecommendedRenderingMode; }; - /// /// The IDWriteFont interface represents a physical font in a font collection. /// @@ -1711,7 +1700,6 @@ interface DWRITE_DECLARE_INTERFACE("80DAD800-E21F-4E83-96CE-BFCCE500DB7C") IDWri ) PURE; }; - /// /// The interface implemented by the client to provide needed information to /// the text analyzer, such as the text and associated text properties. @@ -1752,7 +1740,6 @@ interface DWRITE_DECLARE_INTERFACE("639CFAD8-0FB4-4B21-A58A-067920120009") IDWri ) PURE; }; - /// /// The interface implemented by the client to receive the /// output of the text analyzers. @@ -1792,7 +1779,6 @@ interface DWRITE_DECLARE_INTERFACE("B0D941A0-85E7-4D8B-9FD3-5CED9934482A") IDWri ) PURE; }; - /// /// The IDWriteTextLayout1 interface represents a block of text after it has /// been fully analyzed and formatted. diff --git a/gfx/include/dxsdk/dwrite_2.h b/gfx/include/dxsdk/dwrite_2.h index 10a5dd4d57..ffa8dd2d69 100644 --- a/gfx/include/dxsdk/dwrite_2.h +++ b/gfx/include/dxsdk/dwrite_2.h @@ -14,10 +14,8 @@ #include - interface IDWriteFontFallback; - /// /// How to align glyphs to the margin. /// @@ -37,7 +35,6 @@ enum DWRITE_OPTICAL_ALIGNMENT DWRITE_OPTICAL_ALIGNMENT_NO_SIDE_BEARINGS, }; - /// /// Whether to enable grid-fitting of glyph outlines (a.k.a. hinting). /// @@ -59,7 +56,6 @@ enum DWRITE_GRID_FIT_MODE DWRITE_GRID_FIT_MODE_ENABLED }; - /// /// Overall metrics associated with text after layout. /// All coordinates are in device independent pixels (DIPs). @@ -74,7 +70,6 @@ struct DWRITE_TEXT_METRICS1 : DWRITE_TEXT_METRICS FLOAT heightIncludingTrailingWhitespace; }; - /// /// The text renderer interface represents a set of application-defined /// callbacks that perform rendering of text, inline objects, and decorations @@ -243,7 +238,6 @@ interface DWRITE_DECLARE_INTERFACE("D3E0E934-22A0-427E-AAE4-7D9574B59DB1") IDWri using IDWriteTextRenderer::DrawInlineObject; }; - /// /// The format of text used for text layout. /// @@ -325,7 +319,6 @@ interface DWRITE_DECLARE_INTERFACE("5F174B49-0D8B-4CFB-8BCA-F1CCE9D06C67") IDWri ) PURE; }; - /// /// The text layout interface represents a block of text after it has /// been fully analyzed and formatted. @@ -426,7 +419,6 @@ interface DWRITE_DECLARE_INTERFACE("1093C18F-8D5E-43F0-B064-0917311B525E") IDWri ) PURE; }; - /// /// The text analyzer interface represents a set of application-defined /// callbacks that perform rendering of text, inline objects, and decorations @@ -517,7 +509,6 @@ interface DWRITE_DECLARE_INTERFACE("553A9FF3-5693-4DF7-B52B-74806F7F2EB9") IDWri using IDWriteTextAnalyzer1::GetGlyphOrientationTransform; }; - /// /// A font fallback definition used for mapping characters to fonts capable of /// supporting them. @@ -564,7 +555,6 @@ interface DWRITE_DECLARE_INTERFACE("EFA008F9-F7A1-48BF-B05C-F224713CC0FF") IDWri ) PURE; }; - /// /// Builder used to create a font fallback definition by appending a series of /// fallback mappings, followed by a creation call. @@ -971,5 +961,4 @@ interface DWRITE_DECLARE_INTERFACE("0439fc60-ca44-4994-8dee-3a9af7b732ec") IDWri using IDWriteFactory::CreateGlyphRunAnalysis; }; - #endif /* DWRITE_2_H_INCLUDED */ diff --git a/gfx/include/dxsdk/dwrite_3.h b/gfx/include/dxsdk/dwrite_3.h index 45eb6203cb..a1bfa6761e 100644 --- a/gfx/include/dxsdk/dwrite_3.h +++ b/gfx/include/dxsdk/dwrite_3.h @@ -24,7 +24,6 @@ interface IDWriteFontFamily1; interface IDWriteStringList; interface IDWriteFontDownloadQueue; - /// /// A font resource could not be accessed because it was remote. This can happen /// when calling CreateFontFace on a non-local font or trying to measure/draw @@ -218,7 +217,6 @@ enum DWRITE_FONT_PROPERTY_ID DWRITE_FONT_PROPERTY_ID_FACE_NAME = DWRITE_FONT_PROPERTY_ID_WEIGHT_STRETCH_STYLE_FACE_NAME, }; - /// /// Font property used for filtering font sets and /// building a font set with explicit properties. @@ -249,7 +247,6 @@ struct DWRITE_FONT_PROPERTY _Field_z_ _Maybenull_ WCHAR const* localeName; }; - /// /// Specifies the locality of a resource. /// @@ -275,7 +272,6 @@ enum DWRITE_LOCALITY DWRITE_LOCALITY_LOCAL, }; - /// /// Represents a method of rendering glyphs. /// @@ -338,7 +334,6 @@ enum DWRITE_RENDERING_MODE1 DWRITE_RENDERING_MODE1_NATURAL_SYMMETRIC_DOWNSAMPLED, }; - /// /// The interface that represents text rendering settings for glyph rasterization and filtering. /// @@ -350,7 +345,6 @@ interface DWRITE_DECLARE_INTERFACE("B7924BAA-391B-412A-8C5C-E44CC2D867DC") IDWri STDMETHOD_(DWRITE_RENDERING_MODE1, GetRenderingMode1)() PURE; }; - /// /// The root factory interface for all DWrite objects. /// @@ -529,7 +523,6 @@ interface DWRITE_DECLARE_INTERFACE("9A1B41C3-D3BB-466A-87FC-FE67556A3B65") IDWri ) PURE; }; - /// /// Set of fonts used for creating font faces, selecting nearest matching fonts, and filtering. /// Unlike IDWriteFontFamily and IDWriteFontList, which are part of the IDWriteFontCollection heirarchy, font sets @@ -714,7 +707,6 @@ interface DWRITE_DECLARE_INTERFACE("53585141-D9F8-4095-8321-D73CF6BD116B") IDWri ) PURE; }; - /// /// Builder interface to add font face references and create a font set. /// @@ -787,7 +779,6 @@ interface DWRITE_DECLARE_INTERFACE("2F642AFE-9C68-4F40-B8BE-457401AFCB3D") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("53585141-D9F8-4095-8321-D73CF6BD116C") IDWriteFontCollection1 : public IDWriteFontCollection { /// @@ -817,7 +808,6 @@ interface DWRITE_DECLARE_INTERFACE("53585141-D9F8-4095-8321-D73CF6BD116C") IDWri using IDWriteFontCollection::GetFontFamily; }; - /// /// The IDWriteFontFamily interface represents a set of fonts that share the same design but are differentiated /// by weight, stretch, and style. @@ -870,7 +860,6 @@ interface DWRITE_DECLARE_INTERFACE("DA20D8EF-812A-4C43-9802-62EC4ABD7ADF") IDWri ) PURE; }; - /// /// The IDWriteFontList interface represents a list of fonts. /// @@ -922,7 +911,6 @@ interface DWRITE_DECLARE_INTERFACE("DA20D8EF-812A-4C43-9802-62EC4ABD7ADE") IDWri ) PURE; }; - /// /// A uniquely identifying reference to a font, from which you can create a font /// face to query font metrics and use for rendering. A font face reference @@ -1083,7 +1071,6 @@ interface DWRITE_DECLARE_INTERFACE("5E7FA7CA-DDE3-424C-89F0-9FCD6FED58CD") IDWri ) PURE; }; - /// /// The IDWriteFont interface represents a font in a font collection. /// @@ -1145,7 +1132,6 @@ interface DWRITE_DECLARE_INTERFACE("29748ED6-8C9C-4A6A-BE0B-D912E8538944") IDWri STDMETHOD_(DWRITE_LOCALITY, GetLocality)() PURE; }; - /// /// The interface that represents an absolute reference to a font face. /// It contains font face type, appropriate file references and face identification data. @@ -1344,7 +1330,6 @@ interface DWRITE_DECLARE_INTERFACE("D37D7598-09BE-4222-A236-2081341CC1F2") IDWri ) PURE; }; - /// /// Represents a collection of strings indexed by number. /// An IDWriteStringList is otherwise identical to IDWriteLocalizedStrings except @@ -1420,7 +1405,6 @@ interface DWRITE_DECLARE_INTERFACE("CFEE3140-1157-47CA-8B85-31BFCF3F2D0E") IDWri ) PURE; }; - /// /// Application-defined callback interface that receives notifications from the font /// download queue (IDWriteFontDownloadQueue interface). Callbacks will occur on the @@ -1446,7 +1430,6 @@ interface DWRITE_DECLARE_INTERFACE("B06FE5B9-43EC-4393-881B-DBE4DC72FDA7") IDWri ) PURE; }; - /// /// Interface that enqueues download requests for remote fonts, characters, glyphs, and font fragments. /// Provides methods to asynchronously execute a download, cancel pending downloads, and be notified of @@ -1545,7 +1528,6 @@ interface DWRITE_DECLARE_INTERFACE("B71E6052-5AEA-4FA3-832E-F60D431F7E91") IDWri STDMETHOD_(UINT64, GetGenerationCount)() PURE; }; - /// /// The GDI interop interface provides interoperability with GDI. /// @@ -1784,13 +1766,10 @@ interface DWRITE_DECLARE_INTERFACE("07DDCD52-020E-4DE8-AC33-6C953D83F92D") IDWri using IDWriteTextLayout2::GetLineMetrics; }; - //////////////////////////////////////////////////////////////////////////////////////////////////// - #if NTDDI_VERSION >= NTDDI_WIN10_RS1 - /// /// Represents a color glyph run. The IDWriteFactory4::TranslateColorGlyphRun /// method returns an ordered collection of color glyph runs of varying types @@ -1813,7 +1792,6 @@ struct DWRITE_COLOR_GLYPH_RUN1 : DWRITE_COLOR_GLYPH_RUN DWRITE_MEASURING_MODE measuringMode; }; - /// /// Data for a single glyph from GetGlyphImageData. /// @@ -1868,7 +1846,6 @@ struct DWRITE_GLYPH_IMAGE_DATA D2D1_POINT_2L verticalBottomOrigin; }; - /// /// Enumerator for an ordered collection of color glyph runs. /// @@ -1892,7 +1869,6 @@ interface DWRITE_DECLARE_INTERFACE("7C5F86DA-C7A1-4F05-B8E1-55A179FE5A35") IDWri using IDWriteColorGlyphRunEnumerator::GetCurrentRun; }; - /// /// The interface that represents an absolute reference to a font face. /// It contains font face type, appropriate file references and face identification data. @@ -1958,7 +1934,6 @@ interface DWRITE_DECLARE_INTERFACE("27F2A904-4EB8-441D-9678-0563F53E3E2F") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("4B0B5BD3-0797-4549-8AC5-FE915CC53856") IDWriteFactory4 : public IDWriteFactory3 { /// @@ -2038,10 +2013,8 @@ interface DWRITE_DECLARE_INTERFACE("4B0B5BD3-0797-4549-8AC5-FE915CC53856") IDWri #endif // NTDDI_VERSION >= NTDDI_WIN10_RS1 - //////////////////////////////////////////////////////////////////////////////////////////////////// - #if NTDDI_VERSION >= NTDDI_WIN10_RS2 interface DWRITE_DECLARE_INTERFACE("3FF7715F-3CDC-4DC6-9B72-EC5621DCCAFD") IDWriteFontSetBuilder1 : public IDWriteFontSetBuilder @@ -2080,7 +2053,6 @@ interface DWRITE_DECLARE_INTERFACE("CE25F8FD-863B-4D13-9651-C1F88DC73FE2") IDWri STDMETHOD(GetResult)() PURE; }; - /// /// DWRITE_FILE_FRAGMENT represents a range of bytes in a font file. /// @@ -2097,7 +2069,6 @@ struct DWRITE_FILE_FRAGMENT UINT64 fragmentSize; }; - /// /// IDWriteRemoteFontFileStream represents a font file stream parts of which may be /// non-local. Non-local data must be downloaded before it can be accessed using @@ -2174,7 +2145,6 @@ interface DWRITE_DECLARE_INTERFACE("4DB3757A-2C72-4ED9-B2B6-1ABABE1AFF9C") IDWri ) PURE; }; - /// /// Specifies the container format of a font resource. A container format is distinct from /// a font file format (DWRITE_FONT_FILE_TYPE) because the container describes the container @@ -2187,7 +2157,6 @@ enum DWRITE_CONTAINER_TYPE DWRITE_CONTAINER_TYPE_WOFF2 }; - /// /// The IDWriteRemoteFontFileLoader interface represents a font file loader that can access /// remote (i.e., downloadable) fonts. The IDWriteFactory5::CreateHttpFontFileLoader method @@ -2260,7 +2229,6 @@ interface DWRITE_DECLARE_INTERFACE("68648C83-6EDE-46C0-AB46-20083A887FDE") IDWri ) PURE; }; - /// /// The IDWriteInMemoryFontFileLoader interface enables clients to reference /// in-memory fonts without having to implement a custom loader. The @@ -2306,7 +2274,6 @@ interface DWRITE_DECLARE_INTERFACE("DC102F47-A12D-4B1C-822D-9E117E33043F") IDWri STDMETHOD_(UINT32, GetFileCount)() PURE; }; - /// /// The root factory interface for all DWrite objects. /// @@ -2395,13 +2362,10 @@ interface DWRITE_DECLARE_INTERFACE("958DB99A-BE2A-4F09-AF7D-65189803D1D3") IDWri #endif // NTDDI_VERSION >= NTDDI_WIN10_RS2 - //////////////////////////////////////////////////////////////////////////////////////////////////// - #if NTDDI_VERSION >= NTDDI_WIN10_RS3 - interface IDWriteFontResource; interface IDWriteFontFace5; interface IDWriteFontFaceReference1; @@ -2410,13 +2374,11 @@ interface IDWriteFontCollection2; interface IDWriteTextFormat3; interface IDWriteFontSetBuilder2; - /// /// Creates an OpenType tag for a font axis. /// #define DWRITE_MAKE_FONT_AXIS_TAG(a,b,c,d) (static_cast(DWRITE_MAKE_OPENTYPE_TAG(a,b,c,d))) - /// /// Four character identifier for a font axis. /// @@ -2432,7 +2394,6 @@ enum DWRITE_FONT_AXIS_TAG : UINT32 DWRITE_FONT_AXIS_TAG_ITALIC = DWRITE_MAKE_FONT_AXIS_TAG('i','t','a','l'), }; - /// /// Value for a font axis, used when querying and creating font instances. /// @@ -2451,7 +2412,6 @@ struct DWRITE_FONT_AXIS_VALUE FLOAT value; }; - /// /// Minimum and maximum range of a font axis. /// @@ -2473,7 +2433,6 @@ struct DWRITE_FONT_AXIS_RANGE FLOAT maxValue; }; - /// /// How font families are grouped together, used by IDWriteFontCollection. /// @@ -2495,7 +2454,6 @@ enum DWRITE_FONT_FAMILY_MODEL DWRITE_FONT_FAMILY_MODEL_WEIGHT_STRETCH_STYLE, }; - /// /// Apply certain axes automatically in layout during font selection. /// @@ -2518,7 +2476,6 @@ enum DWRITE_AUTOMATIC_FONT_AXES DEFINE_ENUM_FLAG_OPERATORS(DWRITE_AUTOMATIC_FONT_AXES); #endif - /// /// Attributes for a font axis. /// @@ -2551,7 +2508,6 @@ enum DWRITE_FONT_AXIS_ATTRIBUTES DEFINE_ENUM_FLAG_OPERATORS(DWRITE_FONT_AXIS_ATTRIBUTES); #endif - interface DWRITE_DECLARE_INTERFACE("F3744D80-21F7-42EB-B35D-995BC72FC223") IDWriteFactory6 : public IDWriteFactory5 { /// @@ -2688,7 +2644,6 @@ interface DWRITE_DECLARE_INTERFACE("F3744D80-21F7-42EB-B35D-995BC72FC223") IDWri using IDWriteFactory::CreateTextFormat; }; - interface DWRITE_DECLARE_INTERFACE("98EFF3A5-B667-479A-B145-E2FA5B9FDC29") IDWriteFontFace5 : public IDWriteFontFace4 { /// @@ -2737,7 +2692,6 @@ interface DWRITE_DECLARE_INTERFACE("98EFF3A5-B667-479A-B145-E2FA5B9FDC29") IDWri STDMETHOD_(BOOL, Equals)(IDWriteFontFace* fontFace) PURE; }; - /// /// Interface to return axis information for a font resource and create specific font face instances. /// @@ -2913,7 +2867,6 @@ interface DWRITE_DECLARE_INTERFACE("1F803A76-6871-48E8-987F-B975551C50F2") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("C081FE77-2FD1-41AC-A5A3-34983C4BA61A") IDWriteFontFaceReference1 : public IDWriteFontFaceReference { /// @@ -2951,7 +2904,6 @@ interface DWRITE_DECLARE_INTERFACE("C081FE77-2FD1-41AC-A5A3-34983C4BA61A") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("EE5BA612-B131-463C-8F4F-3189B9401E45") IDWriteFontSetBuilder2 : public IDWriteFontSetBuilder1 { /// @@ -3001,7 +2953,6 @@ interface DWRITE_DECLARE_INTERFACE("EE5BA612-B131-463C-8F4F-3189B9401E45") IDWri using IDWriteFontSetBuilder1::AddFontFile; }; - interface DWRITE_DECLARE_INTERFACE("7E9FDA85-6C92-4053-BC47-7AE3530DB4D3") IDWriteFontSet1 : public IDWriteFontSet { /// @@ -3229,7 +3180,6 @@ interface DWRITE_DECLARE_INTERFACE("7E9FDA85-6C92-4053-BC47-7AE3530DB4D3") IDWri STDMETHOD_(DWRITE_LOCALITY, GetFontLocality)(UINT32 listIndex) PURE; }; - interface DWRITE_DECLARE_INTERFACE("C0763A34-77AF-445A-B735-08C37B0A5BF5") IDWriteFontList2 : public IDWriteFontList1 { /// @@ -3244,7 +3194,6 @@ interface DWRITE_DECLARE_INTERFACE("C0763A34-77AF-445A-B735-08C37B0A5BF5") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("3ED49E77-A398-4261-B9CF-C126C2131EF3") IDWriteFontFamily2 : public IDWriteFontFamily1 { /// @@ -3276,7 +3225,6 @@ interface DWRITE_DECLARE_INTERFACE("3ED49E77-A398-4261-B9CF-C126C2131EF3") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("514039C6-4617-4064-BF8B-92EA83E506E0") IDWriteFontCollection2 : public IDWriteFontCollection1 { /// @@ -3336,7 +3284,6 @@ interface DWRITE_DECLARE_INTERFACE("514039C6-4617-4064-BF8B-92EA83E506E0") IDWri ) PURE; }; - interface DWRITE_DECLARE_INTERFACE("05A9BF42-223F-4441-B5FB-8263685F55E9") IDWriteTextLayout4 : public IDWriteTextLayout3 { /// @@ -3393,7 +3340,6 @@ interface DWRITE_DECLARE_INTERFACE("05A9BF42-223F-4441-B5FB-8263685F55E9") IDWri STDMETHOD(SetAutomaticFontAxes)(DWRITE_AUTOMATIC_FONT_AXES automaticFontAxes) PURE; }; - interface DWRITE_DECLARE_INTERFACE("6D3B5641-E550-430D-A85B-B7BF48A93427") IDWriteTextFormat3 : public IDWriteTextFormat2 { /// @@ -3445,7 +3391,6 @@ interface DWRITE_DECLARE_INTERFACE("6D3B5641-E550-430D-A85B-B7BF48A93427") IDWri STDMETHOD(SetAutomaticFontAxes)(DWRITE_AUTOMATIC_FONT_AXES automaticFontAxes) PURE; }; - interface DWRITE_DECLARE_INTERFACE("2397599D-DD0D-4681-BD6A-F4F31EAADE77") IDWriteFontFallback1 : public IDWriteFontFallback { /// diff --git a/gfx/include/dxsdk/dxdiag.h b/gfx/include/dxsdk/dxdiag.h index 82b607c02a..d27ebf1035 100644 --- a/gfx/include/dxsdk/dxdiag.h +++ b/gfx/include/dxsdk/dxdiag.h @@ -14,7 +14,6 @@ #pragma region Desktop Family #if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) - #include // for DECLARE_INTERFACE_ and HRESULT // This identifier is passed to IDxDiagProvider::Initialize in order to ensure that an @@ -28,7 +27,6 @@ extern "C" { #endif - /**************************************************************************** * * DxDiag Errors @@ -36,7 +34,6 @@ extern "C" { ****************************************************************************/ #define DXDIAG_E_INSUFFICIENT_BUFFER ((HRESULT)0x8007007AL) // HRESULT_FROM_WIN32(ERROR_INSUFFICIENT_BUFFER) - /**************************************************************************** * * DxDiag CLSIDs @@ -47,7 +44,6 @@ extern "C" { DEFINE_GUID(CLSID_DxDiagProvider, 0xA65B8071, 0x3BFE, 0x4213, 0x9A, 0x5B, 0x49, 0x1D, 0xA4, 0x46, 0x1C, 0xA7); - /**************************************************************************** * * DxDiag Interface IIDs @@ -62,7 +58,6 @@ DEFINE_GUID(IID_IDxDiagProvider, DEFINE_GUID(IID_IDxDiagContainer, 0x7D0F462F, 0x4064, 0x4862, 0xBC, 0x7F, 0x93, 0x3E, 0x50, 0x58, 0xC1, 0x0F); - /**************************************************************************** * * DxDiag Interface Pointer definitions @@ -73,7 +68,6 @@ typedef struct IDxDiagProvider *LPDXDIAGPROVIDER, *PDXDIAGPROVIDER; typedef struct IDxDiagContainer *LPDXDIAGCONTAINER, *PDXDIAGCONTAINER; - /**************************************************************************** * * DxDiag Structures @@ -91,7 +85,6 @@ typedef struct _DXDIAG_INIT_PARAMS VOID* pReserved; // Reserved. Must be NULL. } DXDIAG_INIT_PARAMS; - /**************************************************************************** * * DxDiag Application Interfaces @@ -115,7 +108,6 @@ DECLARE_INTERFACE_(IDxDiagProvider,IUnknown) STDMETHOD(GetRootContainer) (THIS_ IDxDiagContainer **ppInstance) PURE; }; - // // COM definition for IDxDiagContainer // @@ -137,7 +129,6 @@ DECLARE_INTERFACE_(IDxDiagContainer,IUnknown) STDMETHOD(GetProp) (THIS_ LPCWSTR pwszPropName, VARIANT *pvarProp) PURE; }; - /**************************************************************************** * * DxDiag application interface macros @@ -182,15 +173,12 @@ DECLARE_INTERFACE_(IDxDiagContainer,IUnknown) #endif - #ifdef __cplusplus } #endif - #endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ #pragma endregion #endif /* _DXDIAG_H_ */ - diff --git a/gfx/include/dxsdk/dxerr.h b/gfx/include/dxsdk/dxerr.h index 2bd7591197..3bafb2fca9 100644 --- a/gfx/include/dxsdk/dxerr.h +++ b/gfx/include/dxsdk/dxerr.h @@ -32,7 +32,6 @@ const WCHAR* WINAPI DXGetErrorStringW(__in HRESULT hr); #define DXGetErrorString DXGetErrorStringA #endif - // // DXGetErrorDescription // @@ -52,7 +51,6 @@ const WCHAR* WINAPI DXGetErrorDescriptionW(__in HRESULT hr); #define DXGetErrorDescription DXGetErrorDescriptionA #endif - // // DXTrace // @@ -77,7 +75,6 @@ HRESULT WINAPI DXTraceW( __in_z const char* strFile, __in DWORD dwLine, __in HRE #define DXTrace DXTraceA #endif - // // Helper macros // @@ -91,7 +88,6 @@ HRESULT WINAPI DXTraceW( __in_z const char* strFile, __in DWORD dwLine, __in HRE #define DXTRACE_ERR_MSGBOX(str,hr) (hr) #endif - #ifdef __cplusplus } #endif //__cplusplus diff --git a/gfx/include/dxsdk/dxfile.h b/gfx/include/dxsdk/dxfile.h index 74e80e585b..3fb665ee43 100644 --- a/gfx/include/dxsdk/dxfile.h +++ b/gfx/include/dxsdk/dxfile.h @@ -119,7 +119,6 @@ DECLARE_INTERFACE_(IDirectXFileSaveObject, IUnknown) STDMETHOD(SaveData) (THIS_ LPDIRECTXFILEDATA) PURE; }; - #undef INTERFACE #define INTERFACE IDirectXFileObject @@ -193,7 +192,6 @@ DEFINE_GUID(IID_IDirectXFileBinary, 0x3d82ab46, 0x62da, 0x11cf, 0xab, 0x DEFINE_GUID(TID_DXFILEHeader, 0x3d82ab43, 0x62da, 0x11cf, 0xab, 0x39, 0x0, 0x20, 0xaf, 0x71, 0xe4, 0x33); - /* * DirectX File errors. */ @@ -231,7 +229,6 @@ DEFINE_GUID(TID_DXFILEHeader, 0x3d82ab43, 0x62da, 0x11cf, 0xab, 0x39, 0x0, 0x2 #define DXFILEERR_BADCACHEFILE MAKE_DDHRESULT(875) #define DXFILEERR_NOINTERNET MAKE_DDHRESULT(876) - #ifdef __cplusplus }; #endif diff --git a/gfx/include/dxsdk/dxgi.h b/gfx/include/dxsdk/dxgi.h index 06bc6c64ef..9b90bcf9b5 100644 --- a/gfx/include/dxsdk/dxgi.h +++ b/gfx/include/dxsdk/dxgi.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,98 +41,84 @@ typedef interface IDXGIObject IDXGIObject; #endif /* __IDXGIObject_FWD_DEFINED__ */ - #ifndef __IDXGIDeviceSubObject_FWD_DEFINED__ #define __IDXGIDeviceSubObject_FWD_DEFINED__ typedef interface IDXGIDeviceSubObject IDXGIDeviceSubObject; #endif /* __IDXGIDeviceSubObject_FWD_DEFINED__ */ - #ifndef __IDXGIResource_FWD_DEFINED__ #define __IDXGIResource_FWD_DEFINED__ typedef interface IDXGIResource IDXGIResource; #endif /* __IDXGIResource_FWD_DEFINED__ */ - #ifndef __IDXGIKeyedMutex_FWD_DEFINED__ #define __IDXGIKeyedMutex_FWD_DEFINED__ typedef interface IDXGIKeyedMutex IDXGIKeyedMutex; #endif /* __IDXGIKeyedMutex_FWD_DEFINED__ */ - #ifndef __IDXGISurface_FWD_DEFINED__ #define __IDXGISurface_FWD_DEFINED__ typedef interface IDXGISurface IDXGISurface; #endif /* __IDXGISurface_FWD_DEFINED__ */ - #ifndef __IDXGISurface1_FWD_DEFINED__ #define __IDXGISurface1_FWD_DEFINED__ typedef interface IDXGISurface1 IDXGISurface1; #endif /* __IDXGISurface1_FWD_DEFINED__ */ - #ifndef __IDXGIAdapter_FWD_DEFINED__ #define __IDXGIAdapter_FWD_DEFINED__ typedef interface IDXGIAdapter IDXGIAdapter; #endif /* __IDXGIAdapter_FWD_DEFINED__ */ - #ifndef __IDXGIOutput_FWD_DEFINED__ #define __IDXGIOutput_FWD_DEFINED__ typedef interface IDXGIOutput IDXGIOutput; #endif /* __IDXGIOutput_FWD_DEFINED__ */ - #ifndef __IDXGISwapChain_FWD_DEFINED__ #define __IDXGISwapChain_FWD_DEFINED__ typedef interface IDXGISwapChain IDXGISwapChain; #endif /* __IDXGISwapChain_FWD_DEFINED__ */ - #ifndef __IDXGIFactory_FWD_DEFINED__ #define __IDXGIFactory_FWD_DEFINED__ typedef interface IDXGIFactory IDXGIFactory; #endif /* __IDXGIFactory_FWD_DEFINED__ */ - #ifndef __IDXGIDevice_FWD_DEFINED__ #define __IDXGIDevice_FWD_DEFINED__ typedef interface IDXGIDevice IDXGIDevice; #endif /* __IDXGIDevice_FWD_DEFINED__ */ - #ifndef __IDXGIFactory1_FWD_DEFINED__ #define __IDXGIFactory1_FWD_DEFINED__ typedef interface IDXGIFactory1 IDXGIFactory1; #endif /* __IDXGIFactory1_FWD_DEFINED__ */ - #ifndef __IDXGIAdapter1_FWD_DEFINED__ #define __IDXGIAdapter1_FWD_DEFINED__ typedef interface IDXGIAdapter1 IDXGIAdapter1; #endif /* __IDXGIAdapter1_FWD_DEFINED__ */ - #ifndef __IDXGIDevice1_FWD_DEFINED__ #define __IDXGIDevice1_FWD_DEFINED__ typedef interface IDXGIDevice1 IDXGIDevice1; #endif /* __IDXGIDevice1_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -147,7 +129,6 @@ typedef interface IDXGIDevice1 IDXGIDevice1; extern "C"{ #endif - /* interface __MIDL_itf_dxgi_0000_0000 */ /* [local] */ @@ -294,8 +275,6 @@ typedef struct DXGI_SWAP_CHAIN_DESC UINT Flags; } DXGI_SWAP_CHAIN_DESC; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0000_v0_0_s_ifspec; @@ -305,7 +284,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0000_v0_0_s_ifspec; /* interface IDXGIObject */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIObject; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -405,7 +383,6 @@ EXTERN_C const IID IID_IDXGIObject; #ifdef COBJMACROS - #define IDXGIObject_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -415,7 +392,6 @@ EXTERN_C const IID IID_IDXGIObject; #define IDXGIObject_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIObject_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -430,22 +406,16 @@ EXTERN_C const IID IID_IDXGIObject; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIObject_INTERFACE_DEFINED__ */ - #ifndef __IDXGIDeviceSubObject_INTERFACE_DEFINED__ #define __IDXGIDeviceSubObject_INTERFACE_DEFINED__ /* interface IDXGIDeviceSubObject */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDeviceSubObject; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -531,7 +501,6 @@ EXTERN_C const IID IID_IDXGIDeviceSubObject; #ifdef COBJMACROS - #define IDXGIDeviceSubObject_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -541,7 +510,6 @@ EXTERN_C const IID IID_IDXGIDeviceSubObject; #define IDXGIDeviceSubObject_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDeviceSubObject_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -554,28 +522,21 @@ EXTERN_C const IID IID_IDXGIDeviceSubObject; #define IDXGIDeviceSubObject_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDeviceSubObject_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDeviceSubObject_INTERFACE_DEFINED__ */ - #ifndef __IDXGIResource_INTERFACE_DEFINED__ #define __IDXGIResource_INTERFACE_DEFINED__ /* interface IDXGIResource */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIResource; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -687,7 +648,6 @@ EXTERN_C const IID IID_IDXGIResource; #ifdef COBJMACROS - #define IDXGIResource_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -697,7 +657,6 @@ EXTERN_C const IID IID_IDXGIResource; #define IDXGIResource_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIResource_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -710,11 +669,9 @@ EXTERN_C const IID IID_IDXGIResource; #define IDXGIResource_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIResource_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGIResource_GetSharedHandle(This,pSharedHandle) \ ( (This)->lpVtbl -> GetSharedHandle(This,pSharedHandle) ) @@ -729,22 +686,16 @@ EXTERN_C const IID IID_IDXGIResource; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIResource_INTERFACE_DEFINED__ */ - #ifndef __IDXGIKeyedMutex_INTERFACE_DEFINED__ #define __IDXGIKeyedMutex_INTERFACE_DEFINED__ /* interface IDXGIKeyedMutex */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIKeyedMutex; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -840,7 +791,6 @@ EXTERN_C const IID IID_IDXGIKeyedMutex; #ifdef COBJMACROS - #define IDXGIKeyedMutex_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -850,7 +800,6 @@ EXTERN_C const IID IID_IDXGIKeyedMutex; #define IDXGIKeyedMutex_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIKeyedMutex_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -863,11 +812,9 @@ EXTERN_C const IID IID_IDXGIKeyedMutex; #define IDXGIKeyedMutex_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIKeyedMutex_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGIKeyedMutex_AcquireSync(This,Key,dwMilliseconds) \ ( (This)->lpVtbl -> AcquireSync(This,Key,dwMilliseconds) ) @@ -876,15 +823,10 @@ EXTERN_C const IID IID_IDXGIKeyedMutex; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIKeyedMutex_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0004 */ /* [local] */ @@ -894,8 +836,6 @@ EXTERN_C const IID IID_IDXGIKeyedMutex; #define DXGI_MAP_DISCARD ( 4UL ) - - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0004_v0_0_s_ifspec; @@ -905,7 +845,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0004_v0_0_s_ifspec; /* interface IDXGISurface */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISurface; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1010,7 +949,6 @@ EXTERN_C const IID IID_IDXGISurface; #ifdef COBJMACROS - #define IDXGISurface_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1020,7 +958,6 @@ EXTERN_C const IID IID_IDXGISurface; #define IDXGISurface_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISurface_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1033,11 +970,9 @@ EXTERN_C const IID IID_IDXGISurface; #define IDXGISurface_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISurface_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISurface_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -1049,22 +984,16 @@ EXTERN_C const IID IID_IDXGISurface; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISurface_INTERFACE_DEFINED__ */ - #ifndef __IDXGISurface1_INTERFACE_DEFINED__ #define __IDXGISurface1_INTERFACE_DEFINED__ /* interface IDXGISurface1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISurface1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1178,7 +1107,6 @@ EXTERN_C const IID IID_IDXGISurface1; #ifdef COBJMACROS - #define IDXGISurface1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1188,7 +1116,6 @@ EXTERN_C const IID IID_IDXGISurface1; #define IDXGISurface1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISurface1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1201,11 +1128,9 @@ EXTERN_C const IID IID_IDXGISurface1; #define IDXGISurface1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISurface1_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISurface1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -1215,7 +1140,6 @@ EXTERN_C const IID IID_IDXGISurface1; #define IDXGISurface1_Unmap(This) \ ( (This)->lpVtbl -> Unmap(This) ) - #define IDXGISurface1_GetDC(This,Discard,phdc) \ ( (This)->lpVtbl -> GetDC(This,Discard,phdc) ) @@ -1224,21 +1148,13 @@ EXTERN_C const IID IID_IDXGISurface1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISurface1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0006 */ /* [local] */ - - - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0006_v0_0_s_ifspec; @@ -1248,7 +1164,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0006_v0_0_s_ifspec; /* interface IDXGIAdapter */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIAdapter; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1354,7 +1269,6 @@ EXTERN_C const IID IID_IDXGIAdapter; #ifdef COBJMACROS - #define IDXGIAdapter_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1364,7 +1278,6 @@ EXTERN_C const IID IID_IDXGIAdapter; #define IDXGIAdapter_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIAdapter_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1377,7 +1290,6 @@ EXTERN_C const IID IID_IDXGIAdapter; #define IDXGIAdapter_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIAdapter_EnumOutputs(This,Output,ppOutput) \ ( (This)->lpVtbl -> EnumOutputs(This,Output,ppOutput) ) @@ -1389,15 +1301,10 @@ EXTERN_C const IID IID_IDXGIAdapter; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIAdapter_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0007 */ /* [local] */ @@ -1405,8 +1312,6 @@ EXTERN_C const IID IID_IDXGIAdapter; #define DXGI_ENUM_MODES_SCALING ( 2UL ) - - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0007_v0_0_s_ifspec; @@ -1416,7 +1321,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0007_v0_0_s_ifspec; /* interface IDXGIOutput */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1607,7 +1511,6 @@ EXTERN_C const IID IID_IDXGIOutput; #ifdef COBJMACROS - #define IDXGIOutput_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1617,7 +1520,6 @@ EXTERN_C const IID IID_IDXGIOutput; #define IDXGIOutput_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1630,7 +1532,6 @@ EXTERN_C const IID IID_IDXGIOutput; #define IDXGIOutput_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -1669,15 +1570,10 @@ EXTERN_C const IID IID_IDXGIOutput; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0008 */ /* [local] */ @@ -1692,7 +1588,6 @@ EXTERN_C const IID IID_IDXGIOutput; #define DXGI_PRESENT_USE_DURATION 0x00000100UL #define DXGI_PRESENT_ALLOW_TEARING 0x00000200UL - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0008_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0008_v0_0_s_ifspec; @@ -1702,7 +1597,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0008_v0_0_s_ifspec; /* interface IDXGISwapChain */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChain; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1890,7 +1784,6 @@ EXTERN_C const IID IID_IDXGISwapChain; #ifdef COBJMACROS - #define IDXGISwapChain_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1900,7 +1793,6 @@ EXTERN_C const IID IID_IDXGISwapChain; #define IDXGISwapChain_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChain_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1913,11 +1805,9 @@ EXTERN_C const IID IID_IDXGISwapChain; #define IDXGISwapChain_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISwapChain_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISwapChain_Present(This,SyncInterval,Flags) \ ( (This)->lpVtbl -> Present(This,SyncInterval,Flags) ) @@ -1950,15 +1840,10 @@ EXTERN_C const IID IID_IDXGISwapChain; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChain_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0009 */ /* [local] */ @@ -1967,7 +1852,6 @@ EXTERN_C const IID IID_IDXGISwapChain; #define DXGI_MWA_NO_PRINT_SCREEN ( 1 << 2 ) #define DXGI_MWA_VALID ( 0x7 ) - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0009_v0_0_s_ifspec; @@ -1977,7 +1861,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0009_v0_0_s_ifspec; /* interface IDXGIFactory */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2107,7 +1990,6 @@ EXTERN_C const IID IID_IDXGIFactory; #ifdef COBJMACROS - #define IDXGIFactory_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2117,7 +1999,6 @@ EXTERN_C const IID IID_IDXGIFactory; #define IDXGIFactory_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2130,7 +2011,6 @@ EXTERN_C const IID IID_IDXGIFactory; #define IDXGIFactory_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -2148,15 +2028,10 @@ EXTERN_C const IID IID_IDXGIFactory; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0010 */ /* [local] */ @@ -2167,7 +2042,6 @@ HRESULT WINAPI CreateDXGIFactory(REFIID riid, _COM_Outptr_ void **ppFactory); /*#pragma endregion*/ HRESULT WINAPI CreateDXGIFactory1(REFIID riid, _COM_Outptr_ void **ppFactory); - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0010_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0010_v0_0_s_ifspec; @@ -2177,7 +2051,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0010_v0_0_s_ifspec; /* interface IDXGIDevice */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDevice; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2311,7 +2184,6 @@ EXTERN_C const IID IID_IDXGIDevice; #ifdef COBJMACROS - #define IDXGIDevice_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2321,7 +2193,6 @@ EXTERN_C const IID IID_IDXGIDevice; #define IDXGIDevice_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDevice_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2334,7 +2205,6 @@ EXTERN_C const IID IID_IDXGIDevice; #define IDXGIDevice_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDevice_GetAdapter(This,pAdapter) \ ( (This)->lpVtbl -> GetAdapter(This,pAdapter) ) @@ -2352,15 +2222,10 @@ EXTERN_C const IID IID_IDXGIDevice; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDevice_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0011 */ /* [local] */ @@ -2393,9 +2258,6 @@ typedef struct DXGI_DISPLAY_COLOR_SPACE FLOAT WhitePoints[ 16 ][ 2 ]; } DXGI_DISPLAY_COLOR_SPACE; - - - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0011_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0011_v0_0_s_ifspec; @@ -2405,7 +2267,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0011_v0_0_s_ifspec; /* interface IDXGIFactory1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2525,7 +2386,6 @@ EXTERN_C const IID IID_IDXGIFactory1; #ifdef COBJMACROS - #define IDXGIFactory1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2535,7 +2395,6 @@ EXTERN_C const IID IID_IDXGIFactory1; #define IDXGIFactory1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2548,7 +2407,6 @@ EXTERN_C const IID IID_IDXGIFactory1; #define IDXGIFactory1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory1_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -2564,7 +2422,6 @@ EXTERN_C const IID IID_IDXGIFactory1; #define IDXGIFactory1_CreateSoftwareAdapter(This,Module,ppAdapter) \ ( (This)->lpVtbl -> CreateSoftwareAdapter(This,Module,ppAdapter) ) - #define IDXGIFactory1_EnumAdapters1(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters1(This,Adapter,ppAdapter) ) @@ -2573,22 +2430,16 @@ EXTERN_C const IID IID_IDXGIFactory1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory1_INTERFACE_DEFINED__ */ - #ifndef __IDXGIAdapter1_INTERFACE_DEFINED__ #define __IDXGIAdapter1_INTERFACE_DEFINED__ /* interface IDXGIAdapter1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIAdapter1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2688,7 +2539,6 @@ EXTERN_C const IID IID_IDXGIAdapter1; #ifdef COBJMACROS - #define IDXGIAdapter1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2698,7 +2548,6 @@ EXTERN_C const IID IID_IDXGIAdapter1; #define IDXGIAdapter1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIAdapter1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2711,7 +2560,6 @@ EXTERN_C const IID IID_IDXGIAdapter1; #define IDXGIAdapter1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIAdapter1_EnumOutputs(This,Output,ppOutput) \ ( (This)->lpVtbl -> EnumOutputs(This,Output,ppOutput) ) @@ -2721,28 +2569,21 @@ EXTERN_C const IID IID_IDXGIAdapter1; #define IDXGIAdapter1_CheckInterfaceSupport(This,InterfaceName,pUMDVersion) \ ( (This)->lpVtbl -> CheckInterfaceSupport(This,InterfaceName,pUMDVersion) ) - #define IDXGIAdapter1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIAdapter1_INTERFACE_DEFINED__ */ - #ifndef __IDXGIDevice1_INTERFACE_DEFINED__ #define __IDXGIDevice1_INTERFACE_DEFINED__ /* interface IDXGIDevice1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDevice1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2864,7 +2705,6 @@ EXTERN_C const IID IID_IDXGIDevice1; #ifdef COBJMACROS - #define IDXGIDevice1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2874,7 +2714,6 @@ EXTERN_C const IID IID_IDXGIDevice1; #define IDXGIDevice1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDevice1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2887,7 +2726,6 @@ EXTERN_C const IID IID_IDXGIDevice1; #define IDXGIDevice1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDevice1_GetAdapter(This,pAdapter) \ ( (This)->lpVtbl -> GetAdapter(This,pAdapter) ) @@ -2903,7 +2741,6 @@ EXTERN_C const IID IID_IDXGIDevice1; #define IDXGIDevice1_GetGPUThreadPriority(This,pPriority) \ ( (This)->lpVtbl -> GetGPUThreadPriority(This,pPriority) ) - #define IDXGIDevice1_SetMaximumFrameLatency(This,MaxLatency) \ ( (This)->lpVtbl -> SetMaximumFrameLatency(This,MaxLatency) ) @@ -2912,15 +2749,10 @@ EXTERN_C const IID IID_IDXGIDevice1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDevice1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi_0000_0014 */ /* [local] */ @@ -2941,7 +2773,6 @@ DEFINE_GUID(IID_IDXGIFactory1,0x770aae78,0xf26f,0x4dba,0xa8,0x29,0x25,0x3c,0x83, DEFINE_GUID(IID_IDXGIAdapter1,0x29038f61,0x3839,0x4626,0x91,0xfd,0x08,0x68,0x79,0x01,0x1a,0x05); DEFINE_GUID(IID_IDXGIDevice1,0x77db970f,0x6276,0x48ba,0xba,0x28,0x07,0x01,0x43,0xb4,0x39,0x2c); - extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0014_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0014_v0_0_s_ifspec; @@ -2955,4 +2786,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi_0000_0014_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgi1_2.h b/gfx/include/dxsdk/dxgi1_2.h index 84e231bd82..4b1dfa961b 100644 --- a/gfx/include/dxsdk/dxgi1_2.h +++ b/gfx/include/dxsdk/dxgi1_2.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,63 +41,54 @@ typedef interface IDXGIDisplayControl IDXGIDisplayControl; #endif /* __IDXGIDisplayControl_FWD_DEFINED__ */ - #ifndef __IDXGIOutputDuplication_FWD_DEFINED__ #define __IDXGIOutputDuplication_FWD_DEFINED__ typedef interface IDXGIOutputDuplication IDXGIOutputDuplication; #endif /* __IDXGIOutputDuplication_FWD_DEFINED__ */ - #ifndef __IDXGISurface2_FWD_DEFINED__ #define __IDXGISurface2_FWD_DEFINED__ typedef interface IDXGISurface2 IDXGISurface2; #endif /* __IDXGISurface2_FWD_DEFINED__ */ - #ifndef __IDXGIResource1_FWD_DEFINED__ #define __IDXGIResource1_FWD_DEFINED__ typedef interface IDXGIResource1 IDXGIResource1; #endif /* __IDXGIResource1_FWD_DEFINED__ */ - #ifndef __IDXGIDevice2_FWD_DEFINED__ #define __IDXGIDevice2_FWD_DEFINED__ typedef interface IDXGIDevice2 IDXGIDevice2; #endif /* __IDXGIDevice2_FWD_DEFINED__ */ - #ifndef __IDXGISwapChain1_FWD_DEFINED__ #define __IDXGISwapChain1_FWD_DEFINED__ typedef interface IDXGISwapChain1 IDXGISwapChain1; #endif /* __IDXGISwapChain1_FWD_DEFINED__ */ - #ifndef __IDXGIFactory2_FWD_DEFINED__ #define __IDXGIFactory2_FWD_DEFINED__ typedef interface IDXGIFactory2 IDXGIFactory2; #endif /* __IDXGIFactory2_FWD_DEFINED__ */ - #ifndef __IDXGIAdapter2_FWD_DEFINED__ #define __IDXGIAdapter2_FWD_DEFINED__ typedef interface IDXGIAdapter2 IDXGIAdapter2; #endif /* __IDXGIAdapter2_FWD_DEFINED__ */ - #ifndef __IDXGIOutput1_FWD_DEFINED__ #define __IDXGIOutput1_FWD_DEFINED__ typedef interface IDXGIOutput1 IDXGIOutput1; #endif /* __IDXGIOutput1_FWD_DEFINED__ */ - /* header files for imported files */ #include "dxgi.h" @@ -109,7 +96,6 @@ typedef interface IDXGIOutput1 IDXGIOutput1; extern "C"{ #endif - /* interface __MIDL_itf_dxgi1_2_0000_0000 */ /* [local] */ @@ -117,7 +103,6 @@ extern "C"{ /*#pragma region Desktop Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)*/ - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0000_v0_0_s_ifspec; @@ -127,7 +112,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0000_v0_0_s_ifspec; /* interface IDXGIDisplayControl */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDisplayControl; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -181,7 +165,6 @@ EXTERN_C const IID IID_IDXGIDisplayControl; #ifdef COBJMACROS - #define IDXGIDisplayControl_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -191,7 +174,6 @@ EXTERN_C const IID IID_IDXGIDisplayControl; #define IDXGIDisplayControl_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDisplayControl_IsStereoEnabled(This) \ ( (This)->lpVtbl -> IsStereoEnabled(This) ) @@ -200,15 +182,10 @@ EXTERN_C const IID IID_IDXGIDisplayControl; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDisplayControl_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0001 */ /* [local] */ @@ -260,8 +237,6 @@ typedef struct DXGI_OUTDUPL_FRAME_INFO UINT PointerShapeBufferSize; } DXGI_OUTDUPL_FRAME_INFO; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0001_v0_0_s_ifspec; @@ -271,7 +246,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0001_v0_0_s_ifspec; /* interface IDXGIOutputDuplication */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutputDuplication; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -444,7 +418,6 @@ EXTERN_C const IID IID_IDXGIOutputDuplication; #ifdef COBJMACROS - #define IDXGIOutputDuplication_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -454,7 +427,6 @@ EXTERN_C const IID IID_IDXGIOutputDuplication; #define IDXGIOutputDuplication_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutputDuplication_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -467,7 +439,6 @@ EXTERN_C const IID IID_IDXGIOutputDuplication; #define IDXGIOutputDuplication_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutputDuplication_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -494,15 +465,10 @@ EXTERN_C const IID IID_IDXGIOutputDuplication; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutputDuplication_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0002 */ /* [local] */ @@ -520,8 +486,6 @@ enum DXGI_ALPHA_MODE DXGI_ALPHA_MODE_FORCE_DWORD = 0xffffffff } DXGI_ALPHA_MODE; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0002_v0_0_s_ifspec; @@ -531,7 +495,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0002_v0_0_s_ifspec; /* interface IDXGISurface2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISurface2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -653,7 +616,6 @@ EXTERN_C const IID IID_IDXGISurface2; #ifdef COBJMACROS - #define IDXGISurface2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -663,7 +625,6 @@ EXTERN_C const IID IID_IDXGISurface2; #define IDXGISurface2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISurface2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -676,11 +637,9 @@ EXTERN_C const IID IID_IDXGISurface2; #define IDXGISurface2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISurface2_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISurface2_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -690,35 +649,27 @@ EXTERN_C const IID IID_IDXGISurface2; #define IDXGISurface2_Unmap(This) \ ( (This)->lpVtbl -> Unmap(This) ) - #define IDXGISurface2_GetDC(This,Discard,phdc) \ ( (This)->lpVtbl -> GetDC(This,Discard,phdc) ) #define IDXGISurface2_ReleaseDC(This,pDirtyRect) \ ( (This)->lpVtbl -> ReleaseDC(This,pDirtyRect) ) - #define IDXGISurface2_GetResource(This,riid,ppParentResource,pSubresourceIndex) \ ( (This)->lpVtbl -> GetResource(This,riid,ppParentResource,pSubresourceIndex) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISurface2_INTERFACE_DEFINED__ */ - #ifndef __IDXGIResource1_INTERFACE_DEFINED__ #define __IDXGIResource1_INTERFACE_DEFINED__ /* interface IDXGIResource1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIResource1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -848,7 +799,6 @@ EXTERN_C const IID IID_IDXGIResource1; #ifdef COBJMACROS - #define IDXGIResource1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -858,7 +808,6 @@ EXTERN_C const IID IID_IDXGIResource1; #define IDXGIResource1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIResource1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -871,11 +820,9 @@ EXTERN_C const IID IID_IDXGIResource1; #define IDXGIResource1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIResource1_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGIResource1_GetSharedHandle(This,pSharedHandle) \ ( (This)->lpVtbl -> GetSharedHandle(This,pSharedHandle) ) @@ -888,7 +835,6 @@ EXTERN_C const IID IID_IDXGIResource1; #define IDXGIResource1_GetEvictionPriority(This,pEvictionPriority) \ ( (This)->lpVtbl -> GetEvictionPriority(This,pEvictionPriority) ) - #define IDXGIResource1_CreateSubresourceSurface(This,index,ppSurface) \ ( (This)->lpVtbl -> CreateSubresourceSurface(This,index,ppSurface) ) @@ -897,15 +843,10 @@ EXTERN_C const IID IID_IDXGIResource1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIResource1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0004 */ /* [local] */ @@ -917,8 +858,6 @@ enum _DXGI_OFFER_RESOURCE_PRIORITY DXGI_OFFER_RESOURCE_PRIORITY_HIGH = ( DXGI_OFFER_RESOURCE_PRIORITY_NORMAL + 1 ) } DXGI_OFFER_RESOURCE_PRIORITY; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0004_v0_0_s_ifspec; @@ -928,7 +867,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0004_v0_0_s_ifspec; /* interface IDXGIDevice2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDevice2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1086,7 +1024,6 @@ EXTERN_C const IID IID_IDXGIDevice2; #ifdef COBJMACROS - #define IDXGIDevice2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1096,7 +1033,6 @@ EXTERN_C const IID IID_IDXGIDevice2; #define IDXGIDevice2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDevice2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1109,7 +1045,6 @@ EXTERN_C const IID IID_IDXGIDevice2; #define IDXGIDevice2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDevice2_GetAdapter(This,pAdapter) \ ( (This)->lpVtbl -> GetAdapter(This,pAdapter) ) @@ -1125,14 +1060,12 @@ EXTERN_C const IID IID_IDXGIDevice2; #define IDXGIDevice2_GetGPUThreadPriority(This,pPriority) \ ( (This)->lpVtbl -> GetGPUThreadPriority(This,pPriority) ) - #define IDXGIDevice2_SetMaximumFrameLatency(This,MaxLatency) \ ( (This)->lpVtbl -> SetMaximumFrameLatency(This,MaxLatency) ) #define IDXGIDevice2_GetMaximumFrameLatency(This,pMaxLatency) \ ( (This)->lpVtbl -> GetMaximumFrameLatency(This,pMaxLatency) ) - #define IDXGIDevice2_OfferResources(This,NumResources,ppResources,Priority) \ ( (This)->lpVtbl -> OfferResources(This,NumResources,ppResources,Priority) ) @@ -1144,15 +1077,10 @@ EXTERN_C const IID IID_IDXGIDevice2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDevice2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0005 */ /* [local] */ @@ -1215,8 +1143,6 @@ typedef struct DXGI_PRESENT_PARAMETERS POINT *pScrollOffset; } DXGI_PRESENT_PARAMETERS; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0005_v0_0_s_ifspec; @@ -1226,7 +1152,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0005_v0_0_s_ifspec; /* interface IDXGISwapChain1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChain1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1468,7 +1393,6 @@ EXTERN_C const IID IID_IDXGISwapChain1; #ifdef COBJMACROS - #define IDXGISwapChain1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1478,7 +1402,6 @@ EXTERN_C const IID IID_IDXGISwapChain1; #define IDXGISwapChain1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChain1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1491,11 +1414,9 @@ EXTERN_C const IID IID_IDXGISwapChain1; #define IDXGISwapChain1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISwapChain1_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISwapChain1_Present(This,SyncInterval,Flags) \ ( (This)->lpVtbl -> Present(This,SyncInterval,Flags) ) @@ -1526,7 +1447,6 @@ EXTERN_C const IID IID_IDXGISwapChain1; #define IDXGISwapChain1_GetLastPresentCount(This,pLastPresentCount) \ ( (This)->lpVtbl -> GetLastPresentCount(This,pLastPresentCount) ) - #define IDXGISwapChain1_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) @@ -1562,22 +1482,16 @@ EXTERN_C const IID IID_IDXGISwapChain1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChain1_INTERFACE_DEFINED__ */ - #ifndef __IDXGIFactory2_INTERFACE_DEFINED__ #define __IDXGIFactory2_INTERFACE_DEFINED__ /* interface IDXGIFactory2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1861,7 +1775,6 @@ EXTERN_C const IID IID_IDXGIFactory2; #ifdef COBJMACROS - #define IDXGIFactory2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1871,7 +1784,6 @@ EXTERN_C const IID IID_IDXGIFactory2; #define IDXGIFactory2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1884,7 +1796,6 @@ EXTERN_C const IID IID_IDXGIFactory2; #define IDXGIFactory2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory2_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -1900,14 +1811,12 @@ EXTERN_C const IID IID_IDXGIFactory2; #define IDXGIFactory2_CreateSoftwareAdapter(This,Module,ppAdapter) \ ( (This)->lpVtbl -> CreateSoftwareAdapter(This,Module,ppAdapter) ) - #define IDXGIFactory2_EnumAdapters1(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters1(This,Adapter,ppAdapter) ) #define IDXGIFactory2_IsCurrent(This) \ ( (This)->lpVtbl -> IsCurrent(This) ) - #define IDXGIFactory2_IsWindowedStereoEnabled(This) \ ( (This)->lpVtbl -> IsWindowedStereoEnabled(This) ) @@ -1943,15 +1852,10 @@ EXTERN_C const IID IID_IDXGIFactory2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory2_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0007 */ /* [local] */ @@ -1991,8 +1895,6 @@ typedef struct DXGI_ADAPTER_DESC2 DXGI_COMPUTE_PREEMPTION_GRANULARITY ComputePreemptionGranularity; } DXGI_ADAPTER_DESC2; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0007_v0_0_s_ifspec; @@ -2002,7 +1904,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0007_v0_0_s_ifspec; /* interface IDXGIAdapter2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIAdapter2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2107,7 +2008,6 @@ EXTERN_C const IID IID_IDXGIAdapter2; #ifdef COBJMACROS - #define IDXGIAdapter2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2117,7 +2017,6 @@ EXTERN_C const IID IID_IDXGIAdapter2; #define IDXGIAdapter2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIAdapter2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2130,7 +2029,6 @@ EXTERN_C const IID IID_IDXGIAdapter2; #define IDXGIAdapter2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIAdapter2_EnumOutputs(This,Output,ppOutput) \ ( (This)->lpVtbl -> EnumOutputs(This,Output,ppOutput) ) @@ -2140,32 +2038,24 @@ EXTERN_C const IID IID_IDXGIAdapter2; #define IDXGIAdapter2_CheckInterfaceSupport(This,InterfaceName,pUMDVersion) \ ( (This)->lpVtbl -> CheckInterfaceSupport(This,InterfaceName,pUMDVersion) ) - #define IDXGIAdapter2_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) - #define IDXGIAdapter2_GetDesc2(This,pDesc) \ ( (This)->lpVtbl -> GetDesc2(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIAdapter2_INTERFACE_DEFINED__ */ - #ifndef __IDXGIOutput1_INTERFACE_DEFINED__ #define __IDXGIOutput1_INTERFACE_DEFINED__ /* interface IDXGIOutput1 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -2359,7 +2249,6 @@ EXTERN_C const IID IID_IDXGIOutput1; #ifdef COBJMACROS - #define IDXGIOutput1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2369,7 +2258,6 @@ EXTERN_C const IID IID_IDXGIOutput1; #define IDXGIOutput1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput1_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2382,7 +2270,6 @@ EXTERN_C const IID IID_IDXGIOutput1; #define IDXGIOutput1_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput1_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -2419,7 +2306,6 @@ EXTERN_C const IID IID_IDXGIOutput1; #define IDXGIOutput1_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput1_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -2434,15 +2320,10 @@ EXTERN_C const IID IID_IDXGIOutput1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_2_0000_0009 */ /* [local] */ @@ -2458,7 +2339,6 @@ DEFINE_GUID(IID_IDXGIFactory2,0x50c83a1c,0xe072,0x4c48,0x87,0xb0,0x36,0x30,0xfa, DEFINE_GUID(IID_IDXGIAdapter2,0x0AA1AE0A,0xFA0E,0x4B84,0x86,0x44,0xE0,0x5F,0xF8,0xE5,0xAC,0xB5); DEFINE_GUID(IID_IDXGIOutput1,0x00cddea8,0x939b,0x4b83,0xa3,0x40,0xa6,0x85,0x22,0x66,0x66,0xcc); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0009_v0_0_s_ifspec; @@ -2472,4 +2352,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_2_0000_0009_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgi1_3.h b/gfx/include/dxsdk/dxgi1_3.h index 839c05ca46..6e2cf39326 100644 --- a/gfx/include/dxsdk/dxgi1_3.h +++ b/gfx/include/dxsdk/dxgi1_3.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,56 +41,48 @@ typedef interface IDXGIDevice3 IDXGIDevice3; #endif /* __IDXGIDevice3_FWD_DEFINED__ */ - #ifndef __IDXGISwapChain2_FWD_DEFINED__ #define __IDXGISwapChain2_FWD_DEFINED__ typedef interface IDXGISwapChain2 IDXGISwapChain2; #endif /* __IDXGISwapChain2_FWD_DEFINED__ */ - #ifndef __IDXGIOutput2_FWD_DEFINED__ #define __IDXGIOutput2_FWD_DEFINED__ typedef interface IDXGIOutput2 IDXGIOutput2; #endif /* __IDXGIOutput2_FWD_DEFINED__ */ - #ifndef __IDXGIFactory3_FWD_DEFINED__ #define __IDXGIFactory3_FWD_DEFINED__ typedef interface IDXGIFactory3 IDXGIFactory3; #endif /* __IDXGIFactory3_FWD_DEFINED__ */ - #ifndef __IDXGIDecodeSwapChain_FWD_DEFINED__ #define __IDXGIDecodeSwapChain_FWD_DEFINED__ typedef interface IDXGIDecodeSwapChain IDXGIDecodeSwapChain; #endif /* __IDXGIDecodeSwapChain_FWD_DEFINED__ */ - #ifndef __IDXGIFactoryMedia_FWD_DEFINED__ #define __IDXGIFactoryMedia_FWD_DEFINED__ typedef interface IDXGIFactoryMedia IDXGIFactoryMedia; #endif /* __IDXGIFactoryMedia_FWD_DEFINED__ */ - #ifndef __IDXGISwapChainMedia_FWD_DEFINED__ #define __IDXGISwapChainMedia_FWD_DEFINED__ typedef interface IDXGISwapChainMedia IDXGISwapChainMedia; #endif /* __IDXGISwapChainMedia_FWD_DEFINED__ */ - #ifndef __IDXGIOutput3_FWD_DEFINED__ #define __IDXGIOutput3_FWD_DEFINED__ typedef interface IDXGIOutput3 IDXGIOutput3; #endif /* __IDXGIOutput3_FWD_DEFINED__ */ - /* header files for imported files */ #include "dxgi1_2.h" @@ -102,7 +90,6 @@ typedef interface IDXGIOutput3 IDXGIOutput3; extern "C"{ #endif - /* interface __MIDL_itf_dxgi1_3_0000_0000 */ /* [local] */ @@ -113,7 +100,6 @@ extern "C"{ HRESULT WINAPI CreateDXGIFactory2(UINT Flags, REFIID riid, _COM_Outptr_ void **ppFactory); HRESULT WINAPI DXGIGetDebugInterface1(UINT Flags, REFIID riid, _COM_Outptr_ void **pDebug); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0000_v0_0_s_ifspec; @@ -123,7 +109,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0000_v0_0_s_ifspec; /* interface IDXGIDevice3 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDevice3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -266,7 +251,6 @@ EXTERN_C const IID IID_IDXGIDevice3; #ifdef COBJMACROS - #define IDXGIDevice3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -276,7 +260,6 @@ EXTERN_C const IID IID_IDXGIDevice3; #define IDXGIDevice3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDevice3_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -289,7 +272,6 @@ EXTERN_C const IID IID_IDXGIDevice3; #define IDXGIDevice3_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDevice3_GetAdapter(This,pAdapter) \ ( (This)->lpVtbl -> GetAdapter(This,pAdapter) ) @@ -305,14 +287,12 @@ EXTERN_C const IID IID_IDXGIDevice3; #define IDXGIDevice3_GetGPUThreadPriority(This,pPriority) \ ( (This)->lpVtbl -> GetGPUThreadPriority(This,pPriority) ) - #define IDXGIDevice3_SetMaximumFrameLatency(This,MaxLatency) \ ( (This)->lpVtbl -> SetMaximumFrameLatency(This,MaxLatency) ) #define IDXGIDevice3_GetMaximumFrameLatency(This,pMaxLatency) \ ( (This)->lpVtbl -> GetMaximumFrameLatency(This,pMaxLatency) ) - #define IDXGIDevice3_OfferResources(This,NumResources,ppResources,Priority) \ ( (This)->lpVtbl -> OfferResources(This,NumResources,ppResources,Priority) ) @@ -322,21 +302,15 @@ EXTERN_C const IID IID_IDXGIDevice3; #define IDXGIDevice3_EnqueueSetEvent(This,hEvent) \ ( (This)->lpVtbl -> EnqueueSetEvent(This,hEvent) ) - #define IDXGIDevice3_Trim(This) \ ( (This)->lpVtbl -> Trim(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDevice3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_3_0000_0001 */ /* [local] */ @@ -350,8 +324,6 @@ typedef struct DXGI_MATRIX_3X2_F FLOAT _32; } DXGI_MATRIX_3X2_F; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0001_v0_0_s_ifspec; @@ -361,7 +333,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0001_v0_0_s_ifspec; /* interface IDXGISwapChain2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChain2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -616,7 +587,6 @@ EXTERN_C const IID IID_IDXGISwapChain2; #ifdef COBJMACROS - #define IDXGISwapChain2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -626,7 +596,6 @@ EXTERN_C const IID IID_IDXGISwapChain2; #define IDXGISwapChain2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChain2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -639,11 +608,9 @@ EXTERN_C const IID IID_IDXGISwapChain2; #define IDXGISwapChain2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISwapChain2_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISwapChain2_Present(This,SyncInterval,Flags) \ ( (This)->lpVtbl -> Present(This,SyncInterval,Flags) ) @@ -674,7 +641,6 @@ EXTERN_C const IID IID_IDXGISwapChain2; #define IDXGISwapChain2_GetLastPresentCount(This,pLastPresentCount) \ ( (This)->lpVtbl -> GetLastPresentCount(This,pLastPresentCount) ) - #define IDXGISwapChain2_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) @@ -708,7 +674,6 @@ EXTERN_C const IID IID_IDXGISwapChain2; #define IDXGISwapChain2_GetRotation(This,pRotation) \ ( (This)->lpVtbl -> GetRotation(This,pRotation) ) - #define IDXGISwapChain2_SetSourceSize(This,Width,Height) \ ( (This)->lpVtbl -> SetSourceSize(This,Width,Height) ) @@ -732,22 +697,16 @@ EXTERN_C const IID IID_IDXGISwapChain2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChain2_INTERFACE_DEFINED__ */ - #ifndef __IDXGIOutput2_INTERFACE_DEFINED__ #define __IDXGIOutput2_INTERFACE_DEFINED__ /* interface IDXGIOutput2 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -920,7 +879,6 @@ EXTERN_C const IID IID_IDXGIOutput2; #ifdef COBJMACROS - #define IDXGIOutput2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -930,7 +888,6 @@ EXTERN_C const IID IID_IDXGIOutput2; #define IDXGIOutput2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput2_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -943,7 +900,6 @@ EXTERN_C const IID IID_IDXGIOutput2; #define IDXGIOutput2_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput2_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -980,7 +936,6 @@ EXTERN_C const IID IID_IDXGIOutput2; #define IDXGIOutput2_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput2_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -993,28 +948,21 @@ EXTERN_C const IID IID_IDXGIOutput2; #define IDXGIOutput2_DuplicateOutput(This,pDevice,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput(This,pDevice,ppOutputDuplication) ) - #define IDXGIOutput2_SupportsOverlays(This) \ ( (This)->lpVtbl -> SupportsOverlays(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput2_INTERFACE_DEFINED__ */ - #ifndef __IDXGIFactory3_INTERFACE_DEFINED__ #define __IDXGIFactory3_INTERFACE_DEFINED__ /* interface IDXGIFactory3 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1223,7 +1171,6 @@ EXTERN_C const IID IID_IDXGIFactory3; #ifdef COBJMACROS - #define IDXGIFactory3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1233,7 +1180,6 @@ EXTERN_C const IID IID_IDXGIFactory3; #define IDXGIFactory3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory3_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1246,7 +1192,6 @@ EXTERN_C const IID IID_IDXGIFactory3; #define IDXGIFactory3_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory3_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -1262,14 +1207,12 @@ EXTERN_C const IID IID_IDXGIFactory3; #define IDXGIFactory3_CreateSoftwareAdapter(This,Module,ppAdapter) \ ( (This)->lpVtbl -> CreateSoftwareAdapter(This,Module,ppAdapter) ) - #define IDXGIFactory3_EnumAdapters1(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters1(This,Adapter,ppAdapter) ) #define IDXGIFactory3_IsCurrent(This) \ ( (This)->lpVtbl -> IsCurrent(This) ) - #define IDXGIFactory3_IsWindowedStereoEnabled(This) \ ( (This)->lpVtbl -> IsWindowedStereoEnabled(This) ) @@ -1303,21 +1246,15 @@ EXTERN_C const IID IID_IDXGIFactory3; #define IDXGIFactory3_CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) \ ( (This)->lpVtbl -> CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) ) - #define IDXGIFactory3_GetCreationFlags(This) \ ( (This)->lpVtbl -> GetCreationFlags(This) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_3_0000_0004 */ /* [local] */ @@ -1338,8 +1275,6 @@ enum DXGI_MULTIPLANE_OVERLAY_YCbCr_FLAGS DXGI_MULTIPLANE_OVERLAY_YCbCr_FLAG_xvYCC = 0x4 } DXGI_MULTIPLANE_OVERLAY_YCbCr_FLAGS; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0004_v0_0_s_ifspec; @@ -1349,7 +1284,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0004_v0_0_s_ifspec; /* interface IDXGIDecodeSwapChain */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDecodeSwapChain; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1468,7 +1402,6 @@ EXTERN_C const IID IID_IDXGIDecodeSwapChain; #ifdef COBJMACROS - #define IDXGIDecodeSwapChain_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1478,7 +1411,6 @@ EXTERN_C const IID IID_IDXGIDecodeSwapChain; #define IDXGIDecodeSwapChain_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDecodeSwapChain_PresentBuffer(This,BufferToPresent,SyncInterval,Flags) \ ( (This)->lpVtbl -> PresentBuffer(This,BufferToPresent,SyncInterval,Flags) ) @@ -1508,22 +1440,16 @@ EXTERN_C const IID IID_IDXGIDecodeSwapChain; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDecodeSwapChain_INTERFACE_DEFINED__ */ - #ifndef __IDXGIFactoryMedia_INTERFACE_DEFINED__ #define __IDXGIFactoryMedia_INTERFACE_DEFINED__ /* interface IDXGIFactoryMedia */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactoryMedia; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1619,7 +1545,6 @@ EXTERN_C const IID IID_IDXGIFactoryMedia; #ifdef COBJMACROS - #define IDXGIFactoryMedia_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1629,7 +1554,6 @@ EXTERN_C const IID IID_IDXGIFactoryMedia; #define IDXGIFactoryMedia_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactoryMedia_CreateSwapChainForCompositionSurfaceHandle(This,pDevice,hSurface,pDesc,pRestrictToOutput,ppSwapChain) \ ( (This)->lpVtbl -> CreateSwapChainForCompositionSurfaceHandle(This,pDevice,hSurface,pDesc,pRestrictToOutput,ppSwapChain) ) @@ -1638,15 +1562,10 @@ EXTERN_C const IID IID_IDXGIFactoryMedia; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactoryMedia_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_3_0000_0006 */ /* [local] */ @@ -1670,8 +1589,6 @@ typedef struct DXGI_FRAME_STATISTICS_MEDIA UINT ApprovedPresentDuration; } DXGI_FRAME_STATISTICS_MEDIA; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0006_v0_0_s_ifspec; @@ -1681,7 +1598,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0006_v0_0_s_ifspec; /* interface IDXGISwapChainMedia */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChainMedia; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1754,7 +1670,6 @@ EXTERN_C const IID IID_IDXGISwapChainMedia; #ifdef COBJMACROS - #define IDXGISwapChainMedia_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1764,7 +1679,6 @@ EXTERN_C const IID IID_IDXGISwapChainMedia; #define IDXGISwapChainMedia_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChainMedia_GetFrameStatisticsMedia(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatisticsMedia(This,pStats) ) @@ -1776,15 +1690,10 @@ EXTERN_C const IID IID_IDXGISwapChainMedia; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChainMedia_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_3_0000_0007 */ /* [local] */ @@ -1800,7 +1709,6 @@ enum DXGI_OVERLAY_SUPPORT_FLAG /*#pragma region App Family*/ /*#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)*/ - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0007_v0_0_s_ifspec; @@ -1810,7 +1718,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0007_v0_0_s_ifspec; /* interface IDXGIOutput3 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1998,7 +1905,6 @@ EXTERN_C const IID IID_IDXGIOutput3; #ifdef COBJMACROS - #define IDXGIOutput3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -2008,7 +1914,6 @@ EXTERN_C const IID IID_IDXGIOutput3; #define IDXGIOutput3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput3_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -2021,7 +1926,6 @@ EXTERN_C const IID IID_IDXGIOutput3; #define IDXGIOutput3_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput3_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -2058,7 +1962,6 @@ EXTERN_C const IID IID_IDXGIOutput3; #define IDXGIOutput3_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput3_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -2071,25 +1974,18 @@ EXTERN_C const IID IID_IDXGIOutput3; #define IDXGIOutput3_DuplicateOutput(This,pDevice,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput(This,pDevice,ppOutputDuplication) ) - #define IDXGIOutput3_SupportsOverlays(This) \ ( (This)->lpVtbl -> SupportsOverlays(This) ) - #define IDXGIOutput3_CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_3_0000_0008 */ /* [local] */ @@ -2104,7 +2000,6 @@ DEFINE_GUID(IID_IDXGIFactoryMedia,0x41e7d1f2,0xa591,0x4f7b,0xa2,0xe5,0xfa,0x9c,0 DEFINE_GUID(IID_IDXGISwapChainMedia,0xdd95b90b,0xf05f,0x4f6a,0xbd,0x65,0x25,0xbf,0xb2,0x64,0xbd,0x84); DEFINE_GUID(IID_IDXGIOutput3,0x8a6bb301,0x7e7e,0x41F4,0xa8,0xe0,0x5b,0x32,0xf7,0xf9,0x9b,0x18); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0008_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0008_v0_0_s_ifspec; @@ -2118,4 +2013,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_3_0000_0008_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgi1_4.h b/gfx/include/dxsdk/dxgi1_4.h index 5eae7849dc..bd929744e5 100644 --- a/gfx/include/dxsdk/dxgi1_4.h +++ b/gfx/include/dxsdk/dxgi1_4.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,28 +41,24 @@ typedef interface IDXGISwapChain3 IDXGISwapChain3; #endif /* __IDXGISwapChain3_FWD_DEFINED__ */ - #ifndef __IDXGIOutput4_FWD_DEFINED__ #define __IDXGIOutput4_FWD_DEFINED__ typedef interface IDXGIOutput4 IDXGIOutput4; #endif /* __IDXGIOutput4_FWD_DEFINED__ */ - #ifndef __IDXGIFactory4_FWD_DEFINED__ #define __IDXGIFactory4_FWD_DEFINED__ typedef interface IDXGIFactory4 IDXGIFactory4; #endif /* __IDXGIFactory4_FWD_DEFINED__ */ - #ifndef __IDXGIAdapter3_FWD_DEFINED__ #define __IDXGIAdapter3_FWD_DEFINED__ typedef interface IDXGIAdapter3 IDXGIAdapter3; #endif /* __IDXGIAdapter3_FWD_DEFINED__ */ - /* header files for imported files */ #include "dxgi1_3.h" @@ -74,7 +66,6 @@ typedef interface IDXGIAdapter3 IDXGIAdapter3; extern "C"{ #endif - /* interface __MIDL_itf_dxgi1_4_0000_0000 */ /* [local] */ @@ -88,8 +79,6 @@ enum DXGI_SWAP_CHAIN_COLOR_SPACE_SUPPORT_FLAG DXGI_SWAP_CHAIN_COLOR_SPACE_SUPPORT_FLAG_OVERLAY_PRESENT = 0x2 } DXGI_SWAP_CHAIN_COLOR_SPACE_SUPPORT_FLAG; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0000_v0_0_s_ifspec; @@ -99,7 +88,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0000_v0_0_s_ifspec; /* interface IDXGISwapChain3 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChain3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -388,7 +376,6 @@ EXTERN_C const IID IID_IDXGISwapChain3; #ifdef COBJMACROS - #define IDXGISwapChain3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -398,7 +385,6 @@ EXTERN_C const IID IID_IDXGISwapChain3; #define IDXGISwapChain3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChain3_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -411,11 +397,9 @@ EXTERN_C const IID IID_IDXGISwapChain3; #define IDXGISwapChain3_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISwapChain3_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISwapChain3_Present(This,SyncInterval,Flags) \ ( (This)->lpVtbl -> Present(This,SyncInterval,Flags) ) @@ -446,7 +430,6 @@ EXTERN_C const IID IID_IDXGISwapChain3; #define IDXGISwapChain3_GetLastPresentCount(This,pLastPresentCount) \ ( (This)->lpVtbl -> GetLastPresentCount(This,pLastPresentCount) ) - #define IDXGISwapChain3_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) @@ -480,7 +463,6 @@ EXTERN_C const IID IID_IDXGISwapChain3; #define IDXGISwapChain3_GetRotation(This,pRotation) \ ( (This)->lpVtbl -> GetRotation(This,pRotation) ) - #define IDXGISwapChain3_SetSourceSize(This,Width,Height) \ ( (This)->lpVtbl -> SetSourceSize(This,Width,Height) ) @@ -502,7 +484,6 @@ EXTERN_C const IID IID_IDXGISwapChain3; #define IDXGISwapChain3_GetMatrixTransform(This,pMatrix) \ ( (This)->lpVtbl -> GetMatrixTransform(This,pMatrix) ) - #define IDXGISwapChain3_GetCurrentBackBufferIndex(This) \ ( (This)->lpVtbl -> GetCurrentBackBufferIndex(This) ) @@ -517,15 +498,10 @@ EXTERN_C const IID IID_IDXGISwapChain3; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChain3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_4_0000_0001 */ /* [local] */ @@ -535,8 +511,6 @@ enum DXGI_OVERLAY_COLOR_SPACE_SUPPORT_FLAG DXGI_OVERLAY_COLOR_SPACE_SUPPORT_FLAG_PRESENT = 0x1 } DXGI_OVERLAY_COLOR_SPACE_SUPPORT_FLAG; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0001_v0_0_s_ifspec; @@ -546,7 +520,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0001_v0_0_s_ifspec; /* interface IDXGIOutput4 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -747,7 +720,6 @@ EXTERN_C const IID IID_IDXGIOutput4; #ifdef COBJMACROS - #define IDXGIOutput4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -757,7 +729,6 @@ EXTERN_C const IID IID_IDXGIOutput4; #define IDXGIOutput4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput4_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -770,7 +741,6 @@ EXTERN_C const IID IID_IDXGIOutput4; #define IDXGIOutput4_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput4_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -807,7 +777,6 @@ EXTERN_C const IID IID_IDXGIOutput4; #define IDXGIOutput4_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput4_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -820,36 +789,27 @@ EXTERN_C const IID IID_IDXGIOutput4; #define IDXGIOutput4_DuplicateOutput(This,pDevice,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput(This,pDevice,ppOutputDuplication) ) - #define IDXGIOutput4_SupportsOverlays(This) \ ( (This)->lpVtbl -> SupportsOverlays(This) ) - #define IDXGIOutput4_CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) ) - #define IDXGIOutput4_CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput4_INTERFACE_DEFINED__ */ - #ifndef __IDXGIFactory4_INTERFACE_DEFINED__ #define __IDXGIFactory4_INTERFACE_DEFINED__ /* interface IDXGIFactory4 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1086,7 +1046,6 @@ EXTERN_C const IID IID_IDXGIFactory4; #ifdef COBJMACROS - #define IDXGIFactory4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1096,7 +1055,6 @@ EXTERN_C const IID IID_IDXGIFactory4; #define IDXGIFactory4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory4_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1109,7 +1067,6 @@ EXTERN_C const IID IID_IDXGIFactory4; #define IDXGIFactory4_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory4_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -1125,14 +1082,12 @@ EXTERN_C const IID IID_IDXGIFactory4; #define IDXGIFactory4_CreateSoftwareAdapter(This,Module,ppAdapter) \ ( (This)->lpVtbl -> CreateSoftwareAdapter(This,Module,ppAdapter) ) - #define IDXGIFactory4_EnumAdapters1(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters1(This,Adapter,ppAdapter) ) #define IDXGIFactory4_IsCurrent(This) \ ( (This)->lpVtbl -> IsCurrent(This) ) - #define IDXGIFactory4_IsWindowedStereoEnabled(This) \ ( (This)->lpVtbl -> IsWindowedStereoEnabled(This) ) @@ -1166,11 +1121,9 @@ EXTERN_C const IID IID_IDXGIFactory4; #define IDXGIFactory4_CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) \ ( (This)->lpVtbl -> CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) ) - #define IDXGIFactory4_GetCreationFlags(This) \ ( (This)->lpVtbl -> GetCreationFlags(This) ) - #define IDXGIFactory4_EnumAdapterByLuid(This,AdapterLuid,riid,ppvAdapter) \ ( (This)->lpVtbl -> EnumAdapterByLuid(This,AdapterLuid,riid,ppvAdapter) ) @@ -1179,15 +1132,10 @@ EXTERN_C const IID IID_IDXGIFactory4; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory4_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_4_0000_0003 */ /* [local] */ @@ -1206,8 +1154,6 @@ typedef struct DXGI_QUERY_VIDEO_MEMORY_INFO UINT64 CurrentReservation; } DXGI_QUERY_VIDEO_MEMORY_INFO; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0003_v0_0_s_ifspec; @@ -1217,7 +1163,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0003_v0_0_s_ifspec; /* interface IDXGIAdapter3 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIAdapter3; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1396,7 +1341,6 @@ EXTERN_C const IID IID_IDXGIAdapter3; #ifdef COBJMACROS - #define IDXGIAdapter3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1406,7 +1350,6 @@ EXTERN_C const IID IID_IDXGIAdapter3; #define IDXGIAdapter3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIAdapter3_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1419,7 +1362,6 @@ EXTERN_C const IID IID_IDXGIAdapter3; #define IDXGIAdapter3_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIAdapter3_EnumOutputs(This,Output,ppOutput) \ ( (This)->lpVtbl -> EnumOutputs(This,Output,ppOutput) ) @@ -1429,15 +1371,12 @@ EXTERN_C const IID IID_IDXGIAdapter3; #define IDXGIAdapter3_CheckInterfaceSupport(This,InterfaceName,pUMDVersion) \ ( (This)->lpVtbl -> CheckInterfaceSupport(This,InterfaceName,pUMDVersion) ) - #define IDXGIAdapter3_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) - #define IDXGIAdapter3_GetDesc2(This,pDesc) \ ( (This)->lpVtbl -> GetDesc2(This,pDesc) ) - #define IDXGIAdapter3_RegisterHardwareContentProtectionTeardownStatusEvent(This,hEvent,pdwCookie) \ ( (This)->lpVtbl -> RegisterHardwareContentProtectionTeardownStatusEvent(This,hEvent,pdwCookie) ) @@ -1458,15 +1397,10 @@ EXTERN_C const IID IID_IDXGIAdapter3; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIAdapter3_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_4_0000_0004 */ /* [local] */ @@ -1477,7 +1411,6 @@ DEFINE_GUID(IID_IDXGIOutput4,0xdc7dca35,0x2196,0x414d,0x9F,0x53,0x61,0x78,0x84,0 DEFINE_GUID(IID_IDXGIFactory4,0x1bc6ea02,0xef36,0x464f,0xbf,0x0c,0x21,0xca,0x39,0xe5,0x16,0x8a); DEFINE_GUID(IID_IDXGIAdapter3,0x645967A4,0x1392,0x4310,0xA7,0x98,0x80,0x53,0xCE,0x3E,0x93,0xFD); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0004_v0_0_s_ifspec; @@ -1491,4 +1424,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_4_0000_0004_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgi1_5.h b/gfx/include/dxsdk/dxgi1_5.h index f9d8257d5c..0e9f887cfc 100644 --- a/gfx/include/dxsdk/dxgi1_5.h +++ b/gfx/include/dxsdk/dxgi1_5.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,28 +41,24 @@ typedef interface IDXGIOutput5 IDXGIOutput5; #endif /* __IDXGIOutput5_FWD_DEFINED__ */ - #ifndef __IDXGISwapChain4_FWD_DEFINED__ #define __IDXGISwapChain4_FWD_DEFINED__ typedef interface IDXGISwapChain4 IDXGISwapChain4; #endif /* __IDXGISwapChain4_FWD_DEFINED__ */ - #ifndef __IDXGIDevice4_FWD_DEFINED__ #define __IDXGIDevice4_FWD_DEFINED__ typedef interface IDXGIDevice4 IDXGIDevice4; #endif /* __IDXGIDevice4_FWD_DEFINED__ */ - #ifndef __IDXGIFactory5_FWD_DEFINED__ #define __IDXGIFactory5_FWD_DEFINED__ typedef interface IDXGIFactory5 IDXGIFactory5; #endif /* __IDXGIFactory5_FWD_DEFINED__ */ - /* header files for imported files */ #include "dxgi1_4.h" @@ -74,7 +66,6 @@ typedef interface IDXGIFactory5 IDXGIFactory5; extern "C"{ #endif - /* interface __MIDL_itf_dxgi1_5_0000_0000 */ /* [local] */ @@ -87,8 +78,6 @@ enum DXGI_OUTDUPL_FLAG DXGI_OUTDUPL_COMPOSITED_UI_CAPTURE_ONLY = 1 } DXGI_OUTDUPL_FLAG; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0000_v0_0_s_ifspec; @@ -98,7 +87,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0000_v0_0_s_ifspec; /* interface IDXGIOutput5 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput5; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -312,7 +300,6 @@ EXTERN_C const IID IID_IDXGIOutput5; #ifdef COBJMACROS - #define IDXGIOutput5_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -322,7 +309,6 @@ EXTERN_C const IID IID_IDXGIOutput5; #define IDXGIOutput5_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput5_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -335,7 +321,6 @@ EXTERN_C const IID IID_IDXGIOutput5; #define IDXGIOutput5_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput5_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -372,7 +357,6 @@ EXTERN_C const IID IID_IDXGIOutput5; #define IDXGIOutput5_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput5_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -385,33 +369,24 @@ EXTERN_C const IID IID_IDXGIOutput5; #define IDXGIOutput5_DuplicateOutput(This,pDevice,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput(This,pDevice,ppOutputDuplication) ) - #define IDXGIOutput5_SupportsOverlays(This) \ ( (This)->lpVtbl -> SupportsOverlays(This) ) - #define IDXGIOutput5_CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) ) - #define IDXGIOutput5_CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) ) - #define IDXGIOutput5_DuplicateOutput1(This,pDevice,Flags,SupportedFormatsCount,pSupportedFormats,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput1(This,pDevice,Flags,SupportedFormatsCount,pSupportedFormats,ppOutputDuplication) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput5_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_5_0000_0001 */ /* [local] */ @@ -434,8 +409,6 @@ typedef struct DXGI_HDR_METADATA_HDR10 UINT16 MaxFrameAverageLightLevel; } DXGI_HDR_METADATA_HDR10; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0001_v0_0_s_ifspec; @@ -445,7 +418,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0001_v0_0_s_ifspec; /* interface IDXGISwapChain4 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGISwapChain4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -723,7 +695,6 @@ EXTERN_C const IID IID_IDXGISwapChain4; #ifdef COBJMACROS - #define IDXGISwapChain4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -733,7 +704,6 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGISwapChain4_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -746,11 +716,9 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGISwapChain4_GetDevice(This,riid,ppDevice) \ ( (This)->lpVtbl -> GetDevice(This,riid,ppDevice) ) - #define IDXGISwapChain4_Present(This,SyncInterval,Flags) \ ( (This)->lpVtbl -> Present(This,SyncInterval,Flags) ) @@ -781,7 +749,6 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_GetLastPresentCount(This,pLastPresentCount) \ ( (This)->lpVtbl -> GetLastPresentCount(This,pLastPresentCount) ) - #define IDXGISwapChain4_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) @@ -815,7 +782,6 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_GetRotation(This,pRotation) \ ( (This)->lpVtbl -> GetRotation(This,pRotation) ) - #define IDXGISwapChain4_SetSourceSize(This,Width,Height) \ ( (This)->lpVtbl -> SetSourceSize(This,Width,Height) ) @@ -837,7 +803,6 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_GetMatrixTransform(This,pMatrix) \ ( (This)->lpVtbl -> GetMatrixTransform(This,pMatrix) ) - #define IDXGISwapChain4_GetCurrentBackBufferIndex(This) \ ( (This)->lpVtbl -> GetCurrentBackBufferIndex(This) ) @@ -850,21 +815,15 @@ EXTERN_C const IID IID_IDXGISwapChain4; #define IDXGISwapChain4_ResizeBuffers1(This,BufferCount,Width,Height,Format,SwapChainFlags,pCreationNodeMask,ppPresentQueue) \ ( (This)->lpVtbl -> ResizeBuffers1(This,BufferCount,Width,Height,Format,SwapChainFlags,pCreationNodeMask,ppPresentQueue) ) - #define IDXGISwapChain4_SetHDRMetaData(This,Type,Size,pMetaData) \ ( (This)->lpVtbl -> SetHDRMetaData(This,Type,Size,pMetaData) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGISwapChain4_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_5_0000_0002 */ /* [local] */ @@ -882,8 +841,6 @@ enum _DXGI_RECLAIM_RESOURCE_RESULTS DXGI_RECLAIM_RESOURCE_RESULT_NOT_COMMITTED = 2 } DXGI_RECLAIM_RESOURCE_RESULTS; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0002_v0_0_s_ifspec; @@ -893,7 +850,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0002_v0_0_s_ifspec; /* interface IDXGIDevice4 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIDevice4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1072,7 +1028,6 @@ EXTERN_C const IID IID_IDXGIDevice4; #ifdef COBJMACROS - #define IDXGIDevice4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1082,7 +1037,6 @@ EXTERN_C const IID IID_IDXGIDevice4; #define IDXGIDevice4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDevice4_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1095,7 +1049,6 @@ EXTERN_C const IID IID_IDXGIDevice4; #define IDXGIDevice4_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIDevice4_GetAdapter(This,pAdapter) \ ( (This)->lpVtbl -> GetAdapter(This,pAdapter) ) @@ -1111,14 +1064,12 @@ EXTERN_C const IID IID_IDXGIDevice4; #define IDXGIDevice4_GetGPUThreadPriority(This,pPriority) \ ( (This)->lpVtbl -> GetGPUThreadPriority(This,pPriority) ) - #define IDXGIDevice4_SetMaximumFrameLatency(This,MaxLatency) \ ( (This)->lpVtbl -> SetMaximumFrameLatency(This,MaxLatency) ) #define IDXGIDevice4_GetMaximumFrameLatency(This,pMaxLatency) \ ( (This)->lpVtbl -> GetMaximumFrameLatency(This,pMaxLatency) ) - #define IDXGIDevice4_OfferResources(This,NumResources,ppResources,Priority) \ ( (This)->lpVtbl -> OfferResources(This,NumResources,ppResources,Priority) ) @@ -1128,11 +1079,9 @@ EXTERN_C const IID IID_IDXGIDevice4; #define IDXGIDevice4_EnqueueSetEvent(This,hEvent) \ ( (This)->lpVtbl -> EnqueueSetEvent(This,hEvent) ) - #define IDXGIDevice4_Trim(This) \ ( (This)->lpVtbl -> Trim(This) ) - #define IDXGIDevice4_OfferResources1(This,NumResources,ppResources,Priority,Flags) \ ( (This)->lpVtbl -> OfferResources1(This,NumResources,ppResources,Priority,Flags) ) @@ -1141,15 +1090,10 @@ EXTERN_C const IID IID_IDXGIDevice4; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDevice4_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_5_0000_0003 */ /* [local] */ @@ -1159,8 +1103,6 @@ enum DXGI_FEATURE DXGI_FEATURE_PRESENT_ALLOW_TEARING = 0 } DXGI_FEATURE; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0003_v0_0_s_ifspec; @@ -1170,7 +1112,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0003_v0_0_s_ifspec; /* interface IDXGIFactory5 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIFactory5; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -1406,7 +1347,6 @@ EXTERN_C const IID IID_IDXGIFactory5; #ifdef COBJMACROS - #define IDXGIFactory5_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -1416,7 +1356,6 @@ EXTERN_C const IID IID_IDXGIFactory5; #define IDXGIFactory5_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIFactory5_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -1429,7 +1368,6 @@ EXTERN_C const IID IID_IDXGIFactory5; #define IDXGIFactory5_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIFactory5_EnumAdapters(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters(This,Adapter,ppAdapter) ) @@ -1445,14 +1383,12 @@ EXTERN_C const IID IID_IDXGIFactory5; #define IDXGIFactory5_CreateSoftwareAdapter(This,Module,ppAdapter) \ ( (This)->lpVtbl -> CreateSoftwareAdapter(This,Module,ppAdapter) ) - #define IDXGIFactory5_EnumAdapters1(This,Adapter,ppAdapter) \ ( (This)->lpVtbl -> EnumAdapters1(This,Adapter,ppAdapter) ) #define IDXGIFactory5_IsCurrent(This) \ ( (This)->lpVtbl -> IsCurrent(This) ) - #define IDXGIFactory5_IsWindowedStereoEnabled(This) \ ( (This)->lpVtbl -> IsWindowedStereoEnabled(This) ) @@ -1486,32 +1422,24 @@ EXTERN_C const IID IID_IDXGIFactory5; #define IDXGIFactory5_CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) \ ( (This)->lpVtbl -> CreateSwapChainForComposition(This,pDevice,pDesc,pRestrictToOutput,ppSwapChain) ) - #define IDXGIFactory5_GetCreationFlags(This) \ ( (This)->lpVtbl -> GetCreationFlags(This) ) - #define IDXGIFactory5_EnumAdapterByLuid(This,AdapterLuid,riid,ppvAdapter) \ ( (This)->lpVtbl -> EnumAdapterByLuid(This,AdapterLuid,riid,ppvAdapter) ) #define IDXGIFactory5_EnumWarpAdapter(This,riid,ppvAdapter) \ ( (This)->lpVtbl -> EnumWarpAdapter(This,riid,ppvAdapter) ) - #define IDXGIFactory5_CheckFeatureSupport(This,Feature,pFeatureSupportData,FeatureSupportDataSize) \ ( (This)->lpVtbl -> CheckFeatureSupport(This,Feature,pFeatureSupportData,FeatureSupportDataSize) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIFactory5_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_5_0000_0004 */ /* [local] */ @@ -1522,7 +1450,6 @@ DEFINE_GUID(IID_IDXGISwapChain4,0x3D585D5A,0xBD4A,0x489E,0xB1,0xF4,0x3D,0xBC,0xB DEFINE_GUID(IID_IDXGIDevice4,0x95B4F95F,0xD8DA,0x4CA4,0x9E,0xE6,0x3B,0x76,0xD5,0x96,0x8A,0x10); DEFINE_GUID(IID_IDXGIFactory5,0x7632e1f5,0xee65,0x4dca,0x87,0xfd,0x84,0xcd,0x75,0xf8,0x83,0x8d); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0004_v0_0_s_ifspec; @@ -1536,4 +1463,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_5_0000_0004_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgi1_6.h b/gfx/include/dxsdk/dxgi1_6.h index a23db170d7..3ecb3de0a6 100644 --- a/gfx/include/dxsdk/dxgi1_6.h +++ b/gfx/include/dxsdk/dxgi1_6.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,14 +41,12 @@ typedef interface IDXGIAdapter4 IDXGIAdapter4; #endif /* __IDXGIAdapter4_FWD_DEFINED__ */ - #ifndef __IDXGIOutput6_FWD_DEFINED__ #define __IDXGIOutput6_FWD_DEFINED__ typedef interface IDXGIOutput6 IDXGIOutput6; #endif /* __IDXGIOutput6_FWD_DEFINED__ */ - /* header files for imported files */ #include "dxgi1_5.h" @@ -60,7 +54,6 @@ typedef interface IDXGIOutput6 IDXGIOutput6; extern "C"{ #endif - /* interface __MIDL_itf_dxgi1_6_0000_0000 */ /* [local] */ @@ -98,8 +91,6 @@ typedef struct DXGI_ADAPTER_DESC3 DXGI_COMPUTE_PREEMPTION_GRANULARITY ComputePreemptionGranularity; } DXGI_ADAPTER_DESC3; - - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0000_v0_0_s_ifspec; @@ -109,7 +100,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0000_v0_0_s_ifspec; /* interface IDXGIAdapter4 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIAdapter4; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -261,7 +251,6 @@ EXTERN_C const IID IID_IDXGIAdapter4; #ifdef COBJMACROS - #define IDXGIAdapter4_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -271,7 +260,6 @@ EXTERN_C const IID IID_IDXGIAdapter4; #define IDXGIAdapter4_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIAdapter4_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -284,7 +272,6 @@ EXTERN_C const IID IID_IDXGIAdapter4; #define IDXGIAdapter4_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIAdapter4_EnumOutputs(This,Output,ppOutput) \ ( (This)->lpVtbl -> EnumOutputs(This,Output,ppOutput) ) @@ -294,15 +281,12 @@ EXTERN_C const IID IID_IDXGIAdapter4; #define IDXGIAdapter4_CheckInterfaceSupport(This,InterfaceName,pUMDVersion) \ ( (This)->lpVtbl -> CheckInterfaceSupport(This,InterfaceName,pUMDVersion) ) - #define IDXGIAdapter4_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) - #define IDXGIAdapter4_GetDesc2(This,pDesc) \ ( (This)->lpVtbl -> GetDesc2(This,pDesc) ) - #define IDXGIAdapter4_RegisterHardwareContentProtectionTeardownStatusEvent(This,hEvent,pdwCookie) \ ( (This)->lpVtbl -> RegisterHardwareContentProtectionTeardownStatusEvent(This,hEvent,pdwCookie) ) @@ -321,21 +305,15 @@ EXTERN_C const IID IID_IDXGIAdapter4; #define IDXGIAdapter4_UnregisterVideoMemoryBudgetChangeNotification(This,dwCookie) \ ( (This)->lpVtbl -> UnregisterVideoMemoryBudgetChangeNotification(This,dwCookie) ) - #define IDXGIAdapter4_GetDesc3(This,pDesc) \ ( (This)->lpVtbl -> GetDesc3(This,pDesc) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIAdapter4_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_6_0000_0001 */ /* [local] */ @@ -367,7 +345,6 @@ enum DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAGS DEFINE_ENUM_FLAG_OPERATORS( DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAGS ); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0001_v0_0_s_ifspec; @@ -377,7 +354,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0001_v0_0_s_ifspec; /* interface IDXGIOutput6 */ /* [unique][local][uuid][object] */ - EXTERN_C const IID IID_IDXGIOutput6; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -598,7 +574,6 @@ EXTERN_C const IID IID_IDXGIOutput6; #ifdef COBJMACROS - #define IDXGIOutput6_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -608,7 +583,6 @@ EXTERN_C const IID IID_IDXGIOutput6; #define IDXGIOutput6_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIOutput6_SetPrivateData(This,Name,DataSize,pData) \ ( (This)->lpVtbl -> SetPrivateData(This,Name,DataSize,pData) ) @@ -621,7 +595,6 @@ EXTERN_C const IID IID_IDXGIOutput6; #define IDXGIOutput6_GetParent(This,riid,ppParent) \ ( (This)->lpVtbl -> GetParent(This,riid,ppParent) ) - #define IDXGIOutput6_GetDesc(This,pDesc) \ ( (This)->lpVtbl -> GetDesc(This,pDesc) ) @@ -658,7 +631,6 @@ EXTERN_C const IID IID_IDXGIOutput6; #define IDXGIOutput6_GetFrameStatistics(This,pStats) \ ( (This)->lpVtbl -> GetFrameStatistics(This,pStats) ) - #define IDXGIOutput6_GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) \ ( (This)->lpVtbl -> GetDisplayModeList1(This,EnumFormat,Flags,pNumModes,pDesc) ) @@ -671,23 +643,18 @@ EXTERN_C const IID IID_IDXGIOutput6; #define IDXGIOutput6_DuplicateOutput(This,pDevice,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput(This,pDevice,ppOutputDuplication) ) - #define IDXGIOutput6_SupportsOverlays(This) \ ( (This)->lpVtbl -> SupportsOverlays(This) ) - #define IDXGIOutput6_CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlaySupport(This,EnumFormat,pConcernedDevice,pFlags) ) - #define IDXGIOutput6_CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) \ ( (This)->lpVtbl -> CheckOverlayColorSpaceSupport(This,Format,ColorSpace,pConcernedDevice,pFlags) ) - #define IDXGIOutput6_DuplicateOutput1(This,pDevice,Flags,SupportedFormatsCount,pSupportedFormats,ppOutputDuplication) \ ( (This)->lpVtbl -> DuplicateOutput1(This,pDevice,Flags,SupportedFormatsCount,pSupportedFormats,ppOutputDuplication) ) - #define IDXGIOutput6_GetDesc1(This,pDesc) \ ( (This)->lpVtbl -> GetDesc1(This,pDesc) ) @@ -696,15 +663,10 @@ EXTERN_C const IID IID_IDXGIOutput6; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIOutput6_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgi1_6_0000_0002 */ /* [local] */ @@ -713,7 +675,6 @@ EXTERN_C const IID IID_IDXGIOutput6; DEFINE_GUID(IID_IDXGIAdapter4,0x3c8d99d1,0x4fbf,0x4181,0xa8,0x2c,0xaf,0x66,0xbf,0x7b,0xd2,0x4e); DEFINE_GUID(IID_IDXGIOutput6,0x068346e8,0xaaec,0x4b84,0xad,0xd7,0x13,0x7f,0x51,0x3f,0x77,0xa1); - extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0002_v0_0_s_ifspec; @@ -727,4 +688,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgi1_6_0000_0002_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgicommon.h b/gfx/include/dxsdk/dxgicommon.h index bdeab3217f..8b8fbf5863 100644 --- a/gfx/include/dxsdk/dxgicommon.h +++ b/gfx/include/dxsdk/dxgicommon.h @@ -5,7 +5,6 @@ #ifndef __dxgicommon_h__ #define __dxgicommon_h__ - typedef struct DXGI_RATIONAL { UINT Numerator; diff --git a/gfx/include/dxsdk/dxgidebug.h b/gfx/include/dxsdk/dxgidebug.h index 9a561ad31c..ee4756ce42 100644 --- a/gfx/include/dxsdk/dxgidebug.h +++ b/gfx/include/dxsdk/dxgidebug.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,21 +41,18 @@ typedef interface IDXGIInfoQueue IDXGIInfoQueue; #endif /* __IDXGIInfoQueue_FWD_DEFINED__ */ - #ifndef __IDXGIDebug_FWD_DEFINED__ #define __IDXGIDebug_FWD_DEFINED__ typedef interface IDXGIDebug IDXGIDebug; #endif /* __IDXGIDebug_FWD_DEFINED__ */ - #ifndef __IDXGIDebug1_FWD_DEFINED__ #define __IDXGIDebug1_FWD_DEFINED__ typedef interface IDXGIDebug1 IDXGIDebug1; #endif /* __IDXGIDebug1_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -68,7 +61,6 @@ typedef interface IDXGIDebug1 IDXGIDebug1; extern "C"{ #endif - /* interface __MIDL_itf_dxgidebug_0000_0000 */ /* [local] */ @@ -154,7 +146,6 @@ typedef struct DXGI_INFO_QUEUE_FILTER #define DXGI_INFO_QUEUE_DEFAULT_MESSAGE_COUNT_LIMIT 1024 HRESULT WINAPI DXGIGetDebugInterface(REFIID riid, void **ppDebug); - extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0000_v0_0_s_ifspec; @@ -164,7 +155,6 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0000_v0_0_s_ifspec; /* interface IDXGIInfoQueue */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_IDXGIInfoQueue; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -647,7 +637,6 @@ EXTERN_C const IID IID_IDXGIInfoQueue; #ifdef COBJMACROS - #define IDXGIInfoQueue_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -657,7 +646,6 @@ EXTERN_C const IID IID_IDXGIInfoQueue; #define IDXGIInfoQueue_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIInfoQueue_SetMessageCountLimit(This,Producer,MessageCountLimit) \ ( (This)->lpVtbl -> SetMessageCountLimit(This,Producer,MessageCountLimit) ) @@ -771,22 +759,16 @@ EXTERN_C const IID IID_IDXGIInfoQueue; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIInfoQueue_INTERFACE_DEFINED__ */ - #ifndef __IDXGIDebug_INTERFACE_DEFINED__ #define __IDXGIDebug_INTERFACE_DEFINED__ /* interface IDXGIDebug */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_IDXGIDebug; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -837,7 +819,6 @@ EXTERN_C const IID IID_IDXGIDebug; #ifdef COBJMACROS - #define IDXGIDebug_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -847,28 +828,21 @@ EXTERN_C const IID IID_IDXGIDebug; #define IDXGIDebug_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDebug_ReportLiveObjects(This,apiid,flags) \ ( (This)->lpVtbl -> ReportLiveObjects(This,apiid,flags) ) #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDebug_INTERFACE_DEFINED__ */ - #ifndef __IDXGIDebug1_INTERFACE_DEFINED__ #define __IDXGIDebug1_INTERFACE_DEFINED__ /* interface IDXGIDebug1 */ /* [unique][local][object][uuid] */ - EXTERN_C const IID IID_IDXGIDebug1; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -930,7 +904,6 @@ EXTERN_C const IID IID_IDXGIDebug1; #ifdef COBJMACROS - #define IDXGIDebug1_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -940,11 +913,9 @@ EXTERN_C const IID IID_IDXGIDebug1; #define IDXGIDebug1_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IDXGIDebug1_ReportLiveObjects(This,apiid,flags) \ ( (This)->lpVtbl -> ReportLiveObjects(This,apiid,flags) ) - #define IDXGIDebug1_EnableLeakTrackingForThread(This) \ ( (This)->lpVtbl -> EnableLeakTrackingForThread(This) ) @@ -956,15 +927,10 @@ EXTERN_C const IID IID_IDXGIDebug1; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IDXGIDebug1_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_dxgidebug_0000_0003 */ /* [local] */ @@ -978,7 +944,6 @@ DEFINE_GUID(IID_IDXGIInfoQueue,0xD67441C7,0x672A,0x476f,0x9E,0x82,0xCD,0x55,0xB4 DEFINE_GUID(IID_IDXGIDebug,0x119E7452,0xDE9E,0x40fe,0x88,0x06,0x88,0xF9,0x0C,0x12,0xB4,0x41); DEFINE_GUID(IID_IDXGIDebug1,0xc5a05f0c,0x16f2,0x4adf,0x9f,0x4d,0xa8,0xc4,0xd5,0x8a,0xc5,0x50); - extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0003_v0_0_s_ifspec; @@ -992,4 +957,3 @@ extern RPC_IF_HANDLE __MIDL_itf_dxgidebug_0000_0003_v0_0_s_ifspec; #endif - diff --git a/gfx/include/dxsdk/dxgiformat.h b/gfx/include/dxsdk/dxgiformat.h index 4159caba4b..7eeb6c6ecc 100644 --- a/gfx/include/dxsdk/dxgiformat.h +++ b/gfx/include/dxsdk/dxgiformat.h @@ -130,7 +130,6 @@ typedef enum DXGI_FORMAT DXGI_FORMAT_V208 = 131, DXGI_FORMAT_V408 = 132, - DXGI_FORMAT_FORCE_UINT = 0xffffffff } DXGI_FORMAT; diff --git a/gfx/include/dxsdk/dxgitype.h b/gfx/include/dxsdk/dxgitype.h index d3a698b5a1..31c96b7a68 100644 --- a/gfx/include/dxsdk/dxgitype.h +++ b/gfx/include/dxsdk/dxgitype.h @@ -51,7 +51,6 @@ #define DXGI_CPU_ACCESS_SCRATCH ( 3 ) #define DXGI_CPU_ACCESS_FIELD 15 - typedef struct DXGI_RGB { float Red; diff --git a/gfx/include/dxsdk/gameux.h b/gfx/include/dxsdk/gameux.h index 5065960d7f..e61e4a257a 100644 --- a/gfx/include/dxsdk/gameux.h +++ b/gfx/include/dxsdk/gameux.h @@ -1,13 +1,9 @@ - /* this ALWAYS GENERATED file contains the definitions for the interfaces */ - /* File created by MIDL compiler version 8.00.0613 */ /* @@MIDL_FILE_HEADING( ) */ - - /* verify that the version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 475 @@ -45,28 +41,24 @@ typedef interface IGameExplorer IGameExplorer; #endif /* __IGameExplorer_FWD_DEFINED__ */ - #ifndef __IGameStatistics_FWD_DEFINED__ #define __IGameStatistics_FWD_DEFINED__ typedef interface IGameStatistics IGameStatistics; #endif /* __IGameStatistics_FWD_DEFINED__ */ - #ifndef __IGameStatisticsMgr_FWD_DEFINED__ #define __IGameStatisticsMgr_FWD_DEFINED__ typedef interface IGameStatisticsMgr IGameStatisticsMgr; #endif /* __IGameStatisticsMgr_FWD_DEFINED__ */ - #ifndef __IGameExplorer2_FWD_DEFINED__ #define __IGameExplorer2_FWD_DEFINED__ typedef interface IGameExplorer2 IGameExplorer2; #endif /* __IGameExplorer2_FWD_DEFINED__ */ - #ifndef __GameExplorer_FWD_DEFINED__ #define __GameExplorer_FWD_DEFINED__ @@ -78,7 +70,6 @@ typedef struct GameExplorer GameExplorer; #endif /* __GameExplorer_FWD_DEFINED__ */ - #ifndef __GameStatistics_FWD_DEFINED__ #define __GameStatistics_FWD_DEFINED__ @@ -90,7 +81,6 @@ typedef struct GameStatistics GameStatistics; #endif /* __GameStatistics_FWD_DEFINED__ */ - /* header files for imported files */ #include "oaidl.h" #include "ocidl.h" @@ -100,7 +90,6 @@ typedef struct GameStatistics GameStatistics; extern "C"{ #endif - /* interface __MIDL_itf_gameux_0000_0000 */ /* [local] */ @@ -120,8 +109,6 @@ enum GAME_INSTALL_SCOPE GIS_ALL_USERS = 3 } GAME_INSTALL_SCOPE; - - extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0000_v0_0_s_ifspec; @@ -131,7 +118,6 @@ extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0000_v0_0_s_ifspec; /* interface IGameExplorer */ /* [unique][helpstring][uuid][object] */ - EXTERN_C const IID IID_IGameExplorer; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -209,7 +195,6 @@ EXTERN_C const IID IID_IGameExplorer; #ifdef COBJMACROS - #define IGameExplorer_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -219,7 +204,6 @@ EXTERN_C const IID IID_IGameExplorer; #define IGameExplorer_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IGameExplorer_AddGame(This,bstrGDFBinaryPath,bstrGameInstallDirectory,installScope,pguidInstanceID) \ ( (This)->lpVtbl -> AddGame(This,bstrGDFBinaryPath,bstrGameInstallDirectory,installScope,pguidInstanceID) ) @@ -234,15 +218,10 @@ EXTERN_C const IID IID_IGameExplorer; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IGameExplorer_INTERFACE_DEFINED__ */ - /* interface __MIDL_itf_gameux_0000_0001 */ /* [local] */ @@ -260,8 +239,6 @@ enum GAMESTATS_OPEN_RESULT GAMESTATS_OPEN_OPENED = 1 } GAMESTATS_OPEN_RESULT; - - extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0001_v0_0_s_ifspec; @@ -271,7 +248,6 @@ extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0001_v0_0_s_ifspec; /* interface IGameStatistics */ /* [unique][helpstring][uuid][object] */ - EXTERN_C const IID IID_IGameStatistics; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -413,7 +389,6 @@ EXTERN_C const IID IID_IGameStatistics; #ifdef COBJMACROS - #define IGameStatistics_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -423,7 +398,6 @@ EXTERN_C const IID IID_IGameStatistics; #define IGameStatistics_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IGameStatistics_GetMaxCategoryLength(This,cch) \ ( (This)->lpVtbl -> GetMaxCategoryLength(This,cch) ) @@ -462,22 +436,16 @@ EXTERN_C const IID IID_IGameStatistics; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IGameStatistics_INTERFACE_DEFINED__ */ - #ifndef __IGameStatisticsMgr_INTERFACE_DEFINED__ #define __IGameStatisticsMgr_INTERFACE_DEFINED__ /* interface IGameStatisticsMgr */ /* [unique][helpstring][uuid][object] */ - EXTERN_C const IID IID_IGameStatisticsMgr; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -539,7 +507,6 @@ EXTERN_C const IID IID_IGameStatisticsMgr; #ifdef COBJMACROS - #define IGameStatisticsMgr_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -549,7 +516,6 @@ EXTERN_C const IID IID_IGameStatisticsMgr; #define IGameStatisticsMgr_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IGameStatisticsMgr_GetGameStatistics(This,GDFBinaryPath,openType,pOpenResult,ppiStats) \ ( (This)->lpVtbl -> GetGameStatistics(This,GDFBinaryPath,openType,pOpenResult,ppiStats) ) @@ -558,22 +524,16 @@ EXTERN_C const IID IID_IGameStatisticsMgr; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IGameStatisticsMgr_INTERFACE_DEFINED__ */ - #ifndef __IGameExplorer2_INTERFACE_DEFINED__ #define __IGameExplorer2_INTERFACE_DEFINED__ /* interface IGameExplorer2 */ /* [unique][helpstring][uuid][object] */ - EXTERN_C const IID IID_IGameExplorer2; #if defined(__cplusplus) && !defined(CINTERFACE) @@ -642,7 +602,6 @@ EXTERN_C const IID IID_IGameExplorer2; #ifdef COBJMACROS - #define IGameExplorer2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) @@ -652,7 +611,6 @@ EXTERN_C const IID IID_IGameExplorer2; #define IGameExplorer2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) - #define IGameExplorer2_InstallGame(This,binaryGDFPath,installDirectory,installScope) \ ( (This)->lpVtbl -> InstallGame(This,binaryGDFPath,installDirectory,installScope) ) @@ -664,23 +622,16 @@ EXTERN_C const IID IID_IGameExplorer2; #endif /* COBJMACROS */ - #endif /* C style interface */ - - - #endif /* __IGameExplorer2_INTERFACE_DEFINED__ */ - - #ifndef __gameuxLib_LIBRARY_DEFINED__ #define __gameuxLib_LIBRARY_DEFINED__ /* library gameuxLib */ /* [helpstring][version][uuid] */ - EXTERN_C const IID LIBID_gameuxLib; EXTERN_C const CLSID CLSID_GameExplorer; @@ -706,7 +657,6 @@ GameStatistics; #endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */ #pragma endregion - extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_gameux_0000_0005_v0_0_s_ifspec; @@ -730,4 +680,3 @@ void __RPC_USER BSTR_UserFree64( __RPC__in unsigned lo #endif - diff --git a/gfx/include/dxsdk/pixplugin.h b/gfx/include/dxsdk/pixplugin.h index 9c249afc0a..03be07b0aa 100644 --- a/gfx/include/dxsdk/pixplugin.h +++ b/gfx/include/dxsdk/pixplugin.h @@ -13,19 +13,16 @@ extern "C" { #endif - //================================================================================================== // PIX_PLUGIN_SYSTEM_VERSION - Indicates version of the plugin interface the plugin is built with. //================================================================================================== #define PIX_PLUGIN_SYSTEM_VERSION 0x101 - //================================================================================================== // PIXCOUNTERID - A unique identifier for each PIX plugin counter. //================================================================================================== typedef int PIXCOUNTERID; - //================================================================================================== // PIXCOUNTERDATATYPE - Indicates what type of data the counter produces. //================================================================================================== @@ -38,7 +35,6 @@ enum PIXCOUNTERDATATYPE PCDT_STRING, }; - //================================================================================================== // PIXPLUGININFO - This structure is filled out by PIXGetPluginInfo and passed back to PIX. //================================================================================================== @@ -53,7 +49,6 @@ struct PIXPLUGININFO int iPluginSystemVersion; // Version of PIX's plugin system this plugin was designed for }; - //================================================================================================== // PIXCOUNTERINFO - This structure is filled out by PIXGetCounterInfo and passed back to PIX // to allow PIX to determine information about the counters in the plugin. @@ -65,13 +60,11 @@ struct PIXCOUNTERINFO PIXCOUNTERDATATYPE pcdtDataType; // Data type returned by this counter }; - //================================================================================================== // PIXGetPluginInfo - This returns basic information about this plugin to PIX. //================================================================================================== BOOL WINAPI PIXGetPluginInfo( PIXPLUGININFO* pPIXPluginInfo ); - //================================================================================================== // PIXGetCounterInfo - This returns an array of PIXCOUNTERINFO structs to PIX. // These PIXCOUNTERINFOs allow PIX to enumerate the counters contained @@ -79,19 +72,16 @@ BOOL WINAPI PIXGetPluginInfo( PIXPLUGININFO* pPIXPluginInfo ); //================================================================================================== BOOL WINAPI PIXGetCounterInfo( DWORD* pdwReturnCounters, PIXCOUNTERINFO** ppCounterInfoList ); - //================================================================================================== // PIXGetCounterDesc - This is called by PIX to request a description of the indicated counter. //================================================================================================== BOOL WINAPI PIXGetCounterDesc( PIXCOUNTERID id, WCHAR** ppstrCounterDesc ); - //================================================================================================== // PIXBeginExperiment - This called by PIX once per counter when instrumentation starts. //================================================================================================== BOOL WINAPI PIXBeginExperiment( PIXCOUNTERID id, const WCHAR* pstrApplication ); - //================================================================================================== // PIXEndFrame - This is called by PIX once per counter at the end of each frame to gather the // counter value for that frame. Note that the pointer to the return data must @@ -103,13 +93,11 @@ BOOL WINAPI PIXBeginExperiment( PIXCOUNTERID id, const WCHAR* pstrApplication ); //================================================================================================== BOOL WINAPI PIXEndFrame( PIXCOUNTERID id, UINT iFrame, DWORD* pdwReturnBytes, BYTE** ppReturnData ); - //================================================================================================== // PIXEndExperiment - This is called by PIX once per counter when instrumentation ends. //================================================================================================== BOOL WINAPI PIXEndExperiment( PIXCOUNTERID id ); - #ifdef __cplusplus }; #endif diff --git a/gfx/include/dxsdk/rpcsal.h b/gfx/include/dxsdk/rpcsal.h index 7e6c69c245..f7ca06c45f 100644 --- a/gfx/include/dxsdk/rpcsal.h +++ b/gfx/include/dxsdk/rpcsal.h @@ -147,12 +147,10 @@ #endif #endif - #ifdef __cplusplus extern "C" { #endif // #ifdef __cplusplus - #ifndef _SAL1_2_Source_ #define _SAL1_2_Source_(Name, args, annotes) _SA_annotes3(SAL_name, #Name, "", "1.2") _Group_(annotes _SAL_nop_impl_) #endif // _SAL1_2_Source_ @@ -169,7 +167,6 @@ extern "C" { #define __RPC__in_xcount_full_string(size) _SAL1_2_Source_(__RPC__in_xcount_full_string, (size), __RPC__in_ecount_full(size) _Pre_ _Null_terminated_) #define __RPC__in_xcount_part(size, length) _SAL1_2_Source_(__RPC__in_xcount_part, (size,length), __RPC__in_ecount(length) _Pre_writable_size_(size)) - #define __RPC__deref_in _SAL1_2_Source_(__RPC__deref_in, (), __RPC__in _At_(*_Curr_, _Pre_ _Notnull_)) #define __RPC__deref_in_string _SAL1_2_Source_(__RPC__deref_in_string, (), __RPC__deref_in _At_(*_Curr_, _Pre_ _Null_terminated_)) #define __RPC__deref_in_opt _SAL1_2_Source_(__RPC__deref_in_opt, (), __RPC__in _At_(*_Curr_, _Pre_ _Maybenull_)) @@ -280,7 +277,6 @@ extern "C" { #define __RPC__deref_inout_xcount_full_string(size) _SAL1_2_Source_(__RPC__deref_inout_xcount_full_string, (size), __RPC__deref_inout _At_(*_Curr_, _Post_ _Null_terminated_)) #define __RPC__deref_inout_xcount_full_opt_string(size) _SAL1_2_Source_(__RPC__deref_inout_xcount_full_opt_string, (size), __RPC__deref_inout_opt _At_(*_Curr_, _Pre_ _Null_terminated_ _Post_ _Null_terminated_)) - // #define __RPC_out_opt out_opt is not allowed in rpc // [in,out,unique] @@ -294,7 +290,6 @@ extern "C" { #define __RPC__deref_opt_inout_xcount_full(size) _SAL1_2_Source_(__RPC__deref_opt_inout_xcount_full, (size), __RPC__deref_opt_inout) #define __RPC__deref_opt_inout_xcount_full_string(size) _SAL1_2_Source_(__RPC__deref_opt_inout_xcount_full_string, (size), __RPC__deref_opt_inout_string) - #define __RPC__deref_out_ecount_opt(size) _SAL1_2_Source_(__RPC__deref_out_ecount_opt, (size), _Outptr_result_buffer_maybenull_(size) _At_(*_Curr_, _Pre_maybenull_)) #define __RPC__deref_out_ecount_part_opt(size, length) _SAL1_2_Source_(__RPC__deref_out_ecount_part_opt, (size,length), _Outptr_result_buffer_to_maybenull_(size, length) _At_(*_Curr_, _Pre_maybenull_)) #define __RPC__deref_out_ecount_full_opt(size) _SAL1_2_Source_(__RPC__deref_out_ecount_full_opt, (size), __RPC__deref_out_ecount_part_opt(size, size)) @@ -323,7 +318,6 @@ extern "C" { #define __RPC__range(min,max) _SAL1_2_Source_(__RPC__range, (min,max), __range(min,max)) #define __RPC__in_range(min,max) _SAL1_2_Source_(__RPC__in_range, (min,max), _In_range_(min,max)) - #ifdef __cplusplus } #endif diff --git a/gfx/include/dxsdk/xapo.h b/gfx/include/dxsdk/xapo.h index 83481a9a3d..159d055d14 100644 --- a/gfx/include/dxsdk/xapo.h +++ b/gfx/include/dxsdk/xapo.h @@ -103,7 +103,6 @@ interface __declspec(uuid("A410B984-9839-4819-A0BE-2856AE6B3ADB")) IXAPO; interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParameters; - #if !defined(GUID_DEFS_ONLY) // ignore rest if only GUID definitions requested #include #include @@ -124,7 +123,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete // unicode string length, including terminator, used with XAPO_REGISTRATION_PROPERTIES #define XAPO_REGISTRATION_STRING_LENGTH 256 - // XAPO property flags, used with XAPO_REGISTRATION_PROPERTIES.Flags: // Number of channels of input and output buffers must match, // applies to XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS.pFormat. @@ -178,11 +176,9 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete // in-place processing when possible. #define XAPO_FLAG_INPLACE_SUPPORTED 0x00000010 - //-----------------------------------------------------// #pragma pack(push, 1) // set packing alignment to ensure consistency across arbitrary build environments - // XAPO registration properties, describes general XAPO characteristics, used with IXAPO::GetRegistrationProperties typedef struct XAPO_REGISTRATION_PROPERTIES { CLSID clsid; // COM class ID, used with CoCreate @@ -197,7 +193,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete UINT32 MaxOutputBufferCount; // maximum number of output buffers supported for processing, must be >= MinOutputBufferCount, must match MaxInputBufferCount when XAPO_FLAG_BUFFERCOUNT_MUST_MATCH used } XAPO_REGISTRATION_PROPERTIES; - // LockForProcess buffer parameters: // Defines buffer parameters that remain constant while an XAPO is locked. // Used with IXAPO::LockForProcess. @@ -251,7 +246,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete UINT32 ValidFrameCount; // number of frames of valid data, must be within respective [0, XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS.MaxFrameCount], always XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS.MaxFrameCount for CBR/user-defined XAPOs, does not affect BufferFlags } XAPO_PROCESS_BUFFER_PARAMETERS; - //-------------------------------------------------------------// // Memory allocation macros that allow one module to allocate memory and // another to free it, by guaranteeing that the same heap manager is used @@ -262,7 +256,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete #define XAPOAlloc(size) CoTaskMemAlloc(size) #define XAPOFree(p) CoTaskMemFree(p) - //-----------------------------------------------------// // IXAPO: // The only mandatory XAPO COM interface -- a thin wrapper that manages @@ -525,8 +518,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete STDMETHOD_(UINT32, CalcOutputFrames) (THIS_ UINT32 InputFrameCount) PURE; }; - - // IXAPOParameters: // Optional XAPO COM interface that allows an XAPO to use // effect-specific parameters. @@ -572,7 +563,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete STDMETHOD_(void, GetParameters) (THIS_ _Out_writes_bytes_(ParameterByteSize) void* pParameters, UINT32 ParameterByteSize) PURE; }; - //-------------------------------------------------------------// // macros to allow XAPO interfaces to be used in C code #if !defined(__cplusplus) @@ -616,7 +606,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete #define IXAPO_CalcOutputFrames(This, InputFrameCount) \ ( (This)->lpVtbl->CalcOutputFrames(This, InputFrameCount) ) - // IXAPOParameters #define IXAPOParameters_QueryInterface(This, riid, ppInterface) \ ( (This)->lpVtbl->QueryInterface(This, riid, ppInterface) ) @@ -634,7 +623,6 @@ interface __declspec(uuid("26D95C66-80F2-499A-AD54-5AE7F01C6D98")) IXAPOParamete ( (This)->lpVtbl->GetParameters(This, pParameters, ParameterByteSize) ) #endif // !defined(__cplusplus) - #pragma pack(pop) // revert packing alignment #endif // !defined(GUID_DEFS_ONLY) diff --git a/gfx/include/dxsdk/xapobase.h b/gfx/include/dxsdk/xapobase.h index a26bf77571..dfbb69da57 100644 --- a/gfx/include/dxsdk/xapobase.h +++ b/gfx/include/dxsdk/xapobase.h @@ -33,7 +33,6 @@ // default number of input and output buffers supported, applies to XAPO_LOCKFORPROCESS_BUFFER_PARAMETERS #define XAPOBASE_DEFAULT_BUFFER_COUNT 1 - //-------------------------------------------------------------// // assertion #if !defined(XAPOASSERT) @@ -51,15 +50,12 @@ #endif #endif - //-----------------------------------------------------// #pragma pack(push, 8) // set packing alignment to ensure consistency across arbitrary build environments, and ensure synchronization variables used by Interlocked functionality are correctly aligned - // primitive types typedef float FLOAT32; // 32-bit IEEE float - //// // DESCRIPTION: // Default implementation of the IXAPO and IUnknown interfaces. @@ -75,7 +71,6 @@ private: BOOL m_fIsScalarMatrix; // TRUE if m_pfl32MatrixCoefficients is diagonal matrix with all main diagonal entries equal, i.e. m_pfnMatrixMixFunction only used for type conversion (no channel conversion), used for thru processing BOOL m_fIsLocked; // TRUE if XAPO locked via CXAPOBase.LockForProcess - protected: LONG m_lReferenceCount; // COM reference count, must be aligned for atomic operations @@ -158,7 +153,6 @@ protected: const XAPO_REGISTRATION_PROPERTIES* GetRegistrationPropertiesInternal () { return m_pRegistrationProperties; } BOOL IsLocked () { return m_fIsLocked; } - public: CXAPOBase (const XAPO_REGISTRATION_PROPERTIES* pRegistrationProperties); virtual ~CXAPOBase (); @@ -248,10 +242,6 @@ public: STDMETHOD_(UINT32, CalcOutputFrames) (UINT32 InputFrameCount) { return InputFrameCount; } }; - - - - //--------------------------------------------------------------------------// //// // DESCRIPTION: @@ -274,7 +264,6 @@ private: BOOL m_fNewerResultsReady; // TRUE if there exists new processing results not yet picked up by GetParameters(), must be aligned for atomic operations BOOL m_fProducer; // TRUE if IXAPO::Process produces data to be returned by GetParameters(), SetParameters() and ParametersChanged() disallowed - public: //// // PARAMETERS: @@ -347,6 +336,5 @@ public: void EndProcess (); }; - #pragma pack(pop) // revert packing alignment //---------------------------------<-EOF->----------------------------------// diff --git a/gfx/include/dxsdk/xapofx.h b/gfx/include/dxsdk/xapofx.h index 02f8ab0f85..1ddaf9067b 100644 --- a/gfx/include/dxsdk/xapofx.h +++ b/gfx/include/dxsdk/xapofx.h @@ -34,13 +34,11 @@ class __declspec(uuid("C4137916-2BE1-46FD-8599-441536F49856")) FXMasteringLimite class __declspec(uuid("7D9ACA56-CB68-4807-B632-B137352E8596")) FXReverb; class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; - #if !defined(GUID_DEFS_ONLY) // ignore rest if only GUID definitions requested #include #include #include // float bounds - // EQ parameter bounds (inclusive), used with FXEQ: #define FXEQ_MIN_FRAMERATE 22000 #define FXEQ_MAX_FRAMERATE 48000 @@ -60,7 +58,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; #define FXEQ_MAX_BANDWIDTH 2.0f #define FXEQ_DEFAULT_BANDWIDTH 1.0f // all bands - // Mastering limiter parameter bounds (inclusive), used with FXMasteringLimiter: #define FXMASTERINGLIMITER_MIN_RELEASE 1 #define FXMASTERINGLIMITER_MAX_RELEASE 20 @@ -70,7 +67,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; #define FXMASTERINGLIMITER_MAX_LOUDNESS 1800 #define FXMASTERINGLIMITER_DEFAULT_LOUDNESS 1000 - // Reverb parameter bounds (inclusive), used with FXReverb: #define FXREVERB_MIN_DIFFUSION 0.0f #define FXREVERB_MAX_DIFFUSION 1.0f @@ -80,7 +76,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; #define FXREVERB_MAX_ROOMSIZE 1.0f #define FXREVERB_DEFAULT_ROOMSIZE 0.6f - // Echo initialization data/parameter bounds (inclusive), used with FXEcho: #define FXECHO_MIN_WETDRYMIX 0.0f #define FXECHO_MAX_WETDRYMIX 1.0f @@ -94,11 +89,9 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; #define FXECHO_MAX_DELAY 2000.0f #define FXECHO_DEFAULT_DELAY 500.0f - //-----------------------------------------------------// #pragma pack(push, 1) // set packing alignment to ensure consistency across arbitrary build environments - // EQ parameters (4 bands), used with IXAPOParameters::SetParameters: // The EQ supports only FLOAT32 audio foramts. // The framerate must be within [22000, 48000] Hz. @@ -117,7 +110,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; float Bandwidth3; } FXEQ_PARAMETERS; - // Mastering limiter parameters, used with IXAPOParameters::SetParameters: // The mastering limiter supports only FLOAT32 audio formats. typedef struct FXMASTERINGLIMITER_PARAMETERS { @@ -125,7 +117,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; UINT32 Loudness; // loudness target (threshold) } FXMASTERINGLIMITER_PARAMETERS; - // Reverb parameters, used with IXAPOParameters::SetParameters: // The reverb supports only FLOAT32 audio formats with the following // channel configurations: @@ -136,7 +127,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; float RoomSize; // room size } FXREVERB_PARAMETERS; - // Echo initialization data, used with CreateFX: // Use of this structure is optional, the default MaxDelay is FXECHO_DEFAULT_DELAY. typedef struct FXECHO_INITDATA { @@ -151,7 +141,6 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; float Delay; // delay (all channels) in milliseconds, must be within [FXECHO_MIN_DELAY, FXECHO_PARAMETERS.MaxDelay] } FXECHO_PARAMETERS; - //-------------------------------------------------------------// // function storage-class attribute and calltype @@ -167,14 +156,12 @@ class __declspec(uuid("5039D740-F736-449A-84D3-A56202557B87")) FXEcho; #define FX_IMP_(type) type STDMETHODVCALLTYPE - //-------------------------------------------------------// // creates instance of requested XAPO, use Release to free instance // pInitData - [in] effect-specific initialization parameters, may be NULL if InitDataByteSize == 0 // InitDataByteSize - [in] size of pInitData in bytes, may be 0 if pInitData is NULL FX_API_(HRESULT) CreateFX (REFCLSID clsid, _Outptr_ IUnknown** pEffect, _In_reads_bytes_opt_(InitDataByteSize) const void* pInitData=NULL, UINT32 InitDataByteSize=0); - #pragma pack(pop) // revert packing alignment #endif // !defined(GUID_DEFS_ONLY) diff --git a/gfx/include/dxsdk/xdsp.h b/gfx/include/dxsdk/xdsp.h index 6ed0dc546d..79dfda9da1 100644 --- a/gfx/include/dxsdk/xdsp.h +++ b/gfx/include/dxsdk/xdsp.h @@ -30,7 +30,6 @@ #include #endif - //-------------------------------------------------------------// // assertion #if !defined(DSPASSERT) @@ -46,13 +45,11 @@ #define ISPOWEROF2(n) ( ((n)&((n)-1)) == 0 && (n) != 0 ) #endif - //-----------------------------------------------------------// namespace XDSP { #pragma warning(push) #pragma warning(disable: 4328 4640) // disable "indirection alignment of formal parameter", "construction of local static object is not thread-safe" compile warnings - // Helper functions, used by the FFT functions. // The application need not call them directly. @@ -61,7 +58,6 @@ namespace XDSP { typedef XVECTOR& XVECTORREF; typedef const XVECTOR& XVECTORREFC; - // Parallel multiplication of four complex numbers, assuming // real and imaginary values are stored in separate vectors. __forceinline void vmulComplex (__out XVECTORREF rResult, __out XVECTORREF iResult, __in XVECTORREFC r1, __in XVECTORREFC i1, __in XVECTORREFC r2, __in XVECTORREFC i2) @@ -85,7 +81,6 @@ namespace XDSP { i1 = _mm_add_ps(vr1i2, vr2i1); // imaginary: (r1*i2 + r2*i1) } - // Radix-4 decimation-in-time FFT butterfly. // This version assumes that all four elements of the butterfly are // adjacent in a single vector. @@ -121,7 +116,6 @@ namespace XDSP { const static XVECTOR vDFT4SignBits2 = { 0.0f, 0.0f, -0.0f, -0.0f }; const static XVECTOR vDFT4SignBits3 = { 0.0f, -0.0f, -0.0f, 0.0f }; - // calculating Temp XVECTOR rTemp = _mm_add_ps( _mm_shuffle_ps(r1, r1, _MM_SHUFFLE(1, 1, 0, 0)), // [r1X| r1X|r1Y| r1Y] + _mm_xor_ps(_mm_shuffle_ps(r1, r1, _MM_SHUFFLE(3, 3, 2, 2)), vDFT4SignBits1) ); // [r1Z|-r1Z|r1W|-r1W] @@ -178,7 +172,6 @@ namespace XDSP { XVECTOR rTemp0, rTemp1, rTemp2, rTemp3, rTemp4, rTemp5, rTemp6, rTemp7; XVECTOR iTemp0, iTemp1, iTemp2, iTemp3, iTemp4, iTemp5, iTemp6, iTemp7; - // calculating Temp rTemp0 = _mm_add_ps(r0, r2); iTemp0 = _mm_add_ps(i0, i2); rTemp2 = _mm_add_ps(r1, r3); iTemp2 = _mm_add_ps(i1, i3); @@ -201,7 +194,6 @@ namespace XDSP { ButterflyDIT4_1(rTemp7, iTemp7); } - r0 = rTemp4; i0 = iTemp4; r1 = rTemp5; i1 = iTemp5; r2 = rTemp6; i2 = iTemp6; @@ -235,8 +227,6 @@ namespace XDSP { } } - - //// // DESCRIPTION: // 8-sample FFT. @@ -262,7 +252,6 @@ namespace XDSP { static XVECTOR wr2 = { -1.0f, -0.70710677f, 0.0f, 0.70710677f }; static XVECTOR wi2 = { 0.0f, 0.70710677f, 1.0f, 0.70710677f }; - for (UINT32 uIndex=0; uIndex>2); ++uIndex) { const UINT32 n = ((uIndex & uStrideInvMask) << 2) + (uIndex & uStrideMask); ButterflyDIT4_4(pReal[n], @@ -385,7 +368,6 @@ namespace XDSP { uStride, FALSE); } - if (uLength > 16*4) { FFT(pReal, pImaginary, pUnityTable+(uLength>>1), uLength>>2, uCount*4); } else if (uLength == 16*4) { @@ -423,7 +405,6 @@ inline void FFTInitializeUnityTable (__out_ecount(uLength) XVECTOR* __restrict p FLOAT32* __restrict pfUnityTable = (FLOAT32* __restrict)pUnityTable; - // initialize unity table for recursive FFT lengths: uLength, uLength/4, uLength/16... > 16 do { FLOAT32 flStep = 6.283185307f / uLength; // 2PI / FFT length @@ -442,7 +423,6 @@ inline void FFTInitializeUnityTable (__out_ecount(uLength) XVECTOR* __restrict p } while (uLength > 16); } - //// // DESCRIPTION: // The FFT functions generate output in bit reversed order. @@ -468,7 +448,6 @@ inline void FFTUnswizzle (__out_ecount((1< 1) { Deinterleave(vRealTemp, pReal, uChannelCount, uLength); } else { @@ -680,7 +645,6 @@ inline void FFTInterleaved (__inout_ecount((1<>2); u++) { @@ -747,7 +710,6 @@ inline void IFFTDeinterleaved (__inout_ecount((1<----------------------------------// diff --git a/gfx/include/dxsdk/xma2defs.h b/gfx/include/dxsdk/xma2defs.h index 13a4306cb8..b1a9767344 100644 --- a/gfx/include/dxsdk/xma2defs.h +++ b/gfx/include/dxsdk/xma2defs.h @@ -14,7 +14,6 @@ #include // For S_OK, E_FAIL #include // Basic data types and constants for audio work - /*************************************************************************** * Overview ***************************************************************************/ @@ -70,7 +69,6 @@ // blocks, all the same size (as specified in XMA2WAVEFORMAT.BlockSizeInBytes) // except for the last one, which may be shorter. - // MULTICHANNEL AUDIO: the XMA decoder can only decode raw XMA data into either // mono or stereo PCM data. In order to encode a 6-channel file (say), the file // must be deinterleaved into 3 stereo streams that are encoded independently, @@ -94,7 +92,6 @@ // its first 15 bits; see XMAFRAME below). The GetXmaFrameBitPosition function // uses this technique. - // SEEKING IN XMA2 FILES: Here is some pseudocode to find the byte position and // subframe in an XMA2 file which will contain sample S when decoded. // @@ -128,8 +125,6 @@ // Step 1 can be performed using the GetXmaBlockContainingSample function below, // and steps 2-4 by calling GetXmaDecodePositionForSample once for each stream. - - /*************************************************************************** * XMA constants ***************************************************************************/ @@ -171,8 +166,6 @@ #define XMA_MAX_LOOPCOUNT 254u #define XMA_INFINITE_LOOP 255u - - /*************************************************************************** * XMA format structures ***************************************************************************/ @@ -210,7 +203,6 @@ typedef struct XMA2WAVEFORMATEX WORD BlockCount; // XMA blocks in file (and entries in its seek table) } XMA2WAVEFORMATEX, *PXMA2WAVEFORMATEX; - // The legacy XMA format structures are described here for reference, but they // should not be used in new content. XMAWAVEFORMAT was the structure used in // XMA version 1 files. XMA2WAVEFORMAT was used in early XMA2 files; it is not @@ -232,7 +224,6 @@ typedef struct XMA2WAVEFORMATEX #define XMA_SPEAKER_RIGHT_BACK 0x80 #endif - // Used in XMAWAVEFORMAT for per-stream data typedef struct XMASTREAMFORMAT { @@ -267,7 +258,6 @@ typedef struct XMAWAVEFORMAT // array length is in the NumStreams field. } XMAWAVEFORMAT; - // Used in XMA2WAVEFORMAT for per-stream data typedef struct XMA2STREAMFORMAT { @@ -303,8 +293,6 @@ typedef struct XMA2WAVEFORMAT #endif // #ifndef WAVE_FORMAT_XMA - - /*************************************************************************** * XMA packet structure (in big-endian form) ***************************************************************************/ @@ -327,7 +315,6 @@ typedef struct XMA2PACKET // | |_____________________ First frame starts 527 bits into packet // |________________________________ Packet contains 12 frames - // Helper functions to extract the fields above from an XMA packet. (Note that // the bitfields cannot be read directly on little-endian architectures such as // the Intel x86, as they are laid out in big-endian form.) @@ -354,8 +341,6 @@ __inline DWORD GetXmaPacketSkipCount(__in_bcount(4) const BYTE* pPacket) return (DWORD)(pPacket[3]); } - - /*************************************************************************** * XMA frame structure ***************************************************************************/ @@ -376,8 +361,6 @@ __inline DWORD GetXmaPacketSkipCount(__in_bcount(4) const BYTE* pPacket) // Special LengthInBits value that marks an invalid final frame #define XMA_FINAL_FRAME_MARKER 0x7FFF - - /*************************************************************************** * XMA helper functions ***************************************************************************/ @@ -392,7 +375,6 @@ __inline DWORD GetXmaPacketSkipCount(__in_bcount(4) const BYTE* pPacket) #endif #endif - // GetXmaBlockContainingSample: Use a given seek table to find the XMA block // containing a given decoded sample. Note that the seek table entries in an // XMA file are stored in big-endian form and may need to be converted prior @@ -430,7 +412,6 @@ __inline HRESULT GetXmaBlockContainingSample return E_FAIL; } - // GetXmaFrameLengthInBits: Reads a given frame's LengthInBits field. __inline DWORD GetXmaFrameLengthInBits @@ -459,7 +440,6 @@ __inline DWORD GetXmaFrameLengthInBits } } - // GetXmaFrameBitPosition: Calculates the bit offset of a given frame within // an XMA block or set of blocks. Returns 0 on failure. @@ -523,7 +503,6 @@ __inline DWORD GetXmaFrameBitPosition } } - // GetLastXmaFrameBitPosition: Calculates the bit offset of the last complete // frame in an XMA block or set of blocks. @@ -582,7 +561,6 @@ __inline DWORD GetLastXmaFrameBitPosition return (DWORD)(pLastPacket - pXmaData) * 8 + nFrameBitOffset; } - // GetXmaDecodePositionForSample: Obtains the information needed to make the // decoder generate audio starting at a given sample position relative to the // beginning of the given XMA block: the bit offset of the appropriate frame, @@ -619,7 +597,6 @@ __inline HRESULT GetXmaDecodePositionForSample } } - // GetXmaSampleRate: Obtains the legal XMA sample rate (24, 32, 44.1 or 48Khz) // corresponding to a generic sample rate. @@ -634,7 +611,6 @@ __inline DWORD GetXmaSampleRate(DWORD dwGeneralRate) return dwXmaRate; } - // Functions to convert between WAVEFORMATEXTENSIBLE channel masks (combinations // of the SPEAKER_xxx flags defined in audiodefs.h) and XMA channel masks (which // are limited to eight possible speaker positions: left, right, center, low @@ -672,7 +648,6 @@ __inline BYTE GetXmaChannelMaskFromStandardMask(DWORD dwStandardMask) return bXmaMask; } - // LocalizeXma2Format: Modifies a XMA2WAVEFORMATEX structure in place to comply // with the current platform's byte-ordering rules (little- or big-endian). @@ -714,5 +689,4 @@ __inline HRESULT LocalizeXma2Format(__inout XMA2WAVEFORMATEX* pXma2Format) #undef XMASWAP4BYTES } - #endif // #ifndef __XMA2DEFS_INCLUDED__ diff --git a/gfx/include/dxsdk/xnamath.h b/gfx/include/dxsdk/xnamath.h index daaba0b559..df496e1aa8 100644 --- a/gfx/include/dxsdk/xnamath.h +++ b/gfx/include/dxsdk/xnamath.h @@ -56,7 +56,6 @@ Abstract: #error xnamath.h only supports x86, x64, or XBox 360 targets #endif - #if defined(_XM_SSE_INTRINSICS_) #ifndef _XM_NO_INTRINSICS_ #include @@ -111,7 +110,6 @@ Abstract: #define _DECLSPEC_ALIGN_16_ #endif - #if defined(_MSC_VER) && (_MSC_VER<1500) && (_MSC_VER>=1400) #define _XM_ISVS2005_ #endif @@ -169,7 +167,6 @@ XMFINLINE FLOAT XMConvertToDegrees(FLOAT fRadians) { return fRadians * (180.0f / #define XMComparisonAllInBounds(CR) (((CR) & XM_CRMASK_CR6BOUNDS) == XM_CRMASK_CR6BOUNDS) #define XMComparisonAnyOutOfBounds(CR) (((CR) & XM_CRMASK_CR6BOUNDS) != XM_CRMASK_CR6BOUNDS) - #define XMMin(a, b) (((a) < (b)) ? (a) : (b)) #define XMMax(a, b) (((a) > (b)) ? (a) : (b)) @@ -1882,7 +1879,6 @@ typedef __declspec(align(16)) XMFLOAT4X4 XMFLOAT4X4A; #pragma warning(pop) - /**************************************************************************** * * Data conversion operations @@ -2246,7 +2242,6 @@ XMVECTOR XMVectorBaryCentricV(FXMVECTOR Position0, FXMVECTOR Position1, F * ****************************************************************************/ - BOOL XMVector2Equal(FXMVECTOR V1, FXMVECTOR V2); UINT XMVector2EqualR(FXMVECTOR V1, FXMVECTOR V2); BOOL XMVector2EqualInt(FXMVECTOR V1, FXMVECTOR V2); @@ -2312,7 +2307,6 @@ XMFLOAT2* XMVector2TransformNormalStream(_Out_bytecap_x_(sizeof(XMFLOAT2)+ * ****************************************************************************/ - BOOL XMVector3Equal(FXMVECTOR V1, FXMVECTOR V2); UINT XMVector3EqualR(FXMVECTOR V1, FXMVECTOR V2); BOOL XMVector3EqualInt(FXMVECTOR V1, FXMVECTOR V2); diff --git a/gfx/include/pixman/pixman-private.h b/gfx/include/pixman/pixman-private.h index 02c286abb7..6dd6b1eb17 100644 --- a/gfx/include/pixman/pixman-private.h +++ b/gfx/include/pixman/pixman-private.h @@ -640,7 +640,6 @@ _pixman_choose_implementation (void); pixman_bool_t _pixman_disabled (const char *name); - /* * Utilities */ diff --git a/gfx/include/vulkan/vk_platform.h b/gfx/include/vulkan/vk_platform.h index 802e77a6f3..a27dcc5fb9 100644 --- a/gfx/include/vulkan/vk_platform.h +++ b/gfx/include/vulkan/vk_platform.h @@ -16,7 +16,6 @@ ** limitations under the License. */ - #ifndef VK_PLATFORM_H_ #define VK_PLATFORM_H_ diff --git a/gfx/include/vulkan/vulkan.h b/gfx/include/vulkan/vulkan.h index f874647c10..5610f05c31 100644 --- a/gfx/include/vulkan/vulkan.h +++ b/gfx/include/vulkan/vulkan.h @@ -24,52 +24,43 @@ #include "vulkan_android.h" #endif - #ifdef VK_USE_PLATFORM_IOS_MVK #include "vulkan_ios.h" #endif - #ifdef VK_USE_PLATFORM_MACOS_MVK #include "vulkan_macos.h" #endif - #ifdef VK_USE_PLATFORM_MIR_KHR #include #include "vulkan_mir.h" #endif - #ifdef VK_USE_PLATFORM_VI_NN #include "vulkan_vi.h" #endif - #ifdef VK_USE_PLATFORM_WAYLAND_KHR #include #include "vulkan_wayland.h" #endif - #ifdef VK_USE_PLATFORM_WIN32_KHR #include #include "vulkan_win32.h" #endif - #ifdef VK_USE_PLATFORM_XCB_KHR #include #include "vulkan_xcb.h" #endif - #ifdef VK_USE_PLATFORM_XLIB_KHR #include #include "vulkan_xlib.h" #endif - #ifdef VK_USE_PLATFORM_XLIB_XRANDR_EXT #include #include diff --git a/gfx/include/vulkan/vulkan_android.h b/gfx/include/vulkan/vulkan_android.h index 07aaeda28e..967ade544a 100644 --- a/gfx/include/vulkan/vulkan_android.h +++ b/gfx/include/vulkan/vulkan_android.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_android_surface 1 struct ANativeWindow; @@ -42,7 +41,6 @@ typedef struct VkAndroidSurfaceCreateInfoKHR { struct ANativeWindow* window; } VkAndroidSurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateAndroidSurfaceKHR)(VkInstance instance, const VkAndroidSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); #ifndef VK_NO_PROTOTYPES @@ -103,7 +101,6 @@ typedef struct VkExternalFormatANDROID { uint64_t externalFormat; } VkExternalFormatANDROID; - typedef VkResult (VKAPI_PTR *PFN_vkGetAndroidHardwareBufferPropertiesANDROID)(VkDevice device, const struct AHardwareBuffer* buffer, VkAndroidHardwareBufferPropertiesANDROID* pProperties); typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryAndroidHardwareBufferANDROID)(VkDevice device, const VkMemoryGetAndroidHardwareBufferInfoANDROID* pInfo, struct AHardwareBuffer** pBuffer); diff --git a/gfx/include/vulkan/vulkan_core.h b/gfx/include/vulkan/vulkan_core.h index d088c26bab..1b65ab4310 100644 --- a/gfx/include/vulkan/vulkan_core.h +++ b/gfx/include/vulkan/vulkan_core.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_VERSION_1_0 1 #include "vk_platform.h" @@ -47,14 +46,11 @@ extern "C" { /* Version of this file */ #define VK_HEADER_VERSION 73 - #define VK_NULL_HANDLE 0 - #define VK_DEFINE_HANDLE(object) typedef struct object##_T* object; - #if !defined(VK_DEFINE_NON_DISPATCHABLE_HANDLE) #if defined(__LP64__) || defined(_WIN64) || (defined(__x86_64__) && !defined(__ILP32__) ) || defined(_M_X64) || defined(__ia64) || defined (_M_IA64) || defined(__aarch64__) || defined(__powerpc64__) #define VK_DEFINE_NON_DISPATCHABLE_HANDLE(object) typedef struct object##_T *object; @@ -64,7 +60,6 @@ extern "C" { #endif - typedef uint32_t VkFlags; typedef uint32_t VkBool32; typedef uint64_t VkDeviceSize; @@ -112,7 +107,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkCommandPool) #define VK_MAX_EXTENSION_NAME_SIZE 256 #define VK_MAX_DESCRIPTION_SIZE 256 - typedef enum VkPipelineCacheHeaderVersion { VK_PIPELINE_CACHE_HEADER_VERSION_ONE = 1, VK_PIPELINE_CACHE_HEADER_VERSION_BEGIN_RANGE = VK_PIPELINE_CACHE_HEADER_VERSION_ONE, @@ -2717,7 +2711,6 @@ typedef struct VkDrawIndirectCommand { uint32_t firstInstance; } VkDrawIndirectCommand; - typedef VkResult (VKAPI_PTR *PFN_vkCreateInstance)(const VkInstanceCreateInfo* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkInstance* pInstance); typedef void (VKAPI_PTR *PFN_vkDestroyInstance)(VkInstance instance, const VkAllocationCallbacks* pAllocator); typedef VkResult (VKAPI_PTR *PFN_vkEnumeratePhysicalDevices)(VkInstance instance, uint32_t* pPhysicalDeviceCount, VkPhysicalDevice* pPhysicalDevices); @@ -3666,7 +3659,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDescriptorUpdateTemplate) #define VK_LUID_SIZE 8 #define VK_QUEUE_FAMILY_EXTERNAL (~0U-1) - typedef enum VkPointClippingBehavior { VK_POINT_CLIPPING_BEHAVIOR_ALL_CLIP_PLANES = 0, VK_POINT_CLIPPING_BEHAVIOR_USER_CLIP_PLANES_ONLY = 1, @@ -3738,7 +3730,6 @@ typedef enum VkDescriptorUpdateTemplateType { VK_DESCRIPTOR_UPDATE_TEMPLATE_TYPE_MAX_ENUM = 0x7FFFFFFF } VkDescriptorUpdateTemplateType; - typedef enum VkSubgroupFeatureFlagBits { VK_SUBGROUP_FEATURE_BASIC_BIT = 0x00000001, VK_SUBGROUP_FEATURE_VOTE_BIT = 0x00000002, @@ -4353,7 +4344,6 @@ typedef struct VkPhysicalDeviceShaderDrawParameterFeatures { VkBool32 shaderDrawParameters; } VkPhysicalDeviceShaderDrawParameterFeatures; - typedef VkResult (VKAPI_PTR *PFN_vkEnumerateInstanceVersion)(uint32_t* pApiVersion); typedef VkResult (VKAPI_PTR *PFN_vkBindBufferMemory2)(VkDevice device, uint32_t bindInfoCount, const VkBindBufferMemoryInfo* pBindInfos); typedef VkResult (VKAPI_PTR *PFN_vkBindImageMemory2)(VkDevice device, uint32_t bindInfoCount, const VkBindImageMemoryInfo* pBindInfos); @@ -4537,7 +4527,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkSurfaceKHR) #define VK_KHR_SURFACE_EXTENSION_NAME "VK_KHR_surface" #define VK_COLORSPACE_SRGB_NONLINEAR_KHR VK_COLOR_SPACE_SRGB_NONLINEAR_KHR - typedef enum VkColorSpaceKHR { VK_COLOR_SPACE_SRGB_NONLINEAR_KHR = 0, VK_COLOR_SPACE_DISPLAY_P3_NONLINEAR_EXT = 1000104001, @@ -4573,7 +4562,6 @@ typedef enum VkPresentModeKHR { VK_PRESENT_MODE_MAX_ENUM_KHR = 0x7FFFFFFF } VkPresentModeKHR; - typedef enum VkSurfaceTransformFlagBitsKHR { VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR = 0x00000001, VK_SURFACE_TRANSFORM_ROTATE_90_BIT_KHR = 0x00000002, @@ -4615,7 +4603,6 @@ typedef struct VkSurfaceFormatKHR { VkColorSpaceKHR colorSpace; } VkSurfaceFormatKHR; - typedef void (VKAPI_PTR *PFN_vkDestroySurfaceKHR)(VkInstance instance, VkSurfaceKHR surface, const VkAllocationCallbacks* pAllocator); typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, VkSurfaceKHR surface, VkBool32* pSupported); typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceCapabilitiesKHR)(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface, VkSurfaceCapabilitiesKHR* pSurfaceCapabilities); @@ -4658,7 +4645,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkSwapchainKHR) #define VK_KHR_SWAPCHAIN_SPEC_VERSION 70 #define VK_KHR_SWAPCHAIN_EXTENSION_NAME "VK_KHR_swapchain" - typedef enum VkSwapchainCreateFlagBitsKHR { VK_SWAPCHAIN_CREATE_SPLIT_INSTANCE_BIND_REGIONS_BIT_KHR = 0x00000001, VK_SWAPCHAIN_CREATE_PROTECTED_BIT_KHR = 0x00000002, @@ -4751,7 +4737,6 @@ typedef struct VkDeviceGroupSwapchainCreateInfoKHR { VkDeviceGroupPresentModeFlagsKHR modes; } VkDeviceGroupSwapchainCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateSwapchainKHR)(VkDevice device, const VkSwapchainCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSwapchainKHR* pSwapchain); typedef void (VKAPI_PTR *PFN_vkDestroySwapchainKHR)(VkDevice device, VkSwapchainKHR swapchain, const VkAllocationCallbacks* pAllocator); typedef VkResult (VKAPI_PTR *PFN_vkGetSwapchainImagesKHR)(VkDevice device, VkSwapchainKHR swapchain, uint32_t* pSwapchainImageCount, VkImage* pSwapchainImages); @@ -4820,7 +4805,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDisplayModeKHR) #define VK_KHR_DISPLAY_SPEC_VERSION 21 #define VK_KHR_DISPLAY_EXTENSION_NAME "VK_KHR_display" - typedef enum VkDisplayPlaneAlphaFlagBitsKHR { VK_DISPLAY_PLANE_ALPHA_OPAQUE_BIT_KHR = 0x00000001, VK_DISPLAY_PLANE_ALPHA_GLOBAL_BIT_KHR = 0x00000002, @@ -4889,7 +4873,6 @@ typedef struct VkDisplaySurfaceCreateInfoKHR { VkExtent2D imageExtent; } VkDisplaySurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceDisplayPropertiesKHR)(VkPhysicalDevice physicalDevice, uint32_t* pPropertyCount, VkDisplayPropertiesKHR* pProperties); typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceDisplayPlanePropertiesKHR)(VkPhysicalDevice physicalDevice, uint32_t* pPropertyCount, VkDisplayPlanePropertiesKHR* pProperties); typedef VkResult (VKAPI_PTR *PFN_vkGetDisplayPlaneSupportedDisplaysKHR)(VkPhysicalDevice physicalDevice, uint32_t planeIndex, uint32_t* pDisplayCount, VkDisplayKHR* pDisplays); @@ -4953,7 +4936,6 @@ typedef struct VkDisplayPresentInfoKHR { VkBool32 persistent; } VkDisplayPresentInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateSharedSwapchainsKHR)(VkDevice device, uint32_t swapchainCount, const VkSwapchainCreateInfoKHR* pCreateInfos, const VkAllocationCallbacks* pAllocator, VkSwapchainKHR* pSwapchains); #ifndef VK_NO_PROTOTYPES @@ -4969,7 +4951,6 @@ VKAPI_ATTR VkResult VKAPI_CALL vkCreateSharedSwapchainsKHR( #define VK_KHR_SAMPLER_MIRROR_CLAMP_TO_EDGE_SPEC_VERSION 1 #define VK_KHR_SAMPLER_MIRROR_CLAMP_TO_EDGE_EXTENSION_NAME "VK_KHR_sampler_mirror_clamp_to_edge" - #define VK_KHR_multiview 1 #define VK_KHR_MULTIVIEW_SPEC_VERSION 1 #define VK_KHR_MULTIVIEW_EXTENSION_NAME "VK_KHR_multiview" @@ -4980,8 +4961,6 @@ typedef VkPhysicalDeviceMultiviewFeatures VkPhysicalDeviceMultiviewFeaturesKHR; typedef VkPhysicalDeviceMultiviewProperties VkPhysicalDeviceMultiviewPropertiesKHR; - - #define VK_KHR_get_physical_device_properties2 1 #define VK_KHR_GET_PHYSICAL_DEVICE_PROPERTIES_2_SPEC_VERSION 1 #define VK_KHR_GET_PHYSICAL_DEVICE_PROPERTIES_2_EXTENSION_NAME "VK_KHR_get_physical_device_properties2" @@ -5004,7 +4983,6 @@ typedef VkSparseImageFormatProperties2 VkSparseImageFormatProperties2KHR; typedef VkPhysicalDeviceSparseImageFormatInfo2 VkPhysicalDeviceSparseImageFormatInfo2KHR; - typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceFeatures2KHR)(VkPhysicalDevice physicalDevice, VkPhysicalDeviceFeatures2* pFeatures); typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceProperties2KHR)(VkPhysicalDevice physicalDevice, VkPhysicalDeviceProperties2* pProperties); typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceFormatProperties2KHR)(VkPhysicalDevice physicalDevice, VkFormat format, VkFormatProperties2* pFormatProperties); @@ -5060,7 +5038,6 @@ typedef VkMemoryAllocateFlags VkMemoryAllocateFlagsKHR; typedef VkMemoryAllocateFlagBits VkMemoryAllocateFlagBitsKHR; - typedef VkMemoryAllocateFlagsInfo VkMemoryAllocateFlagsInfoKHR; typedef VkDeviceGroupRenderPassBeginInfo VkDeviceGroupRenderPassBeginInfoKHR; @@ -5075,7 +5052,6 @@ typedef VkBindBufferMemoryDeviceGroupInfo VkBindBufferMemoryDeviceGroupInfoKHR; typedef VkBindImageMemoryDeviceGroupInfo VkBindImageMemoryDeviceGroupInfoKHR; - typedef void (VKAPI_PTR *PFN_vkGetDeviceGroupPeerMemoryFeaturesKHR)(VkDevice device, uint32_t heapIndex, uint32_t localDeviceIndex, uint32_t remoteDeviceIndex, VkPeerMemoryFeatureFlags* pPeerMemoryFeatures); typedef void (VKAPI_PTR *PFN_vkCmdSetDeviceMaskKHR)(VkCommandBuffer commandBuffer, uint32_t deviceMask); typedef void (VKAPI_PTR *PFN_vkCmdDispatchBaseKHR)(VkCommandBuffer commandBuffer, uint32_t baseGroupX, uint32_t baseGroupY, uint32_t baseGroupZ, uint32_t groupCountX, uint32_t groupCountY, uint32_t groupCountZ); @@ -5106,14 +5082,12 @@ VKAPI_ATTR void VKAPI_CALL vkCmdDispatchBaseKHR( #define VK_KHR_SHADER_DRAW_PARAMETERS_SPEC_VERSION 1 #define VK_KHR_SHADER_DRAW_PARAMETERS_EXTENSION_NAME "VK_KHR_shader_draw_parameters" - #define VK_KHR_maintenance1 1 #define VK_KHR_MAINTENANCE1_SPEC_VERSION 2 #define VK_KHR_MAINTENANCE1_EXTENSION_NAME "VK_KHR_maintenance1" typedef VkCommandPoolTrimFlags VkCommandPoolTrimFlagsKHR; - typedef void (VKAPI_PTR *PFN_vkTrimCommandPoolKHR)(VkDevice device, VkCommandPool commandPool, VkCommandPoolTrimFlags flags); #ifndef VK_NO_PROTOTYPES @@ -5132,7 +5106,6 @@ typedef VkPhysicalDeviceGroupProperties VkPhysicalDeviceGroupPropertiesKHR; typedef VkDeviceGroupDeviceCreateInfo VkDeviceGroupDeviceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkEnumeratePhysicalDeviceGroupsKHR)(VkInstance instance, uint32_t* pPhysicalDeviceGroupCount, VkPhysicalDeviceGroupProperties* pPhysicalDeviceGroupProperties); #ifndef VK_NO_PROTOTYPES @@ -5155,7 +5128,6 @@ typedef VkExternalMemoryFeatureFlags VkExternalMemoryFeatureFlagsKHR; typedef VkExternalMemoryFeatureFlagBits VkExternalMemoryFeatureFlagBitsKHR; - typedef VkExternalMemoryProperties VkExternalMemoryPropertiesKHR; typedef VkPhysicalDeviceExternalImageFormatInfo VkPhysicalDeviceExternalImageFormatInfoKHR; @@ -5168,7 +5140,6 @@ typedef VkExternalBufferProperties VkExternalBufferPropertiesKHR; typedef VkPhysicalDeviceIDProperties VkPhysicalDeviceIDPropertiesKHR; - typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceExternalBufferPropertiesKHR)(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceExternalBufferInfo* pExternalBufferInfo, VkExternalBufferProperties* pExternalBufferProperties); #ifndef VK_NO_PROTOTYPES @@ -5189,8 +5160,6 @@ typedef VkExternalMemoryBufferCreateInfo VkExternalMemoryBufferCreateInfoKHR; typedef VkExportMemoryAllocateInfo VkExportMemoryAllocateInfoKHR; - - #define VK_KHR_external_memory_fd 1 #define VK_KHR_EXTERNAL_MEMORY_FD_SPEC_VERSION 1 #define VK_KHR_EXTERNAL_MEMORY_FD_EXTENSION_NAME "VK_KHR_external_memory_fd" @@ -5215,7 +5184,6 @@ typedef struct VkMemoryGetFdInfoKHR { VkExternalMemoryHandleTypeFlagBits handleType; } VkMemoryGetFdInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryFdKHR)(VkDevice device, const VkMemoryGetFdInfoKHR* pGetFdInfo, int* pFd); typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryFdPropertiesKHR)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, int fd, VkMemoryFdPropertiesKHR* pMemoryFdProperties); @@ -5244,12 +5212,10 @@ typedef VkExternalSemaphoreFeatureFlags VkExternalSemaphoreFeatureFlagsKHR; typedef VkExternalSemaphoreFeatureFlagBits VkExternalSemaphoreFeatureFlagBitsKHR; - typedef VkPhysicalDeviceExternalSemaphoreInfo VkPhysicalDeviceExternalSemaphoreInfoKHR; typedef VkExternalSemaphoreProperties VkExternalSemaphorePropertiesKHR; - typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceExternalSemaphorePropertiesKHR)(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceExternalSemaphoreInfo* pExternalSemaphoreInfo, VkExternalSemaphoreProperties* pExternalSemaphoreProperties); #ifndef VK_NO_PROTOTYPES @@ -5267,11 +5233,8 @@ typedef VkSemaphoreImportFlags VkSemaphoreImportFlagsKHR; typedef VkSemaphoreImportFlagBits VkSemaphoreImportFlagBitsKHR; - typedef VkExportSemaphoreCreateInfo VkExportSemaphoreCreateInfoKHR; - - #define VK_KHR_external_semaphore_fd 1 #define VK_KHR_EXTERNAL_SEMAPHORE_FD_SPEC_VERSION 1 #define VK_KHR_EXTERNAL_SEMAPHORE_FD_EXTENSION_NAME "VK_KHR_external_semaphore_fd" @@ -5292,7 +5255,6 @@ typedef struct VkSemaphoreGetFdInfoKHR { VkExternalSemaphoreHandleTypeFlagBits handleType; } VkSemaphoreGetFdInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkImportSemaphoreFdKHR)(VkDevice device, const VkImportSemaphoreFdInfoKHR* pImportSemaphoreFdInfo); typedef VkResult (VKAPI_PTR *PFN_vkGetSemaphoreFdKHR)(VkDevice device, const VkSemaphoreGetFdInfoKHR* pGetFdInfo, int* pFd); @@ -5317,7 +5279,6 @@ typedef struct VkPhysicalDevicePushDescriptorPropertiesKHR { uint32_t maxPushDescriptors; } VkPhysicalDevicePushDescriptorPropertiesKHR; - typedef void (VKAPI_PTR *PFN_vkCmdPushDescriptorSetKHR)(VkCommandBuffer commandBuffer, VkPipelineBindPoint pipelineBindPoint, VkPipelineLayout layout, uint32_t set, uint32_t descriptorWriteCount, const VkWriteDescriptorSet* pDescriptorWrites); typedef void (VKAPI_PTR *PFN_vkCmdPushDescriptorSetWithTemplateKHR)(VkCommandBuffer commandBuffer, VkDescriptorUpdateTemplate descriptorUpdateTemplate, VkPipelineLayout layout, uint32_t set, const void* pData); @@ -5344,8 +5305,6 @@ VKAPI_ATTR void VKAPI_CALL vkCmdPushDescriptorSetWithTemplateKHR( typedef VkPhysicalDevice16BitStorageFeatures VkPhysicalDevice16BitStorageFeaturesKHR; - - #define VK_KHR_incremental_present 1 #define VK_KHR_INCREMENTAL_PRESENT_SPEC_VERSION 1 #define VK_KHR_INCREMENTAL_PRESENT_EXTENSION_NAME "VK_KHR_incremental_present" @@ -5368,26 +5327,20 @@ typedef struct VkPresentRegionsKHR { const VkPresentRegionKHR* pRegions; } VkPresentRegionsKHR; - - #define VK_KHR_descriptor_update_template 1 typedef VkDescriptorUpdateTemplate VkDescriptorUpdateTemplateKHR; - #define VK_KHR_DESCRIPTOR_UPDATE_TEMPLATE_SPEC_VERSION 1 #define VK_KHR_DESCRIPTOR_UPDATE_TEMPLATE_EXTENSION_NAME "VK_KHR_descriptor_update_template" typedef VkDescriptorUpdateTemplateType VkDescriptorUpdateTemplateTypeKHR; - typedef VkDescriptorUpdateTemplateCreateFlags VkDescriptorUpdateTemplateCreateFlagsKHR; - typedef VkDescriptorUpdateTemplateEntry VkDescriptorUpdateTemplateEntryKHR; typedef VkDescriptorUpdateTemplateCreateInfo VkDescriptorUpdateTemplateCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateDescriptorUpdateTemplateKHR)(VkDevice device, const VkDescriptorUpdateTemplateCreateInfo* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkDescriptorUpdateTemplate* pDescriptorUpdateTemplate); typedef void (VKAPI_PTR *PFN_vkDestroyDescriptorUpdateTemplateKHR)(VkDevice device, VkDescriptorUpdateTemplate descriptorUpdateTemplate, const VkAllocationCallbacks* pAllocator); typedef void (VKAPI_PTR *PFN_vkUpdateDescriptorSetWithTemplateKHR)(VkDevice device, VkDescriptorSet descriptorSet, VkDescriptorUpdateTemplate descriptorUpdateTemplate, const void* pData); @@ -5421,7 +5374,6 @@ typedef struct VkSharedPresentSurfaceCapabilitiesKHR { VkImageUsageFlags sharedPresentSupportedUsageFlags; } VkSharedPresentSurfaceCapabilitiesKHR; - typedef VkResult (VKAPI_PTR *PFN_vkGetSwapchainStatusKHR)(VkDevice device, VkSwapchainKHR swapchain); #ifndef VK_NO_PROTOTYPES @@ -5442,12 +5394,10 @@ typedef VkExternalFenceFeatureFlags VkExternalFenceFeatureFlagsKHR; typedef VkExternalFenceFeatureFlagBits VkExternalFenceFeatureFlagBitsKHR; - typedef VkPhysicalDeviceExternalFenceInfo VkPhysicalDeviceExternalFenceInfoKHR; typedef VkExternalFenceProperties VkExternalFencePropertiesKHR; - typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceExternalFencePropertiesKHR)(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceExternalFenceInfo* pExternalFenceInfo, VkExternalFenceProperties* pExternalFenceProperties); #ifndef VK_NO_PROTOTYPES @@ -5465,11 +5415,8 @@ typedef VkFenceImportFlags VkFenceImportFlagsKHR; typedef VkFenceImportFlagBits VkFenceImportFlagBitsKHR; - typedef VkExportFenceCreateInfo VkExportFenceCreateInfoKHR; - - #define VK_KHR_external_fence_fd 1 #define VK_KHR_EXTERNAL_FENCE_FD_SPEC_VERSION 1 #define VK_KHR_EXTERNAL_FENCE_FD_EXTENSION_NAME "VK_KHR_external_fence_fd" @@ -5490,7 +5437,6 @@ typedef struct VkFenceGetFdInfoKHR { VkExternalFenceHandleTypeFlagBits handleType; } VkFenceGetFdInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkImportFenceFdKHR)(VkDevice device, const VkImportFenceFdInfoKHR* pImportFenceFdInfo); typedef VkResult (VKAPI_PTR *PFN_vkGetFenceFdKHR)(VkDevice device, const VkFenceGetFdInfoKHR* pGetFdInfo, int* pFd); @@ -5513,7 +5459,6 @@ typedef VkPointClippingBehavior VkPointClippingBehaviorKHR; typedef VkTessellationDomainOrigin VkTessellationDomainOriginKHR; - typedef VkPhysicalDevicePointClippingProperties VkPhysicalDevicePointClippingPropertiesKHR; typedef VkRenderPassInputAttachmentAspectCreateInfo VkRenderPassInputAttachmentAspectCreateInfoKHR; @@ -5524,8 +5469,6 @@ typedef VkImageViewUsageCreateInfo VkImageViewUsageCreateInfoKHR; typedef VkPipelineTessellationDomainOriginStateCreateInfo VkPipelineTessellationDomainOriginStateCreateInfoKHR; - - #define VK_KHR_get_surface_capabilities2 1 #define VK_KHR_GET_SURFACE_CAPABILITIES_2_SPEC_VERSION 1 #define VK_KHR_GET_SURFACE_CAPABILITIES_2_EXTENSION_NAME "VK_KHR_get_surface_capabilities2" @@ -5548,7 +5491,6 @@ typedef struct VkSurfaceFormat2KHR { VkSurfaceFormatKHR surfaceFormat; } VkSurfaceFormat2KHR; - typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceCapabilities2KHR)(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR* pSurfaceInfo, VkSurfaceCapabilities2KHR* pSurfaceCapabilities); typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceFormats2KHR)(VkPhysicalDevice physicalDevice, const VkPhysicalDeviceSurfaceInfo2KHR* pSurfaceInfo, uint32_t* pSurfaceFormatCount, VkSurfaceFormat2KHR* pSurfaceFormats); @@ -5571,8 +5513,6 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceFormats2KHR( typedef VkPhysicalDeviceVariablePointerFeatures VkPhysicalDeviceVariablePointerFeaturesKHR; - - #define VK_KHR_dedicated_allocation 1 #define VK_KHR_DEDICATED_ALLOCATION_SPEC_VERSION 3 #define VK_KHR_DEDICATED_ALLOCATION_EXTENSION_NAME "VK_KHR_dedicated_allocation" @@ -5581,18 +5521,14 @@ typedef VkMemoryDedicatedRequirements VkMemoryDedicatedRequirementsKHR; typedef VkMemoryDedicatedAllocateInfo VkMemoryDedicatedAllocateInfoKHR; - - #define VK_KHR_storage_buffer_storage_class 1 #define VK_KHR_STORAGE_BUFFER_STORAGE_CLASS_SPEC_VERSION 1 #define VK_KHR_STORAGE_BUFFER_STORAGE_CLASS_EXTENSION_NAME "VK_KHR_storage_buffer_storage_class" - #define VK_KHR_relaxed_block_layout 1 #define VK_KHR_RELAXED_BLOCK_LAYOUT_SPEC_VERSION 1 #define VK_KHR_RELAXED_BLOCK_LAYOUT_EXTENSION_NAME "VK_KHR_relaxed_block_layout" - #define VK_KHR_get_memory_requirements2 1 #define VK_KHR_GET_MEMORY_REQUIREMENTS_2_SPEC_VERSION 1 #define VK_KHR_GET_MEMORY_REQUIREMENTS_2_EXTENSION_NAME "VK_KHR_get_memory_requirements2" @@ -5607,7 +5543,6 @@ typedef VkMemoryRequirements2 VkMemoryRequirements2KHR; typedef VkSparseImageMemoryRequirements2 VkSparseImageMemoryRequirements2KHR; - typedef void (VKAPI_PTR *PFN_vkGetImageMemoryRequirements2KHR)(VkDevice device, const VkImageMemoryRequirementsInfo2* pInfo, VkMemoryRequirements2* pMemoryRequirements); typedef void (VKAPI_PTR *PFN_vkGetBufferMemoryRequirements2KHR)(VkDevice device, const VkBufferMemoryRequirementsInfo2* pInfo, VkMemoryRequirements2* pMemoryRequirements); typedef void (VKAPI_PTR *PFN_vkGetImageSparseMemoryRequirements2KHR)(VkDevice device, const VkImageSparseMemoryRequirementsInfo2* pInfo, uint32_t* pSparseMemoryRequirementCount, VkSparseImageMemoryRequirements2* pSparseMemoryRequirements); @@ -5641,12 +5576,9 @@ typedef struct VkImageFormatListCreateInfoKHR { const VkFormat* pViewFormats; } VkImageFormatListCreateInfoKHR; - - #define VK_KHR_sampler_ycbcr_conversion 1 typedef VkSamplerYcbcrConversion VkSamplerYcbcrConversionKHR; - #define VK_KHR_SAMPLER_YCBCR_CONVERSION_SPEC_VERSION 1 #define VK_KHR_SAMPLER_YCBCR_CONVERSION_EXTENSION_NAME "VK_KHR_sampler_ycbcr_conversion" @@ -5656,7 +5588,6 @@ typedef VkSamplerYcbcrRange VkSamplerYcbcrRangeKHR; typedef VkChromaLocation VkChromaLocationKHR; - typedef VkSamplerYcbcrConversionCreateInfo VkSamplerYcbcrConversionCreateInfoKHR; typedef VkSamplerYcbcrConversionInfo VkSamplerYcbcrConversionInfoKHR; @@ -5669,7 +5600,6 @@ typedef VkPhysicalDeviceSamplerYcbcrConversionFeatures VkPhysicalDeviceSamplerYc typedef VkSamplerYcbcrConversionImageFormatProperties VkSamplerYcbcrConversionImageFormatPropertiesKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateSamplerYcbcrConversionKHR)(VkDevice device, const VkSamplerYcbcrConversionCreateInfo* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSamplerYcbcrConversion* pYcbcrConversion); typedef void (VKAPI_PTR *PFN_vkDestroySamplerYcbcrConversionKHR)(VkDevice device, VkSamplerYcbcrConversion ycbcrConversion, const VkAllocationCallbacks* pAllocator); @@ -5694,7 +5624,6 @@ typedef VkBindBufferMemoryInfo VkBindBufferMemoryInfoKHR; typedef VkBindImageMemoryInfo VkBindImageMemoryInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkBindBufferMemory2KHR)(VkDevice device, uint32_t bindInfoCount, const VkBindBufferMemoryInfo* pBindInfos); typedef VkResult (VKAPI_PTR *PFN_vkBindImageMemory2KHR)(VkDevice device, uint32_t bindInfoCount, const VkBindImageMemoryInfo* pBindInfos); @@ -5718,7 +5647,6 @@ typedef VkPhysicalDeviceMaintenance3Properties VkPhysicalDeviceMaintenance3Prope typedef VkDescriptorSetLayoutSupport VkDescriptorSetLayoutSupportKHR; - typedef void (VKAPI_PTR *PFN_vkGetDescriptorSetLayoutSupportKHR)(VkDevice device, const VkDescriptorSetLayoutCreateInfo* pCreateInfo, VkDescriptorSetLayoutSupport* pSupport); #ifndef VK_NO_PROTOTYPES @@ -5736,7 +5664,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDebugReportCallbackEXT) #define VK_STRUCTURE_TYPE_DEBUG_REPORT_CREATE_INFO_EXT VK_STRUCTURE_TYPE_DEBUG_REPORT_CALLBACK_CREATE_INFO_EXT #define VK_DEBUG_REPORT_OBJECT_TYPE_DEBUG_REPORT_EXT VK_DEBUG_REPORT_OBJECT_TYPE_DEBUG_REPORT_CALLBACK_EXT_EXT - typedef enum VkDebugReportObjectTypeEXT { VK_DEBUG_REPORT_OBJECT_TYPE_UNKNOWN_EXT = 0, VK_DEBUG_REPORT_OBJECT_TYPE_INSTANCE_EXT = 1, @@ -5782,7 +5709,6 @@ typedef enum VkDebugReportObjectTypeEXT { VK_DEBUG_REPORT_OBJECT_TYPE_MAX_ENUM_EXT = 0x7FFFFFFF } VkDebugReportObjectTypeEXT; - typedef enum VkDebugReportFlagBitsEXT { VK_DEBUG_REPORT_INFORMATION_BIT_EXT = 0x00000001, VK_DEBUG_REPORT_WARNING_BIT_EXT = 0x00000002, @@ -5811,7 +5737,6 @@ typedef struct VkDebugReportCallbackCreateInfoEXT { void* pUserData; } VkDebugReportCallbackCreateInfoEXT; - typedef VkResult (VKAPI_PTR *PFN_vkCreateDebugReportCallbackEXT)(VkInstance instance, const VkDebugReportCallbackCreateInfoEXT* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkDebugReportCallbackEXT* pCallback); typedef void (VKAPI_PTR *PFN_vkDestroyDebugReportCallbackEXT)(VkInstance instance, VkDebugReportCallbackEXT callback, const VkAllocationCallbacks* pAllocator); typedef void (VKAPI_PTR *PFN_vkDebugReportMessageEXT)(VkInstance instance, VkDebugReportFlagsEXT flags, VkDebugReportObjectTypeEXT objectType, uint64_t object, size_t location, int32_t messageCode, const char* pLayerPrefix, const char* pMessage); @@ -5843,22 +5768,18 @@ VKAPI_ATTR void VKAPI_CALL vkDebugReportMessageEXT( #define VK_NV_GLSL_SHADER_SPEC_VERSION 1 #define VK_NV_GLSL_SHADER_EXTENSION_NAME "VK_NV_glsl_shader" - #define VK_EXT_depth_range_unrestricted 1 #define VK_EXT_DEPTH_RANGE_UNRESTRICTED_SPEC_VERSION 1 #define VK_EXT_DEPTH_RANGE_UNRESTRICTED_EXTENSION_NAME "VK_EXT_depth_range_unrestricted" - #define VK_IMG_filter_cubic 1 #define VK_IMG_FILTER_CUBIC_SPEC_VERSION 1 #define VK_IMG_FILTER_CUBIC_EXTENSION_NAME "VK_IMG_filter_cubic" - #define VK_AMD_rasterization_order 1 #define VK_AMD_RASTERIZATION_ORDER_SPEC_VERSION 1 #define VK_AMD_RASTERIZATION_ORDER_EXTENSION_NAME "VK_AMD_rasterization_order" - typedef enum VkRasterizationOrderAMD { VK_RASTERIZATION_ORDER_STRICT_AMD = 0, VK_RASTERIZATION_ORDER_RELAXED_AMD = 1, @@ -5874,18 +5795,14 @@ typedef struct VkPipelineRasterizationStateRasterizationOrderAMD { VkRasterizationOrderAMD rasterizationOrder; } VkPipelineRasterizationStateRasterizationOrderAMD; - - #define VK_AMD_shader_trinary_minmax 1 #define VK_AMD_SHADER_TRINARY_MINMAX_SPEC_VERSION 1 #define VK_AMD_SHADER_TRINARY_MINMAX_EXTENSION_NAME "VK_AMD_shader_trinary_minmax" - #define VK_AMD_shader_explicit_vertex_parameter 1 #define VK_AMD_SHADER_EXPLICIT_VERTEX_PARAMETER_SPEC_VERSION 1 #define VK_AMD_SHADER_EXPLICIT_VERTEX_PARAMETER_EXTENSION_NAME "VK_AMD_shader_explicit_vertex_parameter" - #define VK_EXT_debug_marker 1 #define VK_EXT_DEBUG_MARKER_SPEC_VERSION 4 #define VK_EXT_DEBUG_MARKER_EXTENSION_NAME "VK_EXT_debug_marker" @@ -5915,7 +5832,6 @@ typedef struct VkDebugMarkerMarkerInfoEXT { float color[4]; } VkDebugMarkerMarkerInfoEXT; - typedef VkResult (VKAPI_PTR *PFN_vkDebugMarkerSetObjectTagEXT)(VkDevice device, const VkDebugMarkerObjectTagInfoEXT* pTagInfo); typedef VkResult (VKAPI_PTR *PFN_vkDebugMarkerSetObjectNameEXT)(VkDevice device, const VkDebugMarkerObjectNameInfoEXT* pNameInfo); typedef void (VKAPI_PTR *PFN_vkCmdDebugMarkerBeginEXT)(VkCommandBuffer commandBuffer, const VkDebugMarkerMarkerInfoEXT* pMarkerInfo); @@ -5947,7 +5863,6 @@ VKAPI_ATTR void VKAPI_CALL vkCmdDebugMarkerInsertEXT( #define VK_AMD_GCN_SHADER_SPEC_VERSION 1 #define VK_AMD_GCN_SHADER_EXTENSION_NAME "VK_AMD_gcn_shader" - #define VK_NV_dedicated_allocation 1 #define VK_NV_DEDICATED_ALLOCATION_SPEC_VERSION 1 #define VK_NV_DEDICATED_ALLOCATION_EXTENSION_NAME "VK_NV_dedicated_allocation" @@ -5971,8 +5886,6 @@ typedef struct VkDedicatedAllocationMemoryAllocateInfoNV { VkBuffer buffer; } VkDedicatedAllocationMemoryAllocateInfoNV; - - #define VK_AMD_draw_indirect_count 1 #define VK_AMD_DRAW_INDIRECT_COUNT_SPEC_VERSION 1 #define VK_AMD_DRAW_INDIRECT_COUNT_EXTENSION_NAME "VK_AMD_draw_indirect_count" @@ -6004,17 +5917,14 @@ VKAPI_ATTR void VKAPI_CALL vkCmdDrawIndexedIndirectCountAMD( #define VK_AMD_NEGATIVE_VIEWPORT_HEIGHT_SPEC_VERSION 1 #define VK_AMD_NEGATIVE_VIEWPORT_HEIGHT_EXTENSION_NAME "VK_AMD_negative_viewport_height" - #define VK_AMD_gpu_shader_half_float 1 #define VK_AMD_GPU_SHADER_HALF_FLOAT_SPEC_VERSION 1 #define VK_AMD_GPU_SHADER_HALF_FLOAT_EXTENSION_NAME "VK_AMD_gpu_shader_half_float" - #define VK_AMD_shader_ballot 1 #define VK_AMD_SHADER_BALLOT_SPEC_VERSION 1 #define VK_AMD_SHADER_BALLOT_EXTENSION_NAME "VK_AMD_shader_ballot" - #define VK_AMD_texture_gather_bias_lod 1 #define VK_AMD_TEXTURE_GATHER_BIAS_LOD_SPEC_VERSION 1 #define VK_AMD_TEXTURE_GATHER_BIAS_LOD_EXTENSION_NAME "VK_AMD_texture_gather_bias_lod" @@ -6025,13 +5935,10 @@ typedef struct VkTextureLODGatherFormatPropertiesAMD { VkBool32 supportsTextureGatherLODBiasAMD; } VkTextureLODGatherFormatPropertiesAMD; - - #define VK_AMD_shader_info 1 #define VK_AMD_SHADER_INFO_SPEC_VERSION 1 #define VK_AMD_SHADER_INFO_EXTENSION_NAME "VK_AMD_shader_info" - typedef enum VkShaderInfoTypeAMD { VK_SHADER_INFO_TYPE_STATISTICS_AMD = 0, VK_SHADER_INFO_TYPE_BINARY_AMD = 1, @@ -6060,7 +5967,6 @@ typedef struct VkShaderStatisticsInfoAMD { uint32_t computeWorkGroupSize[3]; } VkShaderStatisticsInfoAMD; - typedef VkResult (VKAPI_PTR *PFN_vkGetShaderInfoAMD)(VkDevice device, VkPipeline pipeline, VkShaderStageFlagBits shaderStage, VkShaderInfoTypeAMD infoType, size_t* pInfoSize, void* pInfo); #ifndef VK_NO_PROTOTYPES @@ -6077,17 +5983,14 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetShaderInfoAMD( #define VK_AMD_SHADER_IMAGE_LOAD_STORE_LOD_SPEC_VERSION 1 #define VK_AMD_SHADER_IMAGE_LOAD_STORE_LOD_EXTENSION_NAME "VK_AMD_shader_image_load_store_lod" - #define VK_IMG_format_pvrtc 1 #define VK_IMG_FORMAT_PVRTC_SPEC_VERSION 1 #define VK_IMG_FORMAT_PVRTC_EXTENSION_NAME "VK_IMG_format_pvrtc" - #define VK_NV_external_memory_capabilities 1 #define VK_NV_EXTERNAL_MEMORY_CAPABILITIES_SPEC_VERSION 1 #define VK_NV_EXTERNAL_MEMORY_CAPABILITIES_EXTENSION_NAME "VK_NV_external_memory_capabilities" - typedef enum VkExternalMemoryHandleTypeFlagBitsNV { VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_BIT_NV = 0x00000001, VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_KMT_BIT_NV = 0x00000002, @@ -6112,7 +6015,6 @@ typedef struct VkExternalImageFormatPropertiesNV { VkExternalMemoryHandleTypeFlagsNV compatibleHandleTypes; } VkExternalImageFormatPropertiesNV; - typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceExternalImageFormatPropertiesNV)(VkPhysicalDevice physicalDevice, VkFormat format, VkImageType type, VkImageTiling tiling, VkImageUsageFlags usage, VkImageCreateFlags flags, VkExternalMemoryHandleTypeFlagsNV externalHandleType, VkExternalImageFormatPropertiesNV* pExternalImageFormatProperties); #ifndef VK_NO_PROTOTYPES @@ -6143,13 +6045,10 @@ typedef struct VkExportMemoryAllocateInfoNV { VkExternalMemoryHandleTypeFlagsNV handleTypes; } VkExportMemoryAllocateInfoNV; - - #define VK_EXT_validation_flags 1 #define VK_EXT_VALIDATION_FLAGS_SPEC_VERSION 1 #define VK_EXT_VALIDATION_FLAGS_EXTENSION_NAME "VK_EXT_validation_flags" - typedef enum VkValidationCheckEXT { VK_VALIDATION_CHECK_ALL_EXT = 0, VK_VALIDATION_CHECK_SHADERS_EXT = 1, @@ -6166,18 +6065,14 @@ typedef struct VkValidationFlagsEXT { VkValidationCheckEXT* pDisabledValidationChecks; } VkValidationFlagsEXT; - - #define VK_EXT_shader_subgroup_ballot 1 #define VK_EXT_SHADER_SUBGROUP_BALLOT_SPEC_VERSION 1 #define VK_EXT_SHADER_SUBGROUP_BALLOT_EXTENSION_NAME "VK_EXT_shader_subgroup_ballot" - #define VK_EXT_shader_subgroup_vote 1 #define VK_EXT_SHADER_SUBGROUP_VOTE_SPEC_VERSION 1 #define VK_EXT_SHADER_SUBGROUP_VOTE_EXTENSION_NAME "VK_EXT_shader_subgroup_vote" - #define VK_NVX_device_generated_commands 1 VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkObjectTableNVX) VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkIndirectCommandsLayoutNVX) @@ -6185,7 +6080,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkIndirectCommandsLayoutNVX) #define VK_NVX_DEVICE_GENERATED_COMMANDS_SPEC_VERSION 3 #define VK_NVX_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME "VK_NVX_device_generated_commands" - typedef enum VkIndirectCommandsTokenTypeNVX { VK_INDIRECT_COMMANDS_TOKEN_TYPE_PIPELINE_NVX = 0, VK_INDIRECT_COMMANDS_TOKEN_TYPE_DESCRIPTOR_SET_NVX = 1, @@ -6213,7 +6107,6 @@ typedef enum VkObjectEntryTypeNVX { VK_OBJECT_ENTRY_TYPE_MAX_ENUM_NVX = 0x7FFFFFFF } VkObjectEntryTypeNVX; - typedef enum VkIndirectCommandsLayoutUsageFlagBitsNVX { VK_INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NVX = 0x00000001, VK_INDIRECT_COMMANDS_LAYOUT_USAGE_SPARSE_SEQUENCES_BIT_NVX = 0x00000002, @@ -6343,7 +6236,6 @@ typedef struct VkObjectTablePushConstantEntryNVX { VkShaderStageFlags stageFlags; } VkObjectTablePushConstantEntryNVX; - typedef void (VKAPI_PTR *PFN_vkCmdProcessCommandsNVX)(VkCommandBuffer commandBuffer, const VkCmdProcessCommandsInfoNVX* pProcessCommandsInfo); typedef void (VKAPI_PTR *PFN_vkCmdReserveSpaceForCommandsNVX)(VkCommandBuffer commandBuffer, const VkCmdReserveSpaceForCommandsInfoNVX* pReserveSpaceInfo); typedef VkResult (VKAPI_PTR *PFN_vkCreateIndirectCommandsLayoutNVX)(VkDevice device, const VkIndirectCommandsLayoutCreateInfoNVX* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkIndirectCommandsLayoutNVX* pIndirectCommandsLayout); @@ -6422,7 +6314,6 @@ typedef struct VkPipelineViewportWScalingStateCreateInfoNV { const VkViewportWScalingNV* pViewportWScalings; } VkPipelineViewportWScalingStateCreateInfoNV; - typedef void (VKAPI_PTR *PFN_vkCmdSetViewportWScalingNV)(VkCommandBuffer commandBuffer, uint32_t firstViewport, uint32_t viewportCount, const VkViewportWScalingNV* pViewportWScalings); #ifndef VK_NO_PROTOTYPES @@ -6450,7 +6341,6 @@ VKAPI_ATTR VkResult VKAPI_CALL vkReleaseDisplayEXT( #define VK_EXT_DISPLAY_SURFACE_COUNTER_EXTENSION_NAME "VK_EXT_display_surface_counter" #define VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES2_EXT VK_STRUCTURE_TYPE_SURFACE_CAPABILITIES_2_EXT - typedef enum VkSurfaceCounterFlagBitsEXT { VK_SURFACE_COUNTER_VBLANK_EXT = 0x00000001, VK_SURFACE_COUNTER_FLAG_BITS_MAX_ENUM_EXT = 0x7FFFFFFF @@ -6473,7 +6363,6 @@ typedef struct VkSurfaceCapabilities2EXT { VkSurfaceCounterFlagsEXT supportedSurfaceCounters; } VkSurfaceCapabilities2EXT; - typedef VkResult (VKAPI_PTR *PFN_vkGetPhysicalDeviceSurfaceCapabilities2EXT)(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface, VkSurfaceCapabilities2EXT* pSurfaceCapabilities); #ifndef VK_NO_PROTOTYPES @@ -6487,7 +6376,6 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetPhysicalDeviceSurfaceCapabilities2EXT( #define VK_EXT_DISPLAY_CONTROL_SPEC_VERSION 1 #define VK_EXT_DISPLAY_CONTROL_EXTENSION_NAME "VK_EXT_display_control" - typedef enum VkDisplayPowerStateEXT { VK_DISPLAY_POWER_STATE_OFF_EXT = 0, VK_DISPLAY_POWER_STATE_SUSPEND_EXT = 1, @@ -6538,7 +6426,6 @@ typedef struct VkSwapchainCounterCreateInfoEXT { VkSurfaceCounterFlagsEXT surfaceCounters; } VkSwapchainCounterCreateInfoEXT; - typedef VkResult (VKAPI_PTR *PFN_vkDisplayPowerControlEXT)(VkDevice device, VkDisplayKHR display, const VkDisplayPowerInfoEXT* pDisplayPowerInfo); typedef VkResult (VKAPI_PTR *PFN_vkRegisterDeviceEventEXT)(VkDevice device, const VkDeviceEventInfoEXT* pDeviceEventInfo, const VkAllocationCallbacks* pAllocator, VkFence* pFence); typedef VkResult (VKAPI_PTR *PFN_vkRegisterDisplayEventEXT)(VkDevice device, VkDisplayKHR display, const VkDisplayEventInfoEXT* pDisplayEventInfo, const VkAllocationCallbacks* pAllocator, VkFence* pFence); @@ -6598,7 +6485,6 @@ typedef struct VkPresentTimesInfoGOOGLE { const VkPresentTimeGOOGLE* pTimes; } VkPresentTimesInfoGOOGLE; - typedef VkResult (VKAPI_PTR *PFN_vkGetRefreshCycleDurationGOOGLE)(VkDevice device, VkSwapchainKHR swapchain, VkRefreshCycleDurationGOOGLE* pDisplayTimingProperties); typedef VkResult (VKAPI_PTR *PFN_vkGetPastPresentationTimingGOOGLE)(VkDevice device, VkSwapchainKHR swapchain, uint32_t* pPresentationTimingCount, VkPastPresentationTimingGOOGLE* pPresentationTimings); @@ -6619,17 +6505,14 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetPastPresentationTimingGOOGLE( #define VK_NV_SAMPLE_MASK_OVERRIDE_COVERAGE_SPEC_VERSION 1 #define VK_NV_SAMPLE_MASK_OVERRIDE_COVERAGE_EXTENSION_NAME "VK_NV_sample_mask_override_coverage" - #define VK_NV_geometry_shader_passthrough 1 #define VK_NV_GEOMETRY_SHADER_PASSTHROUGH_SPEC_VERSION 1 #define VK_NV_GEOMETRY_SHADER_PASSTHROUGH_EXTENSION_NAME "VK_NV_geometry_shader_passthrough" - #define VK_NV_viewport_array2 1 #define VK_NV_VIEWPORT_ARRAY2_SPEC_VERSION 1 #define VK_NV_VIEWPORT_ARRAY2_EXTENSION_NAME "VK_NV_viewport_array2" - #define VK_NVX_multiview_per_view_attributes 1 #define VK_NVX_MULTIVIEW_PER_VIEW_ATTRIBUTES_SPEC_VERSION 1 #define VK_NVX_MULTIVIEW_PER_VIEW_ATTRIBUTES_EXTENSION_NAME "VK_NVX_multiview_per_view_attributes" @@ -6640,13 +6523,10 @@ typedef struct VkPhysicalDeviceMultiviewPerViewAttributesPropertiesNVX { VkBool32 perViewPositionAllComponents; } VkPhysicalDeviceMultiviewPerViewAttributesPropertiesNVX; - - #define VK_NV_viewport_swizzle 1 #define VK_NV_VIEWPORT_SWIZZLE_SPEC_VERSION 1 #define VK_NV_VIEWPORT_SWIZZLE_EXTENSION_NAME "VK_NV_viewport_swizzle" - typedef enum VkViewportCoordinateSwizzleNV { VK_VIEWPORT_COORDINATE_SWIZZLE_POSITIVE_X_NV = 0, VK_VIEWPORT_COORDINATE_SWIZZLE_NEGATIVE_X_NV = 1, @@ -6679,13 +6559,10 @@ typedef struct VkPipelineViewportSwizzleStateCreateInfoNV { const VkViewportSwizzleNV* pViewportSwizzles; } VkPipelineViewportSwizzleStateCreateInfoNV; - - #define VK_EXT_discard_rectangles 1 #define VK_EXT_DISCARD_RECTANGLES_SPEC_VERSION 1 #define VK_EXT_DISCARD_RECTANGLES_EXTENSION_NAME "VK_EXT_discard_rectangles" - typedef enum VkDiscardRectangleModeEXT { VK_DISCARD_RECTANGLE_MODE_INCLUSIVE_EXT = 0, VK_DISCARD_RECTANGLE_MODE_EXCLUSIVE_EXT = 1, @@ -6712,7 +6589,6 @@ typedef struct VkPipelineDiscardRectangleStateCreateInfoEXT { const VkRect2D* pDiscardRectangles; } VkPipelineDiscardRectangleStateCreateInfoEXT; - typedef void (VKAPI_PTR *PFN_vkCmdSetDiscardRectangleEXT)(VkCommandBuffer commandBuffer, uint32_t firstDiscardRectangle, uint32_t discardRectangleCount, const VkRect2D* pDiscardRectangles); #ifndef VK_NO_PROTOTYPES @@ -6727,7 +6603,6 @@ VKAPI_ATTR void VKAPI_CALL vkCmdSetDiscardRectangleEXT( #define VK_EXT_CONSERVATIVE_RASTERIZATION_SPEC_VERSION 1 #define VK_EXT_CONSERVATIVE_RASTERIZATION_EXTENSION_NAME "VK_EXT_conservative_rasterization" - typedef enum VkConservativeRasterizationModeEXT { VK_CONSERVATIVE_RASTERIZATION_MODE_DISABLED_EXT = 0, VK_CONSERVATIVE_RASTERIZATION_MODE_OVERESTIMATE_EXT = 1, @@ -6762,13 +6637,10 @@ typedef struct VkPipelineRasterizationConservativeStateCreateInfoEXT { float extraPrimitiveOverestimationSize; } VkPipelineRasterizationConservativeStateCreateInfoEXT; - - #define VK_EXT_swapchain_colorspace 1 #define VK_EXT_SWAPCHAIN_COLOR_SPACE_SPEC_VERSION 3 #define VK_EXT_SWAPCHAIN_COLOR_SPACE_EXTENSION_NAME "VK_EXT_swapchain_colorspace" - #define VK_EXT_hdr_metadata 1 #define VK_EXT_HDR_METADATA_SPEC_VERSION 1 #define VK_EXT_HDR_METADATA_EXTENSION_NAME "VK_EXT_hdr_metadata" @@ -6791,7 +6663,6 @@ typedef struct VkHdrMetadataEXT { float maxFrameAverageLightLevel; } VkHdrMetadataEXT; - typedef void (VKAPI_PTR *PFN_vkSetHdrMetadataEXT)(VkDevice device, uint32_t swapchainCount, const VkSwapchainKHR* pSwapchains, const VkHdrMetadataEXT* pMetadata); #ifndef VK_NO_PROTOTYPES @@ -6806,13 +6677,11 @@ VKAPI_ATTR void VKAPI_CALL vkSetHdrMetadataEXT( #define VK_EXT_EXTERNAL_MEMORY_DMA_BUF_SPEC_VERSION 1 #define VK_EXT_EXTERNAL_MEMORY_DMA_BUF_EXTENSION_NAME "VK_EXT_external_memory_dma_buf" - #define VK_EXT_queue_family_foreign 1 #define VK_EXT_QUEUE_FAMILY_FOREIGN_SPEC_VERSION 1 #define VK_EXT_QUEUE_FAMILY_FOREIGN_EXTENSION_NAME "VK_EXT_queue_family_foreign" #define VK_QUEUE_FAMILY_FOREIGN_EXT (~0U-2) - #define VK_EXT_debug_utils 1 VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDebugUtilsMessengerEXT) @@ -6895,7 +6764,6 @@ typedef struct VkDebugUtilsMessengerCreateInfoEXT { void* pUserData; } VkDebugUtilsMessengerCreateInfoEXT; - typedef VkResult (VKAPI_PTR *PFN_vkSetDebugUtilsObjectNameEXT)(VkDevice device, const VkDebugUtilsObjectNameInfoEXT* pNameInfo); typedef VkResult (VKAPI_PTR *PFN_vkSetDebugUtilsObjectTagEXT)(VkDevice device, const VkDebugUtilsObjectTagInfoEXT* pTagInfo); typedef void (VKAPI_PTR *PFN_vkQueueBeginDebugUtilsLabelEXT)(VkQueue queue, const VkDebugUtilsLabelEXT* pLabelInfo); @@ -6961,7 +6829,6 @@ VKAPI_ATTR void VKAPI_CALL vkSubmitDebugUtilsMessageEXT( #define VK_EXT_SAMPLER_FILTER_MINMAX_SPEC_VERSION 1 #define VK_EXT_SAMPLER_FILTER_MINMAX_EXTENSION_NAME "VK_EXT_sampler_filter_minmax" - typedef enum VkSamplerReductionModeEXT { VK_SAMPLER_REDUCTION_MODE_WEIGHTED_AVERAGE_EXT = 0, VK_SAMPLER_REDUCTION_MODE_MIN_EXT = 1, @@ -6985,28 +6852,22 @@ typedef struct VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT { VkBool32 filterMinmaxImageComponentMapping; } VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT; - - #define VK_AMD_gpu_shader_int16 1 #define VK_AMD_GPU_SHADER_INT16_SPEC_VERSION 1 #define VK_AMD_GPU_SHADER_INT16_EXTENSION_NAME "VK_AMD_gpu_shader_int16" - #define VK_AMD_mixed_attachment_samples 1 #define VK_AMD_MIXED_ATTACHMENT_SAMPLES_SPEC_VERSION 1 #define VK_AMD_MIXED_ATTACHMENT_SAMPLES_EXTENSION_NAME "VK_AMD_mixed_attachment_samples" - #define VK_AMD_shader_fragment_mask 1 #define VK_AMD_SHADER_FRAGMENT_MASK_SPEC_VERSION 1 #define VK_AMD_SHADER_FRAGMENT_MASK_EXTENSION_NAME "VK_AMD_shader_fragment_mask" - #define VK_EXT_shader_stencil_export 1 #define VK_EXT_SHADER_STENCIL_EXPORT_SPEC_VERSION 1 #define VK_EXT_SHADER_STENCIL_EXPORT_EXTENSION_NAME "VK_EXT_shader_stencil_export" - #define VK_EXT_sample_locations 1 #define VK_EXT_SAMPLE_LOCATIONS_SPEC_VERSION 1 #define VK_EXT_SAMPLE_LOCATIONS_EXTENSION_NAME "VK_EXT_sample_locations" @@ -7067,7 +6928,6 @@ typedef struct VkMultisamplePropertiesEXT { VkExtent2D maxSampleLocationGridSize; } VkMultisamplePropertiesEXT; - typedef void (VKAPI_PTR *PFN_vkCmdSetSampleLocationsEXT)(VkCommandBuffer commandBuffer, const VkSampleLocationsInfoEXT* pSampleLocationsInfo); typedef void (VKAPI_PTR *PFN_vkGetPhysicalDeviceMultisamplePropertiesEXT)(VkPhysicalDevice physicalDevice, VkSampleCountFlagBits samples, VkMultisamplePropertiesEXT* pMultisampleProperties); @@ -7086,7 +6946,6 @@ VKAPI_ATTR void VKAPI_CALL vkGetPhysicalDeviceMultisamplePropertiesEXT( #define VK_EXT_BLEND_OPERATION_ADVANCED_SPEC_VERSION 2 #define VK_EXT_BLEND_OPERATION_ADVANCED_EXTENSION_NAME "VK_EXT_blend_operation_advanced" - typedef enum VkBlendOverlapEXT { VK_BLEND_OVERLAP_UNCORRELATED_EXT = 0, VK_BLEND_OVERLAP_DISJOINT_EXT = 1, @@ -7122,8 +6981,6 @@ typedef struct VkPipelineColorBlendAdvancedStateCreateInfoEXT { VkBlendOverlapEXT blendOverlap; } VkPipelineColorBlendAdvancedStateCreateInfoEXT; - - #define VK_NV_fragment_coverage_to_color 1 #define VK_NV_FRAGMENT_COVERAGE_TO_COLOR_SPEC_VERSION 1 #define VK_NV_FRAGMENT_COVERAGE_TO_COLOR_EXTENSION_NAME "VK_NV_fragment_coverage_to_color" @@ -7138,13 +6995,10 @@ typedef struct VkPipelineCoverageToColorStateCreateInfoNV { uint32_t coverageToColorLocation; } VkPipelineCoverageToColorStateCreateInfoNV; - - #define VK_NV_framebuffer_mixed_samples 1 #define VK_NV_FRAMEBUFFER_MIXED_SAMPLES_SPEC_VERSION 1 #define VK_NV_FRAMEBUFFER_MIXED_SAMPLES_EXTENSION_NAME "VK_NV_framebuffer_mixed_samples" - typedef enum VkCoverageModulationModeNV { VK_COVERAGE_MODULATION_MODE_NONE_NV = 0, VK_COVERAGE_MODULATION_MODE_RGB_NV = 1, @@ -7168,18 +7022,14 @@ typedef struct VkPipelineCoverageModulationStateCreateInfoNV { const float* pCoverageModulationTable; } VkPipelineCoverageModulationStateCreateInfoNV; - - #define VK_NV_fill_rectangle 1 #define VK_NV_FILL_RECTANGLE_SPEC_VERSION 1 #define VK_NV_FILL_RECTANGLE_EXTENSION_NAME "VK_NV_fill_rectangle" - #define VK_EXT_post_depth_coverage 1 #define VK_EXT_POST_DEPTH_COVERAGE_SPEC_VERSION 1 #define VK_EXT_POST_DEPTH_COVERAGE_EXTENSION_NAME "VK_EXT_post_depth_coverage" - #define VK_EXT_validation_cache 1 VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkValidationCacheEXT) @@ -7187,7 +7037,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkValidationCacheEXT) #define VK_EXT_VALIDATION_CACHE_EXTENSION_NAME "VK_EXT_validation_cache" #define VK_DEBUG_REPORT_OBJECT_TYPE_VALIDATION_CACHE_EXT VK_DEBUG_REPORT_OBJECT_TYPE_VALIDATION_CACHE_EXT_EXT - typedef enum VkValidationCacheHeaderVersionEXT { VK_VALIDATION_CACHE_HEADER_VERSION_ONE_EXT = 1, VK_VALIDATION_CACHE_HEADER_VERSION_BEGIN_RANGE_EXT = VK_VALIDATION_CACHE_HEADER_VERSION_ONE_EXT, @@ -7212,7 +7061,6 @@ typedef struct VkShaderModuleValidationCacheCreateInfoEXT { VkValidationCacheEXT validationCache; } VkShaderModuleValidationCacheCreateInfoEXT; - typedef VkResult (VKAPI_PTR *PFN_vkCreateValidationCacheEXT)(VkDevice device, const VkValidationCacheCreateInfoEXT* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkValidationCacheEXT* pValidationCache); typedef void (VKAPI_PTR *PFN_vkDestroyValidationCacheEXT)(VkDevice device, VkValidationCacheEXT validationCache, const VkAllocationCallbacks* pAllocator); typedef VkResult (VKAPI_PTR *PFN_vkMergeValidationCachesEXT)(VkDevice device, VkValidationCacheEXT dstCache, uint32_t srcCacheCount, const VkValidationCacheEXT* pSrcCaches); @@ -7247,7 +7095,6 @@ VKAPI_ATTR VkResult VKAPI_CALL vkGetValidationCacheDataEXT( #define VK_EXT_DESCRIPTOR_INDEXING_SPEC_VERSION 2 #define VK_EXT_DESCRIPTOR_INDEXING_EXTENSION_NAME "VK_EXT_descriptor_indexing" - typedef enum VkDescriptorBindingFlagBitsEXT { VK_DESCRIPTOR_BINDING_UPDATE_AFTER_BIND_BIT_EXT = 0x00000001, VK_DESCRIPTOR_BINDING_UPDATE_UNUSED_WHILE_PENDING_BIT_EXT = 0x00000002, @@ -7330,18 +7177,14 @@ typedef struct VkDescriptorSetVariableDescriptorCountLayoutSupportEXT { uint32_t maxVariableDescriptorCount; } VkDescriptorSetVariableDescriptorCountLayoutSupportEXT; - - #define VK_EXT_shader_viewport_index_layer 1 #define VK_EXT_SHADER_VIEWPORT_INDEX_LAYER_SPEC_VERSION 1 #define VK_EXT_SHADER_VIEWPORT_INDEX_LAYER_EXTENSION_NAME "VK_EXT_shader_viewport_index_layer" - #define VK_EXT_global_priority 1 #define VK_EXT_GLOBAL_PRIORITY_SPEC_VERSION 2 #define VK_EXT_GLOBAL_PRIORITY_EXTENSION_NAME "VK_EXT_global_priority" - typedef enum VkQueueGlobalPriorityEXT { VK_QUEUE_GLOBAL_PRIORITY_LOW_EXT = 128, VK_QUEUE_GLOBAL_PRIORITY_MEDIUM_EXT = 256, @@ -7359,8 +7202,6 @@ typedef struct VkDeviceQueueGlobalPriorityCreateInfoEXT { VkQueueGlobalPriorityEXT globalPriority; } VkDeviceQueueGlobalPriorityCreateInfoEXT; - - #define VK_EXT_external_memory_host 1 #define VK_EXT_EXTERNAL_MEMORY_HOST_SPEC_VERSION 1 #define VK_EXT_EXTERNAL_MEMORY_HOST_EXTENSION_NAME "VK_EXT_external_memory_host" @@ -7384,7 +7225,6 @@ typedef struct VkPhysicalDeviceExternalMemoryHostPropertiesEXT { VkDeviceSize minImportedHostPointerAlignment; } VkPhysicalDeviceExternalMemoryHostPropertiesEXT; - typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryHostPointerPropertiesEXT)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, const void* pHostPointer, VkMemoryHostPointerPropertiesEXT* pMemoryHostPointerProperties); #ifndef VK_NO_PROTOTYPES @@ -7433,8 +7273,6 @@ typedef struct VkPhysicalDeviceShaderCorePropertiesAMD { uint32_t vgprAllocationGranularity; } VkPhysicalDeviceShaderCorePropertiesAMD; - - #define VK_EXT_vertex_attribute_divisor 1 #define VK_EXT_VERTEX_ATTRIBUTE_DIVISOR_SPEC_VERSION 1 #define VK_EXT_VERTEX_ATTRIBUTE_DIVISOR_EXTENSION_NAME "VK_EXT_vertex_attribute_divisor" @@ -7457,13 +7295,10 @@ typedef struct VkPipelineVertexInputDivisorStateCreateInfoEXT { const VkVertexInputBindingDivisorDescriptionEXT* pVertexBindingDivisors; } VkPipelineVertexInputDivisorStateCreateInfoEXT; - - #define VK_NV_shader_subgroup_partitioned 1 #define VK_NV_SHADER_SUBGROUP_PARTITIONED_SPEC_VERSION 1 #define VK_NV_SHADER_SUBGROUP_PARTITIONED_EXTENSION_NAME "VK_NV_shader_subgroup_partitioned" - #ifdef __cplusplus } #endif diff --git a/gfx/include/vulkan/vulkan_ios.h b/gfx/include/vulkan/vulkan_ios.h index a0924816d5..2e45f4eb1a 100644 --- a/gfx/include/vulkan/vulkan_ios.h +++ b/gfx/include/vulkan/vulkan_ios.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_MVK_ios_surface 1 #define VK_MVK_IOS_SURFACE_SPEC_VERSION 2 #define VK_MVK_IOS_SURFACE_EXTENSION_NAME "VK_MVK_ios_surface" @@ -40,7 +39,6 @@ typedef struct VkIOSSurfaceCreateInfoMVK { const void* pView; } VkIOSSurfaceCreateInfoMVK; - typedef VkResult (VKAPI_PTR *PFN_vkCreateIOSSurfaceMVK)(VkInstance instance, const VkIOSSurfaceCreateInfoMVK* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); #ifndef VK_NO_PROTOTYPES diff --git a/gfx/include/vulkan/vulkan_macos.h b/gfx/include/vulkan/vulkan_macos.h index ff0b701801..049bbc95d5 100644 --- a/gfx/include/vulkan/vulkan_macos.h +++ b/gfx/include/vulkan/vulkan_macos.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_MVK_macos_surface 1 #define VK_MVK_MACOS_SURFACE_SPEC_VERSION 2 #define VK_MVK_MACOS_SURFACE_EXTENSION_NAME "VK_MVK_macos_surface" @@ -40,7 +39,6 @@ typedef struct VkMacOSSurfaceCreateInfoMVK { const void* pView; } VkMacOSSurfaceCreateInfoMVK; - typedef VkResult (VKAPI_PTR *PFN_vkCreateMacOSSurfaceMVK)(VkInstance instance, const VkMacOSSurfaceCreateInfoMVK* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); #ifndef VK_NO_PROTOTYPES diff --git a/gfx/include/vulkan/vulkan_mir.h b/gfx/include/vulkan/vulkan_mir.h index 7d24ed27a3..3c14619284 100644 --- a/gfx/include/vulkan/vulkan_mir.h +++ b/gfx/include/vulkan/vulkan_mir.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_mir_surface 1 #define VK_KHR_MIR_SURFACE_SPEC_VERSION 4 #define VK_KHR_MIR_SURFACE_EXTENSION_NAME "VK_KHR_mir_surface" @@ -41,7 +40,6 @@ typedef struct VkMirSurfaceCreateInfoKHR { MirSurface* mirSurface; } VkMirSurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateMirSurfaceKHR)(VkInstance instance, const VkMirSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceMirPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, MirConnection* connection); diff --git a/gfx/include/vulkan/vulkan_vi.h b/gfx/include/vulkan/vulkan_vi.h index 015166bfc6..cd194e27da 100644 --- a/gfx/include/vulkan/vulkan_vi.h +++ b/gfx/include/vulkan/vulkan_vi.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_NN_vi_surface 1 #define VK_NN_VI_SURFACE_SPEC_VERSION 1 #define VK_NN_VI_SURFACE_EXTENSION_NAME "VK_NN_vi_surface" @@ -40,7 +39,6 @@ typedef struct VkViSurfaceCreateInfoNN { void* window; } VkViSurfaceCreateInfoNN; - typedef VkResult (VKAPI_PTR *PFN_vkCreateViSurfaceNN)(VkInstance instance, const VkViSurfaceCreateInfoNN* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); #ifndef VK_NO_PROTOTYPES diff --git a/gfx/include/vulkan/vulkan_wayland.h b/gfx/include/vulkan/vulkan_wayland.h index 5ba0827aa3..a5b952af22 100644 --- a/gfx/include/vulkan/vulkan_wayland.h +++ b/gfx/include/vulkan/vulkan_wayland.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_wayland_surface 1 #define VK_KHR_WAYLAND_SURFACE_SPEC_VERSION 6 #define VK_KHR_WAYLAND_SURFACE_EXTENSION_NAME "VK_KHR_wayland_surface" @@ -41,7 +40,6 @@ typedef struct VkWaylandSurfaceCreateInfoKHR { struct wl_surface* surface; } VkWaylandSurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateWaylandSurfaceKHR)(VkInstance instance, const VkWaylandSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceWaylandPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, struct wl_display* display); diff --git a/gfx/include/vulkan/vulkan_win32.h b/gfx/include/vulkan/vulkan_win32.h index 6a85409ebe..8c248c547d 100644 --- a/gfx/include/vulkan/vulkan_win32.h +++ b/gfx/include/vulkan/vulkan_win32.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_win32_surface 1 #define VK_KHR_WIN32_SURFACE_SPEC_VERSION 6 #define VK_KHR_WIN32_SURFACE_EXTENSION_NAME "VK_KHR_win32_surface" @@ -41,7 +40,6 @@ typedef struct VkWin32SurfaceCreateInfoKHR { HWND hwnd; } VkWin32SurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateWin32SurfaceKHR)(VkInstance instance, const VkWin32SurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceWin32PresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex); @@ -90,7 +88,6 @@ typedef struct VkMemoryGetWin32HandleInfoKHR { VkExternalMemoryHandleTypeFlagBits handleType; } VkMemoryGetWin32HandleInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandleKHR)(VkDevice device, const VkMemoryGetWin32HandleInfoKHR* pGetWin32HandleInfo, HANDLE* pHandle); typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandlePropertiesKHR)(VkDevice device, VkExternalMemoryHandleTypeFlagBits handleType, HANDLE handle, VkMemoryWin32HandlePropertiesKHR* pMemoryWin32HandleProperties); @@ -123,8 +120,6 @@ typedef struct VkWin32KeyedMutexAcquireReleaseInfoKHR { const uint64_t* pReleaseKeys; } VkWin32KeyedMutexAcquireReleaseInfoKHR; - - #define VK_KHR_external_semaphore_win32 1 #define VK_KHR_EXTERNAL_SEMAPHORE_WIN32_SPEC_VERSION 1 #define VK_KHR_EXTERNAL_SEMAPHORE_WIN32_EXTENSION_NAME "VK_KHR_external_semaphore_win32" @@ -163,7 +158,6 @@ typedef struct VkSemaphoreGetWin32HandleInfoKHR { VkExternalSemaphoreHandleTypeFlagBits handleType; } VkSemaphoreGetWin32HandleInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkImportSemaphoreWin32HandleKHR)(VkDevice device, const VkImportSemaphoreWin32HandleInfoKHR* pImportSemaphoreWin32HandleInfo); typedef VkResult (VKAPI_PTR *PFN_vkGetSemaphoreWin32HandleKHR)(VkDevice device, const VkSemaphoreGetWin32HandleInfoKHR* pGetWin32HandleInfo, HANDLE* pHandle); @@ -207,7 +201,6 @@ typedef struct VkFenceGetWin32HandleInfoKHR { VkExternalFenceHandleTypeFlagBits handleType; } VkFenceGetWin32HandleInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkImportFenceWin32HandleKHR)(VkDevice device, const VkImportFenceWin32HandleInfoKHR* pImportFenceWin32HandleInfo); typedef VkResult (VKAPI_PTR *PFN_vkGetFenceWin32HandleKHR)(VkDevice device, const VkFenceGetWin32HandleInfoKHR* pGetWin32HandleInfo, HANDLE* pHandle); @@ -240,7 +233,6 @@ typedef struct VkExportMemoryWin32HandleInfoNV { DWORD dwAccess; } VkExportMemoryWin32HandleInfoNV; - typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryWin32HandleNV)(VkDevice device, VkDeviceMemory memory, VkExternalMemoryHandleTypeFlagsNV handleType, HANDLE* pHandle); #ifndef VK_NO_PROTOTYPES @@ -267,8 +259,6 @@ typedef struct VkWin32KeyedMutexAcquireReleaseInfoNV { const uint64_t* pReleaseKeys; } VkWin32KeyedMutexAcquireReleaseInfoNV; - - #ifdef __cplusplus } #endif diff --git a/gfx/include/vulkan/vulkan_xcb.h b/gfx/include/vulkan/vulkan_xcb.h index ba03600602..646a9928f9 100644 --- a/gfx/include/vulkan/vulkan_xcb.h +++ b/gfx/include/vulkan/vulkan_xcb.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_xcb_surface 1 #define VK_KHR_XCB_SURFACE_SPEC_VERSION 6 #define VK_KHR_XCB_SURFACE_EXTENSION_NAME "VK_KHR_xcb_surface" @@ -41,7 +40,6 @@ typedef struct VkXcbSurfaceCreateInfoKHR { xcb_window_t window; } VkXcbSurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateXcbSurfaceKHR)(VkInstance instance, const VkXcbSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceXcbPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, xcb_connection_t* connection, xcb_visualid_t visual_id); diff --git a/gfx/include/vulkan/vulkan_xlib.h b/gfx/include/vulkan/vulkan_xlib.h index e1d967e018..5ceb75de5e 100644 --- a/gfx/include/vulkan/vulkan_xlib.h +++ b/gfx/include/vulkan/vulkan_xlib.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_KHR_xlib_surface 1 #define VK_KHR_XLIB_SURFACE_SPEC_VERSION 6 #define VK_KHR_XLIB_SURFACE_EXTENSION_NAME "VK_KHR_xlib_surface" @@ -41,7 +40,6 @@ typedef struct VkXlibSurfaceCreateInfoKHR { Window window; } VkXlibSurfaceCreateInfoKHR; - typedef VkResult (VKAPI_PTR *PFN_vkCreateXlibSurfaceKHR)(VkInstance instance, const VkXlibSurfaceCreateInfoKHR* pCreateInfo, const VkAllocationCallbacks* pAllocator, VkSurfaceKHR* pSurface); typedef VkBool32 (VKAPI_PTR *PFN_vkGetPhysicalDeviceXlibPresentationSupportKHR)(VkPhysicalDevice physicalDevice, uint32_t queueFamilyIndex, Display* dpy, VisualID visualID); diff --git a/gfx/include/vulkan/vulkan_xlib_xrandr.h b/gfx/include/vulkan/vulkan_xlib_xrandr.h index 117d01799e..a79f3d1bb2 100644 --- a/gfx/include/vulkan/vulkan_xlib_xrandr.h +++ b/gfx/include/vulkan/vulkan_xlib_xrandr.h @@ -26,7 +26,6 @@ extern "C" { ** */ - #define VK_EXT_acquire_xlib_display 1 #define VK_EXT_ACQUIRE_XLIB_DISPLAY_SPEC_VERSION 1 #define VK_EXT_ACQUIRE_XLIB_DISPLAY_EXTENSION_NAME "VK_EXT_acquire_xlib_display" diff --git a/gfx/video_defines.h b/gfx/video_defines.h index 7633846589..1bef08c767 100644 --- a/gfx/video_defines.h +++ b/gfx/video_defines.h @@ -88,6 +88,7 @@ enum font_driver_render_api FONT_DRIVER_RENDER_D3D10_API, FONT_DRIVER_RENDER_D3D11_API, FONT_DRIVER_RENDER_D3D12_API, + FONT_DRIVER_RENDER_PS2, FONT_DRIVER_RENDER_VITA2D, FONT_DRIVER_RENDER_CTR, FONT_DRIVER_RENDER_WIIU, diff --git a/gfx/video_display_server.c b/gfx/video_display_server.c index e4824a0a46..f5f4f917ea 100644 --- a/gfx/video_display_server.c +++ b/gfx/video_display_server.c @@ -39,7 +39,7 @@ void* video_display_server_init(void) switch (type) { case RARCH_DISPLAY_WIN32: -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) current_display_server = &dispserv_win32; #endif break; @@ -89,7 +89,6 @@ bool video_display_server_set_window_decorations(bool on) return false; } - bool video_display_server_set_resolution(unsigned width, unsigned height, int int_hz, float hz, int center) { diff --git a/gfx/video_driver.c b/gfx/video_driver.c index a3b15c5932..ce9a83cc40 100644 --- a/gfx/video_driver.c +++ b/gfx/video_driver.c @@ -119,7 +119,6 @@ #define video_driver_context_unlock() ((void)0) #endif - typedef struct video_pixel_scaler { struct scaler_ctx *scaler; @@ -148,7 +147,6 @@ static bool video_driver_crt_switching_active = false; static struct retro_system_av_info video_driver_av_info; - static enum retro_pixel_format video_driver_pix_fmt = RETRO_PIXEL_FORMAT_0RGB1555; static const void *frame_cache_data = NULL; @@ -274,14 +272,14 @@ static const video_driver_t *video_drivers[] = { #ifdef XENON &video_xenon360, #endif -#if defined(HAVE_D3D10) - &video_d3d10, +#if defined(HAVE_D3D12) + &video_d3d12, #endif #if defined(HAVE_D3D11) &video_d3d11, #endif -#if defined(HAVE_D3D12) - &video_d3d12, +#if defined(HAVE_D3D10) + &video_d3d10, #endif #if defined(HAVE_D3D9) &video_d3d9, @@ -340,7 +338,7 @@ static const video_driver_t *video_drivers[] = { #ifdef HAVE_XSHM &video_xshm, #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) &video_gdi, #endif #ifdef DJGPP @@ -419,7 +417,7 @@ static const gfx_ctx_driver_t *gfx_ctx_drivers[] = { #if defined(HAVE_VULKAN) && defined(HAVE_VULKAN_DISPLAY) &gfx_ctx_khr_display, #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) &gfx_ctx_gdi, #endif #ifdef HAVE_SIXEL @@ -954,7 +952,6 @@ static bool video_driver_init_internal(bool *video_is_threaded) if (!string_is_empty(settings->paths.path_softfilter_plugin)) video_driver_init_filter(video_driver_pix_fmt); - max_dim = MAX(geom->max_width, geom->max_height); scale = next_pow2(max_dim) / RARCH_SCALE_BASE; scale = MAX(scale, 1); @@ -2025,7 +2022,6 @@ bool video_driver_read_viewport(uint8_t *buffer, bool is_idle) return false; } - bool video_driver_frame_filter_alive(void) { return !!video_driver_state_filter; @@ -2425,7 +2421,6 @@ void video_driver_frame(const void *data, unsigned width, } } - if (data) frame_cache_data = data; frame_cache_width = width; @@ -3150,7 +3145,6 @@ void video_context_driver_make_current(bool release) current_video_context.make_current(release); } - bool video_context_driver_translate_aspect(gfx_ctx_aspect_t *aspect) { if (!video_context_data || !aspect) @@ -3348,8 +3342,6 @@ bool video_driver_get_all_flags(gfx_ctx_flags_t *flags, enum display_flags flag) return false; } - - bool video_context_driver_set_flags(gfx_ctx_flags_t *flags) { if (!flags) diff --git a/gfx/video_driver.h b/gfx/video_driver.h index ba380809c4..eea9ef14e4 100644 --- a/gfx/video_driver.h +++ b/gfx/video_driver.h @@ -509,7 +509,6 @@ typedef bool (*get_metrics_cb)(void *data, enum display_metric_types type, float *value); typedef bool (*set_resize_cb)(void*, unsigned, unsigned); - typedef struct gfx_ctx_driver { /* The opaque pointer is the underlying video driver data (e.g. gl_t for @@ -749,7 +748,6 @@ typedef struct video_poke_interface const struct retro_hw_render_interface **iface); } video_poke_interface_t; - /* msg is for showing a message on the screen * along with the video frame. */ typedef bool (*video_driver_frame_t)(void *data, @@ -832,7 +830,6 @@ typedef struct video_driver unsigned (*wrap_type_to_enum)(enum gfx_wrap_type type); } video_driver_t; - extern struct aspect_ratio_elem aspectratio_lut[ASPECT_RATIO_END]; bool video_driver_has_windowed(void); @@ -1302,7 +1299,6 @@ extern const gfx_ctx_driver_t switch_ctx; extern const gfx_ctx_driver_t orbis_ctx; extern const gfx_ctx_driver_t gfx_ctx_null; - extern const shader_backend_t gl_glsl_backend; extern const shader_backend_t gl_cg_backend; extern const shader_backend_t shader_null_backend; diff --git a/gfx/video_filters/2xbr.c b/gfx/video_filters/2xbr.c index ef978ee741..83f347bb46 100644 --- a/gfx/video_filters/2xbr.c +++ b/gfx/video_filters/2xbr.c @@ -278,7 +278,6 @@ static void twoxbr_generic_destroy(void *data) ((((src & pg_blue_mask) - \ (dst & pg_blue_mask))) >>3))) ) - #define ALPHA_BLEND_8888_32_W(dst, src) \ dst = ( \ (pg_red_mask & ((dst & pg_red_mask) + \ @@ -292,7 +291,6 @@ static void twoxbr_generic_destroy(void *data) (dst & pg_blue_mask))) >>3))) ) +\ pg_alpha_mask - #define ALPHA_BLEND_64_W(dst, src) \ dst = ( \ (pg_red_mask & ((dst & pg_red_mask) + \ @@ -318,7 +316,6 @@ static void twoxbr_generic_destroy(void *data) (dst & pg_blue_mask))) >>2))) ) +\ pg_alpha_mask - #define ALPHA_BLEND_192_W(dst, src) \ dst = ( \ (pg_red_mask & ((dst & pg_red_mask) + \ @@ -331,7 +328,6 @@ static void twoxbr_generic_destroy(void *data) ((((src & pg_blue_mask) - \ (dst & pg_blue_mask)) * 192) >>8))) ) - #define ALPHA_BLEND_8888_192_W(dst, src) \ dst = ( \ (pg_red_mask & ((dst & pg_red_mask) + \ @@ -370,13 +366,11 @@ static void twoxbr_generic_destroy(void *data) (dst & pg_blue_mask)) * 224) >>8))) ) +\ pg_alpha_mask - #define LEFT_UP_2_2X(N3, N2, N1, PIXEL)\ ALPHA_BLEND_224_W(E[N3], PIXEL); \ ALPHA_BLEND_64_W( E[N2], PIXEL); \ E[N1] = E[N2]; \ - #define LEFT_2_2X(N3, N2, PIXEL)\ ALPHA_BLEND_192_W(E[N3], PIXEL); \ ALPHA_BLEND_64_W( E[N2], PIXEL); \ @@ -388,13 +382,11 @@ static void twoxbr_generic_destroy(void *data) #define DIA_2X(N3, PIXEL)\ ALPHA_BLEND_128_W(E[N3], PIXEL); \ - #define LEFT_UP_2_8888_2X(N3, N2, N1, PIXEL)\ ALPHA_BLEND_8888_224_W(E[N3], PIXEL); \ ALPHA_BLEND_8888_64_W( E[N2], PIXEL); \ E[N1] = E[N2]; \ - #define LEFT_2_8888_2X(N3, N2, PIXEL)\ ALPHA_BLEND_8888_192_W(E[N3], PIXEL); \ ALPHA_BLEND_8888_64_W( E[N2], PIXEL); \ @@ -406,15 +398,12 @@ static void twoxbr_generic_destroy(void *data) #define DIA_8888_2X(N3, PIXEL)\ ALPHA_BLEND_128_W(E[N3], PIXEL); \ - #define df(Z, A, B)\ abs(Z->RGBtoYUV[A] - Z->RGBtoYUV[B])\ #define eq(Z, A, B)\ (df(Z, A, B) < 155)\ - - float df8(uint32_t A, uint32_t B, uint32_t pg_red_mask, uint32_t pg_green_mask, uint32_t pg_blue_mask) { @@ -461,7 +450,6 @@ int eq8(uint32_t A, uint32_t B, return ((48 >= y) && (7 >= u) && (6 >= v)) ? 1 : 0; } - #define FILTRO_RGB565(Z, PE, _PI, PH, PF, PG, PC, PD, PB, PA, G5, C4, G0, D0, C1, B1, F4, I4, H5, I5, A0, A1, N0, N1, N2, N3, pg_red_mask, pg_green_mask, pg_blue_mask) \ ex = (PE!=PH && PE!=PF); \ if ( ex )\ @@ -531,7 +519,6 @@ int eq8(uint32_t A, uint32_t B, }\ }\ - #ifndef twoxbr_function #define twoxbr_function(FILTRO, Z) \ E[0] = E[1] = E[2] = E[3] = PE;\ @@ -547,7 +534,6 @@ int eq8(uint32_t A, uint32_t B, out += 2 #endif - static void twoxbr_generic_xrgb8888(void *data, unsigned width, unsigned height, int first, int last, uint32_t *src, unsigned src_stride, uint32_t *dst, unsigned dst_stride) diff --git a/gfx/video_filters/Makefile b/gfx/video_filters/Makefile index 3a1a3e6b8f..de2df86955 100644 --- a/gfx/video_filters/Makefile +++ b/gfx/video_filters/Makefile @@ -64,7 +64,6 @@ asflags := $(ASFLAGS) -fPIC $(extra_flags) objects := flags += -std=c99 - ifeq (1,$(use_neon)) ASMFLAGS := -INEON/asm asflags += -mfpu=neon diff --git a/gfx/video_filters/blargg_ntsc_snes.c b/gfx/video_filters/blargg_ntsc_snes.c index 334885981e..131ea3161d 100644 --- a/gfx/video_filters/blargg_ntsc_snes.c +++ b/gfx/video_filters/blargg_ntsc_snes.c @@ -54,7 +54,6 @@ struct filter_data int burst_toggle; }; - static unsigned blargg_ntsc_snes_generic_input_fmts(void) { return SOFTFILTER_FMT_RGB565; @@ -143,7 +142,6 @@ static void *blargg_ntsc_snes_generic_create(const struct softfilter_config *con return filt; } - static void blargg_ntsc_snes_generic_output(void *data, unsigned *out_width, unsigned *out_height, unsigned width, unsigned height) diff --git a/gfx/video_filters/epx.c b/gfx/video_filters/epx.c index 0256f80ca6..63bf788fa8 100644 --- a/gfx/video_filters/epx.c +++ b/gfx/video_filters/epx.c @@ -210,7 +210,6 @@ static void epx_work_cb_rgb565(void *data, void *thread_data) (unsigned)(thr->out_pitch / SOFTFILTER_BPP_RGB565)); } - static void epx_generic_packets(void *data, struct softfilter_work_packet *packets, void *output, size_t output_stride, diff --git a/gfx/video_filters/phosphor2x.c b/gfx/video_filters/phosphor2x.c index 8ba64afe2a..3fc84906c3 100644 --- a/gfx/video_filters/phosphor2x.c +++ b/gfx/video_filters/phosphor2x.c @@ -58,7 +58,6 @@ struct filter_data float scan_range_565[64]; }; - #define clamp8(x) ((x) > 255 ? 255 : ((x < 0) ? 0 : (uint32_t)x)) #define clamp6(x) ((x) > 63 ? 63 : ((x < 0) ? 0 : (uint32_t)x)) diff --git a/gfx/video_filters/snes_ntsc/snes_ntsc.h b/gfx/video_filters/snes_ntsc/snes_ntsc.h index d9aa710e27..a8e728a237 100644 --- a/gfx/video_filters/snes_ntsc/snes_ntsc.h +++ b/gfx/video_filters/snes_ntsc/snes_ntsc.h @@ -68,7 +68,6 @@ value. */ #define SNES_NTSC_IN_WIDTH( out_width ) \ (((out_width) / snes_ntsc_out_chunk - 1) * snes_ntsc_in_chunk + 1) - /* Interface for user-defined custom blitters */ enum { snes_ntsc_in_chunk = 3 }; /* number of input pixels read per chunk */ @@ -129,7 +128,6 @@ statement in a block (unless you're using C++). */ SNES_NTSC_RGB_OUT_( rgb_out, (bits), 0 );\ } - /* private */ enum { snes_ntsc_entry_size = 128 }; enum { snes_ntsc_palette_size = 0x2000 }; diff --git a/gfx/video_shader_parse.h b/gfx/video_shader_parse.h index 15d228a44f..39189992a4 100644 --- a/gfx/video_shader_parse.h +++ b/gfx/video_shader_parse.h @@ -46,7 +46,6 @@ RETRO_BEGIN_DECLS #define GFX_MAX_FRAME_HISTORY 128 #endif - enum rarch_shader_type { RARCH_SHADER_NONE = 0, diff --git a/gfx/video_state_tracker.c b/gfx/video_state_tracker.c index a36a50f8fb..cb57728135 100644 --- a/gfx/video_state_tracker.c +++ b/gfx/video_state_tracker.c @@ -288,7 +288,6 @@ unsigned state_tracker_get_uniform(state_tracker_t *tracker, state_tracker_update_input(&tracker->input_state[0], &tracker->input_state[1]); - for (i = 0; i < elems; i++) state_tracker_update_element( &uniforms[i], &tracker->info[i], frame_count); diff --git a/griffin/griffin.c b/griffin/griffin.c index 209788f3f5..12ca607fcd 100644 --- a/griffin/griffin.c +++ b/griffin/griffin.c @@ -230,7 +230,6 @@ VIDEO CONTEXT #include "../gfx/drivers_context/cgl_ctx.c" #endif - #if defined(HAVE_VIVANTE_FBDEV) #include "../gfx/drivers_context/vivante_fbdev_ctx.c" #endif @@ -498,6 +497,10 @@ FONTS #include "../gfx/drivers_font/xdk1_xfonts.c" #endif +#if defined(PS2) +#include "../gfx/drivers_font/ps2_font.c" +#endif + #if defined(VITA) #include "../gfx/drivers_font/vita2d_font.c" #endif @@ -604,6 +607,9 @@ INPUT #elif defined(DJGPP) #include "../input/drivers/dos_input.c" #include "../input/drivers_joypad/dos_joypad.c" +#elif defined(__WINRT__) +#include "../input/drivers/xdk_xinput_input.c" +#include "../input/drivers/uwp_input.c" #endif #ifdef HAVE_WAYLAND @@ -773,7 +779,7 @@ AUDIO #elif defined(PSP) || defined(VITA) || defined(ORBIS) #include "../audio/drivers/psp_audio.c" #elif defined(PS2) -// #include "../audio/drivers/ps2_audio.c" +#include "../audio/drivers/ps2_audio.c" #elif defined(_3DS) #include "../audio/drivers/ctr_csnd_audio.c" #include "../audio/drivers/ctr_dsp_audio.c" @@ -955,6 +961,10 @@ FRONTEND #include "../frontend/drivers/platform_win32.c" #endif +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#include "../frontend/drivers/platform_uwp.c" +#endif + #ifdef _XBOX #include "../frontend/drivers/platform_xdk.c" #endif @@ -1023,7 +1033,6 @@ GIT #include "../version_git.c" #endif - /*============================================================ RETROARCH ============================================================ */ @@ -1265,13 +1274,12 @@ MENU #include "../menu/drivers_display/menu_display_vga.c" #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) #include "../menu/drivers_display/menu_display_gdi.c" #endif #endif - #ifdef HAVE_RGUI #include "../menu/drivers/rgui.c" #endif @@ -1551,3 +1559,7 @@ SSL #endif #endif #endif + +#ifdef HAVE_EASTEREGG +#include "../cores/libretro-gong/gong.c" +#endif diff --git a/griffin/griffin_cpp.cpp b/griffin/griffin_cpp.cpp index fd3673afa0..e34561659f 100644 --- a/griffin/griffin_cpp.cpp +++ b/griffin/griffin_cpp.cpp @@ -43,7 +43,7 @@ UI #include "../ui/drivers/qt/ui_qt_browser_window.cpp" #include "../ui/drivers/qt/ui_qt_msg_window.cpp" #include "../ui/drivers/qt/ui_qt_application.cpp" -#include "../ui/drivers/qt/flowlayout.cpp" +#include "../ui/drivers/qt/gridview.cpp" #include "../ui/drivers/qt/shaderparamsdialog.cpp" #include "../ui/drivers/qt/coreoptionsdialog.cpp" #include "../ui/drivers/qt/filedropwidget.cpp" @@ -59,7 +59,7 @@ UI #include "../ui/drivers/qt/moc_coreinfodialog.cpp" #include "../ui/drivers/qt/moc_coreoptionsdialog.cpp" #include "../ui/drivers/qt/moc_filedropwidget.cpp" -#include "../ui/drivers/qt/moc_flowlayout.cpp" +#include "../ui/drivers/qt/moc_gridview.cpp" #include "../ui/drivers/qt/moc_playlistentrydialog.cpp" #include "../ui/drivers/qt/moc_shaderparamsdialog.cpp" #include "../ui/drivers/qt/moc_ui_qt_load_core_window.cpp" diff --git a/input/common/hid/device_wiiu_gca.c b/input/common/hid/device_wiiu_gca.c index 73e58681fb..b5198367b5 100644 --- a/input/common/hid/device_wiiu_gca.c +++ b/input/common/hid/device_wiiu_gca.c @@ -44,7 +44,6 @@ typedef struct gca_pad_data int16_t analog_state[3][2]; // analog state } gca_pad_t; - static void update_pad_state(wiiu_gca_instance_t *instance); static void unregister_pad(wiiu_gca_instance_t *instance, int port); @@ -279,7 +278,6 @@ static void update_analog_state(gca_pad_t *pad) } } - /** * The USB packet provides a 9-byte data packet for each pad. * @@ -302,8 +300,6 @@ static void wiiu_gca_packet_handler(void *data, uint8_t *packet, uint16_t size) update_analog_state(pad); } - - static void wiiu_gca_set_rumble(void *data, enum retro_rumble_effect effect, uint16_t strength) { (void)data; diff --git a/input/common/input_common.c b/input/common/input_common.c index 4f6e656363..c3580b400f 100644 --- a/input/common/input_common.c +++ b/input/common/input_common.c @@ -75,4 +75,3 @@ int16_t gamepad_get_axis_value(int16_t state[3][2], axis_data *data) return clamp_axis(value, data->is_negative); } - diff --git a/input/common/linux_common.c b/input/common/linux_common.c index 0d35611db1..9754fa7005 100644 --- a/input/common/linux_common.c +++ b/input/common/linux_common.c @@ -71,7 +71,6 @@ bool linux_terminal_init(void) if (tcsetattr(0, TCSAFLUSH, &newTerm) < 0) return false; - return true; } diff --git a/input/drivers/android_input.c b/input/drivers/android_input.c index 3e0339e9a0..47a1c3fa42 100644 --- a/input/drivers/android_input.c +++ b/input/drivers/android_input.c @@ -471,7 +471,6 @@ static void engine_handle_dpad_getaxisvalue(android_input_t *android, } #endif - static bool android_input_init_handle(void) { #ifdef HAVE_DYNAMIC diff --git a/input/drivers/cocoa_input.c b/input/drivers/cocoa_input.c index fa8454a6d7..b5dba8df36 100644 --- a/input/drivers/cocoa_input.c +++ b/input/drivers/cocoa_input.c @@ -136,7 +136,6 @@ int32_t cocoa_input_find_any_axis(uint32_t port) return 0; } - static void *cocoa_input_init(const char *joypad_driver) { cocoa_input_data_t *apple = (cocoa_input_data_t*)calloc(1, sizeof(*apple)); diff --git a/input/drivers/dinput.c b/input/drivers/dinput.c index 4d3b7cace7..f82cbf2a7a 100644 --- a/input/drivers/dinput.c +++ b/input/drivers/dinput.c @@ -98,6 +98,8 @@ void dinput_destroy_context(void) IDirectInput8_Release(g_dinput_ctx); g_dinput_ctx = NULL; + + CoUninitialize(); } bool dinput_init_context(void) @@ -105,7 +107,11 @@ bool dinput_init_context(void) if (g_dinput_ctx) return true; - CoInitialize(NULL); + if (FAILED(CoInitialize(NULL))) + { + RARCH_ERR("[DINPUT]: Failed to initialize the COM interface\n"); + return false; + } /* Who said we shouldn't have same call signature in a COM API? <_< */ #ifdef __cplusplus @@ -125,11 +131,10 @@ bool dinput_init_context(void) error: RARCH_ERR("[DINPUT]: Failed to initialize DirectInput.\n"); + CoUninitialize(); return false; } - - static void *dinput_init(const char *joypad_driver) { struct dinput_input *di = NULL; @@ -239,7 +244,6 @@ static void dinput_poll(void *data) di->mouse_rel_x = mouse_state.lX; di->mouse_rel_y = mouse_state.lY; - if (!mouse_state.rgbButtons[0]) unset_doubleclick_on_titlebar(); if (doubleclick_on_titlebar_pressed()) diff --git a/input/drivers/nullinput.c b/input/drivers/nullinput.c index e449e1d7fa..7de6d63867 100644 --- a/input/drivers/nullinput.c +++ b/input/drivers/nullinput.c @@ -87,7 +87,6 @@ static bool nullinput_keyboard_mapping_is_blocked(void *data) return false; } - input_driver_t input_null = { nullinput_input_init, nullinput_input_poll, diff --git a/input/drivers/ps2_input.c b/input/drivers/ps2_input.c index 6942c700f9..733bd75b04 100644 --- a/input/drivers/ps2_input.c +++ b/input/drivers/ps2_input.c @@ -1,6 +1,5 @@ /* RetroArch - A frontend for libretro. - * Copyright (C) 2010-2014 - Hans-Kristian Arntzen - * Copyright (C) 2011-2017 - Daniel De Matteis + * Copyright (C) 2011-2018 - Francisco Javier Trujillo Mata - fjtrujy * * RetroArch is free software: you can redistribute it and/or modify it under the terms * of the GNU General Public License as published by the Free Software Found- diff --git a/input/drivers/ps3_input.c b/input/drivers/ps3_input.c index 7d8fee8b83..fead6eefc8 100644 --- a/input/drivers/ps3_input.c +++ b/input/drivers/ps3_input.c @@ -164,7 +164,6 @@ static void ps3_input_free_input(void *data) free(data); } - static void* ps3_input_init(const char *joypad_driver) { ps3_input_t *ps3 = (ps3_input_t*)calloc(1, sizeof(*ps3)); diff --git a/input/drivers/qnx_input.c b/input/drivers/qnx_input.c index 276a1f3ca2..19d21e78a6 100644 --- a/input/drivers/qnx_input.c +++ b/input/drivers/qnx_input.c @@ -307,7 +307,6 @@ static void qnx_handle_device(qnx_input_t *qnx, RARCH_LOG("\tAnalog Count: %d\n", controller->analogCount); } - /* Find currently connected gamepads. */ static void qnx_discover_controllers(qnx_input_t *qnx) { diff --git a/input/drivers/udev_input.c b/input/drivers/udev_input.c index f143a44a30..f4e24ea512 100644 --- a/input/drivers/udev_input.c +++ b/input/drivers/udev_input.c @@ -14,7 +14,8 @@ * If not, see . */ -/* TODO/FIXME - set this once the kqueue codepath is implemented and working properly */ +/* TODO/FIXME - set this once the kqueue codepath is implemented and working properly, + * also remove libepoll-shim from the Makefile when that happens. */ #if 1 #define HAVE_EPOLL #else @@ -46,7 +47,9 @@ #include #include +#ifdef __linux__ #include +#endif #include #include @@ -131,7 +134,6 @@ struct udev_input struct udev *udev; struct udev_monitor *monitor; - const input_device_driver_t *joypad; int fd; @@ -222,7 +224,7 @@ static udev_input_mouse_t *udev_get_mouse(struct udev_input *udev, unsigned port settings_t *settings = config_get_ptr(); udev_input_mouse_t *mouse = NULL; - if (port >= MAX_USERS) + if (port >= MAX_USERS || !video_driver_cb_has_focus()) return NULL; for (i = 0; i < udev->num_devices; ++i) @@ -1204,7 +1206,9 @@ static void *udev_input_init(const char *joypad_driver) udev->joypad = input_joypad_init_driver(joypad_driver, udev); input_keymaps_init_keyboard_lut(rarch_key_map_linux); +#ifdef __linux__ linux_terminal_disable_input(); +#endif #ifndef HAVE_X11 RARCH_WARN("[udev]: Full-screen pointer won't be available.\n"); @@ -1299,7 +1303,11 @@ input_driver_t input_udev = { udev_input_get_capabilities, "udev", udev_input_grab_mouse, +#ifdef __linux__ linux_terminal_grab_stdin, +#else + NULL, +#endif udev_input_set_rumble, udev_input_get_joypad_driver, NULL, diff --git a/input/drivers/uwp_input.c b/input/drivers/uwp_input.c new file mode 100644 index 0000000000..4c2f53af19 --- /dev/null +++ b/input/drivers/uwp_input.c @@ -0,0 +1,174 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2018 - Krzysztof Haładyn + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#include +#include + +#ifdef HAVE_CONFIG_H +#include "../../config.h" +#endif + +#include +#include + +#include + +#include "../input_driver.h" + +// TODO: Add support for multiple mice and multiple touch + +typedef struct uwp_input +{ + bool blocked; + const input_device_driver_t *joypad; +} uwp_input_t; + +static void uwp_input_poll(void *data) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + + if (uwp && uwp->joypad) + uwp->joypad->poll(); + + uwp_input_next_frame(); +} + +static int16_t uwp_input_state(void *data, + rarch_joypad_info_t joypad_info, + const struct retro_keybind **binds, + unsigned port, unsigned device, + unsigned index, unsigned id) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + + switch (device) + { + case RETRO_DEVICE_JOYPAD: + return input_joypad_pressed(uwp->joypad, joypad_info, port, binds[port], id); + case RETRO_DEVICE_ANALOG: + if (binds[port]) + return input_joypad_analog(uwp->joypad, joypad_info, port, index, id, binds[port]); + break; + + case RETRO_DEVICE_KEYBOARD: + return (id < RETROK_LAST) && uwp_keyboard_pressed(id); + + case RETRO_DEVICE_MOUSE: + case RARCH_DEVICE_MOUSE_SCREEN: + return uwp_mouse_state(port, id, device == RARCH_DEVICE_MOUSE_SCREEN); + + case RETRO_DEVICE_POINTER: + case RARCH_DEVICE_POINTER_SCREEN: + return uwp_pointer_state(index, id, device == RARCH_DEVICE_POINTER_SCREEN); + } + + return 0; +} + +static void uwp_input_free_input(void *data) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + + if (!uwp) + return; + + if (uwp->joypad) + uwp->joypad->destroy(); + + free(uwp); +} + +static void *uwp_input_init(const char *joypad_driver) +{ + uwp_input_t *uwp = (uwp_input_t*)calloc(1, sizeof(*uwp)); + if (!uwp) + return NULL; + + input_keymaps_init_keyboard_lut(rarch_key_map_uwp); + + uwp->joypad = input_joypad_init_driver(joypad_driver, uwp); + + return uwp; +} + +static uint64_t uwp_input_get_capabilities(void *data) +{ + uint64_t caps = 0; + + caps |= (1 << RETRO_DEVICE_JOYPAD); + caps |= (1 << RETRO_DEVICE_MOUSE); + caps |= (1 << RETRO_DEVICE_KEYBOARD); + caps |= (1 << RETRO_DEVICE_POINTER); + caps |= (1 << RETRO_DEVICE_ANALOG); + + return caps; +} + +static bool uwp_input_set_rumble(void *data, unsigned port, + enum retro_rumble_effect effect, uint16_t strength) +{ + struct uwp_input *uwp = (struct uwp_input*)data; + if (!uwp) + return false; + return input_joypad_set_rumble(uwp->joypad, port, effect, strength); +} + +static const input_device_driver_t *uwp_input_get_joypad_driver(void *data) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + if (!uwp) + return NULL; + return uwp->joypad; +} + +static void uwp_input_grab_mouse(void *data, bool state) +{ + (void)data; + (void)state; +} + +static bool uwp_keyboard_mapping_is_blocked(void *data) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + if (!uwp) + return false; + return uwp->blocked; +} + +static void uwp_keyboard_mapping_set_block(void *data, bool value) +{ + uwp_input_t *uwp = (uwp_input_t*)data; + if (!uwp) + return; + uwp->blocked = value; +} + +input_driver_t input_uwp = { + uwp_input_init, + uwp_input_poll, + uwp_input_state, + uwp_input_free_input, + NULL, + NULL, + uwp_input_get_capabilities, + "uwp", + uwp_input_grab_mouse, + NULL, + uwp_input_set_rumble, + uwp_input_get_joypad_driver, + NULL, + uwp_keyboard_mapping_is_blocked, + uwp_keyboard_mapping_set_block, +}; diff --git a/input/drivers/wayland_input.c b/input/drivers/wayland_input.c index 88b7169d1d..0955e104c8 100644 --- a/input/drivers/wayland_input.c +++ b/input/drivers/wayland_input.c @@ -50,7 +50,6 @@ /* TODO/FIXME - * fix game focus toggle */ - /* Forward declaration */ void flush_wayland_fd(void *data); @@ -282,9 +281,6 @@ static int16_t input_wl_touch_state(input_ctx_wayland_data_t *wl, return 0; } - - - static int16_t input_wl_state(void *data, rarch_joypad_info_t joypad_info, const struct retro_keybind **binds, diff --git a/input/drivers/wiiu_input.c b/input/drivers/wiiu_input.c index ba00ed971a..fae110f2f7 100644 --- a/input/drivers/wiiu_input.c +++ b/input/drivers/wiiu_input.c @@ -71,7 +71,6 @@ void kb_key_callback(KBDKeyEvent *key) if (code < RETROK_LAST) keyboardState[code] = pressed; - if (key->modifier & KBD_WIIU_SHIFT) mod |= RETROKMOD_SHIFT; diff --git a/input/drivers/x11_input.c b/input/drivers/x11_input.c index 466c94b2e3..77cd53438d 100644 --- a/input/drivers/x11_input.c +++ b/input/drivers/x11_input.c @@ -452,7 +452,6 @@ static void x_input_poll_mouse(x11_input_t *x11) } } - static void x_input_poll(void *data) { x11_input_t *x11 = (x11_input_t*)data; diff --git a/input/drivers_hid/btstack_hid.c b/input/drivers_hid/btstack_hid.c index cf7e1cf6c9..f690a26a80 100644 --- a/input/drivers_hid/btstack_hid.c +++ b/input/drivers_hid/btstack_hid.c @@ -459,7 +459,6 @@ extern const hci_cmd_t rfcomm_persistent_channel_for_service; /* linked_list.h */ - void linked_item_set_user(linked_item_t *item, void *user_data); void * linked_item_get_user(linked_item_t *item); @@ -478,8 +477,6 @@ void test_linked_list(void); /* run_loop.h */ - - /* Set timer based on current time in milliseconds. */ void run_loop_set_timer(timer_source_t *a, uint32_t timeout_in_ms); @@ -526,7 +523,6 @@ uint32_t embedded_get_ticks(void); /* Connection handle type. */ - /* helper for BT little endian format. */ #define READ_BT_16( buffer, pos) ( ((uint16_t) buffer[pos]) | (((uint16_t)buffer[pos+1]) << 8)) #define READ_BT_24( buffer, pos) ( ((uint32_t) buffer[pos]) | (((uint32_t)buffer[pos+1]) << 8) | (((uint32_t)buffer[pos+2]) << 16)) @@ -592,7 +588,6 @@ uint8_t crc8_calc(uint8_t *data, uint16_t len); /* UNIX domain socket for BTstack. */ #define BTSTACK_UNIX "/tmp/BTstack" - /* Optional * * If called before bt_open, TCP socket is used @@ -975,7 +970,6 @@ static struct btstack_hid_adapter *btpad_find_connection_for( return 0; } - static void btpad_queue_reset(void) { insert_position = 0; @@ -983,7 +977,6 @@ static void btpad_queue_reset(void) can_run = 1; } - static void btpad_queue_btstack_set_power_mode( struct btpad_queue_command *cmd, uint8_t on) { @@ -997,8 +990,6 @@ static void btpad_queue_btstack_set_power_mode( btpad_queue_process(); } - - static void btpad_set_inquiry_state(bool on) { inquiry_off = !on; @@ -1348,8 +1339,6 @@ static void btstack_set_poweron(bool on) } } - - static bool btstack_hid_joypad_query(void *data, unsigned pad) { return pad < MAX_USERS; diff --git a/input/drivers_hid/iohidmanager_hid.c b/input/drivers_hid/iohidmanager_hid.c index 2f0a8da0fe..9a52f08f7e 100644 --- a/input/drivers_hid/iohidmanager_hid.c +++ b/input/drivers_hid/iohidmanager_hid.c @@ -545,9 +545,6 @@ static void iohidmanager_hid_device_get_product_string( CFStringGetCString(ref, buf, len, kCFStringEncodingUTF8); } - - - static void iohidmanager_hid_device_add_autodetect(unsigned idx, const char *device_name, const char *driver_name, uint16_t dev_vid, uint16_t dev_pid) @@ -877,7 +874,6 @@ static void iohidmanager_hid_device_add_device( tmpButtons = next; } - iohidmanager_hid_device_add_autodetect(adapter->slot, adapter->name, iohidmanager_hid.ident, dev_vid, dev_pid); @@ -967,7 +963,6 @@ static int iohidmanager_hid_manager_init(iohidmanager_hid_t *hid) return 0; } - static int iohidmanager_hid_manager_free(iohidmanager_hid_t *hid) { if (!hid || !hid->ptr) @@ -1059,7 +1054,6 @@ static int iohidmanager_hid_manager_set_device_matching( } free(device_array); - #if !(defined(__ppc__) || defined(__ppc64__)) /* register call back to dynamically add device plugged when retroarch is * running diff --git a/input/drivers_hid/libusb_hid.c b/input/drivers_hid/libusb_hid.c index b7622b92c1..4f564df244 100644 --- a/input/drivers_hid/libusb_hid.c +++ b/input/drivers_hid/libusb_hid.c @@ -428,7 +428,6 @@ static int libusb_hid_hotplug_callback(struct libusb_context *ctx, return 0; } - static bool libusb_hid_joypad_query(void *data, unsigned pad) { return pad < MAX_USERS; @@ -639,7 +638,6 @@ error: return NULL; } - static void libusb_hid_poll(void *data) { (void)data; diff --git a/input/drivers_hid/wiiu_hid.c b/input/drivers_hid/wiiu_hid.c index ca15e41249..f18e9ad3bd 100644 --- a/input/drivers_hid/wiiu_hid.c +++ b/input/drivers_hid/wiiu_hid.c @@ -240,7 +240,6 @@ static int32_t wiiu_hid_read(void *data, void *buffer, size_t size) return result; } - static void start_polling_thread(wiiu_hid_t *hid) { OSThreadAttributes attributes = OS_THREAD_ATTRIB_AFFINITY_CPU2; @@ -285,7 +284,6 @@ error: return; } - static void stop_polling_thread(wiiu_hid_t *hid) { int thread_result = 0; @@ -328,7 +326,6 @@ static void log_device(HIDDevice *device) RARCH_LOG(" max_packet_size_tx: %d\n", device->max_packet_size_tx); } - static uint8_t try_init_driver(wiiu_adapter_t *adapter) { adapter->driver_handle = adapter->driver->init(adapter); @@ -460,7 +457,6 @@ static void wiiu_hid_detach(wiiu_hid_t *hid, wiiu_attach_event *event) adapter->connected = false; } - static void wiiu_hid_attach(wiiu_hid_t *hid, wiiu_attach_event *event) { wiiu_adapter_t *adapter = new_adapter(event); @@ -798,7 +794,6 @@ static void delete_attach_event(wiiu_attach_event *event) free(event); } - void *alloc_zeroed(size_t alignment, size_t size) { void *result = memalign(alignment, size); @@ -808,7 +803,6 @@ void *alloc_zeroed(size_t alignment, size_t size) return result; } - hid_driver_t wiiu_hid = { wiiu_hid_init, wiiu_hid_joypad_query, diff --git a/input/drivers_joypad/android_joypad.c b/input/drivers_joypad/android_joypad.c index a818406092..fa1b8e3596 100644 --- a/input/drivers_joypad/android_joypad.c +++ b/input/drivers_joypad/android_joypad.c @@ -94,7 +94,6 @@ static bool android_joypad_query_pad(unsigned pad) return (pad < MAX_USERS); } - static void android_joypad_destroy(void) { unsigned i, j; diff --git a/input/drivers_joypad/ctr_joypad.c b/input/drivers_joypad/ctr_joypad.c index 1bfd559cd2..6bf24ab9cc 100644 --- a/input/drivers_joypad/ctr_joypad.c +++ b/input/drivers_joypad/ctr_joypad.c @@ -185,7 +185,6 @@ static bool ctr_joypad_query_pad(unsigned pad) return pad < MAX_USERS && pad_state; } - static void ctr_joypad_destroy(void) { } diff --git a/input/drivers_joypad/linuxraw_joypad.c b/input/drivers_joypad/linuxraw_joypad.c index b87a6e7bd0..8a209aa5a7 100644 --- a/input/drivers_joypad/linuxraw_joypad.c +++ b/input/drivers_joypad/linuxraw_joypad.c @@ -371,7 +371,6 @@ static bool linuxraw_joypad_query_pad(unsigned pad) return pad < MAX_USERS && linuxraw_pads[pad].fd >= 0; } - input_device_driver_t linuxraw_joypad = { linuxraw_joypad_init, linuxraw_joypad_query_pad, diff --git a/input/drivers_joypad/null_joypad.c b/input/drivers_joypad/null_joypad.c index d41198a8bf..1c4ad06956 100644 --- a/input/drivers_joypad/null_joypad.c +++ b/input/drivers_joypad/null_joypad.c @@ -56,7 +56,6 @@ static bool null_joypad_query_pad(unsigned pad) return true; } - static void null_joypad_destroy(void) { } diff --git a/input/drivers_joypad/ps2_joypad.c b/input/drivers_joypad/ps2_joypad.c index 969c075ebe..8ba07273c6 100644 --- a/input/drivers_joypad/ps2_joypad.c +++ b/input/drivers_joypad/ps2_joypad.c @@ -1,7 +1,5 @@ /* RetroArch - A frontend for libretro. - * Copyright (C) 2010-2014 - Hans-Kristian Arntzen - * Copyright (C) 2011-2017 - Daniel De Matteis - * Copyright (C) 2013-2014 - CatalystG + * Copyright (C) 2011-2018 - Francisco Javier Trujillo Mata - fjtrujy * * RetroArch is free software: you can redistribute it and/or modify it under the terms * of the GNU General Public License as published by the Free Software Found- @@ -23,17 +21,14 @@ #include "libpad.h" -#define PS2_MAX_PADS 1 +#define PS2_MAX_PADS 2 +#define PS2_PAD_SLOT 0 /* Always zero if not using multitap */ -/* - * Global var's - */ -// pad_dma_buf is provided by the user, one buf for each pad -// contains the pad's current state -static char padBuf[256] __attribute__((aligned(64))); +static unsigned char padBuf[2][256] ALIGNED(64); static uint64_t pad_state[PS2_MAX_PADS]; +extern uint64_t lifecycle_state; static const char *ps2_joypad_name(unsigned pad) { @@ -42,41 +37,32 @@ static const char *ps2_joypad_name(unsigned pad) static bool ps2_joypad_init(void *data) { - unsigned i; - unsigned players_count = PS2_MAX_PADS; + unsigned ret, port; + bool init = true; - for (i = 0; i < players_count; i++) - { - bool auto_configure = input_autoconfigure_connect( ps2_joypad_name(i), + printf("PortMax: %d\n", padGetPortMax()); + printf("SlotMax: %d\n", padGetSlotMax(port)); + + for (port = 0; port < PS2_MAX_PADS; port++) { + bool auto_configure = input_autoconfigure_connect( ps2_joypad_name(port), NULL, ps2_joypad.ident, - i, + port, 0, 0); if (!auto_configure) { - input_config_set_device_name(i, ps2_joypad_name(i)); + input_config_set_device_name(port, ps2_joypad_name(port)); } - padInit(i); - - int ret; - int port, slot; - - port = 0; // 0 -> Connector 1, 1 -> Connector 2 - slot = 0; // Always zero if not using multitap - - printf("PortMax: %d\n", padGetPortMax()); - printf("SlotMax: %d\n", padGetSlotMax(port)); - - - if((ret = padPortOpen(port, slot, padBuf)) == 0) { + /* Port 0 -> Connector 1, Port 1 -> Connector 2 */ + if((ret = padPortOpen(port, PS2_PAD_SLOT, padBuf[port])) == 0) { printf("padOpenPort failed: %d\n", ret); + init = false; + break; } - - } - return true; + return init; } static bool ps2_joypad_button(unsigned port_num, uint16_t joykey) @@ -100,38 +86,34 @@ static int16_t ps2_joypad_axis(unsigned port_num, uint32_t joyaxis) static void ps2_joypad_poll(void) { unsigned player; - unsigned players_count = PS2_MAX_PADS; struct padButtonStatus buttons; - for (player = 0; player < players_count; player++) - { - unsigned j, k; - unsigned i = player; - unsigned p = player; - - int ret = padRead(player, player, &buttons); // port, slot, buttons - if (ret != 0) - { - int32_t state_tmp = 0xffff ^ buttons.btns; + for (player = 0; player < PS2_MAX_PADS; player++) { + int state = padGetState(player, PS2_PAD_SLOT); + if (state == PAD_STATE_STABLE) { + int ret = padRead(player, PS2_PAD_SLOT, &buttons); /* port, slot, buttons */ + if (ret != 0) { + int32_t state_tmp = 0xffff ^ buttons.btns; + pad_state[player] = 0; - pad_state[i] = 0; - - pad_state[i] |= (state_tmp & PAD_LEFT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_LEFT) : 0; - pad_state[i] |= (state_tmp & PAD_DOWN) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_DOWN) : 0; - pad_state[i] |= (state_tmp & PAD_RIGHT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_RIGHT) : 0; - pad_state[i] |= (state_tmp & PAD_UP) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_UP) : 0; - pad_state[i] |= (state_tmp & PAD_START) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_START) : 0; - pad_state[i] |= (state_tmp & PAD_SELECT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_SELECT) : 0; - pad_state[i] |= (state_tmp & PAD_TRIANGLE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_X) : 0; - pad_state[i] |= (state_tmp & PAD_SQUARE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_Y) : 0; - pad_state[i] |= (state_tmp & PAD_CROSS) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_B) : 0; - pad_state[i] |= (state_tmp & PAD_CIRCLE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_A) : 0; - pad_state[i] |= (state_tmp & PAD_R1) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R) : 0; - pad_state[i] |= (state_tmp & PAD_L1) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L) : 0; - pad_state[i] |= (state_tmp & PAD_R2) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R2) : 0; - pad_state[i] |= (state_tmp & PAD_L2) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L2) : 0; - pad_state[i] |= (state_tmp & PAD_R3) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R3) : 0; - pad_state[i] |= (state_tmp & PAD_L3) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L3) : 0; + pad_state[player] |= (state_tmp & PAD_LEFT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_LEFT) : 0; + pad_state[player] |= (state_tmp & PAD_DOWN) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_DOWN) : 0; + pad_state[player] |= (state_tmp & PAD_RIGHT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_RIGHT) : 0; + pad_state[player] |= (state_tmp & PAD_UP) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_UP) : 0; + pad_state[player] |= (state_tmp & PAD_START) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_START) : 0; + pad_state[player] |= (state_tmp & PAD_SELECT) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_SELECT) : 0; + pad_state[player] |= (state_tmp & PAD_TRIANGLE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_X) : 0; + pad_state[player] |= (state_tmp & PAD_SQUARE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_Y) : 0; + pad_state[player] |= (state_tmp & PAD_CROSS) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_B) : 0; + pad_state[player] |= (state_tmp & PAD_CIRCLE) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_A) : 0; + pad_state[player] |= (state_tmp & PAD_R1) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R) : 0; + pad_state[player] |= (state_tmp & PAD_L1) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L) : 0; + pad_state[player] |= (state_tmp & PAD_R2) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R2) : 0; + pad_state[player] |= (state_tmp & PAD_L2) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L2) : 0; + pad_state[player] |= (state_tmp & PAD_R3) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_R3) : 0; + pad_state[player] |= (state_tmp & PAD_L3) ? (UINT64_C(1) << RETRO_DEVICE_ID_JOYPAD_L3) : 0; + + } } } @@ -148,9 +130,12 @@ static bool ps2_joypad_rumble(unsigned pad, return false; } - static void ps2_joypad_destroy(void) { + unsigned port; + for (port = 0; port < PS2_MAX_PADS; port++) { + padPortClose(port, PS2_PAD_SLOT); + } } input_device_driver_t ps2_joypad = { diff --git a/input/drivers_joypad/ps3_joypad.c b/input/drivers_joypad/ps3_joypad.c index 0088f6d256..79d8748776 100644 --- a/input/drivers_joypad/ps3_joypad.c +++ b/input/drivers_joypad/ps3_joypad.c @@ -266,7 +266,6 @@ static void ps3_joypad_destroy(void) cellPadEnd(); } - input_device_driver_t ps3_joypad = { ps3_joypad_init, ps3_joypad_query_pad, diff --git a/input/drivers_joypad/psp_joypad.c b/input/drivers_joypad/psp_joypad.c index 309a8a0f3c..6bba2eba92 100644 --- a/input/drivers_joypad/psp_joypad.c +++ b/input/drivers_joypad/psp_joypad.c @@ -375,7 +375,6 @@ static bool psp_joypad_rumble(unsigned pad, #endif } - static void psp_joypad_destroy(void) { } diff --git a/input/drivers_joypad/qnx_joypad.c b/input/drivers_joypad/qnx_joypad.c index 7279779e1e..ece4871971 100644 --- a/input/drivers_joypad/qnx_joypad.c +++ b/input/drivers_joypad/qnx_joypad.c @@ -120,7 +120,6 @@ static bool qnx_joypad_query_pad(unsigned pad) return (pad < MAX_USERS); } - static void qnx_joypad_destroy(void) { } diff --git a/input/drivers_joypad/rwebpad_joypad.c b/input/drivers_joypad/rwebpad_joypad.c index 4278afb757..3159bf69a5 100644 --- a/input/drivers_joypad/rwebpad_joypad.c +++ b/input/drivers_joypad/rwebpad_joypad.c @@ -47,7 +47,6 @@ static EM_BOOL rwebpad_gamepad_cb(int event_type, pid = 1; } - if (event_type == EMSCRIPTEN_EVENT_GAMEPADCONNECTED) { if(!input_autoconfigure_connect( @@ -199,7 +198,6 @@ static bool rwebpad_joypad_query_pad(unsigned pad) return false; } - static void rwebpad_joypad_destroy(void) { } diff --git a/input/drivers_joypad/sdl_joypad.c b/input/drivers_joypad/sdl_joypad.c index 05ccfad1a5..8a3c224ab6 100644 --- a/input/drivers_joypad/sdl_joypad.c +++ b/input/drivers_joypad/sdl_joypad.c @@ -399,6 +399,8 @@ static void sdl_joypad_poll(void) break; } } + + SDL_FlushEvents(SDL_JOYAXISMOTION, SDL_CONTROLLERDEVICEREMAPPED); #else SDL_JoystickUpdate(); #endif diff --git a/input/drivers_joypad/switch_joypad.c b/input/drivers_joypad/switch_joypad.c index b92397779b..c40745af31 100644 --- a/input/drivers_joypad/switch_joypad.c +++ b/input/drivers_joypad/switch_joypad.c @@ -17,7 +17,6 @@ #include "../../command.h" #include "string.h" - #ifdef HAVE_LIBNX #ifndef MAX_PADS diff --git a/input/drivers_joypad/udev_joypad.c b/input/drivers_joypad/udev_joypad.c index 2841032dda..26a577ed8f 100644 --- a/input/drivers_joypad/udev_joypad.c +++ b/input/drivers_joypad/udev_joypad.c @@ -25,7 +25,9 @@ #include #include #include +#ifdef __linux__ #include +#endif #include #include @@ -116,7 +118,6 @@ static int udev_find_vacant_pad(void) return -1; } - static int udev_open_joystick(const char *path) { unsigned long evbit[NBITS(EV_MAX)] = {0}; diff --git a/input/drivers_joypad/wiiu/wpad_driver.c b/input/drivers_joypad/wiiu/wpad_driver.c index 3f008342c7..82ced41e99 100644 --- a/input/drivers_joypad/wiiu/wpad_driver.c +++ b/input/drivers_joypad/wiiu/wpad_driver.c @@ -51,7 +51,6 @@ static int16_t scale_touchpad(int16_t from_min, int16_t from_max, return (((value - from_min) * to_range) / from_range) + to_min; } - static void get_calibrated_point(VPADTouchData *point, struct video_viewport *viewport, VPADStatus *vpad) { VPADTouchData calibrated720p = {0}; @@ -154,7 +153,6 @@ static void update_touch_state(int16_t state[3][2], uint64_t *buttons, VPADStatu state[WIIU_DEVICE_INDEX_TOUCHPAD][RETRO_DEVICE_ID_ANALOG_Y]); #endif - if (!touch_clamped) *buttons |= VPAD_BUTTON_TOUCH; else @@ -167,7 +165,6 @@ static void check_panic_button(uint32_t held_buttons) command_event(CMD_EVENT_QUIT, NULL); } - static void wpad_poll(void) { VPADStatus vpad; diff --git a/input/drivers_joypad/wiiu_joypad.c b/input/drivers_joypad/wiiu_joypad.c index 12151519ef..69acd5605c 100644 --- a/input/drivers_joypad/wiiu_joypad.c +++ b/input/drivers_joypad/wiiu_joypad.c @@ -21,7 +21,6 @@ static input_device_driver_t *pad_drivers[MAX_USERS]; extern pad_connection_listener_t wiiu_pad_connection_listener; - static bool ready = false; static bool wiiu_joypad_init(void *data); diff --git a/input/drivers_joypad/xinput_joypad.c b/input/drivers_joypad/xinput_joypad.c index a7b5e639a8..9dd3e5208f 100644 --- a/input/drivers_joypad/xinput_joypad.c +++ b/input/drivers_joypad/xinput_joypad.c @@ -44,10 +44,15 @@ #include "dinput_joypad.h" #endif +#if defined(__WINRT__) +#include +#endif + /* Check if the definitions do not already exist. * Official and mingw xinput headers have different include guards. + * Windows 10 API version doesn't have an include guard at all and just uses #pragma once instead */ -#if ((!_XINPUT_H_) && (!__WINE_XINPUT_H)) +#if ((!_XINPUT_H_) && (!__WINE_XINPUT_H)) && !defined(__WINRT__) #define XINPUT_GAMEPAD_DPAD_UP 0x0001 #define XINPUT_GAMEPAD_DPAD_DOWN 0x0002 @@ -96,6 +101,7 @@ typedef struct #define ERROR_DEVICE_NOT_CONNECTED 1167 #endif +#ifdef HAVE_DINPUT /* Due to 360 pads showing up under both XInput and DirectInput, * and since we are going to have to pass through unhandled * joypad numbers to DirectInput, a slightly ugly @@ -106,6 +112,7 @@ typedef struct */ extern int g_xinput_pad_indexes[MAX_USERS]; extern bool g_xinput_block_pads; +#endif #ifdef HAVE_DYNAMIC /* For xinput1_n.dll */ @@ -134,7 +141,11 @@ static xinput_joypad_state g_xinput_states[4]; static INLINE int pad_index_to_xuser_index(unsigned pad) { +#ifdef HAVE_DINPUT return g_xinput_pad_indexes[pad]; +#else + return pad < MAX_PADS && g_xinput_states[pad].connected ? pad : -1; +#endif } /* Generic "XInput" instead of "Xbox 360", because there are @@ -173,7 +184,7 @@ const char *xinput_joypad_name(unsigned pad) return XBOX_CONTROLLER_NAMES[xuser]; } -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) static bool load_xinput_dll(void) { const char *version = "1.4"; @@ -210,7 +221,7 @@ static bool xinput_joypad_init(void *data) unsigned i, j; XINPUT_STATE dummy_state; -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) if (!g_xinput_dll) if (!load_xinput_dll()) return false; @@ -219,6 +230,9 @@ static bool xinput_joypad_init(void *data) * First try to load ordinal 100 (XInputGetStateEx). */ g_XInputGetStateEx = (XInputGetStateEx_t)dylib_proc(g_xinput_dll, (const char*)100); +#elif defined(__WINRT__) + /* XInputGetStateEx is not available on WinRT */ + g_XInputGetStateEx = NULL; #else g_XInputGetStateEx = (XInputGetStateEx_t)XInputGetStateEx; #endif @@ -230,7 +244,7 @@ static bool xinput_joypad_init(void *data) * XInputGetState, at the cost of losing guide button support. */ g_xinput_guide_button_supported = false; -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) g_XInputGetStateEx = (XInputGetStateEx_t)dylib_proc(g_xinput_dll, "XInputGetState"); #else g_XInputGetStateEx = (XInputGetStateEx_t)XInputGetState; @@ -239,7 +253,7 @@ static bool xinput_joypad_init(void *data) if (!g_XInputGetStateEx) { RARCH_ERR("[XInput]: Failed to init: DLL is invalid or corrupt.\n"); -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) dylib_close(g_xinput_dll); #endif return false; /* DLL was loaded but did not contain the correct function. */ @@ -247,7 +261,7 @@ static bool xinput_joypad_init(void *data) RARCH_WARN("[XInput]: No guide button support.\n"); } -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) g_XInputSetState = (XInputSetState_t)dylib_proc(g_xinput_dll, "XInputSetState"); #else g_XInputSetState = (XInputSetState_t)XInputSetState; @@ -255,7 +269,7 @@ static bool xinput_joypad_init(void *data) if (!g_XInputSetState) { RARCH_ERR("[XInput]: Failed to init: DLL is invalid or corrupt.\n"); -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) dylib_close(g_xinput_dll); #endif return false; /* DLL was loaded but did not contain the correct function. */ @@ -277,13 +291,18 @@ static bool xinput_joypad_init(void *data) (!g_xinput_states[1].connected) && (!g_xinput_states[2].connected) && (!g_xinput_states[3].connected)) +#ifdef __WINRT__ + return true; +#else return false; +#endif RARCH_LOG("[XInput]: Pads connected: %d\n", g_xinput_states[0].connected + g_xinput_states[1].connected + g_xinput_states[2].connected + g_xinput_states[3].connected); - g_xinput_block_pads = true; #ifdef HAVE_DINPUT + g_xinput_block_pads = true; + /* We're going to have to be buddies with dinput if we want to be able * to use XInput and non-XInput controllers together. */ if (!dinput_joypad.init(data)) @@ -347,7 +366,7 @@ static void xinput_joypad_destroy(void) for (i = 0; i < 4; ++i) memset(&g_xinput_states[i], 0, sizeof(xinput_joypad_state)); -#ifdef HAVE_DYNAMIC +#if defined(HAVE_DYNAMIC) && !defined(__WINRT__) dylib_close(g_xinput_dll); g_xinput_dll = NULL; @@ -357,9 +376,9 @@ static void xinput_joypad_destroy(void) #ifdef HAVE_DINPUT dinput_joypad.destroy(); -#endif g_xinput_block_pads = false; +#endif } /* Buttons are provided by XInput as bits of a uint16. @@ -499,6 +518,7 @@ static void xinput_joypad_poll(void) for (i = 0; i < 4; ++i) { +#ifdef HAVE_DINPUT if (g_xinput_states[i].connected) { if (g_XInputGetStateEx && g_XInputGetStateEx(i, @@ -506,6 +526,28 @@ static void xinput_joypad_poll(void) == ERROR_DEVICE_NOT_CONNECTED) g_xinput_states[i].connected = false; } +#else + /* Normally, dinput handles device insertion/removal for us, but + * since dinput is not available on UWP we have to do it ourselves */ + /* Also note that on UWP, the controllers are not available on startup + * and are instead 'plugged in' a moment later because Microsoft reasons */ + // TODO: This may be bad for performance? + bool new_connected = g_XInputGetStateEx && g_XInputGetStateEx(i, &(g_xinput_states[i].xstate)) != ERROR_DEVICE_NOT_CONNECTED; + if (new_connected != g_xinput_states[i].connected) + { + if (new_connected) + { + /* This is kinda ugly, but it's the same thing that dinput does */ + xinput_joypad_destroy(); + xinput_joypad_init(NULL); + return; + } + else + { + g_xinput_states[i].connected = new_connected; + } + } +#endif } #ifdef HAVE_DINPUT diff --git a/input/include/hid_driver.h b/input/include/hid_driver.h index 02b6529f63..81c9f7cd94 100644 --- a/input/include/hid_driver.h +++ b/input/include/hid_driver.h @@ -71,8 +71,6 @@ struct hid_driver #define HID_MAX_SLOT() hid_instance.max_slot #define HID_PAD_CONNECTION_PTR(slot) &(hid_instance.pad_list[(slot)]) - - struct hid_driver_instance { hid_driver_t *os_driver; void *os_driver_data; diff --git a/input/input_autodetect_builtin.c b/input/input_autodetect_builtin.c index fab56585d7..7cda7ca0e8 100644 --- a/input/input_autodetect_builtin.c +++ b/input/input_autodetect_builtin.c @@ -303,7 +303,6 @@ DECL_AXIS_EX(r_x_minus, -3, "R Analog left") \ DECL_AXIS_EX(r_y_plus, +2, "R Analog up") \ DECL_AXIS_EX(r_y_minus, -2, "R Analog down") - #define WIIUINPUT_GAMEPAD_DEFAULT_BINDS \ DECL_BTN_EX(menu_toggle, 1, "Home") \ DECL_BTN_EX(select, 2, "-") \ diff --git a/input/input_driver.c b/input/input_driver.c index 304ec34645..2ed4c4a021 100644 --- a/input/input_driver.c +++ b/input/input_driver.c @@ -107,10 +107,13 @@ static const input_driver_t *input_drivers[] = { #ifdef HAVE_X11 &input_x, #endif +#ifdef __WINRT__ + &input_uwp, +#endif #ifdef XENON &input_xenon360, #endif -#if defined(HAVE_XINPUT2) || defined(HAVE_XINPUT_XBOX1) +#if defined(HAVE_XINPUT2) || defined(HAVE_XINPUT_XBOX1) || defined(__WINRT__) &input_xinput, #endif #ifdef GEKKO @@ -140,7 +143,7 @@ static const input_driver_t *input_drivers[] = { #ifdef DJGPP &input_dos, #endif -#if defined(_WIN32) && !defined(_XBOX) && _WIN32_WINNT >= 0x0501 +#if defined(_WIN32) && !defined(_XBOX) && _WIN32_WINNT >= 0x0501 && !defined(__WINRT__) /* winraw only available since XP */ &input_winraw, #endif @@ -255,7 +258,6 @@ struct input_bind_map uint8_t retro_key; }; - static const uint8_t buttons[] = { RETRO_DEVICE_ID_JOYPAD_R, RETRO_DEVICE_ID_JOYPAD_L, @@ -368,7 +370,6 @@ const struct input_bind_map input_config_bind_map[RARCH_BIND_LIST_END_NULL] = { DECLARE_META_BIND(2, streaming_toggle, RARCH_STREAMING_TOGGLE, MENU_ENUM_LABEL_VALUE_INPUT_META_STREAMING_TOGGLE), }; - typedef struct turbo_buttons turbo_buttons_t; /* Turbo support. */ @@ -589,7 +590,6 @@ float input_sensor_get_input(unsigned port, unsigned id) return 0.0f; } - /** * input_poll: * @@ -611,8 +611,6 @@ void input_poll(void) if (input_driver_block_libretro_input) return; - - for (i = 0; i < max_users; i++) { if (libretro_input_binds[i][RARCH_TURBO_ENABLE].valid) @@ -749,8 +747,6 @@ int16_t input_state(unsigned port, unsigned device, input_mapper_state(input_driver_mapper, &res, port, device, idx, id); - - /* Don't allow turbo for D-pad. */ if (device == RETRO_DEVICE_JOYPAD && (id < RETRO_DEVICE_ID_JOYPAD_UP || id > RETRO_DEVICE_ID_JOYPAD_RIGHT)) @@ -1481,7 +1477,6 @@ bool input_driver_init_mapper(void) return false; } - bool input_driver_grab_mouse(void) { if (!current_input || !current_input->grab_mouse) diff --git a/input/input_driver.h b/input/input_driver.h index 2c5c35a7ea..341cd2ff66 100644 --- a/input/input_driver.h +++ b/input/input_driver.h @@ -701,7 +701,6 @@ bool input_keyboard_line_append(const char *word); const char **input_keyboard_start_line(void *userdata, input_keyboard_line_complete_t cb); - bool input_keyboard_ctl(enum rarch_input_keyboard_ctl_state state, void *data); extern struct retro_keybind input_config_binds[MAX_USERS][RARCH_BIND_LIST_END]; @@ -836,6 +835,7 @@ extern input_driver_t input_xenon360; extern input_driver_t input_gx; extern input_driver_t input_wiiu; extern input_driver_t input_xinput; +extern input_driver_t input_uwp; extern input_driver_t input_linuxraw; extern input_driver_t input_udev; extern input_driver_t input_cocoa; diff --git a/input/input_keymaps.c b/input/input_keymaps.c index ff3817ad92..522f77ae32 100644 --- a/input/input_keymaps.c +++ b/input/input_keymaps.c @@ -44,7 +44,7 @@ #include "SDL.h" #endif -#ifdef __linux__ +#if defined(__linux__) || defined(HAVE_WAYLAND) #include #include #endif @@ -848,7 +848,7 @@ const struct rarch_key_map rarch_key_map_x11[] = { }; #endif -#ifdef __linux__ +#if defined(__linux__) || defined(HAVE_WAYLAND) const struct rarch_key_map rarch_key_map_linux[] = { { KEY_BACKSPACE, RETROK_BACKSPACE }, { KEY_TAB, RETROK_TAB }, @@ -1423,7 +1423,7 @@ const struct rarch_key_map rarch_key_map_dos[] = { }; #endif -#if defined(_WIN32) && _WIN32_WINNT >= 0x0501 +#if defined(_WIN32) && _WIN32_WINNT >= 0x0501 && !defined(__WINRT__) const struct rarch_key_map rarch_key_map_winraw[] = { { VK_BACK, RETROK_BACKSPACE }, { VK_TAB, RETROK_TAB }, @@ -1539,6 +1539,11 @@ const struct rarch_key_map rarch_key_map_winraw[] = { }; #endif +#ifdef __WINRT__ +/* Refer to uwp_main.cpp - on WinRT these constants are defined as C++ enum classes + * so they can't be placed in a C source file */ +#endif + enum retro_key rarch_keysym_lut[RETROK_LAST]; /** diff --git a/input/input_mapper.c b/input/input_mapper.c index b6b386a656..b6c7440e54 100644 --- a/input/input_mapper.c +++ b/input/input_mapper.c @@ -15,7 +15,6 @@ * If not, see . */ - #include #include #include diff --git a/input/input_remapping.c b/input/input_remapping.c index bd43985eb1..d435d1088a 100644 --- a/input/input_remapping.c +++ b/input/input_remapping.c @@ -245,7 +245,7 @@ bool input_remapping_save_file(const char *path) config_set_int(conf, s1, settings->uints.input_analog_dpad_mode[i]); } - ret = config_file_write(conf, remap_file); + ret = config_file_write(conf, remap_file, true); config_file_free(conf); free(remap_file); diff --git a/input/input_remote.c b/input/input_remote.c index d74529c7d2..bd1b7f0028 100644 --- a/input/input_remote.c +++ b/input/input_remote.c @@ -14,7 +14,6 @@ * If not, see . */ - #include #include #include diff --git a/intl/msg_hash_ar.h b/intl/msg_hash_ar.h index 8fa2330b82..ef0fd5921a 100644 --- a/intl/msg_hash_ar.h +++ b/intl/msg_hash_ar.h @@ -7,8 +7,9 @@ MSG_HASH( "Unknown compiler" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Device disconnected from port" @@ -145,6 +146,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Adjusts menu screen appearance settings." diff --git a/intl/msg_hash_chs.h b/intl/msg_hash_chs.h index 66a7eca707..97e543affc 100644 --- a/intl/msg_hash_chs.h +++ b/intl/msg_hash_chs.h @@ -35,8 +35,9 @@ MSG_HASH( "未知的编译器" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "设备已从端口上断开" @@ -133,6 +134,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "调整菜单屏幕相关的设置。" diff --git a/intl/msg_hash_cht.h b/intl/msg_hash_cht.h index b314f009b8..05ff2c10f7 100644 --- a/intl/msg_hash_cht.h +++ b/intl/msg_hash_cht.h @@ -7,8 +7,9 @@ MSG_HASH( "未知的編譯器" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "設備已從連接口上移開" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "使用模擬器硬體渲染私人內容時可避免硬體在各frames時的狀態改變." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "調整選單顯示的相關設定。" @@ -985,6 +990,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, /* TODO/FIXME - updat "選單文件瀏覽器") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "選單線性過濾") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "選單") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_de.h b/intl/msg_hash_de.h index 214f52dbf3..f690ec327d 100644 --- a/intl/msg_hash_de.h +++ b/intl/msg_hash_de.h @@ -35,8 +35,9 @@ MSG_HASH( "Unbekannter Compiler" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Gerät von Anschluss getrennt" @@ -133,6 +134,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Gibt Hardware-gerenderten Cores einen eigenen privaten Kontext. Vermeidet, dass der Hardware-Status zwischen den Frames geschätzt werden muss." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Legt die Einstellungen für das Aussehen des Menübildschirms fest." diff --git a/intl/msg_hash_el.h b/intl/msg_hash_el.h index a6c9cbb4e7..fae4ab9b95 100644 --- a/intl/msg_hash_el.h +++ b/intl/msg_hash_el.h @@ -146,6 +146,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Προσαρμόζει τις εμφανισιακές ρυθμίσεις της οθόνης του μενού." diff --git a/intl/msg_hash_eo.h b/intl/msg_hash_eo.h index 9fe65dfbe6..f26d9f4c96 100644 --- a/intl/msg_hash_eo.h +++ b/intl/msg_hash_eo.h @@ -7,8 +7,9 @@ MSG_HASH( "Unknown compiler" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Device disconnected from port" @@ -45,6 +46,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Adjusts settings related to the appearance of the menu screen." diff --git a/intl/msg_hash_es.h b/intl/msg_hash_es.h index 5c6e193bd5..cbbb73f97e 100644 --- a/intl/msg_hash_es.h +++ b/intl/msg_hash_es.h @@ -7,7 +7,7 @@ MSG_HASH( MENU_ENUM_SUBLABEL_SWITCH_GPU_PROFILE, "Acelera el procesador de video" ) - MSG_HASH( +MSG_HASH( MENU_ENUM_LABEL_VALUE_SWITCH_BACKLIGHT_CONTROL, "Brillo de pantalla" ) @@ -173,6 +173,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Dar a los núcleos renderizados por hardware un contexto privado. Evita tener que asumir cambios en el estado del hardware entre cuadros" ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Ajusta la apariencia del menú" @@ -673,6 +677,18 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_CORE_LIST, "Cargar núcleo" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_SIDELOAD_CORE_LIST, + "Instalar or Restaurar un núcleo" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_SIDELOAD_CORE_ERROR, + "Falló la instalación del núcleo" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_SIDELOAD_CORE_SUCCESS, + "Núcleo instalado exitosamente" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_CORE_OPTIONS, "Opciones" @@ -759,7 +775,7 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_LABEL_VALUE_DISK_CYCLE_TRAY_STATUS, - "Estado de la bandeja de discos" + "Abrir/Cerrar la bandeja de discos" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_DISK_IMAGE_APPEND, @@ -845,6 +861,10 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_FPS_SHOW, "Mostrar FPS" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_MEMORY_SHOW, + "Incluir detalles de memoria" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_FRAME_THROTTLE_ENABLE, "Limitar velocidad máxima de ejecución" @@ -1249,6 +1269,10 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_INPUT_META_FRAMEADVANCE, "Avanzar frame" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_INPUT_META_FPS_TOGGLE, + "Mostrar FPS" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_INPUT_META_FULLSCREEN_TOGGLE_KEY, "Pantalla completa" @@ -1297,10 +1321,17 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_INPUT_META_PAUSE_TOGGLE, "Pausar" ) +#ifdef HAVE_LAKKA +MSG_HASH( + MENU_ENUM_LABEL_VALUE_INPUT_META_QUIT_KEY, + "Reiniciar RetroArch" + ) +#else MSG_HASH( MENU_ENUM_LABEL_VALUE_INPUT_META_QUIT_KEY, "Cerrar RetroArch" ) +#endif MSG_HASH( MENU_ENUM_LABEL_VALUE_INPUT_META_RESET, "Resetear juego" @@ -2049,10 +2080,17 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_MIDI_SETTINGS, "MIDI" ) +#ifdef HAVE_LAKKA +MSG_HASH( + MENU_ENUM_LABEL_VALUE_QUIT_RETROARCH, + "Reiniciar RetroArch" + ) +#else MSG_HASH( MENU_ENUM_LABEL_VALUE_QUIT_RETROARCH, "Cerrar RetroArch" ) +#endif MSG_HASH( MENU_ENUM_LABEL_VALUE_RDB_ENTRY_ANALOG, "Soporte de analógico" @@ -2920,10 +2958,58 @@ MSG_HASH( MENU_ENUM_SUBLABEL_TIMEDATE_STYLE, "Cambia la forma en que se muestra la fecha y hora" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_YMD_HMS, + "YYYY-MM-DD HH:MM:SS" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_YMD_HM, + "YYYY-MM-DD HH:MM" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_MDYYYY, + "MM-DD-YYYY HH:MM" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_HMS, + "HH:MM:SS" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_HM, + "HH:MM" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_DM_HM, + "DD/MM HH:MM" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_MD_HM, + "MM/DD HH:MM" + ) + MSG_HASH( + MENU_ENUM_LABEL_VALUE_TIMEDATE_STYLE_AM_PM, + "HH:MM:SS (AM/PM)" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_TITLE_COLOR, "Color de títulos del menú" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_BG_DARK_COLOR, + "Color oscuro del fondo del menú" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_BG_LIGHT_COLOR, + "Color claro del fondo del menú" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_BORDER_DARK_COLOR, + "Color oscuro del borde del menú" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_BORDER_LIGHT_COLOR, + "Color claro del borde del menú" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_TRUE, "Activado" @@ -3176,6 +3262,10 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_VIDEO_SCALE, "Escala en ventana" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_VIDEO_RECORD_THREADS, + "Hilos de grabación (Threads)" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_VIDEO_SCALE_INTEGER, "Escalar usando enteros" @@ -3486,7 +3576,8 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_SUBLABEL_CHEEVOS_HARDCORE_MODE_ENABLE, - "Duplica puntos pero desactiva guardado rápido, trucos, rebobinar, y cámara lenta para todos los juegos" + "Duplica puntos pero desactiva guardado rápido, trucos, rebobinar, y cámara lenta." + "Cambiar esto reiniciará el juego." ) MSG_HASH( MENU_ENUM_SUBLABEL_CHEEVOS_LEADERBOARDS_ENABLE, @@ -3596,6 +3687,14 @@ MSG_HASH( MENU_ENUM_SUBLABEL_FPS_SHOW, "Muestra la velocidad de cuadros por segundo" ) +MSG_HASH( + MENU_ENUM_SUBLABEL_FRAMECOUNT_SHOW, + "Muestra el contador de frames" + ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MEMORY_SHOW, + "Muestra la cantidad de memoria usada/total" + ) MSG_HASH( MENU_ENUM_SUBLABEL_INPUT_HOTKEY_BINDS, "Opciones de teclas rápidas (hotkeys)" @@ -4838,6 +4937,14 @@ MSG_HASH( MENU_ENUM_SUBLABEL_CORE_LIST, "Seleccionar que núcleo usar" ) +MSG_HASH( + MENU_ENUM_SUBLABEL_DOWNLOAD_CORE, + "Instalar un núcleo desde el Actualizador en línea" + ) +MSG_HASH( + MENU_ENUM_SUBLABEL_SIDELOAD_CORE_LIST, + "Instalr o restaurar un núcleo desde la carpeta de descargas" + ) MSG_HASH( MENU_ENUM_SUBLABEL_LOAD_CONTENT_LIST, "Seleccionar que contenido iniciar" @@ -4850,10 +4957,17 @@ MSG_HASH( MENU_ENUM_SUBLABEL_SYSTEM_INFORMATION, "Mostrar información especifica del dispositivo" ) +#ifdef HAVE_LAKKA +MSG_HASH( + MENU_ENUM_SUBLABEL_QUIT_RETROARCH, + "Reiniciar el programa" + ) +#else MSG_HASH( MENU_ENUM_SUBLABEL_QUIT_RETROARCH, "Salir del programa" ) +#endif MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_WINDOW_WIDTH, "Establece el ancho de la ventana. Al dejarlo en 0 hará que intente ser lo mas grande posible" @@ -4862,6 +4976,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_WINDOW_HEIGHT, "Establece el alto de la ventana. Al dejarlo en 0 hará que intente ser lo mas grande posible" ) +MSG_HASH( + MENU_ENUM_SUBLABEL_VIDEO_WINDOW_SAVE_POSITION, + "Tomará precedencia sobre Escala en Ventana" + ) MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_FULLSCREEN_X, "Establece el ancho en pantalla completa. Al dejarlo en 0 se usará la resolución del escritorio" @@ -6037,14 +6155,25 @@ MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SHOW_HELP, "Mostrar/ocultar la opción de 'Ayuda'" ) +#ifdef HAVE_LAKKA MSG_HASH( MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, - "Mostrar salir de RetroArch" + "Mostrar Reiniciar RetroArch" ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, - "Mostrar/ocultar la opción de 'Salir de RetroArch'" + "Mostrar/ocultar la opción de 'Reiniciar RetroArch'" ) +#else +MSG_HASH( + MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, + "Mostrar Cerrar RetroArch" + ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, + "Muestrar/Ocultar la opción de 'Cerrar RetroArch'" + ) +#endif MSG_HASH( MENU_ENUM_LABEL_VALUE_MENU_SHOW_REBOOT, "Mostrar reiniciar" @@ -6103,27 +6232,27 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_LABEL_VALUE_QUICK_MENU_SHOW_START_RECORDING, - "Show Start Recording" + "Mostrar Comenzar grabación" ) MSG_HASH( MENU_ENUM_SUBLABEL_QUICK_MENU_SHOW_START_RECORDING, - "Show/hide the 'Start Recording' option." + "Mostrar/ocultar la opción de 'Comenzar grabación'" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_QUICK_MENU_SHOW_START_STREAMING, - "Show Start Streaming" + "Mostrar Comenzar Streamingg" ) MSG_HASH( MENU_ENUM_SUBLABEL_QUICK_MENU_SHOW_START_STREAMING, - "Show/hide the 'Start Streaming' option." + "Mostrar/ocultar la opción de 'Comenzar Streaming'" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_QUICK_MENU_SHOW_RESET_CORE_ASSOCIATION, - "Show Reset Core Association" + "Mostrar Restablecer asociación de núcleo" ) MSG_HASH( MENU_ENUM_SUBLABEL_QUICK_MENU_SHOW_RESET_CORE_ASSOCIATION, - "Show/hide the 'Reset Core Association' option." + "Mostrar/ocultar la opción de 'Restablecer asociación de núcleo'" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_QUICK_MENU_SHOW_OPTIONS, @@ -7576,7 +7705,8 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_ADAPTIVE_VSYNC, - "V-Sync está activado hasta que el rendimiento sea inferior al necesario para mantener el refresco de pantalla. Puede minimizar los tirones cuando hay caidas de fps y es més eficiente energeticamente." + "V-Sync está activado hasta que el rendimiento sea inferior al necesario para mantener el refresco de pantalla.\n" + "Puede minimizar los tirones cuando hay caidas de fps y es més eficiente energeticamente." ) MSG_HASH( MENU_ENUM_LABEL_VALUE_CRT_SWITCHRES_SETTINGS, @@ -7774,5 +7904,11 @@ MSG_HASH( MSG_MISSING_ASSETS, "ADVERTENCIA: Faltan recursos, use el Actualizador si está disponible" ) -MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_WINDOW_SAVE_POSITION, - "Remember Window Position and Size") +MSG_HASH( + MENU_ENUM_LABEL_VALUE_VIDEO_WINDOW_SAVE_POSITION, + "Recordar posición y tamaño de la ventana" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_HOLD_START, + "Mantener Start (2 segundos)" + ) diff --git a/intl/msg_hash_fr.h b/intl/msg_hash_fr.h index 37ac633783..ec9d2803c9 100644 --- a/intl/msg_hash_fr.h +++ b/intl/msg_hash_fr.h @@ -7,8 +7,9 @@ MSG_HASH( "Compilateur inconnu" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Périphérique déconnecté du port" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Donne aux cœurs bénéficiant de l'accélération graphique leur propre contexte. Évite d'avoir à supposer des changements d'état matériel entre deux images." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Ajuster les réglages et l'apparence du menu." @@ -989,6 +994,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "Réglages") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "Filtre linéaire pour le menu") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "Appearance") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_it.h b/intl/msg_hash_it.h index e7668d494b..6ab4cbd73c 100644 --- a/intl/msg_hash_it.h +++ b/intl/msg_hash_it.h @@ -7,8 +7,9 @@ MSG_HASH( "Compilatore sconosciuto" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Dispositivo disconnesso dalla porta" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Fornisce i core hardware nel proprio contesto privato. Evita di assumere cambiamenti di stato hardware tra i fotogrammi." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Regola le impostazioni relative all'aspetto della schermata del menu." diff --git a/intl/msg_hash_ja.h b/intl/msg_hash_ja.h index 0f3bfe42fb..5b1f980024 100644 --- a/intl/msg_hash_ja.h +++ b/intl/msg_hash_ja.h @@ -12,8 +12,9 @@ MSG_HASH( "不明なコンパイラ" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "デバイスがポートから切断されました" @@ -150,6 +151,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "メニューの外観に関係する設定を変更します。" @@ -3919,10 +3924,10 @@ MSG_HASH( "カスタムリフレッシュレートを使用") MSG_HASH( MENU_ENUM_SUBLABEL_CRT_SWITCH_RESOLUTION_OUTPUT_DISPLAY_ID, - "Select the output port connected to the CRT display.") + "CRTディスプレイに接続されている出力ポートを選択します。") MSG_HASH( MENU_ENUM_LABEL_VALUE_CRT_SWITCH_RESOLUTION_OUTPUT_DISPLAY_ID, - "Output Display ID") + "出力ディスプレイの識別番号") MSG_HASH( MENU_ENUM_LABEL_VALUE_QUICK_MENU_START_RECORDING, "録画を開始" @@ -4015,45 +4020,45 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_OZONE_MENU_COLOR_THEME, "メニューの色テーマ") MSG_HASH( MENU_ENUM_LABEL_VALUE_OZONE_COLOR_THEME_BASIC_WHITE, - "Basic White" + "ベーシックホワイト" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_OZONE_COLOR_THEME_BASIC_BLACK, - "Basic Black" + "ベーシックブラック" ) MSG_HASH( MENU_ENUM_SUBLABEL_OZONE_MENU_COLOR_THEME, - "Select a different color theme." + "色テーマを選択します。" ) MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_USE_PREFERRED_SYSTEM_COLOR_THEME, "Use preferred system color theme") MSG_HASH(MENU_ENUM_SUBLABEL_MENU_USE_PREFERRED_SYSTEM_COLOR_THEME, "Use your operating system's color theme (if any) - overrides theme settings.") MSG_HASH(MSG_RESAMPLER_QUALITY_LOWEST, - "Lowest") + "最低") MSG_HASH(MSG_RESAMPLER_QUALITY_LOWER, - "Lower") + "低") MSG_HASH(MSG_RESAMPLER_QUALITY_NORMAL, - "Normal") + "普通") MSG_HASH(MSG_RESAMPLER_QUALITY_HIGHER, - "Higher") + "高") MSG_HASH(MSG_RESAMPLER_QUALITY_HIGHEST, - "Highest") + "最高") MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_MUSIC_AVAILABLE, - "No music available." + "音楽ファイルがありません。" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_VIDEOS_AVAILABLE, - "No videos available." + "動画ファイルがありません。" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_IMAGES_AVAILABLE, - "No images available." + "画像ファイルがありません。" ) MSG_HASH( MENU_ENUM_LABEL_VALUE_NO_FAVORITES_AVAILABLE, - "No favorites available." + "お気に入りがありません。" ) MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_WINDOW_SAVE_POSITION, - "Remember Window Position and Size") + "ウィンドウの位置とサイズを記憶") diff --git a/intl/msg_hash_ko.h b/intl/msg_hash_ko.h index b94ce77dc2..4d6d3cc5f6 100644 --- a/intl/msg_hash_ko.h +++ b/intl/msg_hash_ko.h @@ -7,8 +7,9 @@ MSG_HASH( "알 수 없는 컴파일러" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "장치가 포트에서 연결 해제 되었습니다" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "하드웨어 렌더링된 코어에 고유의 컨텍스트를 부여. 프레임간 하드웨어 상태가 변경된 것으로 가정하지 않도록 함." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "화면 표시 설정을 조정합니다." @@ -970,6 +975,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "설정") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "메뉴 선형 필터") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "메뉴") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_nl.h b/intl/msg_hash_nl.h index 1426e3b5f9..17677a9825 100644 --- a/intl/msg_hash_nl.h +++ b/intl/msg_hash_nl.h @@ -7,8 +7,9 @@ MSG_HASH( "Onbekende compiler" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Apparaat ontkoppeld van port" @@ -45,6 +46,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Adjusts settings related to the appearance of the menu screen." @@ -905,6 +910,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "Instellingen") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "Menu Linear Filter") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "Uiterlijk") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_pl.h b/intl/msg_hash_pl.h index 86d03816a9..59853c16d0 100644 --- a/intl/msg_hash_pl.h +++ b/intl/msg_hash_pl.h @@ -7,8 +7,9 @@ MSG_HASH( "Nieznany kompilator" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Urządzenie zostało odłączone od portu" @@ -145,6 +146,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Nadaj rdzeniom sprzętowym własny prywatny kontekst. Unikaj konieczności przejmowania zmian stanu sprzętu pomiędzy klatkami." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Dostosuj ustawienia wyglądu ekranu menu." diff --git a/intl/msg_hash_pt_br.h b/intl/msg_hash_pt_br.h index 3bb3c1a358..7c23ba87bf 100644 --- a/intl/msg_hash_pt_br.h +++ b/intl/msg_hash_pt_br.h @@ -173,6 +173,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Dar aos núcleos renderizados por hardware seu próprio contexto privado. Evita ter que assumir mudanças de estado de hardware entre quadros." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Ajusta as configurações de aparência da tela de menu." diff --git a/intl/msg_hash_pt_pt.h b/intl/msg_hash_pt_pt.h index 84b8e21efc..929abe53d6 100644 --- a/intl/msg_hash_pt_pt.h +++ b/intl/msg_hash_pt_pt.h @@ -7,8 +7,9 @@ MSG_HASH( "Compilador desconhecido" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Dispositivo desconectado da porta" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Dê aos núcleos renderizados por hardware o seu próprio contexto privado. Evita ter que assumir mudanças de estado de hardware entre frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "ajusta as definições de aparência no ecrã do menu." @@ -970,6 +975,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "Definições") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "Filtro linear do menu") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "Aparência") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_ru.h b/intl/msg_hash_ru.h index 7fdb5e26d8..e531e1964e 100644 --- a/intl/msg_hash_ru.h +++ b/intl/msg_hash_ru.h @@ -12,8 +12,9 @@ MSG_HASH( "Неизвестный компилятор" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Устройство отключено от порта" @@ -110,6 +111,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Предоставьте аппаратно-рендерированным ядрам собственный контекст. Избегайте принятия изменений состояния оборудования между кадрами." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Настройка параметров, относящихся к внешнему виду экрана меню." @@ -993,6 +998,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "Настройки") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "Линейный фильтр меню") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "Меню") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/intl/msg_hash_us.h b/intl/msg_hash_us.h index f49615f723..6854693894 100644 --- a/intl/msg_hash_us.h +++ b/intl/msg_hash_us.h @@ -59,7 +59,11 @@ MSG_HASH( ) MSG_HASH( MSG_PUBLIC_ADDRESS, - "Public address" + "Port Mapping Successful" + ) +MSG_HASH( + MSG_UPNP_FAILED, + "Port Mapping Failed" ) MSG_HASH( MSG_NO_ARGUMENTS_SUPPLIED_AND_NO_MENU_BUILTIN, @@ -129,6 +133,10 @@ MSG_HASH( MSG_NETPLAY_ENTER_PASSWORD, "Enter netplay server password:" ) +MSG_HASH( + MSG_DISCORD_CONNECTION_REQUEST, + "Do you want to allow connection from user:" + ) MSG_HASH( MSG_NETPLAY_INCORRECT_PASSWORD, "Incorrect password" @@ -173,6 +181,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Adjusts menu screen appearance settings." @@ -3572,7 +3584,8 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_SUBLABEL_CHEEVOS_HARDCORE_MODE_ENABLE, - "Enables hardcore mode, this will enable or disable savestates, cheats, rewind, pause, and slow-motion.\nToggling this setting at runtime will restart your game." + "Enables hardcore mode, this will enable or disable savestates, cheats, rewind, pause, and slow-motion.\n" + "Toggling this setting at runtime will restart your game." ) MSG_HASH( MENU_ENUM_SUBLABEL_CHEEVOS_LEADERBOARDS_ENABLE, @@ -4932,6 +4945,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_CORE_LIST, "Select which core to use." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_START_CORE, + "Start core without content." + ) MSG_HASH( MENU_ENUM_SUBLABEL_DOWNLOAD_CORE, "Install a core from the online updater." @@ -4953,11 +4970,15 @@ MSG_HASH( "Show information specific to the device." ) #ifdef HAVE_LAKKA -MSG_HASH(MENU_ENUM_SUBLABEL_QUIT_RETROARCH, - "Restart the program.") +MSG_HASH( + MENU_ENUM_SUBLABEL_QUIT_RETROARCH, + "Restart the program." + ) #else -MSG_HASH(MENU_ENUM_SUBLABEL_QUIT_RETROARCH, - "Quit the program.") +MSG_HASH( + MENU_ENUM_SUBLABEL_QUIT_RETROARCH, + "Quit the program." + ) #endif MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_WINDOW_WIDTH, @@ -6147,15 +6168,23 @@ MSG_HASH( "Show/hide the 'Help' option." ) #ifdef HAVE_LAKKA -MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, - "Show Restart RetroArch") -MSG_HASH(MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, - "Show/hide the 'Restart RetroArch' option.") +MSG_HASH( + MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, + "Show Restart RetroArch" + ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, + "Show/hide the 'Restart RetroArch' option." + ) #else -MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, - "Show Quit RetroArch") -MSG_HASH(MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, - "Show/hide the 'Quit RetroArch' option.") +MSG_HASH( + MENU_ENUM_LABEL_VALUE_MENU_SHOW_QUIT_RETROARCH, + "Show Quit RetroArch" + ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_SHOW_QUIT_RETROARCH, + "Show/hide the 'Quit RetroArch' option." + ) #endif MSG_HASH( MENU_ENUM_LABEL_VALUE_MENU_SHOW_REBOOT, @@ -7650,6 +7679,14 @@ MSG_HASH( MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_STARTUP_PLAYLIST, "Start on playlist:" ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_TYPE, + "Icon view thumbnail type:" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_CACHE_LIMIT, + "Thumbnail cache limit:" + ) MSG_HASH( MENU_ENUM_LABEL_VALUE_QT_DOWNLOAD_ALL_THUMBNAILS, "Download All Thumbnails" @@ -7688,7 +7725,8 @@ MSG_HASH( ) MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_ADAPTIVE_VSYNC, - "V-Sync is enabled until performance falls below the target refresh rate. Can minimize stuttering when performance falls below realtime, and can be more energy efficient." + "V-Sync is enabled until performance falls below the target refresh rate.\n" + "This can minimize stuttering when performance falls below realtime, and can be more energy efficient." ) MSG_HASH( MENU_ENUM_LABEL_VALUE_CRT_SWITCHRES_SETTINGS, @@ -7886,7 +7924,11 @@ MSG_HASH( MSG_MISSING_ASSETS, "Warning: Missing assets, use the Online Updater if available" ) -MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_WINDOW_SAVE_POSITION, - "Remember Window Position and Size") -MSG_HASH(MENU_ENUM_LABEL_VALUE_HOLD_START, - "Hold Start (2 seconds)") +MSG_HASH( + MENU_ENUM_LABEL_VALUE_VIDEO_WINDOW_SAVE_POSITION, + "Remember Window Position and Size" + ) +MSG_HASH( + MENU_ENUM_LABEL_VALUE_HOLD_START, + "Hold Start (2 seconds)" + ) diff --git a/intl/msg_hash_vn.h b/intl/msg_hash_vn.h index 33f84b7482..a7bb34ce4c 100644 --- a/intl/msg_hash_vn.h +++ b/intl/msg_hash_vn.h @@ -7,8 +7,9 @@ MSG_HASH( "Unknown compiler" ) MSG_HASH( - MSG_NATIVE, - "Native") + MSG_NATIVE, + "Native" + ) MSG_HASH( MSG_DEVICE_DISCONNECTED_FROM_PORT, "Device disconnected from port" @@ -105,6 +106,10 @@ MSG_HASH( MENU_ENUM_SUBLABEL_VIDEO_SHARED_CONTEXT, "Give hardware-rendered cores their own private context. Avoids having to assume hardware state changes inbetween frames." ) +MSG_HASH( + MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION, + "Enable horizontal animation for the menu. This will have a performance hit." + ) MSG_HASH( MENU_ENUM_SUBLABEL_MENU_SETTINGS, "Điều chỉnh thiết lập related to the appearance of the menu screen." @@ -991,6 +996,8 @@ MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_FILE_BROWSER_SETTINGS, "Settings") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_LINEAR_FILTER, "Menu Linear Filter") +MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_HORIZONTAL_ANIMATION, + "Horizontal Animation") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_SETTINGS, "Appearance") MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WALLPAPER, diff --git a/led/drivers/led_null.c b/led/drivers/led_null.c index 3f178a1389..1d95ce3bc6 100644 --- a/led/drivers/led_null.c +++ b/led/drivers/led_null.c @@ -15,14 +15,13 @@ #include "../led_driver.h" #include "../../verbosity.h" -static void null_init(void) { } -static void null_free(void) { } -static void null_set(int led, int state) { } +static void null_led_init(void) { } +static void null_led_free(void) { } +static void null_led_set(int led, int state) { } const led_driver_t null_led_driver = { - null_init, - null_free, - null_set, + null_led_init, + null_led_free, + null_led_set, "null" }; - diff --git a/led/led_driver.h b/led/led_driver.h index 916ee95306..d275a1a079 100644 --- a/led/led_driver.h +++ b/led/led_driver.h @@ -35,7 +35,6 @@ typedef struct led_driver const char *ident; } led_driver_t; - bool led_driver_init(void); void led_driver_free(void); diff --git a/libretro-common/audio/audio_mixer.c b/libretro-common/audio/audio_mixer.c index 3b66d0b1f2..21a0089c46 100644 --- a/libretro-common/audio/audio_mixer.c +++ b/libretro-common/audio/audio_mixer.c @@ -52,7 +52,6 @@ #include #endif - #ifdef HAVE_DR_MP3 #define DR_MP3_IMPLEMENTATION #include @@ -402,7 +401,6 @@ audio_mixer_sound_t* audio_mixer_load_ogg(void *buffer, int32_t size) #endif } - audio_mixer_sound_t* audio_mixer_load_flac(void *buffer, int32_t size) { #ifdef HAVE_DR_FLAC @@ -641,7 +639,6 @@ error: } #endif - #ifdef HAVE_DR_FLAC static bool audio_mixer_play_flac( audio_mixer_sound_t* sound, @@ -748,7 +745,6 @@ error: } #endif - audio_mixer_voice_t* audio_mixer_play(audio_mixer_sound_t* sound, bool repeat, float volume, audio_mixer_stop_cb_t stop_cb) { diff --git a/libretro-common/audio/dsp_filters/crystalizer.c b/libretro-common/audio/dsp_filters/crystalizer.c index c0e253c7e3..61510d5426 100644 --- a/libretro-common/audio/dsp_filters/crystalizer.c +++ b/libretro-common/audio/dsp_filters/crystalizer.c @@ -20,7 +20,6 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ - #include #include #include @@ -88,6 +87,5 @@ const struct dspfilter_implementation *dspfilter_get_implementation(dspfilter_si return &delta_plug; } - #undef dspfilter_get_implementation diff --git a/libretro-common/audio/dsp_filters/echo.c b/libretro-common/audio/dsp_filters/echo.c index 4b0c6cccfc..47c5b20411 100644 --- a/libretro-common/audio/dsp_filters/echo.c +++ b/libretro-common/audio/dsp_filters/echo.c @@ -157,7 +157,6 @@ error: return NULL; } - static const struct dspfilter_implementation echo_plug = { echo_init, echo_process, diff --git a/libretro-common/audio/dsp_filters/eq.c b/libretro-common/audio/dsp_filters/eq.c index a3defe77e1..b926a41cb0 100644 --- a/libretro-common/audio/dsp_filters/eq.c +++ b/libretro-common/audio/dsp_filters/eq.c @@ -271,7 +271,6 @@ static void *eq_init(const struct dspfilter_info *info, if (!eq) return NULL; - config->get_float(userdata, "window_beta", &beta, 4.0f); config->get_int(userdata, "block_size_log2", &size_log2, 8); diff --git a/libretro-common/audio/dsp_filters/fft/fft.h b/libretro-common/audio/dsp_filters/fft/fft.h index e5bcdf7176..38e67ccbd0 100644 --- a/libretro-common/audio/dsp_filters/fft/fft.h +++ b/libretro-common/audio/dsp_filters/fft/fft.h @@ -41,6 +41,5 @@ void fft_process_forward(fft_t *fft, void fft_process_inverse(fft_t *fft, float *out, const fft_complex_t *in, unsigned step); - #endif diff --git a/libretro-common/audio/dsp_filters/iir.c b/libretro-common/audio/dsp_filters/iir.c index 748d0b8c1e..9b38f4bb3c 100644 --- a/libretro-common/audio/dsp_filters/iir.c +++ b/libretro-common/audio/dsp_filters/iir.c @@ -261,7 +261,6 @@ static void iir_filter_init(struct iir_data *iir, a1 = a[1]; a2 = a[2]; - /* Normalise to 0dB at 1kHz (Thanks to Glenn Davis) */ y = 2.0 * M_PI * 1000.0 / sample_rate; b_re = b0 + b1 * cos(-y) + b2 * cos(-2.0 * y); diff --git a/libretro-common/audio/dsp_filters/reverb.c b/libretro-common/audio/dsp_filters/reverb.c index d1a770fd34..0b517e5061 100644 --- a/libretro-common/audio/dsp_filters/reverb.c +++ b/libretro-common/audio/dsp_filters/reverb.c @@ -60,7 +60,6 @@ static INLINE float comb_process(struct comb *c, float input) return output; } - static INLINE float allpass_process(struct allpass *a, float input) { float bufout = a->buffer[a->bufidx]; @@ -316,4 +315,3 @@ const struct dspfilter_implementation *dspfilter_get_implementation(dspfilter_si #undef dspfilter_get_implementation - diff --git a/libretro-common/audio/dsp_filters/vibrato.c b/libretro-common/audio/dsp_filters/vibrato.c index 6e79d2f0fb..ff2b3f9446 100644 --- a/libretro-common/audio/dsp_filters/vibrato.c +++ b/libretro-common/audio/dsp_filters/vibrato.c @@ -30,7 +30,6 @@ #define sqr(a) ((a) * (a)) - const float BASE_DELAY_SEC = 0.002; // 2 ms const float VIBRATO_FREQUENCY_DEFAULT_HZ = 2; const float VIBRATO_FREQUENCY_MAX_HZ = 14; diff --git a/libretro-common/dynamic/dylib.c b/libretro-common/dynamic/dylib.c index bc6be9fc40..1db756c734 100644 --- a/libretro-common/dynamic/dylib.c +++ b/libretro-common/dynamic/dylib.c @@ -74,17 +74,42 @@ static void set_dl_error(void) dylib_t dylib_load(const char *path) { #ifdef _WIN32 +#ifndef __WINRT__ int prevmode = SetErrorMode(SEM_FAILCRITICALERRORS | SEM_NOOPENFILEERRORBOX); -#ifdef LEGACY_WIN32 +#endif +#ifdef __WINRT__ + /* On UWP, you can only load DLLs inside your install directory, using a special function that takes a relative path */ + + if (!path_is_absolute(path)) + RARCH_WARN("Relative path in dylib_load! This is likely an attempt to load a system library that will fail\n"); + + char *relative_path_abbrev = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); + fill_pathname_abbreviate_special(relative_path_abbrev, path, PATH_MAX_LENGTH * sizeof(char)); + + char *relative_path = relative_path_abbrev; + if (relative_path[0] != ':' || !path_char_is_slash(relative_path[1])) + RARCH_WARN("Path to dylib_load is not inside app install directory! Loading will probably fail\n"); + else + relative_path += 2; + + RARCH_LOG("Loading library using a relative path: '%s'\n", relative_path); + + wchar_t *pathW = utf8_to_utf16_string_alloc(relative_path); + dylib_t lib = LoadPackagedLibrary(pathW, 0); + free(pathW); + + free(relative_path_abbrev); +#elif defined(LEGACY_WIN32) dylib_t lib = LoadLibrary(path); #else wchar_t *pathW = utf8_to_utf16_string_alloc(path); dylib_t lib = LoadLibraryW(pathW); - free(pathW); #endif +#ifndef __WINRT__ SetErrorMode(prevmode); +#endif if (!lib) { @@ -114,8 +139,20 @@ function_t dylib_proc(dylib_t lib, const char *proc) function_t sym; #ifdef _WIN32 - sym = (function_t)GetProcAddress(lib ? - (HMODULE)lib : GetModuleHandle(NULL), proc); + HMODULE mod = (HMODULE)lib; +#ifndef __WINRT__ + if (!mod) + mod = GetModuleHandle(NULL); +#else + /* GetModuleHandle is not available on UWP */ + if (!mod) + { + RARCH_WARN("FIXME: It's not possible to look up symbols in current executable on UWP!\n"); + DebugBreak(); + return NULL; + } +#endif + sym = (function_t)GetProcAddress(mod, proc); if (!sym) { set_dl_error(); diff --git a/libretro-common/features/features_cpu.c b/libretro-common/features/features_cpu.c index 1a04ce07c5..0eb6abeee0 100644 --- a/libretro-common/features/features_cpu.c +++ b/libretro-common/features/features_cpu.c @@ -68,7 +68,6 @@ #if defined(PS2) #include #include -#include #endif #if defined(__PSL1GHT__) @@ -128,7 +127,6 @@ static int ra_clock_gettime(int clk_ik, struct timespec *t) #define ra_clock_gettime clock_gettime #endif - #ifdef EMSCRIPTEN #include #endif @@ -174,9 +172,9 @@ retro_perf_tick_t cpu_features_get_perf_counter(void) time_ticks = (retro_perf_tick_t)tv.tv_sec * 1000000000 + (retro_perf_tick_t)tv.tv_nsec; -#elif defined(__GNUC__) && defined(__i386__) || defined(__i486__) || defined(__i686__) +#elif defined(__GNUC__) && defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(_M_X64) || defined(_M_AMD64) __asm__ volatile ("rdtsc" : "=A" (time_ticks)); -#elif defined(__GNUC__) && defined(__x86_64__) +#elif defined(__GNUC__) && defined(__x86_64__) || defined(_M_IX86) unsigned a, d; __asm__ volatile ("rdtsc" : "=a" (a), "=d" (d)); time_ticks = (retro_perf_tick_t)a | ((retro_perf_tick_t)d << 32); @@ -191,7 +189,7 @@ retro_perf_tick_t cpu_features_get_perf_counter(void) #elif defined(VITA) sceRtcGetCurrentTick((SceRtcTick*)&time_ticks); #elif defined(PS2) - time_ticks = SDL_GetTicks()*294912; // 294,912MHZ / 1000 msecs + time_ticks = clock()*294912; // 294,912MHZ / 1000 msecs #elif defined(_3DS) time_ticks = svcGetSystemTick(); #elif defined(WIIU) @@ -241,7 +239,7 @@ retro_time_t cpu_features_get_time_usec(void) #elif defined(EMSCRIPTEN) return emscripten_get_now() * 1000; #elif defined(PS2) - return SDL_GetTicks()*1000; + return clock()*1000; #elif defined(__mips__) || defined(DJGPP) struct timeval tv; gettimeofday(&tv,NULL); @@ -482,10 +480,14 @@ static void cpulist_read_from(CpuList* list, const char* filename) **/ unsigned cpu_features_get_core_amount(void) { -#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) +#if defined(_WIN32) && !defined(_XBOX) /* Win32 */ SYSTEM_INFO sysinfo; +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + GetNativeSystemInfo(&sysinfo); +#else GetSystemInfo(&sysinfo); +#endif return sysinfo.dwNumberOfProcessors; #elif defined(GEKKO) return 1; @@ -704,7 +706,6 @@ uint64_t cpu_features_get(void) cpu |= RETRO_SIMD_MMXEXT; } - if (flags[3] & (1 << 26)) cpu |= RETRO_SIMD_SSE2; @@ -729,7 +730,6 @@ uint64_t cpu_features_get(void) if (flags[2] & (1 << 25)) cpu |= RETRO_SIMD_AES; - /* Must only perform xgetbv check if we have * AVX CPU support (guaranteed to have at least i686). */ if (((flags[2] & avx_flags) == avx_flags) diff --git a/libretro-common/file/archive_file.c b/libretro-common/file/archive_file.c index 675145432a..becdf6345b 100644 --- a/libretro-common/file/archive_file.c +++ b/libretro-common/file/archive_file.c @@ -20,7 +20,6 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ - #include #include #include diff --git a/libretro-common/file/config_file.c b/libretro-common/file/config_file.c index a15ce9c7f6..15a1dbae04 100644 --- a/libretro-common/file/config_file.c +++ b/libretro-common/file/config_file.c @@ -547,7 +547,6 @@ bool config_append_file(config_file_t *conf, const char *path) return true; } - config_file_t *config_file_new_from_string(const char *from_string) { size_t i; @@ -979,7 +978,7 @@ void config_set_bool(config_file_t *conf, const char *key, bool val) config_set_string(conf, key, val ? "true" : "false"); } -bool config_file_write(config_file_t *conf, const char *path) +bool config_file_write(config_file_t *conf, const char *path, bool sort) { if (!string_is_empty(path)) { @@ -998,10 +997,12 @@ bool config_file_write(config_file_t *conf, const char *path) return false; /* TODO: this is only useful for a few platforms, find which and add ifdef */ +#if !defined(PS2) buf = calloc(1, 0x4000); setvbuf(file, (char*)buf, _IOFBF, 0x4000); +#endif - config_file_dump(conf, file); + config_file_dump(conf, file, sort); if (file != stdout) fclose(file); @@ -1009,10 +1010,11 @@ bool config_file_write(config_file_t *conf, const char *path) #endif } else - config_file_dump(conf, stdout); + config_file_dump(conf, stdout, sort); return true; } + #ifdef ORBIS void config_file_dump_orbis(config_file_t *conf, int fd) { @@ -1041,7 +1043,8 @@ void config_file_dump_orbis(config_file_t *conf, int fd) } } #endif -void config_file_dump(config_file_t *conf, FILE *file) + +void config_file_dump(config_file_t *conf, FILE *file, bool sort) { struct config_entry_list *list = NULL; struct config_include_list *includes = conf->includes; @@ -1052,7 +1055,11 @@ void config_file_dump(config_file_t *conf, FILE *file) includes = includes->next; } - list = merge_sort_linked_list((struct config_entry_list*)conf->entries, config_sort_compare_func); + if (sort) + list = merge_sort_linked_list((struct config_entry_list*)conf->entries, config_sort_compare_func); + else + list = (struct config_entry_list*)conf->entries; + conf->entries = list; while (list) diff --git a/libretro-common/file/file_path.c b/libretro-common/file/file_path.c index 3716271ac0..762dbc52c0 100644 --- a/libretro-common/file/file_path.c +++ b/libretro-common/file/file_path.c @@ -101,6 +101,12 @@ #include /* stat() is defined here */ #endif +#if !defined(RARCH_CONSOLE) && defined(RARCH_INTERNAL) +#ifdef __WINRT__ +#include +#endif +#endif + /* Assume W-functions do not work below Win2K and Xbox platforms */ #if defined(_WIN32_WINNT) && _WIN32_WINNT < 0x0500 || defined(_XBOX) @@ -954,7 +960,6 @@ void fill_pathname_join_noext(char *out_path, path_remove_extension(out_path); } - /** * fill_pathname_join_delim: * @out_path : output path @@ -979,7 +984,8 @@ void fill_pathname_join_delim(char *out_path, const char *dir, out_path[copied] = delim; out_path[copied+1] = '\0'; - strlcat(out_path, path, size); + if (path) + strlcat(out_path, path, size); } void fill_pathname_join_delim_concat(char *out_path, const char *dir, @@ -1029,45 +1035,67 @@ void fill_pathname_expand_special(char *out_path, const char *in_path, size_t size) { #if !defined(RARCH_CONSOLE) && defined(RARCH_INTERNAL) - if (*in_path == '~') + if (in_path[0] == '~') { - const char *home = getenv("HOME"); - if (home) + char *home_dir = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); + + home_dir[0] = '\0'; + + fill_pathname_home_dir(home_dir, + PATH_MAX_LENGTH * sizeof(char)); + + if (*home_dir) { - size_t src_size = strlcpy(out_path, home, size); + size_t src_size = strlcpy(out_path, home_dir, size); retro_assert(src_size < size); out_path += src_size; size -= src_size; - in_path++; + + if (!path_char_is_slash(out_path[-1])) + { + src_size = strlcpy(out_path, path_default_slash(), size); + retro_assert(src_size < size); + + out_path += src_size; + size -= src_size; + } + + in_path += 2; } + + free(home_dir); } - else if ((in_path[0] == ':') && - ( - (in_path[1] == '/') -#ifdef _WIN32 - || (in_path[1] == '\\') -#endif - ) - ) + else if (in_path[0] == ':') { - size_t src_size; char *application_dir = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); application_dir[0] = '\0'; - fill_pathname_application_path(application_dir, + fill_pathname_application_dir(application_dir, PATH_MAX_LENGTH * sizeof(char)); - path_basedir_wrapper(application_dir); - src_size = strlcpy(out_path, application_dir, size); - retro_assert(src_size < size); + if (*application_dir) + { + size_t src_size = strlcpy(out_path, application_dir, size); + retro_assert(src_size < size); + + out_path += src_size; + size -= src_size; + + if (!path_char_is_slash(out_path[-1])) + { + src_size = strlcpy(out_path, path_default_slash(), size); + retro_assert(src_size < size); + + out_path += src_size; + size -= src_size; + } + + in_path += 2; + } free(application_dir); - - out_path += src_size; - size -= src_size; - in_path += 2; } #endif @@ -1082,7 +1110,7 @@ void fill_pathname_abbreviate_special(char *out_path, const char *candidates[3]; const char *notations[3]; char *application_dir = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); - const char *home = getenv("HOME"); + char *home_dir = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); application_dir[0] = '\0'; @@ -1094,16 +1122,17 @@ void fill_pathname_abbreviate_special(char *out_path, /* ugly hack - use application_dir pointer * before filling it in. C89 reasons */ candidates[0] = application_dir; - candidates[1] = home; + candidates[1] = home_dir; candidates[2] = NULL; notations [0] = ":"; notations [1] = "~"; notations [2] = NULL; - fill_pathname_application_path(application_dir, + fill_pathname_application_dir(application_dir, + PATH_MAX_LENGTH * sizeof(char)); + fill_pathname_home_dir(home_dir, PATH_MAX_LENGTH * sizeof(char)); - path_basedir_wrapper(application_dir); for (i = 0; candidates[i]; i++) { @@ -1131,6 +1160,7 @@ void fill_pathname_abbreviate_special(char *out_path, } free(application_dir); + free(home_dir); #endif retro_assert(strlcpy(out_path, in_path, size) < size); @@ -1172,7 +1202,7 @@ void fill_pathname_application_path(char *s, size_t len) CFBundleRef bundle = CFBundleGetMainBundle(); #endif #ifdef _WIN32 - DWORD ret; + DWORD ret = 0; wchar_t wstr[PATH_MAX_LENGTH] = {0}; #endif #ifdef __HAIKU__ @@ -1184,11 +1214,11 @@ void fill_pathname_application_path(char *s, size_t len) if (!len) return; -#ifdef _WIN32 +#if defined(_WIN32) #ifdef LEGACY_WIN32 - ret = GetModuleFileNameA(GetModuleHandle(NULL), s, len); + ret = GetModuleFileNameA(NULL, s, len); #else - ret = GetModuleFileNameW(GetModuleHandle(NULL), wstr, ARRAY_SIZE(wstr)); + ret = GetModuleFileNameW(NULL, wstr, ARRAY_SIZE(wstr)); if (*wstr) { @@ -1257,4 +1287,27 @@ void fill_pathname_application_path(char *s, size_t len) } #endif } + +void fill_pathname_application_dir(char *s, size_t len) +{ +#ifdef __WINRT__ + strlcpy(s, uwp_dir_install, len); +#else + fill_pathname_application_path(s, len); + path_basedir_wrapper(s); +#endif +} + +void fill_pathname_home_dir(char *s, size_t len) +{ +#ifdef __WINRT__ + strlcpy(s, uwp_dir_data, len); +#else + const char *home = getenv("HOME"); + if (home) + strlcpy(s, home, len); + else + *s = 0; +#endif +} #endif diff --git a/libretro-common/file/nbio/nbio_linux.c b/libretro-common/file/nbio/nbio_linux.c index 8644bb94cb..c454440cd8 100644 --- a/libretro-common/file/nbio/nbio_linux.c +++ b/libretro-common/file/nbio/nbio_linux.c @@ -32,7 +32,6 @@ #include #include - #include #include #include diff --git a/libretro-common/file/nbio/nbio_windowsmmap.c b/libretro-common/file/nbio/nbio_windowsmmap.c index 67860a3909..cac7194f25 100644 --- a/libretro-common/file/nbio/nbio_windowsmmap.c +++ b/libretro-common/file/nbio/nbio_windowsmmap.c @@ -22,7 +22,7 @@ #include -#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) +#if defined(_WIN32) && !defined(_XBOX) #include #include @@ -69,7 +69,11 @@ static void *nbio_mmap_win32_open(const char * filename, unsigned mode) HANDLE file = CreateFile(filename, access, FILE_SHARE_ALL, NULL, dispositions[mode], FILE_ATTRIBUTE_NORMAL, NULL); #else wchar_t *filename_wide = utf8_to_utf16_string_alloc(filename); +#ifdef __WINRT__ + HANDLE file = CreateFile2(filename_wide, access, FILE_SHARE_ALL, dispositions[mode], NULL); +#else HANDLE file = CreateFileW(filename_wide, access, FILE_SHARE_ALL, NULL, dispositions[mode], FILE_ATTRIBUTE_NORMAL, NULL); +#endif if (filename_wide) free(filename_wide); diff --git a/libretro-common/formats/image_texture.c b/libretro-common/formats/image_texture.c index e2f3c3d162..58df1e2324 100644 --- a/libretro-common/formats/image_texture.c +++ b/libretro-common/formats/image_texture.c @@ -202,7 +202,6 @@ end: return success; } - void image_texture_free(struct texture_image *img) { if (!img) diff --git a/libretro-common/formats/jpeg/rjpeg.c b/libretro-common/formats/jpeg/rjpeg.c index e321b69b33..7d4e45a1b3 100644 --- a/libretro-common/formats/jpeg/rjpeg.c +++ b/libretro-common/formats/jpeg/rjpeg.c @@ -779,7 +779,6 @@ static INLINE uint8_t rjpeg__clamp(int x) return (uint8_t) x; } - /* derived from jidctint -- DCT_ISLOW */ #define RJPEG__IDCT_1D(s0,s1,s2,s3,s4,s5,s6,s7) \ int t0,t1,t2,t3,p1,p2,p3,p4,p5,x0,x1,x2,x3; \ @@ -1292,7 +1291,6 @@ static uint8_t rjpeg__get_marker(rjpeg__jpeg *j) return x; } - /* after a restart interval, rjpeg__jpeg_reset the entropy decoder and * the dc prediction */ @@ -1866,7 +1864,6 @@ static int rjpeg__process_frame_header(rjpeg__jpeg *z, int scan) return 1; } - static int rjpeg__decode_jpeg_header(rjpeg__jpeg *z, int scan) { int m; @@ -2014,7 +2011,6 @@ static uint8_t* rjpeg__resample_row_h_2(uint8_t *out, uint8_t *in_near, return out; } - static uint8_t *rjpeg__resample_row_hv_2(uint8_t *out, uint8_t *in_near, uint8_t *in_far, int w, int hs) { @@ -2370,7 +2366,6 @@ static void rjpeg__setup_jpeg(rjpeg__jpeg *j) j->YCbCr_to_RGB_kernel = rjpeg__YCbCr_to_RGB_row; j->resample_row_hv_2_kernel = rjpeg__resample_row_hv_2; - #if defined(__SSE2__) if (mask & RETRO_SIMD_SSE2) { diff --git a/libretro-common/formats/libchdr/libchdr_bitstream.c b/libretro-common/formats/libchdr/libchdr_bitstream.c index 036c60d400..1a6cf73ba2 100644 --- a/libretro-common/formats/libchdr/libchdr_bitstream.c +++ b/libretro-common/formats/libchdr/libchdr_bitstream.c @@ -34,7 +34,6 @@ struct bitstream* create_bitstream(const void *src, uint32_t srclength) return bitstream; } - /*----------------------------------------------------- * bitstream_peek - fetch the requested number of bits * but don't advance the input pointer @@ -62,7 +61,6 @@ uint32_t bitstream_peek(struct bitstream* bitstream, int numbits) return bitstream->buffer >> (32 - numbits); } - /*----------------------------------------------------- * bitstream_remove - advance the input pointer by the * specified number of bits @@ -75,7 +73,6 @@ void bitstream_remove(struct bitstream* bitstream, int numbits) bitstream->bits -= numbits; } - /*----------------------------------------------------- * bitstream_read - fetch the requested number of bits *----------------------------------------------------- @@ -88,7 +85,6 @@ uint32_t bitstream_read(struct bitstream* bitstream, int numbits) return result; } - /*------------------------------------------------- * read_offset - return the current read offset *------------------------------------------------- @@ -106,7 +102,6 @@ uint32_t bitstream_read_offset(struct bitstream* bitstream) return result; } - /*------------------------------------------------- * flush - flush to the nearest byte *------------------------------------------------- diff --git a/libretro-common/formats/libchdr/libchdr_cdrom.c b/libretro-common/formats/libchdr/libchdr_cdrom.c index f59c1712f9..f6876e0b7c 100644 --- a/libretro-common/formats/libchdr/libchdr_cdrom.c +++ b/libretro-common/formats/libchdr/libchdr_cdrom.c @@ -66,8 +66,6 @@ void CLIB_DECL logerror(const char *text, ...) ATTR_PRINTF(1,2); #define LOG(x) #endif - - /*************************************************************************** CONSTANTS ***************************************************************************/ @@ -94,8 +92,6 @@ void CLIB_DECL logerror(const char *text, ...) ATTR_PRINTF(1,2); /** @brief 43 bytes each. */ #define ECC_Q_COMP 43 - - /** * @brief ------------------------------------------------- * ECC lookup tables pre-calculated tables for ECC data calcs @@ -303,7 +299,6 @@ static const uint16_t qoffsets[ECC_Q_NUM_BYTES][ECC_Q_COMP] = { 0x867,0x003,0x05b,0x0b3,0x10b,0x163,0x1bb,0x213,0x26b,0x2c3,0x31b,0x373,0x3cb,0x423,0x47b,0x4d3,0x52b,0x583,0x5db,0x633,0x68b,0x6e3,0x73b,0x793,0x7eb,0x843,0x89b,0x037,0x08f,0x0e7,0x13f,0x197,0x1ef,0x247,0x29f,0x2f7,0x34f,0x3a7,0x3ff,0x457,0x4af,0x507,0x55f } }; - /*------------------------------------------------- * ecc_source_byte - return data from the sector * at the given offset, masking anything diff --git a/libretro-common/formats/libchdr/libchdr_chd.c b/libretro-common/formats/libchdr/libchdr_chd.c index 79a50aac2f..9d41cb44bc 100644 --- a/libretro-common/formats/libchdr/libchdr_chd.c +++ b/libretro-common/formats/libchdr/libchdr_chd.c @@ -1545,8 +1545,6 @@ static chd_error read_uncompressed(chd_file *chd, UINT64 offset, size_t size, UI return CHDERR_NONE; } - - /*------------------------------------------------- hunk_read_into_memory - read a hunk into memory at the given location diff --git a/libretro-common/formats/libchdr/libchdr_huffman.c b/libretro-common/formats/libchdr/libchdr_huffman.c index dd041a76c9..9d69a7b7ac 100644 --- a/libretro-common/formats/libchdr/libchdr_huffman.c +++ b/libretro-common/formats/libchdr/libchdr_huffman.c @@ -232,7 +232,6 @@ enum huffman_error huffman_import_tree_rle(struct huffman_decoder* decoder, stru return bitstream_overflow(bitbuf) ? HUFFERR_INPUT_BUFFER_TOO_SMALL : HUFFERR_NONE; } - /*------------------------------------------------- * import_tree_huffman - import a huffman-encoded * huffman tree from a source data stream diff --git a/libretro-common/formats/tga/rtga.c b/libretro-common/formats/tga/rtga.c index 47017d7523..d39ea57bc0 100644 --- a/libretro-common/formats/tga/rtga.c +++ b/libretro-common/formats/tga/rtga.c @@ -37,7 +37,6 @@ #define RTGA_COMPUTE_Y(r, g, b) ((uint8_t)((((r) * 77) + ((g) * 150) + (29 * (b))) >> 8)) - struct rtga { uint8_t *buff_data; diff --git a/libretro-common/glsm/glsm.c b/libretro-common/glsm/glsm.c index 70fed4ba3f..22ae5f2343 100644 --- a/libretro-common/glsm/glsm.c +++ b/libretro-common/glsm/glsm.c @@ -131,7 +131,6 @@ struct gl_cached_state GLenum func; } depthfunc; - struct { bool used; @@ -335,7 +334,6 @@ void rglTexSubImage2D( width, height, format, type, pixels); } - void rglGetBufferSubData( GLenum target, GLintptr offset, GLsizeiptr size, @@ -898,7 +896,6 @@ void rglCompressedTexImage2D(GLenum target, GLint level, width, height, border, imageSize, data); } - void rglDeleteFramebuffers(GLsizei n, const GLuint *framebuffers) { #ifdef GLSM_DEBUG @@ -1035,7 +1032,6 @@ void rglBindFragDataLocation(GLuint program, GLuint colorNumber, #endif } - /* * Category: Shaders * @@ -1140,7 +1136,6 @@ void rglEndQuery( GLenum target) #endif } - /* * Category: UBO * @@ -1505,7 +1500,6 @@ GLboolean rglIsProgram(GLuint program) return glIsProgram(program); } - void rglTexCoord2f(GLfloat s, GLfloat t) { #ifdef HAVE_LEGACY_GL @@ -1973,7 +1967,6 @@ void rglUniform4fv(GLint location, GLsizei count, const GLfloat *value) glUniform4fv(location, count, value); } - /* * * Core in: @@ -2208,7 +2201,6 @@ void rglTexImage2DMultisample( GLenum target, #endif } - void rglTexImage3D( GLenum target, GLint level, GLint internalFormat, diff --git a/libretro-common/include/array/dynarray.h b/libretro-common/include/array/dynarray.h index f6b1bdf8f6..cdc4ff0d14 100644 --- a/libretro-common/include/array/dynarray.h +++ b/libretro-common/include/array/dynarray.h @@ -235,7 +235,6 @@ #define da_free(a) \ dg_dynarr_free(a) - /* add an element to the array (appended at the end) */ #define da_push(a, v) \ dg_dynarr_push(a, v) @@ -264,7 +263,6 @@ #define da_addn_uninit(a, n) \ dg_dynarr_addn_uninit(a, n) - /* insert a single value v at index idx */ #define da_insert(a, idx, v) \ dg_dynarr_insert(a, idx, v) @@ -343,7 +341,6 @@ #define da_shrink_to_fit(a) \ dg_dynarr_shrink_to_fit(a) - /* removes and returns the last element of the array */ #define da_pop(a) \ dg_dynarr_pop(a) @@ -385,7 +382,6 @@ #define da_end(a) \ dg_dynarr_end(a) - /* returns (logical) number of elements currently in the array */ #define da_count(a) \ dg_dynarr_count(a) @@ -441,7 +437,6 @@ #define dg_dynarr_free(a) \ dg__dynarr_free((void**)&(a).p, &(a).md) - /* add an element to the array (appended at the end) */ #define dg_dynarr_push(a, v) \ (dg__dynarr_maybegrowadd(dg__dynarr_unp(a), 1) ? (((a).p[(a).md.cnt++] = (v)),0) : 0) diff --git a/libretro-common/include/compat/msvc/stdint.h b/libretro-common/include/compat/msvc/stdint.h index c791176c83..63baea04e2 100644 --- a/libretro-common/include/compat/msvc/stdint.h +++ b/libretro-common/include/compat/msvc/stdint.h @@ -67,7 +67,6 @@ extern "C" { # endif #endif - /* 7.18.1 Integer types. */ /* 7.18.1.1 Exact-width integer types. */ @@ -94,7 +93,6 @@ extern "C" { typedef signed __int64 int64_t; typedef unsigned __int64 uint64_t; - /* 7.18.1.2 Minimum-width integer types. */ typedef int8_t int_least8_t; typedef int16_t int_least16_t; diff --git a/libretro-common/include/compat/posix_string.h b/libretro-common/include/compat/posix_string.h index 46c14413c5..f4380c3a65 100644 --- a/libretro-common/include/compat/posix_string.h +++ b/libretro-common/include/compat/posix_string.h @@ -59,7 +59,6 @@ int isblank(int c); #endif - RETRO_END_DECLS #endif diff --git a/libretro-common/include/compat/zlib.h b/libretro-common/include/compat/zlib.h index 60fa3be50d..94110afd3d 100644 --- a/libretro-common/include/compat/zlib.h +++ b/libretro-common/include/compat/zlib.h @@ -31,7 +31,6 @@ Jean-loup Gailly Mark Adler jloup@gzip.org madler@alumni.caltech.edu - The data format used by the zlib library is described by RFCs (Request for Comments) 1950 to 1952 in the files http://tools.ietf.org/html/rfc1950 (zlib format), rfc1951 (deflate format) and rfc1952 (gzip format). @@ -220,7 +219,6 @@ typedef gz_header FAR *gz_headerp; #define zlib_version zlibVersion() /* for compatibility with versions < 1.0.2 */ - /* basic functions */ const char * zlibVersion (void); @@ -252,7 +250,6 @@ typedef gz_header FAR *gz_headerp; this will be done by deflate(). */ - int deflate (z_streamp strm, int flush); /* deflate compresses as much data as possible, and stops when the input @@ -359,7 +356,6 @@ typedef gz_header FAR *gz_headerp; space to continue compressing. */ - int deflateEnd (z_streamp strm); /* All dynamically allocated data structures for this stream are freed. @@ -373,7 +369,6 @@ typedef gz_header FAR *gz_headerp; deallocated). */ - /* int inflateInit (z_streamp strm); @@ -398,7 +393,6 @@ typedef gz_header FAR *gz_headerp; until inflate() is called. */ - int inflate (z_streamp strm, int flush); /* inflate decompresses as much data as possible, and stops when the input @@ -514,7 +508,6 @@ typedef gz_header FAR *gz_headerp; recovery of the data is desired. */ - int inflateEnd (z_streamp strm); /* All dynamically allocated data structures for this stream are freed. @@ -526,7 +519,6 @@ typedef gz_header FAR *gz_headerp; static string (which must not be deallocated). */ - /* Advanced functions */ /* @@ -1634,7 +1626,6 @@ uint32_t adler32 (uint32_t adler, const uint8_t *buf, size_t len); len2. */ - /* various hacks, don't look :) */ /* deflateInit and inflateInit are macros to allow checking the zlib version diff --git a/libretro-common/include/file/config_file.h b/libretro-common/include/file/config_file.h index 41b65a91f6..b60801c91b 100644 --- a/libretro-common/include/file/config_file.h +++ b/libretro-common/include/file/config_file.h @@ -20,7 +20,6 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ - #ifndef __LIBRETRO_SDK_CONFIG_FILE_H #define __LIBRETRO_SDK_CONFIG_FILE_H @@ -64,7 +63,6 @@ struct config_file struct config_include_list *includes; }; - typedef struct config_file config_file_t; struct config_file_cb @@ -181,17 +179,20 @@ void config_set_bool(config_file_t *conf, const char *entry, bool val); void config_set_uint(config_file_t *conf, const char *key, unsigned int val); /* Write the current config to a file. */ -bool config_file_write(config_file_t *conf, const char *path); +bool config_file_write(config_file_t *conf, const char *path, bool val); /* Dump the current config to an already opened file. * Does not close the file. */ void config_file_dump(config_file_t *conf, FILE *file); + #ifdef ORBIS void config_file_dump_orbis(config_file_t *conf, int fd); #endif + +void config_file_dump(config_file_t *conf, FILE *file, bool val); + bool config_file_exists(const char *path); RETRO_END_DECLS #endif - diff --git a/libretro-common/include/file/file_path.h b/libretro-common/include/file/file_path.h index 026b4f7933..51adab9f1f 100644 --- a/libretro-common/include/file/file_path.h +++ b/libretro-common/include/file/file_path.h @@ -46,7 +46,6 @@ enum RARCH_FILE_UNSUPPORTED }; - /** * path_is_compressed_file: * @path : path @@ -462,6 +461,8 @@ void fill_pathname_slash(char *path, size_t size); #if !defined(RARCH_CONSOLE) && defined(RARCH_INTERNAL) void fill_pathname_application_path(char *buf, size_t size); +void fill_pathname_application_dir(char *buf, size_t size); +void fill_pathname_home_dir(char *buf, size_t size); #endif /** diff --git a/libretro-common/include/formats/jsonsax.h b/libretro-common/include/formats/jsonsax.h index c98331fb39..837d5b28bf 100644 --- a/libretro-common/include/formats/jsonsax.h +++ b/libretro-common/include/formats/jsonsax.h @@ -29,7 +29,6 @@ RETRO_BEGIN_DECLS - enum { JSONSAX_OK = 0, diff --git a/libretro-common/include/gfx/math/matrix_3x3.h b/libretro-common/include/gfx/math/matrix_3x3.h index 791f1dae06..8dbf66c090 100644 --- a/libretro-common/include/gfx/math/matrix_3x3.h +++ b/libretro-common/include/gfx/math/matrix_3x3.h @@ -197,7 +197,6 @@ static INLINE bool matrix_3x3_square_to_quad( e = dy3 - dy0 + h * dy3; } - matrix_3x3_init(*mat, a, d, g, b, e, h, diff --git a/libretro-common/include/gfx/scaler/pixconv.h b/libretro-common/include/gfx/scaler/pixconv.h index b83e0e7f03..27b98b0ef5 100644 --- a/libretro-common/include/gfx/scaler/pixconv.h +++ b/libretro-common/include/gfx/scaler/pixconv.h @@ -29,7 +29,6 @@ RETRO_BEGIN_DECLS - void conv_0rgb1555_argb8888(void *output, const void *input, int width, int height, int out_stride, int in_stride); diff --git a/libretro-common/include/libchdr/bitstream.h b/libretro-common/include/libchdr/bitstream.h index d376373b76..271c89cb08 100644 --- a/libretro-common/include/libchdr/bitstream.h +++ b/libretro-common/include/libchdr/bitstream.h @@ -39,5 +39,4 @@ uint32_t bitstream_peek(struct bitstream* bitstream, int numbits); void bitstream_remove(struct bitstream* bitstream, int numbits); uint32_t bitstream_flush(struct bitstream* bitstream); - #endif diff --git a/libretro-common/include/libchdr/cdrom.h b/libretro-common/include/libchdr/cdrom.h index 232314e76b..041ff2fa60 100644 --- a/libretro-common/include/libchdr/cdrom.h +++ b/libretro-common/include/libchdr/cdrom.h @@ -15,7 +15,6 @@ #include - /*************************************************************************** CONSTANTS ***************************************************************************/ diff --git a/libretro-common/include/libchdr/chd.h b/libretro-common/include/libchdr/chd.h index 9b4df95349..454de38774 100644 --- a/libretro-common/include/libchdr/chd.h +++ b/libretro-common/include/libchdr/chd.h @@ -49,7 +49,6 @@ extern "C" { #include "coretypes.h" #include - /*************************************************************************** Compressed Hunks of Data header format. All numbers are stored in @@ -171,7 +170,6 @@ extern "C" { ***************************************************************************/ - /*************************************************************************** CONSTANTS ***************************************************************************/ @@ -279,8 +277,6 @@ enum _chd_error }; typedef enum _chd_error chd_error; - - /*************************************************************************** TYPE DEFINITIONS ***************************************************************************/ @@ -288,7 +284,6 @@ typedef enum _chd_error chd_error; /* opaque types */ typedef struct _chd_file chd_file; - /* extract header structure (NOT the on-disk header structure) */ typedef struct _chd_header chd_header; struct _chd_header @@ -321,7 +316,6 @@ struct _chd_header UINT32 obsolete_hunksize; /* obsolete field -- do not use! */ }; - /* structure for returning information about a verification pass */ typedef struct _chd_verify_result chd_verify_result; struct _chd_verify_result @@ -332,13 +326,10 @@ struct _chd_verify_result UINT8 metasha1[CHD_SHA1_BYTES]; /* SHA1 checksum of metadata */ }; - - /*************************************************************************** FUNCTION PROTOTYPES ***************************************************************************/ - /* ----- CHD file management ----- */ /* create a new CHD file fitting the given description */ @@ -364,31 +355,21 @@ RFILE *chd_core_file(chd_file *chd); /* return an error string for the given CHD error */ const char *chd_error_string(chd_error err); - - /* ----- CHD header management ----- */ /* return a pointer to the extracted CHD header data */ const chd_header *chd_get_header(chd_file *chd); - - - /* ----- core data read/write ----- */ /* read one hunk from the CHD file */ chd_error chd_read(chd_file *chd, UINT32 hunknum, void *buffer); - - /* ----- metadata management ----- */ /* get indexed metadata of a particular sort */ chd_error chd_get_metadata(chd_file *chd, UINT32 searchtag, UINT32 searchindex, void *output, UINT32 outputlen, UINT32 *resultlen, UINT32 *resulttag, UINT8 *resultflags); - - - /* ----- codec interfaces ----- */ /* set internal codec parameters */ diff --git a/libretro-common/include/libchdr/huffman.h b/libretro-common/include/libchdr/huffman.h index 183bd74fdf..ec5ef54a7b 100644 --- a/libretro-common/include/libchdr/huffman.h +++ b/libretro-common/include/libchdr/huffman.h @@ -15,7 +15,6 @@ #include "bitstream.h" - /*************************************************************************** * CONSTANTS *************************************************************************** diff --git a/libretro-common/include/libchdr/libchdr_zlib.h b/libretro-common/include/libchdr/libchdr_zlib.h index 4f3f141050..324faeeaa2 100644 --- a/libretro-common/include/libchdr/libchdr_zlib.h +++ b/libretro-common/include/libchdr/libchdr_zlib.h @@ -36,7 +36,6 @@ struct _zlib_codec_data zlib_allocator allocator; }; - /* codec-private data for the CDZL codec */ typedef struct _cdzl_codec_data cdzl_codec_data; struct _cdzl_codec_data { diff --git a/libretro-common/include/libretro_d3d.h b/libretro-common/include/libretro_d3d.h index d95931b3e9..a0ba716fdb 100644 --- a/libretro-common/include/libretro_d3d.h +++ b/libretro-common/include/libretro_d3d.h @@ -54,7 +54,6 @@ struct retro_hw_render_interface_d3d11 pD3DCompile D3DCompile; }; - #endif #endif /* LIBRETRO_DIRECT3D_H__ */ diff --git a/libretro-common/include/lists/dir_list.h b/libretro-common/include/lists/dir_list.h index 4babb02d39..d1d61d9be5 100644 --- a/libretro-common/include/lists/dir_list.h +++ b/libretro-common/include/lists/dir_list.h @@ -29,6 +29,23 @@ RETRO_BEGIN_DECLS +/** + * dir_list_append: + * @list : existing list to append to. + * @dir : directory path. + * @ext : allowed extensions of file directory entries to include. + * @include_dirs : include directories as part of the finished directory listing? + * @include_hidden : include hidden files and directories as part of the finished directory listing? + * @include_compressed : Only include files which match ext. Do not try to match compressed files, etc. + * @recursive : list directory contents recursively + * + * Create a directory listing, appending to an existing list + * + * Returns: true success, false in case of error. + **/ +bool dir_list_append(struct string_list *list, const char *dir, const char *ext, + bool include_dirs, bool include_hidden, bool include_compressed, bool recursive); + /** * dir_list_new: * @dir : directory path. diff --git a/libretro-common/include/lists/file_list.h b/libretro-common/include/lists/file_list.h index 208bf15a59..587967d514 100644 --- a/libretro-common/include/lists/file_list.h +++ b/libretro-common/include/lists/file_list.h @@ -52,7 +52,6 @@ typedef struct file_list size_t size; } file_list_t; - void *file_list_get_userdata_at_offset(const file_list_t *list, size_t index); diff --git a/libretro-common/include/math/float_minmax.h b/libretro-common/include/math/float_minmax.h index 2164dde0f7..9d446d6196 100644 --- a/libretro-common/include/math/float_minmax.h +++ b/libretro-common/include/math/float_minmax.h @@ -58,5 +58,4 @@ static INLINE float float_max(float a, float b) #endif } - #endif diff --git a/libretro-common/include/net/net_compat.h b/libretro-common/include/net/net_compat.h index 789f944e71..516120ab9d 100644 --- a/libretro-common/include/net/net_compat.h +++ b/libretro-common/include/net/net_compat.h @@ -46,7 +46,6 @@ #define MSG_NOSIGNAL 0 #endif - #elif defined(_XBOX) #define NOD3D diff --git a/libretro-common/include/net/net_ifinfo.h b/libretro-common/include/net/net_ifinfo.h index b1d2535500..14fbf68823 100644 --- a/libretro-common/include/net/net_ifinfo.h +++ b/libretro-common/include/net/net_ifinfo.h @@ -32,7 +32,6 @@ RETRO_BEGIN_DECLS - struct net_ifinfo_entry { char *name; @@ -53,5 +52,4 @@ bool net_ifinfo_new(net_ifinfo_t *list); RETRO_END_DECLS - #endif diff --git a/libretro-common/include/queues/task_queue.h b/libretro-common/include/queues/task_queue.h index 40c35ddfdb..c0965ecda5 100644 --- a/libretro-common/include/queues/task_queue.h +++ b/libretro-common/include/queues/task_queue.h @@ -42,7 +42,6 @@ enum task_type TASK_TYPE_BLOCKING }; - typedef struct retro_task retro_task_t; typedef void (*retro_task_callback_t)(void *task_data, void *user_data, const char *error); @@ -210,7 +209,6 @@ void task_queue_push(retro_task_t *task); * This must only be called from the main thread. */ void task_queue_wait(retro_task_condition_fn_t cond, void* data); - /* Sends a signal to terminate all the tasks. * * This won't terminate the tasks immediately. diff --git a/libretro-common/include/retro_assert.h b/libretro-common/include/retro_assert.h index 9f3abdeafb..13db8cf8a5 100644 --- a/libretro-common/include/retro_assert.h +++ b/libretro-common/include/retro_assert.h @@ -26,6 +26,7 @@ #include #ifdef RARCH_INTERNAL +#include #define retro_assert(cond) do { \ if (!(cond)) { printf("Assertion failed at %s:%d.\n", __FILE__, __LINE__); abort(); } \ } while(0) diff --git a/libretro-common/include/retro_common_api.h b/libretro-common/include/retro_common_api.h index c3b3f4927f..fc4f745414 100644 --- a/libretro-common/include/retro_common_api.h +++ b/libretro-common/include/retro_common_api.h @@ -113,6 +113,5 @@ Of course, another school of thought is that you should do as little damage as p in as few places as possible... */ - /* _LIBRETRO_COMMON_RETRO_COMMON_API_H */ #endif diff --git a/libretro-common/include/retro_environment.h b/libretro-common/include/retro_environment.h index e220c1529b..4a68046b51 100644 --- a/libretro-common/include/retro_environment.h +++ b/libretro-common/include/retro_environment.h @@ -101,6 +101,14 @@ printf("This is C++, version %d.\n", __cplusplus); #define __WINRT__ 1 #endif +/* MSVC obviously has to have some non-standard constants... */ +#if _M_IX86_FP == 1 +#define __SSE__ 1 +#elif _M_IX86_FP == 2 || (defined(_M_AMD64) || defined(_M_X64)) +#define __SSE__ 1 +#define __SSE2__ 1 +#endif + #endif #endif diff --git a/libretro-common/include/retro_timers.h b/libretro-common/include/retro_timers.h index d11e67e7c2..884c078942 100644 --- a/libretro-common/include/retro_timers.h +++ b/libretro-common/include/retro_timers.h @@ -95,8 +95,8 @@ static INLINE void retro_sleep(unsigned msec) SDL_Delay(msec); #elif defined(_3DS) svcSleepThread(1000000 * (s64)msec); -#elif defined(__WINRT__) - /* TODO/FIXME */ +#elif defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + SleepEx(msec, FALSE); #elif defined(_WIN32) Sleep(msec); #elif defined(XENON) diff --git a/libretro-common/include/streams/interface_stream.h b/libretro-common/include/streams/interface_stream.h index 71d5c97fd4..ec480c6624 100644 --- a/libretro-common/include/streams/interface_stream.h +++ b/libretro-common/include/streams/interface_stream.h @@ -103,7 +103,6 @@ intfstream_t *intfstream_open_memory(void *data, intfstream_t *intfstream_open_chd_track(const char *path, unsigned mode, unsigned hints, int32_t track); - RETRO_END_DECLS #endif diff --git a/libretro-common/include/streams/trans_stream.h b/libretro-common/include/streams/trans_stream.h index 0a10368e73..9adc09ad0f 100644 --- a/libretro-common/include/streams/trans_stream.h +++ b/libretro-common/include/streams/trans_stream.h @@ -39,7 +39,6 @@ RETRO_BEGIN_DECLS - enum trans_stream_error { TRANS_STREAM_ERROR_NONE = 0, diff --git a/libretro-common/include/utils/md5.h b/libretro-common/include/utils/md5.h index 6e84851c5d..caf160bce1 100644 --- a/libretro-common/include/utils/md5.h +++ b/libretro-common/include/utils/md5.h @@ -32,7 +32,6 @@ RETRO_BEGIN_DECLS - /* Any 32-bit or wider unsigned integer data type will do */ typedef unsigned int MD5_u32plus; diff --git a/libretro-common/include/vulkan/vulkan_symbol_wrapper.h b/libretro-common/include/vulkan/vulkan_symbol_wrapper.h index 06f404e2ce..ac891aa06a 100644 --- a/libretro-common/include/vulkan/vulkan_symbol_wrapper.h +++ b/libretro-common/include/vulkan/vulkan_symbol_wrapper.h @@ -348,7 +348,6 @@ VkBool32 vulkan_symbol_wrapper_load_device_symbol(VkDevice device, const char *n #define VULKAN_SYMBOL_WRAPPER_LOAD_DEVICE_SYMBOL(device, name, pfn) vulkan_symbol_wrapper_load_device_symbol(device, name, (PFN_vkVoidFunction*) &(pfn)) #define VULKAN_SYMBOL_WRAPPER_LOAD_DEVICE_EXTENSION_SYMBOL(device, name) vulkan_symbol_wrapper_load_device_symbol(device, #name, (PFN_vkVoidFunction*) & name) - #ifdef __cplusplus } #endif diff --git a/libretro-common/lists/dir_list.c b/libretro-common/lists/dir_list.c index fc360f748b..0972ec84f0 100644 --- a/libretro-common/lists/dir_list.c +++ b/libretro-common/lists/dir_list.c @@ -53,7 +53,6 @@ static int qstrcmp_dir(const void *a_, const void *b_) int a_type = a->attr.i; int b_type = b->attr.i; - /* Sort directories before files. */ if (a_type != b_type) return b_type - a_type; @@ -230,6 +229,42 @@ error: return -1; } +/** + * dir_list_append: + * @list : existing list to append to. + * @dir : directory path. + * @ext : allowed extensions of file directory entries to include. + * @include_dirs : include directories as part of the finished directory listing? + * @include_hidden : include hidden files and directories as part of the finished directory listing? + * @include_compressed : Only include files which match ext. Do not try to match compressed files, etc. + * @recursive : list directory contents recursively + * + * Create a directory listing, appending to an existing list + * + * Returns: true success, false in case of error. + **/ +bool dir_list_append(struct string_list *list, + const char *dir, + const char *ext, bool include_dirs, + bool include_hidden, bool include_compressed, + bool recursive) +{ + struct string_list *ext_list = NULL; + + if (ext) + ext_list = string_split(ext, "|"); + + if(dir_list_read(dir, list, ext_list, include_dirs, + include_hidden, include_compressed, recursive) == -1) + { + string_list_free(ext_list); + return false; + } + + string_list_free(ext_list); + return true; +} + /** * dir_list_new: * @dir : directory path. @@ -249,24 +284,18 @@ struct string_list *dir_list_new(const char *dir, bool include_hidden, bool include_compressed, bool recursive) { - struct string_list *ext_list = NULL; struct string_list *list = NULL; if (!(list = string_list_new())) return NULL; - if (ext) - ext_list = string_split(ext, "|"); - - if(dir_list_read(dir, list, ext_list, include_dirs, - include_hidden, include_compressed, recursive) == -1) + if (!dir_list_append(list, dir, ext, include_dirs, + include_hidden, include_compressed, recursive)) { string_list_free(list); - string_list_free(ext_list); return NULL; } - string_list_free(ext_list); return list; } diff --git a/libretro-common/lists/file_list.c b/libretro-common/lists/file_list.c index 1525d8879e..dcf03d4de6 100644 --- a/libretro-common/lists/file_list.c +++ b/libretro-common/lists/file_list.c @@ -136,7 +136,6 @@ size_t file_list_get_directory_ptr(const file_list_t *list) return list->list[size].directory_ptr; } - void file_list_pop(file_list_t *list, size_t *directory_ptr) { if (!list) diff --git a/libretro-common/memmap/memalign.c b/libretro-common/memmap/memalign.c index 449d8471b8..c2332962b7 100644 --- a/libretro-common/memmap/memalign.c +++ b/libretro-common/memmap/memalign.c @@ -25,7 +25,6 @@ #include - void *memalign_alloc(size_t boundary, size_t size) { void **place = NULL; @@ -54,9 +53,9 @@ void memalign_free(void *ptr) void *memalign_alloc_aligned(size_t size) { -#if defined(__x86_64__) || defined(__LP64) || defined(__IA64__) || defined(_M_X64) || defined(_WIN64) +#if defined(__x86_64__) || defined(__LP64) || defined(__IA64__) || defined(_M_X64) || defined(_M_X64) || defined(_WIN64) return memalign_alloc(64, size); -#elif defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(GEKKO) +#elif defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(GEKKO) || defined(_M_IX86) return memalign_alloc(32, size); #else return memalign_alloc(32, size); diff --git a/libretro-common/net/net_compat.c b/libretro-common/net/net_compat.c index ea45743596..cec24a0cd1 100644 --- a/libretro-common/net/net_compat.c +++ b/libretro-common/net/net_compat.c @@ -447,7 +447,6 @@ error: return NULL; } - /* convert presentation format to network format */ static const char * inet_ntop6x(const unsigned char *src, char *dst, size_t size) diff --git a/libretro-common/queues/fifo_queue.c b/libretro-common/queues/fifo_queue.c index d6b21aca48..09fae570e0 100644 --- a/libretro-common/queues/fifo_queue.c +++ b/libretro-common/queues/fifo_queue.c @@ -64,7 +64,6 @@ void fifo_write(fifo_buffer_t *buffer, const void *in_buf, size_t size) buffer->end = (buffer->end + size) % buffer->size; } - void fifo_read(fifo_buffer_t *buffer, void *in_buf, size_t size) { size_t first_read = size; diff --git a/libretro-common/queues/message_queue.c b/libretro-common/queues/message_queue.c index a8086c3b9f..f5af162f2d 100644 --- a/libretro-common/queues/message_queue.c +++ b/libretro-common/queues/message_queue.c @@ -93,7 +93,6 @@ void msg_queue_free(msg_queue_t *queue) free(queue); } - /** * msg_queue_push: * @queue : pointer to queue object diff --git a/libretro-common/queues/task_queue.c b/libretro-common/queues/task_queue.c index 2eb51dd9e7..7ca188eefc 100644 --- a/libretro-common/queues/task_queue.c +++ b/libretro-common/queues/task_queue.c @@ -401,7 +401,6 @@ static void retro_task_threaded_reset(void) slock_unlock(running_lock); } - static bool retro_task_threaded_find( retro_task_finder_t func, void *user_data) { diff --git a/libretro-common/rthreads/psp_pthread.h b/libretro-common/rthreads/psp_pthread.h index 007aa5cb11..7aea08a875 100644 --- a/libretro-common/rthreads/psp_pthread.h +++ b/libretro-common/rthreads/psp_pthread.h @@ -62,7 +62,6 @@ typedef struct sthreadEntry start_routine; } sthread_args_struct; - static int psp_thread_wrap(SceSize args, void *argp) { sthread_args_struct* sthread_args = (sthread_args_struct*)argp; @@ -137,7 +136,6 @@ static INLINE int pthread_mutex_unlock(pthread_mutex_t *mutex) #endif } - static INLINE int pthread_join(pthread_t thread, void **retval) { #ifdef VITA @@ -238,7 +236,6 @@ static INLINE int pthread_cond_init(pthread_cond_t *cond, return 0; - #else /* FIXME: stub */ return 1; @@ -282,7 +279,6 @@ static INLINE int pthread_cond_destroy(pthread_cond_t *cond) #endif } - static INLINE int pthread_detach(pthread_t thread) { return 0; diff --git a/libretro-common/rthreads/rthreads.c b/libretro-common/rthreads/rthreads.c index 7c67d9465c..930f71b05c 100644 --- a/libretro-common/rthreads/rthreads.c +++ b/libretro-common/rthreads/rthreads.c @@ -853,9 +853,9 @@ bool scond_wait_timeout(scond_t *cond, slock_t *lock, int64_t timeout_us) now.tv_sec = s; now.tv_nsec = n; #elif defined(PS2) - int tickUS = cpu_ticks()/295.0; - now.tv_sec = tickUS/1000000; - now.tv_nsec = tickUS * 1000; + int tickms = clock(); + now.tv_sec = tickms/1000; + now.tv_nsec = tickms * 1000; #elif defined(__mips__) || defined(VITA) || defined(_3DS) struct timeval tm; diff --git a/libretro-common/samples/utils/Makefile b/libretro-common/samples/utils/Makefile index b9c785ee55..94942be407 100644 --- a/libretro-common/samples/utils/Makefile +++ b/libretro-common/samples/utils/Makefile @@ -62,13 +62,11 @@ asflags := $(extra_flags) LDFLAGS := flags += -std=c99 -DMD5_BUILD_UTILITY -DSHA1_BUILD_UTILITY - ifeq (1,$(use_neon)) ASMFLAGS := -INEON/asm asflags += -mfpu=neon endif - OBJS += $(CORE_DIR)/djb2.o \ $(CORE_DIR)/md5.o \ $(CORE_DIR)/sha1.o \ diff --git a/libretro-common/streams/chd_stream.c b/libretro-common/streams/chd_stream.c index 669bd43391..f622a782ff 100644 --- a/libretro-common/streams/chd_stream.c +++ b/libretro-common/streams/chd_stream.c @@ -251,7 +251,6 @@ chdstream_t *chdstream_open(const char *path, int32_t track) else pregap = 0; - stream->chd = chd; stream->frames_per_hunk = hd->hunkbytes / hd->unitbytes; stream->track_frame = meta.frame_offset; diff --git a/libretro-common/streams/file_stream.c b/libretro-common/streams/file_stream.c index 680a809ec5..3a6f161c5d 100644 --- a/libretro-common/streams/file_stream.c +++ b/libretro-common/streams/file_stream.c @@ -323,7 +323,6 @@ int filestream_eof(RFILE *stream) return stream->eof_flag; } - int64_t filestream_tell(RFILE *stream) { int64_t output; diff --git a/libretro-common/utils/sha1_main.c b/libretro-common/utils/sha1_main.c index 1eb0c8ec54..55b0e0c4e3 100644 --- a/libretro-common/utils/sha1_main.c +++ b/libretro-common/utils/sha1_main.c @@ -31,7 +31,6 @@ */ void usage(void); - /* * main * diff --git a/libretro-common/vfs/vfs_implementation.c b/libretro-common/vfs/vfs_implementation.c index 8dbef4c42e..ec1a21a2b0 100644 --- a/libretro-common/vfs/vfs_implementation.c +++ b/libretro-common/vfs/vfs_implementation.c @@ -326,6 +326,7 @@ libretro_vfs_implementation_file *retro_vfs_file_open_impl(const char *path, uns */ /* TODO: this is only useful for a few platforms, find which and add ifdef */ stream->fp = fp; +#if !defined(PS2) /* TODO: PS2 IMPROVEMENT */ stream->buf = (char*)calloc(1, 0x4000); setvbuf(stream->fp, stream->buf, _IOFBF, 0x4000); #endif diff --git a/libretro-common/vulkan/vulkan_symbol_wrapper.c b/libretro-common/vulkan/vulkan_symbol_wrapper.c index abf02dca3b..7fe13ea8b9 100644 --- a/libretro-common/vulkan/vulkan_symbol_wrapper.c +++ b/libretro-common/vulkan/vulkan_symbol_wrapper.c @@ -176,7 +176,6 @@ PFN_vkGetInstanceProcAddr vulkan_symbol_wrapper_instance_proc_addr(void) return GetInstanceProcAddr; } - VkBool32 vulkan_symbol_wrapper_load_instance_symbol(VkInstance instance, const char *name, PFN_vkVoidFunction *ppSymbol) { *ppSymbol = GetInstanceProcAddr(instance, name); diff --git a/libretro-db/bintree.c b/libretro-db/bintree.c index b080aa4f55..b68d391bf1 100644 --- a/libretro-db/bintree.c +++ b/libretro-db/bintree.c @@ -86,7 +86,6 @@ static int bintree_insert_internal(bintree_t *t, struct bintree_node *root, void return -EINVAL; } - static int bintree_iterate_internal(struct bintree_node *n, bintree_iter_cb cb, void *ctx) { diff --git a/libretro-db/c_converter.c b/libretro-db/c_converter.c index 3d2e2ac615..294164c437 100644 --- a/libretro-db/c_converter.c +++ b/libretro-db/c_converter.c @@ -64,7 +64,6 @@ typedef struct const char* fname; } dat_converter_token_t; - typedef struct dat_converter_map_t dat_converter_map_t; typedef struct dat_converter_list_t dat_converter_list_t; typedef union dat_converter_list_item_t dat_converter_list_item_t; @@ -100,7 +99,6 @@ union dat_converter_list_item_t dat_converter_list_t* list; }; - struct dat_converter_bt_node_t { int index; @@ -212,7 +210,6 @@ static dat_converter_bt_node_t* dat_converter_bt_node_insert( return NULL; } - static void dat_converter_list_append(dat_converter_list_t* dst, void* item) { if (dst->count == dst->capacity) diff --git a/libretro-db/query.c b/libretro-db/query.c index 47dc88f069..6bcb0e2f7a 100644 --- a/libretro-db/query.c +++ b/libretro-db/query.c @@ -353,7 +353,6 @@ static void query_raise_unexpected_char( *error = tmp_error_buff; } - static void query_argument_free(struct argument *arg) { unsigned i; @@ -399,7 +398,6 @@ static struct buffer query_chomp(struct buffer buff) return buff; } - static struct buffer query_expect_eof(struct buffer buff, const char ** error) { buff = query_chomp(buff); @@ -613,7 +611,6 @@ static struct buffer query_expect_char(struct buffer buff, return buff; } - static struct buffer query_parse_argument(struct buffer buff, struct argument *arg, const char **error) { diff --git a/managers/cheat_manager.c b/managers/cheat_manager.c index 9e979d09f2..96d3f4090b 100644 --- a/managers/cheat_manager.c +++ b/managers/cheat_manager.c @@ -52,7 +52,6 @@ #include "../input/input_driver.h" #include "../configuration.h" - unsigned cheat_manager_get_buf_size(void) { return cheat_manager_state.buf_size; @@ -227,7 +226,7 @@ bool cheat_manager_save(const char *path, const char *cheat_database, bool overw } - ret = config_file_write(conf, cheats_file); + ret = config_file_write(conf, cheats_file, true); config_file_free(conf); return ret; @@ -272,7 +271,6 @@ static void cheat_manager_new(unsigned size) { unsigned i; - cheat_manager_free(); cheat_manager_state.buf_size = size; @@ -413,7 +411,6 @@ bool cheat_manager_load(const char *path, bool append) config_file_free(conf); conf = NULL; - cheat_manager_alloc_if_empty(); if (append) @@ -433,7 +430,6 @@ bool cheat_manager_load(const char *path, bool append) cheat_manager_new(cheats); } - for (i = orig_size; i < cheats; i++) { cheat_manager_state.cheats[i].idx = i; @@ -461,13 +457,11 @@ error: return false; } - bool cheat_manager_realloc(unsigned new_size, unsigned default_handler) { unsigned i; unsigned orig_size; - if (!cheat_manager_state.cheats) { cheat_manager_state.cheats = (struct item_cheat*) @@ -845,7 +839,6 @@ int cheat_manager_initialize_memory(rarch_setting_t *setting, bool wraparound) cheat_manager_state.memory_initialized = true; - runloop_msg_queue_push(msg_hash_to_str(MSG_CHEAT_INIT_SUCCESS), 1, 180, true); #ifdef HAVE_MENU @@ -973,7 +966,6 @@ int cheat_manager_search(enum cheat_search_type search_type) return 0; } - cheat_manager_setup_search_meta(cheat_manager_state.search_bit_size, &bytes_per_item, &mask, &bits); /* little endian FF000000 = 256 */ diff --git a/managers/cheat_manager.h b/managers/cheat_manager.h index e941036a07..c1f4dbff15 100644 --- a/managers/cheat_manager.h +++ b/managers/cheat_manager.h @@ -24,7 +24,6 @@ RETRO_BEGIN_DECLS - enum cheat_handler_type { CHEAT_HANDLER_TYPE_EMU = 0, diff --git a/managers/core_option_manager.c b/managers/core_option_manager.c index a60554bfa6..87ea3e23ca 100644 --- a/managers/core_option_manager.c +++ b/managers/core_option_manager.c @@ -156,7 +156,6 @@ void core_option_manager_get(core_option_manager_t *opt, void *data) var->value = NULL; } - /** * core_option_manager_new: * @conf_path : Filesystem path to write core option config file to. @@ -253,7 +252,7 @@ bool core_option_manager_flush(core_option_manager_t *opt) } RARCH_LOG("Saved core options file to \"%s\"\n", opt->conf_path); - return config_file_write(opt->conf, opt->conf_path); + return config_file_write(opt->conf, opt->conf_path, true); } /** @@ -279,7 +278,7 @@ bool core_option_manager_flush_game_specific( core_option_manager_get_val(opt, i)); } - return config_file_write(opt->conf, path); + return config_file_write(opt->conf, path, true); } /** diff --git a/managers/state_manager.c b/managers/state_manager.c index 26425e3ded..fc6b512a6b 100644 --- a/managers/state_manager.c +++ b/managers/state_manager.c @@ -50,7 +50,7 @@ #define UINT32_MAX 0xffffffffu #endif -#if defined(__x86_64__) || defined(__i386__) || defined(__i486__) || defined(__i686__) +#if defined(__x86_64__) || defined(__i386__) || defined(__i486__) || defined(__i686__) || defined(_M_IX86) || defined(_M_AMD64) || defined(_M_X64) #define CPU_X86 #endif @@ -394,7 +394,6 @@ static void state_manager_raw_decompress(const void *patch, * This means that on average, ~2 * maxcompsize is * unused at any given moment. */ - /* These are called very few constant times per frame, * keep it as simple as possible. */ static INLINE void write_size_t(void *ptr, size_t val) @@ -660,7 +659,6 @@ void state_manager_event_init(unsigned rewind_buffer_size) state_manager_push_do(rewind_state.state); } - bool state_manager_frame_is_reversed(void) { return frame_is_reversed; diff --git a/menu/cbs/menu_cbs_cancel.c b/menu/cbs/menu_cbs_cancel.c index 4dba74ac47..72c3fe8774 100644 --- a/menu/cbs/menu_cbs_cancel.c +++ b/menu/cbs/menu_cbs_cancel.c @@ -159,7 +159,6 @@ int menu_cbs_init_bind_cancel(menu_file_list_cbs_t *cbs, if (!cbs) return -1; - BIND_ACTION_CANCEL(cbs, action_cancel_pop_default); if (menu_cbs_init_bind_cancel_compare_label(cbs, label) == 0) diff --git a/menu/cbs/menu_cbs_deferred_push.c b/menu/cbs/menu_cbs_deferred_push.c index 79e1aee9b2..64b6af9a01 100644 --- a/menu/cbs/menu_cbs_deferred_push.c +++ b/menu/cbs/menu_cbs_deferred_push.c @@ -246,7 +246,6 @@ end: return ret; } - #ifdef HAVE_LIBRETRODB static int deferred_push_cursor_manager_list_generic( menu_displaylist_info_t *info, enum database_query_type type) diff --git a/menu/cbs/menu_cbs_get_value.c b/menu/cbs/menu_cbs_get_value.c index a5ccd31733..ed273bde70 100644 --- a/menu/cbs/menu_cbs_get_value.c +++ b/menu/cbs/menu_cbs_get_value.c @@ -501,7 +501,6 @@ static void menu_action_setting_disp_set_label_input_desc( else strlcpy(s, "---", len); - *w = 19; strlcpy(s2, path, len2); } diff --git a/menu/cbs/menu_cbs_left.c b/menu/cbs/menu_cbs_left.c index 2fcb431cf5..19704f5320 100644 --- a/menu/cbs/menu_cbs_left.c +++ b/menu/cbs/menu_cbs_left.c @@ -234,7 +234,6 @@ static int action_left_mainmenu(unsigned type, const char *label, else push_list = 2; - switch (push_list) { case 1: diff --git a/menu/cbs/menu_cbs_ok.c b/menu/cbs/menu_cbs_ok.c index 734408e440..33275572cd 100644 --- a/menu/cbs/menu_cbs_ok.c +++ b/menu/cbs/menu_cbs_ok.c @@ -26,6 +26,10 @@ #include "../../config.h" #endif +#ifdef HAVE_DISCORD +#include "../../discord/discord.h" +#endif + #include "../../config.def.h" #include "../../config.def.keybinds.h" #include "../../wifi/wifi_driver.h" @@ -1122,7 +1126,6 @@ static int file_load_with_detect_core_wrapper( PATH_MAX_LENGTH * sizeof(char))) ret = -1; - if ( !is_carchive && !string_is_empty(path) && !string_is_empty(menu_path_new)) fill_pathname_join(menu->detect_content_path, @@ -1546,7 +1549,6 @@ static int default_action_ok_load_content_from_playlist_from_menu(const char *_p return 0; } - #define default_action_ok_set(funcname, _id, _flush) \ static int (funcname)(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) \ { \ @@ -1657,7 +1659,6 @@ static int action_ok_file_load(const char *path, CORE_TYPE_PLAIN); } - static int action_ok_playlist_entry_collection(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { @@ -2151,7 +2152,6 @@ static void menu_input_wifi_cb(void *userdata, const char *passphrase) menu_input_dialog_end(); } - static void menu_input_st_string_cb_rename_entry(void *userdata, const char *str) { @@ -2170,7 +2170,6 @@ static void menu_input_st_string_cb_rename_entry(void *userdata, NULL); } - menu_input_dialog_end(); } @@ -2628,7 +2627,6 @@ static int action_ok_deferred_list_stub(const char *path, return 0; } - #if defined(HAVE_LAKKA_SWITCH) || defined(HAVE_LIBNX) static int action_ok_set_switch_cpu_profile(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) @@ -3008,7 +3006,6 @@ static int action_ok_cheat_copy_before(const char *path, runloop_msg_queue_push(msg, 1, 180, true); - return 0 ; } @@ -3150,7 +3147,6 @@ static int action_ok_file_load_detect_core(const char *path, return 0; } - static int action_ok_load_state(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { @@ -3343,10 +3339,11 @@ static void cb_generic_dir_download(void *task_data, } /* expects http_transfer_t*, file_transfer_t* */ -static void cb_generic_download(void *task_data, +void cb_generic_download(void *task_data, void *user_data, const char *err) { char output_path[PATH_MAX_LENGTH]; + char buf[PATH_MAX_LENGTH]; #if defined(HAVE_COMPRESSION) && defined(HAVE_ZLIB) bool extract = true; #endif @@ -3423,6 +3420,14 @@ static void cb_generic_download(void *task_data, case MENU_ENUM_LABEL_CB_LAKKA_DOWNLOAD: dir_path = LAKKA_UPDATE_DIR; break; + case MENU_ENUM_LABEL_CB_DISCORD_AVATAR: + { + fill_pathname_application_special(buf, + PATH_MAX_LENGTH * sizeof(char), + APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_DISCORD_AVATARS); + dir_path = buf; + break; + } default: RARCH_WARN("Unknown transfer type '%s' bailing out.\n", msg_hash_to_str(transf->enum_idx)); @@ -3495,6 +3500,10 @@ finish: RARCH_ERR("Download of '%s' failed: %s\n", (transf ? transf->path: "unknown"), err); } +#ifdef HAVE_DISCORD + else if (transf->enum_idx == MENU_ENUM_LABEL_CB_DISCORD_AVATAR) + discord_avatar_set_ready(true); +#endif if (data) { @@ -3508,7 +3517,6 @@ finish: } #endif - static int action_ok_download_generic(const char *path, const char *label, const char *menu_label, unsigned type, size_t idx, size_t entry_idx, @@ -3661,7 +3669,7 @@ static int action_ok_option_create(const char *path, return false; } - if (config_file_write(conf, game_path)) + if (config_file_write(conf, game_path, true)) { runloop_msg_queue_push( msg_hash_to_str(MSG_CORE_OPTIONS_FILE_CREATED_SUCCESSFULLY), @@ -3804,7 +3812,6 @@ static int action_ok_delete_entry(const char *path, return 0; } - static int action_ok_rdb_entry_submenu(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { @@ -4016,7 +4023,6 @@ static int action_ok_netplay_connect_room(const char *path, return 0; } - static int action_ok_netplay_lan_scan(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { @@ -4326,7 +4332,7 @@ static void netplay_lan_scan_callback(void *task_data, static int action_ok_push_netplay_refresh_rooms(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { - char url [2048] = "http://newlobby.libretro.com/list/"; + char url [2048] = "http://lobby.libretro.com/list/"; #ifndef RARCH_CONSOLE task_push_netplay_lan_scan(netplay_lan_scan_callback); #endif @@ -4335,7 +4341,6 @@ static int action_ok_push_netplay_refresh_rooms(const char *path, } #endif - static int action_ok_scan_directory_list(const char *path, const char *label, unsigned type, size_t idx, size_t entry_idx) { diff --git a/menu/cbs/menu_cbs_right.c b/menu/cbs/menu_cbs_right.c index f0f902a2c2..35661aef08 100644 --- a/menu/cbs/menu_cbs_right.c +++ b/menu/cbs/menu_cbs_right.c @@ -212,7 +212,6 @@ static int audio_mixer_stream_volume_right(unsigned type, const char *label, return 0; } - static int action_right_goto_tab(void) { menu_ctx_list_t list_info; diff --git a/menu/cbs/menu_cbs_start.c b/menu/cbs/menu_cbs_start.c index 963b3c154f..1867101741 100644 --- a/menu/cbs/menu_cbs_start.c +++ b/menu/cbs/menu_cbs_start.c @@ -164,7 +164,6 @@ static int action_start_shader_pass(unsigned type, const char *label) return 0; } - static int action_start_shader_scale_pass(unsigned type, const char *label) { unsigned pass = type - MENU_SETTINGS_SHADER_PASS_SCALE_0; diff --git a/menu/cbs/menu_cbs_sublabel.c b/menu/cbs/menu_cbs_sublabel.c index 7b4c258f89..207f325afb 100644 --- a/menu/cbs/menu_cbs_sublabel.c +++ b/menu/cbs/menu_cbs_sublabel.c @@ -43,6 +43,8 @@ #include "../../dynamic.h" #include "../../configuration.h" #include "../../managers/cheat_manager.h" +#include "../input/input_driver.h" +#include "../tasks/tasks_internal.h" #define default_sublabel_macro(func_name, lbl) \ static int (func_name)(file_list_t *list, unsigned type, unsigned i, const char *label, const char *path, char *s, size_t len) \ @@ -187,6 +189,7 @@ default_sublabel_macro(action_bind_sublabel_netplay_nickname, MENU_ default_sublabel_macro(action_bind_sublabel_cheevos_username, MENU_ENUM_SUBLABEL_CHEEVOS_USERNAME) default_sublabel_macro(action_bind_sublabel_cheevos_password, MENU_ENUM_SUBLABEL_CHEEVOS_PASSWORD) default_sublabel_macro(action_bind_sublabel_video_post_filter_record, MENU_ENUM_SUBLABEL_VIDEO_POST_FILTER_RECORD) +default_sublabel_macro(action_bind_sublabel_start_core, MENU_ENUM_SUBLABEL_START_CORE) default_sublabel_macro(action_bind_sublabel_core_list, MENU_ENUM_SUBLABEL_CORE_LIST) default_sublabel_macro(action_bind_sublabel_download_core, MENU_ENUM_SUBLABEL_DOWNLOAD_CORE) default_sublabel_macro(action_bind_sublabel_sideload_core_list, MENU_ENUM_SUBLABEL_SIDELOAD_CORE_LIST) @@ -384,6 +387,7 @@ default_sublabel_macro(action_bind_sublabel_ozone_menu_color_theme, default_sublabel_macro(action_bind_sublabel_menu_use_preferred_system_color_theme, MENU_ENUM_SUBLABEL_MENU_USE_PREFERRED_SYSTEM_COLOR_THEME) default_sublabel_macro(action_bind_sublabel_menu_wallpaper_opacity, MENU_ENUM_SUBLABEL_MENU_WALLPAPER_OPACITY) default_sublabel_macro(action_bind_sublabel_menu_framebuffer_opacity, MENU_ENUM_SUBLABEL_MENU_FRAMEBUFFER_OPACITY) +default_sublabel_macro(action_bind_sublabel_menu_horizontal_animation, MENU_ENUM_SUBLABEL_MENU_HORIZONTAL_ANIMATION) default_sublabel_macro(action_bind_sublabel_menu_ribbon_enable, MENU_ENUM_SUBLABEL_XMB_RIBBON_ENABLE) default_sublabel_macro(action_bind_sublabel_menu_font, MENU_ENUM_SUBLABEL_XMB_FONT) default_sublabel_macro(action_bind_sublabel_quick_menu_show_take_screenshot, MENU_ENUM_SUBLABEL_QUICK_MENU_SHOW_TAKE_SCREENSHOT) @@ -499,6 +503,36 @@ default_sublabel_macro(action_bind_sublabel_switch_gpu_profile, MENU default_sublabel_macro(action_bind_sublabel_switch_backlight_control, MENU_ENUM_SUBLABEL_SWITCH_BACKLIGHT_CONTROL) #endif +static int action_bind_sublabel_systeminfo_controller_entry( + file_list_t *list, + unsigned type, unsigned i, + const char *label, const char *path, + char *s, size_t len) +{ + char tmp[4096]; + unsigned controller; + + for(controller = 0; controller < MAX_USERS; controller++) + { + if (input_is_autoconfigured(controller)) + { + snprintf(tmp, sizeof(tmp), "Port #%d device name: %s (#%d)", + controller, + input_config_get_device_name(controller), + input_autoconfigure_get_device_name_index(controller)); + + if (string_is_equal(path, tmp)) + break; + } + } + snprintf(tmp, sizeof(tmp), "Device display name: %s\nDevice config name: %s\nDevice identifiers: %d/%d", + input_config_get_device_display_name(controller) ? input_config_get_device_display_name(controller) : "N/A", + input_config_get_device_display_name(controller) ? input_config_get_device_config_name(controller) : "N/A", + input_config_get_vid(controller), input_config_get_pid(controller)); + strlcpy(s, tmp, len); + + return 0; +} static int action_bind_sublabel_cheevos_entry( file_list_t *list, unsigned type, unsigned i, @@ -1104,6 +1138,9 @@ int menu_cbs_init_bind_sublabel(menu_file_list_cbs_t *cbs, case MENU_ENUM_LABEL_MENU_FRAMEBUFFER_OPACITY: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_menu_framebuffer_opacity); break; + case MENU_ENUM_LABEL_MENU_HORIZONTAL_ANIMATION: + BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_menu_horizontal_animation); + break; case MENU_ENUM_LABEL_MENU_WALLPAPER_OPACITY: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_menu_wallpaper_opacity); break; @@ -1672,6 +1709,9 @@ int menu_cbs_init_bind_sublabel(menu_file_list_cbs_t *cbs, case MENU_ENUM_LABEL_LOAD_CONTENT_SPECIAL: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_content_special); break; + case MENU_ENUM_LABEL_START_CORE: + BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_start_core); + break; case MENU_ENUM_LABEL_CORE_LIST: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_core_list); break; @@ -1859,6 +1899,9 @@ int menu_cbs_init_bind_sublabel(menu_file_list_cbs_t *cbs, case MENU_ENUM_LABEL_CPU_CORES: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_systeminfo_cpu_cores); break; + case MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY: + BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_systeminfo_controller_entry); + break; case MENU_ENUM_LABEL_VIDEO_BLACK_FRAME_INSERTION: BIND_ACTION_SUBLABEL(cbs, action_bind_sublabel_video_black_frame_insertion); break; diff --git a/menu/drivers/materialui.c b/menu/drivers/materialui.c index 9099662cd8..2cc5b53d4f 100644 --- a/menu/drivers/materialui.c +++ b/menu/drivers/materialui.c @@ -608,7 +608,6 @@ static void materialui_compute_entries_box(materialui_handle_t* mui, int width) menu_entry_init(&entry); menu_entry_get(&entry, 0, i, NULL, true); - sublabel_str = menu_entry_get_sublabel(&entry); menu_entry_free(&entry); @@ -998,7 +997,6 @@ static void materialui_render_menu_list( } } - static size_t materialui_list_get_size(void *data, enum menu_list_type type) { switch (type) @@ -2205,7 +2203,6 @@ static int materialui_pointer_down(void *userdata, menu_navigation_set_selection(ii); } - } return 0; @@ -2352,7 +2349,6 @@ static void materialui_list_insert(void *userdata, node->texture_switch2_index = MUI_TEXTURE_DATABASE; node->texture_switch2_set = true; break; - case 32: /* TODO: Need to find out what this is */ case FILE_TYPE_RDB_ENTRY: node->texture_switch2_index = MUI_TEXTURE_SETTINGS; node->texture_switch2_set = true; diff --git a/menu/drivers/nuklear.c b/menu/drivers/nuklear.c index b6e5154619..3d687af322 100644 --- a/menu/drivers/nuklear.c +++ b/menu/drivers/nuklear.c @@ -117,7 +117,6 @@ error: return NULL; } - static void nk_menu_input_gamepad(nk_menu_handle_t *nk) { switch (nk->action) @@ -195,7 +194,6 @@ static void nk_menu_main(nk_menu_handle_t *nk) nk_buffer_info(&nk->status, &nk->ctx.memory); } - static void nk_menu_frame(void *data, video_frame_info_t *video_info) { unsigned ticker_limit, i; @@ -212,7 +210,6 @@ static void nk_menu_frame(void *data, video_frame_info_t *video_info) 0.98, 0.98, 0.98, 1, }; - for (i = 0; i < 16; i++) { coord_black[i] = 0; diff --git a/menu/drivers/nuklear/nk_common.c b/menu/drivers/nuklear/nk_common.c index 61800585fd..6c8e849c93 100644 --- a/menu/drivers/nuklear/nk_common.c +++ b/menu/drivers/nuklear/nk_common.c @@ -201,7 +201,6 @@ void nk_common_device_draw(struct nk_device *dev, menu_display_blend_begin(); - #if defined(HAVE_OPENGL) || defined(HAVE_OPENGLES) glActiveTexture(GL_TEXTURE0); #endif diff --git a/menu/drivers/null.c b/menu/drivers/null.c index 55a6bdc5f3..9022267cb1 100644 --- a/menu/drivers/null.c +++ b/menu/drivers/null.c @@ -22,18 +22,54 @@ #include "../menu_driver.h" +static bool g_menu_on = false; + +static void* null_init(void **userdata, bool video_is_threaded) +{ + menu_handle_t *menu = (menu_handle_t*)calloc(1, sizeof(*menu)); + + if (!menu) + return NULL; + + return menu; +} + +static void null_free(void *data) +{ + menu_handle_t *menu = (menu_handle_t*)data; + + /*if (menu) + free(menu);*/ +} + +static void null_toggle(void *userdata, bool menu_on) +{ + (void)userdata; + + g_menu_on = menu_on; +} + +static int null_menu_iterate(menu_handle_t *menu, void *userdata, enum menu_action action) +{ + (void)menu; + (void)userdata; + (void)action; + + return 1; +} + menu_ctx_driver_t menu_ctx_null = { NULL, /* set_texture */ NULL, /* render_messagebox */ - NULL, /* iterate */ + null_menu_iterate, NULL, /* render */ NULL, /* frame */ - NULL, /* init */ - NULL, /* free */ + null_init, + null_free, NULL, /* context_reset */ NULL, /* context_destroy */ NULL, /* populate_entries */ - NULL, /* toggle */ + null_toggle, NULL, /* navigation_clear */ NULL, /* navigation_decrement */ NULL, /* navigation_increment */ diff --git a/menu/drivers/ozone/ozone.c b/menu/drivers/ozone/ozone.c index fa9fd08a87..6463ae5e90 100644 --- a/menu/drivers/ozone/ozone.c +++ b/menu/drivers/ozone/ozone.c @@ -23,6 +23,10 @@ #include "ozone_texture.h" #include "ozone_sidebar.h" +#ifdef HAVE_DISCORD +#include "discord/discord.h" +#endif + #include #include #include @@ -348,14 +352,36 @@ static void ozone_context_reset(void *data, bool is_threaded) for (i = 0; i < OZONE_TEXTURE_LAST; i++) { char filename[PATH_MAX_LENGTH]; - strlcpy(filename, OZONE_TEXTURES_FILES[i], sizeof(filename)); +#ifdef HAVE_DISCORD + if (i == OZONE_TEXTURE_DISCORD_OWN_AVATAR) + strlcpy(filename, discord_get_own_avatar(), sizeof(filename)); + else +#endif + strlcpy(filename, OZONE_TEXTURES_FILES[i], sizeof(filename)); + strlcat(filename, ".png", sizeof(filename)); - if (!menu_display_reset_textures_list(filename, ozone->png_path, &ozone->textures[i], TEXTURE_FILTER_MIPMAP_LINEAR)) +#ifdef HAVE_DISCORD + if (i == OZONE_TEXTURE_DISCORD_OWN_AVATAR && discord_avatar_is_ready()) { - ozone->has_all_assets = false; - RARCH_WARN("[OZONE] Asset missing: %s%s%s\n", ozone->png_path, path_default_slash(), filename); + char buf[PATH_MAX_LENGTH]; + fill_pathname_application_special(buf, + sizeof(buf), + APPLICATION_SPECIAL_DIRECTORY_THUMBNAILS_DISCORD_AVATARS); + if (!menu_display_reset_textures_list(filename, buf, &ozone->textures[i], TEXTURE_FILTER_MIPMAP_LINEAR)) + RARCH_WARN("[OZONE] Asset missing: %s%s%s\n", ozone->png_path, path_default_slash(), filename); } + else + { +#endif + if (!menu_display_reset_textures_list(filename, ozone->png_path, &ozone->textures[i], TEXTURE_FILTER_MIPMAP_LINEAR)) + { + ozone->has_all_assets = false; + RARCH_WARN("[OZONE] Asset missing: %s%s%s\n", ozone->png_path, path_default_slash(), filename); + } +#ifdef HAVE_DISCORD + } +#endif } /* Sidebar textures */ @@ -930,7 +956,12 @@ static void ozone_draw_header(ozone_handle_t *ozone, video_frame_info_t *video_i /* Icon */ menu_display_blend_begin(video_info); - ozone_draw_icon(video_info, 60, 60, ozone->textures[OZONE_TEXTURE_RETROARCH], 47, 14, video_info->width, video_info->height, 0, 1, ozone->theme->entries_icon); +#ifdef HAVE_DISCORD + if (discord_avatar_is_ready()) + ozone_draw_icon(video_info, 60, 60, ozone->textures[OZONE_TEXTURE_DISCORD_OWN_AVATAR], 47, 14, video_info->width, video_info->height, 0, 1, ozone->theme->entries_icon); + else +#endif + ozone_draw_icon(video_info, 60, 60, ozone->textures[OZONE_TEXTURE_RETROARCH], 47, 14, video_info->width, video_info->height, 0, 1, ozone->theme->entries_icon); menu_display_blend_end(video_info); /* Battery */ @@ -1117,6 +1148,16 @@ static void ozone_frame(void *data, video_frame_info_t *video_info) bool draw_osk = menu_input_dialog_get_display_kb(); static bool draw_osk_old = false; +#ifdef HAVE_DISCORD + static bool reset = false; + + if (discord_avatar_is_ready() && !reset) + { + ozone_context_reset(data, false); + reset = true; + } +#endif + menu_animation_ctx_entry_t entry; if (!ozone) diff --git a/menu/drivers/ozone/ozone_sidebar.c b/menu/drivers/ozone/ozone_sidebar.c index a6d51dfb40..21bceb7342 100644 --- a/menu/drivers/ozone/ozone_sidebar.c +++ b/menu/drivers/ozone/ozone_sidebar.c @@ -370,7 +370,6 @@ void ozone_sidebar_goto(ozone_handle_t *ozone, unsigned new_selection) } } - void ozone_change_tab(ozone_handle_t *ozone, enum msg_hash_enums tab, enum menu_settings_type type) diff --git a/menu/drivers/ozone/ozone_texture.c b/menu/drivers/ozone/ozone_texture.c index 3b3414dcdc..d131167d83 100644 --- a/menu/drivers/ozone/ozone_texture.c +++ b/menu/drivers/ozone/ozone_texture.c @@ -79,7 +79,6 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_RDB]; - /* Menu collection submenus*/ case MENU_ENUM_LABEL_CONTENT_COLLECTION_LIST: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_ZIP]; @@ -150,6 +149,7 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_HELP_AUDIO_VIDEO_TROUBLESHOOTING: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_HELP]; case MENU_ENUM_LABEL_QUIT_RETROARCH: + case MENU_ENUM_LABEL_BLOCK_SRAM_OVERWRITE: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_EXIT]; /* Settings icons*/ case MENU_ENUM_LABEL_DRIVER_SETTINGS: @@ -178,6 +178,7 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_INPUT_USER_14_BINDS: case MENU_ENUM_LABEL_INPUT_USER_15_BINDS: case MENU_ENUM_LABEL_INPUT_USER_16_BINDS: + case MENU_ENUM_LABEL_START_NET_RETROPAD: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_SETTINGS]; case MENU_ENUM_LABEL_LATENCY_SETTINGS: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_LATENCY]; @@ -191,6 +192,7 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_LOGGING_SETTINGS: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_LOG]; case MENU_ENUM_LABEL_FRAME_THROTTLE_SETTINGS: + case MENU_ENUM_LABEL_FASTFORWARD_RATIO: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_FRAMESKIP]; case MENU_ENUM_LABEL_QUICK_MENU_START_RECORDING: case MENU_ENUM_LABEL_RECORDING_SETTINGS: @@ -258,6 +260,8 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_RESET_TO_DEFAULT_CONFIG: case MENU_ENUM_LABEL_CHEAT_RELOAD_CHEATS: case MENU_ENUM_LABEL_RESTART_RETROARCH: + case MENU_ENUM_LABEL_VRR_RUNLOOP_ENABLE: + case MENU_ENUM_LABEL_AUTOSAVE_INTERVAL: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_RELOAD]; case MENU_ENUM_LABEL_SHUTDOWN: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_SHUTDOWN]; @@ -269,6 +273,7 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET: case MENU_ENUM_LABEL_CHEAT_FILE_LOAD: case MENU_ENUM_LABEL_CHEAT_FILE_LOAD_APPEND: + case MENU_ENUM_LABEL_SAVESTATE_AUTO_LOAD: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_LOADSTATE]; case MENU_ENUM_LABEL_CHEAT_APPLY_CHANGES: case MENU_ENUM_LABEL_SHADER_APPLY_CHANGES: @@ -281,7 +286,14 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_TOGGLE: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_MENU_APPLY_TOGGLE]; case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_LOAD: + case MENU_ENUM_LABEL_SAVESTATE_AUTO_INDEX: return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_MENU_APPLY_COG]; + case MENU_ENUM_LABEL_SAVESTATE_AUTO_SAVE: + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_SAVESTATE]; + case MENU_ENUM_LABEL_SLOWMOTION_RATIO: + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_RESUME]; + case MENU_ENUM_LABEL_START_VIDEO_PROCESSOR: + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_MOVIE]; default: break; } @@ -385,26 +397,40 @@ menu_texture_item ozone_entries_icon_get_texture(ozone_handle_t *ozone, (type <= MENU_SETTINGS_INPUT_DESC_END) ) { + /* This part is only utilized by Input User # Binds */ unsigned input_id; if (type < MENU_SETTINGS_INPUT_DESC_BEGIN) { input_id = MENU_SETTINGS_INPUT_BEGIN; + if ( type == input_id + 1) + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_ADC]; if ( type == input_id + 2) return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_SETTINGS]; + if ( type == input_id + 3) + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_BIND_ALL]; if ( type == input_id + 4) return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_RELOAD]; if ( type == input_id + 5) return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_SAVING]; + if ( type == input_id + 6) + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_MOUSE]; + if ((type > (input_id + 30)) && (type < (input_id + 42))) + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_LGUN]; + if ( type == input_id + 42) + return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_TURBO]; + /* align to use the same code of Quickmenu controls*/ input_id = input_id + 7; } else { + /* Quickmenu controls repeats the same icons for all users*/ input_id = MENU_SETTINGS_INPUT_DESC_BEGIN; while (type > (input_id + 23)) { input_id = (input_id + 24) ; } } + /* This is utilized for both Input Binds and Quickmenu controls*/ if ( type == input_id ) return ozone->icons_textures[OZONE_ENTRIES_ICONS_TEXTURE_INPUT_BTN_D]; if ( type == (input_id + 1)) @@ -683,6 +709,16 @@ switch (id) return "menu_apply_toggle.png"; case OZONE_ENTRIES_ICONS_TEXTURE_MENU_APPLY_COG: return "menu_apply_cog.png"; + case OZONE_ENTRIES_ICONS_TEXTURE_INPUT_ADC: + return "input_ADC.png"; + case OZONE_ENTRIES_ICONS_TEXTURE_INPUT_BIND_ALL: + return "input_BIND_ALL.png"; + case OZONE_ENTRIES_ICONS_TEXTURE_INPUT_MOUSE: + return "input_MOUSE.png"; + case OZONE_ENTRIES_ICONS_TEXTURE_INPUT_LGUN: + return "input_LGUN.png"; + case OZONE_ENTRIES_ICONS_TEXTURE_INPUT_TURBO: + return "input_TURBO.png"; } return NULL; } diff --git a/menu/drivers/ozone/ozone_texture.h b/menu/drivers/ozone/ozone_texture.h index 5441732378..1be37d7774 100644 --- a/menu/drivers/ozone/ozone_texture.h +++ b/menu/drivers/ozone/ozone_texture.h @@ -28,7 +28,9 @@ enum OZONE_TEXTURE { OZONE_TEXTURE_RETROARCH = 0, OZONE_TEXTURE_CURSOR_BORDER, - +#ifdef HAVE_DISCORD + OZONE_TEXTURE_DISCORD_OWN_AVATAR, +#endif OZONE_TEXTURE_LAST }; @@ -198,6 +200,11 @@ enum OZONE_ENTRIES_ICONS_TEXTURE_PAUSE, OZONE_ENTRIES_ICONS_TEXTURE_MENU_APPLY_TOGGLE, OZONE_ENTRIES_ICONS_TEXTURE_MENU_APPLY_COG, + OZONE_ENTRIES_ICONS_TEXTURE_INPUT_ADC, + OZONE_ENTRIES_ICONS_TEXTURE_INPUT_BIND_ALL, + OZONE_ENTRIES_ICONS_TEXTURE_INPUT_MOUSE, + OZONE_ENTRIES_ICONS_TEXTURE_INPUT_LGUN, + OZONE_ENTRIES_ICONS_TEXTURE_INPUT_TURBO, OZONE_ENTRIES_ICONS_TEXTURE_LAST }; diff --git a/menu/drivers/rgui.c b/menu/drivers/rgui.c index 5c172a6f3c..86590ad5e4 100644 --- a/menu/drivers/rgui.c +++ b/menu/drivers/rgui.c @@ -53,6 +53,17 @@ #define RGUI_TERM_WIDTH(width) (((width - RGUI_TERM_START_X(width) - RGUI_TERM_START_X(width)) / (FONT_WIDTH_STRIDE))) #define RGUI_TERM_HEIGHT(width, height) (((height - RGUI_TERM_START_Y(height) - RGUI_TERM_START_X(width)) / (FONT_HEIGHT_STRIDE)) - 1) +typedef struct +{ + uint16_t hover_color; + uint16_t normal_color; + uint16_t title_color; + uint16_t bg_dark_color; + uint16_t bg_light_color; + uint16_t border_dark_color; + uint16_t border_light_color; +} rgui_colors_t; + typedef struct { bool bg_modified; @@ -65,75 +76,39 @@ typedef struct bool border_thickness; float scroll_y; char *msgbox; + rgui_colors_t colors; } rgui_t; static uint16_t *rgui_framebuf_data = NULL; -/* Note: if we knew what colour format each of these - * special cases required, we could do away with all - * this nonsense and handle it inside a single colour - * conversion function... - * In the meantime, we'll use the existing obfuscated - * values for all the non-standard platforms, and leave - * it messy... */ -#if defined(GEKKO) || defined(PSP) +#if defined(PS2) -/* Is this supposed to be 4444 ABGR? - * Have no idea what's going on here, so have to use - * fixed colour values... */ -#define HOVER_COLOR(settings) ((3 << 0) | (10 << 4) | (3 << 8) | (7 << 12)) -#define NORMAL_COLOR(settings) 0x7FFF -#define TITLE_COLOR(settings) HOVER_COLOR(settings) -#define BG_DARK_COLOR(settings) ((6 << 12) | (1 << 8) | (1 << 4) | (1 << 0)) -#define BG_LIGHT_COLOR(settings) ((6 << 12) | (2 << 8) | (2 << 4) | (2 << 0)) -#define BORDER_DARK_COLOR(settings) ((6 << 12) | (1 << 8) | (1 << 5) | (1 << 0)) -#define BORDER_LIGHT_COLOR(settings) ((6 << 12) | (2 << 8) | (2 << 5) | (2 << 0)) +static uint16_t argb32_to_abgr1555(uint32_t col) +{ + unsigned a = ((col >> 24) & 0xff) >> 7; + unsigned r = ((col >> 16) & 0xff) >> 3; + unsigned g = ((col >> 8) & 0xff) >> 3; + unsigned b = ((col & 0xff) ) >> 3; + return (a << 15) | (b << 10) | (g << 5) | r; +} -#elif defined(PS2) +#define argb32_to_pixel_platform_format(color) argb32_to_abgr1555(color) -/* Have no idea what's going on here, so have to use - * fixed colour values... */ -#define HOVER_COLOR(settings) 0x03E0 -#define NORMAL_COLOR(settings) 0x7FFF -#define TITLE_COLOR(settings) HOVER_COLOR(settings) -#define BG_DARK_COLOR(settings) ((0 << 15) | (1 << 12) | (1 << 7) | (1 << 2)) -#define BG_LIGHT_COLOR(settings) ((0 << 15) | (2 << 12) | (2 << 7) | (2 << 2)) -#define BORDER_DARK_COLOR(settings) ((0 << 15) | (1 << 12) | (1 << 8) | (1 << 2)) -#define BORDER_LIGHT_COLOR(settings) ((0 << 15) | (2 << 12) | (2 << 8) | (2 << 2)) +#elif defined(PSP) || defined(GEKKO) -#elif defined(HAVE_LIBNX) && !defined(HAVE_OPENGL) - -#define HOVER_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_entry_hover_color)) -#define NORMAL_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_entry_normal_color)) -#define TITLE_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_title_color)) -/* Is this supposed to be RGB565? - * Have no idea what's going on here, so have to use - * fixed colour values... */ -#define BG_DARK_COLOR(settings) ((((31 * (54)) / 255) << 11) | (((63 * (54)) / 255) << 5) | ((31 * (54)) / 255)) -#define BG_LIGHT_COLOR(settings) BG_DARK_COLOR(settings) -#define BORDER_DARK_COLOR(settings) ((((31 * (54)) / 255) << 11) | (((63 * (109)) / 255) << 5) | ((31 * (54)) / 255)) -#define BORDER_LIGHT_COLOR(settings) BORDER_DARK_COLOR(settings) - -static uint16_t argb32_to_rgba4444(uint32_t col) +static uint16_t argb32_to_abgr4444(uint32_t col) { unsigned a = ((col >> 24) & 0xff) >> 4; unsigned r = ((col >> 16) & 0xff) >> 4; unsigned g = ((col >> 8) & 0xff) >> 4; unsigned b = ((col & 0xff) ) >> 4; - return (r << 12) | (g << 8) | (b << 4) | a; + return (a << 12) | (b << 8) | (g << 4) | r; } +#define argb32_to_pixel_platform_format(color) argb32_to_abgr4444(color) + #else -/* This is the only sane case... */ -#define HOVER_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_entry_hover_color)) -#define NORMAL_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_entry_normal_color)) -#define TITLE_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_title_color)) -#define BG_DARK_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_bg_dark_color)) -#define BG_LIGHT_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_bg_light_color)) -#define BORDER_DARK_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_border_dark_color)) -#define BORDER_LIGHT_COLOR(settings) (argb32_to_rgba4444(settings->uints.menu_border_light_color)) - static uint16_t argb32_to_rgba4444(uint32_t col) { unsigned a = ((col >> 24) & 0xff) >> 4; @@ -143,8 +118,21 @@ static uint16_t argb32_to_rgba4444(uint32_t col) return (r << 12) | (g << 8) | (b << 4) | a; } +#define argb32_to_pixel_platform_format(color) argb32_to_rgba4444(color) + #endif +static void prepare_rgui_colors(rgui_t *rgui, settings_t *settings) +{ + rgui->colors.hover_color = argb32_to_pixel_platform_format(settings->uints.menu_entry_hover_color); + rgui->colors.normal_color = argb32_to_pixel_platform_format(settings->uints.menu_entry_normal_color); + rgui->colors.title_color = argb32_to_pixel_platform_format(settings->uints.menu_title_color); + rgui->colors.bg_dark_color = argb32_to_pixel_platform_format(settings->uints.menu_bg_dark_color); + rgui->colors.bg_light_color = argb32_to_pixel_platform_format(settings->uints.menu_bg_light_color); + rgui->colors.border_dark_color = argb32_to_pixel_platform_format(settings->uints.menu_border_dark_color); + rgui->colors.border_light_color = argb32_to_pixel_platform_format(settings->uints.menu_border_light_color); +} + static uint16_t rgui_bg_filler(rgui_t *rgui, unsigned x, unsigned y, uint16_t dark_color, uint16_t light_color) { unsigned shift = (rgui->bg_thickness ? 1 : 0); @@ -322,8 +310,8 @@ static void rgui_render_background(rgui_t *rgui) if (settings->bools.menu_rgui_border_filler_enable) { - dark_color = BORDER_DARK_COLOR(settings); - light_color = BORDER_LIGHT_COLOR(settings); + dark_color = rgui->colors.border_dark_color; + light_color = rgui->colors.border_light_color; rgui_fill_rect(rgui, rgui_framebuf_data, fb_pitch, 5, 5, fb_width - 10, 5, dark_color, light_color, rgui_border_filler); @@ -405,8 +393,8 @@ static void rgui_render_messagebox(rgui_t *rgui, const char *message) if (rgui_framebuf_data) { - dark_color = BG_DARK_COLOR(settings); - light_color = BG_LIGHT_COLOR(settings); + dark_color = rgui->colors.bg_dark_color; + light_color = rgui->colors.bg_light_color; rgui_fill_rect(rgui, rgui_framebuf_data, fb_pitch, x + 5, y + 5, width - 10, height - 10, dark_color, light_color, rgui_bg_filler); @@ -414,8 +402,8 @@ static void rgui_render_messagebox(rgui_t *rgui, const char *message) if (settings->bools.menu_rgui_border_filler_enable) { - dark_color = BORDER_DARK_COLOR(settings); - light_color = BORDER_LIGHT_COLOR(settings); + dark_color = rgui->colors.border_dark_color; + light_color = rgui->colors.border_light_color; rgui_fill_rect(rgui, rgui_framebuf_data, fb_pitch, x, y, width - 5, 5, dark_color, light_color, rgui_border_filler); @@ -428,7 +416,7 @@ static void rgui_render_messagebox(rgui_t *rgui, const char *message) } } - normal_color = NORMAL_COLOR(settings); + normal_color = rgui->colors.normal_color; for (i = 0; i < list->size; i++) { @@ -518,8 +506,8 @@ static void rgui_render(void *data, bool is_idle) { if (rgui_framebuf_data) { - dark_color = BG_DARK_COLOR(settings); - light_color = BG_LIGHT_COLOR(settings); + dark_color = rgui->colors.bg_dark_color; + light_color = rgui->colors.bg_light_color; rgui_fill_rect(rgui, rgui_framebuf_data, fb_pitch, 0, fb_height, fb_width, 4, dark_color, light_color, rgui_bg_filler); @@ -606,8 +594,8 @@ static void rgui_render(void *data, bool is_idle) menu_animation_ticker(&ticker); - hover_color = HOVER_COLOR(settings); - normal_color = NORMAL_COLOR(settings); + hover_color = rgui->colors.hover_color; + normal_color = rgui->colors.normal_color; if (menu_entries_ctl(MENU_ENTRIES_CTL_SHOW_BACK, NULL)) { @@ -623,7 +611,7 @@ static void rgui_render(void *data, bool is_idle) RGUI_TERM_START_X(fb_width), RGUI_TERM_START_X(fb_width), back_msg, - TITLE_COLOR(settings)); + rgui->colors.title_color); } string_to_upper(title_buf); @@ -633,7 +621,7 @@ static void rgui_render(void *data, bool is_idle) (int)(RGUI_TERM_START_X(fb_width) + (RGUI_TERM_WIDTH(fb_width) - utf8len(title_buf)) * FONT_WIDTH_STRIDE / 2), RGUI_TERM_START_X(fb_width), - title_buf, TITLE_COLOR(settings)); + title_buf, rgui->colors.title_color); if (settings->bools.menu_core_enable && menu_entries_get_core_title(title_msg, sizeof(title_msg)) == 0) @@ -789,6 +777,9 @@ static void *rgui_init(void **userdata, bool video_is_threaded) *userdata = rgui; + /* Prepare RGUI colors, to improve performance */ + prepare_rgui_colors(rgui, settings); + /* 4 extra lines to cache the checked background */ rgui_framebuf_data = (uint16_t*) calloc(400 * (240 + 4), sizeof(uint16_t)); @@ -830,7 +821,6 @@ error: return NULL; } - static void rgui_free(void *data) { const uint8_t *font_fb; diff --git a/menu/drivers/stripes.c b/menu/drivers/stripes.c old mode 100755 new mode 100644 index be2abdd1e5..4717c5577e --- a/menu/drivers/stripes.c +++ b/menu/drivers/stripes.c @@ -1899,7 +1899,6 @@ static void stripes_context_reset_horizontal_list( continue; } - file_list_get_at_offset(stripes->horizontal_list, i, &path, NULL, NULL, NULL); @@ -2047,7 +2046,6 @@ static void stripes_list_open(stripes_handle_t *stripes) stripes_list_open_new(stripes, selection_buf, dir, selection); - entry.duration = STRIPES_DELAY; entry.target_value = stripes->icon_size * -(stripes->depth*2-2); entry.subject = &stripes->x; @@ -2510,7 +2508,6 @@ static int stripes_draw_item( TEXT_ALIGN_LEFT, width, height, stripes->font); - menu_display_set_alpha(color, MIN(node->alpha, stripes->alpha)); if (color[3] != 0) @@ -3076,7 +3073,6 @@ static void stripes_layout_ps3(stripes_handle_t *stripes, int width, int height) stripes->font2_size = 24.0 * scale_factor; new_header_height = 128.0 * scale_factor; - stripes->thumbnail_width = 1024.0 * scale_factor; stripes->left_thumbnail_width = 1024.0 * scale_factor; stripes->savestate_thumbnail_width= 460.0 * scale_factor; @@ -4030,7 +4026,6 @@ static void stripes_list_cache(void *data, enum menu_list_type type, unsigned ac } } - static void stripes_context_destroy(void *data) { unsigned i; diff --git a/menu/drivers/xmb.c b/menu/drivers/xmb.c index 654851b4ab..3f357979d8 100644 --- a/menu/drivers/xmb.c +++ b/menu/drivers/xmb.c @@ -201,6 +201,11 @@ enum XMB_TEXTURE_INPUT_RB, XMB_TEXTURE_INPUT_LT, XMB_TEXTURE_INPUT_RT, + XMB_TEXTURE_INPUT_ADC, + XMB_TEXTURE_INPUT_BIND_ALL, + XMB_TEXTURE_INPUT_MOUSE, + XMB_TEXTURE_INPUT_LGUN, + XMB_TEXTURE_INPUT_TURBO, XMB_TEXTURE_CHECKMARK, XMB_TEXTURE_MENU_ADD, XMB_TEXTURE_BRIGHTNESS, @@ -2270,6 +2275,9 @@ static uintptr_t xmb_icon_get_id(xmb_handle_t *xmb, case MENU_ENUM_LABEL_ADD_TO_FAVORITES: case MENU_ENUM_LABEL_ADD_TO_FAVORITES_PLAYLIST: return xmb->textures.list[XMB_TEXTURE_ADD_FAVORITE]; + case MENU_ENUM_LABEL_PARENT_DIRECTORY: + case MENU_ENUM_LABEL_UNDO_LOAD_STATE: + case MENU_ENUM_LABEL_UNDO_SAVE_STATE: case MENU_ENUM_LABEL_RESET_CORE_ASSOCIATION: return xmb->textures.list[XMB_TEXTURE_UNDO]; case MENU_ENUM_LABEL_CORE_INPUT_REMAPPING_OPTIONS: @@ -2284,34 +2292,50 @@ static uintptr_t xmb_icon_get_id(xmb_handle_t *xmb, case MENU_ENUM_LABEL_SHADER_OPTIONS: return xmb->textures.list[XMB_TEXTURE_SHADER_OPTIONS]; case MENU_ENUM_LABEL_ACHIEVEMENT_LIST: - return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENT_LIST]; case MENU_ENUM_LABEL_ACHIEVEMENT_LIST_HARDCORE: return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENT_LIST]; case MENU_ENUM_LABEL_SAVE_STATE: + case MENU_ENUM_LABEL_SAVESTATE_AUTO_SAVE: return xmb->textures.list[XMB_TEXTURE_SAVESTATE]; case MENU_ENUM_LABEL_LOAD_STATE: + case MENU_ENUM_LABEL_CONFIGURATIONS: + case MENU_ENUM_LABEL_GAME_SPECIFIC_OPTIONS: + case MENU_ENUM_LABEL_REMAP_FILE_LOAD: + case MENU_ENUM_LABEL_AUTO_OVERRIDES_ENABLE: + case MENU_ENUM_LABEL_AUTO_REMAPS_ENABLE: + case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET: + case MENU_ENUM_LABEL_CHEAT_FILE_LOAD: + case MENU_ENUM_LABEL_CHEAT_FILE_LOAD_APPEND: + case MENU_ENUM_LABEL_SAVESTATE_AUTO_LOAD: return xmb->textures.list[XMB_TEXTURE_LOADSTATE]; - case MENU_ENUM_LABEL_PARENT_DIRECTORY: - case MENU_ENUM_LABEL_UNDO_LOAD_STATE: - case MENU_ENUM_LABEL_UNDO_SAVE_STATE: - return xmb->textures.list[XMB_TEXTURE_UNDO]; case MENU_ENUM_LABEL_TAKE_SCREENSHOT: return xmb->textures.list[XMB_TEXTURE_SCREENSHOT]; case MENU_ENUM_LABEL_DELETE_ENTRY: return xmb->textures.list[XMB_TEXTURE_CLOSE]; case MENU_ENUM_LABEL_RESTART_CONTENT: + case MENU_ENUM_LABEL_REBOOT: + case MENU_ENUM_LABEL_RESET_TO_DEFAULT_CONFIG: + case MENU_ENUM_LABEL_CHEAT_RELOAD_CHEATS: + case MENU_ENUM_LABEL_RESTART_RETROARCH: + case MENU_ENUM_LABEL_VRR_RUNLOOP_ENABLE: + case MENU_ENUM_LABEL_AUTOSAVE_INTERVAL: return xmb->textures.list[XMB_TEXTURE_RELOAD]; case MENU_ENUM_LABEL_RENAME_ENTRY: return xmb->textures.list[XMB_TEXTURE_RENAME]; case MENU_ENUM_LABEL_RESUME_CONTENT: return xmb->textures.list[XMB_TEXTURE_RESUME]; - case MENU_ENUM_LABEL_FAVORITES: + case MENU_ENUM_LABEL_DIRECTORY_SETTINGS: + case MENU_ENUM_LABEL_SCAN_DIRECTORY: + case MENU_ENUM_LABEL_REMAP_FILE_SAVE_CONTENT_DIR: + case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_CONTENT_DIR: + case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT: + case MENU_ENUM_LABEL_FAVORITES: /* "Start Directory" */ case MENU_ENUM_LABEL_DOWNLOADED_FILE_DETECT_CORE_LIST: return xmb->textures.list[XMB_TEXTURE_FOLDER]; case MENU_ENUM_LABEL_FILE_DETECT_CORE_LIST_PUSH_DIR: return xmb->textures.list[XMB_TEXTURE_RDB]; - /* Menu collection submenus*/ + /* Menu collection submenus */ case MENU_ENUM_LABEL_CONTENT_COLLECTION_LIST: return xmb->textures.list[XMB_TEXTURE_ZIP]; case MENU_ENUM_LABEL_GOTO_FAVORITES: @@ -2323,210 +2347,183 @@ static uintptr_t xmb_icon_get_id(xmb_handle_t *xmb, case MENU_ENUM_LABEL_GOTO_MUSIC: return xmb->textures.list[XMB_TEXTURE_MUSIC]; - default: - /* Menu icons are here waiting for theme support*/ - { - settings_t *settings = config_get_ptr(); - if (settings->uints.menu_xmb_theme != XMB_ICON_THEME_FLATUI && - settings->uints.menu_xmb_theme != XMB_ICON_THEME_PIXEL ) - { - switch (enum_idx) - { - /* Menu icons */ - case MENU_ENUM_LABEL_CONTENT_SETTINGS: - case MENU_ENUM_LABEL_UPDATE_ASSETS: - case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_GAME: - case MENU_ENUM_LABEL_REMAP_FILE_SAVE_GAME: - case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME: - return xmb->textures.list[XMB_TEXTURE_QUICKMENU]; - case MENU_ENUM_LABEL_START_CORE: - case MENU_ENUM_LABEL_CHEAT_START_OR_CONT: - return xmb->textures.list[XMB_TEXTURE_RUN]; - case MENU_ENUM_LABEL_CORE_LIST: - case MENU_ENUM_LABEL_SIDELOAD_CORE_LIST: - case MENU_ENUM_LABEL_CORE_SETTINGS: - case MENU_ENUM_LABEL_CORE_UPDATER_LIST: - case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE: - case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_CORE: - case MENU_ENUM_LABEL_REMAP_FILE_SAVE_CORE: - return xmb->textures.list[XMB_TEXTURE_CORE]; - case MENU_ENUM_LABEL_LOAD_CONTENT_LIST: - case MENU_ENUM_LABEL_SCAN_FILE: - return xmb->textures.list[XMB_TEXTURE_FILE]; - case MENU_ENUM_LABEL_ONLINE_UPDATER: - case MENU_ENUM_LABEL_UPDATER_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_UPDATER]; - case MENU_ENUM_LABEL_UPDATE_LAKKA: - return xmb->textures.list[XMB_TEXTURE_MAIN_MENU]; - case MENU_ENUM_LABEL_UPDATE_CHEATS: - return xmb->textures.list[XMB_TEXTURE_CHEAT_OPTIONS]; - case MENU_ENUM_LABEL_THUMBNAILS_UPDATER_LIST: - return xmb->textures.list[XMB_TEXTURE_IMAGE]; - case MENU_ENUM_LABEL_UPDATE_OVERLAYS: - case MENU_ENUM_LABEL_ONSCREEN_OVERLAY_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_OVERLAY]; - case MENU_ENUM_LABEL_UPDATE_CG_SHADERS: - case MENU_ENUM_LABEL_UPDATE_GLSL_SHADERS: - case MENU_ENUM_LABEL_UPDATE_SLANG_SHADERS: - case MENU_ENUM_LABEL_AUTO_SHADERS_ENABLE: - case MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS: - return xmb->textures.list[XMB_TEXTURE_SHADER_OPTIONS]; - case MENU_ENUM_LABEL_INFORMATION: - case MENU_ENUM_LABEL_INFORMATION_LIST: - case MENU_ENUM_LABEL_SYSTEM_INFORMATION: - case MENU_ENUM_LABEL_UPDATE_CORE_INFO_FILES: - return xmb->textures.list[XMB_TEXTURE_INFO]; - case MENU_ENUM_LABEL_UPDATE_DATABASES: - case MENU_ENUM_LABEL_DATABASE_MANAGER_LIST: - return xmb->textures.list[XMB_TEXTURE_RDB]; - case MENU_ENUM_LABEL_CURSOR_MANAGER_LIST: - return xmb->textures.list[XMB_TEXTURE_CURSOR]; - case MENU_ENUM_LABEL_HELP_LIST: - case MENU_ENUM_LABEL_HELP_CONTROLS: - case MENU_ENUM_LABEL_HELP_LOADING_CONTENT: - case MENU_ENUM_LABEL_HELP_SCANNING_CONTENT: - case MENU_ENUM_LABEL_HELP_WHAT_IS_A_CORE: - case MENU_ENUM_LABEL_HELP_CHANGE_VIRTUAL_GAMEPAD: - case MENU_ENUM_LABEL_HELP_AUDIO_VIDEO_TROUBLESHOOTING: - return xmb->textures.list[XMB_TEXTURE_HELP]; - case MENU_ENUM_LABEL_QUIT_RETROARCH: - return xmb->textures.list[XMB_TEXTURE_EXIT]; - /* Settings icons*/ - case MENU_ENUM_LABEL_DRIVER_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_DRIVERS]; - case MENU_ENUM_LABEL_VIDEO_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_VIDEO]; - case MENU_ENUM_LABEL_AUDIO_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_AUDIO]; - case MENU_ENUM_LABEL_AUDIO_MIXER_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_MIXER]; - case MENU_ENUM_LABEL_INPUT_SETTINGS: - case MENU_ENUM_LABEL_UPDATE_AUTOCONFIG_PROFILES: - case MENU_ENUM_LABEL_INPUT_USER_1_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_2_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_3_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_4_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_5_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_6_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_7_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_8_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_9_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_10_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_11_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_12_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_13_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_14_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_15_BINDS: - case MENU_ENUM_LABEL_INPUT_USER_16_BINDS: - return xmb->textures.list[XMB_TEXTURE_INPUT_SETTINGS]; - case MENU_ENUM_LABEL_LATENCY_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_LATENCY]; - case MENU_ENUM_LABEL_SAVING_SETTINGS: - case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG: - case MENU_ENUM_LABEL_SAVE_NEW_CONFIG: - case MENU_ENUM_LABEL_CONFIG_SAVE_ON_EXIT: - case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS: - case MENU_ENUM_LABEL_CHEAT_FILE_SAVE_AS: - return xmb->textures.list[XMB_TEXTURE_SAVING]; - case MENU_ENUM_LABEL_LOGGING_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_LOG]; - case MENU_ENUM_LABEL_FRAME_THROTTLE_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_FRAMESKIP]; - case MENU_ENUM_LABEL_QUICK_MENU_START_RECORDING: - case MENU_ENUM_LABEL_RECORDING_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_RECORD]; - case MENU_ENUM_LABEL_QUICK_MENU_START_STREAMING: - return xmb->textures.list[XMB_TEXTURE_STREAM]; - case MENU_ENUM_LABEL_QUICK_MENU_STOP_STREAMING: - case MENU_ENUM_LABEL_QUICK_MENU_STOP_RECORDING: - case MENU_ENUM_LABEL_CHEAT_DELETE_ALL: - case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_CORE: - case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_GAME: - case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_CONTENT_DIR: - case MENU_ENUM_LABEL_CORE_DELETE: - return xmb->textures.list[XMB_TEXTURE_CLOSE]; - case MENU_ENUM_LABEL_ONSCREEN_DISPLAY_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_OSD]; - case MENU_ENUM_LABEL_SHOW_WIMP: - case MENU_ENUM_LABEL_USER_INTERFACE_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_UI]; + case MENU_ENUM_LABEL_CONTENT_SETTINGS: + case MENU_ENUM_LABEL_UPDATE_ASSETS: + case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_GAME: + case MENU_ENUM_LABEL_REMAP_FILE_SAVE_GAME: + case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME: + return xmb->textures.list[XMB_TEXTURE_QUICKMENU]; + case MENU_ENUM_LABEL_START_CORE: + case MENU_ENUM_LABEL_CHEAT_START_OR_CONT: + return xmb->textures.list[XMB_TEXTURE_RUN]; + case MENU_ENUM_LABEL_CORE_LIST: + case MENU_ENUM_LABEL_SIDELOAD_CORE_LIST: + case MENU_ENUM_LABEL_CORE_SETTINGS: + case MENU_ENUM_LABEL_CORE_UPDATER_LIST: + case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE: + case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_CORE: + case MENU_ENUM_LABEL_REMAP_FILE_SAVE_CORE: + return xmb->textures.list[XMB_TEXTURE_CORE]; + case MENU_ENUM_LABEL_LOAD_CONTENT_LIST: + case MENU_ENUM_LABEL_SCAN_FILE: + return xmb->textures.list[XMB_TEXTURE_FILE]; + case MENU_ENUM_LABEL_ONLINE_UPDATER: + case MENU_ENUM_LABEL_UPDATER_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_UPDATER]; + case MENU_ENUM_LABEL_UPDATE_LAKKA: + return xmb->textures.list[XMB_TEXTURE_MAIN_MENU]; + case MENU_ENUM_LABEL_UPDATE_CHEATS: + return xmb->textures.list[XMB_TEXTURE_CHEAT_OPTIONS]; + case MENU_ENUM_LABEL_THUMBNAILS_UPDATER_LIST: + return xmb->textures.list[XMB_TEXTURE_IMAGE]; + case MENU_ENUM_LABEL_UPDATE_OVERLAYS: + case MENU_ENUM_LABEL_ONSCREEN_OVERLAY_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_OVERLAY]; + case MENU_ENUM_LABEL_UPDATE_CG_SHADERS: + case MENU_ENUM_LABEL_UPDATE_GLSL_SHADERS: + case MENU_ENUM_LABEL_UPDATE_SLANG_SHADERS: + case MENU_ENUM_LABEL_AUTO_SHADERS_ENABLE: + case MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS: + return xmb->textures.list[XMB_TEXTURE_SHADER_OPTIONS]; + case MENU_ENUM_LABEL_INFORMATION: + case MENU_ENUM_LABEL_INFORMATION_LIST: + case MENU_ENUM_LABEL_SYSTEM_INFORMATION: + case MENU_ENUM_LABEL_UPDATE_CORE_INFO_FILES: + return xmb->textures.list[XMB_TEXTURE_INFO]; + case MENU_ENUM_LABEL_UPDATE_DATABASES: + case MENU_ENUM_LABEL_DATABASE_MANAGER_LIST: + return xmb->textures.list[XMB_TEXTURE_RDB]; + case MENU_ENUM_LABEL_CURSOR_MANAGER_LIST: + return xmb->textures.list[XMB_TEXTURE_CURSOR]; + case MENU_ENUM_LABEL_HELP_LIST: + case MENU_ENUM_LABEL_HELP_CONTROLS: + case MENU_ENUM_LABEL_HELP_LOADING_CONTENT: + case MENU_ENUM_LABEL_HELP_SCANNING_CONTENT: + case MENU_ENUM_LABEL_HELP_WHAT_IS_A_CORE: + case MENU_ENUM_LABEL_HELP_CHANGE_VIRTUAL_GAMEPAD: + case MENU_ENUM_LABEL_HELP_AUDIO_VIDEO_TROUBLESHOOTING: + return xmb->textures.list[XMB_TEXTURE_HELP]; + case MENU_ENUM_LABEL_QUIT_RETROARCH: + case MENU_ENUM_LABEL_BLOCK_SRAM_OVERWRITE: + return xmb->textures.list[XMB_TEXTURE_EXIT]; + case MENU_ENUM_LABEL_DRIVER_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_DRIVERS]; + case MENU_ENUM_LABEL_VIDEO_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_VIDEO]; + case MENU_ENUM_LABEL_AUDIO_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_AUDIO]; + case MENU_ENUM_LABEL_AUDIO_MIXER_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_MIXER]; + case MENU_ENUM_LABEL_INPUT_SETTINGS: + case MENU_ENUM_LABEL_UPDATE_AUTOCONFIG_PROFILES: + case MENU_ENUM_LABEL_INPUT_USER_1_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_2_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_3_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_4_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_5_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_6_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_7_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_8_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_9_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_10_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_11_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_12_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_13_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_14_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_15_BINDS: + case MENU_ENUM_LABEL_INPUT_USER_16_BINDS: + case MENU_ENUM_LABEL_START_NET_RETROPAD: + return xmb->textures.list[XMB_TEXTURE_INPUT_SETTINGS]; + case MENU_ENUM_LABEL_LATENCY_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_LATENCY]; + case MENU_ENUM_LABEL_SAVING_SETTINGS: + case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG: + case MENU_ENUM_LABEL_SAVE_NEW_CONFIG: + case MENU_ENUM_LABEL_CONFIG_SAVE_ON_EXIT: + case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS: + case MENU_ENUM_LABEL_CHEAT_FILE_SAVE_AS: + return xmb->textures.list[XMB_TEXTURE_SAVING]; + case MENU_ENUM_LABEL_LOGGING_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_LOG]; + case MENU_ENUM_LABEL_FASTFORWARD_RATIO: + case MENU_ENUM_LABEL_FRAME_THROTTLE_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_FRAMESKIP]; + case MENU_ENUM_LABEL_QUICK_MENU_START_RECORDING: + case MENU_ENUM_LABEL_RECORDING_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_RECORD]; + case MENU_ENUM_LABEL_QUICK_MENU_START_STREAMING: + return xmb->textures.list[XMB_TEXTURE_STREAM]; + case MENU_ENUM_LABEL_QUICK_MENU_STOP_STREAMING: + case MENU_ENUM_LABEL_QUICK_MENU_STOP_RECORDING: + case MENU_ENUM_LABEL_CHEAT_DELETE_ALL: + case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_CORE: + case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_GAME: + case MENU_ENUM_LABEL_REMAP_FILE_REMOVE_CONTENT_DIR: + case MENU_ENUM_LABEL_CORE_DELETE: + return xmb->textures.list[XMB_TEXTURE_CLOSE]; + case MENU_ENUM_LABEL_ONSCREEN_DISPLAY_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_OSD]; + case MENU_ENUM_LABEL_SHOW_WIMP: + case MENU_ENUM_LABEL_USER_INTERFACE_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_UI]; #ifdef HAVE_LAKKA_SWITCH - case MENU_ENUM_LABEL_SWITCH_GPU_PROFILE: + case MENU_ENUM_LABEL_SWITCH_GPU_PROFILE: #endif #if defined(HAVE_LAKKA_SWITCH) || defined(HAVE_LIBNX) - case MENU_ENUM_LABEL_SWITCH_CPU_PROFILE: - return xmb->textures.list[XMB_TEXTURE_POWER]; + case MENU_ENUM_LABEL_SWITCH_CPU_PROFILE: + return xmb->textures.list[XMB_TEXTURE_POWER]; #endif - case MENU_ENUM_LABEL_POWER_MANAGEMENT_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_POWER]; - case MENU_ENUM_LABEL_RETRO_ACHIEVEMENTS_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENTS]; - case MENU_ENUM_LABEL_NETWORK_INFORMATION: - case MENU_ENUM_LABEL_NETWORK_SETTINGS: - case MENU_ENUM_LABEL_WIFI_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_NETWORK]; - case MENU_ENUM_LABEL_PLAYLIST_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_PLAYLIST]; - case MENU_ENUM_LABEL_USER_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_USER]; - case MENU_ENUM_LABEL_DIRECTORY_SETTINGS: - case MENU_ENUM_LABEL_SCAN_DIRECTORY: - case MENU_ENUM_LABEL_REMAP_FILE_SAVE_CONTENT_DIR: - case MENU_ENUM_LABEL_SAVE_CURRENT_CONFIG_OVERRIDE_CONTENT_DIR: - case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT: - return xmb->textures.list[XMB_TEXTURE_FOLDER]; - case MENU_ENUM_LABEL_PRIVACY_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_PRIVACY]; - case MENU_ENUM_LABEL_REWIND_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_REWIND]; - case MENU_ENUM_LABEL_QUICK_MENU_OVERRIDE_OPTIONS: - return xmb->textures.list[XMB_TEXTURE_OVERRIDE]; - case MENU_ENUM_LABEL_ONSCREEN_NOTIFICATIONS_SETTINGS: - return xmb->textures.list[XMB_TEXTURE_NOTIFICATIONS]; + case MENU_ENUM_LABEL_POWER_MANAGEMENT_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_POWER]; + case MENU_ENUM_LABEL_RETRO_ACHIEVEMENTS_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_ACHIEVEMENTS]; + case MENU_ENUM_LABEL_PLAYLIST_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_PLAYLIST]; + case MENU_ENUM_LABEL_USER_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_USER]; + case MENU_ENUM_LABEL_PRIVACY_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_PRIVACY]; + case MENU_ENUM_LABEL_REWIND_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_REWIND]; + case MENU_ENUM_LABEL_QUICK_MENU_OVERRIDE_OPTIONS: + return xmb->textures.list[XMB_TEXTURE_OVERRIDE]; + case MENU_ENUM_LABEL_ONSCREEN_NOTIFICATIONS_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_NOTIFICATIONS]; #ifdef HAVE_NETWORKING - case MENU_ENUM_LABEL_NETPLAY_ENABLE_HOST: - return xmb->textures.list[XMB_TEXTURE_RUN]; - case MENU_ENUM_LABEL_NETPLAY_DISCONNECT: - return xmb->textures.list[XMB_TEXTURE_CLOSE]; - case MENU_ENUM_LABEL_NETPLAY_ENABLE_CLIENT: - return xmb->textures.list[XMB_TEXTURE_ROOM]; - case MENU_ENUM_LABEL_NETPLAY_REFRESH_ROOMS: - return xmb->textures.list[XMB_TEXTURE_RELOAD]; + case MENU_ENUM_LABEL_NETPLAY_ENABLE_HOST: + return xmb->textures.list[XMB_TEXTURE_RUN]; + case MENU_ENUM_LABEL_NETPLAY_DISCONNECT: + return xmb->textures.list[XMB_TEXTURE_CLOSE]; + case MENU_ENUM_LABEL_NETPLAY_ENABLE_CLIENT: + return xmb->textures.list[XMB_TEXTURE_ROOM]; + case MENU_ENUM_LABEL_NETPLAY_REFRESH_ROOMS: + return xmb->textures.list[XMB_TEXTURE_RELOAD]; + case MENU_ENUM_LABEL_NETWORK_INFORMATION: + case MENU_ENUM_LABEL_NETWORK_SETTINGS: + case MENU_ENUM_LABEL_WIFI_SETTINGS: + return xmb->textures.list[XMB_TEXTURE_NETWORK]; #endif - case MENU_ENUM_LABEL_REBOOT: - case MENU_ENUM_LABEL_RESET_TO_DEFAULT_CONFIG: - case MENU_ENUM_LABEL_CHEAT_RELOAD_CHEATS: - case MENU_ENUM_LABEL_RESTART_RETROARCH: - return xmb->textures.list[XMB_TEXTURE_RELOAD]; - case MENU_ENUM_LABEL_SHUTDOWN: - return xmb->textures.list[XMB_TEXTURE_SHUTDOWN]; - case MENU_ENUM_LABEL_CONFIGURATIONS: - case MENU_ENUM_LABEL_GAME_SPECIFIC_OPTIONS: - case MENU_ENUM_LABEL_REMAP_FILE_LOAD: - case MENU_ENUM_LABEL_AUTO_OVERRIDES_ENABLE: - case MENU_ENUM_LABEL_AUTO_REMAPS_ENABLE: - case MENU_ENUM_LABEL_VIDEO_SHADER_PRESET: - case MENU_ENUM_LABEL_CHEAT_FILE_LOAD: - case MENU_ENUM_LABEL_CHEAT_FILE_LOAD_APPEND: - return xmb->textures.list[XMB_TEXTURE_LOADSTATE]; - case MENU_ENUM_LABEL_CHEAT_APPLY_CHANGES: - case MENU_ENUM_LABEL_SHADER_APPLY_CHANGES: - return xmb->textures.list[XMB_TEXTURE_CHECKMARK]; - case MENU_ENUM_LABEL_CHEAT_ADD_NEW_AFTER: - case MENU_ENUM_LABEL_CHEAT_ADD_NEW_BEFORE: - case MENU_ENUM_LABEL_CHEAT_ADD_NEW_TOP: - case MENU_ENUM_LABEL_CHEAT_ADD_NEW_BOTTOM: - return xmb->textures.list[XMB_TEXTURE_MENU_ADD]; - case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_TOGGLE: - return xmb->textures.list[XMB_TEXTURE_MENU_APPLY_TOGGLE]; - case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_LOAD: - return xmb->textures.list[XMB_TEXTURE_MENU_APPLY_COG]; - default: - break; - } - } - break; - } + case MENU_ENUM_LABEL_SHUTDOWN: + return xmb->textures.list[XMB_TEXTURE_SHUTDOWN]; + case MENU_ENUM_LABEL_CHEAT_APPLY_CHANGES: + case MENU_ENUM_LABEL_SHADER_APPLY_CHANGES: + return xmb->textures.list[XMB_TEXTURE_CHECKMARK]; + case MENU_ENUM_LABEL_CHEAT_ADD_NEW_AFTER: + case MENU_ENUM_LABEL_CHEAT_ADD_NEW_BEFORE: + case MENU_ENUM_LABEL_CHEAT_ADD_NEW_TOP: + case MENU_ENUM_LABEL_CHEAT_ADD_NEW_BOTTOM: + return xmb->textures.list[XMB_TEXTURE_MENU_ADD]; + case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_TOGGLE: + return xmb->textures.list[XMB_TEXTURE_MENU_APPLY_TOGGLE]; + case MENU_ENUM_LABEL_CHEAT_APPLY_AFTER_LOAD: + case MENU_ENUM_LABEL_SAVESTATE_AUTO_INDEX: + return xmb->textures.list[XMB_TEXTURE_MENU_APPLY_COG]; + case MENU_ENUM_LABEL_SLOWMOTION_RATIO: + return xmb->textures.list[XMB_TEXTURE_RESUME]; + case MENU_ENUM_LABEL_START_VIDEO_PROCESSOR: + return xmb->textures.list[XMB_TEXTURE_MOVIE]; + default: + break; } switch(type) @@ -2650,24 +2647,38 @@ static uintptr_t xmb_icon_get_id(xmb_handle_t *xmb, { unsigned input_id; if (type < MENU_SETTINGS_INPUT_DESC_BEGIN) + /* Input User # Binds only */ { input_id = MENU_SETTINGS_INPUT_BEGIN; + if ( type == input_id + 1) + return xmb->textures.list[XMB_TEXTURE_INPUT_ADC]; if ( type == input_id + 2) return xmb->textures.list[XMB_TEXTURE_INPUT_SETTINGS]; + if ( type == input_id + 3) + return xmb->textures.list[XMB_TEXTURE_INPUT_BIND_ALL]; if ( type == input_id + 4) return xmb->textures.list[XMB_TEXTURE_RELOAD]; if ( type == input_id + 5) return xmb->textures.list[XMB_TEXTURE_SAVING]; + if ( type == input_id + 6) + return xmb->textures.list[XMB_TEXTURE_INPUT_MOUSE]; + if ((type > (input_id + 30)) && (type < (input_id + 42))) + return xmb->textures.list[XMB_TEXTURE_INPUT_LGUN]; + if ( type == input_id + 42) + return xmb->textures.list[XMB_TEXTURE_INPUT_TURBO]; + /* align to use the same code of Quickmenu controls */ input_id = input_id + 7; } else { + /* Quickmenu controls repeats the same icons for all users */ input_id = MENU_SETTINGS_INPUT_DESC_BEGIN; while (type > (input_id + 23)) { input_id = (input_id + 24) ; } } + /* This is utilized for both Input # Binds and Quickmenu controls */ if ( type == input_id ) return xmb->textures.list[XMB_TEXTURE_INPUT_BTN_D]; if ( type == (input_id + 1)) @@ -4842,6 +4853,16 @@ static const char *xmb_texture_path(unsigned id) return "input_SELECT.png"; case XMB_TEXTURE_INPUT_START: return "input_START.png"; + case XMB_TEXTURE_INPUT_ADC: + return "input_ADC.png"; + case XMB_TEXTURE_INPUT_BIND_ALL: + return "input_BIND_ALL.png"; + case XMB_TEXTURE_INPUT_MOUSE: + return "input_MOUSE.png"; + case XMB_TEXTURE_INPUT_LGUN: + return "input_LGUN.png"; + case XMB_TEXTURE_INPUT_TURBO: + return "input_TURBO.png"; case XMB_TEXTURE_CHECKMARK: return "menu_check.png"; case XMB_TEXTURE_MENU_ADD: diff --git a/menu/drivers/zarch.c b/menu/drivers/zarch.c index 495f1eab7d..52b4665eb6 100644 --- a/menu/drivers/zarch.c +++ b/menu/drivers/zarch.c @@ -163,7 +163,6 @@ struct zui_tabbed bool inited; }; - static enum zarch_layout_type zarch_layout = LAY_HOME; static float zarch_zui_strwidth(void *fb_buf, const char *text, float scale) @@ -415,7 +414,6 @@ static bool zarch_zui_tab(zui_t *zui, struct zui_tabbed *tab, return active || (tab->active_id == id); } - static void zarch_zui_render_lay_settings(zui_t *zui) { int width, x1, y1; @@ -945,7 +943,6 @@ static void zarch_frame(void *data, video_frame_info_t *video_info) zarch_zui_input_state(zui, MENU_ZARCH_MOUSE_X), zarch_zui_input_state(zui, MENU_ZARCH_MOUSE_Y)); - if (!zarch_zui_input_state(zui, MENU_ZARCH_PRESSED)) zui->item.active = 0; else if (zui->item.active == 0) diff --git a/menu/drivers_display/menu_display_ctr.c b/menu/drivers_display/menu_display_ctr.c index 4ce9adc381..3713f966d2 100644 --- a/menu/drivers_display/menu_display_ctr.c +++ b/menu/drivers_display/menu_display_ctr.c @@ -59,7 +59,6 @@ static void menu_display_ctr_viewport(menu_display_ctx_draw_t *draw, } - static void menu_display_ctr_draw(menu_display_ctx_draw_t *draw, video_frame_info_t *video_info) { @@ -133,7 +132,6 @@ static void menu_display_ctr_draw(menu_display_ctx_draw_t *draw, GPU_TEXTURE_WRAP_S(GPU_CLAMP_TO_EDGE) | GPU_TEXTURE_WRAP_T(GPU_CLAMP_TO_EDGE), GPU_RGBA8); - GPU_SetViewport(NULL, VIRT_TO_PHYS(ctr->drawbuffers.top.left), 0, 0, CTR_TOP_FRAMEBUFFER_HEIGHT, diff --git a/menu/drivers_display/menu_display_vita2d.c b/menu/drivers_display/menu_display_vita2d.c index d97b3f2437..b1d439cdb6 100644 --- a/menu/drivers_display/menu_display_vita2d.c +++ b/menu/drivers_display/menu_display_vita2d.c @@ -102,7 +102,6 @@ static void menu_display_vita2d_viewport(menu_display_ctx_draw_t *draw, #endif } - static void menu_display_vita2d_draw(menu_display_ctx_draw_t *draw, video_frame_info_t *video_info) { diff --git a/menu/drivers_display/menu_display_vulkan.c b/menu/drivers_display/menu_display_vulkan.c index e1e5ee4699..6bae63a2d6 100644 --- a/menu/drivers_display/menu_display_vulkan.c +++ b/menu/drivers_display/menu_display_vulkan.c @@ -1,4 +1,4 @@ -/* RetroArch - A frontend for libretro. +/* RetroArch - A frontend for libretro. * Copyright (C) 2016-2017 - Hans-Kristian Arntzen * Copyright (C) 2011-2017 - Daniel De Matteis * @@ -349,7 +349,6 @@ static bool menu_display_vk_font_init_first( static void menu_display_vk_scissor_begin(video_frame_info_t *video_info, int x, int y, unsigned width, unsigned height) { - VkRect2D sci; vk_t *vk = video_info ? (vk_t*)video_info->userdata : NULL; vk->tracker.use_scissor = true; @@ -362,7 +361,6 @@ static void menu_display_vk_scissor_begin(video_frame_info_t *video_info, static void menu_display_vk_scissor_end(video_frame_info_t *video_info) { - VkRect2D sci; vk_t *vk = video_info ? (vk_t*)video_info->userdata : NULL; vk->tracker.use_scissor = false; vk->tracker.dirty |= VULKAN_DIRTY_DYNAMIC_BIT; diff --git a/menu/drivers_display/menu_display_wiiu.c b/menu/drivers_display/menu_display_wiiu.c index 42f0c300cf..fdf50010e1 100644 --- a/menu/drivers_display/menu_display_wiiu.c +++ b/menu/drivers_display/menu_display_wiiu.c @@ -60,7 +60,6 @@ static void menu_display_wiiu_viewport(menu_display_ctx_draw_t *draw, } - static void menu_display_wiiu_draw(menu_display_ctx_draw_t *draw, video_frame_info_t *video_info) { @@ -115,17 +114,14 @@ static void menu_display_wiiu_draw(menu_display_ctx_draw_t *draw, break; } - } else if(draw->coords->vertex || draw->coords->color[0] != draw->coords->color[12]) { if (wiiu->vertex_cache_tex.current + 4 > wiiu->vertex_cache_tex.size) return; - tex_shader_vertex_t* v = wiiu->vertex_cache_tex.v + wiiu->vertex_cache_tex.current; - GX2SetShaderMode(GX2_SHADER_MODE_UNIFORM_BLOCK); GX2SetShader(&tex_shader); GX2SetVertexUniformBlock(tex_shader.vs.uniformBlocks[0].offset, @@ -188,7 +184,6 @@ static void menu_display_wiiu_draw(menu_display_ctx_draw_t *draw, v[i].color.a = draw->coords->color[(i << 2) + 3]; } - if(draw->texture) GX2SetPixelTexture((GX2Texture*)draw->texture, tex_shader.ps.samplerVars[0].location); @@ -221,9 +216,6 @@ static void menu_display_wiiu_draw(menu_display_ctx_draw_t *draw, return; } - - - GX2SetShaderMode(GX2_SHADER_MODE_GEOMETRY_SHADER); GX2SetShader(&sprite_shader); // GX2SetGeometryShaderInputRingBuffer(wiiu->input_ring_buffer, wiiu->input_ring_buffer_size); diff --git a/menu/menu_cbs.h b/menu/menu_cbs.h index 717ca7a302..6fccf1a8d4 100644 --- a/menu/menu_cbs.h +++ b/menu/menu_cbs.h @@ -286,6 +286,9 @@ void menu_cbs_init(void *data, int menu_cbs_exit(void); +void cb_generic_download(void *task_data, + void *user_data, const char *err); + RETRO_END_DECLS #endif diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index cdf3fda1ce..a891d68701 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -201,7 +201,6 @@ static int menu_displaylist_parse_core_info(menu_displaylist_info_t *info) MENU_ENUM_LABEL_CORE_INFO_ENTRY, MENU_SETTINGS_CORE_INFO_NONE, 0, 0); } - if (core_info->display_name) { fill_pathname_join_concat_noext(tmp, @@ -359,12 +358,15 @@ static int menu_displaylist_parse_core_info(menu_displaylist_info_t *info) } } +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#else if (settings->bools.menu_show_core_updater) menu_entries_append_enum(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_CORE_DELETE), msg_hash_to_str(MENU_ENUM_LABEL_CORE_DELETE), MENU_ENUM_LABEL_CORE_DELETE, MENU_SETTING_ACTION_CORE_DELETE, 0, 0); +#endif return 0; } @@ -385,6 +387,7 @@ static int menu_displaylist_parse_system_info(menu_displaylist_info_t *info) #endif const char *tmp_string = NULL; const frontend_ctx_driver_t *frontend = frontend_get_ptr(); + settings_t *settings = config_get_ptr(); tmp[0] = feat_str[0] = '\0'; @@ -502,40 +505,39 @@ static int menu_displaylist_parse_system_info(menu_displaylist_info_t *info) MENU_ENUM_LABEL_CPU_CORES, MENU_SETTINGS_CORE_INFO_NONE, 0, 0); } - for(controller = 0; controller < MAX_USERS; controller++) { - if (input_is_autoconfigured(controller)) - { + if (input_is_autoconfigured(controller)) + { snprintf(tmp, sizeof(tmp), "Port #%d device name: %s (#%d)", - controller, - input_config_get_device_name(controller), - input_autoconfigure_get_device_name_index(controller)); + controller, + input_config_get_device_name(controller), + input_autoconfigure_get_device_name_index(controller)); menu_entries_append_enum(info->list, tmp, "", - MENU_ENUM_LABEL_SYSTEM_INFO_ENTRY, - MENU_SETTINGS_CORE_INFO_NONE, 0, 0); - snprintf(tmp, sizeof(tmp), "Port #%d device display name: %s", - controller, - input_config_get_device_display_name(controller) ? - input_config_get_device_display_name(controller) : "N/A"); - menu_entries_append_enum(info->list, tmp, "", - MENU_ENUM_LABEL_SYSTEM_INFO_ENTRY, - MENU_SETTINGS_CORE_INFO_NONE, 0, 0); - snprintf(tmp, sizeof(tmp), "Port #%d device config name: %s", - controller, - input_config_get_device_display_name(controller) ? - input_config_get_device_config_name(controller) : "N/A"); - menu_entries_append_enum(info->list, tmp, "", - MENU_ENUM_LABEL_SYSTEM_INFO_ENTRY, - MENU_SETTINGS_CORE_INFO_NONE, 0, 0); - snprintf(tmp, sizeof(tmp), "Port #%d device VID/PID: %d/%d", - controller, - input_config_get_vid(controller), - input_config_get_pid(controller)); - menu_entries_append_enum(info->list, tmp, "", - MENU_ENUM_LABEL_SYSTEM_INFO_ENTRY, - MENU_SETTINGS_CORE_INFO_NONE, 0, 0); - } + MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY, + MENU_SETTINGS_CORE_INFO_NONE, 0, 0); + if (string_is_equal(settings->arrays.menu_driver, "rgui")) + { + snprintf(tmp, sizeof(tmp), " Device display name: %s", + input_config_get_device_display_name(controller) ? + input_config_get_device_display_name(controller) : "N/A"); + menu_entries_append_enum(info->list, tmp, "", + MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY, + MENU_SETTINGS_CORE_INFO_NONE, 0, 0); + snprintf(tmp, sizeof(tmp), " Device config name: %s", + input_config_get_device_display_name(controller) ? + input_config_get_device_config_name(controller) : "N/A"); + menu_entries_append_enum(info->list, tmp, "", + MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY, + MENU_SETTINGS_CORE_INFO_NONE, 0, 0); + snprintf(tmp, sizeof(tmp), " Device VID/PID: %d/%d", + input_config_get_vid(controller), + input_config_get_pid(controller)); + menu_entries_append_enum(info->list, tmp, "", + MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY, + MENU_SETTINGS_CORE_INFO_NONE, 0, 0); + } + } } if (frontend) @@ -1768,7 +1770,6 @@ static int menu_displaylist_parse_database_entry(menu_handle_t *menu, goto error; } - if (db_info_entry->developer) { for (k = 0; k < db_info_entry->developer->size; k++) @@ -2059,7 +2060,6 @@ static int menu_database_parse_query(file_list_t *list, const char *path, } #endif - static unsigned deferred_push_video_shader_parameters_common( menu_displaylist_info_t *info, struct video_shader *shader, unsigned base_parameter) @@ -2445,7 +2445,6 @@ static int menu_displaylist_parse_settings_internal_enum(void *data, goto loop; #endif - menu_entries_append_enum(info->list, short_description, name, enum_idx, menu_setting_set_flags(setting), 0, 0); count++; @@ -2514,7 +2513,6 @@ static void menu_displaylist_set_new_playlist( sizeof(menu->db_playlist_file)); } - static int menu_displaylist_parse_horizontal_list( menu_handle_t *menu, menu_displaylist_info_t *info) @@ -2616,7 +2614,6 @@ static int menu_displaylist_parse_load_content_settings( MENU_SETTING_ACTION_SCREENSHOT, 0, 0); } - if (settings->bools.quick_menu_show_save_load_state #ifdef HAVE_CHEEVOS && !cheevos_hardcore_active @@ -2659,7 +2656,6 @@ static int menu_displaylist_parse_load_content_settings( MENU_SETTING_ACTION_LOADSTATE, 0, 0); } - if (settings->bools.quick_menu_show_add_to_favorites) { menu_entries_append_enum(info->list, @@ -2672,7 +2668,7 @@ static int menu_displaylist_parse_load_content_settings( { if (!recording_is_enabled()) { - if (settings->bools.quick_menu_show_start_recording) + if (settings->bools.quick_menu_show_start_recording && !settings->bools.kiosk_mode_enable) { menu_entries_append_enum(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QUICK_MENU_START_RECORDING), @@ -2680,7 +2676,7 @@ static int menu_displaylist_parse_load_content_settings( MENU_ENUM_LABEL_QUICK_MENU_START_RECORDING, MENU_SETTING_ACTION, 0, 0); } - if (settings->bools.quick_menu_show_start_streaming) + if (settings->bools.quick_menu_show_start_streaming && !settings->bools.kiosk_mode_enable) { menu_entries_append_enum(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QUICK_MENU_START_STREAMING), @@ -2796,7 +2792,6 @@ static int menu_displaylist_parse_load_content_settings( MENU_SETTING_ACTION, 0, 0); } - #ifdef HAVE_CHEEVOS if(settings->bools.cheevos_enable) { @@ -2893,7 +2888,7 @@ static int menu_displaylist_parse_horizontal_content_actions( MENU_ENUM_LABEL_ADD_TO_FAVORITES_PLAYLIST, FILE_TYPE_PLAYLIST_ENTRY, 0, 0); } - if (settings->bools.quick_menu_show_reset_core_association) + if (settings->bools.quick_menu_show_reset_core_association && !settings->bools.kiosk_mode_enable) { menu_entries_append_enum(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_RESET_CORE_ASSOCIATION), @@ -3102,6 +3097,8 @@ static unsigned menu_displaylist_parse_options( MENU_SETTING_ACTION, 0, 0); count++; #elif defined(HAVE_NETWORKING) +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#else if (settings->bools.menu_show_core_updater) { menu_entries_append_enum(info->list, @@ -3111,6 +3108,7 @@ static unsigned menu_displaylist_parse_options( MENU_SETTING_ACTION, 0, 0); count++; } +#endif menu_entries_append_enum(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_THUMBNAILS_UPDATER_LIST), @@ -3605,6 +3603,7 @@ static unsigned menu_displaylist_parse_cores( unsigned items_found = 0; settings_t *settings = config_get_ptr(); const char *path = info->path; + bool ok; if (string_is_empty(path)) { @@ -3615,9 +3614,29 @@ static unsigned menu_displaylist_parse_cores( return items_found; } - str_list = dir_list_new(path, info->exts, + str_list = string_list_new(); + ok = dir_list_append(str_list, path, info->exts, true, settings->bools.show_hidden_files, true, false); +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP + /* UWP: browse the optional packages for additional cores */ + struct string_list *core_packages = string_list_new(); + uwp_fill_installed_core_packages(core_packages); + for (i = 0; i < core_packages->size; i++) + { + dir_list_append(str_list, core_packages->elems[i].data, info->exts, + true, settings->bools.show_hidden_files, true, false); + } + string_list_free(core_packages); +#else + /* Keep the old 'directory not found' behavior */ + if (!ok) + { + string_list_free(str_list); + str_list = NULL; + } +#endif + { char *out_dir = (char*)malloc(PATH_MAX_LENGTH * sizeof(char)); @@ -4151,6 +4170,8 @@ bool menu_displaylist_process(menu_displaylist_info_t *info) file_list_sort_on_alt(info->list); #if defined(HAVE_NETWORKING) +#if defined(__WINRT__) || defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_FAMILY_PHONE_APP +#else if (settings->bools.menu_show_core_updater && !settings->bools.kiosk_mode_enable) { if (info->download_core) @@ -4168,6 +4189,7 @@ bool menu_displaylist_process(menu_displaylist_info_t *info) MENU_SETTING_ACTION, 0, 0); } } +#endif #endif if (info->push_builtin_cores) @@ -4296,6 +4318,7 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist menu_handle_t *menu = NULL; bool load_content = true; bool use_filebrowser = false; + static bool core_selected = false; unsigned count = 0; int ret = 0; @@ -4725,7 +4748,6 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist path_playlist[0] = '\0'; - fill_pathname_join( path_playlist, settings->paths.directory_playlist, @@ -5032,6 +5054,7 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist info->need_sort = true; info->need_refresh = true; info->need_push = true; + core_selected = true; { unsigned cores_names_len = 0; @@ -5426,7 +5449,6 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist if ( setting ) setting->max = cheat_manager_state.total_memory_size>0?cheat_manager_state.total_memory_size-1:0 ; - menu_displaylist_parse_settings_enum(menu, info, MENU_ENUM_LABEL_CHEAT_IDX, PARSE_ONLY_UINT, false); @@ -5539,7 +5561,6 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist menu_entries_ctl(MENU_ENTRIES_CTL_CLEAR, info->list); - menu_displaylist_parse_settings_enum(menu, info, MENU_ENUM_LABEL_CHEAT_START_OR_RESTART, PARSE_ONLY_UINT, false); @@ -5618,8 +5639,6 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist MENU_ENUM_LABEL_CHEAT_BROWSE_MEMORY, PARSE_ONLY_UINT, false); - - setting = menu_setting_find_enum(MENU_ENUM_LABEL_CHEAT_DELETE_MATCH); if (setting) setting->max = cheat_manager_state.num_matches-1; @@ -7082,6 +7101,13 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist ret = menu_displaylist_parse_horizontal_content_actions(menu, info); info->need_refresh = true; info->need_push = true; + + if (core_selected) + { + info->need_clear = true; + core_selected = false; + } + break; case DISPLAYLIST_CONTENT_SETTINGS: menu_entries_ctl(MENU_ENTRIES_CTL_CLEAR, info->list); @@ -7844,7 +7870,6 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist filebrowser_clear_type(); info->type_default = FILE_TYPE_SHADER; - if (video_shader_is_supported(RARCH_SHADER_CG) && video_shader_get_type_from_ext("cg", &is_preset) != RARCH_SHADER_NONE) @@ -8101,19 +8126,26 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type, menu_displaylist if (tmp_str_list && tmp_str_list->size > 0) { core_option_manager_t *coreopts = NULL; + const char *val = NULL; rarch_ctl(RARCH_CTL_CORE_OPTIONS_LIST_GET, &coreopts); if (coreopts) { + settings_t *settings = config_get_ptr(); unsigned size = (unsigned)tmp_str_list->size; unsigned i = atoi(tmp_str_list->elems[size-1].data); struct core_option *option = NULL; bool checked_found = false; unsigned checked = 0; - const char *val = core_option_manager_get_val(coreopts, i-1); - i--; + if (settings->bools.game_specific_options) + { + val = core_option_manager_get_val(coreopts, i-1); + i--; + } + else + val = core_option_manager_get_val(coreopts, i); option = (struct core_option*)&coreopts->opts[i]; diff --git a/menu/menu_driver.c b/menu/menu_driver.c index 5e193fca93..f602763bfc 100644 --- a/menu/menu_driver.c +++ b/menu/menu_driver.c @@ -85,26 +85,26 @@ float osk_dark[16] = { /* Menu drivers */ static const menu_ctx_driver_t *menu_ctx_drivers[] = { -#if defined(HAVE_OZONE) - &menu_ctx_ozone, -#endif -#if defined(HAVE_XUI) - &menu_ctx_xui, -#endif #if defined(HAVE_MATERIALUI) &menu_ctx_mui, #endif #if defined(HAVE_NUKLEAR) &menu_ctx_nuklear, #endif -#if defined(HAVE_XMB) - &menu_ctx_xmb, +#if defined(HAVE_OZONE) + &menu_ctx_ozone, +#endif +#if defined(HAVE_RGUI) + &menu_ctx_rgui, #endif #if defined(HAVE_STRIPES) &menu_ctx_stripes, #endif -#if defined(HAVE_RGUI) - &menu_ctx_rgui, +#if defined(HAVE_XMB) + &menu_ctx_xmb, +#endif +#if defined(HAVE_XUI) + &menu_ctx_xui, #endif #if defined(HAVE_ZARCH) &menu_ctx_zarch, @@ -148,7 +148,7 @@ static menu_display_ctx_driver_t *menu_display_ctx_drivers[] = { #ifdef WIIU &menu_display_ctx_wiiu, #endif -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) &menu_display_ctx_gdi, #endif #ifdef DJGPP @@ -1743,9 +1743,10 @@ static bool menu_init(menu_handle_t *menu_data) configuration_set_bool(settings, settings->bools.menu_show_start_screen, false); - +#if !defined(PS2) /* TODO: PS2 IMPROVEMENT */ if (settings->bools.config_save_on_exit) command_event(CMD_EVENT_MENU_SAVE_CURRENT_CONFIG, NULL); +#endif } if ( settings->bools.bundle_assets_extract_enable @@ -2071,8 +2072,9 @@ static bool menu_driver_init_internal(bool video_is_threaded) if (menu_driver_data) return true; - menu_driver_data = (menu_handle_t*) - menu_driver_ctx->init(&menu_userdata, video_is_threaded); + if (menu_driver_ctx->init) + menu_driver_data = (menu_handle_t*) + menu_driver_ctx->init(&menu_userdata, video_is_threaded); if (!menu_driver_data || !menu_init(menu_driver_data)) goto error; @@ -2665,7 +2667,7 @@ void hex32_to_rgba_normalized(uint32_t hex, float* rgba, float alpha) void menu_subsystem_populate(const struct retro_subsystem_info* subsystem, menu_displaylist_info_t *info) { - int i = 0; + unsigned i = 0; if (subsystem && subsystem_current_count > 0) { for (i = 0; i < subsystem_current_count; i++, subsystem++) diff --git a/menu/menu_driver.h b/menu/menu_driver.h index dcded3f3b3..77ec064907 100644 --- a/menu/menu_driver.h +++ b/menu/menu_driver.h @@ -230,7 +230,7 @@ enum menu_settings_type MENU_SETTINGS_CHEAT_BEGIN, MENU_SETTINGS_CHEAT_END = MENU_SETTINGS_CHEAT_BEGIN + (MAX_CHEAT_COUNTERS - 1), MENU_SETTINGS_INPUT_BEGIN, - MENU_SETTINGS_INPUT_END = MENU_SETTINGS_INPUT_BEGIN + RARCH_CUSTOM_BIND_LIST_END, + MENU_SETTINGS_INPUT_END = MENU_SETTINGS_INPUT_BEGIN + RARCH_CUSTOM_BIND_LIST_END + 6, MENU_SETTINGS_INPUT_DESC_BEGIN, MENU_SETTINGS_INPUT_DESC_END = MENU_SETTINGS_INPUT_DESC_BEGIN + ((RARCH_FIRST_CUSTOM_BIND + 8) * MAX_USERS), MENU_SETTINGS_INPUT_DESC_KBD_BEGIN, @@ -246,7 +246,7 @@ enum menu_settings_type MENU_SET_SWITCH_GPU_PROFILE, MENU_SET_SWITCH_BRIGHTNESS, #endif -#if defined(HAVE_LAKKA_SWITCH) || defined(HAVE_LIBNX) +#if defined(HAVE_LAKKA_SWITCH) || defined(HAVE_LIBNX) MENU_SET_SWITCH_CPU_PROFILE, #endif @@ -399,7 +399,6 @@ typedef struct menu_display_ctx_driver void (*scissor_end)(video_frame_info_t *video_info); } menu_display_ctx_driver_t; - typedef struct { unsigned rpl_entry_selection_ptr; diff --git a/menu/menu_entries.c b/menu/menu_entries.c index d9f4bae160..161ada057d 100644 --- a/menu/menu_entries.c +++ b/menu/menu_entries.c @@ -235,7 +235,6 @@ static void menu_list_flush_stack(menu_list_t *list, } } - void menu_entries_get_at_offset(const file_list_t *list, size_t idx, const char **path, const char **label, unsigned *file_type, size_t *entry_idx, const char **alt) @@ -338,7 +337,6 @@ static void menu_entries_build_scroll_indices(file_list_t *list) current_is_dir = is_dir; } - scroll_value = list->size - 1; menu_driver_ctl(MENU_NAVIGATION_CTL_ADD_SCROLL_INDEX, &scroll_value); } diff --git a/menu/menu_input.c b/menu/menu_input.c index 1930307488..b7607c699c 100644 --- a/menu/menu_input.c +++ b/menu/menu_input.c @@ -651,7 +651,6 @@ static int menu_input_mouse_frame( return ret; } - int16_t menu_input_pointer_state(enum menu_input_pointer_state state) { menu_input_t *menu_input = &menu_input_state; diff --git a/menu/menu_setting.c b/menu/menu_setting.c index 5bf9a944d2..592008b136 100644 --- a/menu/menu_setting.c +++ b/menu/menu_setting.c @@ -52,7 +52,6 @@ #include "../cheevos/cheevos.h" #endif - #include "../frontend/frontend_driver.h" #include "widgets/menu_input_bind_dialog.h" @@ -188,7 +187,6 @@ static int setting_action_ok_bind_all_save_autoconfig(rarch_setting_t *setting, runloop_msg_queue_push( msg_hash_to_str(MSG_AUTOCONFIG_FILE_ERROR_SAVING), 1, 100, true); - return 0; } @@ -792,8 +790,6 @@ static void setting_get_string_representation_uint_xmb_menu_color_theme( } #endif - - #ifdef HAVE_OZONE static void setting_get_string_representation_uint_ozone_menu_color_theme( rarch_setting_t *setting, @@ -1042,7 +1038,6 @@ static int setting_action_left_libretro_device_type( return 0; } - static int setting_uint_action_left_crt_switch_resolution_super( rarch_setting_t *setting, bool wraparound) { @@ -1090,7 +1085,6 @@ static int setting_action_left_bind_device(rarch_setting_t *setting, bool wrapar return 0; } - static int setting_action_left_mouse_index(rarch_setting_t *setting, bool wraparound) { settings_t *settings = config_get_ptr(); @@ -1228,7 +1222,6 @@ static int setting_string_action_left_driver(rarch_setting_t *setting, return 0; } - #ifdef HAVE_NETWORKING static int setting_string_action_left_netplay_mitm_server( rarch_setting_t *setting, bool wraparound) @@ -2024,7 +2017,6 @@ void menu_settings_list_current_add_enum_value_idx( (*list)[idx].enum_value_idx = enum_idx; } - int menu_setting_generic(rarch_setting_t *setting, bool wraparound) { uint64_t flags = setting->flags; @@ -2342,7 +2334,6 @@ static int setting_action_start_bind_device(rarch_setting_t *setting) return 0; } - static int setting_action_start_custom_viewport_width(rarch_setting_t *setting) { video_viewport_t vp; @@ -2395,8 +2386,6 @@ static int setting_action_start_custom_viewport_height(rarch_setting_t *setting) return 0; } - - static int setting_action_start_analog_dpad_mode(rarch_setting_t *setting) { if (!setting) @@ -2618,7 +2607,6 @@ static void get_string_representation_bind_device(rarch_setting_t *setting, char strlcpy(s, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_DISABLED), len); } - /** * menu_setting_get_label: * @list : File list on which to perform the search @@ -3576,7 +3564,6 @@ static bool setting_append_list( &subgroup_info, parent_group); - if (settings->bools.history_list_enable) { CONFIG_ACTION( @@ -4300,7 +4287,6 @@ static bool setting_append_list( bool_entries[i].flags); } - END_SUB_GROUP(list, list_info, parent_group); END_GROUP(list, list_info, parent_group); } @@ -4558,7 +4544,6 @@ static bool setting_append_list( &setting_get_string_representation_uint_autosave_interval; #endif - END_SUB_GROUP(list, list_info, parent_group); END_GROUP(list, list_info, parent_group); } @@ -4687,8 +4672,6 @@ static bool setting_append_list( START_SUB_GROUP(list, list_info, "State", &group_info, &subgroup_info, parent_group); - - config_uint_cbs(cheat_manager_state.working_cheat.idx, CHEAT_IDX, NULL,NULL, 0,&setting_get_string_representation_uint,0,cheat_manager_get_size()-1,1) ; @@ -4896,7 +4879,6 @@ static bool setting_append_list( (*list)[list_info->index - 1].get_string_representation = &setting_get_string_representation_uint_cheat_exact; (*list)[list_info->index - 1].action_ok = &cheat_manager_search_exact; - CONFIG_UINT( list, list_info, &cheat_manager_state.dummy, @@ -5059,7 +5041,6 @@ static bool setting_append_list( (*list)[list_info->index - 1].action_right = &setting_uint_action_right_with_refresh; (*list)[list_info->index - 1].get_string_representation = &setting_get_string_representation_uint_cheat_browse_address; - END_SUB_GROUP(list, list_info, parent_group); END_GROUP(list, list_info, parent_group); break; @@ -5136,8 +5117,6 @@ static bool setting_append_list( general_read_handler, SD_FLAG_NONE); - - CONFIG_BOOL( list, list_info, &settings->bools.video_framecount_show, @@ -6581,7 +6560,6 @@ static bool setting_append_list( END_SUB_GROUP(list, list_info, parent_group); - START_SUB_GROUP( list, list_info, @@ -7514,7 +7492,6 @@ static bool setting_append_list( settings_data_list_current_add_flags(list, list_info, SD_FLAG_LAKKA_ADVANCED); } - CONFIG_BOOL( list, list_info, &settings->bools.menu_pause_libretro, @@ -7759,7 +7736,6 @@ static bool setting_append_list( #endif } - END_SUB_GROUP(list, list_info, parent_group); START_SUB_GROUP(list, list_info, "Navigation", &group_info, &subgroup_info, parent_group); @@ -7848,7 +7824,6 @@ static bool setting_append_list( ); #endif - END_SUB_GROUP(list, list_info, parent_group); START_SUB_GROUP(list, list_info, "Display", &group_info, &subgroup_info, parent_group); @@ -8207,7 +8182,6 @@ static bool setting_append_list( general_read_handler, SD_FLAG_LAKKA_ADVANCED); - #ifdef HAVE_LAKKA CONFIG_BOOL( list, list_info, @@ -8704,7 +8678,6 @@ static bool setting_append_list( general_read_handler, SD_FLAG_NONE); - #ifdef HAVE_IMAGEVIEWER CONFIG_BOOL( list, list_info, @@ -9756,7 +9729,6 @@ static bool setting_append_list( &subgroup_info, parent_group); - #if defined(HAVE_NETWORK_CMD) CONFIG_BOOL( list, list_info, @@ -9830,7 +9802,6 @@ static bool setting_append_list( snprintf(s1, sizeof(s1), "%s_user_p%d", msg_hash_to_str(MENU_ENUM_LABEL_NETWORK_REMOTE_ENABLE), user + 1); snprintf(s2, sizeof(s2), msg_hash_to_str(MENU_ENUM_LABEL_VALUE_NETWORK_USER_REMOTE_ENABLE), user + 1); - CONFIG_BOOL_ALT( list, list_info, &settings->bools.network_remote_enable_user[user], @@ -10669,7 +10640,6 @@ static bool setting_append_list( break; } - return true; } diff --git a/menu/menu_shader.c b/menu/menu_shader.c index 1dbb2aaf71..c547bfc26c 100644 --- a/menu/menu_shader.c +++ b/menu/menu_shader.c @@ -208,7 +208,9 @@ bool menu_shader_manager_set_preset(void *data, } config_file_free(conf); +#ifdef HAVE_MENU menu_entries_ctl(MENU_ENTRIES_CTL_SET_REFRESH, &refresh); +#endif return true; } @@ -341,7 +343,7 @@ bool menu_shader_manager_save_preset( if (!string_is_empty(basename)) strlcpy(preset_path, buffer, sizeof(preset_path)); - if (config_file_write(conf, preset_path)) + if (config_file_write(conf, preset_path, true)) { RARCH_LOG("Saved shader preset to %s.\n", preset_path); if (apply) @@ -361,7 +363,7 @@ bool menu_shader_manager_save_preset( fill_pathname_join(preset_path, dirs[d], buffer, sizeof(preset_path)); - if (config_file_write(conf, preset_path)) + if (config_file_write(conf, preset_path, true)) { RARCH_LOG("Saved shader preset to %s.\n", preset_path); if (apply) @@ -394,7 +396,10 @@ int menu_shader_manager_clear_num_passes(void) if (shader->passes) shader->passes = 0; +#ifdef HAVE_MENU menu_entries_ctl(MENU_ENTRIES_CTL_SET_REFRESH, &refresh); +#endif + video_shader_resolve_parameters(NULL, shader); return 0; diff --git a/menu/widgets/menu_filebrowser.c b/menu/widgets/menu_filebrowser.c index 4999bcca5e..3475f316fe 100644 --- a/menu/widgets/menu_filebrowser.c +++ b/menu/widgets/menu_filebrowser.c @@ -110,7 +110,6 @@ void filebrowser_parse(menu_displaylist_info_t *info, unsigned type_data) true, settings->bools.show_hidden_files, true, false); } - switch (filebrowser_types) { case FILEBROWSER_SCAN_DIR: @@ -305,7 +304,7 @@ void filebrowser_parse(menu_displaylist_info_t *info, unsigned type_data) } end: - if (info) + if (info && !path_is_compressed) menu_entries_prepend(info->list, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_PARENT_DIRECTORY), path, diff --git a/menu/widgets/menu_input_bind_dialog.c b/menu/widgets/menu_input_bind_dialog.c index 67e864d976..69ad36c2db 100644 --- a/menu/widgets/menu_input_bind_dialog.c +++ b/menu/widgets/menu_input_bind_dialog.c @@ -391,7 +391,6 @@ static bool menu_input_key_bind_poll_find_trigger_pad( return false; } - static bool menu_input_key_bind_poll_find_hold_pad( struct menu_bind_state *new_state, struct retro_keybind * output, diff --git a/msg_hash.c b/msg_hash.c index a9e7e7e5b2..2a629e0a09 100644 --- a/msg_hash.c +++ b/msg_hash.c @@ -211,6 +211,8 @@ uint32_t msg_hash_calculate(const char *s) #define MENU_VALUE_FILE_JPEG_CAPS 0x7c87010bU #define MENU_VALUE_FILE_PNG 0x0b889deaU #define MENU_VALUE_FILE_PNG_CAPS 0x0b88118aU +#define MENU_VALUE_FILE_GONG 0x7c977150U +#define MENU_VALUE_FILE_GONG_CAPS 0x7c8558d0U #define MENU_VALUE_FILE_TGA 0x0b88ae01U #define MENU_VALUE_FILE_BMP 0x0b886244U @@ -390,6 +392,11 @@ enum msg_file_type msg_hash_to_file_type(uint32_t hash) return FILE_TYPE_TGA; case MENU_VALUE_FILE_BMP: return FILE_TYPE_BMP; +#endif +#ifdef HAVE_EASTEREGG + case MENU_VALUE_FILE_GONG: + case MENU_VALUE_FILE_GONG_CAPS: + return FILE_TYPE_GONG; #endif case HASH_EXTENSION_CUE: case HASH_EXTENSION_CUE_UPPERCASE: diff --git a/msg_hash.h b/msg_hash.h index 643bca75db..6e299750d5 100644 --- a/msg_hash.h +++ b/msg_hash.h @@ -141,6 +141,8 @@ enum msg_file_type FILE_TYPE_DIRECT_LOAD, + FILE_TYPE_GONG, + FILE_TYPE_LAST }; @@ -189,6 +191,7 @@ enum msg_hash_enums MSG_RESAMPLER_QUALITY_NORMAL, MSG_RESAMPLER_QUALITY_HIGHER, MSG_RESAMPLER_QUALITY_HIGHEST, + MSG_DISCORD_CONNECTION_REQUEST, MSG_ADDED_TO_FAVORITES, MSG_RESET_CORE_ASSOCIATION, MSG_CORE_ASSOCIATION_RESET, @@ -228,6 +231,7 @@ enum msg_hash_enums MSG_GOT_CONNECTION_FROM_NAME, MSG_CONNECTION_SLOT, MSG_PUBLIC_ADDRESS, + MSG_UPNP_FAILED, MSG_NO_SAVE_STATE_HAS_BEEN_OVERWRITTEN_YET, MSG_CANNOT_INFER_NEW_CONFIG_PATH, MSG_UNDID_LOAD_STATE, @@ -539,6 +543,7 @@ enum msg_hash_enums MENU_ENUM_LABEL_CORE_OPTION_ENTRY, MENU_ENUM_LABEL_NETWORK_INFO_ENTRY, MENU_ENUM_LABEL_SYSTEM_INFO_ENTRY, + MENU_ENUM_LABEL_SYSTEM_INFO_CONTROLLER_ENTRY, MENU_ENUM_LABEL_CORE_INFO_ENTRY, MENU_ENUM_LABEL_PLAYLIST_ENTRY, @@ -774,7 +779,6 @@ enum msg_hash_enums MENU_LABEL(VIDEO_SHARED_CONTEXT), MENU_LABEL(VIDEO_THREADED), - MENU_LABEL(VIDEO_SWAP_INTERVAL), MENU_LABEL(VIDEO_FULLSCREEN), MENU_LABEL(VIDEO_MONITOR_INDEX), @@ -787,7 +791,6 @@ enum msg_hash_enums MENU_ENUM_LABEL_CONTENT_ACTIONS, - /* Menu settings */ MENU_LABEL(MENU_SHOW_LOAD_CORE), MENU_LABEL(MENU_SHOW_LOAD_CONTENT), @@ -974,7 +977,6 @@ enum msg_hash_enums MENU_ENUM_LABEL_PLAYLIST_SETTINGS_BEGIN, - MENU_ENUM_LABEL_VALUE_CHEEVOS_SETTINGS, MENU_LABEL(CHEEVOS_USERNAME), @@ -1931,6 +1933,7 @@ enum msg_hash_enums MENU_ENUM_LABEL_CB_UPDATE_SHADERS_CG, MENU_ENUM_LABEL_CB_UPDATE_SHADERS_GLSL, MENU_ENUM_LABEL_CB_UPDATE_SHADERS_SLANG, + MENU_ENUM_LABEL_CB_DISCORD_AVATAR, /* Sublabels */ MENU_ENUM_SUBLABEL_MIXER_ACTION_PLAY, @@ -1982,6 +1985,8 @@ enum msg_hash_enums MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_ALL_PLAYLISTS_LIST_MAX_COUNT, MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_ALL_PLAYLISTS_GRID_MAX_COUNT, MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_STARTUP_PLAYLIST, + MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_TYPE, + MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_CACHE_LIMIT, MENU_ENUM_LABEL_VALUE_QT_MENU_TOOLS, MENU_ENUM_LABEL_VALUE_QT_MENU_HELP, MENU_ENUM_LABEL_VALUE_QT_MENU_DOCK_CONTENT_BROWSER, diff --git a/network/netplay/netplay.h b/network/netplay/netplay.h index 23536bdbbc..6fe9eeb9d5 100644 --- a/network/netplay/netplay.h +++ b/network/netplay/netplay.h @@ -15,7 +15,6 @@ * If not, see . */ - #ifndef __RARCH_NETPLAY_H #define __RARCH_NETPLAY_H diff --git a/network/netplay/netplay_discovery.h b/network/netplay/netplay_discovery.h index 27b910915c..8df1fb5bdd 100644 --- a/network/netplay/netplay_discovery.h +++ b/network/netplay/netplay_discovery.h @@ -13,7 +13,6 @@ * If not, see . */ - #ifndef __RARCH_NETPLAY_DISCOVERY_H #define __RARCH_NETPLAY_DISCOVERY_H diff --git a/network/netplay/netplay_frontend.c b/network/netplay/netplay_frontend.c index db201ae222..f5261d630c 100644 --- a/network/netplay/netplay_frontend.c +++ b/network/netplay/netplay_frontend.c @@ -41,6 +41,7 @@ #include "../../file_path_special.h" #include "../../paths.h" #include "../../command.h" +#include "../../dynamic.h" #include "../../retroarch.h" /* Only used before init_netplay */ @@ -272,7 +273,6 @@ bool init_netplay_deferred(const char* server, unsigned port) return netplay_client_deferred; } - /** * netplay_poll: * @netplay : pointer to netplay object @@ -640,15 +640,6 @@ static void netplay_announce_cb(void *task_data, void *user_data, const char *er { RARCH_LOG("[netplay] announcing netplay game... \n"); -#ifdef HAVE_DISCORD - if (discord_is_inited) - { - discord_userdata_t userdata; - userdata.status = DISCORD_PRESENCE_NETPLAY_HOSTING; - command_event(CMD_EVENT_DISCORD_UPDATE, &userdata); - } -#endif - if (task_data) { unsigned i, ip_len, port_len; @@ -794,6 +785,15 @@ static void netplay_announce_cb(void *task_data, void *user_data, const char *er free(host_string); } +#ifdef HAVE_DISCORD + if (discord_is_inited) + { + discord_userdata_t userdata; + userdata.status = DISCORD_PRESENCE_NETPLAY_HOSTING; + command_event(CMD_EVENT_DISCORD_UPDATE, &userdata); + } +#endif + string_list_free(lines); free(buf); free(task_data); @@ -857,19 +857,40 @@ static void netplay_announce(void) char *username = NULL; char *corename = NULL; char *gamename = NULL; + char *subsystemname = NULL; char *coreversion = NULL; char *frontend_ident = NULL; settings_t *settings = config_get_ptr(); struct retro_system_info *system = runloop_get_libretro_system_info(); uint32_t content_crc = content_get_crc(); + struct string_list *subsystem = path_get_subsystem_list(); + + if (subsystem) + { + unsigned i; + + for (i = 0; i < subsystem->size; i++) + { + strlcat(buf, path_basename(subsystem->elems[i].data), sizeof(buf)); + if (i < subsystem->size - 1) + strlcat(buf, "|", sizeof(buf)); + } + RARCH_LOG("%s\n", buf); + net_http_urlencode(&gamename, buf); + net_http_urlencode(&subsystemname, path_get(RARCH_PATH_SUBSYSTEM)); + } + else + { + net_http_urlencode(&gamename, + !string_is_empty(path_basename(path_get(RARCH_PATH_BASENAME))) ? + path_basename(path_get(RARCH_PATH_BASENAME)) : "N/A"); + net_http_urlencode(&subsystemname, "N/A"); + } netplay_get_architecture(frontend_architecture, sizeof(frontend_architecture)); net_http_urlencode(&username, settings->paths.username); net_http_urlencode(&corename, system->library_name); - net_http_urlencode(&gamename, - !string_is_empty(path_basename(path_get(RARCH_PATH_BASENAME))) ? - path_basename(path_get(RARCH_PATH_BASENAME)) : "N/A"); net_http_urlencode(&coreversion, system->library_version); net_http_urlencode(&frontend_ident, frontend_architecture); @@ -877,14 +898,15 @@ static void netplay_announce(void) snprintf(buf, sizeof(buf), "username=%s&core_name=%s&core_version=%s&" "game_name=%s&game_crc=%08X&port=%d&mitm_server=%s" - "&has_password=%d&has_spectate_password=%d&force_mitm=%d&retroarch_version=%s&frontend=%s", + "&has_password=%d&has_spectate_password=%d&force_mitm=%d" + "&retroarch_version=%s&frontend=%s&subsystem_name=%s", username, corename, coreversion, gamename, content_crc, settings->uints.netplay_port, settings->arrays.netplay_mitm_server, *settings->paths.netplay_password ? 1 : 0, *settings->paths.netplay_spectate_password ? 1 : 0, settings->bools.netplay_use_mitm_server, - PACKAGE_VERSION, frontend_architecture); + PACKAGE_VERSION, frontend_architecture, subsystemname); #if 0 RARCH_LOG("[netplay] announcement URL: %s\n", buf); #endif @@ -1115,7 +1137,6 @@ static void netplay_force_future(netplay_t *netplay) netplay->run_ptr = netplay->self_ptr; netplay->run_frame_count = netplay->self_frame_count; - /* We need to ignore any intervening data from the other side, * and never rewind past this */ netplay_update_unread_ptr(netplay); @@ -1485,8 +1506,6 @@ bool init_netplay(void *direct_host, const char *server, unsigned port) return false; } - - /** * netplay_driver_ctl * diff --git a/network/netplay/netplay_io.c b/network/netplay/netplay_io.c index 33506e1430..c513a26519 100644 --- a/network/netplay/netplay_io.c +++ b/network/netplay/netplay_io.c @@ -54,7 +54,7 @@ static void print_state(netplay_t *netplay) } msg[sizeof(msg)-1] = '\0'; - RARCH_LOG("%s\n", msg); + RARCH_LOG("[netplay] %s\n", msg); #undef APPEND #undef M @@ -117,7 +117,7 @@ void netplay_hangup(netplay_t *netplay, struct netplay_connection *connection) dmsg = msg_hash_to_str(MSG_NETPLAY_CLIENT_HANGUP); netplay->is_connected = false; } - RARCH_LOG("%s\n", dmsg); + RARCH_LOG("[netplay] %s\n", dmsg); runloop_msg_queue_push(dmsg, 1, 180, false); socket_close(connection->fd); @@ -246,7 +246,7 @@ static bool send_input_frame(netplay_t *netplay, struct delta_frame *dframe, buffer[1] = htonl((bufused-2) * sizeof(uint32_t)); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Sending input for client %u\n", (unsigned) client_num); + RARCH_LOG("[netplay] Sending input for client %u\n", (unsigned) client_num); print_state(netplay); #endif @@ -635,7 +635,7 @@ static void announce_play_spectate(netplay_t *netplay, if (msg[0]) { - RARCH_LOG("%s\n", msg); + RARCH_LOG("[netplay] %s\n", msg); runloop_msg_queue_push(msg, 1, 180, false); } } @@ -915,7 +915,7 @@ static bool netplay_get_cmd(netplay_t *netplay, cmd_size = ntohl(cmd_size); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received netplay command %X (%u) from %u\n", cmd, cmd_size, + RARCH_LOG("[netplay] Received netplay command %X (%u) from %u\n", cmd, cmd_size, (unsigned) (connection - netplay->connections)); #endif @@ -1063,7 +1063,7 @@ static bool netplay_get_cmd(netplay_t *netplay, } #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received input from %u\n", client_num); + RARCH_LOG("[netplay] Received input from %u\n", client_num); print_state(netplay); #endif break; @@ -1102,7 +1102,7 @@ static bool netplay_get_cmd(netplay_t *netplay, netplay->server_ptr = NEXT_PTR(netplay->server_ptr); netplay->server_frame_count++; #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received server noinput\n"); + RARCH_LOG("[netplay] Received server noinput\n"); print_state(netplay); #endif break; @@ -1339,7 +1339,7 @@ static bool netplay_get_cmd(netplay_t *netplay, announce_play_spectate(netplay, NULL, NETPLAY_CONNECTION_PLAYING, devices); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received mode change self->%X\n", devices); + RARCH_LOG("[netplay] Received mode change self->%X\n", devices); print_state(netplay); #endif @@ -1363,7 +1363,7 @@ static bool netplay_get_cmd(netplay_t *netplay, announce_play_spectate(netplay, NULL, NETPLAY_CONNECTION_SPECTATING, 0); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received mode change self->spectating\n"); + RARCH_LOG("[netplay] Received mode change self->spectating\n"); print_state(netplay); #endif @@ -1394,7 +1394,7 @@ static bool netplay_get_cmd(netplay_t *netplay, announce_play_spectate(netplay, nick, NETPLAY_CONNECTION_PLAYING, devices); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received mode change %u->%u\n", client_num, devices); + RARCH_LOG("[netplay] Received mode change %u->%u\n", client_num, devices); print_state(netplay); #endif @@ -1410,7 +1410,7 @@ static bool netplay_get_cmd(netplay_t *netplay, announce_play_spectate(netplay, nick, NETPLAY_CONNECTION_SPECTATING, 0); #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Received mode change %u->spectator\n", client_num); + RARCH_LOG("[netplay] Received mode change %u->spectator\n", client_num); print_state(netplay); #endif @@ -1468,7 +1468,7 @@ static bool netplay_get_cmd(netplay_t *netplay, if (dmsg) { - RARCH_LOG("%s\n", dmsg); + RARCH_LOG("[netplay] %s\n", dmsg); runloop_msg_queue_push(dmsg, 1, 180, false); } break; @@ -1728,7 +1728,7 @@ static bool netplay_get_cmd(netplay_t *netplay, netplay->other_frame_count = load_frame_count; #ifdef DEBUG_NETPLAY_STEPS - RARCH_LOG("Loading state at %u\n", load_frame_count); + RARCH_LOG("[netplay] Loading state at %u\n", load_frame_count); print_state(netplay); #endif @@ -1774,7 +1774,7 @@ static bool netplay_get_cmd(netplay_t *netplay, { snprintf(msg, sizeof(msg)-1, msg_hash_to_str(MSG_NETPLAY_PEER_PAUSED), nick); } - RARCH_LOG("%s\n", msg); + RARCH_LOG("[netplay] %s\n", msg); runloop_msg_queue_push(msg, 1, 180, false); break; } @@ -1901,7 +1901,7 @@ int netplay_poll_net_input(netplay_t *netplay, bool block) if (socket_select(max_fd, &fds, NULL, NULL, &tv) < 0) return -1; - RARCH_LOG("Network is stalling at frame %u, count %u of %d ...\n", + RARCH_LOG("[netplay] Network is stalling at frame %u, count %u of %d ...\n", netplay->run_frame_count, netplay->timeout_cnt, MAX_RETRIES); if (netplay->timeout_cnt >= MAX_RETRIES && !netplay->remote_paused) @@ -2011,13 +2011,19 @@ void netplay_announce_nat_traversal(netplay_t *netplay) } #endif else + { + snprintf(msg, sizeof(msg), "%s\n", + msg_hash_to_str(MSG_UPNP_FAILED)); + runloop_msg_queue_push(msg, 1, 180, false); + RARCH_LOG("[netplay] %s\n", msg); return; + } snprintf(msg, sizeof(msg), "%s: %s:%s\n", msg_hash_to_str(MSG_PUBLIC_ADDRESS), host, port); runloop_msg_queue_push(msg, 1, 180, false); - RARCH_LOG("%s\n", msg); + RARCH_LOG("[netplay] %s\n", msg); #endif } diff --git a/network/netplay/netplay_private.h b/network/netplay/netplay_private.h index d607b5e84f..d5f64150e4 100644 --- a/network/netplay/netplay_private.h +++ b/network/netplay/netplay_private.h @@ -569,7 +569,6 @@ struct netplay bool crcs_valid; }; - /*************************************************************** * NETPLAY-BUF.C **************************************************************/ @@ -639,7 +638,6 @@ void netplay_recv_reset(struct socket_buffer *sbuf); */ void netplay_recv_flush(struct socket_buffer *sbuf); - /*************************************************************** * NETPLAY-DELTA.C **************************************************************/ @@ -685,7 +683,6 @@ netplay_input_state_t netplay_input_state_for(netplay_input_state_t *list, */ uint32_t netplay_expected_input_size(netplay_t *netplay, uint32_t devices); - /*************************************************************** * NETPLAY-DISCOVERY.C **************************************************************/ @@ -697,7 +694,6 @@ uint32_t netplay_expected_input_size(netplay_t *netplay, uint32_t devices); */ bool netplay_lan_ad_server(netplay_t *netplay); - /*************************************************************** * NETPLAY-FRONTEND.C **************************************************************/ @@ -749,7 +745,6 @@ bool netplay_handshake_init_send(netplay_t *netplay, bool netplay_handshake(netplay_t *netplay, struct netplay_connection *connection, bool *had_input); - /*************************************************************** * NETPLAY-INIT.C **************************************************************/ @@ -803,7 +798,6 @@ netplay_t *netplay_new(void *direct_host, const char *server, uint16_t port, */ void netplay_free(netplay_t *netplay); - /*************************************************************** * NETPLAY-IO.C **************************************************************/ @@ -914,7 +908,6 @@ void netplay_announce_nat_traversal(netplay_t *netplay); */ void netplay_init_nat_traversal(netplay_t *netplay); - /*************************************************************** * NETPLAY-KEYBOARD.C **************************************************************/ @@ -941,7 +934,6 @@ uint32_t netplay_key_hton(unsigned key); * netplay_key_hton */ void netplay_key_hton_init(void); - /*************************************************************** * NETPLAY-SYNC.C **************************************************************/ diff --git a/paths.c b/paths.c index 67a71840c2..8eb2a48d6d 100644 --- a/paths.c +++ b/paths.c @@ -258,7 +258,6 @@ void path_set_special(char **argv, unsigned num_content) char str[PATH_MAX_LENGTH]; global_t *global = global_get_ptr(); - /* First content file is the significant one. */ path_set_basename(argv[0]); @@ -311,7 +310,7 @@ static bool path_init_subsystem(void) /* For subsystems, we know exactly which RAM types are supported. */ info = libretro_find_subsystem_info( - subsystem_data, + system->subsystem.data, system->subsystem.size, path_get(RARCH_PATH_SUBSYSTEM)); @@ -424,7 +423,6 @@ static void path_init_savefile_internal(void) } } - void path_fill_names(void) { global_t *global = global_get_ptr(); @@ -779,6 +777,10 @@ enum rarch_content_type path_is_media_type(const char *path) case FILE_TYPE_XM: return RARCH_CONTENT_MUSIC; #endif +#ifdef HAVE_EASTEREGG + case FILE_TYPE_GONG: + return RARCH_CONTENT_GONG; +#endif case FILE_TYPE_NONE: default: diff --git a/paths.h b/paths.h index fd8e0659ef..15c49fa511 100644 --- a/paths.h +++ b/paths.h @@ -28,7 +28,8 @@ enum rarch_content_type RARCH_CONTENT_NONE = 0, RARCH_CONTENT_MOVIE, RARCH_CONTENT_MUSIC, - RARCH_CONTENT_IMAGE + RARCH_CONTENT_IMAGE, + RARCH_CONTENT_GONG }; enum rarch_path_type diff --git a/pkg/msvc-uwp/.gitignore b/pkg/msvc-uwp/.gitignore new file mode 100644 index 0000000000..c7d7d6c4da --- /dev/null +++ b/pkg/msvc-uwp/.gitignore @@ -0,0 +1,3 @@ +AppPackages/ +*/BundleArtifacts/ +.vs/ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-100.png new file mode 100644 index 0000000000..f731463086 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-200.png new file mode 100644 index 0000000000..80c1425605 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-400.png new file mode 100644 index 0000000000..85140caac2 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/LargeTile.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-100.png new file mode 100644 index 0000000000..ef1f5dc6a8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-200.png new file mode 100644 index 0000000000..ca2057c758 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-400.png new file mode 100644 index 0000000000..398721a461 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/SmallTile.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-100.png new file mode 100644 index 0000000000..3b3b57758c Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-200.png new file mode 100644 index 0000000000..22ebaab856 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-400.png new file mode 100644 index 0000000000..efe1abaff7 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square150x150Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-16.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-16.png new file mode 100644 index 0000000000..d5b34622f9 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-16.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-256.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-256.png new file mode 100644 index 0000000000..22c0960e8d Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-256.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-48.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-48.png new file mode 100644 index 0000000000..2a253ca049 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.altform-unplated_targetsize-48.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-100.png new file mode 100644 index 0000000000..8b7216b8d8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-200.png new file mode 100644 index 0000000000..6fec1f0113 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-400.png new file mode 100644 index 0000000000..5e2a9c1e20 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-16.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-16.png new file mode 100644 index 0000000000..979d24169f Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-16.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-256.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-256.png new file mode 100644 index 0000000000..1f953b2fc8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-256.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-48.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-48.png new file mode 100644 index 0000000000..82b200438a Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Square44x44Logo.targetsize-48.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-100.png new file mode 100644 index 0000000000..a065bc4725 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-200.png new file mode 100644 index 0000000000..2f37ce6d7d Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-400.png new file mode 100644 index 0000000000..bc17a33e34 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/StoreLogo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-100.png new file mode 100644 index 0000000000..6253947fdc Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-200.png new file mode 100644 index 0000000000..7053ee0bbf Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-400.png new file mode 100644 index 0000000000..a0661bc4aa Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Assets/Wide310x150Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Package.appxmanifest b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Package.appxmanifest new file mode 100644 index 0000000000..c4a89d6664 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/Package.appxmanifest @@ -0,0 +1,23 @@ + + + + + + RetroArch: non-free cores + libretro + Assets\StoreLogo.png + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj new file mode 100644 index 0000000000..ce015f68d1 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj @@ -0,0 +1,230 @@ + + + + {cc7b9a23-bd64-4eb9-9d8f-f5115fb8960f} + RetroArch_msvc2017_UWP_cores_nonfree + en-US + 14.0 + true + Windows Store + 10.0.17763.0 + 10.0.15063.0 + 10.0 + + + + + Debug + ARM + + + Debug + ARM64 + + + Debug + Win32 + + + Debug + x64 + + + Release + ARM + + + Release + ARM64 + + + Release + Win32 + + + Release + x64 + + + + Application + true + v141 + + + Application + true + v141 + + + Application + true + v141 + + + Application + true + v141 + true + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + + + + + + + + + + + + + + + + + + + + + + + ..\RetroArch-msvc2017-UWP\RetroArch-UWP_TemporaryKey.pfx + False + False + Always + x86|x64|arm + 1 + OnApplicationRun + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + /bigobj %(AdditionalOptions) + 4453;28204 + NotUsing + + + + + Designer + + + true + cores\%(Filename)%(Extension) + + + true + %(Filename)%(Extension) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj.filters b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj.filters new file mode 100644 index 0000000000..9834a81c26 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/RetroArch-msvc2017-UWP-cores-nonfree.vcxproj.filters @@ -0,0 +1,100 @@ + + + + + 56304c12-6031-4556-a470-2c69aecd5919 + bmp;fbx;gif;jpg;jpeg;tga;tiff;tif;png + + + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/input/drivers_joypad/ps2_joypad_copy.c b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM/.empty similarity index 100% rename from input/drivers_joypad/ps2_joypad_copy.c rename to pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM/.empty diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM64/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM64/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM64/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/ARM64/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/Win32/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/Win32/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/Win32/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/Win32/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/x64/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/x64/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/x64/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/cores/x64/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/dummy.cpp b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/dummy.cpp new file mode 100644 index 0000000000..935c25a93c --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP-cores-nonfree/dummy.cpp @@ -0,0 +1,5 @@ +[Platform::MTAThread] +int main(Platform::Array^) +{ + throw ref new Platform::NotImplementedException(); +} diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP.sln b/pkg/msvc-uwp/RetroArch-msvc2017-UWP.sln new file mode 100644 index 0000000000..7cd6c43dd7 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP.sln @@ -0,0 +1,83 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.28307.168 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "RetroArch-msvc2017-UWP", "RetroArch-msvc2017-UWP\RetroArch-msvc2017-UWP.vcxproj", "{F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}" +EndProject +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "RetroArch-msvc2017-UWP-cores-nonfree", "RetroArch-msvc2017-UWP-cores-nonfree\RetroArch-msvc2017-UWP-cores-nonfree.vcxproj", "{CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Debug|ARM = Debug|ARM + Debug|ARM64 = Debug|ARM64 + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|Any CPU = Release|Any CPU + Release|ARM = Release|ARM + Release|ARM64 = Release|ARM64 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|Any CPU.ActiveCfg = Debug|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM.ActiveCfg = Debug|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM.Build.0 = Debug|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM.Deploy.0 = Debug|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM64.ActiveCfg = Debug|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM64.Build.0 = Debug|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|ARM64.Deploy.0 = Debug|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x64.ActiveCfg = Debug|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x64.Build.0 = Debug|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x64.Deploy.0 = Debug|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x86.ActiveCfg = Debug|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x86.Build.0 = Debug|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Debug|x86.Deploy.0 = Debug|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|Any CPU.ActiveCfg = Release|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM.ActiveCfg = Release|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM.Build.0 = Release|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM.Deploy.0 = Release|ARM + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM64.ActiveCfg = Release|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM64.Build.0 = Release|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|ARM64.Deploy.0 = Release|ARM64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x64.ActiveCfg = Release|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x64.Build.0 = Release|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x64.Deploy.0 = Release|x64 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x86.ActiveCfg = Release|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x86.Build.0 = Release|Win32 + {F5E937B6-1BA0-4446-B94B-F3BBDEF908F4}.Release|x86.Deploy.0 = Release|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|Any CPU.ActiveCfg = Debug|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM.ActiveCfg = Debug|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM.Build.0 = Debug|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM.Deploy.0 = Debug|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM64.ActiveCfg = Debug|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM64.Build.0 = Debug|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|ARM64.Deploy.0 = Debug|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x64.ActiveCfg = Debug|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x64.Build.0 = Debug|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x64.Deploy.0 = Debug|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x86.ActiveCfg = Debug|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x86.Build.0 = Debug|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Debug|x86.Deploy.0 = Debug|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|Any CPU.ActiveCfg = Release|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM.ActiveCfg = Release|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM.Build.0 = Release|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM.Deploy.0 = Release|ARM + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM64.ActiveCfg = Release|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM64.Build.0 = Release|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|ARM64.Deploy.0 = Release|ARM64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x64.ActiveCfg = Release|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x64.Build.0 = Release|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x64.Deploy.0 = Release|x64 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x86.ActiveCfg = Release|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x86.Build.0 = Release|Win32 + {CC7B9A23-BD64-4EB9-9D8F-F5115FB8960F}.Release|x86.Deploy.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {2A811B94-2232-4C4E-A88E-33B0CDF139A2} + EndGlobalSection +EndGlobal diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-100.png new file mode 100644 index 0000000000..f731463086 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-200.png new file mode 100644 index 0000000000..80c1425605 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-400.png new file mode 100644 index 0000000000..85140caac2 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/LargeTile.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-100.png new file mode 100644 index 0000000000..ef1f5dc6a8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-200.png new file mode 100644 index 0000000000..ca2057c758 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-400.png new file mode 100644 index 0000000000..398721a461 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SmallTile.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-100.png new file mode 100644 index 0000000000..23acbe613d Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-200.png new file mode 100644 index 0000000000..5fb2eb78fc Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-400.png new file mode 100644 index 0000000000..62d2b0911b Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/SplashScreen.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-100.png new file mode 100644 index 0000000000..3b3b57758c Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-200.png new file mode 100644 index 0000000000..22ebaab856 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-400.png new file mode 100644 index 0000000000..efe1abaff7 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square150x150Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-16.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-16.png new file mode 100644 index 0000000000..d5b34622f9 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-16.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-256.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-256.png new file mode 100644 index 0000000000..22c0960e8d Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-256.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-48.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-48.png new file mode 100644 index 0000000000..2a253ca049 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.altform-unplated_targetsize-48.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-100.png new file mode 100644 index 0000000000..8b7216b8d8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-200.png new file mode 100644 index 0000000000..6fec1f0113 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-400.png new file mode 100644 index 0000000000..5e2a9c1e20 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-16.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-16.png new file mode 100644 index 0000000000..979d24169f Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-16.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-256.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-256.png new file mode 100644 index 0000000000..1f953b2fc8 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-256.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-48.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-48.png new file mode 100644 index 0000000000..82b200438a Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Square44x44Logo.targetsize-48.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-100.png new file mode 100644 index 0000000000..a065bc4725 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-200.png new file mode 100644 index 0000000000..2f37ce6d7d Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-400.png new file mode 100644 index 0000000000..bc17a33e34 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/StoreLogo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-100.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-100.png new file mode 100644 index 0000000000..6253947fdc Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-100.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-200.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-200.png new file mode 100644 index 0000000000..7053ee0bbf Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-200.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-400.png b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-400.png new file mode 100644 index 0000000000..a0661bc4aa Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Assets/Wide310x150Logo.scale-400.png differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Bundle.Mapping.txt b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Bundle.Mapping.txt new file mode 100644 index 0000000000..5e48e1ae47 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Bundle.Mapping.txt @@ -0,0 +1,2 @@ +[ExternalPackages] +"..\AppPackages\RetroArch-UWP-cores-nonfree\RetroArch-UWP-cores-nonfree_1.0.0.0_Test\RetroArch-UWP-cores-nonfree_1.0.0.0_x86_x64_arm.appxbundle" diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Package.appxmanifest b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Package.appxmanifest new file mode 100644 index 0000000000..e1d4376bbd --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/Package.appxmanifest @@ -0,0 +1,29 @@ + + + + + + RetroArch + libretro + Assets\StoreLogo.png + + + + + + + + + + + + + + + + + + + + + diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj new file mode 100644 index 0000000000..1f21ca7a6c --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj @@ -0,0 +1,337 @@ + + + + + Debug + Win32 + + + Release + Win32 + + + Debug + x64 + + + Release + x64 + + + Debug + ARM + + + Release + ARM + + + Debug + ARM64 + + + Release + ARM64 + + + + {f5e937b6-1ba0-4446-b94b-f3bbdef908f4} + DirectXApp + RetroArchUWP + en-US + 14.0 + true + Windows Store + 10.0 + 10.0.17763.0 + 10.0.15063.0 + true + + + + Application + true + v141 + + + Application + true + v141 + + + Application + true + v141 + true + + + Application + true + v141 + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + Application + false + true + v141 + true + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + RetroArch-UWP_TemporaryKey.pfx + False + False + x86|x64|arm + 1 + OnApplicationRun + Always + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\arm; $(VCInstallDir)\lib\arm + /nodefaultlib:vccorlibd /nodefaultlib:msvcrtd vccorlibd.lib msvcrtd.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_RGUI;HAVE_MENU;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\arm; $(VCInstallDir)\lib\arm + /nodefaultlib:vccorlib /nodefaultlib:msvcrt vccorlib.lib msvcrt.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_MENU;HAVE_RGUI;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\arm64; $(VCInstallDir)\lib\arm64 + /nodefaultlib:vccorlibd /nodefaultlib:msvcrtd vccorlibd.lib msvcrtd.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_RGUI;HAVE_MENU;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\arm64; $(VCInstallDir)\lib\arm64 + /nodefaultlib:vccorlib /nodefaultlib:msvcrt vccorlib.lib msvcrt.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_MENU;HAVE_RGUI;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store; $(VCInstallDir)\lib + /nodefaultlib:vccorlibd /nodefaultlib:msvcrtd vccorlibd.lib msvcrtd.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_RGUI;HAVE_MENU;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + ProgramDatabase + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store; $(VCInstallDir)\lib + /nodefaultlib:vccorlib /nodefaultlib:msvcrt vccorlib.lib msvcrt.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_MENU;HAVE_RGUI;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\amd64; $(VCInstallDir)\lib\amd64 + /nodefaultlib:vccorlibd /nodefaultlib:msvcrtd vccorlibd.lib msvcrtd.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_RGUI;HAVE_MENU;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + ProgramDatabase + + + + + d2d1.lib; d3d11.lib; dxgi.lib; windowscodecs.lib; dwrite.lib; dxguid.lib; %(AdditionalDependencies) + %(AdditionalLibraryDirectories); $(VCInstallDir)\lib\store\amd64; $(VCInstallDir)\lib\amd64 + /nodefaultlib:vccorlib /nodefaultlib:msvcrt vccorlib.lib msvcrt.lib %(AdditionalOptions) + + + + + $(MSBuildProjectDirectory);$(MSBuildProjectDirectory)\..\..\..\;$(MSBuildProjectDirectory)\..\..\..\deps\rcheevos\include;$(MSBuildProjectDirectory)\..\..\..\deps\zlib;$(MSBuildProjectDirectory)\..\..\..\libretro-common\include;$(MSBuildProjectDirectory)\..\..\..\deps;$(MSBuildProjectDirectory)\..\..\..\deps\glslang;$(MSBuildProjectDirectory)\..\..\..\deps\SPIRV-Cross;$(MSBuildProjectDirectory)\..\..\..\deps\stb;$(MSBuildProjectDirectory)\..\..\..\gfx\include;%(AdditionalIncludeDirectories) + /bigobj %(AdditionalOptions) + 4453;28204 + WIN32;HAVE_MAIN;HAVE_DYNAMIC;HAVE_XAUDIO2;RARCH_INTERNAL;HAVE_CC_RESAMPLER;WANT_GLSLANG;HAVE_GLSLANG;HAVE_SLANG;HAVE_SPIRV_CROSS;HAVE_UPDATE_ASSETS;HAVE_D3D;HAVE_D3D11;HAVE_D3D12;ENABLE_HLSL;RC_DISABLE_LUA;HAVE_CHEEVOS;HAVE_RUNAHEAD;HAVE_GRIFFIN;HAVE_LANGEXTRA;HAVE_FBO;HAVE_ZLIB;HAVE_XMB;HAVE_SHADERPIPELINE;WANT_ZLIB;HAVE_RPNG;HAVE_RJPEG;HAVE_RBMP;HAVE_RTGA;HAVE_IMAGEVIEWER;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);HAVE_XINPUT;HAVE_XINPUT2;HAVE_XAUDIO;HAVE_DIRECTX;HAVE_NETWORKING;HAVE_NETWORK_CMD;HAVE_NETPLAYDISCOVERY;HAVE_COMMAND;HAVE_STDIN_CMD;HAVE_THREADS;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;HAVE_OVERLAY;HAVE_MENU;HAVE_RGUI;HAVE_MATERIALUI;HAVE_LIBRETRODB;HAVE_STB_FONT;HAVE_STATIC_DUMMY;HAVE_STATIC_VIDEO_FILTERS;HAVE_STATIC_AUDIO_FILTERS + + + + + false + false + false + false + false + false + false + false + + + + + + + + + + Designer + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + cores\%(Filename)%(Extension) + + + true + %(Filename)%(Extension) + + + + + + + + + + + + \ No newline at end of file diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj.filters b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj.filters new file mode 100644 index 0000000000..3fcb574ea4 --- /dev/null +++ b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP.vcxproj.filters @@ -0,0 +1,130 @@ + + + + + {1246fa09-e114-4a52-88c2-657b2f13d9fb} + + + {32de9679-6494-4933-afa2-430fd975e506} + + + {c3155604-6d38-494a-bfe0-861cef871cb2} + + + + + + + + + + + + + uwp + + + uwp + + + + + griffin + + + griffin + + + uwp + + + griffin + + + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + Assets + + + + + + \ No newline at end of file diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP_TemporaryKey.pfx b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP_TemporaryKey.pfx new file mode 100644 index 0000000000..ff20a54c34 Binary files /dev/null and b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/RetroArch-msvc2017-UWP_TemporaryKey.pfx differ diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM64/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM64/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM64/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/ARM64/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/Win32/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/Win32/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/Win32/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/Win32/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/x64/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/x64/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/x64/cores/.empty b/pkg/msvc-uwp/RetroArch-msvc2017-UWP/cores/x64/cores/.empty new file mode 100644 index 0000000000..e69de29bb2 diff --git a/playlist.c b/playlist.c index fba39fee5f..7089402ce5 100644 --- a/playlist.c +++ b/playlist.c @@ -490,7 +490,6 @@ size_t playlist_size(playlist_t *playlist) return playlist->size; } - static bool playlist_read_file( playlist_t *playlist, const char *path) { diff --git a/ps2/compat_ctype.c b/ps2/compat_files/compat_ctype.c similarity index 87% rename from ps2/compat_ctype.c rename to ps2/compat_files/compat_ctype.c index 0c5dba835d..83e80394f7 100644 --- a/ps2/compat_ctype.c +++ b/ps2/compat_files/compat_ctype.c @@ -1,3 +1,17 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + #include #include #include @@ -6,7 +20,13 @@ #define ULLONG_MAX UINT64_C(0xffffffffffffffff) -/* Do not link from libc */ +/* All the functions included in this file either could be: + - Because the PS2SDK doesn't contains this specific functionality + - Because the PS2SDK implementation is wrong + + Overrriding these methods here, make that the RetroArch will execute this code + rather than the code in the linked libraries + */ int islower(int c) { @@ -425,3 +445,8 @@ int link(const char *oldpath, const char *newpath) { return fileXioSymlink(oldpath, newpath); } + +int unlink(const char *path) +{ + return fileXioRemove(path); +} diff --git a/ps2/compat_files/time.c b/ps2/compat_files/time.c new file mode 100644 index 0000000000..2a7e672892 --- /dev/null +++ b/ps2/compat_files/time.c @@ -0,0 +1,114 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2019 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +/* This file improve the content of the original time.c file that belong to the PS2SDK. +The original time.c contains 4 non-static methods + +void _ps2sdk_time_init(void); +void _ps2sdk_time_deinit(void); +clock_t clock(void); +time_t time(time_t *t); + +So we need to duplicate all the method because this way the compiler will avoid to import +the code that belong to the PS2SDK */ + +#include +#include +#include +#include +#include +#include + +#define STARTING_YEAR 2000 +#define MIN_SUPPORTED_YEAR 1970 +#define MAX_SUPPORTED_YEAR 2108 +#define SECS_MIN 60L +#define MINS_HOUR 60L +#define HOURS_DAY 24L +#define DAYS_YEAR 365L +#define DEC(x) (10*(x/16)+(x%16)) +int _days[] = {-1, 30, 58, 89, 119, 150, 180, 211, 242, 272, 303, 333, 364}; + +static time_t _gmtotime_t ( + int yr, /* 0 based */ + int mo, /* 1 based */ + int dy, /* 1 based */ + int hr, + int mn, + int sc + ) +{ + int passed_years; + long passed_days; + long passed_seconds_current_day; + time_t seconds_from_1970 = -1; + + if ((yr >= MIN_SUPPORTED_YEAR) || (yr <= MAX_SUPPORTED_YEAR)) { + passed_years = (long)yr - MIN_SUPPORTED_YEAR; /* Years after 1970 */ + /* Calculate days for these years */ + passed_days = passed_years * DAYS_YEAR; + passed_days += (passed_years >> 2) * (DAYS_YEAR + 1); /* passed leap years */ + passed_days += dy + _days[mo - 1]; /* passed days in the year */ + if ( !(yr & 3) && (mo > 2) ) { + passed_days++; /* if current year, is a leap year */ + } + passed_seconds_current_day = (((hr * MINS_HOUR) + mn) * SECS_MIN) + sc; + seconds_from_1970 = (passed_days * HOURS_DAY * MINS_HOUR * SECS_MIN) + passed_seconds_current_day; + } + + return seconds_from_1970; +} + +time_t ps2_time(time_t *t) { + time_t tim; + sceCdCLOCK clocktime; /* defined in libcdvd.h */ + + sceCdReadClock(&clocktime); /* libcdvd.a */ + configConvertToLocalTime(&clocktime); + + tim = _gmtotime_t (DEC(clocktime.year)+ STARTING_YEAR, + DEC(clocktime.month), + DEC(clocktime.day), + DEC(clocktime.hour), + DEC(clocktime.minute), + DEC(clocktime.second)); + + if(t) + *t = tim; + + return tim; +} + +/* Protected methods in libc */ +void _ps2sdk_time_init(void) +{ + SDL_Init(SDL_INIT_TIMER); +} + +/* Protected methods in libc */ +void _ps2sdk_time_deinit(void) +{ + SDL_QuitSubSystem(SDL_INIT_TIMER); +} + +clock_t clock(void) +{ + return SDL_GetTicks(); +} + +time_t time(time_t *t) { + time_t tim = -1; + /* TODO: This function need to be implemented again because the SDK one is not working fine */ + return time; +} diff --git a/ps2/include/compat_ctype.h b/ps2/include/compat_ctype.h index 1d80025c28..cd1b96f543 100644 --- a/ps2/include/compat_ctype.h +++ b/ps2/include/compat_ctype.h @@ -1,3 +1,17 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + #ifndef COMPAT_CTYPE_H #define COMPAT_CTYPE_H @@ -6,5 +20,6 @@ char *strtok_r(char *str, const char *delim, char **saveptr); unsigned long long strtoull(const char * __restrict nptr, char ** __restrict endptr, int base); int link(const char *oldpath, const char *newpath); +int unlink(const char *path); #endif diff --git a/ps2/include/inttypes.h b/ps2/include/inttypes.h index 3049fbdbba..8b37fcc33e 100644 --- a/ps2/include/inttypes.h +++ b/ps2/include/inttypes.h @@ -1,3 +1,17 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + #ifndef INTTYPES_H #define INTTYPES_H diff --git a/ps2/include/math.h b/ps2/include/math.h index bf0071edb1..fa0672624f 100644 --- a/ps2/include/math.h +++ b/ps2/include/math.h @@ -1,3 +1,17 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + #ifndef MATH_H #define MATH_H diff --git a/ps2/include/pte_types.h b/ps2/include/pte_types.h index 7e81156684..4da1ebac65 100644 --- a/ps2/include/pte_types.h +++ b/ps2/include/pte_types.h @@ -1,4 +1,16 @@ -/* pte_types.h */ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ #ifndef PTE_TYPES_H #define PTE_TYPES_H diff --git a/ps2/include/stdint.h b/ps2/include/stdint.h index 813efd21f8..cc2582c1f3 100644 --- a/ps2/include/stdint.h +++ b/ps2/include/stdint.h @@ -1,3 +1,17 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2010-2018 - Francisco Javier Trujillo Mata - fjtrujy + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + #ifndef STDINT_H #define STDINT_H @@ -13,7 +27,7 @@ typedef unsigned short uint16_t; typedef unsigned int uint32_t; typedef unsigned long uint64_t; -#define STDIN_FILENO 0 /* standard input file descriptor */ +#define STDIN_FILENO 0 /* standard input file descriptor */ #define STDOUT_FILENO 1 /* standard output file descriptor */ #define STDERR_FILENO 2 /* standard error file descriptor */ @@ -27,4 +41,4 @@ typedef unsigned long uint64_t; #define UINT32_C(val) val##ui #define UINT64_C(val) val##ul -#endif //STDINT_H +#endif /* STDINT_H */ diff --git a/qb/config.libs.sh b/qb/config.libs.sh index 9ba639ec91..cf4ed4ab64 100644 --- a/qb/config.libs.sh +++ b/qb/config.libs.sh @@ -409,11 +409,18 @@ else check_val '' ZLIB '-lz' fi -if [ "$HAVE_MPV" != 'no' ]; then - check_pkgconf MPV libmpv +check_pkgconf MPV mpv +check_val '' MPV -lmpv + +if [ "$HAVE_THREADS" = 'no' ] && [ "$HAVE_FFMPEG" != 'no' ]; then + HAVE_FFMPEG='no' + die : 'Notice: Threads are not available, FFmpeg will also be disabled.' fi -if [ "$HAVE_THREADS" != 'no' ] && [ "$HAVE_FFMPEG" != 'no' ]; then +check_header DRMINGW exchndl.h +check_lib '' DRMINGW -lexchndl + +if [ "$HAVE_FFMPEG" != 'no' ]; then check_pkgconf AVCODEC libavcodec 54 check_pkgconf AVFORMAT libavformat 54 check_pkgconf AVDEVICE libavdevice @@ -438,7 +445,6 @@ if [ "$HAVE_THREADS" != 'no' ] && [ "$HAVE_FFMPEG" != 'no' ]; then die : 'Notice: FFmpeg built-in support disabled due to missing or unsuitable packages.' fi else - die : 'Notice: Not building with threading support. Will skip FFmpeg.' HAVE_FFMPEG='no' fi @@ -556,29 +562,24 @@ fi check_pkgconf PYTHON python3 -if [ "$HAVE_MATERIALUI" != 'no' ] || [ "$HAVE_XMB" != 'no' ] || [ "$HAVE_ZARCH" != 'no' ] || [ "$HAVE_OZONE" != 'no' ]; then - if [ "$HAVE_RGUI" = 'no' ]; then - HAVE_MATERIALUI=no - HAVE_XMB=no - HAVE_STRIPES=no - HAVE_ZARCH=no - HAVE_OZONE=no - die : 'Notice: RGUI not available, MaterialUI, XMB, Ozone and ZARCH will also be disabled.' - elif [ "$HAVE_OPENGL" = 'no' ] && [ "$HAVE_OPENGLES" = 'no' ] && [ "$HAVE_VULKAN" = 'no' ]; then +if [ "$HAVE_MENU" != 'no' ]; then + if [ "$HAVE_OPENGL" = 'no' ] && [ "$HAVE_OPENGLES" = 'no' ] && [ "$HAVE_VULKAN" = 'no' ]; then if [ "$OS" = 'Win32' ]; then HAVE_SHADERPIPELINE=no HAVE_VULKAN=no - die : 'Notice: Hardware rendering context not available.' - elif [ "$HAVE_CACA" = 'yes' ] || [ "$HAVE_SIXEL" = 'yes' ]; then - die : 'Notice: Hardware rendering context not available.' else + if [ "$HAVE_CACA" != 'yes' ] && [ "$HAVE_SIXEL" != 'yes' ] && + [ "$HAVE_SDL" != 'yes' ] && [ "$HAVE_SDL2" != 'yes' ]; then + HAVE_RGUI=no + fi HAVE_MATERIALUI=no + HAVE_OZONE=no HAVE_XMB=no + HAVE_NUKLEAR=no HAVE_STRIPES=no HAVE_ZARCH=no - HAVE_OZONE=no - die : 'Notice: Hardware rendering context not available, XMB, MaterialUI, Ozone and ZARCH will also be disabled.' fi + die : 'Notice: Hardware rendering context not available.' fi fi diff --git a/qb/config.params.sh b/qb/config.params.sh index bf62a58029..d1b178569a 100644 --- a/qb/config.params.sh +++ b/qb/config.params.sh @@ -7,7 +7,8 @@ HAVE_OPENGLES_CFLAGS= # C-flags for custom GLES library HAVE_CACA=no # Libcaca support HAVE_SIXEL=no # Libsixel support HAVE_LIBRETRODB=yes # Libretrodb support -HAVE_RGUI=yes # RGUI menu +HAVE_MENU=yes # Enable menu drivers +HAVE_RGUI=auto # RGUI menu HAVE_MATERIALUI=auto # MaterialUI menu HAVE_XMB=auto # XMB menu HAVE_OZONE=auto # Ozone menu @@ -34,7 +35,7 @@ HAVE_THREADS=auto # Threading support HAVE_THREAD_STORAGE=auto # Thread Local Storage support HAVE_FFMPEG=auto # FFmpeg support C89_FFMPEG=no -HAVE_MPV=auto # MPV support +HAVE_MPV=no # MPV support HAVE_SSA=auto # SSA/ASS for FFmpeg subtitle support HAVE_DYLIB=auto # Dynamic loading support HAVE_NETWORKING=auto # Networking features (recommended) @@ -117,7 +118,7 @@ C89_QT=no HAVE_XSHM=no # XShm video driver support HAVE_CHEEVOS=yes # Retro Achievements C89_CHEEVOS=no -HAVE_LUA=yes # Lua support (for Retro Achievements) +HAVE_LUA=no # Lua support (for Retro Achievements) HAVE_DISCORD=yes # Discord Integration C89_DISCORD=no HAVE_SHADERPIPELINE=yes # Additional shader-based pipelines @@ -134,3 +135,5 @@ HAVE_LANGEXTRA=yes # Multi-language support HAVE_OSMESA=no # Off-screen Mesa rendering HAVE_VIDEOPROCESSOR=auto # Enable video processor core HAVE_VIDEOCORE=auto # Broadcom Videocore 4 support +HAVE_DRMINGW=no # DrMingw exception handler +HAVE_EASTEREGG=yes # Easter egg diff --git a/qb/qb.libs.sh b/qb/qb.libs.sh index 9ea78a7c1e..0ecc808080 100644 --- a/qb/qb.libs.sh +++ b/qb/qb.libs.sh @@ -242,8 +242,21 @@ create_config_make() printf %s\\n "Creating make config: $outfile" - { [ "$HAVE_CC" = 'yes' ] && printf %s\\n "CC = $CC" "CFLAGS = $CFLAGS" - [ "$HAVE_CXX" = 'yes' ] && printf %s\\n "CXX = $CXX" "CXXFLAGS = $CXXFLAGS" + { if [ "$HAVE_CC" = 'yes' ]; then + printf %s\\n "CC = $CC" + + if [ "${CFLAGS}" ]; then + printf %s\\n "CFLAGS = $CFLAGS" + fi + fi + + if [ "$HAVE_CXX" = 'yes' ]; then + printf %s\\n "CXX = $CXX" + + if [ "${CXXFLAGS}" ]; then + printf %s\\n "CXXFLAGS = $CXXFLAGS" + fi + fi printf %s\\n "WINDRES = $WINDRES" \ "MOC = $MOC" \ diff --git a/record/record_driver.c b/record/record_driver.c index e92f0d8724..d65700b9ea 100644 --- a/record/record_driver.c +++ b/record/record_driver.c @@ -155,7 +155,6 @@ const record_driver_t *ffemu_find_backend(const char *ident) return NULL; } - /** * gfx_ctx_init_first: * @backend : Recording backend handle. diff --git a/retroarch.c b/retroarch.c index 910ae5a4a4..410e284f35 100644 --- a/retroarch.c +++ b/retroarch.c @@ -23,6 +23,9 @@ #define WIN32_LEAN_AND_MEAN #include #endif +#if defined(DEBUG) && defined(HAVE_DRMINGW) +#include "exchndl.h" +#endif #endif #include @@ -55,10 +58,6 @@ #include "config.h" #endif -#ifdef HAVE_COMMAND -#include "command.h" -#endif - #ifdef HAVE_MENU #include "menu/menu_driver.h" #include "menu/menu_input.h" @@ -87,6 +86,7 @@ #endif #include "autosave.h" +#include "command.h" #include "config.features.h" #include "content.h" #include "core_type.h" @@ -120,8 +120,6 @@ #include "retroarch.h" -#include "command.h" - #ifdef HAVE_RUNAHEAD #include "runahead/run_ahead.h" #endif @@ -276,6 +274,8 @@ static retro_time_t frame_limit_last_time = 0.0; extern bool input_driver_flushing_input; +static char launch_arguments[4096]; + #ifdef HAVE_DYNAMIC bool retroarch_core_set_on_cmdline(void) { @@ -341,7 +341,6 @@ static void retroarch_override_setting_free_state(void) } } - static void global_free(void) { global_t *global = NULL; @@ -635,6 +634,7 @@ static void retroarch_parse_input_and_config(int argc, char *argv[]) { const char *optstring = NULL; bool explicit_menu = false; + unsigned i; global_t *global = global_get_ptr(); const struct option opts[] = { @@ -687,6 +687,14 @@ static void retroarch_parse_input_and_config(int argc, char *argv[]) { NULL, 0, NULL, 0 } }; + /* Copy the args into a buffer so launch arguments can be reused */ + for (i = 0; i < (unsigned)argc; i++) + { + strlcat(launch_arguments, argv[i], sizeof(launch_arguments)); + strlcat(launch_arguments, " ", sizeof(launch_arguments)); + } + string_trim_whitespace_left(launch_arguments); + /* Handling the core type is finicky. Based on the arguments we pass in, * we handle it differently. * Some current cases which track desired behavior and how it is supposed to work: @@ -747,52 +755,55 @@ static void retroarch_parse_input_and_config(int argc, char *argv[]) /* First pass: Read the config file path and any directory overrides, so * they're in place when we load the config */ - for (;;) + if (argc) { - int c = getopt_long(argc, argv, optstring, opts, NULL); + for (;;) + { + int c = getopt_long(argc, argv, optstring, opts, NULL); #if 0 - fprintf(stderr, "c is: %c (%d), optarg is: [%s]\n", c, c, string_is_empty(optarg) ? "" : optarg); + fprintf(stderr, "c is: %c (%d), optarg is: [%s]\n", c, c, string_is_empty(optarg) ? "" : optarg); #endif - if (c == -1) - break; - - switch (c) - { - case 'h': - retroarch_print_help(argv[0]); - exit(0); - - case 'c': - RARCH_LOG("Set config file to : %s\n", optarg); - path_set(RARCH_PATH_CONFIG, optarg); + if (c == -1) break; - case RA_OPT_APPENDCONFIG: - path_set(RARCH_PATH_CONFIG_APPEND, optarg); - break; + switch (c) + { + case 'h': + retroarch_print_help(argv[0]); + exit(0); - case 's': - strlcpy(global->name.savefile, optarg, - sizeof(global->name.savefile)); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_SAVE_PATH, NULL); - break; + case 'c': + RARCH_LOG("Set config file to : %s\n", optarg); + path_set(RARCH_PATH_CONFIG, optarg); + break; - case 'S': - strlcpy(global->name.savestate, optarg, - sizeof(global->name.savestate)); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_STATE_PATH, NULL); - break; + case RA_OPT_APPENDCONFIG: + path_set(RARCH_PATH_CONFIG_APPEND, optarg); + break; - /* Must handle '?' otherwise you get an infinite loop */ - case '?': - retroarch_print_help(argv[0]); - retroarch_fail(1, "retroarch_parse_input()"); - break; - /* All other arguments are handled in the second pass */ + case 's': + strlcpy(global->name.savefile, optarg, + sizeof(global->name.savefile)); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_SAVE_PATH, NULL); + break; + + case 'S': + strlcpy(global->name.savestate, optarg, + sizeof(global->name.savestate)); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_STATE_PATH, NULL); + break; + + /* Must handle '?' otherwise you get an infinite loop */ + case '?': + retroarch_print_help(argv[0]); + retroarch_fail(1, "retroarch_parse_input()"); + break; + /* All other arguments are handled in the second pass */ + } } } @@ -801,346 +812,350 @@ static void retroarch_parse_input_and_config(int argc, char *argv[]) /* Second pass: All other arguments override the config file */ optind = 1; - for (;;) + + if (argc) { - int c = getopt_long(argc, argv, optstring, opts, NULL); - - if (c == -1) - break; - - switch (c) + for (;;) { - case 'd': - { - unsigned new_port; - unsigned id = 0; - struct string_list *list = string_split(optarg, ":"); - int port = 0; + int c = getopt_long(argc, argv, optstring, opts, NULL); - if (list && list->size == 2) + if (c == -1) + break; + + switch (c) + { + case 'd': { - port = (int)strtol(list->elems[0].data, NULL, 0); - id = (unsigned)strtoul(list->elems[1].data, NULL, 0); + unsigned new_port; + unsigned id = 0; + struct string_list *list = string_split(optarg, ":"); + int port = 0; + + if (list && list->size == 2) + { + port = (int)strtol(list->elems[0].data, NULL, 0); + id = (unsigned)strtoul(list->elems[1].data, NULL, 0); + } + string_list_free(list); + + if (port < 1 || port > MAX_USERS) + { + RARCH_ERR("%s\n", msg_hash_to_str(MSG_VALUE_CONNECT_DEVICE_FROM_A_VALID_PORT)); + retroarch_print_help(argv[0]); + retroarch_fail(1, "retroarch_parse_input()"); + } + new_port = port -1; + + input_config_set_device(new_port, id); + + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); } - string_list_free(list); + break; - if (port < 1 || port > MAX_USERS) + case 'A': { - RARCH_ERR("%s\n", msg_hash_to_str(MSG_VALUE_CONNECT_DEVICE_FROM_A_VALID_PORT)); + unsigned new_port; + int port = (int)strtol(optarg, NULL, 0); + + if (port < 1 || port > MAX_USERS) + { + RARCH_ERR("Connect dualanalog to a valid port.\n"); + retroarch_print_help(argv[0]); + retroarch_fail(1, "retroarch_parse_input()"); + } + new_port = port - 1; + + input_config_set_device(new_port, RETRO_DEVICE_ANALOG); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); + } + break; + + case 'f': + rarch_force_fullscreen = true; + break; + + case 'v': + verbosity_enable(); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_VERBOSITY, NULL); + break; + + case 'N': + { + unsigned new_port; + int port = (int)strtol(optarg, NULL, 0); + + if (port < 1 || port > MAX_USERS) + { + RARCH_ERR("%s\n", + msg_hash_to_str(MSG_DISCONNECT_DEVICE_FROM_A_VALID_PORT)); + retroarch_print_help(argv[0]); + retroarch_fail(1, "retroarch_parse_input()"); + } + new_port = port - 1; + input_config_set_device(port - 1, RETRO_DEVICE_NONE); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); + } + break; + + case 'r': + strlcpy(global->record.path, optarg, + sizeof(global->record.path)); + if (recording_is_enabled()) + recording_set_state(true); + break; + + #ifdef HAVE_DYNAMIC + case 'L': + if (path_is_directory(optarg)) + { + settings_t *settings = config_get_ptr(); + + if (rarch_first_start) + core_set_on_cmdline = true; + + path_clear(RARCH_PATH_CORE); + strlcpy(settings->paths.directory_libretro, optarg, + sizeof(settings->paths.directory_libretro)); + + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO, NULL); + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO_DIRECTORY, NULL); + RARCH_WARN("Using old --libretro behavior. " + "Setting libretro_directory to \"%s\" instead.\n", + optarg); + } + else if (filestream_exists(optarg)) + { + if (rarch_first_start) + core_set_on_cmdline = true; + + rarch_ctl(RARCH_CTL_SET_LIBRETRO_PATH, optarg); + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO, NULL); + + /* We requested explicit core, so use PLAIN core type. */ + retroarch_set_current_core_type(CORE_TYPE_PLAIN, false); + } + else + { + RARCH_WARN("--libretro argument \"%s\" is neither a file nor directory. Ignoring.\n", + optarg); + } + + break; + #endif + case 'P': + case 'R': + bsv_movie_set_start_path(optarg); + + if (c == 'P') + bsv_movie_ctl(BSV_MOVIE_CTL_SET_START_PLAYBACK, NULL); + else + bsv_movie_ctl(BSV_MOVIE_CTL_UNSET_START_PLAYBACK, NULL); + + if (c == 'R') + bsv_movie_ctl(BSV_MOVIE_CTL_SET_START_RECORDING, NULL); + else + bsv_movie_ctl(BSV_MOVIE_CTL_UNSET_START_RECORDING, NULL); + break; + + case 'M': + if (string_is_equal(optarg, "noload-nosave")) + { + rarch_is_sram_load_disabled = true; + rarch_is_sram_save_disabled = true; + } + else if (string_is_equal(optarg, "noload-save")) + rarch_is_sram_load_disabled = true; + else if (string_is_equal(optarg, "load-nosave")) + rarch_is_sram_save_disabled = true; + else if (string_is_not_equal(optarg, "load-save")) + { + RARCH_ERR("Invalid argument in --sram-mode.\n"); retroarch_print_help(argv[0]); retroarch_fail(1, "retroarch_parse_input()"); } - new_port = port -1; + break; - input_config_set_device(new_port, id); - - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); - } - break; - - case 'A': - { - unsigned new_port; - int port = (int)strtol(optarg, NULL, 0); - - if (port < 1 || port > MAX_USERS) - { - RARCH_ERR("Connect dualanalog to a valid port.\n"); - retroarch_print_help(argv[0]); - retroarch_fail(1, "retroarch_parse_input()"); - } - new_port = port - 1; - - input_config_set_device(new_port, RETRO_DEVICE_ANALOG); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); - } - break; - - case 'f': - rarch_force_fullscreen = true; - break; - - case 'v': - verbosity_enable(); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_VERBOSITY, NULL); - break; - - case 'N': - { - unsigned new_port; - int port = (int)strtol(optarg, NULL, 0); - - if (port < 1 || port > MAX_USERS) - { - RARCH_ERR("%s\n", - msg_hash_to_str(MSG_DISCONNECT_DEVICE_FROM_A_VALID_PORT)); - retroarch_print_help(argv[0]); - retroarch_fail(1, "retroarch_parse_input()"); - } - new_port = port - 1; - input_config_set_device(port - 1, RETRO_DEVICE_NONE); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_LIBRETRO_DEVICE, &new_port); - } - break; - - case 'r': - strlcpy(global->record.path, optarg, - sizeof(global->record.path)); - if (recording_is_enabled()) - recording_set_state(true); - break; - -#ifdef HAVE_DYNAMIC - case 'L': - if (path_is_directory(optarg)) - { - settings_t *settings = config_get_ptr(); - - if (rarch_first_start) - core_set_on_cmdline = true; - - path_clear(RARCH_PATH_CORE); - strlcpy(settings->paths.directory_libretro, optarg, - sizeof(settings->paths.directory_libretro)); - - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO, NULL); - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO_DIRECTORY, NULL); - RARCH_WARN("Using old --libretro behavior. " - "Setting libretro_directory to \"%s\" instead.\n", - optarg); - } - else if (filestream_exists(optarg)) - { - if (rarch_first_start) - core_set_on_cmdline = true; - - rarch_ctl(RARCH_CTL_SET_LIBRETRO_PATH, optarg); - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO, NULL); - - /* We requested explicit core, so use PLAIN core type. */ - retroarch_set_current_core_type(CORE_TYPE_PLAIN, false); - } - else - { - RARCH_WARN("--libretro argument \"%s\" is neither a file nor directory. Ignoring.\n", - optarg); - } - - break; -#endif - case 'P': - case 'R': - bsv_movie_set_start_path(optarg); - - if (c == 'P') - bsv_movie_ctl(BSV_MOVIE_CTL_SET_START_PLAYBACK, NULL); - else - bsv_movie_ctl(BSV_MOVIE_CTL_UNSET_START_PLAYBACK, NULL); - - if (c == 'R') - bsv_movie_ctl(BSV_MOVIE_CTL_SET_START_RECORDING, NULL); - else - bsv_movie_ctl(BSV_MOVIE_CTL_UNSET_START_RECORDING, NULL); - break; - - case 'M': - if (string_is_equal(optarg, "noload-nosave")) - { - rarch_is_sram_load_disabled = true; - rarch_is_sram_save_disabled = true; - } - else if (string_is_equal(optarg, "noload-save")) - rarch_is_sram_load_disabled = true; - else if (string_is_equal(optarg, "load-nosave")) - rarch_is_sram_save_disabled = true; - else if (string_is_not_equal(optarg, "load-save")) - { - RARCH_ERR("Invalid argument in --sram-mode.\n"); - retroarch_print_help(argv[0]); - retroarch_fail(1, "retroarch_parse_input()"); - } - break; - -#ifdef HAVE_NETWORKING - case 'H': - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_NETPLAY_MODE, NULL); - netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_SERVER, NULL); - break; - - case 'C': - { - settings_t *settings = config_get_ptr(); + #ifdef HAVE_NETWORKING + case 'H': retroarch_override_setting_set( RARCH_OVERRIDE_SETTING_NETPLAY_MODE, NULL); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_NETPLAY_IP_ADDRESS, NULL); - netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_CLIENT, NULL); - strlcpy(settings->paths.netplay_server, optarg, - sizeof(settings->paths.netplay_server)); - } - break; + netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_SERVER, NULL); + break; - case RA_OPT_STATELESS: - { - settings_t *settings = config_get_ptr(); + case 'C': + { + settings_t *settings = config_get_ptr(); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_NETPLAY_MODE, NULL); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_NETPLAY_IP_ADDRESS, NULL); + netplay_driver_ctl(RARCH_NETPLAY_CTL_ENABLE_CLIENT, NULL); + strlcpy(settings->paths.netplay_server, optarg, + sizeof(settings->paths.netplay_server)); + } + break; - configuration_set_bool(settings, - settings->bools.netplay_stateless_mode, true); + case RA_OPT_STATELESS: + { + settings_t *settings = config_get_ptr(); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_NETPLAY_STATELESS_MODE, NULL); - } - break; + configuration_set_bool(settings, + settings->bools.netplay_stateless_mode, true); - case RA_OPT_CHECK_FRAMES: - { - settings_t *settings = config_get_ptr(); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_NETPLAY_CHECK_FRAMES, NULL); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_NETPLAY_STATELESS_MODE, NULL); + } + break; - configuration_set_int(settings, - settings->ints.netplay_check_frames, - (int)strtoul(optarg, NULL, 0)); - } - break; + case RA_OPT_CHECK_FRAMES: + { + settings_t *settings = config_get_ptr(); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_NETPLAY_CHECK_FRAMES, NULL); - case RA_OPT_PORT: - { - settings_t *settings = config_get_ptr(); - retroarch_override_setting_set( - RARCH_OVERRIDE_SETTING_NETPLAY_IP_PORT, NULL); - configuration_set_uint(settings, - settings->uints.netplay_port, - (int)strtoul(optarg, NULL, 0)); - } - break; + configuration_set_int(settings, + settings->ints.netplay_check_frames, + (int)strtoul(optarg, NULL, 0)); + } + break; -#if defined(HAVE_NETWORK_CMD) - case RA_OPT_COMMAND: -#ifdef HAVE_COMMAND - if (command_network_send((const char*)optarg)) + case RA_OPT_PORT: + { + settings_t *settings = config_get_ptr(); + retroarch_override_setting_set( + RARCH_OVERRIDE_SETTING_NETPLAY_IP_PORT, NULL); + configuration_set_uint(settings, + settings->uints.netplay_port, + (int)strtoul(optarg, NULL, 0)); + } + break; + + #if defined(HAVE_NETWORK_CMD) + case RA_OPT_COMMAND: + #ifdef HAVE_COMMAND + if (command_network_send((const char*)optarg)) + exit(0); + else + retroarch_fail(1, "network_cmd_send()"); + #endif + break; + #endif + + #endif + + case RA_OPT_BPS: + strlcpy(global->name.bps, optarg, + sizeof(global->name.bps)); + rarch_bps_pref = true; + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_BPS_PREF, NULL); + break; + + case 'U': + strlcpy(global->name.ups, optarg, + sizeof(global->name.ups)); + rarch_ups_pref = true; + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_UPS_PREF, NULL); + break; + + case RA_OPT_IPS: + strlcpy(global->name.ips, optarg, + sizeof(global->name.ips)); + rarch_ips_pref = true; + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_IPS_PREF, NULL); + break; + + case RA_OPT_NO_PATCH: + rarch_ctl(RARCH_CTL_SET_PATCH_BLOCKED, NULL); + break; + + case 'D': + frontend_driver_detach_console(); + break; + + case RA_OPT_MENU: + explicit_menu = true; + break; + + case RA_OPT_NICK: + { + settings_t *settings = config_get_ptr(); + + has_set_username = true; + + strlcpy(settings->paths.username, optarg, + sizeof(settings->paths.username)); + } + break; + + case RA_OPT_SIZE: + if (sscanf(optarg, "%ux%u", + recording_driver_get_width(), + recording_driver_get_height()) != 2) + { + RARCH_ERR("Wrong format for --size.\n"); + retroarch_print_help(argv[0]); + retroarch_fail(1, "retroarch_parse_input()"); + } + break; + + case RA_OPT_RECORDCONFIG: + strlcpy(global->record.config, optarg, + sizeof(global->record.config)); + break; + + case RA_OPT_MAX_FRAMES: + runloop_max_frames = (unsigned)strtoul(optarg, NULL, 10); + break; + + case RA_OPT_MAX_FRAMES_SCREENSHOT: + runloop_max_frames_screenshot = true; + break; + + case RA_OPT_MAX_FRAMES_SCREENSHOT_PATH: + strlcpy(runloop_max_frames_screenshot_path, optarg, sizeof(runloop_max_frames_screenshot_path)); + break; + + case RA_OPT_SUBSYSTEM: + path_set(RARCH_PATH_SUBSYSTEM, optarg); + break; + + case RA_OPT_FEATURES: + retroarch_print_features(); exit(0); - else - retroarch_fail(1, "network_cmd_send()"); -#endif - break; -#endif -#endif + case RA_OPT_EOF_EXIT: + bsv_movie_ctl(BSV_MOVIE_CTL_SET_END_EOF, NULL); + break; - case RA_OPT_BPS: - strlcpy(global->name.bps, optarg, - sizeof(global->name.bps)); - rarch_bps_pref = true; - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_BPS_PREF, NULL); - break; + case RA_OPT_VERSION: + retroarch_print_version(); + exit(0); - case 'U': - strlcpy(global->name.ups, optarg, - sizeof(global->name.ups)); - rarch_ups_pref = true; - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_UPS_PREF, NULL); - break; + #ifdef HAVE_FILE_LOGGER + case RA_OPT_LOG_FILE: + retro_main_log_file_init(optarg); + break; + #endif - case RA_OPT_IPS: - strlcpy(global->name.ips, optarg, - sizeof(global->name.ips)); - rarch_ips_pref = true; - retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_IPS_PREF, NULL); - break; + case 'c': + case 'h': + case RA_OPT_APPENDCONFIG: + case 's': + case 'S': + break; /* Handled in the first pass */ - case RA_OPT_NO_PATCH: - rarch_ctl(RARCH_CTL_SET_PATCH_BLOCKED, NULL); - break; - - case 'D': - frontend_driver_detach_console(); - break; - - case RA_OPT_MENU: - explicit_menu = true; - break; - - case RA_OPT_NICK: - { - settings_t *settings = config_get_ptr(); - - has_set_username = true; - - strlcpy(settings->paths.username, optarg, - sizeof(settings->paths.username)); - } - break; - - case RA_OPT_SIZE: - if (sscanf(optarg, "%ux%u", - recording_driver_get_width(), - recording_driver_get_height()) != 2) - { - RARCH_ERR("Wrong format for --size.\n"); + case '?': retroarch_print_help(argv[0]); retroarch_fail(1, "retroarch_parse_input()"); - } - break; - case RA_OPT_RECORDCONFIG: - strlcpy(global->record.config, optarg, - sizeof(global->record.config)); - break; - - case RA_OPT_MAX_FRAMES: - runloop_max_frames = (unsigned)strtoul(optarg, NULL, 10); - break; - - case RA_OPT_MAX_FRAMES_SCREENSHOT: - runloop_max_frames_screenshot = true; - break; - - case RA_OPT_MAX_FRAMES_SCREENSHOT_PATH: - strlcpy(runloop_max_frames_screenshot_path, optarg, sizeof(runloop_max_frames_screenshot_path)); - break; - - case RA_OPT_SUBSYSTEM: - path_set(RARCH_PATH_SUBSYSTEM, optarg); - break; - - case RA_OPT_FEATURES: - retroarch_print_features(); - exit(0); - - case RA_OPT_EOF_EXIT: - bsv_movie_ctl(BSV_MOVIE_CTL_SET_END_EOF, NULL); - break; - - case RA_OPT_VERSION: - retroarch_print_version(); - exit(0); - -#ifdef HAVE_FILE_LOGGER - case RA_OPT_LOG_FILE: - retro_main_log_file_init(optarg); - break; -#endif - - case 'c': - case 'h': - case RA_OPT_APPENDCONFIG: - case 's': - case 'S': - break; /* Handled in the first pass */ - - case '?': - retroarch_print_help(argv[0]); - retroarch_fail(1, "retroarch_parse_input()"); - - default: - RARCH_ERR("%s\n", msg_hash_to_str(MSG_ERROR_PARSING_ARGUMENTS)); - retroarch_fail(1, "retroarch_parse_input()"); + default: + RARCH_ERR("%s\n", msg_hash_to_str(MSG_ERROR_PARSING_ARGUMENTS)); + retroarch_fail(1, "retroarch_parse_input()"); + } } } @@ -1260,7 +1275,7 @@ static void retroarch_validate_cpu_features(void) static void retroarch_main_init_media(void) { - settings_t *settings = config_get_ptr(); + settings_t *settings = config_get_ptr(); const char *fullpath = path_get(RARCH_PATH_CONTENT); bool builtin_imageviewer = false; bool builtin_mediaplayer = false; @@ -1301,6 +1316,12 @@ static void retroarch_main_init_media(void) retroarch_set_current_core_type(CORE_TYPE_IMAGEVIEWER, false); } break; +#endif +#ifdef HAVE_EASTEREGG + case RARCH_CONTENT_GONG: + retroarch_override_setting_set(RARCH_OVERRIDE_SETTING_LIBRETRO, NULL); + retroarch_set_current_core_type(CORE_TYPE_GONG, false); + break; #endif default: break; @@ -1321,6 +1342,10 @@ bool retroarch_main_init(int argc, char *argv[]) bool init_failed = false; global_t *global = global_get_ptr(); +#if defined(DEBUG) && defined(HAVE_DRMINGW) + char log_file_name[128]; +#endif + retroarch_init_state(); if (setjmp(error_sjlj_context) > 0) @@ -1339,7 +1364,6 @@ bool retroarch_main_init(int argc, char *argv[]) if (verbosity_is_enabled()) { char str[128]; - str[0] = '\0'; RARCH_LOG_OUTPUT("=== Build =======================================\n"); @@ -1353,6 +1377,14 @@ bool retroarch_main_init(int argc, char *argv[]) RARCH_LOG_OUTPUT("=================================================\n"); } +#if defined(DEBUG) && defined(HAVE_DRMINGW) + RARCH_LOG("Initializing Dr.MingW Exception handler\n"); + fill_str_dated_filename(log_file_name, "crash", + "log", sizeof(log_file_name)); + ExcHndlInit(); + ExcHndlSetLogFileNameA(log_file_name); +#endif + retroarch_validate_cpu_features(); rarch_ctl(RARCH_CTL_TASK_INIT, NULL); @@ -2387,7 +2419,6 @@ global_t *global_get_ptr(void) return &g_extern; } - void runloop_msg_queue_push(const char *msg, unsigned prio, unsigned duration, bool flush) @@ -2420,7 +2451,6 @@ void runloop_msg_queue_push(const char *msg, #endif } - void runloop_get_status(bool *is_paused, bool *is_idle, bool *is_slowmotion, bool *is_perfcnt_enable) { @@ -2570,6 +2600,9 @@ static enum runloop_state runloop_check_state( #ifdef HAVE_MENU bool menu_driver_binding_state = menu_driver_is_binding_state(); bool menu_is_alive = menu_driver_is_alive(); +#ifdef HAVE_EASTEREGG + static uint64_t seq = 0; +#endif #endif #ifdef HAVE_LIBNX @@ -2671,7 +2704,6 @@ static enum runloop_state runloop_check_state( old_pressed = pressed; } - #ifdef HAVE_OVERLAY { static char prev_overlay_restore = false; @@ -2770,7 +2802,6 @@ static enum runloop_state runloop_check_state( retro_ctx.poll_cb(); - { enum menu_action action; bool focused = false; @@ -2840,6 +2871,32 @@ static enum runloop_state runloop_check_state( if (settings->bools.audio_enable_menu && !libretro_running) audio_driver_menu_sample(); + +#ifdef HAVE_EASTEREGG + { + if (string_is_empty(runloop_system.info.library_name) && trigger_input.data[0]) + { + seq |= trigger_input.data[0] & 0xF0; + + if (seq == 1157460427127406720ULL) + { + content_ctx_info_t content_info; + content_info.argc = 0; + content_info.argv = NULL; + content_info.args = NULL; + content_info.environ_get = NULL; + + task_push_start_builtin_core( + &content_info, + CORE_TYPE_GONG, NULL, NULL); + } + + seq <<= 8; + } + else if (!string_is_empty(runloop_system.info.library_name)) + seq = 0; + } +#endif } old_input = current_input; @@ -2856,9 +2913,14 @@ static enum runloop_state runloop_check_state( return RUNLOOP_STATE_POLLED_AND_SLEEP; } else +#endif + { +#if defined(HAVE_MENU) && defined(HAVE_EASTEREGG) + seq = 0; #endif if (runloop_idle) return RUNLOOP_STATE_SLEEP; + } /* Check game focus toggle */ { @@ -2890,8 +2952,10 @@ static enum runloop_state runloop_check_state( /* Check menu toggle */ { static bool old_pressed = false; + char *menu_driver = settings->arrays.menu_driver; bool pressed = BIT256_GET( - current_input, RARCH_MENU_TOGGLE); + current_input, RARCH_MENU_TOGGLE) && + !string_is_equal(menu_driver, "null"); if (menu_event_kb_is_set(RETROK_F1) == 1) { @@ -3481,7 +3545,6 @@ int runloop_iterate(unsigned *sleep_ms) input_nonblock_state) | !!recording_data; - if (!runloop_frame_time_last || is_locked_fps) delta = runloop_frame_time.reference; @@ -3658,3 +3721,8 @@ struct retro_system_info *runloop_get_libretro_system_info(void) struct retro_system_info *system = &runloop_system.info; return system; } + +char *get_retroarch_launch_arguments(void) +{ + return launch_arguments; +} diff --git a/retroarch.h b/retroarch.h index 50f481ea6c..033b1a1d2e 100644 --- a/retroarch.h +++ b/retroarch.h @@ -35,7 +35,6 @@ RETRO_BEGIN_DECLS #define RETRO_ENVIRONMENT_RETROARCH_START_BLOCK 0x800000 - #define RETRO_ENVIRONMENT_SET_SAVE_STATE_IN_BACKGROUND (2 | RETRO_ENVIRONMENT_RETROARCH_START_BLOCK) /* bool * -- * Boolean value that tells the front end to save states in the @@ -391,6 +390,8 @@ void rarch_menu_running_finished(void); bool retroarch_is_on_main_thread(void); +char *get_retroarch_launch_arguments(void); + rarch_system_info_t *runloop_get_system_info(void); struct retro_system_info *runloop_get_libretro_system_info(void); diff --git a/runahead/run_ahead.c b/runahead/run_ahead.c index f5ce38b51c..faa7985f90 100644 --- a/runahead/run_ahead.c +++ b/runahead/run_ahead.c @@ -130,7 +130,6 @@ static void unload_hook(void) current_core.retro_unload_game(); } - static void deinit_hook(void) { remove_hooks(); @@ -156,7 +155,6 @@ static void add_hooks(void) add_input_state_hook(); } - /* Runahead Code */ static bool runahead_video_driver_is_active = true; @@ -184,7 +182,6 @@ static uint64_t runahead_get_frame_count() return frame_count; } - static void runahead_check_for_gui(void) { /* Hack: If we were in the GUI, force a resync. */ @@ -467,7 +464,6 @@ void runahead_destroy(void) static bool request_fast_savestate; static bool hard_disable_audio; - bool want_fast_savestate(void) { return request_fast_savestate; diff --git a/runahead/secondary_core.c b/runahead/secondary_core.c index 02d708e736..f1f51c81f2 100644 --- a/runahead/secondary_core.c +++ b/runahead/secondary_core.c @@ -324,7 +324,6 @@ static bool secondary_core_create(void) return true; } - void secondary_core_set_variable_update(void) { has_variable_update = true; diff --git a/setting_list.c b/setting_list.c index f62df7c389..71e7b04b56 100644 --- a/setting_list.c +++ b/setting_list.c @@ -348,7 +348,6 @@ int setting_uint_action_left_with_refresh(rarch_setting_t *setting, bool wraparo } - static int setting_size_action_left_default(rarch_setting_t *setting, bool wraparound) { double min = 0.0f; @@ -717,7 +716,6 @@ static void setting_get_string_representation_st_bool(rarch_setting_t *setting, setting->boolean.off_label, len); } - /** * setting_get_string_representation_st_float: * @setting : pointer to setting @@ -790,7 +788,6 @@ static int setting_action_action_ok(rarch_setting_t *setting, bool wraparound) return 0; } - /** * setting_action_setting: * @name : Name of setting. diff --git a/tasks/task_audio_mixer.c b/tasks/task_audio_mixer.c index 833412fd78..9f43692f14 100644 --- a/tasks/task_audio_mixer.c +++ b/tasks/task_audio_mixer.c @@ -367,7 +367,6 @@ bool task_audio_mixer_load_handler(retro_task_t *task) image->copy_data_over = false; image->is_finished = true; - return false; } diff --git a/tasks/task_autodetect.c b/tasks/task_autodetect.c index 00bb990b85..72c494285d 100644 --- a/tasks/task_autodetect.c +++ b/tasks/task_autodetect.c @@ -303,7 +303,6 @@ static void input_autoconfigure_joypad_add(config_file_t *conf, else input_config_set_device_config_name(params->idx, "N/A"); - input_autoconfigure_joypad_reindex_devices(); } diff --git a/tasks/task_content.c b/tasks/task_content.c index 60e08e11da..da1f02dc9c 100644 --- a/tasks/task_content.c +++ b/tasks/task_content.c @@ -61,9 +61,10 @@ #ifdef HAVE_MENU #include "../menu/menu_driver.h" -#include "../menu/menu_shader.h" #endif +#include "../menu/menu_shader.h" + #ifdef HAVE_CHEEVOS #include "../cheevos/cheevos.h" #endif @@ -152,7 +153,6 @@ static char pending_subsystem_extensions[PATH_MAX_LENGTH]; #endif static char *pending_subsystem_roms[RARCH_MAX_SUBSYSTEM_ROMS]; - static int64_t content_file_read(const char *path, void **buf, int64_t *length) { #ifdef HAVE_COMPRESSION @@ -290,11 +290,8 @@ static bool content_load(content_ctx_info_t *info) content_clear_subsystem(); } - -#ifdef HAVE_MENU - /* TODO/FIXME - can we get rid of this? */ menu_shader_manager_init(); -#endif + command_event(CMD_EVENT_HISTORY_INIT, NULL); command_event(CMD_EVENT_RESUME, NULL); command_event(CMD_EVENT_VIDEO_SET_ASPECT_RATIO, NULL); @@ -832,8 +829,6 @@ static bool content_file_init( return ret; } - -#ifdef HAVE_MENU static void menu_content_environment_get(int *argc, char *argv[], void *args, void *params_data) { @@ -867,7 +862,6 @@ static void menu_content_environment_get(int *argc, char *argv[], path_get(RARCH_PATH_CORE); } -#endif /** * task_load_content: @@ -1115,10 +1109,8 @@ bool task_push_start_dummy_core(content_ctx_info_t *content_info) if (!string_is_empty(settings->paths.directory_system)) content_ctx.directory_system = strdup(settings->paths.directory_system); -#ifdef HAVE_MENU if (!content_info->environ_get) content_info->environ_get = menu_content_environment_get; -#endif /* Clear content path */ path_clear(RARCH_PATH_CONTENT); @@ -1308,10 +1300,8 @@ bool task_push_start_current_core(content_ctx_info_t *content_info) if (!string_is_empty(settings->paths.directory_system)) content_ctx.directory_system = strdup(settings->paths.directory_system); -#ifdef HAVE_MENU if (!content_info->environ_get) content_info->environ_get = menu_content_environment_get; -#endif /* Clear content path */ path_clear(RARCH_PATH_CONTENT); @@ -1560,10 +1550,8 @@ static bool task_load_content_callback(content_ctx_info_t *content_info, if (!string_is_empty(settings->paths.directory_system)) content_ctx.directory_system = strdup(settings->paths.directory_system); -#ifdef HAVE_MENU if (!content_info->environ_get) content_info->environ_get = menu_content_environment_get; -#endif if (firmware_update_status(&content_ctx)) goto end; diff --git a/tasks/task_database.c b/tasks/task_database.c index e7b1fae035..06bc7b0b1e 100644 --- a/tasks/task_database.c +++ b/tasks/task_database.c @@ -1032,7 +1032,6 @@ static int task_database_iterate_playlist_lutro( return 0; } - static int task_database_iterate_serial_lookup( db_handle_t *_db, database_state_handle_t *db_state, diff --git a/tasks/task_decompress.c b/tasks/task_decompress.c index d83cc1d1c7..8b23a74ff8 100644 --- a/tasks/task_decompress.c +++ b/tasks/task_decompress.c @@ -14,7 +14,6 @@ * If not, see . */ - #include #include #include diff --git a/tasks/task_netplay_find_content.c b/tasks/task_netplay_find_content.c index 1f53758d41..c6f8301c10 100644 --- a/tasks/task_netplay_find_content.c +++ b/tasks/task_netplay_find_content.c @@ -120,7 +120,6 @@ static void netplay_crc_scan_callback(void *task_data, 1, 480, true); } - free(state); } diff --git a/tasks/task_patch.c b/tasks/task_patch.c index 469a83e240..5f9b82da12 100644 --- a/tasks/task_patch.c +++ b/tasks/task_patch.c @@ -380,7 +380,6 @@ static enum patch_error ups_apply_patch( while (data.target_offset < data.target_length) ups_target_write(&data, ups_source_read(&data)); - for (i = 0; i < 4; i++) source_read_checksum |= ups_patch_read(&data) << (i * 8); for (i = 0; i < 4; i++) diff --git a/tasks/task_save.c b/tasks/task_save.c index 66bc264055..cb5fe7dee7 100644 --- a/tasks/task_save.c +++ b/tasks/task_save.c @@ -267,7 +267,6 @@ static void autosave_free(autosave_t *handle) handle->buffer = NULL; } - bool autosave_init(void) { unsigned i; @@ -1194,7 +1193,6 @@ bool content_save_state(const char *path, bool save_to_disk, bool autosave) data = get_serialized_data(path, info.size) ; - if (!data) { RARCH_ERR("%s \"%s\".\n", diff --git a/tasks/task_screenshot.c b/tasks/task_screenshot.c index 2ea95618ac..d84167bf00 100644 --- a/tasks/task_screenshot.c +++ b/tasks/task_screenshot.c @@ -195,10 +195,14 @@ static bool screenshot_dump( calloc(1, sizeof(*state)); const char *screenshot_dir = settings->paths.directory_screenshot; char shotname[256]; + struct retro_system_info system_info; shotname[0] = '\0'; screenshot_path[0] = '\0'; + if (!core_get_system_info(&system_info)) + return false; + /* If fullpath is true, name_base already contains a static path + filename to save the screenshot to. */ if (fullpath) strlcpy(state->filename, name_base, sizeof(state->filename)); @@ -232,8 +236,14 @@ static bool screenshot_dump( else { if (settings->bools.auto_screenshot_filename) - fill_str_dated_filename(shotname, path_basename(name_base), - IMG_EXT, sizeof(shotname)); + { + if (path_is_empty(RARCH_PATH_CONTENT)) + fill_str_dated_filename(shotname, system_info.library_name, + IMG_EXT, sizeof(shotname)); + else + fill_str_dated_filename(shotname, path_basename(name_base), + IMG_EXT, sizeof(shotname)); + } else snprintf(shotname, sizeof(shotname), "%s.png", path_basename(name_base)); diff --git a/tasks/tasks_internal.h b/tasks/tasks_internal.h index dbcf0e2963..df6a03fd43 100644 --- a/tasks/tasks_internal.h +++ b/tasks/tasks_internal.h @@ -269,7 +269,6 @@ void set_save_state_in_background(bool state); extern const char* const input_builtin_autoconfs[]; - RETRO_END_DECLS #endif diff --git a/tools/com-parser/Makefile b/tools/com-parser/Makefile index 71ed3df303..b36e8af407 100644 --- a/tools/com-parser/Makefile +++ b/tools/com-parser/Makefile @@ -5,12 +5,9 @@ GENDEPS = 1 TARGET_ARCH = amd64 OS ?= win32 - OBJ := OBJ += com-parse.o - - EXE_EXT := $(suffix $(wildcard $(MAKE).*)) ifeq ($(compiler),) @@ -102,10 +99,8 @@ else endif endif - INCLUDE_DIRS += -I. -I../../deps/peglib - $(info os : $(OS)) $(info host : $(ARCH)) $(info target : $(TARGET_ARCH)) @@ -121,7 +116,6 @@ all: $(TARGET)$(EXE_EXT) SHELL:=$(SHELL) -o pipefail - ifeq ($(GENDEPS),0) DEPFLAGS := MAKEDEPS := @@ -143,7 +137,6 @@ $(TARGET)$(EXE_EXT): $(OBJ) .$(TARGET).last @touch .$(TARGET).last $(LD) $(OBJ) $(LDFLAGS) $(LIBS) $(LD_OUT)$@ - %.depend: ; %.last: ; .FORCE: diff --git a/tools/com-parser/com-parse.cpp b/tools/com-parser/com-parse.cpp index 49abccc6e8..b0dc1dc825 100644 --- a/tools/com-parser/com-parse.cpp +++ b/tools/com-parser/com-parse.cpp @@ -13,7 +13,6 @@ * If not, see . */ - #include #include #include @@ -26,7 +25,6 @@ using namespace std; template AstBase AstBase::empty = AstBase("", 0, 0, "", string("")); - //bool use_typedefs = false; bool use_typedefs = true; @@ -253,7 +251,6 @@ string get_prefix(const string &type) return get_prefix(type.c_str()); } - string clean_name(const char *name) { string str; @@ -567,7 +564,6 @@ public: return out.str(); } - }; class ComHeader { @@ -747,7 +743,6 @@ basic_ostream<_Elem, _Traits> &operator << (basic_ostream<_Elem, _Traits> &ios, return ios << header.str(); } - int main(int argc, const char **argv) { const char *header_fn = argv[1]; @@ -780,6 +775,5 @@ int main(int argc, const char **argv) out << header; out.close(); - return 0; } diff --git a/tools/ps3/ps3py/crypt.c b/tools/ps3/ps3py/crypt.c index 47241f869a..24045b476a 100644 --- a/tools/ps3/ps3py/crypt.c +++ b/tools/ps3/ps3py/crypt.c @@ -123,4 +123,3 @@ PyMODINIT_FUNC initpkgcrypt(void) (void) Py_InitModule("pkgcrypt", cryptMethods); } - diff --git a/ui/drivers/cocoa/cocoa_common.h b/ui/drivers/cocoa/cocoa_common.h index be2aee7595..d95eb64f14 100644 --- a/ui/drivers/cocoa/cocoa_common.h +++ b/ui/drivers/cocoa/cocoa_common.h @@ -35,7 +35,6 @@ #import #endif - /*********************************************/ /* RAMenuBase */ /* A menu class that displays RAMenuItemBase */ diff --git a/ui/drivers/cocoa/cocoa_common_metal.h b/ui/drivers/cocoa/cocoa_common_metal.h index 1be147c5b2..2da8cb03c0 100644 --- a/ui/drivers/cocoa/cocoa_common_metal.h +++ b/ui/drivers/cocoa/cocoa_common_metal.h @@ -75,7 +75,6 @@ extern id apple_platform; #import #endif - /*********************************************/ /* RAMenuBase */ /* A menu class that displays RAMenuItemBase */ diff --git a/ui/drivers/qt/coreoptionsdialog.cpp b/ui/drivers/qt/coreoptionsdialog.cpp index 8841cf05e5..52538435ca 100644 --- a/ui/drivers/qt/coreoptionsdialog.cpp +++ b/ui/drivers/qt/coreoptionsdialog.cpp @@ -139,7 +139,7 @@ void CoreOptionsDialog::onSaveGameSpecificOptions() } } - if (config_file_write(conf, game_path)) + if (config_file_write(conf, game_path, true)) { runloop_msg_queue_push( msg_hash_to_str(MSG_CORE_OPTIONS_FILE_CREATED_SUCCESSFULLY), diff --git a/ui/drivers/qt/filedropwidget.cpp b/ui/drivers/qt/filedropwidget.cpp index a53b588e7e..8a336288b2 100644 --- a/ui/drivers/qt/filedropwidget.cpp +++ b/ui/drivers/qt/filedropwidget.cpp @@ -41,7 +41,12 @@ void FileDropWidget::paintEvent(QPaintEvent *event) void FileDropWidget::keyPressEvent(QKeyEvent *event) { - if (event->key() == Qt::Key_Delete) + if (event->key() == Qt::Key_Return || event->key() == Qt::Key_Enter) + { + event->accept(); + emit enterPressed(); + } + else if (event->key() == Qt::Key_Delete) { event->accept(); emit deletePressed(); diff --git a/ui/drivers/qt/filedropwidget.h b/ui/drivers/qt/filedropwidget.h index 9301d948df..3a5d420e5a 100644 --- a/ui/drivers/qt/filedropwidget.h +++ b/ui/drivers/qt/filedropwidget.h @@ -15,6 +15,7 @@ public: FileDropWidget(QWidget *parent = 0); signals: void filesDropped(QStringList files); + void enterPressed(); void deletePressed(); protected: void dragEnterEvent(QDragEnterEvent *event); diff --git a/ui/drivers/qt/flowlayout.cpp b/ui/drivers/qt/flowlayout.cpp deleted file mode 100644 index b970e10b10..0000000000 --- a/ui/drivers/qt/flowlayout.cpp +++ /dev/null @@ -1,248 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:BSD$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** BSD License Usage -** Alternatively, you may use this file under the terms of the BSD license -** as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of The Qt Company Ltd nor the names of its -** contributors may be used to endorse or promote products derived -** from this software without specific prior written permission. -** -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -/* Original work Copyright (C) 2016 The Qt Company Ltd. - * Modified work Copyright (C) 2018 - Brad Parker - */ - -#include - -#include "flowlayout.h" -#include "../ui_qt.h" - -FlowLayout::FlowLayout(QWidget *parent, int margin, int hSpacing, int vSpacing) - : QLayout(parent), m_hSpace(hSpacing), m_vSpace(vSpacing) -{ - setContentsMargins(margin, margin, margin, margin); - - connect(this, SIGNAL(signalAddWidgetDeferred(QPointer)), this, SLOT(onAddWidgetDeferred(QPointer)), Qt::QueuedConnection); -} - -FlowLayout::FlowLayout(int margin, int hSpacing, int vSpacing) - : m_hSpace(hSpacing), m_vSpace(vSpacing) -{ - setContentsMargins(margin, margin, margin, margin); -} - -FlowLayout::~FlowLayout() -{ - QLayoutItem *item = NULL; - - while ((item = takeAt(0)) != NULL) - delete item; -} - -void FlowLayout::addItem(QLayoutItem *item) -{ - itemList.append(item); -} - -int FlowLayout::horizontalSpacing() const -{ - if (m_hSpace >= 0) - return m_hSpace; - else - return smartSpacing(QStyle::PM_LayoutHorizontalSpacing); -} - -int FlowLayout::verticalSpacing() const -{ - if (m_vSpace >= 0) - return m_vSpace; - else - return smartSpacing(QStyle::PM_LayoutVerticalSpacing); -} - -int FlowLayout::count() const -{ - return itemList.size(); -} - -QLayoutItem* FlowLayout::itemAt(int index) const -{ - return itemList.value(index); -} - -QLayoutItem* FlowLayout::takeAt(int index) -{ - if (index >= 0 && index < itemList.size()) - return itemList.takeAt(index); - else - return NULL; -} - -Qt::Orientations FlowLayout::expandingDirections() const -{ - return 0; -} - -bool FlowLayout::hasHeightForWidth() const -{ - return true; -} - -int FlowLayout::heightForWidth(int width) const -{ - int height = doLayout(QRect(0, 0, width, 0), true); - return height; -} - -void FlowLayout::setGeometry(const QRect &rect) -{ - QLayout::setGeometry(rect); - doLayout(rect, false); -} - -QSize FlowLayout::sizeHint() const -{ - return minimumSize(); -} - -QSize FlowLayout::minimumSize() const -{ - QSize size; - int i = 0; - - if (itemList.isEmpty()) - return size; - - for (i = 0; i < itemList.count(); i++) - { - const QLayoutItem *item = itemList.at(i); - size = size.expandedTo(item->minimumSize()); - } - - size += QSize(2 * margin(), 2 * margin()); - return size; -} - -int FlowLayout::doLayout(const QRect &rect, bool testOnly) const -{ - QRect effectiveRect; - int left = 0, top = 0, right = 0, bottom = 0; - int x = 0; - int y = 0; - int lineHeight = 0; - int i = 0; - - getContentsMargins(&left, &top, &right, &bottom); - effectiveRect = rect.adjusted(+left, +top, -right, -bottom); - x = effectiveRect.x(); - y = effectiveRect.y(); - - if (itemList.isEmpty()) - return y + lineHeight - rect.y() + bottom; - - for (i = 0; i < itemList.count(); i++) - { - QLayoutItem *item = itemList.at(i); - const QWidget *wid = item->widget(); - int spaceX = horizontalSpacing(); - int spaceY = 0; - int nextX = 0; - - if (spaceX == -1) - spaceX = wid->style()->layoutSpacing( - QSizePolicy::PushButton, QSizePolicy::PushButton, Qt::Horizontal); - - spaceY = verticalSpacing(); - - if (spaceY == -1) - spaceY = wid->style()->layoutSpacing( - QSizePolicy::PushButton, QSizePolicy::PushButton, Qt::Vertical); - - nextX = x + item->sizeHint().width() + spaceX; - - if (nextX - spaceX > effectiveRect.right() && lineHeight > 0) - { - x = effectiveRect.x(); - y = y + lineHeight + spaceY; - nextX = x + item->sizeHint().width() + spaceX; - lineHeight = 0; - } - - if (!testOnly) - item->setGeometry(QRect(QPoint(x, y), item->sizeHint())); - - x = nextX; - lineHeight = qMax(lineHeight, item->sizeHint().height()); - } - - return y + lineHeight - rect.y() + bottom; -} - -int FlowLayout::smartSpacing(QStyle::PixelMetric pm) const -{ - const QObject *parentObj = parent(); - - if (!parentObj) - return -1; - else if (parentObj->isWidgetType()) - { - const QWidget *pw = static_cast(parentObj); - return pw->style()->pixelMetric(pm, NULL, pw); - } - else - return static_cast(parentObj)->spacing(); -} - -void FlowLayout::addWidgetDeferred(QPointer widget) -{ - emit signalAddWidgetDeferred(widget); -} - -void FlowLayout::onAddWidgetDeferred(QPointer widget) -{ - /* widget might have been deleted before we got to it since this uses a queued connection, hence the guarded QPointer */ - if (!widget) - return; - - addWidget(widget); -} diff --git a/ui/drivers/qt/flowlayout.h b/ui/drivers/qt/flowlayout.h deleted file mode 100644 index c9d11e7653..0000000000 --- a/ui/drivers/qt/flowlayout.h +++ /dev/null @@ -1,105 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the examples of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:BSD$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** BSD License Usage -** Alternatively, you may use this file under the terms of the BSD license -** as follows: -** -** "Redistribution and use in source and binary forms, with or without -** modification, are permitted provided that the following conditions are -** met: -** * Redistributions of source code must retain the above copyright -** notice, this list of conditions and the following disclaimer. -** * Redistributions in binary form must reproduce the above copyright -** notice, this list of conditions and the following disclaimer in -** the documentation and/or other materials provided with the -** distribution. -** * Neither the name of The Qt Company Ltd nor the names of its -** contributors may be used to endorse or promote products derived -** from this software without specific prior written permission. -** -** -** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE." -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -/* Original work Copyright (C) 2016 The Qt Company Ltd. - * Modified work Copyright (C) 2018 - Brad Parker - */ - -/* bparker: Removed C++11 override keyword from original source - * Changed QList to QVector - */ - -#ifndef FLOWLAYOUT_H -#define FLOWLAYOUT_H - -#include -#include -#include - -class ThumbnailWidget; - -class FlowLayout : public QLayout -{ - Q_OBJECT -public: - explicit FlowLayout(QWidget *parent, int margin = -1, int hSpacing = -1, int vSpacing = -1); - explicit FlowLayout(int margin = -1, int hSpacing = -1, int vSpacing = -1); - ~FlowLayout(); - - void addItem(QLayoutItem *item); - int horizontalSpacing() const; - int verticalSpacing() const; - Qt::Orientations expandingDirections() const; - bool hasHeightForWidth() const; - int heightForWidth(int) const; - int count() const; - QLayoutItem* itemAt(int index) const; - QSize minimumSize() const; - void setGeometry(const QRect &rect); - QSize sizeHint() const; - QLayoutItem* takeAt(int index); - void addWidgetDeferred(QPointer widget); - -signals: - void signalAddWidgetDeferred(QPointer widget); - -private slots: - void onAddWidgetDeferred(QPointer widget); - -private: - int doLayout(const QRect &rect, bool testOnly) const; - int smartSpacing(QStyle::PixelMetric pm) const; - - QVector itemList; - int m_hSpace; - int m_vSpace; -}; - -#endif // FLOWLAYOUT_H diff --git a/ui/drivers/qt/gridview.cpp b/ui/drivers/qt/gridview.cpp new file mode 100644 index 0000000000..9d53c8c506 --- /dev/null +++ b/ui/drivers/qt/gridview.cpp @@ -0,0 +1,481 @@ +#include +#include + +#include "gridview.h" +#include "../ui_qt.h" + +/* http://www.informit.com/articles/article.aspx?p=1613548 */ + +ThumbnailDelegate::ThumbnailDelegate(const GridItem &gridItem, QObject* parent) : + QStyledItemDelegate(parent), m_style(gridItem) +{ +} +void ThumbnailDelegate::paint(QPainter* painter, const QStyleOptionViewItem &option, const QModelIndex& index) const +{ + QStyleOptionViewItem opt = option; + const QWidget *widget = opt.widget; + QStyle *style = widget->style(); + int padding = m_style.padding; + int textTopMargin = 4; /* Qt seemingly reports -4 the actual line height. */ + int textHeight = painter->fontMetrics().height() + padding + padding; + QRect rect = opt.rect; + QRect adjusted = rect.adjusted(padding, padding, -padding, -textHeight + textTopMargin); + QPixmap pixmap = index.data(PlaylistModel::THUMBNAIL).value(); + + painter->save(); + + initStyleOption(&opt, index); + + /* draw the background */ + style->drawPrimitive(QStyle::PE_PanelItemViewItem, &opt, painter, widget); + + /* draw the image */ + if (!pixmap.isNull()) + { + QPixmap pixmapScaled = pixmap.scaled(adjusted.size(), Qt::KeepAspectRatio, Qt::SmoothTransformation); + style->drawItemPixmap(painter, adjusted, Qt::AlignHCenter | m_style.thumbnailVerticalAlignmentFlag, pixmapScaled); + } + + /* draw the text */ + if (!opt.text.isEmpty()) + { + QPalette::ColorGroup cg = opt.state & QStyle::State_Enabled ? QPalette::Normal : QPalette::Disabled; + QRect textRect = QRect(rect.x() + padding, rect.y() + adjusted.height() - textTopMargin + padding, rect.width() - 2 * padding, textHeight); + QString elidedText = painter->fontMetrics().elidedText(opt.text, opt.textElideMode, textRect.width(), Qt::TextShowMnemonic); + + if (cg == QPalette::Normal && !(opt.state & QStyle::State_Active)) + cg = QPalette::Inactive; + + if (opt.state & QStyle::State_Selected) + painter->setPen(opt.palette.color(cg, QPalette::HighlightedText)); + else + painter->setPen(opt.palette.color(cg, QPalette::Text)); + + painter->setFont(opt.font); + painter->drawText(textRect, Qt::AlignCenter, elidedText); + } + + painter->restore(); +} + +GridView::GridView(QWidget *parent) : QAbstractItemView(parent), m_idealHeight(0), m_hashIsDirty(false) +{ + setFocusPolicy(Qt::WheelFocus); + horizontalScrollBar()->setRange(0, 0); + verticalScrollBar()->setRange(0, 0); +} + +void GridView::setModel(QAbstractItemModel *newModel) +{ + if (model()) + disconnect(model(), SIGNAL(rowsRemoved(QModelIndex, int, int)), this, SLOT(rowsRemoved(QModelIndex, int, int))); + + QAbstractItemView::setModel(newModel); + + connect(newModel, SIGNAL(rowsRemoved(QModelIndex, int, int)), this, SLOT(rowsRemoved(QModelIndex, int, int))); + + m_hashIsDirty = true; +} + +void GridView::setviewMode(ViewMode mode) +{ + m_viewMode = mode; +} + +void GridView::calculateRectsIfNecessary() const +{ + if (!m_hashIsDirty) + return; + + int x = m_spacing; + int y = m_spacing; + int row; + int nextX; + + const int maxWidth = viewport()->width(); + + switch (m_viewMode) + { + case Anchored: + { + int columns = (maxWidth - m_spacing) / (m_size + m_spacing); + if (columns > 0) + { + const int actualSpacing = (maxWidth - m_spacing - m_size - (columns - 1) * m_size) / columns; + for (row = 0; row < model()->rowCount(); ++row) + { + nextX = x + m_size + actualSpacing; + if (nextX > maxWidth) + { + x = m_spacing; + y += m_size + m_spacing; + nextX = x + m_size + actualSpacing; + } + m_rectForRow[row] = QRectF(x, y, m_size, m_size); + x = nextX; + } + } + break; + } + case Centered: + { + int columns = (maxWidth - m_spacing) / (m_size + m_spacing); + if (columns > 0) + { + const int actualSpacing = (maxWidth - columns * m_size) / (columns + 1); + x = actualSpacing; + for (row = 0; row < model()->rowCount(); ++row) + { + nextX = x + m_size + actualSpacing; + if (nextX > maxWidth) + { + x = actualSpacing; + y += m_size + m_spacing; + nextX = x + m_size + actualSpacing; + } + m_rectForRow[row] = QRectF(x, y, m_size, m_size); + x = nextX; + } + } + break; + } + case Simple: + for (row = 0; row < model()->rowCount(); ++row) + { + nextX = x + m_size + m_spacing; + if (nextX > maxWidth) + { + x = m_spacing; + y += m_size + m_spacing; + nextX = x + m_size + m_spacing; + } + m_rectForRow[row] = QRectF(x, y, m_size, m_size); + x = nextX; + } + break; + } + m_idealHeight = y + m_size + m_spacing; + m_hashIsDirty = false; + viewport()->update(); +} + +QRect GridView::visualRect(const QModelIndex &index) const +{ + QRect rect; + if (index.isValid()) + rect = viewportRectForRow(index.row()).toRect(); + return rect; +} + +QRectF GridView::viewportRectForRow(int row) const +{ + QRectF rect; + calculateRectsIfNecessary(); + rect = m_rectForRow.value(row).toRect(); + if (!rect.isValid()) + return rect; + return QRectF(rect.x() - horizontalScrollBar()->value(), rect.y() - verticalScrollBar()->value(), rect.width(), rect.height()); +} + +void GridView::scrollTo(const QModelIndex &index, QAbstractItemView::ScrollHint) +{ + QRect viewRect = viewport()->rect(); + QRect itemRect = visualRect(index); + + if (itemRect.left() < viewRect.left()) + horizontalScrollBar()->setValue(horizontalScrollBar()->value() + itemRect.left() - viewRect.left()); + else if (itemRect.right() > viewRect.right()) + horizontalScrollBar()->setValue(horizontalScrollBar()->value() + qMin(itemRect.right() - viewRect.right(), itemRect.left() - viewRect.left())); + if (itemRect.top() < viewRect.top()) + verticalScrollBar()->setValue(verticalScrollBar()->value() + itemRect.top() - viewRect.top()); + else if (itemRect.bottom() > viewRect.bottom()) + verticalScrollBar()->setValue(verticalScrollBar()->value() + qMin(itemRect.bottom() - viewRect.bottom(), itemRect.top() - viewRect.top())); + viewport()->update(); +} + +/* TODO: Make this more efficient by changing m_rectForRow for another data structure. Look at how Qt's own views do it. */ +QModelIndex GridView::indexAt(const QPoint &point_) const +{ + QPoint point(point_); + QHash::const_iterator i; + point.rx() += horizontalScrollBar()->value(); + point.ry() += verticalScrollBar()->value(); + + calculateRectsIfNecessary(); + + i = m_rectForRow.constBegin(); + + while (i != m_rectForRow.constEnd()) + { + if (i.value().contains(point)) + return model()->index(i.key(), 0, rootIndex()); + i++; + } + return QModelIndex(); +} + +void GridView::dataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight) +{ + m_hashIsDirty = true; + QAbstractItemView::dataChanged(topLeft, bottomRight); +} + +void GridView::refresh() +{ + m_hashIsDirty = true; + calculateRectsIfNecessary(); + updateGeometries(); +} + +void GridView::rowsInserted(const QModelIndex &parent, int start, int end) +{ + QAbstractItemView::rowsInserted(parent, start, end); + refresh(); +} + +void GridView::rowsRemoved(const QModelIndex &parent, int start, int end) +{ + refresh(); +} + +void GridView::setGridSize(const int newSize) +{ + if (newSize != m_size) + { + m_size = newSize; + refresh(); + } +} + +void GridView::resizeEvent(QResizeEvent*) +{ + refresh(); +} + +void GridView::reset() +{ + m_visibleIndexes.clear(); + QAbstractItemView::reset(); + refresh(); +} + +QModelIndex GridView::moveCursor(QAbstractItemView::CursorAction cursorAction, Qt::KeyboardModifiers) +{ + QModelIndex index = currentIndex(); + if (index.isValid()) + { + if ((cursorAction == MoveLeft && index.row() > 0) || (cursorAction == MoveRight && index.row() + 1 < model()->rowCount())) + { + const int offset = (cursorAction == MoveLeft ? -1 : 1); + index = model()->index(index.row() + offset, index.column(), index.parent()); + } + else if ((cursorAction == MoveUp && index.row() > 0) || (cursorAction == MoveDown && index.row() + 1 < model()->rowCount())) + { + const int offset = ((m_size + m_spacing) * (cursorAction == MoveUp ? -1 : 1)); + QRect rect = viewportRectForRow(index.row()).toRect(); + QPoint point(rect.center().x(), rect.center().y() + offset); + index = indexAt(point); + } + } + return index; +} + +int GridView::horizontalOffset() const +{ + return horizontalScrollBar()->value(); +} + +int GridView::verticalOffset() const +{ + return verticalScrollBar()->value(); +} + +void GridView::scrollContentsBy(int dx, int dy) +{ + scrollDirtyRegion(dx, dy); + viewport()->scroll(dx, dy); + emit(visibleItemsChangedMaybe()); +} + +/* TODO: Maybe add a way to get the previous/next visible indexes. */ +QVector GridView::visibleIndexes() const { + return m_visibleIndexes; +} + +void GridView::setSelection(const QRect &rect, QFlags flags) +{ + QRect rectangle; + QHash::const_iterator i; + int firstRow = model()->rowCount(); + int lastRow = -1; + + calculateRectsIfNecessary(); + + rectangle = rect.translated(horizontalScrollBar()->value(), verticalScrollBar()->value()).normalized(); + + i = m_rectForRow.constBegin(); + while (i != m_rectForRow.constEnd()) + { + if (i.value().intersects(rectangle)) + { + firstRow = firstRow < i.key() ? firstRow : i.key(); + lastRow = lastRow > i.key() ? lastRow : i.key(); + } + i++; + } + if (firstRow != model()->rowCount() && lastRow != -1) + { + QItemSelection selection(model()->index(firstRow, 0, rootIndex()), model()->index(lastRow, 0, rootIndex())); + selectionModel()->select(selection, flags); + } + else + { + QModelIndex invalid; + QItemSelection selection(invalid, invalid); + selectionModel()->select(selection, flags); + } +} + +QRegion GridView::visualRegionForSelection(const QItemSelection &selection) const +{ + QRegion region; + QItemSelectionRange range; + int i; + + for (i = 0; i < selection.size(); i++) + { + range = selection.at(i); + int row; + for (row = range.top(); row <= range.bottom(); row++) + { + int column; + for (column = range.left(); column < range.right(); column++) + { + QModelIndex index = model()->index(row, column, rootIndex()); + region += visualRect(index); + } + } + } + + return region; +} + +void GridView::paintEvent(QPaintEvent*) +{ + QPainter painter(viewport()); + int row; + + painter.setRenderHints(QPainter::Antialiasing | QPainter::TextAntialiasing); + m_visibleIndexes.clear(); + + for (row = 0; row < model()->rowCount(rootIndex()); ++row) + { + QModelIndex index = model()->index(row, 0, rootIndex()); + QRectF rect = viewportRectForRow(row); + QStyleOptionViewItem option = viewOptions(); + + if (!rect.isValid() || rect.bottom() < 0 || rect.y() > viewport()->height()) + continue; + + m_visibleIndexes.append(index); + option.rect = rect.toRect(); + + if (selectionModel()->isSelected(index)) + option.state |= QStyle::State_Selected; + + if (currentIndex() == index) + option.state |= QStyle::State_HasFocus; + + itemDelegate()->paint(&painter, option, index); + } +} + +void GridView::updateGeometries() +{ + const int RowHeight = m_size + m_spacing; + + QAbstractItemView::updateGeometries(); + + verticalScrollBar()->setSingleStep(RowHeight); + verticalScrollBar()->setPageStep(viewport()->height()); + verticalScrollBar()->setRange(0, qMax(0, m_idealHeight - viewport()->height())); + + horizontalScrollBar()->setPageStep(viewport()->width()); + horizontalScrollBar()->setRange(0, qMax(0, RowHeight - viewport()->width())); + + emit(visibleItemsChangedMaybe()); +} + +QString GridView::getLayout() const +{ + switch (m_viewMode) + { + case Simple: + return "simple"; + case Anchored: + return "anchored"; + case Centered: + default: + return "centered"; + } +} + +void GridView::setLayout(QString layout) +{ + if (layout == "anchored") + m_viewMode = Anchored; + else if (layout == "centered") + m_viewMode = Centered; + else if (layout == "fixed") + m_viewMode = Simple; +} + +int GridView::getSpacing() const +{ + return m_spacing; +} + +void GridView::setSpacing(const int spacing) +{ + m_spacing = spacing; +} + +GridItem::GridItem(QWidget* parent) : QWidget(parent) +, thumbnailVerticalAlignmentFlag(Qt::AlignBottom) +, padding(11) +{ +} + +int GridItem::getPadding() const +{ + return padding; +} + +void GridItem::setPadding(const int value) +{ + padding = value; +} + +QString GridItem::getThumbnailVerticalAlign() const +{ + switch (thumbnailVerticalAlignmentFlag) + { + case Qt::AlignTop: + return "top"; + case Qt::AlignVCenter: + return "center"; + case Qt::AlignBottom: + default: + return "bottom"; + } +} + +void GridItem::setThumbnailVerticalAlign(const QString valign) +{ + if (valign == "top") + thumbnailVerticalAlignmentFlag = Qt::AlignTop; + else if (valign == "center") + thumbnailVerticalAlignmentFlag = Qt::AlignVCenter; + else if (valign == "bottom") + thumbnailVerticalAlignmentFlag = Qt::AlignBottom; +} diff --git a/ui/drivers/qt/gridview.h b/ui/drivers/qt/gridview.h new file mode 100644 index 0000000000..165781d91e --- /dev/null +++ b/ui/drivers/qt/gridview.h @@ -0,0 +1,91 @@ +#ifndef GRIDVIEW_H +#define GRIDVIEW_H + +#include +#include + +#define DEFAULT_GRID_ITEM_MARGIN 11 +#define DEFAULT_GRID_ITEM_THUMBNAIL_ALIGNMENT "bottom" +#define DEFAULT_GRID_SPACING 7 +#define DEFAULT_GRID_LAYOUT "centered" + +class GridItem; + +class ThumbnailDelegate : public QStyledItemDelegate +{ + Q_OBJECT + +public: + ThumbnailDelegate(const GridItem &gridItem, QObject* parent = 0); + void paint(QPainter* painter, const QStyleOptionViewItem &option, const QModelIndex& index) const; + +private: + const GridItem &m_style; +}; + +class GridView : public QAbstractItemView +{ + Q_OBJECT + + Q_PROPERTY(QString layout READ getLayout WRITE setLayout DESIGNABLE true SCRIPTABLE true) + Q_PROPERTY(int spacing READ getSpacing WRITE setSpacing DESIGNABLE true SCRIPTABLE true) + +public: + enum ViewMode + { + Simple, + Centered, + Anchored + }; + + GridView(QWidget *parent = 0); + ~GridView() {} + + QModelIndex indexAt(const QPoint &point_) const; + QVector visibleIndexes() const; + QRect visualRect(const QModelIndex &index) const; + void setModel(QAbstractItemModel *model); + void scrollTo(const QModelIndex &index, QAbstractItemView::ScrollHint); + void setGridSize(const int newSize); + void setviewMode(ViewMode mode); + QString getLayout() const; + void setLayout(QString layout); + int getSpacing() const; + void setSpacing(const int spacing); + +signals: + void visibleItemsChangedMaybe() const; + +protected slots: + void dataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight); + void rowsInserted(const QModelIndex &parent, int start, int end); + void rowsRemoved(const QModelIndex &parent, int start, int end); + void updateGeometries(); + void reset(); + +protected: + QModelIndex moveCursor(QAbstractItemView::CursorAction cursorAction, Qt::KeyboardModifiers modifiers); + QRegion visualRegionForSelection(const QItemSelection &selection) const; + bool isIndexHidden(const QModelIndex&) const { return false; } + int horizontalOffset() const; + int verticalOffset() const; + void scrollContentsBy(int dx, int dy); + void setSelection(const QRect &rect, QFlags flags); + void paintEvent(QPaintEvent*); + void resizeEvent(QResizeEvent*); + +private: + QRectF viewportRectForRow(int row) const; + void calculateRectsIfNecessary() const; + void refresh(); + + int m_size = 255; + int m_spacing = DEFAULT_GRID_SPACING; + QVector m_visibleIndexes; + ViewMode m_viewMode = Centered; + mutable int m_idealHeight; + mutable QHash m_rectForRow; + mutable bool m_hashIsDirty; +}; + +#endif diff --git a/ui/drivers/qt/playlist.cpp b/ui/drivers/qt/playlist.cpp index 7217f19f5a..ce3742b413 100644 --- a/ui/drivers/qt/playlist.cpp +++ b/ui/drivers/qt/playlist.cpp @@ -9,9 +9,10 @@ #include #include #include +#include +#include #include "../ui_qt.h" -#include "flowlayout.h" #include "playlistentrydialog.h" extern "C" { @@ -28,6 +29,213 @@ extern "C" { #include "../../../verbosity.h" } +PlaylistModel::PlaylistModel(QObject *parent) + : QAbstractListModel(parent) +{ + m_imageFormats = QVector::fromList(QImageReader::supportedImageFormats()); + m_fileSanitizerRegex = QRegularExpression("[&*/:`<>?\\|]"); + setThumbnailCacheLimit(500); + connect(this, &PlaylistModel::imageLoaded, this, &PlaylistModel::onImageLoaded); +} + +int PlaylistModel::rowCount(const QModelIndex & /* parent */) const +{ + return m_contents.count(); +} + +int PlaylistModel::columnCount(const QModelIndex & /* parent */) const +{ + return 1; +} + +QVariant PlaylistModel::data(const QModelIndex &index, int role) const +{ + if (index.column() == 0) + { + if (!index.isValid()) + return QVariant(); + + if (index.row() >= m_contents.size() || index.row() < 0) + return QVariant(); + + switch (role) + { + case Qt::DisplayRole: + case Qt::EditRole: + case Qt::ToolTipRole: + return m_contents.at(index.row())["label_noext"]; + case HASH: + return QVariant::fromValue(m_contents.at(index.row())); + case THUMBNAIL: + { + QPixmap *cachedPreview = m_cache.object(getCurrentTypeThumbnailPath(index)); + if (cachedPreview) + return *cachedPreview; + return QVariant(); + } + } + } + return QVariant(); +} + +Qt::ItemFlags PlaylistModel::flags(const QModelIndex &index) const +{ + if (!index.isValid()) + return Qt::ItemIsEnabled; + + return QAbstractListModel::flags(index) | Qt::ItemIsEditable; +} + +bool PlaylistModel::setData(const QModelIndex &index, const QVariant &value, int role) +{ + if (index.isValid() && role == Qt::EditRole) { + QHash hash = m_contents.at(index.row()); + + hash["label"] = value.toString(); + hash["label_noext"] = QFileInfo(value.toString()).completeBaseName(); + + m_contents.replace(index.row(), hash); + emit dataChanged(index, index, { role }); + return true; + } + return false; +} + +QVariant PlaylistModel::headerData(int section, Qt::Orientation orientation, int role) const +{ + if (role != Qt::DisplayRole) + return QVariant(); + + if (orientation == Qt::Horizontal) + return msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_NAME); + else + return section + 1; +} + +void PlaylistModel::setThumbnailType(const ThumbnailType type) +{ + m_thumbnailType = type; +} + +void PlaylistModel::setThumbnailCacheLimit(int limit) +{ + m_cache.setMaxCost(limit * 1024); +} + +QString PlaylistModel::getThumbnailPath(const QModelIndex &index, QString type) const +{ + QByteArray extension; + QString extensionStr; + + QString thumbnailFileNameNoExt; + int lastIndex = -1; + + const QHash &hash = m_contents.at(index.row()); + lastIndex = hash["path"].lastIndexOf('.'); + + if (lastIndex >= 0) + { + extensionStr = hash["path"].mid(lastIndex + 1); + + if (!extensionStr.isEmpty()) + { + extension = extensionStr.toLower().toUtf8(); + } + } + + if (!extension.isEmpty() && m_imageFormats.contains(extension)) + { + /* use thumbnail widgets to show regular image files */ + return hash["path"]; + } + else + { + thumbnailFileNameNoExt = hash["label_noext"]; + thumbnailFileNameNoExt.replace(m_fileSanitizerRegex, "_"); + return QDir::cleanPath(QString(config_get_ptr()->paths.directory_thumbnails)) + "/" + hash.value("db_name") + "/" + type + "/" + thumbnailFileNameNoExt + ".png"; + } +} + +QString PlaylistModel::getCurrentTypeThumbnailPath(const QModelIndex &index) const +{ + switch (m_thumbnailType) + { + case THUMBNAIL_TYPE_BOXART: + return getThumbnailPath(index, THUMBNAIL_BOXART); + case THUMBNAIL_TYPE_SCREENSHOT: + return getThumbnailPath(index, THUMBNAIL_SCREENSHOT); + case THUMBNAIL_TYPE_TITLE_SCREEN: + return getThumbnailPath(index, THUMBNAIL_TITLE); + default: + return QString(); + } +} + +void PlaylistModel::reloadThumbnail(const QModelIndex &index) +{ + if (index.isValid()) { + reloadThumbnailPath(getCurrentTypeThumbnailPath(index)); + loadThumbnail(index); + } +} + +void PlaylistModel::reloadSystemThumbnails(const QString system) +{ + int i = 0; + QString key; + QString path = QDir::cleanPath(QString(config_get_ptr()->paths.directory_thumbnails)) + "/" + system; + QList keys = m_cache.keys(); + QList pending = m_pendingImages.values(); + + for (i = 0; i < keys.size(); i++) + { + key = keys.at(i); + if (key.startsWith(path)) + m_cache.remove(key); + } + + for (i = 0; i < pending.size(); i++) + { + key = pending.at(i); + if (key.startsWith(path)) + m_pendingImages.remove(key); + } +} + +void PlaylistModel::reloadThumbnailPath(const QString path) +{ + m_cache.remove(path); + m_pendingImages.remove(path); +} + +void PlaylistModel::loadThumbnail(const QModelIndex &index) +{ + QString path = getCurrentTypeThumbnailPath(index); + + if (!m_pendingImages.contains(path) && !m_cache.contains(path)) + { + m_pendingImages.insert(path); + QtConcurrent::run(this, &PlaylistModel::loadImage, index, path); + } +} + +void PlaylistModel::loadImage(const QModelIndex &index, const QString &path) +{ + const QImage image = QImage(path); + if (!image.isNull()) + emit imageLoaded(image, index, path); +} + +void PlaylistModel::onImageLoaded(const QImage image, const QModelIndex &index, const QString &path) +{ + QPixmap *pixmap = new QPixmap(QPixmap::fromImage(image)); + const int cost = pixmap->width() * pixmap->height() * pixmap->depth() / (8 * 1024); + m_cache.insert(path, pixmap, cost); + if (index.isValid()) + emit dataChanged(index, index, { THUMBNAIL }); + m_pendingImages.remove(path); +} + inline static bool comp_hash_name_key_lower(const QHash &lhs, const QHash &rhs) { return lhs.value("name").toLower() < rhs.value("name").toLower(); @@ -38,7 +246,6 @@ inline static bool comp_hash_label_key_lower(const QHash &lhs, return lhs.value("label").toLower() < rhs.value("label").toLower(); } -/* https://stackoverflow.com/questions/7246622/how-to-create-a-slider-with-a-non-linear-scale */ bool MainWindow::addDirectoryFilesToList(QProgressDialog *dialog, QStringList &list, QDir &dir, QStringList &extensions) { PlaylistEntryDialog *playlistDialog = playlistEntryDialog(); @@ -834,9 +1041,6 @@ void MainWindow::reloadPlaylists() getPlaylistFiles(); - /* block this signal because setData() would trigger an infinite loop */ - disconnect(m_listWidget, SIGNAL(itemChanged(QListWidgetItem*)), this, SLOT(onCurrentListItemDataChanged(QListWidgetItem*))); - m_listWidget->clear(); m_listWidget->setSelectionBehavior(QAbstractItemView::SelectRows); m_listWidget->setSelectionMode(QAbstractItemView::SingleSelection); @@ -968,13 +1172,11 @@ void MainWindow::reloadPlaylists() } } - connect(m_listWidget, SIGNAL(itemChanged(QListWidgetItem*)), this, SLOT(onCurrentListItemDataChanged(QListWidgetItem*))); } QString MainWindow::getCurrentPlaylistPath() { QListWidgetItem *playlistItem = m_listWidget->currentItem(); - QHash contentHash; QString playlistPath; if (!playlistItem) @@ -1116,151 +1318,15 @@ void MainWindow::getPlaylistFiles() m_playlistFiles = playlistDir.entryList(QDir::NoDotAndDotDot | QDir::Readable | QDir::Files, QDir::Name); } -void MainWindow::addPlaylistItemsToGrid(const QStringList &paths, bool add) -{ - QVector > items; - int i; - - if (paths.isEmpty()) - return; - - for (i = 0; i < paths.size(); i++) - { - int j; - QVector > vec = getPlaylistItems(paths.at(i)); - /* QVector::append() wasn't added until 5.5, so just do it the old fashioned way */ - for (j = 0; j < vec.size(); j++) - { - if (add && m_allPlaylistsGridMaxCount > 0 && items.size() >= m_allPlaylistsGridMaxCount) - goto finish; - - items.append(vec.at(j)); - } - } -finish: - std::sort(items.begin(), items.end(), comp_hash_label_key_lower); - - addPlaylistHashToGrid(items); -} - -void MainWindow::addPlaylistHashToGrid(const QVector > &items) -{ - QScreen *screen = qApp->primaryScreen(); - QSize screenSize = screen->size(); - QListWidgetItem *currentItem = m_listWidget->currentItem(); - settings_t *settings = config_get_ptr(); - int i = 0; - int zoomValue = m_zoomSlider->value(); - - m_gridProgressBar->setMinimum(0); - m_gridProgressBar->setMaximum(qMax(0, items.count() - 1)); - m_gridProgressBar->setValue(0); - - for (i = 0; i < items.count(); i++) - { - const QHash &hash = items.at(i); - QPointer item; - QPointer label; - QString thumbnailFileNameNoExt; - QLabel *newLabel = NULL; - QSize thumbnailWidgetSizeHint(screenSize.width() / 8, screenSize.height() / 8); - QByteArray extension; - QString extensionStr; - QString imagePath; - int lastIndex = -1; - - if (m_listWidget->currentItem() != currentItem) - { - /* user changed the current playlist before we finished loading... abort */ - m_gridProgressWidget->hide(); - break; - } - - item = new GridItem(); - - lastIndex = hash["path"].lastIndexOf('.'); - - if (lastIndex >= 0) - { - extensionStr = hash["path"].mid(lastIndex + 1); - - if (!extensionStr.isEmpty()) - { - extension = extensionStr.toLower().toUtf8(); - } - } - - if (!extension.isEmpty() && m_imageFormats.contains(extension)) - { - /* use thumbnail widgets to show regular image files */ - imagePath = hash["path"]; - } - else - { - thumbnailFileNameNoExt = hash["label_noext"]; - thumbnailFileNameNoExt.replace(m_fileSanitizerRegex, "_"); - imagePath = QString(settings->paths.directory_thumbnails) + "/" + hash.value("db_name") + "/" + THUMBNAIL_BOXART + "/" + thumbnailFileNameNoExt + ".png"; - } - - item->hash = hash; - item->widget = new ThumbnailWidget(); - item->widget->setSizeHint(thumbnailWidgetSizeHint); - item->widget->setFixedSize(item->widget->sizeHint()); - item->widget->setLayout(new QVBoxLayout()); - item->widget->setObjectName("thumbnailWidget"); - item->widget->setProperty("hash", QVariant::fromValue >(hash)); - item->widget->setProperty("image_path", imagePath); - - connect(item->widget, SIGNAL(mouseDoubleClicked()), this, SLOT(onGridItemDoubleClicked())); - connect(item->widget, SIGNAL(mousePressed()), this, SLOT(onGridItemClicked())); - - label = new ThumbnailLabel(item->widget); - label->setObjectName("thumbnailGridLabel"); - - item->label = label; - item->labelText = hash.value("label"); - - newLabel = new QLabel(item->labelText, item->widget); - newLabel->setObjectName("thumbnailQLabel"); - newLabel->setAlignment(Qt::AlignCenter); - newLabel->setToolTip(item->labelText); - - calcGridItemSize(item, zoomValue); - - item->widget->layout()->addWidget(label); - - item->widget->layout()->addWidget(newLabel); - qobject_cast(item->widget->layout())->setStretchFactor(label, 1); - - m_gridLayout->addWidgetDeferred(item->widget); - m_gridItems.append(item); - - loadImageDeferred(item, imagePath); - - if (i % 25 == 0) - { - /* Needed to update progress dialog while doing a lot of stuff on the main thread. */ - qApp->processEvents(); - } - - m_gridProgressBar->setValue(i); - } - - /* If there's only one entry, a min/max/value of all zero would make an indeterminate progress bar that never ends... so just hide it when we are done. */ - if (m_gridProgressBar->value() == m_gridProgressBar->maximum()) - m_gridProgressWidget->hide(); -} - -QVector > MainWindow::getPlaylistItems(QString pathString) +void PlaylistModel::getPlaylistItems(QString path) { QByteArray pathArray; - QVector > items; const char *pathData = NULL; playlist_t *playlist = NULL; unsigned playlistSize = 0; unsigned i = 0; - pathArray.append(pathString); + pathArray.append(path); pathData = pathArray.constData(); playlist = playlist_init(pathData, COLLECTION_SIZE); @@ -1313,58 +1379,67 @@ QVector > MainWindow::getPlaylistItems(QString pathStrin hash["db_name"].remove(file_path_str(FILE_PATH_LPL_EXTENSION)); } - items.append(hash); + m_contents.append(hash); } playlist_free(playlist); playlist = NULL; - - return items; } -void MainWindow::addPlaylistItemsToTable(const QStringList &paths, bool add) +void PlaylistModel::addPlaylistItems(const QStringList &paths, bool add) { - QVector > items; int i; if (paths.isEmpty()) return; + beginResetModel(); + + m_contents.clear(); + for (i = 0; i < paths.size(); i++) { - int j; - QVector > vec = getPlaylistItems(paths.at(i)); - /* QVector::append() wasn't added until 5.5, so just do it the old fashioned way */ - for (j = 0; j < vec.size(); j++) - { - if (add && m_allPlaylistsListMaxCount > 0 && items.size() >= m_allPlaylistsListMaxCount) - goto finish; - - items.append(vec.at(j)); - } + getPlaylistItems(paths.at(i)); } -finish: - addPlaylistHashToTable(items); + + endResetModel(); } -void MainWindow::addPlaylistHashToTable(const QVector > &items) +void PlaylistModel::addDir(QString path, QFlags showHidden) { + QDir dir = path; + QStringList dirList; int i = 0; - int oldRowCount = m_tableWidget->rowCount(); - m_tableWidget->setRowCount(oldRowCount + items.count()); + dirList = dir.entryList(QDir::NoDotAndDotDot | + QDir::Readable | + QDir::Files | + showHidden, + QDir::Name); - for (i = 0; i < items.count(); i++) + if (dirList.count() == 0) + return; + + beginResetModel(); + + m_contents.clear(); + + for (i = 0; i < dirList.count(); i++) { - QTableWidgetItem *labelItem = NULL; - const QHash &hash = items.at(i); + QString fileName = dirList.at(i); + QHash hash; + QString filePath(QDir::toNativeSeparators(dir.absoluteFilePath(fileName))); + QFileInfo fileInfo(filePath); - labelItem = new QTableWidgetItem(hash.value("label")); - labelItem->setData(Qt::UserRole, QVariant::fromValue >(hash)); - labelItem->setFlags(labelItem->flags() | Qt::ItemIsEditable); + hash["path"] = filePath; + hash["label"] = hash["path"]; + hash["label_noext"] = fileInfo.completeBaseName(); + hash["db_name"] = fileInfo.dir().dirName(); - m_tableWidget->setItem(oldRowCount + i, 0, labelItem); + m_contents.append(hash); } + + endResetModel(); } void MainWindow::setAllPlaylistsListMaxCount(int count) @@ -1382,4 +1457,3 @@ void MainWindow::setAllPlaylistsGridMaxCount(int count) m_allPlaylistsGridMaxCount = count; } - diff --git a/ui/drivers/qt/playlistthumbnaildownload.cpp b/ui/drivers/qt/playlistthumbnaildownload.cpp index e14558ea9d..3dab4cd02f 100644 --- a/ui/drivers/qt/playlistthumbnaildownload.cpp +++ b/ui/drivers/qt/playlistthumbnaildownload.cpp @@ -150,14 +150,14 @@ void MainWindow::onPlaylistThumbnailDownloadFinished() emit showErrorMessageDeferred(QString(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_NETWORK_ERROR)) + ": Code " + QString::number(code) + ": " + errorData);*/ } + m_playlistModel->reloadThumbnailPath(m_playlistThumbnailDownloadFile.fileName()); + if (!m_playlistThumbnailDownloadWasCanceled && m_pendingPlaylistThumbnails.count() > 0) { QHash nextThumbnail = m_pendingPlaylistThumbnails.takeAt(0); ViewType viewType = getCurrentViewType(); - if (viewType == VIEW_TYPE_ICONS) - emit gridItemChanged(reply->property("title").toString()); - + updateVisibleItems(); downloadNextPlaylistThumbnail(nextThumbnail.value("db_name"), nextThumbnail.value("label_noext"), nextThumbnail.value("type")); } else @@ -236,7 +236,7 @@ void MainWindow::downloadNextPlaylistThumbnail(QString system, QString title, QS if (!m_playlistThumbnailDownloadFile.open(QIODevice::WriteOnly)) { m_failedThumbnails++; - + RARCH_ERR("[Qt]: Could not open file for writing: %s\n", fileNameData); if (m_pendingPlaylistThumbnails.count() > 0) @@ -290,9 +290,9 @@ void MainWindow::downloadPlaylistThumbnails(QString playlistPath) QString system; QString title; QString type; - QVector > playlistItems = getPlaylistItems(playlistPath); settings_t *settings = config_get_ptr(); int i; + int count; if (!settings || !playlistFile.exists()) return; @@ -302,12 +302,14 @@ void MainWindow::downloadPlaylistThumbnails(QString playlistPath) m_failedThumbnails = 0; m_playlistThumbnailDownloadWasCanceled = false; - if (playlistItems.count() == 0) + count = m_playlistModel->rowCount(); + + if (count == 0) return; - for (i = 0; i < playlistItems.count(); i++) + for (i = 0; i < count; i++) { - const QHash &itemHash = playlistItems.at(i); + const QHash &itemHash = m_playlistModel->index(i, 0).data(PlaylistModel::HASH).value< QHash >(); QHash hash; QHash hash2; QHash hash3; diff --git a/ui/drivers/qt/shaderparamsdialog.cpp b/ui/drivers/qt/shaderparamsdialog.cpp index 332fbe64b5..1124739723 100644 --- a/ui/drivers/qt/shaderparamsdialog.cpp +++ b/ui/drivers/qt/shaderparamsdialog.cpp @@ -28,9 +28,7 @@ extern "C" { #include "../../../retroarch.h" #include "../../../paths.h" #include "../../../file_path_special.h" -#ifdef HAVE_MENU #include "../../../menu/menu_shader.h" -#endif } enum @@ -169,7 +167,7 @@ void ShaderParamsDialog::clearLayout() void ShaderParamsDialog::getShaders(struct video_shader **menu_shader, struct video_shader **video_shader) { video_shader_ctx_t shader_info = {0}; -#ifdef HAVE_MENU + struct video_shader *shader = menu_shader_get(); if (menu_shader) @@ -195,7 +193,6 @@ void ShaderParamsDialog::getShaders(struct video_shader **menu_shader, struct vi *video_shader = NULL; } } -#endif if (video_shader) { @@ -491,7 +488,6 @@ void ShaderParamsDialog::onShaderPassMoveUpClicked() void ShaderParamsDialog::onShaderLoadPresetClicked() { -#ifdef HAVE_MENU QString path; QString filter; QByteArray pathArray; @@ -541,7 +537,6 @@ void ShaderParamsDialog::onShaderLoadPresetClicked() type = video_shader_parse_type(pathData, RARCH_SHADER_NONE); menu_shader_manager_set_preset(menu_shader, type, pathData); -#endif } void ShaderParamsDialog::onShaderResetPass(int pass) @@ -634,7 +629,6 @@ void ShaderParamsDialog::onShaderResetAllPasses() void ShaderParamsDialog::onShaderAddPassClicked() { -#ifdef HAVE_MENU QString path; QString filter; QByteArray pathArray; @@ -696,12 +690,10 @@ void ShaderParamsDialog::onShaderAddPassClicked() video_shader_resolve_parameters(NULL, menu_shader); command_event(CMD_EVENT_SHADERS_APPLY_CHANGES, NULL); -#endif } void ShaderParamsDialog::onShaderSavePresetAsClicked() { -#ifdef HAVE_MENU settings_t *settings = config_get_ptr(); QString path; QByteArray pathArray; @@ -716,7 +708,6 @@ void ShaderParamsDialog::onShaderSavePresetAsClicked() pathData = pathArray.constData(); saveShaderPreset(pathData, SHADER_PRESET_SAVE_NORMAL); -#endif } void ShaderParamsDialog::saveShaderPreset(const char *path, unsigned action_type) @@ -797,7 +788,6 @@ void ShaderParamsDialog::onShaderSaveGamePresetClicked() void ShaderParamsDialog::onShaderClearAllPassesClicked() { -#ifdef HAVE_MENU struct video_shader *menu_shader = NULL; struct video_shader *video_shader = NULL; @@ -810,12 +800,10 @@ void ShaderParamsDialog::onShaderClearAllPassesClicked() menu_shader_manager_decrement_amount_passes(); onShaderApplyClicked(); -#endif } void ShaderParamsDialog::onShaderRemovePassClicked() { -#ifdef HAVE_MENU int i; QVariant passVariant; QAction *action = qobject_cast(sender()); @@ -851,7 +839,6 @@ void ShaderParamsDialog::onShaderRemovePassClicked() menu_shader_manager_decrement_amount_passes(); onShaderApplyClicked(); -#endif } void ShaderParamsDialog::onShaderApplyClicked() diff --git a/ui/drivers/qt/thumbnaildownload.cpp b/ui/drivers/qt/thumbnaildownload.cpp index d83c8e186b..3e6a90ccb0 100644 --- a/ui/drivers/qt/thumbnaildownload.cpp +++ b/ui/drivers/qt/thumbnaildownload.cpp @@ -154,6 +154,8 @@ void MainWindow::onThumbnailDownloadFinished() { RARCH_LOG("[Qt]: Thumbnail download finished successfully.\n"); /* reload thumbnail image */ + m_playlistModel->reloadThumbnailPath(m_thumbnailDownloadFile.fileName()); + updateVisibleItems(); emit itemChanged(); } else diff --git a/ui/drivers/qt/thumbnailpackdownload.cpp b/ui/drivers/qt/thumbnailpackdownload.cpp index ac29d22fe0..8780e2f9d4 100644 --- a/ui/drivers/qt/thumbnailpackdownload.cpp +++ b/ui/drivers/qt/thumbnailpackdownload.cpp @@ -191,7 +191,6 @@ void MainWindow::onThumbnailPackDownloadFinished() reply->disconnect(); reply->close(); - reply->deleteLater(); } void MainWindow::onThumbnailPackDownloadProgress(qint64 bytesReceived, qint64 bytesTotal) @@ -309,6 +308,11 @@ void MainWindow::onThumbnailPackExtractFinished(bool success) emit showInfoMessageDeferred(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_THUMBNAIL_PACK_DOWNLOADED_SUCCESSFULLY)); + QNetworkReply *reply = m_thumbnailPackDownloadReply.data(); + + m_playlistModel->reloadSystemThumbnails(reply->property("system").toString()); + reply->deleteLater(); + updateVisibleItems(); /* reload thumbnail image */ emit itemChanged(); } diff --git a/ui/drivers/qt/ui_qt_load_core_window.cpp b/ui/drivers/qt/ui_qt_load_core_window.cpp index 8179b82570..ab99f07608 100644 --- a/ui/drivers/qt/ui_qt_load_core_window.cpp +++ b/ui/drivers/qt/ui_qt_load_core_window.cpp @@ -31,7 +31,7 @@ extern "C" { #include #include #include -}; +} #define CORE_NAME_COLUMN 0 #define CORE_VERSION_COLUMN 1 @@ -205,32 +205,36 @@ void LoadCoreWindow::initCoreList(const QStringList &extensionFilters) m_table->setSelectionBehavior(QAbstractItemView::SelectRows); m_table->setSelectionMode(QAbstractItemView::SingleSelection); m_table->setSortingEnabled(false); - m_table->setRowCount(cores->count); m_table->setColumnCount(2); m_table->setHorizontalHeaderLabels(horizontal_header_labels); - for (i = 0; i < cores->count; i++) + if (cores) { - core_info_t *core = core_info_get(cores, i); - QTableWidgetItem *name_item = NULL; - QTableWidgetItem *version_item = new QTableWidgetItem(core->display_version); - QVariantHash hash; - const char *name = core->display_name; + m_table->setRowCount(cores->count); - if (string_is_empty(name)) - name = path_basename(core->path); + for (i = 0; i < cores->count; i++) + { + core_info_t *core = core_info_get(cores, i); + QTableWidgetItem *name_item = NULL; + QTableWidgetItem *version_item = new QTableWidgetItem(core->display_version); + QVariantHash hash; + const char *name = core->display_name; - name_item = new QTableWidgetItem(name); + if (string_is_empty(name)) + name = path_basename(core->path); - hash["path"] = core->path; - hash["extensions"] = QString(core->supported_extensions).split("|"); + name_item = new QTableWidgetItem(name); - name_item->setData(Qt::UserRole, hash); - name_item->setFlags(name_item->flags() & ~Qt::ItemIsEditable); - version_item->setFlags(version_item->flags() & ~Qt::ItemIsEditable); + hash["path"] = core->path; + hash["extensions"] = QString(core->supported_extensions).split("|"); - m_table->setItem(i, CORE_NAME_COLUMN, name_item); - m_table->setItem(i, CORE_VERSION_COLUMN, version_item); + name_item->setData(Qt::UserRole, hash); + name_item->setFlags(name_item->flags() & ~Qt::ItemIsEditable); + version_item->setFlags(version_item->flags() & ~Qt::ItemIsEditable); + + m_table->setItem(i, CORE_NAME_COLUMN, name_item); + m_table->setItem(i, CORE_VERSION_COLUMN, version_item); + } } if (!extensionFilters.isEmpty()) diff --git a/ui/drivers/qt/ui_qt_themes.h b/ui/drivers/qt/ui_qt_themes.h index 803cf8a37a..7525730219 100644 --- a/ui/drivers/qt/ui_qt_themes.h +++ b/ui/drivers/qt/ui_qt_themes.h @@ -313,7 +313,7 @@ static const QString qt_theme_dark_stylesheet = QStringLiteral(R"( padding-left:5px; padding-right:5px; } - QTableWidget { + QTableView { background-color:rgb(25,25,25); alternate-background-color:rgb(40,40,40); } @@ -422,14 +422,18 @@ static const QString qt_theme_dark_stylesheet = QStringLiteral(R"( QSizeGrip { background-color:solid; } - ThumbnailWidget#thumbnailWidget, ThumbnailLabel#thumbnailGridLabel, QLabel#thumbnailQLabel { + GridView::item { background-color:rgb(40,40,40); } - ThumbnailWidget#thumbnailWidgetSelected { - background-color:rgb(40,40,40); + GridView::item:selected { border:3px solid %1; } - QWidget#gridLayoutWidget { + GridView { background-color:rgb(25,25,25); + selection-color: white; + qproperty-layout: "fixed"; + } + GridItem { + qproperty-thumbnailvalign: "center"; } )"); diff --git a/ui/drivers/qt/ui_qt_window.cpp b/ui/drivers/qt/ui_qt_window.cpp index 712137f68d..effb89760e 100644 --- a/ui/drivers/qt/ui_qt_window.cpp +++ b/ui/drivers/qt/ui_qt_window.cpp @@ -41,7 +41,7 @@ #include "invader_png.h" #include "ui_qt_load_core_window.h" #include "ui_qt_themes.h" -#include "flowlayout.h" +#include "gridview.h" #include "shaderparamsdialog.h" #include "coreoptionsdialog.h" #include "filedropwidget.h" @@ -119,13 +119,17 @@ static void scan_finished_handler(void *task_data, void *user_data, const char * { bool dontAsk = false; bool answer = false; + +#ifdef HAVE_MENU menu_ctx_environment_t menu_environ; menu_environ.type = MENU_ENVIRON_RESET_HORIZONTAL_LIST; menu_environ.data = NULL; +#endif (void)task_data; (void)user_data; (void)err; + #ifdef HAVE_MENU menu_driver_ctl(RARCH_MENU_CTL_ENVIRONMENT, &menu_environ); #endif @@ -139,6 +143,7 @@ static void scan_finished_handler(void *task_data, void *user_data, const char * } #endif +/* https://stackoverflow.com/questions/7246622/how-to-create-a-slider-with-a-non-linear-scale */ static double expScale(double inputValue, double midValue, double maxValue) { double returnValue = 0; @@ -152,27 +157,6 @@ static double expScale(double inputValue, double midValue, double maxValue) return returnValue; } -/* https://gist.github.com/andrey-str/0f9c7709cbf0c9c49ef9 */ -static void setElidedText(QLabel *label, QWidget *clipWidget, int padding, const QString &text) -{ - QFontMetrics metrix(label->font()); - int width = clipWidget->width() - padding; - QString clippedText = metrix.elidedText(text, Qt::ElideRight, width); - label->setText(clippedText); -} - -GridItem::GridItem() : - QObject() - ,widget(NULL) - ,label(NULL) - ,hash() - ,image() - ,pixmap() - ,imageWatcher() - ,labelText() -{ -} - TreeView::TreeView(QWidget *parent) : QTreeView(parent) { @@ -192,26 +176,16 @@ void TreeView::selectionChanged(const QItemSelection &selected, const QItemSelec emit itemsSelected(list); } -TableWidget::TableWidget(QWidget *parent) : - QTableWidget(parent) +TableView::TableView(QWidget *parent) : + QTableView(parent) { } -bool TableWidget::isEditorOpen() +bool TableView::isEditorOpen() { return (state() == QAbstractItemView::EditingState); } -void TableWidget::keyPressEvent(QKeyEvent *event) -{ - if (event->key() == Qt::Key_Return || event->key() == Qt::Key_Enter) - emit enterPressed(); - else if (event->key() == Qt::Key_Delete) - emit deletePressed(); - - QTableWidget::keyPressEvent(event); -} - ListWidget::ListWidget(QWidget *parent) : QListWidget(parent) { @@ -283,7 +257,7 @@ MainWindow::MainWindow(QWidget *parent) : ,m_dirTree(new TreeView(this)) ,m_dirModel(new QFileSystemModel(m_dirTree)) ,m_listWidget(new ListWidget(this)) - ,m_tableWidget(new TableWidget(this)) + ,m_tableView(new TableView(this)) ,m_searchWidget(new QWidget(this)) ,m_searchLineEdit(new QLineEdit(this)) ,m_searchDock(new QDockWidget(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_EDIT_SEARCH), this)) @@ -311,19 +285,17 @@ MainWindow::MainWindow(QWidget *parent) : ,m_logDock(new QDockWidget(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_LOG), this)) ,m_logWidget(new QWidget(this)) ,m_logTextEdit(new LogTextEdit(m_logWidget)) - ,m_imageFormats() ,m_historyPlaylistsItem(NULL) ,m_folderIcon() ,m_customThemeString() - ,m_gridLayout(NULL) + ,m_gridView(new GridView(this)) ,m_gridWidget(new QWidget(this)) ,m_gridScrollArea(new QScrollArea(m_gridWidget)) - ,m_gridItems() ,m_gridLayoutWidget(new FileDropWidget()) ,m_zoomSlider(NULL) ,m_lastZoomSliderValue(0) - ,m_pendingItemUpdates() ,m_viewType(VIEW_TYPE_LIST) + ,m_thumbnailType(THUMBNAIL_TYPE_BOXART) ,m_gridProgressBar(NULL) ,m_gridProgressWidget(NULL) ,m_currentGridHash() @@ -354,6 +326,8 @@ MainWindow::MainWindow(QWidget *parent) : ,m_failedThumbnails(0) ,m_playlistThumbnailDownloadWasCanceled(false) ,m_pendingDirScrollPath() + ,m_thumbnailTimer(new QTimer(this)) + ,m_gridItem(this) { settings_t *settings = config_get_ptr(); QDir playlistDir(settings->paths.directory_playlist); @@ -409,15 +383,10 @@ MainWindow::MainWindow(QWidget *parent) : m_gridWidget->setLayout(new QVBoxLayout()); - m_gridLayout = new FlowLayout(m_gridLayoutWidget); - m_gridLayoutWidget->setObjectName("gridLayoutWidget"); + m_gridView->setSelectionMode(QAbstractItemView::SingleSelection); + m_gridView->setEditTriggers(QAbstractItemView::NoEditTriggers); - m_gridScrollArea->setAlignment(Qt::AlignCenter); - m_gridScrollArea->setFrameShape(QFrame::NoFrame); - m_gridScrollArea->setWidgetResizable(true); - m_gridScrollArea->setWidget(m_gridLayoutWidget); - - m_gridWidget->layout()->addWidget(m_gridScrollArea); + m_gridWidget->layout()->addWidget(m_gridView); m_gridWidget->layout()->setAlignment(Qt::AlignCenter); m_gridWidget->layout()->setContentsMargins(0, 0, 0, 0); @@ -444,7 +413,18 @@ MainWindow::MainWindow(QWidget *parent) : m_gridProgressWidget->hide(); - m_tableWidget->setAlternatingRowColors(true); + m_playlistModel = new PlaylistModel(this); + m_proxyModel = new QSortFilterProxyModel(this); + m_proxyModel->setSourceModel(m_playlistModel); + m_proxyModel->setSortCaseSensitivity(Qt::CaseInsensitive); + + m_tableView->setAlternatingRowColors(true); + m_tableView->setModel(m_proxyModel); + m_tableView->setSortingEnabled(true); + m_tableView->verticalHeader()->setVisible(false); + + m_gridView->setItemDelegate(new ThumbnailDelegate(m_gridItem, this)); + m_gridView->setModel(m_proxyModel); m_logWidget->setObjectName("logWidget"); @@ -557,10 +537,6 @@ MainWindow::MainWindow(QWidget *parent) : connect(m_loadCoreWindow, SIGNAL(coreLoaded()), this, SLOT(onCoreLoaded())); connect(m_loadCoreWindow, SIGNAL(windowClosed()), this, SLOT(onCoreLoadWindowClosed())); connect(m_listWidget, SIGNAL(currentItemChanged(QListWidgetItem*, QListWidgetItem*)), this, SLOT(onCurrentListItemChanged(QListWidgetItem*, QListWidgetItem*))); - connect(m_tableWidget, SIGNAL(currentItemChanged(QTableWidgetItem*, QTableWidgetItem*)), this, SLOT(onCurrentTableItemChanged(QTableWidgetItem*, QTableWidgetItem*))); - connect(m_tableWidget, SIGNAL(itemDoubleClicked(QTableWidgetItem*)), this, SLOT(onContentItemDoubleClicked(QTableWidgetItem*))); - connect(m_tableWidget, SIGNAL(enterPressed()), this, SLOT(onTableWidgetEnterPressed())); - connect(m_tableWidget, SIGNAL(deletePressed()), this, SLOT(onTableWidgetDeletePressed())); connect(m_startCorePushButton, SIGNAL(clicked()), this, SLOT(onStartCoreClicked())); connect(m_coreInfoPushButton, SIGNAL(clicked()), m_coreInfoDialog, SLOT(showCoreInfo())); connect(m_runPushButton, SIGNAL(clicked()), this, SLOT(onRunClicked())); @@ -590,9 +566,26 @@ MainWindow::MainWindow(QWidget *parent) : connect(m_thumbnailPackDownloadProgressDialog, SIGNAL(canceled()), this, SLOT(onThumbnailPackDownloadCanceled())); connect(this, SIGNAL(itemChanged()), this, SLOT(onItemChanged())); - connect(this, SIGNAL(gridItemChanged(QString)), this, SLOT(onGridItemChanged(QString))); connect(this, SIGNAL(gotThumbnailDownload(QString,QString)), this, SLOT(onDownloadThumbnail(QString,QString))); + m_thumbnailTimer->setSingleShot(true); + connect(m_thumbnailTimer, SIGNAL(timeout()), this, SLOT(updateVisibleItems())); + connect(this, SIGNAL(updateThumbnails()), this, SLOT(updateVisibleItems())); + + /* TODO: Handle scroll and resize differently. */ + connect(m_gridView, SIGNAL(visibleItemsChangedMaybe()), this, SLOT(startTimer())); + + connect(m_gridView, SIGNAL(clicked(const QModelIndex&)), this, SLOT(currentItemChanged(const QModelIndex&))); + connect(m_tableView, SIGNAL(clicked(const QModelIndex&)), this, SLOT(currentItemChanged(const QModelIndex&))); + + connect(m_gridView->selectionModel(), SIGNAL(currentChanged(const QModelIndex& , const QModelIndex&)), this, SLOT(currentItemChanged(const QModelIndex&))); + connect(m_tableView->selectionModel(), SIGNAL(currentChanged(const QModelIndex&, const QModelIndex&)), this, SLOT(currentItemChanged(const QModelIndex&))); + + connect(m_gridView, SIGNAL(doubleClicked(const QModelIndex&)), this, SLOT(onContentItemDoubleClicked(const QModelIndex&))); + connect(m_tableView, SIGNAL(doubleClicked(const QModelIndex&)), this, SLOT(onContentItemDoubleClicked(const QModelIndex&))); + + connect(m_playlistModel, SIGNAL(dataChanged(const QModelIndex&, const QModelIndex&, const QVector&)), this, SLOT(onCurrentTableItemDataChanged(const QModelIndex&, const QModelIndex&, const QVector&))); + /* make sure these use an auto connection so it will be queued if called from a different thread (some facilities in RA log messages from other threads) */ connect(this, SIGNAL(gotLogMessage(const QString&)), this, SLOT(onGotLogMessage(const QString&)), Qt::AutoConnection); connect(this, SIGNAL(gotStatusMessage(QString,unsigned,unsigned,bool)), this, SLOT(onGotStatusMessage(QString,unsigned,unsigned,bool)), Qt::AutoConnection); @@ -651,8 +644,38 @@ MainWindow::~MainWindow() delete m_thumbnailPixmap2; if (m_thumbnailPixmap3) delete m_thumbnailPixmap3; +} - removeGridItems(); +void MainWindow::startTimer() { + if (m_thumbnailTimer->isActive()) + { + m_thumbnailTimer->stop(); + m_thumbnailTimer->start(50); + } + else + { + m_thumbnailTimer->start(50); + } +} + +void MainWindow::updateVisibleItems() { + if (m_viewType == VIEW_TYPE_ICONS) + { + QVector indexes = m_gridView->visibleIndexes(); + int i; + for (i = 0; i < indexes.size(); i++) + { + m_playlistModel->loadThumbnail(m_proxyModel->mapToSource(indexes.at(i))); + } + } +} + +void MainWindow::setThumbnailCacheLimit(int count) +{ + if (count < 1) + count = 0; + + m_playlistModel->setThumbnailCacheLimit(count); } void MainWindow::onFileSystemDirLoaded(const QString &path) @@ -695,44 +718,11 @@ QVector > MainWindow::getPlaylists() return playlists; } -void MainWindow::onGridItemChanged(QString title) -{ - int i; - - for (i = 0; i < m_gridItems.count(); i++) - { - const QPointer &item = m_gridItems.at(i); - const QHash &hash = item->hash; - - if (hash.value("label_noext") == title) - { - loadImageDeferred(item.data(), item->widget->property("image_path").toString()); - break; - } - } -} - void MainWindow::onItemChanged() { - ViewType viewType = getCurrentViewType(); - - currentItemChanged(getCurrentContentHash()); - - if (viewType == VIEW_TYPE_ICONS) - { - int i; - - for (i = 0; i < m_gridItems.count(); i++) - { - const QPointer &item = m_gridItems.at(i); - - if (item->widget == m_currentGridWidget) - { - loadImageDeferred(item.data(), m_currentGridWidget->property("image_path").toString()); - break; - } - } - } + QModelIndex index = getCurrentContentIndex(); + m_playlistModel->reloadThumbnail(index); + currentItemChanged(index); } QString MainWindow::getSpecialPlaylistPath(SpecialPlaylist playlist) @@ -750,50 +740,6 @@ double MainWindow::lerp(double x, double y, double a, double b, double d) { return a + (b - a) * ((double)(d - x) / (double)(y - x)); } -void MainWindow::onGridItemClicked(ThumbnailWidget *widget) -{ - QHash hash; - ThumbnailWidget *w = static_cast(sender()); - - if (!w) - { - if (widget) - w = widget; - else - return; - } - - if (m_currentGridWidget) - { - m_currentGridWidget->setObjectName("thumbnailWidget"); - m_currentGridWidget->style()->unpolish(m_currentGridWidget); - m_currentGridWidget->style()->polish(m_currentGridWidget); - } - - hash = w->property("hash").value >(); - w->setObjectName("thumbnailWidgetSelected"); - w->style()->unpolish(w); - w->style()->polish(w); - - m_currentGridWidget = w; - m_currentGridHash = hash; - - currentItemChanged(hash); -} - -void MainWindow::onGridItemDoubleClicked() -{ - QHash hash; - ThumbnailWidget *w = static_cast(sender()); - - if (!w) - return; - - hash = w->property("hash").value >(); - - loadContent(hash); -} - void MainWindow::onIconViewClicked() { setCurrentViewType(VIEW_TYPE_ICONS); @@ -806,35 +752,18 @@ void MainWindow::onListViewClicked() onCurrentListItemChanged(m_listWidget->currentItem(), NULL); } -void MainWindow::calcGridItemSize(GridItem *item, int zoomValue) +void MainWindow::onZoomValueChanged(int zoomValue) { int newSize = 0; - QLabel *label = NULL; if (zoomValue < 50) newSize = expScale(lerp(0, 49, 25, 49, zoomValue) / 50.0, 102, 256); else newSize = expScale(zoomValue / 100.0, 256, 1024); - item->widget->setFixedSize(QSize(newSize, newSize)); + m_gridView->setGridSize(newSize); - label = item->widget->findChild("thumbnailQLabel"); - - if (label) - setElidedText(label, item->widget, item->widget->layout()->contentsMargins().left() + item->widget->layout()->spacing() + 2, item->labelText); -} - -void MainWindow::onZoomValueChanged(int value) -{ - int i; - - for (i = 0; i < m_gridItems.count(); i++) - { - GridItem *item = m_gridItems.at(i); - calcGridItemSize(item, value); - } - - m_lastZoomSliderValue = value; + m_lastZoomSliderValue = zoomValue; } void MainWindow::showWelcomeScreen() @@ -1212,6 +1141,8 @@ void MainWindow::setTheme(Theme theme) { m_currentTheme = theme; + setDefaultCustomProperties(); + switch(theme) { case THEME_SYSTEM_DEFAULT: @@ -1237,6 +1168,21 @@ void MainWindow::setTheme(Theme theme) } } +void MainWindow::setDefaultCustomProperties() +{ + m_gridView->setLayout(QString(DEFAULT_GRID_LAYOUT)); + m_gridView->setSpacing(DEFAULT_GRID_SPACING); + m_gridItem.setThumbnailVerticalAlign(QString(DEFAULT_GRID_ITEM_THUMBNAIL_ALIGNMENT)); + m_gridItem.setPadding(DEFAULT_GRID_ITEM_MARGIN); +} + +void MainWindow::changeThumbnailType(ThumbnailType type) +{ + m_playlistModel->setThumbnailType(type); + updateVisibleItems(); + m_gridView->viewport()->update(); +} + QVector > MainWindow::getCoreInfo() { QVector > infoList; @@ -1545,66 +1491,7 @@ void MainWindow::onTreeViewItemsSelected(QModelIndexList selectedIndexes) void MainWindow::selectBrowserDir(QString path) { - QStringList horizontal_header_labels; - QDir dir = path; - QStringList dirList; - int i = 0; - - horizontal_header_labels << msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_NAME); - - /* block this signal because setData() called in addPlaylistHashToTable() would trigger an infinite loop */ - disconnect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); - - m_tableWidget->clear(); - m_tableWidget->setColumnCount(0); - m_tableWidget->setRowCount(0); - m_tableWidget->setSelectionBehavior(QAbstractItemView::SelectRows); - m_tableWidget->setSelectionMode(QAbstractItemView::SingleSelection); - m_tableWidget->setSortingEnabled(false); - m_tableWidget->setColumnCount(1); - m_tableWidget->setRowCount(0); - m_tableWidget->setHorizontalHeaderLabels(horizontal_header_labels); - m_tableWidget->setHorizontalScrollBarPolicy(Qt::ScrollBarAsNeeded); - m_tableWidget->setHorizontalScrollMode(QAbstractItemView::ScrollPerPixel); - - dirList = dir.entryList(QDir::NoDotAndDotDot | - QDir::Readable | - QDir::Files | - (m_settings->value("show_hidden_files", true).toBool() ? (QDir::Hidden | QDir::System) : static_cast(0)), - QDir::Name); - - if (dirList.count() == 0) - return; - - m_tableWidget->setRowCount(dirList.count()); - - for (i = 0; i < dirList.count(); i++) - { - QString fileName = dirList.at(i); - QTableWidgetItem *item = new QTableWidgetItem(fileName); - QHash hash; - QString filePath(QDir::toNativeSeparators(dir.absoluteFilePath(fileName))); - QFileInfo fileInfo(filePath); - - hash["path"] = filePath; - hash["label"] = hash["path"]; - hash["label_noext"] = fileInfo.completeBaseName(); - hash["db_name"] = fileInfo.dir().dirName(); - - item->setData(Qt::UserRole, QVariant::fromValue >(hash)); - item->setFlags(item->flags() & ~Qt::ItemIsEditable); - - m_tableWidget->setItem(i, 0, item); - } - - m_tableWidget->setSortingEnabled(true); - m_tableWidget->resizeColumnsToContents(); - m_tableWidget->sortByColumn(0, Qt::AscendingOrder); - m_tableWidget->selectRow(0); - - onSearchEnterPressed(); - - connect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); + m_playlistModel->addDir(path, m_settings->value("show_hidden_files", true).toBool() ? (QDir::Hidden | QDir::System) : static_cast(0)); } QTabWidget* MainWindow::browserAndPlaylistTabWidget() @@ -1612,45 +1499,40 @@ QTabWidget* MainWindow::browserAndPlaylistTabWidget() return m_browserAndPlaylistTabWidget; } -void MainWindow::onTableWidgetEnterPressed() +void MainWindow::onDropWidgetEnterPressed() { #if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0)) /* entry is being renamed, ignore this enter press */ - if (m_tableWidget->isPersistentEditorOpen(m_tableWidget->currentIndex())) + if (m_tableView->isPersistentEditorOpen(m_tableView->currentIndex())) #else /* we can only check if any editor at all is open */ - if (m_tableWidget->isEditorOpen()) + if (m_tableView->isEditorOpen()) #endif return; onRunClicked(); } -void MainWindow::onTableWidgetDeletePressed() +QModelIndex MainWindow::getCurrentContentIndex() { - deleteCurrentPlaylistItem(); + if (m_viewType == VIEW_TYPE_LIST) + { + return m_tableView->currentIndex(); + } + else if (m_viewType == VIEW_TYPE_ICONS) + { + return m_gridView->currentIndex(); + } + return QModelIndex(); } QHash MainWindow::getCurrentContentHash() { - QTableWidgetItem *contentItem = m_tableWidget->currentItem(); - QHash contentHash; - ViewType viewType = getCurrentViewType(); - - if (viewType == VIEW_TYPE_LIST) - { - if (!contentItem) - return contentHash; - - contentHash = contentItem->data(Qt::UserRole).value >(); - } - else if (viewType == VIEW_TYPE_ICONS) - contentHash = m_currentGridHash; - - return contentHash; + return getCurrentContentIndex().data(PlaylistModel::HASH).value >(); } -void MainWindow::onContentItemDoubleClicked(QTableWidgetItem*) +void MainWindow::onContentItemDoubleClicked(const QModelIndex &index) { + Q_UNUSED(index); onRunClicked(); } @@ -1677,13 +1559,12 @@ QHash MainWindow::getSelectedCore() CoreSelection coreSelection = static_cast(coreMap.value("core_selection").toInt()); QHash coreHash; QHash contentHash; - QTableWidgetItem *contentItem = m_tableWidget->currentItem(); ViewType viewType = getCurrentViewType(); - if (viewType == VIEW_TYPE_LIST && contentItem) - contentHash = contentItem->data(Qt::UserRole).value >(); + if (viewType == VIEW_TYPE_LIST) + contentHash = m_tableView->currentIndex().data(PlaylistModel::HASH).value >(); else if (viewType == VIEW_TYPE_ICONS) - contentHash = m_currentGridHash; + contentHash = m_gridView->currentIndex().data(PlaylistModel::HASH).value >(); else return coreHash; @@ -1747,7 +1628,6 @@ label_noext - the display name of the content that is guaranteed not to contain */ void MainWindow::loadContent(const QHash &contentHash) { -#ifdef HAVE_MENU content_ctx_info_t content_info; QByteArray corePathArray; QByteArray contentPathArray; @@ -1861,48 +1741,33 @@ void MainWindow::loadContent(const QHash &contentHash) content_info.args = NULL; content_info.environ_get = NULL; +#ifdef HAVE_MENU menu_navigation_set_selection(0); +#endif + command_event(CMD_EVENT_UNLOAD_CORE, NULL); - if (!task_push_load_content_from_playlist_from_menu( - corePath, contentPath, contentLabel, - &content_info, - NULL, NULL)) + if (!task_push_load_content_with_new_core_from_companion_ui( + corePath, contentPath, &content_info, + NULL, NULL)) { QMessageBox::critical(this, msg_hash_to_str(MSG_ERROR), msg_hash_to_str(MSG_FAILED_TO_LOAD_CONTENT)); return; } +#ifdef HAVE_MENU menu_driver_ctl(RARCH_MENU_CTL_SET_PENDING_QUICK_MENU, NULL); #endif } void MainWindow::onRunClicked() { -#ifdef HAVE_MENU - QTableWidgetItem *item = m_tableWidget->currentItem(); - ViewType viewType = getCurrentViewType(); - QHash contentHash; + QHash contentHash = getCurrentContentHash(); - if (viewType == VIEW_TYPE_LIST) - { - if (!item) - return; - - contentHash = item->data(Qt::UserRole).value >(); - } - else if (viewType == VIEW_TYPE_ICONS) - { - contentHash = m_currentGridHash; - - if (contentHash.isEmpty()) - return; - } - else + if (contentHash.isEmpty()) return; loadContent(contentHash); -#endif } bool MainWindow::isContentLessCore() @@ -1932,10 +1797,9 @@ ViewOptionsDialog* MainWindow::viewOptionsDialog() void MainWindow::setCoreActions() { - QTableWidgetItem *currentContentItem = m_tableWidget->currentItem(); QListWidgetItem *currentPlaylistItem = m_listWidget->currentItem(); ViewType viewType = getCurrentViewType(); - QHash hash; + QHash hash = getCurrentContentHash(); m_launchWithComboBox->clear(); @@ -1953,11 +1817,6 @@ void MainWindow::setCoreActions() m_launchWithComboBox->addItem(m_currentCore, QVariant::fromValue(comboBoxMap)); } - if (viewType == VIEW_TYPE_LIST && currentContentItem) - hash = currentContentItem->data(Qt::UserRole).value >(); - else if (viewType == VIEW_TYPE_ICONS) - hash = m_currentGridHash; - if (m_browserAndPlaylistTabWidget->tabText(m_browserAndPlaylistTabWidget->currentIndex()) == msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_TAB_PLAYLISTS)) { if (!hash.isEmpty()) @@ -2050,35 +1909,38 @@ void MainWindow::setCoreActions() core_info_get_list(&coreInfoList); - for (j = 0; j < coreInfoList->count; j++) + if (coreInfoList) { - const core_info_t *info = &coreInfoList->list[j]; - - if (core == info->path) + for (j = 0; j < coreInfoList->count; j++) { - if (m_launchWithComboBox->findText(info->core_name) == -1) + const core_info_t *info = &coreInfoList->list[j]; + + if (core == info->path) { - int i = 0; - bool found_existing = false; - - for (i = 0; i < m_launchWithComboBox->count(); i++) + if (m_launchWithComboBox->findText(info->core_name) == -1) { - QVariantMap map = m_launchWithComboBox->itemData(i, Qt::UserRole).toMap(); + int i = 0; + bool found_existing = false; - if (map.value("core_path").toString() == info->path || map.value("core_name").toString() == info->core_name) + for (i = 0; i < m_launchWithComboBox->count(); i++) { - found_existing = true; - break; - } - } + QVariantMap map = m_launchWithComboBox->itemData(i, Qt::UserRole).toMap(); - if (!found_existing) - { - QVariantMap comboBoxMap; - comboBoxMap["core_name"] = info->core_name; - comboBoxMap["core_path"] = info->path; - comboBoxMap["core_selection"] = CORE_SELECTION_PLAYLIST_DEFAULT; - m_launchWithComboBox->addItem(info->core_name, QVariant::fromValue(comboBoxMap)); + if (map.value("core_path").toString() == info->path || map.value("core_name").toString() == info->core_name) + { + found_existing = true; + break; + } + } + + if (!found_existing) + { + QVariantMap comboBoxMap; + comboBoxMap["core_name"] = info->core_name; + comboBoxMap["core_path"] = info->path; + comboBoxMap["core_selection"] = CORE_SELECTION_PLAYLIST_DEFAULT; + m_launchWithComboBox->addItem(info->core_name, QVariant::fromValue(comboBoxMap)); + } } } } @@ -2113,10 +1975,6 @@ void MainWindow::onTabWidgetIndexChanged(int index) /* force list view for file browser, will set it back to whatever the user had when switching back to playlist tab */ setCurrentViewType(VIEW_TYPE_LIST); - m_tableWidget->clear(); - m_tableWidget->setColumnCount(0); - m_tableWidget->setRowCount(0); - if (index.isValid()) { m_dirTree->clearSelection(); @@ -2130,10 +1988,6 @@ void MainWindow::onTabWidgetIndexChanged(int index) if (m_lastViewType != getCurrentViewType()) setCurrentViewType(m_lastViewType); - m_tableWidget->clear(); - m_tableWidget->setColumnCount(0); - m_tableWidget->setRowCount(0); - if (item) { m_listWidget->setCurrentItem(NULL); @@ -2167,8 +2021,6 @@ QComboBox* MainWindow::launchWithComboBox() void MainWindow::onSearchLineEditEdited(const QString &text) { int i = 0; - QList items; - QVector > gridItems; QVector textUnicode = text.toUcs4(); QVector textHiraToKata; QVector textKataToHira; @@ -2197,112 +2049,21 @@ void MainWindow::onSearchLineEditEdited(const QString &text) } } - switch(viewType) + if (!foundHira && !foundKata) { - case VIEW_TYPE_LIST: - { - if (text.isEmpty()) - { - for (i = 0; i < m_tableWidget->rowCount(); i++) - { - m_tableWidget->setRowHidden(i, false); - } - return; - } - - items.append(m_tableWidget->findItems(text, Qt::MatchContains)); - - if (foundHira) - { - items.append(m_tableWidget->findItems(QString::fromUcs4(textHiraToKata.constData(), textHiraToKata.size()), Qt::MatchContains)); - } - - if (foundKata) - { - items.append(m_tableWidget->findItems(QString::fromUcs4(textKataToHira.constData(), textKataToHira.size()), Qt::MatchContains)); - } - - if (items.isEmpty()) - { - for (i = 0; i < m_tableWidget->rowCount(); i++) - { - m_tableWidget->setRowHidden(i, true); - } - - return; - } - else - { - for (i = 0; i < m_tableWidget->rowCount(); i++) - { - if (items.contains(m_tableWidget->item(i, 0))) - m_tableWidget->setRowHidden(i, false); - else - m_tableWidget->setRowHidden(i, true); - } - } - - break; - } - case VIEW_TYPE_ICONS: - { - int i; - - if (text.isEmpty()) - { - for (i = 0; i < m_gridItems.size(); i++) - { - m_gridItems.at(i)->widget->show(); - } - return; - } - - for (i = 0; i < m_gridItems.count(); i++) - { - const QPointer &item = m_gridItems.at(i); - - if (item->hash.value("label").contains(text, Qt::CaseInsensitive)) - gridItems.append(item); - - if (foundHira) - { - if (item->hash.value("label").contains(QString::fromUcs4(textHiraToKata.constData(), textHiraToKata.size()), Qt::CaseInsensitive)) - gridItems.append(item); - } - - if (foundKata) - { - if (item->hash.value("label").contains(QString::fromUcs4(textKataToHira.constData(), textKataToHira.size()), Qt::CaseInsensitive)) - gridItems.append(item); - } - } - - if (gridItems.isEmpty()) - { - for (i = 0; i < m_gridItems.size(); i++) - { - m_gridItems.at(i)->widget->hide(); - } - - return; - } - else - { - for (i = 0; i < m_gridItems.size(); i++) - { - const QPointer &item = m_gridItems.at(i); - - if (gridItems.contains(item)) - item->widget->show(); - else - item->widget->hide(); - } - } - - break; - } - default: - break; + m_proxyModel->setFilterRegExp(QRegExp(text, Qt::CaseInsensitive)); + } + else if (foundHira && !foundKata) + { + m_proxyModel->setFilterRegExp(QRegExp(text + "|" + QString::fromUcs4(textHiraToKata.constData(), textHiraToKata.size()), Qt::CaseInsensitive)); + } + else if (!foundHira && foundKata) + { + m_proxyModel->setFilterRegExp(QRegExp(text + "|" + QString::fromUcs4(textKataToHira.constData(), textKataToHira.size()), Qt::CaseInsensitive)); + } + else + { + m_proxyModel->setFilterRegExp(QRegExp(text + "|" + QString::fromUcs4(textHiraToKata.constData(), textHiraToKata.size()) + "|" + QString::fromUcs4(textKataToHira.constData(), textKataToHira.size()), Qt::CaseInsensitive)); } } @@ -2378,39 +2139,21 @@ void MainWindow::onSearchEnterPressed() onSearchLineEditEdited(m_searchLineEdit->text()); } -void MainWindow::onCurrentTableItemChanged(QTableWidgetItem *current, QTableWidgetItem *) +void MainWindow::onCurrentTableItemDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight, const QVector &roles) { QHash hash; - if (!current) + if (!roles.contains(Qt::EditRole)) return; - hash = current->data(Qt::UserRole).value >(); - - currentItemChanged(hash); -} - -void MainWindow::onCurrentTableItemDataChanged(QTableWidgetItem *item) -{ - QHash hash; - - if (!item) + if (topLeft != bottomRight) return; - /* block this signal because setData() would trigger an infinite loop here */ - disconnect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); - - hash = item->data(Qt::UserRole).value >(); - hash["label"] = item->text(); - hash["label_noext"] = QFileInfo(item->text()).completeBaseName(); - - item->setData(Qt::UserRole, QVariant::fromValue(hash)); + hash = topLeft.data(PlaylistModel::HASH).value>(); updateCurrentPlaylistEntry(hash); - currentItemChanged(hash); - - connect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); + currentItemChanged(topLeft); } void MainWindow::onCurrentListItemDataChanged(QListWidgetItem *item) @@ -2485,7 +2228,7 @@ void MainWindow::renamePlaylistItem(QListWidgetItem *item, QString newName) connect(m_listWidget, SIGNAL(itemChanged(QListWidgetItem*)), this, SLOT(onCurrentListItemDataChanged(QListWidgetItem*))); } -void MainWindow::currentItemChanged(const QHash &hash) +void MainWindow::currentItemChanged(const QModelIndex &index) { settings_t *settings = config_get_ptr(); QString label; @@ -2494,6 +2237,8 @@ void MainWindow::currentItemChanged(const QHash &hash) QString extensionStr; int lastIndex = -1; + const QHash &hash = index.data(PlaylistModel::HASH).value>(); + label = hash["label_noext"]; label.replace(m_fileSanitizerRegex, "_"); @@ -2618,7 +2363,7 @@ void MainWindow::setCurrentViewType(ViewType viewType) { case VIEW_TYPE_ICONS: { - m_tableWidget->hide(); + m_tableView->hide(); m_gridWidget->show(); break; } @@ -2627,48 +2372,48 @@ void MainWindow::setCurrentViewType(ViewType viewType) { m_viewType = VIEW_TYPE_LIST; m_gridWidget->hide(); - m_tableWidget->show(); + m_tableView->show(); break; } } } +void MainWindow::setCurrentThumbnailType(ThumbnailType thumbnailType) +{ + m_lastThumbnailType = m_thumbnailType; + m_thumbnailType = thumbnailType; + + m_playlistModel->setThumbnailType(thumbnailType); + updateVisibleItems(); + m_gridView->viewport()->update(); +} + MainWindow::ViewType MainWindow::getCurrentViewType() { return m_viewType; } +ThumbnailType MainWindow::getCurrentThumbnailType() +{ + return m_thumbnailType; +} + void MainWindow::onCurrentListItemChanged(QListWidgetItem *current, QListWidgetItem *previous) { - ViewType viewType = getCurrentViewType(); - Q_UNUSED(current) Q_UNUSED(previous) if (m_browserAndPlaylistTabWidget->tabText(m_browserAndPlaylistTabWidget->currentIndex()) != msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_TAB_PLAYLISTS)) return; - switch (viewType) - { - case VIEW_TYPE_ICONS: - { - initContentGridLayout(); - break; - } - case VIEW_TYPE_LIST: - default: - { - initContentTableWidget(); - break; - } - } + initContentTableWidget(); setCoreActions(); } -TableWidget* MainWindow::contentTableWidget() +TableView* MainWindow::contentTableView() { - return m_tableWidget; + return m_tableView; } QWidget* MainWindow::contentGridWidget() @@ -2676,9 +2421,9 @@ QWidget* MainWindow::contentGridWidget() return m_gridWidget; } -FlowLayout* MainWindow::contentGridLayout() +GridView* MainWindow::contentGridView() { - return m_gridLayout; + return m_gridView; } void MainWindow::onBrowserDownloadsClicked() @@ -2769,7 +2514,9 @@ void MainWindow::onTimeout() void MainWindow::onStopClicked() { +#ifdef HAVE_MENU menu_navigation_set_selection(0); +#endif command_event(CMD_EVENT_UNLOAD_CORE, NULL); setCurrentCoreLabel(); activateWindow(); @@ -2856,7 +2603,9 @@ void MainWindow::onUnloadCoreMenuAction() { QAction *action = qobject_cast(sender()); +#ifdef HAVE_MENU menu_navigation_set_selection(0); +#endif if (!command_event(CMD_EVENT_UNLOAD_CORE, NULL)) { @@ -2883,184 +2632,12 @@ void MainWindow::onLoadCoreClicked(const QStringList &extensionFilters) m_loadCoreWindow->initCoreList(extensionFilters); } -void MainWindow::removeGridItems() -{ - if (m_gridItems.count() > 0) - { - QMutableVectorIterator > items(m_gridItems); - - m_pendingItemUpdates.clear(); - - while (items.hasNext()) - { - QPointer item = items.next(); - - if (item) - { - item->imageWatcher.waitForFinished(); - - items.remove(); - - m_gridLayout->removeWidget(item->widget); - - delete item->widget; - delete item; - } - } - } -} - -void MainWindow::onDeferredImageLoaded() -{ - const QFutureWatcher *watcher = static_cast*>(sender()); - GridItem *item = NULL; - - if (!watcher) - return; - - item = watcher->result(); - - if (!item) - return; - - if (m_gridItems.contains(item)) - { - if (!item->image.isNull()) - { - m_pendingItemUpdates.append(item); - QTimer::singleShot(0, this, SLOT(onPendingItemUpdates())); - } - } -} - -void MainWindow::onPendingItemUpdates() -{ - QMutableListIterator list(m_pendingItemUpdates); - - while (list.hasNext()) - { - GridItem *item = list.next(); - - if (!item) - continue; - - if (m_gridItems.contains(item)) - onUpdateGridItemPixmapFromImage(item); - - list.remove(); - } -} - -void MainWindow::onUpdateGridItemPixmapFromImage(GridItem *item) -{ - if (!item) - return; - - if (!m_gridItems.contains(item)) - return; - - item->label->setPixmap(QPixmap::fromImage(item->image)); - item->label->update(); -} - -void MainWindow::loadImageDeferred(GridItem *item, QString path) -{ - connect(&item->imageWatcher, SIGNAL(finished()), this, SLOT(onDeferredImageLoaded()), Qt::QueuedConnection); - item->imageWatcher.setFuture(QtConcurrent::run(this, &MainWindow::doDeferredImageLoad, item, path)); -} - -GridItem* MainWindow::doDeferredImageLoad(GridItem *item, QString path) -{ - /* this runs in another thread */ - if (!item) - return NULL; - - /* While we are indeed writing across thread boundaries here, the image is never accessed until after - * its thread finishes, and the item is never deleted without first waiting for the thread to finish. - */ - item->image = QImage(path); - - return item; -} - -void MainWindow::initContentGridLayout() -{ - QListWidgetItem *item = m_listWidget->currentItem(); - QString path; - - if (!item) - return; - - m_gridProgressBar->setMinimum(0); - m_gridProgressBar->setMaximum(0); - m_gridProgressBar->setValue(0); - m_gridProgressWidget->show(); - - removeGridItems(); - - m_currentGridHash.clear(); - - if (m_currentGridWidget) - { - m_currentGridWidget->setObjectName("thumbnailWidget"); - m_currentGridWidget->style()->unpolish(m_currentGridWidget); - m_currentGridWidget->style()->polish(m_currentGridWidget); - } - - m_currentGridWidget = NULL; - - path = item->data(Qt::UserRole).toString(); - - if (path == ALL_PLAYLISTS_TOKEN) - { - settings_t *settings = config_get_ptr(); - QDir playlistDir(settings->paths.directory_playlist); - QStringList playlists; - int i = 0; - - for (i = 0; i < m_playlistFiles.count(); i++) - { - const QString &playlist = m_playlistFiles.at(i); - playlists.append(playlistDir.absoluteFilePath(playlist)); - } - - addPlaylistItemsToGrid(playlists, true); - } - else - addPlaylistItemsToGrid(QStringList() << path); - - QTimer::singleShot(0, this, SLOT(onContentGridInited())); -} - -void MainWindow::onContentGridInited() -{ - ThumbnailWidget *thumbnailWidget = NULL; - - m_gridLayoutWidget->resize(m_gridScrollArea->viewport()->size()); - - onZoomValueChanged(m_zoomSlider->value()); - - onSearchEnterPressed(); - - if (m_gridItems.count() > 0) - { - GridItem *gridItem = m_gridItems.at(0); - - if (gridItem) - { - thumbnailWidget = m_gridItems.at(0)->widget.data(); - - if (thumbnailWidget) - onGridItemClicked(thumbnailWidget); - } - } -} - void MainWindow::initContentTableWidget() { QListWidgetItem *item = m_listWidget->currentItem(); QStringList horizontal_header_labels; QString path; + QModelIndex index; int i = 0; if (!item) @@ -3077,23 +2654,11 @@ void MainWindow::initContentTableWidget() m_currentGridWidget = NULL; - horizontal_header_labels << msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_NAME); - - /* block this signal because setData() called in addPlaylistHashToTable() would trigger an infinite loop */ - disconnect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); - - m_tableWidget->clear(); - m_tableWidget->setColumnCount(0); - m_tableWidget->setRowCount(0); - m_tableWidget->setSelectionBehavior(QAbstractItemView::SelectRows); - m_tableWidget->setSelectionMode(QAbstractItemView::SingleSelection); - m_tableWidget->setEditTriggers(QAbstractItemView::SelectedClicked | QAbstractItemView::EditKeyPressed); - m_tableWidget->setSortingEnabled(false); - m_tableWidget->setColumnCount(1); - m_tableWidget->setRowCount(0); - m_tableWidget->setHorizontalHeaderLabels(horizontal_header_labels); - m_tableWidget->setHorizontalScrollBarPolicy(Qt::ScrollBarAsNeeded); - m_tableWidget->setHorizontalScrollMode(QAbstractItemView::ScrollPerPixel); + m_tableView->setSelectionBehavior(QAbstractItemView::SelectRows); + m_tableView->setSelectionMode(QAbstractItemView::SingleSelection); + m_tableView->setEditTriggers(QAbstractItemView::SelectedClicked | QAbstractItemView::EditKeyPressed); + m_tableView->setHorizontalScrollBarPolicy(Qt::ScrollBarAsNeeded); + m_tableView->setHorizontalScrollMode(QAbstractItemView::ScrollPerPixel); path = item->data(Qt::UserRole).toString(); @@ -3110,31 +2675,23 @@ void MainWindow::initContentTableWidget() playlists.append(playlistDir.absoluteFilePath(playlist)); } - addPlaylistItemsToTable(playlists, true); + m_playlistModel->addPlaylistItems(playlists, true); } else - addPlaylistItemsToTable(QStringList() << path); - - m_tableWidget->setSortingEnabled(true); + m_playlistModel->addPlaylistItems(QStringList() << path); if (item != m_historyPlaylistsItem) - m_tableWidget->sortByColumn(0, Qt::AscendingOrder); + m_tableView->sortByColumn(0, Qt::AscendingOrder); + else + m_proxyModel->sort(-1); - m_tableWidget->resizeColumnsToContents(); + m_tableView->resizeColumnsToContents(); - for (i = 0; i < m_tableWidget->rowCount(); i++) - { - /* select the first non-hidden row */ - if (!m_tableWidget->isRowHidden(i)) - { - m_tableWidget->selectRow(i); - break; - } - } - - onSearchEnterPressed(); - - connect(m_tableWidget, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(onCurrentTableItemDataChanged(QTableWidgetItem*))); + index = m_proxyModel->index(0, 0); + m_gridView->scrollToTop(); + m_gridView->setCurrentIndex(index); + m_tableView->setCurrentIndex(index); + currentItemChanged(index); } void MainWindow::keyPressEvent(QKeyEvent *event) @@ -3174,6 +2731,40 @@ QString MainWindow::getCurrentViewTypeString() return QStringLiteral("list"); } +QString MainWindow::getCurrentThumbnailTypeString() +{ + switch (m_thumbnailType) + { + case THUMBNAIL_TYPE_SCREENSHOT: + { + return QStringLiteral("screenshot"); + } + case THUMBNAIL_TYPE_TITLE_SCREEN: + { + return QStringLiteral("title"); + } + case THUMBNAIL_TYPE_BOXART: + default: + { + return QStringLiteral("boxart"); + } + } + + return QStringLiteral("list"); +} + +ThumbnailType MainWindow::getThumbnailTypeFromString(QString thumbnailType) +{ + if (thumbnailType == "boxart") + return THUMBNAIL_TYPE_BOXART; + else if (thumbnailType == "screenshot") + return THUMBNAIL_TYPE_SCREENSHOT; + else if (thumbnailType == "title") + return THUMBNAIL_TYPE_TITLE_SCREEN; + + return THUMBNAIL_TYPE_BOXART; +} + void MainWindow::closeEvent(QCloseEvent *event) { if (m_settings->value("save_geometry", false).toBool()) diff --git a/ui/drivers/qt/viewoptionsdialog.cpp b/ui/drivers/qt/viewoptionsdialog.cpp index 5d9bce0466..dcfa80782d 100644 --- a/ui/drivers/qt/viewoptionsdialog.cpp +++ b/ui/drivers/qt/viewoptionsdialog.cpp @@ -19,7 +19,7 @@ extern "C" { } ViewOptionsDialog::ViewOptionsDialog(MainWindow *mainwindow, QWidget *parent) : - QDialog(parent) + QDialog(mainwindow) ,m_mainwindow(mainwindow) ,m_settings(mainwindow->settings()) ,m_saveGeometryCheckBox(new QCheckBox(this)) @@ -27,6 +27,8 @@ ViewOptionsDialog::ViewOptionsDialog(MainWindow *mainwindow, QWidget *parent) : ,m_saveLastTabCheckBox(new QCheckBox(this)) ,m_showHiddenFilesCheckBox(new QCheckBox(this)) ,m_themeComboBox(new QComboBox(this)) + ,m_thumbnailComboBox(new QComboBox(this)) + ,m_thumbnailCacheSpinBox(new QSpinBox(this)) ,m_startupPlaylistComboBox(new QComboBox(this)) ,m_highlightColorPushButton(new QPushButton(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_CHOOSE), this)) ,m_highlightColor() @@ -45,6 +47,13 @@ ViewOptionsDialog::ViewOptionsDialog(MainWindow *mainwindow, QWidget *parent) : m_themeComboBox->addItem(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THEME_DARK), MainWindow::THEME_DARK); m_themeComboBox->addItem(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THEME_CUSTOM), MainWindow::THEME_CUSTOM); + m_thumbnailComboBox->addItem(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_THUMBNAIL_BOXART), THUMBNAIL_TYPE_BOXART); + m_thumbnailComboBox->addItem(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_THUMBNAIL_SCREENSHOT), THUMBNAIL_TYPE_SCREENSHOT); + m_thumbnailComboBox->addItem(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_THUMBNAIL_TITLE_SCREEN), THUMBNAIL_TYPE_TITLE_SCREEN); + + m_thumbnailCacheSpinBox->setSuffix(" MB"); + m_thumbnailCacheSpinBox->setRange(0, 99999); + m_allPlaylistsListMaxCountSpinBox->setRange(0, 99999); m_allPlaylistsGridMaxCountSpinBox->setRange(0, 99999); @@ -67,6 +76,8 @@ ViewOptionsDialog::ViewOptionsDialog(MainWindow *mainwindow, QWidget *parent) : form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_ALL_PLAYLISTS_LIST_MAX_COUNT), m_allPlaylistsListMaxCountSpinBox); form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_ALL_PLAYLISTS_GRID_MAX_COUNT), m_allPlaylistsGridMaxCountSpinBox); form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_STARTUP_PLAYLIST), m_startupPlaylistComboBox); + form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_TYPE), m_thumbnailComboBox); + form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THUMBNAIL_CACHE_LIMIT), m_thumbnailCacheSpinBox); form->addRow(msg_hash_to_str(MENU_ENUM_LABEL_VALUE_QT_MENU_VIEW_OPTIONS_THEME), m_themeComboBox); form->addRow(m_highlightColorLabel, m_highlightColorPushButton); @@ -77,9 +88,16 @@ ViewOptionsDialog::ViewOptionsDialog(MainWindow *mainwindow, QWidget *parent) : loadViewOptions(); connect(m_themeComboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(onThemeComboBoxIndexChanged(int))); + connect(m_thumbnailComboBox, SIGNAL(currentIndexChanged(int)), this, SLOT(onThumbnailComboBoxIndexChanged(int))); connect(m_highlightColorPushButton, SIGNAL(clicked()), this, SLOT(onHighlightColorChoose())); } +void ViewOptionsDialog::onThumbnailComboBoxIndexChanged(int index) +{ + ThumbnailType type = static_cast(m_thumbnailComboBox->currentData().value()); + m_mainwindow->setCurrentThumbnailType(type); +} + void ViewOptionsDialog::onThemeComboBoxIndexChanged(int) { MainWindow::Theme theme = static_cast(m_themeComboBox->currentData(Qt::UserRole).toInt()); @@ -138,6 +156,7 @@ void ViewOptionsDialog::loadViewOptions() QVector > playlists = m_mainwindow->getPlaylists(); QString initialPlaylist = m_settings->value("initial_playlist", m_mainwindow->getSpecialPlaylistPath(SPECIAL_PLAYLIST_HISTORY)).toString(); int themeIndex = 0; + int thumbnailIndex = 0; int playlistIndex = 0; int i; @@ -148,12 +167,18 @@ void ViewOptionsDialog::loadViewOptions() m_suggestLoadedCoreFirstCheckBox->setChecked(m_settings->value("suggest_loaded_core_first", false).toBool()); m_allPlaylistsListMaxCountSpinBox->setValue(m_settings->value("all_playlists_list_max_count", 0).toInt()); m_allPlaylistsGridMaxCountSpinBox->setValue(m_settings->value("all_playlists_grid_max_count", 5000).toInt()); + m_thumbnailCacheSpinBox->setValue(m_settings->value("thumbnail_cache_limit", 512).toInt()); themeIndex = m_themeComboBox->findData(m_mainwindow->getThemeFromString(m_settings->value("theme", "default").toString())); if (m_themeComboBox->count() > themeIndex) m_themeComboBox->setCurrentIndex(themeIndex); + thumbnailIndex = m_thumbnailComboBox->findData(m_mainwindow->getThumbnailTypeFromString(m_settings->value("icon_view_thumbnail_type", "boxart").toString())); + + if (m_thumbnailComboBox->count() > thumbnailIndex) + m_thumbnailComboBox->setCurrentIndex(thumbnailIndex); + if (highlightColor.isValid()) { m_highlightColor = highlightColor; @@ -204,12 +229,15 @@ void ViewOptionsDialog::saveViewOptions() m_settings->setValue("all_playlists_list_max_count", m_allPlaylistsListMaxCountSpinBox->value()); m_settings->setValue("all_playlists_grid_max_count", m_allPlaylistsGridMaxCountSpinBox->value()); m_settings->setValue("initial_playlist", m_startupPlaylistComboBox->currentData(Qt::UserRole).toString()); + m_settings->setValue("icon_view_thumbnail_type", m_mainwindow->getCurrentThumbnailTypeString()); + m_settings->setValue("thumbnail_cache_limit", m_thumbnailCacheSpinBox->value()); if (!m_mainwindow->customThemeString().isEmpty()) m_settings->setValue("custom_theme", m_customThemePath); m_mainwindow->setAllPlaylistsListMaxCount(m_allPlaylistsListMaxCountSpinBox->value()); m_mainwindow->setAllPlaylistsGridMaxCount(m_allPlaylistsGridMaxCountSpinBox->value()); + m_mainwindow->setThumbnailCacheLimit(m_thumbnailCacheSpinBox->value()); } void ViewOptionsDialog::onAccepted() @@ -229,11 +257,12 @@ void ViewOptionsDialog::onRejected() void ViewOptionsDialog::showDialog() { loadViewOptions(); + setWindowFlags(windowFlags() | Qt::Tool); show(); + activateWindow(); } void ViewOptionsDialog::hideDialog() { reject(); } - diff --git a/ui/drivers/qt/viewoptionsdialog.h b/ui/drivers/qt/viewoptionsdialog.h index faf0f143df..4e9ff4c76a 100644 --- a/ui/drivers/qt/viewoptionsdialog.h +++ b/ui/drivers/qt/viewoptionsdialog.h @@ -24,6 +24,7 @@ public slots: void onRejected(); private slots: void onThemeComboBoxIndexChanged(int index); + void onThumbnailComboBoxIndexChanged(int index); void onHighlightColorChoose(); private: void loadViewOptions(); @@ -37,6 +38,8 @@ private: QCheckBox *m_saveLastTabCheckBox; QCheckBox *m_showHiddenFilesCheckBox; QComboBox *m_themeComboBox; + QComboBox *m_thumbnailComboBox; + QSpinBox *m_thumbnailCacheSpinBox; QComboBox *m_startupPlaylistComboBox; QPushButton *m_highlightColorPushButton; QColor m_highlightColor; diff --git a/ui/drivers/ui_qt.cpp b/ui/drivers/ui_qt.cpp index 1c494f1e99..306143527a 100644 --- a/ui/drivers/ui_qt.cpp +++ b/ui/drivers/ui_qt.cpp @@ -293,11 +293,12 @@ static void* ui_companion_qt_init(void) widget->setContextMenuPolicy(Qt::CustomContextMenu); QObject::connect(widget, SIGNAL(filesDropped(QStringList)), mainwindow, SLOT(onPlaylistFilesDropped(QStringList))); + QObject::connect(widget, SIGNAL(enterPressed()), mainwindow, SLOT(onDropWidgetEnterPressed())); QObject::connect(widget, SIGNAL(deletePressed()), mainwindow, SLOT(deleteCurrentPlaylistItem())); QObject::connect(widget, SIGNAL(customContextMenuRequested(const QPoint&)), mainwindow, SLOT(onFileDropWidgetContextMenuRequested(const QPoint&))); layout = new QVBoxLayout(); - layout->addWidget(mainwindow->contentTableWidget()); + layout->addWidget(mainwindow->contentTableView()); layout->addWidget(mainwindow->contentGridWidget()); widget->setLayout(layout); @@ -513,6 +514,11 @@ static void* ui_companion_qt_init(void) if (qsettings->contains("all_playlists_grid_max_count")) mainwindow->setAllPlaylistsGridMaxCount(qsettings->value("all_playlists_grid_max_count", 5000).toInt()); + if (qsettings->contains("thumbnail_cache_limit")) + mainwindow->setThumbnailCacheLimit(qsettings->value("thumbnail_cache_limit", 500).toInt()); + else + mainwindow->setThumbnailCacheLimit(500); + if (qsettings->contains("geometry")) if (qsettings->contains("save_geometry")) mainwindow->restoreGeometry(qsettings->value("geometry").toByteArray()); @@ -555,6 +561,25 @@ static void* ui_companion_qt_init(void) else mainwindow->setCurrentViewType(MainWindow::VIEW_TYPE_LIST); + if (qsettings->contains("icon_view_thumbnail_type")) + { + QString thumbnailType = qsettings->value("icon_view_thumbnail_type", "boxart").toString(); + + if (thumbnailType == "boxart") + mainwindow->setCurrentThumbnailType(THUMBNAIL_TYPE_BOXART); + else if (thumbnailType == "screenshot") + mainwindow->setCurrentThumbnailType(THUMBNAIL_TYPE_SCREENSHOT); + else if (thumbnailType == "title") + mainwindow->setCurrentThumbnailType(THUMBNAIL_TYPE_TITLE_SCREEN); + else + mainwindow->setCurrentThumbnailType(THUMBNAIL_TYPE_BOXART); + + /* we set it to the same thing a second time so that m_lastThumbnailType is also equal to the startup view type */ + mainwindow->setCurrentThumbnailType(mainwindow->getCurrentThumbnailType()); + } + else + mainwindow->setCurrentViewType(MainWindow::VIEW_TYPE_LIST); + /* We make sure to hook up the tab widget callback only after the tabs themselves have been added, * but before changing to a specific one, to avoid the callback firing before the view type is set. */ diff --git a/ui/drivers/ui_qt.h b/ui/drivers/ui_qt.h index 7c050d075b..b0fe0b30b6 100644 --- a/ui/drivers/ui_qt.h +++ b/ui/drivers/ui_qt.h @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include #include #include @@ -38,6 +38,10 @@ #include #include #include +#include +#include +#include +#include extern "C" { #include @@ -84,7 +88,7 @@ class LoadCoreWindow; class MainWindow; class ThumbnailWidget; class ThumbnailLabel; -class FlowLayout; +class GridView; class ShaderParamsDialog; class CoreOptionsDialog; class CoreInfoDialog; @@ -96,19 +100,58 @@ enum SpecialPlaylist SPECIAL_PLAYLIST_HISTORY }; -class GridItem : public QObject +enum ThumbnailType +{ + THUMBNAIL_TYPE_BOXART, + THUMBNAIL_TYPE_SCREENSHOT, + THUMBNAIL_TYPE_TITLE_SCREEN, +}; + +class PlaylistModel : public QAbstractListModel { Q_OBJECT -public: - GridItem(); - QPointer widget; - QPointer label; - QHash hash; - QImage image; - QPixmap pixmap; - QFutureWatcher imageWatcher; - QString labelText; +public: + enum Roles + { + HASH = Qt::UserRole + 1, + THUMBNAIL + }; + + PlaylistModel(QObject *parent = 0); + + QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const; + QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const; + Qt::ItemFlags flags(const QModelIndex &index) const; + bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole); + int rowCount(const QModelIndex &parent = QModelIndex()) const; + int columnCount(const QModelIndex &parent = QModelIndex()) const; + void addPlaylistItems(const QStringList &paths, bool add = false); + void addDir(QString path, QFlags showHidden); + void setThumbnailType(const ThumbnailType type); + void loadThumbnail(const QModelIndex &index); + void reloadThumbnail(const QModelIndex &index); + void reloadThumbnailPath(const QString path); + void reloadSystemThumbnails(const QString system); + void setThumbnailCacheLimit(int limit); + +signals: + void imageLoaded(const QImage image, const QModelIndex &index, const QString &path); + +private slots: + void onImageLoaded(const QImage image, const QModelIndex &index, const QString &path); + +private: + QVector > m_contents; + QCache m_cache; + QSet m_pendingImages; + QVector m_imageFormats; + QRegularExpression m_fileSanitizerRegex; + ThumbnailType m_thumbnailType = THUMBNAIL_TYPE_BOXART; + QString getThumbnailPath(const QModelIndex &index, QString type) const; + QString getCurrentTypeThumbnailPath(const QModelIndex &index) const; + void getPlaylistItems(QString path); + void loadImage(const QModelIndex &index, const QString &path); }; class ThumbnailWidget : public QFrame @@ -164,17 +207,12 @@ protected slots: void selectionChanged(const QItemSelection &selected, const QItemSelection &deselected); }; -class TableWidget : public QTableWidget +class TableView : public QTableView { Q_OBJECT public: - TableWidget(QWidget *parent = 0); + TableView(QWidget *parent = 0); bool isEditorOpen(); -signals: - void enterPressed(); - void deletePressed(); -protected: - void keyPressEvent(QKeyEvent *event); }; class ListWidget : public QListWidget @@ -233,6 +271,26 @@ public slots: void appendMessage(const QString& text); }; +/* Used to store styling since delegates don't inherit QWidget. */ +class GridItem : public QWidget +{ + Q_OBJECT + + Q_PROPERTY(QString thumbnailvalign READ getThumbnailVerticalAlign WRITE setThumbnailVerticalAlign) + Q_PROPERTY(int padding READ getPadding WRITE setPadding) + +public: + GridItem(QWidget* parent); + + Qt::AlignmentFlag thumbnailVerticalAlignmentFlag; + int padding; + + int getPadding() const; + void setPadding(const int value); + QString getThumbnailVerticalAlign() const; + void setThumbnailVerticalAlign(const QString valign); +}; + class MainWindow : public QMainWindow { Q_OBJECT @@ -263,9 +321,10 @@ public: MainWindow(QWidget *parent = NULL); ~MainWindow(); TreeView* dirTreeView(); + PlaylistModel* playlistModel(); ListWidget* playlistListWidget(); - TableWidget* contentTableWidget(); - FlowLayout* contentGridLayout(); + TableView* contentTableView(); + GridView* contentGridView(); QWidget* contentGridWidget(); QWidget* searchWidget(); QLineEdit* searchLineEdit(); @@ -289,20 +348,26 @@ public: bool setCustomThemeFile(QString filePath); void setCustomThemeString(QString qss); const QString& customThemeString() const; - GridItem* doDeferredImageLoad(GridItem *item, QString path); void setCurrentViewType(ViewType viewType); QString getCurrentViewTypeString(); ViewType getCurrentViewType(); + void setCurrentThumbnailType(ThumbnailType thumbnailType); + QString getCurrentThumbnailTypeString(); + ThumbnailType getCurrentThumbnailType(); + ThumbnailType getThumbnailTypeFromString(QString thumbnailType); void setAllPlaylistsListMaxCount(int count); void setAllPlaylistsGridMaxCount(int count); + void setThumbnailCacheLimit(int count); PlaylistEntryDialog* playlistEntryDialog(); void addFilesToPlaylist(QStringList files); QString getCurrentPlaylistPath(); + QModelIndex getCurrentContentIndex(); QHash getCurrentContentHash(); static double lerp(double x, double y, double a, double b, double d); QString getSpecialPlaylistPath(SpecialPlaylist playlist); QVector > getPlaylists(); QString getScrubbedString(QString str); + void setDefaultCustomProperties(); signals: void thumbnailChanged(const QPixmap &pixmap); @@ -317,6 +382,7 @@ signals: void showInfoMessageDeferred(QString msg); void extractArchiveDeferred(QString path, QString extractionDir, QString tempExtension, retro_task_callback_t cb); void itemChanged(); + void updateThumbnails(); void gridItemChanged(QString title); void gotThumbnailDownload(QString system, QString title); void scrollToDownloads(QString path); @@ -327,15 +393,13 @@ public slots: void onBrowserUpClicked(); void onBrowserStartClicked(); void initContentTableWidget(); - void initContentGridLayout(); void onViewClosedDocksAboutToShow(); void onShowHiddenDockWidgetAction(); void setCoreActions(); void onRunClicked(); void loadContent(const QHash &contentHash); void onStartCoreClicked(); - void onTableWidgetEnterPressed(); - void onTableWidgetDeletePressed(); + void onDropWidgetEnterPressed(); void selectBrowserDir(QString path); void resizeThumbnails(bool one, bool two, bool three); void onResizeThumbnailOne(); @@ -365,24 +429,20 @@ public slots: void downloadAllThumbnails(QString system, QUrl url = QUrl()); void downloadPlaylistThumbnails(QString playlistPath); void downloadNextPlaylistThumbnail(QString system, QString title, QString type, QUrl url = QUrl()); + void changeThumbnailType(ThumbnailType type); private slots: void onLoadCoreClicked(const QStringList &extensionFilters = QStringList()); void onUnloadCoreMenuAction(); void onTimeout(); void onCoreLoaded(); + void onCurrentTableItemDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight, const QVector &roles); void onCurrentListItemChanged(QListWidgetItem *current, QListWidgetItem *previous); - void onCurrentTableItemChanged(QTableWidgetItem *current, QTableWidgetItem *previous); - void onCurrentTableItemDataChanged(QTableWidgetItem *item); void onCurrentListItemDataChanged(QListWidgetItem *item); - void currentItemChanged(const QHash &hash); + void currentItemChanged(const QModelIndex &index); void onSearchEnterPressed(); void onSearchLineEditEdited(const QString &text); - void addPlaylistItemsToTable(const QStringList &paths, bool all = false); - void addPlaylistHashToTable(const QVector > &items); - void addPlaylistItemsToGrid(const QStringList &paths, bool all = false); - void addPlaylistHashToGrid(const QVector > &items); - void onContentItemDoubleClicked(QTableWidgetItem *item); + void onContentItemDoubleClicked(const QModelIndex &index); void onCoreLoadWindowClosed(); void onTreeViewItemsSelected(QModelIndexList selectedIndexes); void onSearchResetClicked(); @@ -390,13 +450,7 @@ private slots: void onFileBrowserTreeContextMenuRequested(const QPoint &pos); void onPlaylistWidgetContextMenuRequested(const QPoint &pos); void onStopClicked(); - void onDeferredImageLoaded(); void onZoomValueChanged(int value); - void onContentGridInited(); - void onUpdateGridItemPixmapFromImage(GridItem *item); - void onPendingItemUpdates(); - void onGridItemDoubleClicked(); - void onGridItemClicked(ThumbnailWidget *thumbnailWidget = NULL); void onPlaylistFilesDropped(QStringList files); void onShaderParamsClicked(); void onCoreOptionsClicked(); @@ -404,7 +458,6 @@ private slots: void onShowInfoMessage(QString msg); void onContributorsClicked(); void onItemChanged(); - void onGridItemChanged(QString title); void onFileSystemDirLoaded(const QString &path); void onDownloadScroll(QString path); void onDownloadScrollAgain(QString path); @@ -439,14 +492,14 @@ private slots: void onPlaylistThumbnailDownloadReadyRead(); void onPlaylistThumbnailDownloadCanceled(); + void startTimer(); + void updateVisibleItems(); + private: void setCurrentCoreLabel(); void getPlaylistFiles(); bool isCoreLoaded(); bool isContentLessCore(); - void removeGridItems(); - void loadImageDeferred(GridItem *item, QString path); - void calcGridItemSize(GridItem *item, int zoomValue); bool updateCurrentPlaylistEntry(const QHash &contentHash); int extractArchive(QString path); void removeUpdateTempFiles(); @@ -454,8 +507,9 @@ private: void renamePlaylistItem(QListWidgetItem *item, QString newName); bool currentPlaylistIsSpecial(); bool currentPlaylistIsAll(); - QVector > getPlaylistItems(QString pathString); + PlaylistModel *m_playlistModel; + QSortFilterProxyModel *m_proxyModel; LoadCoreWindow *m_loadCoreWindow; QTimer *m_timer; QString m_currentCore; @@ -464,7 +518,7 @@ private: TreeView *m_dirTree; QFileSystemModel *m_dirModel; ListWidget *m_listWidget; - TableWidget *m_tableWidget; + TableView *m_tableView; QWidget *m_searchWidget; QLineEdit *m_searchLineEdit; QDockWidget *m_searchDock; @@ -496,19 +550,19 @@ private: QListWidgetItem *m_historyPlaylistsItem; QIcon m_folderIcon; QString m_customThemeString; - FlowLayout *m_gridLayout; + GridView *m_gridView; QWidget *m_gridWidget; QScrollArea *m_gridScrollArea; - QVector > m_gridItems; QWidget *m_gridLayoutWidget; QSlider *m_zoomSlider; int m_lastZoomSliderValue; - QList m_pendingItemUpdates; ViewType m_viewType; + ThumbnailType m_thumbnailType; QProgressBar *m_gridProgressBar; QWidget *m_gridProgressWidget; QHash m_currentGridHash; ViewType m_lastViewType; + ThumbnailType m_lastThumbnailType; QPointer m_currentGridWidget; int m_allPlaylistsListMaxCount; int m_allPlaylistsGridMaxCount; @@ -540,6 +594,9 @@ private: bool m_playlistThumbnailDownloadWasCanceled; QString m_pendingDirScrollPath; + QTimer *m_thumbnailTimer; + GridItem m_gridItem; + protected: void closeEvent(QCloseEvent *event); void keyPressEvent(QKeyEvent *event); diff --git a/ui/drivers/ui_win32_resource.h b/ui/drivers/ui_win32_resource.h index e7090d701e..b071687311 100644 --- a/ui/drivers/ui_win32_resource.h +++ b/ui/drivers/ui_win32_resource.h @@ -1,5 +1,4 @@ - #define IDR_MENU 101 #define IDD_PICKCORE 103 #define ID_M_LOAD_CONTENT 40001 diff --git a/ui/ui_companion_driver.c b/ui/ui_companion_driver.c index daeae6e1d3..204db1ebc8 100644 --- a/ui/ui_companion_driver.c +++ b/ui/ui_companion_driver.c @@ -27,7 +27,7 @@ #include "ui_companion_driver.h" static const ui_companion_driver_t *ui_companion_drivers[] = { -#if defined(_WIN32) && !defined(_XBOX) +#if defined(_WIN32) && !defined(_XBOX) && !defined(__WINRT__) &ui_companion_win32, #endif #if defined(HAVE_COCOA) || defined(HAVE_COCOA_METAL) diff --git a/uwp/uwp_func.h b/uwp/uwp_func.h new file mode 100644 index 0000000000..ecab3b8a03 --- /dev/null +++ b/uwp/uwp_func.h @@ -0,0 +1,44 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2018 - Krzysztof Haładyn + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#ifndef _UWP_FUNC_H +#define _UWP_FUNC_H + +#include + +#ifdef __cplusplus +extern "C" { +#endif + +extern char uwp_dir_install[PATH_MAX_LENGTH]; +extern char uwp_dir_data[PATH_MAX_LENGTH]; +extern char uwp_device_family[128]; + +void* uwp_get_corewindow(void); + +void uwp_input_next_frame(void); +bool uwp_keyboard_pressed(unsigned key); +int16_t uwp_mouse_state(unsigned port, unsigned id, bool screen); +int16_t uwp_pointer_state(unsigned idx, unsigned id, bool screen); + +void uwp_fill_installed_core_packages(struct string_list *list); + +extern const struct rarch_key_map rarch_key_map_uwp[]; + +#ifdef __cplusplus +} +#endif + +#endif _UWP_FUNC_H diff --git a/uwp/uwp_main.cpp b/uwp/uwp_main.cpp new file mode 100644 index 0000000000..bc1c9b5e13 --- /dev/null +++ b/uwp/uwp_main.cpp @@ -0,0 +1,630 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2018 - Krzysztof Haładyn + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#include "uwp_main.h" +#include +#include +#include "../retroarch.h" +#include "../frontend/frontend.h" +#include "../input/input_keymaps.h" +#include "../input/input_driver.h" +#include "../verbosity.h" +#include "../libretro-common/include/encodings/utf.h" +#include "../libretro-common/include/lists/string_list.h" +#include "uwp_func.h" + +#include +#include + +using namespace RetroArchUWP; + +using namespace concurrency; +using namespace Windows::ApplicationModel; +using namespace Windows::ApplicationModel::Core; +using namespace Windows::ApplicationModel::Activation; +using namespace Windows::UI::Core; +using namespace Windows::UI::Input; +using namespace Windows::UI::ViewManagement; +using namespace Windows::Devices::Input; +using namespace Windows::System; +using namespace Windows::System::Profile; +using namespace Windows::Foundation; +using namespace Windows::Foundation::Collections; +using namespace Windows::Graphics::Display; + +char uwp_dir_install[PATH_MAX_LENGTH]; +char uwp_dir_data[PATH_MAX_LENGTH]; +char uwp_device_family[128]; + +// Some keys are unavailable in the VirtualKey enum (wtf) but the old-style constants work +const struct rarch_key_map rarch_key_map_uwp[] = { + { (unsigned int)VirtualKey::Back, RETROK_BACKSPACE }, + { (unsigned int)VirtualKey::Tab, RETROK_TAB }, + { (unsigned int)VirtualKey::Clear, RETROK_CLEAR }, + { (unsigned int)VirtualKey::Enter, RETROK_RETURN }, + { (unsigned int)VirtualKey::Pause, RETROK_PAUSE }, + { (unsigned int)VirtualKey::Escape, RETROK_ESCAPE }, + { (unsigned int)VirtualKey::ModeChange, RETROK_MODE }, + { (unsigned int)VirtualKey::Space, RETROK_SPACE }, + { (unsigned int)VirtualKey::PageUp, RETROK_PAGEUP }, + { (unsigned int)VirtualKey::PageDown, RETROK_PAGEDOWN }, + { (unsigned int)VirtualKey::End, RETROK_END }, + { (unsigned int)VirtualKey::Home, RETROK_HOME }, + { (unsigned int)VirtualKey::Left, RETROK_LEFT }, + { (unsigned int)VirtualKey::Up, RETROK_UP }, + { (unsigned int)VirtualKey::Right, RETROK_RIGHT }, + { (unsigned int)VirtualKey::Down, RETROK_DOWN }, + { (unsigned int)VirtualKey::Print, RETROK_PRINT }, + { (unsigned int)VirtualKey::Insert, RETROK_INSERT }, + { (unsigned int)VirtualKey::Delete, RETROK_DELETE }, + { (unsigned int)VirtualKey::Help, RETROK_HELP }, + { (unsigned int)VirtualKey::Number0, RETROK_0 }, + { (unsigned int)VirtualKey::Number1, RETROK_1 }, + { (unsigned int)VirtualKey::Number2, RETROK_2 }, + { (unsigned int)VirtualKey::Number3, RETROK_3 }, + { (unsigned int)VirtualKey::Number4, RETROK_4 }, + { (unsigned int)VirtualKey::Number5, RETROK_5 }, + { (unsigned int)VirtualKey::Number6, RETROK_6 }, + { (unsigned int)VirtualKey::Number7, RETROK_7 }, + { (unsigned int)VirtualKey::Number8, RETROK_8 }, + { (unsigned int)VirtualKey::Number9, RETROK_9 }, + { (unsigned int)VirtualKey::A, RETROK_a }, + { (unsigned int)VirtualKey::B, RETROK_b }, + { (unsigned int)VirtualKey::C, RETROK_c }, + { (unsigned int)VirtualKey::D, RETROK_d }, + { (unsigned int)VirtualKey::E, RETROK_e }, + { (unsigned int)VirtualKey::F, RETROK_f }, + { (unsigned int)VirtualKey::G, RETROK_g }, + { (unsigned int)VirtualKey::H, RETROK_h }, + { (unsigned int)VirtualKey::I, RETROK_i }, + { (unsigned int)VirtualKey::J, RETROK_j }, + { (unsigned int)VirtualKey::K, RETROK_k }, + { (unsigned int)VirtualKey::L, RETROK_l }, + { (unsigned int)VirtualKey::M, RETROK_m }, + { (unsigned int)VirtualKey::N, RETROK_n }, + { (unsigned int)VirtualKey::O, RETROK_o }, + { (unsigned int)VirtualKey::P, RETROK_p }, + { (unsigned int)VirtualKey::Q, RETROK_q }, + { (unsigned int)VirtualKey::R, RETROK_r }, + { (unsigned int)VirtualKey::S, RETROK_s }, + { (unsigned int)VirtualKey::T, RETROK_t }, + { (unsigned int)VirtualKey::U, RETROK_u }, + { (unsigned int)VirtualKey::V, RETROK_v }, + { (unsigned int)VirtualKey::W, RETROK_w }, + { (unsigned int)VirtualKey::X, RETROK_x }, + { (unsigned int)VirtualKey::Y, RETROK_y }, + { (unsigned int)VirtualKey::Z, RETROK_z }, + { (unsigned int)VirtualKey::LeftWindows, RETROK_LSUPER }, + { (unsigned int)VirtualKey::RightWindows, RETROK_RSUPER }, + { (unsigned int)VirtualKey::Application, RETROK_MENU }, + { (unsigned int)VirtualKey::NumberPad0, RETROK_KP0 }, + { (unsigned int)VirtualKey::NumberPad1, RETROK_KP1 }, + { (unsigned int)VirtualKey::NumberPad2, RETROK_KP2 }, + { (unsigned int)VirtualKey::NumberPad3, RETROK_KP3 }, + { (unsigned int)VirtualKey::NumberPad4, RETROK_KP4 }, + { (unsigned int)VirtualKey::NumberPad5, RETROK_KP5 }, + { (unsigned int)VirtualKey::NumberPad6, RETROK_KP6 }, + { (unsigned int)VirtualKey::NumberPad7, RETROK_KP7 }, + { (unsigned int)VirtualKey::NumberPad8, RETROK_KP8 }, + { (unsigned int)VirtualKey::NumberPad9, RETROK_KP9 }, + { (unsigned int)VirtualKey::Multiply, RETROK_KP_MULTIPLY }, + { (unsigned int)VirtualKey::Add, RETROK_KP_PLUS }, + { (unsigned int)VirtualKey::Subtract, RETROK_KP_MINUS }, + { (unsigned int)VirtualKey::Decimal, RETROK_KP_PERIOD }, + { (unsigned int)VirtualKey::Divide, RETROK_KP_DIVIDE }, + { (unsigned int)VirtualKey::F1, RETROK_F1 }, + { (unsigned int)VirtualKey::F2, RETROK_F2 }, + { (unsigned int)VirtualKey::F3, RETROK_F3 }, + { (unsigned int)VirtualKey::F4, RETROK_F4 }, + { (unsigned int)VirtualKey::F5, RETROK_F5 }, + { (unsigned int)VirtualKey::F6, RETROK_F6 }, + { (unsigned int)VirtualKey::F7, RETROK_F7 }, + { (unsigned int)VirtualKey::F8, RETROK_F8 }, + { (unsigned int)VirtualKey::F9, RETROK_F9 }, + { (unsigned int)VirtualKey::F10, RETROK_F10 }, + { (unsigned int)VirtualKey::F11, RETROK_F11 }, + { (unsigned int)VirtualKey::F12, RETROK_F12 }, + { (unsigned int)VirtualKey::F13, RETROK_F13 }, + { (unsigned int)VirtualKey::F14, RETROK_F14 }, + { (unsigned int)VirtualKey::F15, RETROK_F15 }, + { (unsigned int)VirtualKey::NumberKeyLock, RETROK_NUMLOCK }, + { (unsigned int)VirtualKey::Scroll, RETROK_SCROLLOCK }, + { (unsigned int)VirtualKey::LeftShift, RETROK_LSHIFT }, + { (unsigned int)VirtualKey::RightShift, RETROK_RSHIFT }, + { (unsigned int)VirtualKey::LeftControl, RETROK_LCTRL }, + { (unsigned int)VirtualKey::RightControl, RETROK_RCTRL }, + { (unsigned int)VirtualKey::LeftMenu, RETROK_LALT }, + { (unsigned int)VirtualKey::RightMenu, RETROK_RALT }, + { VK_RETURN, RETROK_KP_ENTER }, + { (unsigned int)VirtualKey::CapitalLock, RETROK_CAPSLOCK }, + { VK_OEM_1, RETROK_SEMICOLON }, + { VK_OEM_PLUS, RETROK_EQUALS }, + { VK_OEM_COMMA, RETROK_COMMA }, + { VK_OEM_MINUS, RETROK_MINUS }, + { VK_OEM_PERIOD, RETROK_PERIOD }, + { VK_OEM_2, RETROK_SLASH }, + { VK_OEM_3, RETROK_BACKQUOTE }, + { VK_OEM_4, RETROK_LEFTBRACKET }, + { VK_OEM_5, RETROK_BACKSLASH }, + { VK_OEM_6, RETROK_RIGHTBRACKET }, + { VK_OEM_7, RETROK_QUOTE }, + { 0, RETROK_UNKNOWN } +}; + +struct uwp_input_state_t { + short mouse_screen_x; + short mouse_screen_y; + short mouse_rel_x; + short mouse_rel_y; + bool mouse_left; + bool mouse_right; + bool mouse_middle; + bool mouse_button4; + bool mouse_button5; + short mouse_wheel_left; + short mouse_wheel_up; + short touch_screen_x; + short touch_screen_y; + short touch_rel_x; + short touch_rel_y; + bool touch_touched; +}; + +struct uwp_input_state_t uwp_current_input, uwp_next_input; + +// The main function is only used to initialize our IFrameworkView class. +[Platform::MTAThread] +int main(Platform::Array^) +{ + Platform::String^ install_dir = Windows::ApplicationModel::Package::Current->InstalledLocation->Path + L"\\"; + wcstombs(uwp_dir_install, install_dir->Data(), PATH_MAX_LENGTH); + Platform::String^ data_dir = Windows::Storage::ApplicationData::Current->LocalFolder->Path + L"\\"; + wcstombs(uwp_dir_data, data_dir->Data(), PATH_MAX_LENGTH); + + wcstombs(uwp_device_family, AnalyticsInfo::VersionInfo->DeviceFamily->Data(), 128); + + RARCH_LOG("Data dir: %ls\n", data_dir->Data()); + RARCH_LOG("Install dir: %ls\n", install_dir->Data()); + + auto direct3DApplicationSource = ref new Direct3DApplicationSource(); + CoreApplication::Run(direct3DApplicationSource); + return 0; +} + +IFrameworkView^ Direct3DApplicationSource::CreateView() +{ + return ref new App(); +} + +App^ App::m_instance; + +App::App() : + m_initialized(false), + m_windowClosed(false), + m_windowVisible(true), + m_windowFocused(true), + m_windowResized(false) +{ + m_instance = this; +} + +// The first method called when the IFrameworkView is being created. +void App::Initialize(CoreApplicationView^ applicationView) +{ + // Register event handlers for app lifecycle. This example includes Activated, so that we + // can make the CoreWindow active and start rendering on the window. + applicationView->Activated += + ref new TypedEventHandler(this, &App::OnActivated); + + CoreApplication::Suspending += + ref new EventHandler(this, &App::OnSuspending); + + CoreApplication::Resuming += + ref new EventHandler(this, &App::OnResuming); +} + +// Called when the CoreWindow object is created (or re-created). +void App::SetWindow(CoreWindow^ window) +{ + window->SizeChanged += + ref new TypedEventHandler(this, &App::OnWindowSizeChanged); + + window->VisibilityChanged += + ref new TypedEventHandler(this, &App::OnVisibilityChanged); + + window->Activated += + ref new TypedEventHandler(this, &App::OnWindowActivated); + + window->Closed += + ref new TypedEventHandler(this, &App::OnWindowClosed); + + window->KeyDown += + ref new TypedEventHandler(this, &App::OnKey); + + window->KeyUp += + ref new TypedEventHandler(this, &App::OnKey); + + window->PointerPressed += + ref new TypedEventHandler(this, &App::OnPointer); + + window->PointerReleased += + ref new TypedEventHandler(this, &App::OnPointer); + + window->PointerMoved += + ref new TypedEventHandler(this, &App::OnPointer); + + window->PointerWheelChanged += + ref new TypedEventHandler(this, &App::OnPointer); + + DisplayInformation^ currentDisplayInformation = DisplayInformation::GetForCurrentView(); + + currentDisplayInformation->DpiChanged += + ref new TypedEventHandler(this, &App::OnDpiChanged); + + DisplayInformation::DisplayContentsInvalidated += + ref new TypedEventHandler(this, &App::OnDisplayContentsInvalidated); + + currentDisplayInformation->OrientationChanged += + ref new TypedEventHandler(this, &App::OnOrientationChanged); + + Windows::UI::Core::SystemNavigationManager::GetForCurrentView()->BackRequested += + ref new EventHandler(this, &App::OnBackRequested); +} + +// Initializes scene resources, or loads a previously saved app state. +void App::Load(Platform::String^ entryPoint) +{ + int ret = rarch_main(NULL, NULL, NULL); + if (ret != 0) + { + RARCH_ERR("Init failed\n"); + CoreApplication::Exit(); + return; + } + m_initialized = true; + + auto catalog = Windows::ApplicationModel::PackageCatalog::OpenForCurrentPackage(); + + catalog->PackageInstalling += + ref new TypedEventHandler(this, &App::OnPackageInstalling); +} + +// This method is called after the window becomes active. +void App::Run() +{ + if (!m_initialized) + { + RARCH_WARN("Initialization failed, so not running\n"); + return; + } + + bool x = false; + while (true) + { + CoreWindow::GetForCurrentThread()->Dispatcher->ProcessEvents(CoreProcessEventsOption::ProcessAllIfPresent); + + unsigned sleep_ms = 0; + int ret = runloop_iterate(&sleep_ms); + + if (ret == 1 && sleep_ms > 0) + retro_sleep(sleep_ms); + + task_queue_check(); + + if (!x) + { + /* HACK: I have no idea why is this necessary but it is required to get proper scaling on Xbox * + * Perhaps PreferredLaunchViewSize is broken and we need to wait until the app starts to call TryResizeView */ + m_windowResized = true; + x = true; + } + + if (ret == -1) + break; + } +} + +// Required for IFrameworkView. +// Terminate events do not cause Uninitialize to be called. It will be called if your IFrameworkView +// class is torn down while the app is in the foreground. +void App::Uninitialize() +{ + main_exit(NULL); +} + +// Application lifecycle event handlers. + +void App::OnActivated(CoreApplicationView^ applicationView, IActivatedEventArgs^ args) +{ + // Run() won't start until the CoreWindow is activated. + CoreWindow::GetForCurrentThread()->Activate(); +} + +void App::OnSuspending(Platform::Object^ sender, SuspendingEventArgs^ args) +{ + // Save app state asynchronously after requesting a deferral. Holding a deferral + // indicates that the application is busy performing suspending operations. Be + // aware that a deferral may not be held indefinitely. After about five seconds, + // the app will be forced to exit. + SuspendingDeferral^ deferral = args->SuspendingOperation->GetDeferral(); + + create_task([this, deferral]() + { + // TODO: Maybe creating a save state here would be a good idea? + + deferral->Complete(); + }); +} + +void App::OnResuming(Platform::Object^ sender, Platform::Object^ args) +{ + // Restore any data or state that was unloaded on suspend. By default, data + // and state are persisted when resuming from suspend. Note that this event + // does not occur if the app was previously terminated. +} + +void App::OnBackRequested(Platform::Object^ sender, Windows::UI::Core::BackRequestedEventArgs^ args) +{ + /* Prevent the B controller button on Xbox One from quitting the app */ + args->Handled = true; +} + +// Window event handlers. + +void App::OnWindowSizeChanged(CoreWindow^ sender, WindowSizeChangedEventArgs^ args) +{ + m_windowResized = true; +} + +void App::OnVisibilityChanged(CoreWindow^ sender, VisibilityChangedEventArgs^ args) +{ + m_windowVisible = args->Visible; +} + +void App::OnWindowActivated(CoreWindow^ sender, WindowActivatedEventArgs^ args) +{ + m_windowFocused = args->WindowActivationState != CoreWindowActivationState::Deactivated; +} + +void App::OnKey(CoreWindow^ sender, KeyEventArgs^ args) +{ + uint16_t mod = 0; + if ((sender->GetKeyState(VirtualKey::Shift) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_SHIFT; + if ((sender->GetKeyState(VirtualKey::Control) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_CTRL; + if ((sender->GetKeyState(VirtualKey::Menu) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_ALT; + if ((sender->GetKeyState(VirtualKey::CapitalLock) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_CAPSLOCK; + if ((sender->GetKeyState(VirtualKey::Scroll) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_SCROLLOCK; + if ((sender->GetKeyState(VirtualKey::LeftWindows) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked || + (sender->GetKeyState(VirtualKey::RightWindows) & CoreVirtualKeyStates::Locked) == CoreVirtualKeyStates::Locked) + mod |= RETROKMOD_META; + + unsigned keycode = input_keymaps_translate_keysym_to_rk((unsigned)args->VirtualKey); + + input_keyboard_event(!args->KeyStatus.IsKeyReleased, keycode, 0, mod, RETRO_DEVICE_KEYBOARD); +} + +void App::OnPointer(CoreWindow^ sender, PointerEventArgs^ args) +{ + if (args->CurrentPoint->PointerDevice->PointerDeviceType == PointerDeviceType::Mouse) + { + uwp_next_input.mouse_left = args->CurrentPoint->Properties->IsLeftButtonPressed; + uwp_next_input.mouse_middle = args->CurrentPoint->Properties->IsMiddleButtonPressed; + uwp_next_input.mouse_right = args->CurrentPoint->Properties->IsRightButtonPressed; + uwp_next_input.mouse_button4 = args->CurrentPoint->Properties->IsXButton1Pressed; + uwp_next_input.mouse_button5 = args->CurrentPoint->Properties->IsXButton2Pressed; + uwp_next_input.mouse_screen_x = args->CurrentPoint->Position.X; + uwp_next_input.mouse_screen_y = args->CurrentPoint->Position.Y; + uwp_next_input.mouse_rel_x = uwp_next_input.mouse_screen_x - uwp_current_input.mouse_screen_x; + uwp_next_input.mouse_rel_y = uwp_next_input.mouse_screen_y - uwp_current_input.mouse_screen_y; + if (args->CurrentPoint->Properties->IsHorizontalMouseWheel) + uwp_next_input.mouse_wheel_left += args->CurrentPoint->Properties->MouseWheelDelta; + else + uwp_next_input.mouse_wheel_up += args->CurrentPoint->Properties->MouseWheelDelta; + } + else + { + uwp_next_input.touch_touched = args->CurrentPoint->IsInContact; + uwp_next_input.touch_screen_x = args->CurrentPoint->Position.X; + uwp_next_input.touch_screen_y = args->CurrentPoint->Position.Y; + uwp_next_input.touch_rel_x = uwp_next_input.touch_screen_x - uwp_current_input.touch_screen_x; + uwp_next_input.touch_rel_y = uwp_next_input.touch_screen_y - uwp_current_input.touch_screen_y; + } +} + +void App::OnWindowClosed(CoreWindow^ sender, CoreWindowEventArgs^ args) +{ + m_windowClosed = true; +} + +// DisplayInformation event handlers. + +void App::OnDpiChanged(DisplayInformation^ sender, Object^ args) +{ + m_windowResized = true; +} + +void App::OnOrientationChanged(DisplayInformation^ sender, Object^ args) +{ + m_windowResized = true; +} + +void App::OnDisplayContentsInvalidated(DisplayInformation^ sender, Object^ args) +{ + // Probably can be ignored? +} + +void App::OnPackageInstalling(PackageCatalog^ sender, PackageInstallingEventArgs^ args) +{ + /* TODO: This doesn't seem to work even though it's exactly the same as in sample app and it works there */ + if (args->IsComplete) + { + char msg[512]; + snprintf(msg, sizeof(msg), "Package \"%ls\" installed, a restart may be necessary", args->Package->DisplayName->Data()); + runloop_msg_queue_push(msg, 1, 5 * 60, false); + } +} + +// Taken from DirectX UWP samples - on Xbox, everything is scaled 200% so getting the DPI calculation correct is crucial +static inline float ConvertDipsToPixels(float dips, float dpi) +{ + static const float dipsPerInch = 96.0f; + return floorf(dips * dpi / dipsPerInch + 0.5f); +} + +// Implement UWP equivalents of various win32_* functions +extern "C" { + + bool win32_has_focus(void) + { + return App::GetInstance()->IsWindowFocused(); + } + + bool win32_set_video_mode(void *data, unsigned width, unsigned height, bool fullscreen) + { + if (App::GetInstance()->IsInitialized()) + { + if (fullscreen != ApplicationView::GetForCurrentView()->IsFullScreenMode) + { + if (fullscreen) + ApplicationView::GetForCurrentView()->TryEnterFullScreenMode(); + else + ApplicationView::GetForCurrentView()->ExitFullScreenMode(); + } + ApplicationView::GetForCurrentView()->TryResizeView(Size(width, height)); + } + else + { + /* In case the window is not activated yet, TryResizeView will fail and we have to set the initial parameters instead */ + /* Note that these are preserved after restarting the app and used for the UWP splash screen size (!), so they should be set only during init and not changed afterwards */ + ApplicationView::PreferredLaunchViewSize = Size(width, height); + ApplicationView::PreferredLaunchWindowingMode = fullscreen ? ApplicationViewWindowingMode::FullScreen : ApplicationViewWindowingMode::PreferredLaunchViewSize; + } + + /* Setting the window size may sometimes fail "because UWP" + * (i.e. we are on device with no windows, or Windows sandbox decides the window can't be that small) + * so in case resizing fails we just send a resized event back to RetroArch with old size + * (and report success because otherwise it bails out hard about failing to set video mode) + */ + App::GetInstance()->SetWindowResized(); + return true; + } + + void win32_show_cursor(bool state) + { + CoreWindow::GetForCurrentThread()->PointerCursor = state ? ref new CoreCursor(CoreCursorType::Arrow, 0) : nullptr; + } + + void win32_check_window(bool *quit, bool *resize, unsigned *width, unsigned *height) + { + *quit = App::GetInstance()->IsWindowClosed(); + *resize = App::GetInstance()->CheckWindowResized(); + if (*resize) + { + float dpi = DisplayInformation::GetForCurrentView()->LogicalDpi; + *width = ConvertDipsToPixels(CoreWindow::GetForCurrentThread()->Bounds.Width, dpi); + *height = ConvertDipsToPixels(CoreWindow::GetForCurrentThread()->Bounds.Height, dpi); + } + } + + void* uwp_get_corewindow(void) + { + return (void*)CoreWindow::GetForCurrentThread(); + } + + void uwp_fill_installed_core_packages(struct string_list *list) + { + for (auto package : Windows::ApplicationModel::Package::Current->Dependencies) + { + if (package->IsOptional) + { + string_list_elem_attr attr{}; + string_list_append(list, utf16_to_utf8_string_alloc((package->InstalledLocation->Path + L"\\cores")->Data()), attr); + } + } + } + + void uwp_input_next_frame(void) + { + uwp_current_input = uwp_next_input; + uwp_next_input.mouse_rel_x = 0; + uwp_next_input.mouse_rel_y = 0; + uwp_next_input.mouse_wheel_up %= WHEEL_DELTA; + uwp_next_input.mouse_wheel_left %= WHEEL_DELTA; + uwp_next_input.touch_rel_x = 0; + uwp_next_input.touch_rel_y = 0; + } + + bool uwp_keyboard_pressed(unsigned key) + { + unsigned sym = rarch_keysym_lut[(enum retro_key)key]; + return (CoreWindow::GetForCurrentThread()->GetKeyState((VirtualKey)sym) & CoreVirtualKeyStates::Down) == CoreVirtualKeyStates::Down; + } + + int16_t uwp_mouse_state(unsigned port, unsigned id, bool screen) + { + int16_t state = 0; + + switch (id) + { + case RETRO_DEVICE_ID_MOUSE_X: + return screen ? uwp_current_input.mouse_screen_x : uwp_current_input.mouse_rel_x; + case RETRO_DEVICE_ID_MOUSE_Y: + return screen ? uwp_current_input.mouse_screen_y : uwp_current_input.mouse_rel_y; + case RETRO_DEVICE_ID_MOUSE_LEFT: + return uwp_current_input.mouse_left; + case RETRO_DEVICE_ID_MOUSE_RIGHT: + return uwp_current_input.mouse_right; + case RETRO_DEVICE_ID_MOUSE_WHEELUP: + return uwp_current_input.mouse_wheel_up > WHEEL_DELTA; + case RETRO_DEVICE_ID_MOUSE_WHEELDOWN: + return uwp_current_input.mouse_wheel_up < -WHEEL_DELTA; + case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELUP: + return uwp_current_input.mouse_wheel_left > WHEEL_DELTA; + case RETRO_DEVICE_ID_MOUSE_HORIZ_WHEELDOWN: + return uwp_current_input.mouse_wheel_left < -WHEEL_DELTA; + case RETRO_DEVICE_ID_MOUSE_MIDDLE: + return uwp_current_input.mouse_middle; + case RETRO_DEVICE_ID_MOUSE_BUTTON_4: + return uwp_current_input.mouse_button4; + case RETRO_DEVICE_ID_MOUSE_BUTTON_5: + return uwp_current_input.mouse_button5; + } + + return 0; + } + + // TODO: I don't have any touch-enabled Windows devices to test if this actually works + int16_t uwp_pointer_state(unsigned idx, unsigned id, bool screen) + { + switch (id) + { + case RETRO_DEVICE_ID_POINTER_X: + return screen ? uwp_current_input.touch_screen_x : uwp_current_input.touch_rel_x; + case RETRO_DEVICE_ID_POINTER_Y: + return screen ? uwp_current_input.touch_screen_y : uwp_current_input.touch_rel_y; + case RETRO_DEVICE_ID_POINTER_PRESSED: + return uwp_current_input.touch_touched; + default: + break; + } + + return 0; + } +} diff --git a/uwp/uwp_main.h b/uwp/uwp_main.h new file mode 100644 index 0000000000..a2f2595d45 --- /dev/null +++ b/uwp/uwp_main.h @@ -0,0 +1,81 @@ +/* RetroArch - A frontend for libretro. + * Copyright (C) 2018 - Krzysztof Haładyn + * + * RetroArch is free software: you can redistribute it and/or modify it under the terms + * of the GNU General Public License as published by the Free Software Found- + * ation, either version 3 of the License, or (at your option) any later version. + * + * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; + * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along with RetroArch. + * If not, see . + */ + +#pragma once + +#include "uwp_main.h" + +namespace RetroArchUWP +{ + // Main entry point for our app. Connects the app with the Windows shell and handles application lifecycle events. + ref class App sealed : public Windows::ApplicationModel::Core::IFrameworkView + { + public: + App(); + + // IFrameworkView methods. + virtual void Initialize(Windows::ApplicationModel::Core::CoreApplicationView^ applicationView); + virtual void SetWindow(Windows::UI::Core::CoreWindow^ window); + virtual void Load(Platform::String^ entryPoint); + virtual void Run(); + virtual void Uninitialize(); + + protected: + // Application lifecycle event handlers. + void OnActivated(Windows::ApplicationModel::Core::CoreApplicationView^ applicationView, Windows::ApplicationModel::Activation::IActivatedEventArgs^ args); + void OnSuspending(Platform::Object^ sender, Windows::ApplicationModel::SuspendingEventArgs^ args); + void OnResuming(Platform::Object^ sender, Platform::Object^ args); + + void OnBackRequested(Platform::Object^ sender, Windows::UI::Core::BackRequestedEventArgs^ args); + + // Window event handlers. + void OnWindowSizeChanged(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::WindowSizeChangedEventArgs^ args); + void OnVisibilityChanged(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::VisibilityChangedEventArgs^ args); + void OnWindowClosed(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::CoreWindowEventArgs^ args); + void OnWindowActivated(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::WindowActivatedEventArgs^ args); + void OnKey(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::KeyEventArgs^ args); + void OnPointer(Windows::UI::Core::CoreWindow^ sender, Windows::UI::Core::PointerEventArgs^ args); + + // DisplayInformation event handlers. + void OnDpiChanged(Windows::Graphics::Display::DisplayInformation^ sender, Platform::Object^ args); + void OnOrientationChanged(Windows::Graphics::Display::DisplayInformation^ sender, Platform::Object^ args); + void OnDisplayContentsInvalidated(Windows::Graphics::Display::DisplayInformation^ sender, Platform::Object^ args); + + void OnPackageInstalling(Windows::ApplicationModel::PackageCatalog^ sender, Windows::ApplicationModel::PackageInstallingEventArgs^ args); + + public: + bool IsInitialized() { return m_initialized; } + bool IsWindowClosed() { return m_windowClosed; } + bool IsWindowVisible() { return m_windowVisible; } + bool IsWindowFocused() { return m_windowFocused; } + bool CheckWindowResized() { bool resized = m_windowResized; m_windowResized = false; return resized; } + void SetWindowResized() { m_windowResized = true; } + static App^ GetInstance() { return m_instance; } + + private: + bool m_initialized; + bool m_windowClosed; + bool m_windowVisible; + bool m_windowFocused; + bool m_windowResized; + static App^ m_instance; + }; +} + +ref class Direct3DApplicationSource sealed : Windows::ApplicationModel::Core::IFrameworkViewSource +{ +public: + virtual Windows::ApplicationModel::Core::IFrameworkView^ CreateView(); +}; diff --git a/verbosity.c b/verbosity.c index 42a79f4977..7489d2202e 100644 --- a/verbosity.c +++ b/verbosity.c @@ -37,6 +37,11 @@ #include #endif +#if _WIN32 +#define WIN32_LEAN_AND_MEAN +#include +#endif + #include #include #include @@ -118,9 +123,11 @@ void retro_main_log_file_init(const char *path) log_file_fp = (FILE*)fopen_utf8(path, "wb"); log_file_initialized = true; +#if !defined(PS2) /* TODO: PS2 IMPROVEMENT */ /* TODO: this is only useful for a few platforms, find which and add ifdef */ log_file_buf = calloc(1, 0x4000); setvbuf(log_file_fp, (char*)log_file_buf, _IOFBF, 0x4000); +#endif } void retro_main_log_file_deinit(void) @@ -191,7 +198,7 @@ void RARCH_LOG_V(const char *tag, const char *fmt, va_list ap) #else { -#ifdef HAVE_QT +#if defined(HAVE_QT) || defined(__WINRT__) char buffer[1024]; #endif #ifdef HAVE_FILE_LOGGER @@ -200,7 +207,7 @@ void RARCH_LOG_V(const char *tag, const char *fmt, va_list ap) FILE *fp = stderr; #endif -#ifdef HAVE_QT +#if defined(HAVE_QT) || defined(__WINRT__) buffer[0] = '\0'; vsnprintf(buffer, sizeof(buffer), fmt, ap); @@ -210,7 +217,13 @@ void RARCH_LOG_V(const char *tag, const char *fmt, va_list ap) fflush(fp); } +#if defined(HAVE_QT) ui_companion_driver_log_msg(buffer); +#endif + +#if defined(__WINRT__) + OutputDebugStringA(buffer); +#endif #else #if defined(NXLINK) && !defined(HAVE_FILE_LOGGER) if (nxlink_connected) diff --git a/wii/app_booter/elf_abi.h b/wii/app_booter/elf_abi.h index b09261f76a..0595e104dd 100644 --- a/wii/app_booter/elf_abi.h +++ b/wii/app_booter/elf_abi.h @@ -404,7 +404,6 @@ typedef struct elf32_sym #define STV_HIDDEN 2 /* Symbol unavailable in other mods */ #define STV_PROTECTED 3 /* Not preemptible, not exported */ - /* Relocation entry with implicit addend */ typedef struct diff --git a/wii/app_booter/main.c b/wii/app_booter/main.c index 2a3086b0ed..571a377b17 100644 --- a/wii/app_booter/main.c +++ b/wii/app_booter/main.c @@ -137,7 +137,6 @@ static uint32_t load_dol_image(const void *dolstart) return dolfile->entry_point; } - /* if we name this main, GCC inserts the __eabi symbol, * even when we specify -mno-eabi. */ diff --git a/wii/libogc/include/asndlib.h b/wii/libogc/include/asndlib.h index ed62daf57a..d4831c3eb0 100644 --- a/wii/libogc/include/asndlib.h +++ b/wii/libogc/include/asndlib.h @@ -26,7 +26,6 @@ THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #ifndef __ASNDLIB_H__ #define __ASNDLIB_H__ diff --git a/wii/libogc/include/bte/bd_addr.h b/wii/libogc/include/bte/bd_addr.h index b8c9698c8f..a5dcd957ee 100644 --- a/wii/libogc/include/bte/bd_addr.h +++ b/wii/libogc/include/bte/bd_addr.h @@ -71,7 +71,6 @@ struct bd_addr { (addr1)->addr[4] = (addr2)->addr[4]; \ (addr1)->addr[5] = (addr2)->addr[5]; }while(0) - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/wii/libogc/include/bte/bte.h b/wii/libogc/include/bte/bte.h index e05e9cdddb..69eb36e575 100644 --- a/wii/libogc/include/bte/bte.h +++ b/wii/libogc/include/bte/bte.h @@ -110,7 +110,6 @@ struct bte_pcb struct l2cap_pcb *ctl_pcb; struct l2cap_pcb *data_pcb; - s32 (*recv)(void *arg,void *buffer,u16 len); s32 (*conn_cfm)(void *arg,struct bte_pcb *pcb,u8 err); s32 (*disconn_cfm)(void *arg,struct bte_pcb *pcb,u8 err); diff --git a/wii/libogc/include/debug.h b/wii/libogc/include/debug.h index a6139750ae..251b7f9732 100644 --- a/wii/libogc/include/debug.h +++ b/wii/libogc/include/debug.h @@ -17,7 +17,6 @@ extern const char *tcp_localip; extern const char *tcp_netmask; extern const char *tcp_gateway; - /*!\fn void _break() * \brief Stub function to insert the hardware break instruction. This function is used to enter the debug stub and to * connect with the host. The developer is free to insert this function at any position in project's source code. @@ -26,7 +25,6 @@ extern const char *tcp_gateway; */ void _break(); - /*!\fn void DEBUG_Init(s32 device_type,s32 channel_port) * \brief Performs the initialization of the debug stub. * \param[in] device_type type of device to use. can be either USB or TCP. diff --git a/wii/libogc/include/fat.h b/wii/libogc/include/fat.h index 7d828f6e72..1d60af2921 100644 --- a/wii/libogc/include/fat.h +++ b/wii/libogc/include/fat.h @@ -28,7 +28,6 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #ifndef _LIBFAT_H #define _LIBFAT_H diff --git a/wii/libogc/include/gccore.h b/wii/libogc/include/gccore.h index f45b68345a..ba3efd0684 100644 --- a/wii/libogc/include/gccore.h +++ b/wii/libogc/include/gccore.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __GCCORE_H__ #define __GCCORE_H__ @@ -99,7 +98,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! * \mainpage * @@ -107,7 +105,6 @@ distribution. * - \subpage api_doc */ - /*! * \page intro Introduction * Welcome to the libOGC reference documentation. diff --git a/wii/libogc/include/gctypes.h b/wii/libogc/include/gctypes.h index 9b25df14f9..307dcf7b6f 100644 --- a/wii/libogc/include/gctypes.h +++ b/wii/libogc/include/gctypes.h @@ -47,7 +47,6 @@ typedef volatile float vf32; typedef volatile double vf64; /*+----------------------------------------------------------------------------------------------+*/ - typedef unsigned int BOOL; /*+----------------------------------------------------------------------------------------------+*/ // alias type typedefs @@ -78,7 +77,6 @@ typedef unsigned int BOOL; #endif /* BYTE_ORDER */ /*+----------------------------------------------------------------------------------------------+*/ - //! argv structure /*! \struct __argv @@ -106,5 +104,4 @@ extern struct __argv *__system_argv; #endif /* TYPES_H */ - /* END OF FILE */ diff --git a/wii/libogc/include/ipv4/lwip/ip.h b/wii/libogc/include/ipv4/lwip/ip.h index d407b3d694..a7ad9f8449 100644 --- a/wii/libogc/include/ipv4/lwip/ip.h +++ b/wii/libogc/include/ipv4/lwip/ip.h @@ -40,7 +40,6 @@ #include "lwip/err.h" - void ip_init(void); struct netif *ip_route(struct ip_addr *dest); err_t ip_input(struct pbuf *p, struct netif *inp); @@ -65,7 +64,6 @@ err_t ip_output_if(struct pbuf *p, struct ip_addr *src, struct ip_addr *dest, #endif /* IP_HDRINCL */ #define IP_HDRINCL NULL - /* This is the common part of all PCB types. It needs to be at the beginning of a PCB type definition. It is located here so that changes to this common part are made in one location instead of @@ -93,8 +91,6 @@ err_t ip_output_if(struct pbuf *p, struct ip_addr *src, struct ip_addr *dest, #define SOF_OOBINLINE (u16_t)0x0100U /* leave received OOB data in line */ #define SOF_REUSEPORT (u16_t)0x0200U /* allow local address & port reuse */ - - #ifdef PACK_STRUCT_USE_INCLUDES # include "arch/bpstruct.h" #endif @@ -151,4 +147,3 @@ void ip_debug_print(struct pbuf *p); #endif /* __LWIP_IP_H__ */ - diff --git a/wii/libogc/include/ipv4/lwip/ip_addr.h b/wii/libogc/include/ipv4/lwip/ip_addr.h index fa921961de..9d173303f9 100644 --- a/wii/libogc/include/ipv4/lwip/ip_addr.h +++ b/wii/libogc/include/ipv4/lwip/ip_addr.h @@ -113,7 +113,6 @@ extern const struct ip_addr ip_addr_broadcast; #define IN_LOOPBACKNET 127 /* official! */ - #define IP4_ADDR(ipaddr, a,b,c,d) (ipaddr)->addr = htonl(((u32_t)(a & 0xff) << 24) | ((u32_t)(b & 0xff) << 16) | \ ((u32_t)(c & 0xff) << 8) | (u32_t)(d & 0xff)) @@ -140,7 +139,6 @@ u8_t ip_addr_isbroadcast(struct ip_addr *, struct netif *); #define ip_addr_ismulticast(addr1) (((addr1)->addr & ntohl(0xf0000000)) == ntohl(0xe0000000)) - #define ip_addr_debug_print(debug, ipaddr) LWIP_DEBUGF(debug, ("%"U16_F".%"U16_F".%"U16_F".%"U16_F, \ ipaddr?(u16_t)(ntohl((ipaddr)->addr) >> 24) & 0xff:0, \ ipaddr?(u16_t)(ntohl((ipaddr)->addr) >> 16) & 0xff:0, \ @@ -155,8 +153,3 @@ u8_t ip_addr_isbroadcast(struct ip_addr *, struct netif *); #define ip4_addr4(ipaddr) ((u16_t)(ntohl((ipaddr)->addr)) & 0xff) #endif /* __LWIP_IP_ADDR_H__ */ - - - - - diff --git a/wii/libogc/include/ipv4/lwip/ip_frag.h b/wii/libogc/include/ipv4/lwip/ip_frag.h index 4a932d960b..2c6ac63ecf 100644 --- a/wii/libogc/include/ipv4/lwip/ip_frag.h +++ b/wii/libogc/include/ipv4/lwip/ip_frag.h @@ -44,4 +44,3 @@ err_t ip_frag(struct pbuf *p, struct netif *netif, struct ip_addr *dest); #endif /* __LWIP_IP_FRAG_H__ */ - diff --git a/wii/libogc/include/lwip/api.h b/wii/libogc/include/lwip/api.h index ad1002c375..5a30679826 100644 --- a/wii/libogc/include/lwip/api.h +++ b/wii/libogc/include/lwip/api.h @@ -98,4 +98,3 @@ struct netconn { #endif /* __LWIP_API_H__ */ - diff --git a/wii/libogc/include/lwip/arch.h b/wii/libogc/include/lwip/arch.h index 3a831d07d5..a27b2467eb 100644 --- a/wii/libogc/include/lwip/arch.h +++ b/wii/libogc/include/lwip/arch.h @@ -54,8 +54,6 @@ #define PACK_STRUCT_FIELD(x) x #endif /* PACK_STRUCT_FIELD */ - - #ifdef LWIP_PROVIDE_ERRNO #define EPERM 1 /* Operation not permitted */ @@ -186,7 +184,6 @@ #define ENOMEDIUM 123 /* No medium found */ #define EMEDIUMTYPE 124 /* Wrong medium type */ - #define ENSROK 0 /* DNS server returned answer with no data */ #define ENSRNODATA 160 /* DNS server returned answer with no data */ #define ENSRFORMERR 161 /* DNS server claims query was misformatted */ diff --git a/wii/libogc/include/lwip/debug.h b/wii/libogc/include/lwip/debug.h index 8555b938ed..ec3f4081f1 100644 --- a/wii/libogc/include/lwip/debug.h +++ b/wii/libogc/include/lwip/debug.h @@ -83,8 +83,3 @@ #endif /* __LWIP_DEBUG_H__ */ - - - - - diff --git a/wii/libogc/include/lwip/def.h b/wii/libogc/include/lwip/def.h index b1da6d7291..f306bd58a5 100644 --- a/wii/libogc/include/lwip/def.h +++ b/wii/libogc/include/lwip/def.h @@ -42,6 +42,5 @@ #define NULL ((void *)0) #endif - #endif /* __LWIP_DEF_H__ */ diff --git a/wii/libogc/include/lwip/dhcp.h b/wii/libogc/include/lwip/dhcp.h index 04d72568c4..22efb24969 100644 --- a/wii/libogc/include/lwip/dhcp.h +++ b/wii/libogc/include/lwip/dhcp.h @@ -201,7 +201,6 @@ void dhcp_fine_tmr(void); #define DHCP_OPTION_MESSAGE_TYPE 53 /* RFC 2132 9.6, important for DHCP */ #define DHCP_OPTION_MESSAGE_TYPE_LEN 1 - #define DHCP_OPTION_SERVER_ID 54 /* RFC 2132 9.7, server IP address */ #define DHCP_OPTION_PARAMETER_REQUEST_LIST 55 /* RFC 2132 9.8, requested option types */ diff --git a/wii/libogc/include/lwip/err.h b/wii/libogc/include/lwip/err.h index 217ffed4bf..a907e81820 100644 --- a/wii/libogc/include/lwip/err.h +++ b/wii/libogc/include/lwip/err.h @@ -44,7 +44,6 @@ typedef s8_t err_t; #define ERR_MEM -1 /* Out of memory error. */ #define ERR_BUF -2 /* Buffer error. */ - #define ERR_ABRT -3 /* Connection aborted. */ #define ERR_RST -4 /* Connection reset. */ #define ERR_CLSD -5 /* Connection closed. */ @@ -61,7 +60,6 @@ typedef s8_t err_t; #define ERR_IF -11 /* Low-level netif error */ #define ERR_ISCONN -12 /* Already connected. */ - #ifdef LWIP_DEBUG extern char *lwip_strerr(err_t err); #else diff --git a/wii/libogc/include/lwip/lwipopts.h b/wii/libogc/include/lwip/lwipopts.h index 7313a3c6bc..fc7f3c6f3d 100644 --- a/wii/libogc/include/lwip/lwipopts.h +++ b/wii/libogc/include/lwip/lwipopts.h @@ -149,7 +149,6 @@ a lot of data that needs to be copied, this should be set high. */ /* ---------- ICMP options ---------- */ #define ICMP_TTL 255 - /* ---------- DHCP options ---------- */ /* Define LWIP_DHCP to 1 if you want DHCP configuration of interfaces. DHCP is not implemented in lwIP 0.5.1, however, so @@ -216,5 +215,4 @@ a lot of data that needs to be copied, this should be set high. */ #define DBG_MIN_LEVEL DBG_LEVEL_OFF #endif - #endif /* __LWIPOPTS_H__ */ diff --git a/wii/libogc/include/lwip/mem.h b/wii/libogc/include/lwip/mem.h index ae6db434ab..f492c95f3d 100644 --- a/wii/libogc/include/lwip/mem.h +++ b/wii/libogc/include/lwip/mem.h @@ -41,7 +41,6 @@ typedef u32_t mem_size_t; typedef u16_t mem_size_t; #endif /* MEM_SIZE > 64000 */ - void mem_init(void); void *mem_malloc(mem_size_t size); diff --git a/wii/libogc/include/lwip/opt.h b/wii/libogc/include/lwip/opt.h index 4e7f0d84c4..8ff2f27dce 100644 --- a/wii/libogc/include/lwip/opt.h +++ b/wii/libogc/include/lwip/opt.h @@ -152,8 +152,6 @@ a lot of data that needs to be copied, this should be set high. */ #define PBUF_LINK_HLEN 14 #endif - - /* ---------- ARP options ---------- */ /** Number of active hardware address, IP address pairs cached */ @@ -274,7 +272,6 @@ a lot of data that needs to be copied, this should be set high. */ #define TCP_SYNMAXRTX 6 #endif - /* Controls if TCP should queue segments that arrive out of order. Define to 0 if your device is low on memory. */ #ifndef TCP_QUEUE_OOSEQ @@ -297,7 +294,6 @@ a lot of data that needs to be copied, this should be set high. */ #define TCP_SND_QUEUELEN 4 * TCP_SND_BUF/TCP_MSS #endif - /* Maximum number of retransmissions of data segments. */ /* Maximum number of retransmissions of SYN segments. */ @@ -326,7 +322,6 @@ a lot of data that needs to be copied, this should be set high. */ #define LWIP_COMPAT_SOCKETS 1 #endif - #ifndef TCPIP_THREAD_PRIO #define TCPIP_THREAD_PRIO 1 #endif @@ -343,14 +338,12 @@ a lot of data that needs to be copied, this should be set high. */ #define DEFAULT_THREAD_PRIO 1 #endif - /* ---------- Socket Options ---------- */ /* Enable SO_REUSEADDR and SO_REUSEPORT options */ #ifndef SO_REUSE # define SO_REUSE 0 #endif - /* ---------- Statistics options ---------- */ #ifndef LWIP_STATS #define LWIP_STATS 1 @@ -433,8 +426,6 @@ a lot of data that needs to be copied, this should be set high. */ #define NUM_PPP 1 /* Max PPP sessions. */ - - #ifndef PAP_SUPPORT #define PAP_SUPPORT 0 /* Set for PAP. */ #endif @@ -455,7 +446,6 @@ a lot of data that needs to be copied, this should be set high. */ #define MD5_SUPPORT 0 /* Set for MD5 (see also CHAP) */ #endif - /* * Timeouts. */ @@ -470,7 +460,6 @@ a lot of data that needs to be copied, this should be set high. */ #define CHAP_DEFTIMEOUT 6 /* Timeout time in seconds */ #define CHAP_DEFTRANSMITS 10 /* max # times to send challenge */ - /* Interval in seconds between keepalive echo requests, 0 to disable. */ #if 1 #define LCP_ECHOINTERVAL 0 @@ -504,7 +493,6 @@ a lot of data that needs to be copied, this should be set high. */ #define PPP_DEFMRU 296 /* Try for this */ #define PPP_MINMRU 128 /* No MRUs below this */ - #define MAXNAMELEN 256 /* max length of hostname or name for auth */ #define MAXSECRETLEN 256 /* max length of password or secret */ @@ -658,12 +646,9 @@ a lot of data that needs to be copied, this should be set high. */ #define DHCP_DEBUG DBG_OFF #endif - #ifndef DBG_MIN_LEVEL #define DBG_MIN_LEVEL DBG_LEVEL_OFF #endif #endif /* __LWIP_OPT_H__ */ - - diff --git a/wii/libogc/include/lwip/pbuf.h b/wii/libogc/include/lwip/pbuf.h index 4039fd71c3..b7509bb7a8 100644 --- a/wii/libogc/include/lwip/pbuf.h +++ b/wii/libogc/include/lwip/pbuf.h @@ -35,7 +35,6 @@ #include "arch/cc.h" - #define PBUF_TRANSPORT_HLEN 20 #define PBUF_IP_HLEN 20 diff --git a/wii/libogc/include/lwip/raw.h b/wii/libogc/include/lwip/raw.h index 6f7a98717f..ef6478e60a 100644 --- a/wii/libogc/include/lwip/raw.h +++ b/wii/libogc/include/lwip/raw.h @@ -70,5 +70,4 @@ err_t raw_send (struct raw_pcb *pcb, struct pbuf *p); u8_t raw_input (struct pbuf *p, struct netif *inp); void raw_init (void); - #endif /* __LWIP_RAW_H__ */ diff --git a/wii/libogc/include/lwip/sockets.h b/wii/libogc/include/lwip/sockets.h index 9f5cec16ca..314786b428 100644 --- a/wii/libogc/include/lwip/sockets.h +++ b/wii/libogc/include/lwip/sockets.h @@ -30,7 +30,6 @@ * */ - #ifndef __LWIP_SOCKETS_H__ #define __LWIP_SOCKETS_H__ #include "lwip/ip_addr.h" @@ -53,7 +52,6 @@ struct sockaddr { # define socklen_t int #endif - #define SOCK_STREAM 1 #define SOCK_DGRAM 2 #define SOCK_RAW 3 @@ -86,8 +84,6 @@ struct sockaddr { #define SO_ERROR 0x1007 /* get error status and clear */ #define SO_TYPE 0x1008 /* get socket type */ - - /* * Structure used for manipulating linger option. */ @@ -101,7 +97,6 @@ struct linger { */ #define SOL_SOCKET 0xfff /* options for socket level */ - #define AF_UNSPEC 0 #define AF_INET 2 #define PF_INET AF_INET @@ -117,14 +112,12 @@ struct linger { /* Flags we can use with send and recv. */ #define MSG_DONTWAIT 0x40 /* Nonblocking i/o for this operation only */ - /* * Options for level IPPROTO_IP */ #define IP_TOS 1 #define IP_TTL 2 - #define IPTOS_TOS_MASK 0x1E #define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) #define IPTOS_LOWDELAY 0x10 @@ -147,7 +140,6 @@ struct linger { #define IPTOS_PREC_PRIORITY 0x20 #define IPTOS_PREC_ROUTINE 0x00 - /* * Commands for ioctlsocket(), taken from the BSD file fcntl.h. * diff --git a/wii/libogc/include/lwip/stats.h b/wii/libogc/include/lwip/stats.h index a0468d3867..dbf3b4b2fd 100644 --- a/wii/libogc/include/lwip/stats.h +++ b/wii/libogc/include/lwip/stats.h @@ -99,7 +99,6 @@ struct stats_ { extern struct stats_ lwip_stats; - void stats_init(void); #define STATS_INC(x) ++lwip_stats.x @@ -153,6 +152,3 @@ void stats_display(void); #endif /* __LWIP_STATS_H__ */ - - - diff --git a/wii/libogc/include/lwip/sys.h b/wii/libogc/include/lwip/sys.h index 8ce1359642..6c07ff4693 100644 --- a/wii/libogc/include/lwip/sys.h +++ b/wii/libogc/include/lwip/sys.h @@ -36,7 +36,6 @@ #include "lwip/opt.h" - #if NO_SYS /* For a totally minimal and standalone system, we provide null @@ -118,7 +117,6 @@ u32_t sys_arch_mbox_fetch(sys_mbox_t mbox, void **msg, u32_t timeout); void sys_mbox_free(sys_mbox_t mbox); void sys_mbox_fetch(sys_mbox_t mbox, void **msg); - /* Thread functions. */ sys_thread_t sys_thread_new(void (* thread)(void *arg), void *arg, int prio); diff --git a/wii/libogc/include/lwip/tcp.h b/wii/libogc/include/lwip/tcp.h index 5812280cb8..884ef138ee 100644 --- a/wii/libogc/include/lwip/tcp.h +++ b/wii/libogc/include/lwip/tcp.h @@ -99,7 +99,6 @@ void tcp_setprio (struct tcp_pcb *pcb, u8_t prio); void tcp_slowtmr (void); void tcp_fasttmr (void); - /* Only used by IP to pass a TCP segment to TCP: */ void tcp_input (struct pbuf *p, struct netif *inp); /* Used within the TCP code only: */ @@ -107,8 +106,6 @@ err_t tcp_output (struct tcp_pcb *pcb); void tcp_rexmit (struct tcp_pcb *pcb); void tcp_rexmit_rto (struct tcp_pcb *pcb); - - #define TCP_SEQ_LT(a,b) ((s32_t)((a)-(b)) < 0) #define TCP_SEQ_LEQ(a,b) ((s32_t)((a)-(b)) <= 0) #define TCP_SEQ_GT(a,b) ((s32_t)((a)-(b)) > 0) @@ -166,7 +163,6 @@ void tcp_rexmit_rto (struct tcp_pcb *pcb); #define TCP_KEEPCNT 9 /* Counter for KEEPALIVE probes */ #define TCP_MAXIDLE TCP_KEEPCNT * TCP_KEEPINTVL /* Maximum KEEPALIVE probe time */ - #ifdef PACK_STRUCT_USE_INCLUDES # include "arch/bpstruct.h" #endif @@ -277,7 +273,6 @@ struct tcp_pcb { u16_t snd_buf; /* Available buffer space for sending (in bytes). */ u16_t snd_queuelen; /* Available buffer space for sending (in tcp_segs). */ - /* These are ordered by sequence number: */ struct tcp_seg *unsent; /* Unsent (queued) segments. */ struct tcp_seg *unacked; /* Sent but unacknowledged segments. */ @@ -529,5 +524,3 @@ extern struct tcp_pcb *tcp_tmp_pcb; /* Only used for temporary storage. */ #endif /* LWIP_DEBUG */ #endif /* __LWIP_TCP_H__ */ - - diff --git a/wii/libogc/include/lwip/udp.h b/wii/libogc/include/lwip/udp.h index 1460a6394a..0f3b4f1e13 100644 --- a/wii/libogc/include/lwip/udp.h +++ b/wii/libogc/include/lwip/udp.h @@ -101,4 +101,3 @@ void udp_debug_print(struct udp_hdr *udphdr); #endif #endif /* __LWIP_UDP_H__ */ - diff --git a/wii/libogc/include/netif/arch/cc.h b/wii/libogc/include/netif/arch/cc.h index 8e22488d23..f945b7b6db 100644 --- a/wii/libogc/include/netif/arch/cc.h +++ b/wii/libogc/include/netif/arch/cc.h @@ -48,7 +48,6 @@ typedef u32 u32_t; typedef s32 s32_t; typedef u32 mem_ptr_t; - #define PACK_STRUCT_FIELD(x) x #define PACK_STRUCT_STRUCT __attribute__((packed)) #define PACK_STRUCT_BEGIN @@ -69,5 +68,4 @@ typedef u32 mem_ptr_t; #define S32_F "d" #define X32_F "x" - #endif /* __ARCH_CC_H__ */ diff --git a/wii/libogc/include/netif/arch/init.h b/wii/libogc/include/netif/arch/init.h index 40098c71b9..8ac7148756 100644 --- a/wii/libogc/include/netif/arch/init.h +++ b/wii/libogc/include/netif/arch/init.h @@ -41,6 +41,3 @@ int wait_for_tcpip_init(void); #endif /* __ARCH_INIT_H__ */ - - - diff --git a/wii/libogc/include/network.h b/wii/libogc/include/network.h index 91a526d1f1..dd6fcca4bd 100644 --- a/wii/libogc/include/network.h +++ b/wii/libogc/include/network.h @@ -40,8 +40,6 @@ #define SO_ERROR 0x1007 /* get error status and clear */ #define SO_TYPE 0x1008 /* get socket type */ - - /* * Structure used for manipulating linger option. */ @@ -76,7 +74,6 @@ struct linger { #define IP_TOS 1 #define IP_TTL 2 - #define IPTOS_TOS_MASK 0x1E #define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) #define IPTOS_LOWDELAY 0x10 @@ -99,7 +96,6 @@ struct linger { #define IPTOS_PREC_PRIORITY 0x20 #define IPTOS_PREC_ROUTINE 0x00 - /* * Commands for ioctlsocket(), taken from the BSD file fcntl.h. * diff --git a/wii/libogc/include/ogc/aram.h b/wii/libogc/include/ogc/aram.h index df59ea1fc5..12beeb8f28 100644 --- a/wii/libogc/include/ogc/aram.h +++ b/wii/libogc/include/ogc/aram.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __ARAM_H__ #define __ARAM_H__ @@ -39,7 +38,6 @@ distribution. #include - /*! * \addtogroup dmamode ARAM DMA transfer direction * @{ @@ -52,8 +50,6 @@ distribution. * @} */ - - /*! * \addtogroup memmode ARAM memory access modes * @{ @@ -66,12 +62,10 @@ distribution. * @} */ - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - /*! * \typedef void (*ARCallback)(void) * \brief function pointer typedef for the user's ARAM interrupt callback @@ -80,7 +74,6 @@ distribution. */ typedef void (*ARCallback)(void); - /*! * \fn ARCallback AR_RegisterCallback(ARCallback callback) * \brief Register the given function as a DMA callback @@ -93,7 +86,6 @@ typedef void (*ARCallback)(void); */ ARCallback AR_RegisterCallback(ARCallback callback); - /*! * \fn u32 AR_GetDMAStatus() * \brief Get current status of DMA @@ -102,7 +94,6 @@ ARCallback AR_RegisterCallback(ARCallback callback); */ u32 AR_GetDMAStatus(); - /*! * \fn u32 AR_Init(u32 *stack_idx_array,u32 num_entries) * \brief Initializes ARAM subsystem. @@ -146,7 +137,6 @@ u32 AR_GetDMAStatus(); */ u32 AR_Init(u32 *stack_idx_array,u32 num_entries); - /*! * \fn void AR_StartDMA(u32 dir,u32 memaddr,u32 aramaddr,u32 len) * \brief Initiates a DMA between main memory and ARAM. @@ -166,7 +156,6 @@ u32 AR_Init(u32 *stack_idx_array,u32 num_entries); */ void AR_StartDMA(u32 dir,u32 memaddr,u32 aramaddr,u32 len); - /*! * \fn u32 AR_Alloc(u32 len) * \brief Allocate a block of memory from ARAM having len bytes. @@ -179,7 +168,6 @@ void AR_StartDMA(u32 dir,u32 memaddr,u32 aramaddr,u32 len); */ u32 AR_Alloc(u32 len); - /*! * \fn u32 AR_Free(u32 *len) * \brief Free a block from ARAM @@ -190,7 +178,6 @@ u32 AR_Alloc(u32 len); */ u32 AR_Free(u32 *len); - /*! * \fn void AR_Clear(u32 flag) * \brief Clear ARAM memory @@ -201,7 +188,6 @@ u32 AR_Free(u32 *len); */ void AR_Clear(u32 flag); - /*! * \fn BOOL AR_CheckInit() * \brief Get the ARAM subsystem initialization flag @@ -211,7 +197,6 @@ void AR_Clear(u32 flag); */ BOOL AR_CheckInit(); - /*! * \fn void AR_Reset() * \brief Clears the ARAM subsystem initialization flag. @@ -222,7 +207,6 @@ BOOL AR_CheckInit(); */ void AR_Reset(); - /*! * \fn u32 AR_GetSize() * \brief Get the total size - in bytes - of ARAM as calculated during AR_Init() @@ -231,7 +215,6 @@ void AR_Reset(); */ u32 AR_GetSize(); - /*! * \fn u32 AR_GetBaseAddress() * \brief Get the baseaddress of ARAM memory @@ -240,7 +223,6 @@ u32 AR_GetSize(); */ u32 AR_GetBaseAddress(); - /*! * \fn u32 AR_GetInternalSize() * \brief Get the size of the internal ARAM memory @@ -249,7 +231,6 @@ u32 AR_GetBaseAddress(); */ u32 AR_GetInternalSize(); - /*! * \def AR_StartDMARead(maddr,araddr,tlen) * \brief Wraps the DMA read operation done by AR_StartDMA() @@ -257,7 +238,6 @@ u32 AR_GetInternalSize(); #define AR_StartDMARead(maddr,araddr,tlen) \ AR_StartDMA(AR_ARAMTOMRAM,maddr,araddr,tlen); - /*! * \def AR_StartDMAWrite(maddr,araddr,tlen) * \brief Wraps the DMA write operation done by AR_StartDMA() diff --git a/wii/libogc/include/ogc/arqmgr.h b/wii/libogc/include/ogc/arqmgr.h index 64e4259eca..5399212375 100644 --- a/wii/libogc/include/ogc/arqmgr.h +++ b/wii/libogc/include/ogc/arqmgr.h @@ -1,6 +1,5 @@ /*------------------------------------------------------------- - arqmgr.h -- ARAM task queue management Copyright (C) 2004 @@ -26,28 +25,23 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #ifndef __ARQMGR_H__ #define __ARQMGR_H__ - /*! * \file arqmgr.h * \brief ARAM queue managemnt subsystem * */ - #include #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - /*! * \typedef void (*ARQMCallback)() * \brief function pointer typedef for the user's callback when ARAM operation has completed @@ -55,7 +49,6 @@ distribution. */ typedef void (*ARQMCallback)(s32 result); - /*! * \fn void ARQM_Init(u32 arambase,s32 len) * \brief Initialize the ARAM queue management system @@ -67,7 +60,6 @@ typedef void (*ARQMCallback)(s32 result); */ void ARQM_Init(u32 arambase,s32 len); - /*! * \fn u32 ARQM_PushData(void *buff,s32 len) * \brief Push the data onto the ARAM queue @@ -79,7 +71,6 @@ void ARQM_Init(u32 arambase,s32 len); */ u32 ARQM_PushData(void *buffer,s32 len); - /*! * \fn u32 ARQM_GetZeroBuffer() * \brief Returns ARAM address of 'zero buffer' @@ -88,7 +79,6 @@ u32 ARQM_PushData(void *buffer,s32 len); */ u32 ARQM_GetZeroBuffer(); - /*! * \fn u32 ARQM_GetStackPointer() * \brief Return the ARAM address of the next free stack pointer @@ -97,7 +87,6 @@ u32 ARQM_GetZeroBuffer(); */ u32 ARQM_GetStackPointer(); - /*! * \fn u32 ARQM_GetFreeSize() * \brief Return Returns remaining number of bytes on stack diff --git a/wii/libogc/include/ogc/arqueue.h b/wii/libogc/include/ogc/arqueue.h index 137e92978b..0c7d94cb14 100644 --- a/wii/libogc/include/ogc/arqueue.h +++ b/wii/libogc/include/ogc/arqueue.h @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #ifndef __ARQUEUE_H__ #define __ARQUEUE_H__ @@ -67,7 +65,6 @@ struct _arq_request { void ARQ_Init(); void ARQ_Reset(); - /*! * \fn void ARQ_PostRequest(ARQRequest *req,u32 owner,u32 dir,u32 prio,u32 aram_addr,u32 mram_addr,u32 len) * \brief Enqueue a ARAM DMA transfer request. @@ -85,7 +82,6 @@ void ARQ_Reset(); */ void ARQ_PostRequest(ARQRequest *req,u32 owner,u32 dir,u32 prio,u32 aram_addr,u32 mram_addr,u32 len); - /*! * \fn void ARQ_PostRequestAsync(ARQRequest *req,u32 owner,u32 dir,u32 prio,u32 aram_addr,u32 mram_addr,u32 len,ARQCallback cb) * \brief Enqueue a ARAM DMA transfer request. diff --git a/wii/libogc/include/ogc/audio.h b/wii/libogc/include/ogc/audio.h index c37fe3cf28..e7aa109d9e 100644 --- a/wii/libogc/include/ogc/audio.h +++ b/wii/libogc/include/ogc/audio.h @@ -25,11 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - - -------------------------------------------------------------*/ - #ifndef __AUDIO_H__ #define __AUDIO_H__ @@ -52,8 +49,6 @@ distribution. * @} */ - - /*! * \addtogroup ai_sample_rates AI sampling rates * @{ @@ -78,7 +73,6 @@ distribution. */ typedef void (*AIDCallback)(void); - /*! * \typedef void (*AISCallback)(u32 smp_cnt) * \brief function pointer typedef for the user's Audio Streaming interrupt callback @@ -87,7 +81,6 @@ typedef void (*AIDCallback)(void); */ typedef void (*AISCallback)(u32 smp_cnt); - /*! * \fn AISCallback AUDIO_RegisterStreamCallback(AISCallback callback) * \brief Register a user callback function for the AUDIO streaming interface @@ -98,7 +91,6 @@ typedef void (*AISCallback)(u32 smp_cnt); */ AISCallback AUDIO_RegisterStreamCallback(AISCallback callback); - /*! * \fn void AUDIO_Init(u8 *stack) * \brief Initialize the AUDIO subsystem @@ -109,7 +101,6 @@ AISCallback AUDIO_RegisterStreamCallback(AISCallback callback); */ void AUDIO_Init(u8 *stack); - /*! * \fn void AUDIO_SetStreamVolLeft(u8 vol) * \brief Set streaming volume on the left channel. @@ -120,7 +111,6 @@ void AUDIO_Init(u8 *stack); */ void AUDIO_SetStreamVolLeft(u8 vol); - /*! * \fn u8 AUDIO_GetStreamVolLeft() * \brief Get streaming volume of the left channel. @@ -129,7 +119,6 @@ void AUDIO_SetStreamVolLeft(u8 vol); */ u8 AUDIO_GetStreamVolLeft(); - /*! * \fn void AUDIO_SetStreamVolRight(u8 vol) * \brief set streaming volume of the right channel. @@ -140,7 +129,6 @@ u8 AUDIO_GetStreamVolLeft(); */ void AUDIO_SetStreamVolRight(u8 vol); - /*! * \fn u8 AUDIO_GetStreamVolRight() * \brief Get streaming volume of the right channel. @@ -149,7 +137,6 @@ void AUDIO_SetStreamVolRight(u8 vol); */ u8 AUDIO_GetStreamVolRight(); - /*! * \fn void AUDIO_SetStreamSampleRate(u32 rate) * \brief Set streaming sample rate @@ -160,7 +147,6 @@ u8 AUDIO_GetStreamVolRight(); */ void AUDIO_SetStreamSampleRate(u32 rate); - /*! * \fn u32 AUDIO_GetStreamSampleRate() * \brief Get streaming sample rate @@ -169,7 +155,6 @@ void AUDIO_SetStreamSampleRate(u32 rate); */ u32 AUDIO_GetStreamSampleRate(); - /*! * \fn AIDCallback AUDIO_RegisterDMACallback(AIDCallback callback) * \brief Register a user callback function for the audio DMA interface. @@ -183,7 +168,6 @@ u32 AUDIO_GetStreamSampleRate(); */ AIDCallback AUDIO_RegisterDMACallback(AIDCallback callback); - /*! * \fn void AUDIO_InitDMA(u32 startaddr,u32 len) * \brief Initialize an audio DMA transfer @@ -195,7 +179,6 @@ AIDCallback AUDIO_RegisterDMACallback(AIDCallback callback); */ void AUDIO_InitDMA(u32 startaddr,u32 len); - /*! * \fn u16 AUDIO_GetDMAEnableFlag() * \brief Get the audio DMA flag @@ -204,7 +187,6 @@ void AUDIO_InitDMA(u32 startaddr,u32 len); */ u16 AUDIO_GetDMAEnableFlag(); - /*! * \fn void AUDIO_StartDMA() * \brief Start the audio DMA operation. @@ -216,7 +198,6 @@ u16 AUDIO_GetDMAEnableFlag(); */ void AUDIO_StartDMA(); - /*! * \fn void AUDIO_StopDMA() * \brief Stop the previously started audio DMA operation. @@ -225,7 +206,6 @@ void AUDIO_StartDMA(); */ void AUDIO_StopDMA(); - /*! * \fn u32 AUDIO_GetDMABytesLeft() * \brief Get the count of bytes, left to play, from the audio DMA interface @@ -234,7 +214,6 @@ void AUDIO_StopDMA(); */ u32 AUDIO_GetDMABytesLeft(); - /*! * \fn u32 AUDIO_GetDMALength() * \brief Get the DMA transfer length configured in the audio DMA interface. @@ -243,7 +222,6 @@ u32 AUDIO_GetDMABytesLeft(); */ u32 AUDIO_GetDMALength(); - /*! * \fn u32 AUDIO_GetDMAStartAddr() * \brief Get the main memory address for the DMA operation. @@ -252,7 +230,6 @@ u32 AUDIO_GetDMALength(); */ u32 AUDIO_GetDMAStartAddr(); - /*! * \fn void AUDIO_SetStreamTrigger(u32 cnt) * \brief Set the sample count for the stream trigger @@ -263,7 +240,6 @@ u32 AUDIO_GetDMAStartAddr(); */ void AUDIO_SetStreamTrigger(u32 cnt); - /*! * \fn void AUDIO_ResetStreamSampleCnt() * \brief Reset the stream sample count register. @@ -272,7 +248,6 @@ void AUDIO_SetStreamTrigger(u32 cnt); */ void AUDIO_ResetStreamSampleCnt(); - /*! * \fn void AUDIO_SetDSPSampleRate(u8 rate) * \brief Set the sampling rate for the DSP interface @@ -283,7 +258,6 @@ void AUDIO_ResetStreamSampleCnt(); */ void AUDIO_SetDSPSampleRate(u8 rate); - /*! * \fn u32 AUDIO_GetDSPSampleRate() * \brief Get the sampling rate for the DSP interface @@ -292,7 +266,6 @@ void AUDIO_SetDSPSampleRate(u8 rate); */ u32 AUDIO_GetDSPSampleRate(); - /*! * \fn void AUDIO_SetStreamPlayState(u32 state) * \brief Set the play state for the streaming audio interface @@ -303,7 +276,6 @@ u32 AUDIO_GetDSPSampleRate(); */ void AUDIO_SetStreamPlayState(u32 state); - /*! * \fn u32 AUDIO_GetStreamPlayState() * \brief Get the play state from the streaming audio interface diff --git a/wii/libogc/include/ogc/cache.h b/wii/libogc/include/ogc/cache.h index 0753956a1f..401a1460e0 100644 --- a/wii/libogc/include/ogc/cache.h +++ b/wii/libogc/include/ogc/cache.h @@ -1,6 +1,5 @@ /*------------------------------------------------------------- - cache.h -- Cache interface Copyright (C) 2004 @@ -26,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #ifndef __CACHE_H__ #define __CACHE_H__ @@ -47,7 +44,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! * \fn void DCEnable() * \brief Enable L1 d-cache @@ -56,7 +52,6 @@ distribution. */ void DCEnable(); - /*! * \fn void DCDisable() * \brief Disable L1 d-cache @@ -65,7 +60,6 @@ void DCEnable(); */ void DCDisable(); - /*! * \fn void DCFreeze() * \brief Current contents of the L1 d-cache are locked down and will not be cast out. @@ -77,7 +71,6 @@ void DCDisable(); */ void DCFreeze(); - /*! * \fn void DCUnfreeze() * \brief Undoes actions of DCFreeze(). @@ -89,7 +82,6 @@ void DCFreeze(); */ void DCUnfreeze(); - /*! * \fn void DCFlashInvalidate() * \brief Invalidate L1 d-cache. @@ -101,7 +93,6 @@ void DCUnfreeze(); */ void DCFlashInvalidate(); - /*! * \fn void DCInvalidateRange(void *startaddress,u32 len) * \brief Invalidates a given range of the d-cache. @@ -115,7 +106,6 @@ void DCFlashInvalidate(); */ void DCInvalidateRange(void *startaddress,u32 len); - /*! * \fn void DCFlushRange(void *startaddress,u32 len) * \brief Flushes a given range. @@ -143,7 +133,6 @@ void DCFlushRange(void *startaddress,u32 len); */ void DCStoreRange(void *startaddress,u32 len); - /*! * \fn void DCFlushRangeNoSync(void *startaddress,u32 len) * \brief Flushes a given range. @@ -158,7 +147,6 @@ void DCStoreRange(void *startaddress,u32 len); */ void DCFlushRangeNoSync(void *startaddress,u32 len); - /*! * \fn void DCStoreRangeNoSync(void *startaddress,u32 len) * \brief Ensures a range of memory is updated with any modified data in the cache. @@ -172,7 +160,6 @@ void DCFlushRangeNoSync(void *startaddress,u32 len); */ void DCStoreRangeNoSync(void *startaddress,u32 len); - /*! * \fn void DCZeroRange(void *startaddress,u32 len) * \brief Loads a range of memory into cache and zeroes all the cache lines. @@ -184,7 +171,6 @@ void DCStoreRangeNoSync(void *startaddress,u32 len); */ void DCZeroRange(void *startaddress,u32 len); - /*! * \fn void DCTouchRange(void *startaddress,u32 len) * \brief Loads a range of memory into cache. @@ -196,7 +182,6 @@ void DCZeroRange(void *startaddress,u32 len); */ void DCTouchRange(void *startaddress,u32 len); - /*! * \fn void ICSync() * \brief Performs an instruction cache synchronization. @@ -207,7 +192,6 @@ void DCTouchRange(void *startaddress,u32 len); */ void ICSync(); - /*! * \fn void ICFlashInvalidate() * \brief Invalidate the L1 i-cache. @@ -219,7 +203,6 @@ void ICSync(); */ void ICFlashInvalidate(); - /*! * \fn void ICEnable() * \brief Enable L1 i-cache @@ -228,7 +211,6 @@ void ICFlashInvalidate(); */ void ICEnable(); - /*! * \fn void ICDisable() * \brief Disable L1 i-cache @@ -237,7 +219,6 @@ void ICEnable(); */ void ICDisable(); - /*! * \fn void ICFreeze() * \brief Current contents of the L1 i-cache are locked down and will not be cast out. @@ -249,7 +230,6 @@ void ICDisable(); */ void ICFreeze(); - /*! * \fn void ICUnfreeze() * \brief Undoes actions of ICFreeze(). @@ -261,7 +241,6 @@ void ICFreeze(); */ void ICUnfreeze(); - /*! * \fn void ICBlockInvalidate(void *startaddress) * \brief Invalidates a block in the i-cache. @@ -274,7 +253,6 @@ void ICUnfreeze(); */ void ICBlockInvalidate(void *startaddress); - /*! * \fn void ICInvalidateRange(void *startaddress,u32 len) * \brief Invalidate a range in the L1 i-cache. diff --git a/wii/libogc/include/ogc/card.h b/wii/libogc/include/ogc/card.h index 65d5d07be6..d94c43320f 100644 --- a/wii/libogc/include/ogc/card.h +++ b/wii/libogc/include/ogc/card.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __CARD_H__ #define __CARD_H__ @@ -37,7 +36,6 @@ distribution. */ - #include /*! \addtogroup cardsolts Memory card slots @@ -49,7 +47,6 @@ distribution. /*! @} */ - #define CARD_WORKAREA (5*8*1024) /*!< minimum size of the workarea passed to Mount[Async]() */ #define CARD_READSIZE 512 /*!< minimum size of block to read from memory card */ #define CARD_FILENAMELEN 32 /*!< maximum filename length */ @@ -79,7 +76,6 @@ distribution. /*! @} */ - /* File attribute defines */ #define CARD_ATTRIB_PUBLIC 0x04 #define CARD_ATTRIB_NOCOPY 0x08 @@ -117,7 +113,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! \typedef struct _card_file card_file \brief structure to hold the fileinformations upon open and for later use. \param chn CARD slot. @@ -134,7 +129,6 @@ typedef struct _card_file { u16 iblock; } card_file; - /*! \typedef struct card_dir \brief structure to hold the information of a directory entry \param chn CARD slot. @@ -156,7 +150,6 @@ typedef struct _card_dir { bool showall; } card_dir; - /*! \typedef struct card_stat \brief structure to hold the additional statistical informations. \param filename[CARD_FILENAMELEN] name of the file on card. @@ -209,7 +202,6 @@ typedef struct _card_stat { */ typedef void (*cardcallback)(s32 chan,s32 result); - /*! \fn s32 CARD_Init(const char *gamecode,const char *company) \brief Performs the initialization of the memory card subsystem \param[in] gamecode pointer to a 4byte long string to specify the vendors game code. May be NULL @@ -219,7 +211,6 @@ typedef void (*cardcallback)(s32 chan,s32 result); */ s32 CARD_Init(const char *gamecode,const char *company); - /*! \fn s32 CARD_Probe(s32 chn) \brief Performs a check against the desired EXI channel if a device is inserted \param[in] chn CARD slot @@ -228,7 +219,6 @@ s32 CARD_Init(const char *gamecode,const char *company); */ s32 CARD_Probe(s32 chn); - /*! \fn s32 CARD_ProbeEx(s32 chn,s32 *mem_size,s32 *sect_size) \brief Performs a check against the desired EXI channel if a memory card is inserted or mounted \param[in] chn CARD slot @@ -239,7 +229,6 @@ s32 CARD_Probe(s32 chn); */ s32 CARD_ProbeEx(s32 chn,s32 *mem_size,s32 *sect_size); - /*! \fn s32 CARD_Mount(s32 chn,void *workarea,cardcallback detach_cb) \brief Mounts the memory card in the slot CHN. Synchronous version. \param[in] chn CARD slot @@ -250,7 +239,6 @@ s32 CARD_ProbeEx(s32 chn,s32 *mem_size,s32 *sect_size); */ s32 CARD_Mount(s32 chn,void *workarea,cardcallback detach_cb); - /*! \fn s32 CARD_MountAsync(s32 chn,void *workarea,cardcallback detach_cb,cardcallback attach_cb) \brief Mounts the memory card in the slot CHN. This function returns immediately. Asynchronous version. \param[in] chn CARD slot @@ -262,7 +250,6 @@ s32 CARD_Mount(s32 chn,void *workarea,cardcallback detach_cb); */ s32 CARD_MountAsync(s32 chn,void *workarea,cardcallback detach_cb,cardcallback attach_cb); - /*! \fn s32 CARD_Unmount(s32 chn) \brief Unmounts the memory card in the slot CHN and releases the EXI bus. \param[in] chn CARD slot @@ -271,7 +258,6 @@ s32 CARD_MountAsync(s32 chn,void *workarea,cardcallback detach_cb,cardcallback a */ s32 CARD_Unmount(s32 chn); - /*! \fn s32 CARD_Read(card_file *file,void *buffer,u32 len,u32 offset) \brief Reads the data from the file into the buffer from the given offset with the given length. Synchronous version \param[in] file pointer to the card_file structure. It holds the fileinformations to read from. @@ -283,7 +269,6 @@ s32 CARD_Unmount(s32 chn); */ s32 CARD_Read(card_file *file,void *buffer,u32 len,u32 offset); - /*! \fn s32 CARD_ReadAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback callback) \brief Reads the data from the file into the buffer from the given offset with the given length. This function returns immediately. Asynchronous version \param[in] file pointer to the card_file structure. It holds the fileinformations to read from. @@ -296,7 +281,6 @@ s32 CARD_Read(card_file *file,void *buffer,u32 len,u32 offset); */ s32 CARD_ReadAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback callback); - /*! \fn s32 CARD_Open(s32 chn,const char *filename,card_file *file) \brief Opens the file with the given filename and fills in the fileinformations. \param[in] chn CARD slot @@ -307,7 +291,6 @@ s32 CARD_ReadAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback */ s32 CARD_Open(s32 chn,const char *filename,card_file *file); - /*! \fn s32 CARD_OpenEntry(s32 chn,card_dir *entry,card_file *file) \brief Opens the file with the given filename and fills in the fileinformations. \param[in] chn CARD slot @@ -318,7 +301,6 @@ s32 CARD_Open(s32 chn,const char *filename,card_file *file); */ s32 CARD_OpenEntry(s32 chn,card_dir *entry,card_file *file); - /*! \fn s32 CARD_Close(card_file *file) \brief Closes the file with the given card_file structure and releases the handle. \param[in] file pointer to the card_file structure to close. @@ -327,7 +309,6 @@ s32 CARD_OpenEntry(s32 chn,card_dir *entry,card_file *file); */ s32 CARD_Close(card_file *file); - /*! \fn s32 CARD_Create(s32 chn,const char *filename,u32 size,card_file *file) \brief Creates a new file with the given filename and fills in the fileinformations. Synchronous version. \param[in] chn CARD slot @@ -339,7 +320,6 @@ s32 CARD_Close(card_file *file); */ s32 CARD_Create(s32 chn,const char *filename,u32 size,card_file *file); - /*! \fn s32 CARD_CreateAsync(s32 chn,const char *filename,u32 size,card_file *file,cardcallback callback) \brief Creates a new file with the given filename and fills in the fileinformations. This function returns immediately. Asynchronous version. \param[in] chn CARD slot @@ -352,7 +332,6 @@ s32 CARD_Create(s32 chn,const char *filename,u32 size,card_file *file); */ s32 CARD_CreateAsync(s32 chn,const char *filename,u32 size,card_file *file,cardcallback callback); - /*! \fn s32 CARD_CreateEntry(s32 chn,card_dir *entry,card_file *file) \brief Creates a new file with the given filename and fills in the fileinformations. Synchronous version. \param[in] chn CARD slot @@ -363,7 +342,6 @@ s32 CARD_CreateAsync(s32 chn,const char *filename,u32 size,card_file *file,cardc */ s32 CARD_CreateEntry(s32 chn,card_dir *direntry,card_file *file); - /*! \fn s32 CARD_CreateEntryAsync(s32 chn,card_dir *entry,card_file *file,cardcallback callback) \brief Creates a new file with the given filename and fills in the fileinformations. This function returns immediately. Asynchronous version. \param[in] chn CARD slot @@ -375,7 +353,6 @@ s32 CARD_CreateEntry(s32 chn,card_dir *direntry,card_file *file); */ s32 CARD_CreateEntryAsync(s32 chn,card_dir *direntry,card_file *file,cardcallback callback); - /*! \fn s32 CARD_Delete(s32 chn,const char *filename) \brief Deletes a file with the given filename. Synchronous version. \param[in] chn CARD slot @@ -385,7 +362,6 @@ s32 CARD_CreateEntryAsync(s32 chn,card_dir *direntry,card_file *file,cardcallbac */ s32 CARD_Delete(s32 chn,const char *filename); - /*! \fn s32 CARD_DeleteAsync(s32 chn,const char *filename,cardcallback callback) \brief Deletes a file with the given filename. This function returns immediately. Asynchronous version. \param[in] chn CARD slot @@ -396,7 +372,6 @@ s32 CARD_Delete(s32 chn,const char *filename); */ s32 CARD_DeleteAsync(s32 chn,const char *filename,cardcallback callback); - /*! \fn s32 CARD_DeleteEntry(s32 chn,card_dir *dir_entry) \brief Deletes a file with the given directory entry informations. \param[in] chn CARD slot @@ -406,7 +381,6 @@ s32 CARD_DeleteAsync(s32 chn,const char *filename,cardcallback callback); */ s32 CARD_DeleteEntry(s32 chn,card_dir *dir_entry); - /*! \fn s32 CARD_DeleteEntryAsync(s32 chn,card_dir *dir_entry,cardcallback callback) \brief Deletes a file with the given directory entry informations. This function returns immediately. Asynchronous version. \param[in] chn CARD slot @@ -417,7 +391,6 @@ s32 CARD_DeleteEntry(s32 chn,card_dir *dir_entry); */ s32 CARD_DeleteEntryAsync(s32 chn,card_dir *dir_entry,cardcallback callback); - /*! \fn s32 CARD_Write(card_file *file,void *buffer,u32 len,u32 offset) \brief Writes the data to the file from the buffer to the given offset with the given length. Synchronous version \param[in] file pointer to the card_file structure which holds the fileinformations. @@ -429,7 +402,6 @@ s32 CARD_DeleteEntryAsync(s32 chn,card_dir *dir_entry,cardcallback callback); */ s32 CARD_Write(card_file *file,void *buffer,u32 len,u32 offset); - /*! \fn s32 CARD_WriteAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback callback) \brief Writes the data to the file from the buffer to the given offset with the given length. This function returns immediately. Asynchronous version \param[in] file pointer to the card_file structure which holds the fileinformations. @@ -442,7 +414,6 @@ s32 CARD_Write(card_file *file,void *buffer,u32 len,u32 offset); */ s32 CARD_WriteAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback callback); - /*! \fn s32 CARD_GetErrorCode(s32 chn) \brief Returns the result code from the last operation. \param[in] chn CARD slot @@ -451,7 +422,6 @@ s32 CARD_WriteAsync(card_file *file,void *buffer,u32 len,u32 offset,cardcallback */ s32 CARD_GetErrorCode(s32 chn); - /*! \fn s32 CARD_FindFirst(s32 chn, card_dir *dir, bool showall) \brief Start to iterate thru the memory card's directory structure and returns the first directory entry. \param[in] chn CARD slot @@ -462,7 +432,6 @@ s32 CARD_GetErrorCode(s32 chn); */ s32 CARD_FindFirst(s32 chn, card_dir *dir, bool showall); - /*! \fn s32 CARD_FindNext(card_dir *dir) \brief Returns the next directory entry from the memory cards directory structure. \param[out] dir pointer to card_dir structure to receive the result set. @@ -471,7 +440,6 @@ s32 CARD_FindFirst(s32 chn, card_dir *dir, bool showall); */ s32 CARD_FindNext(card_dir *dir); - /*! \fn s32 CARD_GetDirectory(s32 chn, card_dir *dir_entries, s32 *count, bool showall) \brief Returns the directory entries. size of entries is max. 128. \param[in] chn CARD slot @@ -483,7 +451,6 @@ s32 CARD_FindNext(card_dir *dir); */ s32 CARD_GetDirectory(s32 chn, card_dir *dir_entries, s32 *count, bool showall); - /*! \fn s32 CARD_GetSectorSize(s32 chn,u32 *sector_size) \brief Returns the next directory entry from the memory cards directory structure. \param[in] chn CARD slot. @@ -493,7 +460,6 @@ s32 CARD_GetDirectory(s32 chn, card_dir *dir_entries, s32 *count, bool showall); */ s32 CARD_GetSectorSize(s32 chn,u32 *sector_size); - /*! \fn s32 CARD_GetBlockCount(s32 chn,u32 *block_count) \brief Returns the next directory entry from the memory cards directory structure. \param[in] chn CARD slot. @@ -503,7 +469,6 @@ s32 CARD_GetSectorSize(s32 chn,u32 *sector_size); */ s32 CARD_GetBlockCount(s32 chn,u32 *block_count); - /*! \fn s32 CARD_GetStatus(s32 chn,s32 fileno,card_stat *stats) \brief Get additional file statistic informations. \param[in] chn CARD slot. @@ -514,7 +479,6 @@ s32 CARD_GetBlockCount(s32 chn,u32 *block_count); */ s32 CARD_GetStatus(s32 chn,s32 fileno,card_stat *stats); - /*! \fn s32 CARD_SetStatus(s32 chn,s32 fileno,card_stat *stats) \brief Set additional file statistic informations. Synchronous version. \param[in] chn CARD slot. @@ -525,7 +489,6 @@ s32 CARD_GetStatus(s32 chn,s32 fileno,card_stat *stats); */ s32 CARD_SetStatus(s32 chn,s32 fileno,card_stat *stats); - /*! \fn s32 CARD_SetStatusAsync(s32 chn,s32 fileno,card_stat *stats,cardcallback callback) \brief Set additional file statistic informations. This function returns immediately. Asynchronous version. \param[in] chn CARD slot. @@ -537,7 +500,6 @@ s32 CARD_SetStatus(s32 chn,s32 fileno,card_stat *stats); */ s32 CARD_SetStatusAsync(s32 chn,s32 fileno,card_stat *stats,cardcallback callback); - /*! \fn s32 CARD_GetAttributes(s32 chn,s32 fileno,u8 *attr) \brief Get additional file attributes. Synchronous version. \param[in] chn CARD slot. @@ -548,7 +510,6 @@ s32 CARD_SetStatusAsync(s32 chn,s32 fileno,card_stat *stats,cardcallback callbac */ s32 CARD_GetAttributes(s32 chn,s32 fileno,u8 *attr); - /*! \fn s32 CARD_SetAttributes(s32 chn,s32 fileno,u8 attr) \brief Set additional file attributes. Synchronous version. \param[in] chn CARD slot. @@ -559,7 +520,6 @@ s32 CARD_GetAttributes(s32 chn,s32 fileno,u8 *attr); */ s32 CARD_SetAttributes(s32 chn,s32 fileno,u8 attr); - /*! \fn s32 CARD_SetAttributesAsync(s32 chn,s32 fileno,u8 attr,cardcallback callback) \brief Set additional file attributes. This function returns immediately. Asynchronous version. \param[in] chn CARD slot. @@ -580,7 +540,6 @@ s32 CARD_Format(s32 chn); */ s32 CARD_FormatAsync(s32 chn,cardcallback callback); - /*! \fn s32 CARD_SetCompany(const char *company) \brief Set additional file attributes. This function returns immediately. Asynchronous version. \param[in] chn CARD slot. @@ -589,7 +548,6 @@ s32 CARD_FormatAsync(s32 chn,cardcallback callback); */ s32 CARD_SetCompany(const char *company); - /*! \fn s32 CARD_SetGamecode(const char *gamecode) \brief Set additional file attributes. This function returns immediately. Asynchronous version. \param[in] chn CARD slot. diff --git a/wii/libogc/include/ogc/cast.h b/wii/libogc/include/ogc/cast.h index 49016dc3b4..4cbeb36bbc 100644 --- a/wii/libogc/include/ogc/cast.h +++ b/wii/libogc/include/ogc/cast.h @@ -85,7 +85,6 @@ static inline void CAST_SetGQR7(u32 type,u32 scale) __set_gqr(GQR7,val); } - /******************************************************************/ /* */ /* cast from int to float */ diff --git a/wii/libogc/include/ogc/cond.h b/wii/libogc/include/ogc/cond.h index 1d06bfb1b4..0468beeebe 100644 --- a/wii/libogc/include/ogc/cond.h +++ b/wii/libogc/include/ogc/cond.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __COND_H__ #define __COND_H__ @@ -45,13 +44,11 @@ distribution. extern "C" { #endif - /*! \typedef u32 cond_t \brief typedef for the condition variable handle */ typedef u32 cond_t; - /*! \fn s32 LWP_CondInit(cond_t *cond) \brief Initialize condition variable \param[out] cond pointer to the cond_t handle @@ -60,7 +57,6 @@ typedef u32 cond_t; */ s32 LWP_CondInit(cond_t *cond); - /*! \fn s32 LWP_CondWait(cond_t cond,mutex_t mutex) \brief Wait on condition variable. \param[in] cond handle to the cond_t structure @@ -70,7 +66,6 @@ s32 LWP_CondInit(cond_t *cond); */ s32 LWP_CondWait(cond_t cond,mutex_t mutex); - /*! \fn s32 LWP_CondSignal(cond_t cond) \brief Signal a specific thread waiting on this condition variable to wake up. \param[in] cond handle to the cond_t structure @@ -79,7 +74,6 @@ s32 LWP_CondWait(cond_t cond,mutex_t mutex); */ s32 LWP_CondSignal(cond_t cond); - /*! \fn s32 LWP_CondBroadcast(cond_t cond) \brief Broadcast all threads waiting on this condition variable to wake up. \param[in] cond handle to the cond_t structure @@ -88,7 +82,6 @@ s32 LWP_CondSignal(cond_t cond); */ s32 LWP_CondBroadcast(cond_t cond); - /*! \fn s32 LWP_CondTimedWait(cond_t cond,mutex_t mutex,const struct timespec *abstime) \brief Timed wait on a conditionvariable. \param[in] cond handle to the cond_t structure @@ -99,7 +92,6 @@ s32 LWP_CondBroadcast(cond_t cond); */ s32 LWP_CondTimedWait(cond_t cond,mutex_t mutex,const struct timespec *abstime); - /*! \fn s32 LWP_CondDestroy(cond_t cond) \brief Destroy condition variable, release all threads and handles blocked on that condition variable. \param[in] cond handle to the cond_t structure diff --git a/wii/libogc/include/ogc/disc_io.h b/wii/libogc/include/ogc/disc_io.h index f1650a0471..a558e6bfe6 100644 --- a/wii/libogc/include/ogc/disc_io.h +++ b/wii/libogc/include/ogc/disc_io.h @@ -33,7 +33,6 @@ #include #include - #define FEATURE_MEDIUM_CANREAD 0x00000001 #define FEATURE_MEDIUM_CANWRITE 0x00000002 #define FEATURE_GAMECUBE_SLOTA 0x00000010 diff --git a/wii/libogc/include/ogc/dsp.h b/wii/libogc/include/ogc/dsp.h index 743fd186db..57fc5a86a9 100644 --- a/wii/libogc/include/ogc/dsp.h +++ b/wii/libogc/include/ogc/dsp.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __DSP_H__ #define __DSP_H__ @@ -53,7 +52,6 @@ distribution. * @} */ - /*! * \addtogroup dsp_taskflag DSP task flags * \brief DSP task queue state flag indicating the task's current queue state. Multiple states are OR'd. @@ -72,27 +70,23 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! \typedef struct _dsp_task dsptask_t \brief forward typdef to struct _dsp_task. This struture holds certain DSP task information for execution. */ typedef struct _dsp_task dsptask_t; - /*! \typedef void (*DSPTaskCallback)(dsptask_t *task) \brief function pointer typedef for the user's DSP task callbacks \param[in] task pointer to the dsp_task structure. */ typedef void (*DSPTaskCallback)(dsptask_t *task); - /*! \typedef void (*DSPCallback)(void) \brief function pointer typedef for the user's DSP interrupt callback */ typedef void (*DSPCallback)(void); - /*! \typedef struct _dsp_task dsptask_t \param state current task \ref dsp_taskstate "state" set \param prio priority of the task @@ -137,7 +131,6 @@ struct _dsp_task { struct _dsp_task *prev; }; - /*! \fn void DSP_Init() \brief Initialize DSP subsystem. @@ -145,7 +138,6 @@ struct _dsp_task { */ void DSP_Init(); - /*! \fn u32 DSP_CheckMailTo() \brief Check if mail was sent to DSP @@ -153,7 +145,6 @@ void DSP_Init(); */ u32 DSP_CheckMailTo(); - /*! \fn u32 DSP_CheckMailFrom() \brief Check for mail from DSP @@ -161,7 +152,6 @@ u32 DSP_CheckMailTo(); */ u32 DSP_CheckMailFrom(); - /*! \fn u32 DSP_ReadMailFrom() \brief Read mail from DSP @@ -169,7 +159,6 @@ u32 DSP_CheckMailFrom(); */ u32 DSP_ReadMailFrom(); - /*! \fn void DSP_AssertInt() \brief Asserts the processor interface interrupt @@ -177,7 +166,6 @@ u32 DSP_ReadMailFrom(); */ void DSP_AssertInt(); - /*! \fn void DSP_SendMailTo(u32 mail) \brief Send mail to DSP \param[in] mail value to send @@ -186,7 +174,6 @@ void DSP_AssertInt(); */ void DSP_SendMailTo(u32 mail); - /*! \fn u32 DSP_ReadCPUtoDSP() \brief Read back CPU->DSP mailbox @@ -194,7 +181,6 @@ void DSP_SendMailTo(u32 mail); */ u32 DSP_ReadCPUtoDSP(); - /*! \fn dsptask_t* DSP_AddTask(dsptask_t *task) \brief Add a DSP task to the tasklist and start executing if necessary. \param[in] task pointer to a dsptask_t structure which holds all necessary values for DSP task execution. diff --git a/wii/libogc/include/ogc/dvd.h b/wii/libogc/include/ogc/dvd.h index 5fbbc6aa68..cf5cde358b 100644 --- a/wii/libogc/include/ogc/dvd.h +++ b/wii/libogc/include/ogc/dvd.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __DVD_H__ #define __DVD_H__ @@ -69,7 +68,6 @@ distribution. * @} */ - /*! * \addtogroup dvd_resetmode DVD reset modes * @{ @@ -83,7 +81,6 @@ distribution. * @} */ - /*! * \addtogroup dvd_motorctrlmode DVD motor control modes * @{ @@ -98,12 +95,10 @@ distribution. * @} */ - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ - /*! * \typedef struct _dvddiskid dvddiskid * \brief forward typedef for struct _dvddiskid @@ -141,14 +136,12 @@ struct _dvddiskid { */ typedef struct _dvdcmdblk dvdcmdblk; - /*! * \typedef void (*dvdcbcallback)(s32 result,dvdcmdblk *block) * \brief function pointer typedef for the user's operations callback */ typedef void (*dvdcbcallback)(s32 result,dvdcmdblk *block); - /*! * \typedef struct _dvdcmdblk dvdcmdblk * @@ -168,14 +161,12 @@ struct _dvdcmdblk { void *usrdata; }; - /*! * \typedef struct _dvddrvinfo dvddrvinfo * \brief forward typedef for struct _dvddrvinfo */ typedef struct _dvddrvinfo dvddrvinfo; - /*! * \typedef struct _dvddrvinfo dvddrvinfo * @@ -194,14 +185,12 @@ struct _dvddrvinfo { u8 pad[24]; }; - /*! * \typedef struct _dvdfileinfo dvdfileinfo * \brief forward typedef for struct _dvdfileinfo */ typedef struct _dvdfileinfo dvdfileinfo; - /*! * \typedef void (*dvdcallback)(s32 result,dvdfileinfo *info) * \brief function pointer typedef for the user's DVD operation callback @@ -211,7 +200,6 @@ typedef struct _dvdfileinfo dvdfileinfo; */ typedef void (*dvdcallback)(s32 result,dvdfileinfo *info); - /*! * \typedef struct _dvdfileinfo dvdfileinfo * @@ -224,7 +212,6 @@ struct _dvdfileinfo { dvdcallback cb; }; - /*! * \fn void DVD_Init() * \brief Initializes the DVD subsystem @@ -236,7 +223,6 @@ struct _dvdfileinfo { void DVD_Init(); void DVD_Pause(); - /*! * \fn void DVD_Reset(u32 reset_mode) * \brief Performs a reset of the drive and FW respectively. @@ -247,7 +233,6 @@ void DVD_Pause(); */ void DVD_Reset(u32 reset_mode); - /*! * \fn s32 DVD_Mount() * \brief Mounts the DVD drive. @@ -259,7 +244,6 @@ void DVD_Reset(u32 reset_mode); s32 DVD_Mount(); s32 DVD_GetDriveStatus(); - /*! * \fn s32 DVD_MountAsync(dvdcmdblk *block,dvdcbcallback cb) * \brief Mounts the DVD drive. @@ -282,7 +266,6 @@ s32 DVD_GetDriveStatus(); */ s32 DVD_MountAsync(dvdcmdblk *block,dvdcbcallback cb); - /*! * \fn s32 DVD_ControlDrive(dvdcmdblk *block,u32 cmd) * \brief Controls the drive's motor and behavior. @@ -296,7 +279,6 @@ s32 DVD_MountAsync(dvdcmdblk *block,dvdcbcallback cb); */ s32 DVD_ControlDrive(dvdcmdblk *block,u32 cmd); - /*! * \fn s32 DVD_ControlDriveAsync(dvdcmdblk *block,u32 cmd,dvdcbcallback cb) * \brief Controls the drive's motor and behavior. @@ -309,7 +291,6 @@ s32 DVD_ControlDrive(dvdcmdblk *block,u32 cmd); */ s32 DVD_ControlDriveAsync(dvdcmdblk *block,u32 cmd,dvdcbcallback cb); - /*! * \fn s32 DVD_SetGCMOffset(dvdcmdblk *block,u32 offset) * \brief Sets the offset to the GCM. Used for multigame discs. @@ -323,7 +304,6 @@ s32 DVD_ControlDriveAsync(dvdcmdblk *block,u32 cmd,dvdcbcallback cb); */ s32 DVD_SetGCMOffset(dvdcmdblk *block,s64 offset); - /*! * \fn s32 DVD_SetGCMOffsetAsync(dvdcmdblk *block,u32 offset,dvdcbcallback cb) * \brief Sets the offset to the GCM. Used for multigame discs. diff --git a/wii/libogc/include/ogc/exi.h b/wii/libogc/include/ogc/exi.h index 57b484c44d..48e832ea50 100644 --- a/wii/libogc/include/ogc/exi.h +++ b/wii/libogc/include/ogc/exi.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __EXI_H__ #define __EXI_H__ @@ -37,7 +36,6 @@ distribution. */ - #include "gctypes.h" /*! @@ -53,7 +51,6 @@ distribution. * @} */ - /*! * \addtogroup exi_channels EXI channels * @{ @@ -68,7 +65,6 @@ distribution. * @} */ - /*! * \addtogroup exi_devices EXI devices * @{ @@ -83,7 +79,6 @@ distribution. * @} */ - /*! * \addtogroup exi_speed EXI device frequencies * @{ @@ -100,7 +95,6 @@ distribution. * @} */ - /*! * \addtogroup exi_flags EXI device operation flags * @{ @@ -116,7 +110,6 @@ distribution. * @} */ - /*! * \addtogroup exi_mcident EXI memory card identifier * @{ @@ -133,7 +126,6 @@ distribution. * @} */ - #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ @@ -145,7 +137,6 @@ distribution. */ typedef s32 (*EXICallback)(s32 chn,s32 dev); - /*! \fn s32 EXI_ProbeEx(s32 nChn) \brief Performs an extended probe of the EXI channel \param[in] nChn EXI channel to probe @@ -154,7 +145,6 @@ typedef s32 (*EXICallback)(s32 chn,s32 dev); */ s32 EXI_ProbeEx(s32 nChn); - /*! \fn s32 EXI_Probe(s32 nChn) \brief Probes the EXI channel \param[in] nChn EXI channel to probe @@ -163,7 +153,6 @@ s32 EXI_ProbeEx(s32 nChn); */ s32 EXI_Probe(s32 nChn); - /*! \fn s32 EXI_Lock(s32 nChn,s32 nDev,EXICallback unlockCB) \brief Try to lock the desired EXI channel on the given device. \param[in] nChn EXI channel to lock @@ -174,7 +163,6 @@ s32 EXI_Probe(s32 nChn); */ s32 EXI_Lock(s32 nChn,s32 nDev,EXICallback unlockCB); - /*! \fn s32 EXI_Unlock(s32 nChn) \brief Unlock the desired EXI channel. \param[in] nChn EXI channel to unlock @@ -183,7 +171,6 @@ s32 EXI_Lock(s32 nChn,s32 nDev,EXICallback unlockCB); */ s32 EXI_Unlock(s32 nChn); - /*! \fn s32 EXI_Select(s32 nChn,s32 nDev,s32 nFrq) \brief Selects the spedified EXI channel on the given device with the given frequency \param[in] nChn EXI channel to select @@ -194,7 +181,6 @@ s32 EXI_Unlock(s32 nChn); */ s32 EXI_Select(s32 nChn,s32 nDev,s32 nFrq); - /*! \fn s32 EXI_SelectSD(s32 nChn,s32 nDev,s32 nFrq) \brief Performs a special select, for SD cards or adapters respectively, on the given device with the given frequence \param[in] nChn EXI channel to select @@ -205,7 +191,6 @@ s32 EXI_Select(s32 nChn,s32 nDev,s32 nFrq); */ s32 EXI_SelectSD(s32 nChn,s32 nDev,s32 nFrq); - /*! \fn s32 EXI_Deselect(s32 nChn) \brief Deselects the EXI channel. \param[in] nChn EXI channel to deselect @@ -214,7 +199,6 @@ s32 EXI_SelectSD(s32 nChn,s32 nDev,s32 nFrq); */ s32 EXI_Deselect(s32 nChn); - /*! \fn s32 EXI_Sync(s32 nChn) \brief Synchronize or finish respectively the last EXI transfer. \param[in] nChn EXI channel to select @@ -223,7 +207,6 @@ s32 EXI_Deselect(s32 nChn); */ s32 EXI_Sync(s32 nChn); - /*! \fn s32 EXI_Imm(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb) \brief Initializes an immediate mode EXI transfer. \param[in] nChn EXI channel to select @@ -236,7 +219,6 @@ s32 EXI_Sync(s32 nChn); */ s32 EXI_Imm(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb); - /*! \fn s32 EXI_ImmEx(s32 nChn,void *pData,u32 nLen,u32 nMode) \brief Initializes an extended immediate mode EXI transfer. \param[in] nChn EXI channel to select @@ -248,7 +230,6 @@ s32 EXI_Imm(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb); */ s32 EXI_ImmEx(s32 nChn,void *pData,u32 nLen,u32 nMode); - /*! \fn s32 EXI_Dma(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb) \brief Initializes a DMA mode EXI transfer. \param[in] nChn EXI channel to select @@ -261,7 +242,6 @@ s32 EXI_ImmEx(s32 nChn,void *pData,u32 nLen,u32 nMode); */ s32 EXI_Dma(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb); - /*! \fn s32 EXI_GetState(s32 nChn) \brief Get the EXI state \param[in] nChn EXI channel to select @@ -270,7 +250,6 @@ s32 EXI_Dma(s32 nChn,void *pData,u32 nLen,u32 nMode,EXICallback tc_cb); */ s32 EXI_GetState(s32 nChn); - /*! \fn s32 EXI_GetID(s32 nChn,s32 nDev,u32 *nId) \brief Get the ID of the connected EXI device on the given channel \param[in] nChn EXI channel to select @@ -281,7 +260,6 @@ s32 EXI_GetState(s32 nChn); */ s32 EXI_GetID(s32 nChn,s32 nDev,u32 *nId); - /*! \fn s32 EXI_Attach(s32 nChn,EXICallback ext_cb) \brief Attach the device on the given channel \param[in] nChn EXI channel to select @@ -291,7 +269,6 @@ s32 EXI_GetID(s32 nChn,s32 nDev,u32 *nId); */ s32 EXI_Attach(s32 nChn,EXICallback ext_cb); - /*! \fn s32 EXI_Detach(s32 nChn) \brief Detach the device on the given channel \param[in] nChn EXI channel to select @@ -300,7 +277,6 @@ s32 EXI_Attach(s32 nChn,EXICallback ext_cb); */ s32 EXI_Detach(s32 nChn); - /*! \fn void EXI_ProbeReset() \brief Resets certain internal flags and counters and performs a probe on all 3 channels. @@ -308,7 +284,6 @@ s32 EXI_Detach(s32 nChn); */ void EXI_ProbeReset(); - /*! \fn EXICallback EXI_RegisterEXICallback(s32 nChn,EXICallback exi_cb) \brief Register a callback function in the EXI driver for the EXI interrupt. \param[in] nChn EXI channel to select diff --git a/wii/libogc/include/ogc/gu.h b/wii/libogc/include/ogc/gu.h index 324f9d5232..10c3c4eeab 100644 --- a/wii/libogc/include/ogc/gu.h +++ b/wii/libogc/include/ogc/gu.h @@ -210,7 +210,6 @@ void guPerspective(Mtx44 mt,f32 fovy,f32 aspect,f32 n,f32 f); */ void guOrtho(Mtx44 mt,f32 t,f32 b,f32 l,f32 r,f32 n,f32 f); - /*! * \fn void guLightPerspective(Mtx mt,f32 fovY,f32 aspect,f32 scaleS,f32 scaleT,f32 transS,f32 transT) * \brief Sets a 3x4 perspective projection matrix from field of view and aspect ratio parameters, two scale values, and two @@ -302,7 +301,6 @@ void guLightOrtho(Mtx mt,f32 t,f32 b,f32 l,f32 r,f32 scaleS,f32 scaleT,f32 trans */ void guLightFrustum(Mtx mt,f32 t,f32 b,f32 l,f32 r,f32 n,f32 scaleS,f32 scaleT,f32 transS,f32 transT); - /*! * \fn void guLookAt(Mtx mt,guVector *camPos,guVector *camUp,guVector *target) * \brief Sets a world-space to camera-space transformation matrix. @@ -324,7 +322,6 @@ void guLightFrustum(Mtx mt,f32 t,f32 b,f32 l,f32 r,f32 n,f32 scaleS,f32 scaleT,f */ void guLookAt(Mtx mt,guVector *camPos,guVector *camUp,guVector *target); - /*! * \fn void guVecHalfAngle(guVector *a,guVector *b,guVector *half) * \brief Computes a vector that lies halfway between \a a and \a b. diff --git a/wii/libogc/include/ogc/gx.h b/wii/libogc/include/ogc/gx.h index 50462e84f4..22184190c7 100644 --- a/wii/libogc/include/ogc/gx.h +++ b/wii/libogc/include/ogc/gx.h @@ -75,7 +75,6 @@ /*! @} */ - /*! \addtogroup vtxattrin Vertex data input type * @{ */ @@ -86,7 +85,6 @@ /*! @} */ - /*! \addtogroup compsize Number of components in an attribute * @{ */ @@ -358,7 +356,6 @@ /*! @} */ - /*! \addtogroup texgentyp Texture coordinate generation type * @{ */ @@ -501,7 +498,6 @@ /*! @} */ - /*! \addtogroup tevcolorarg TEV color combiner input * @{ */ @@ -525,7 +521,6 @@ /*! @} */ - /*! \addtogroup tevalphaarg TEV alpha combiner input * @{ */ @@ -541,7 +536,6 @@ /*! @} */ - /*! \addtogroup tevstage TEV stage * \details The GameCube's Graphics Processor (GP) can use up to 16 stages to compute a texel for a particular surface. * By default, each texture will use two stages, but it can be configured through various functions calls. @@ -570,7 +564,6 @@ /*! @} */ - /*! \addtogroup tevop TEV combiner operator * @{ */ @@ -590,7 +583,6 @@ /*! @} */ - /*! \addtogroup tevbias TEV bias value * @{ */ @@ -602,7 +594,6 @@ /*! @} */ - /*! \addtogroup tevclampmode TEV clamping mode * \note These modes are used for a function which is not implementable on production (i.e. retail) GameCube hardware. * @{ @@ -616,7 +607,6 @@ /*! @} */ - /*! \addtogroup tevscale TEV scale value * @{ */ @@ -629,7 +619,6 @@ /*! @} */ - /*! \addtogroup tevcoloutreg TEV color/output register * @{ */ @@ -642,7 +631,6 @@ /*! @} */ - /*! \addtogroup cullmode Backface culling mode * @{ */ @@ -757,7 +745,6 @@ #define GX_TEV_KASEL_K3_A 0x1F /*!< K3[A] register */ /*! @} */ - /*! \addtogroup tevswapsel TEV color swap table entry * @{ */ @@ -770,7 +757,6 @@ /*! @} */ - /* tev color chan */ #define GX_CH_RED 0 #define GX_CH_GREEN 1 @@ -902,7 +888,6 @@ #define GX_FOG_REVEXP2 GX_FOG_PERSP_REVEXP2 /*! @} */ - /* pixel format */ #define GX_PF_RGB8_Z24 0 #define GX_PF_RGBA6_Z24 1 @@ -932,7 +917,6 @@ /*! @} */ - /*! \addtogroup gammamode Gamma values * @{ */ @@ -943,7 +927,6 @@ /*! @} */ - /*! \addtogroup copymode EFB copy mode * \brief Controls whether all lines, only even lines, or only odd lines are copied from the EFB. * @{ @@ -2625,7 +2608,6 @@ void GX_SetTevAlphaIn(u8 tevstage,u8 a,u8 b,u8 c,u8 d); */ void GX_SetTevColorOp(u8 tevstage,u8 tevop,u8 tevbias,u8 tevscale,u8 clamp,u8 tevregid); - /*! * \fn void GX_SetTevAlphaOp(u8 tevstage,u8 tevop,u8 tevbias,u8 tevscale,u8 clamp,u8 tevregid) * \brief Sets the \a tevop, \a tevbias, \a tevscale and \a clamp-mode operation for the alpha combiner diff --git a/wii/libogc/include/ogc/gx_struct.h b/wii/libogc/include/ogc/gx_struct.h index e90f519b98..4e36799c82 100644 --- a/wii/libogc/include/ogc/gx_struct.h +++ b/wii/libogc/include/ogc/gx_struct.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __GX_STRUCT_H__ #define __GX_STRUCT_H__ @@ -42,7 +41,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! \typedef struct _gx_rmodeobj GXRModeObj \brief structure to hold the selected video and render settings diff --git a/wii/libogc/include/ogc/irq.h b/wii/libogc/include/ogc/irq.h index 2dae7bdc90..64e990cc51 100644 --- a/wii/libogc/include/ogc/irq.h +++ b/wii/libogc/include/ogc/irq.h @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #ifndef __IRQ_H__ #define __IRQ_H__ @@ -125,7 +123,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! \typedef void (*raw_irq_handler_t)(u32 irq,void *ctx) \brief function pointer typedef for the interrupt handler callback \param[in] irq interrupt number of triggered interrupt. @@ -133,7 +130,6 @@ distribution. */ typedef void (*raw_irq_handler_t)(u32 irq,void *ctx); - /*! \fn raw_irq_handler_t IRQ_Request(u32 nIrq,raw_irq_handler_t pHndl,void *pCtx) \brief Register an interrupt handler. \param[in] nIrq interrupt number to which to register the handler @@ -144,7 +140,6 @@ typedef void (*raw_irq_handler_t)(u32 irq,void *ctx); */ raw_irq_handler_t IRQ_Request(u32 nIrq,raw_irq_handler_t pHndl,void *pCtx); - /*! \fn raw_irq_handler_t IRQ_Free(u32 nIrq) \brief Free an interrupt handler. \param[in] nIrq interrupt number for which to free the handler @@ -153,7 +148,6 @@ raw_irq_handler_t IRQ_Request(u32 nIrq,raw_irq_handler_t pHndl,void *pCtx); */ raw_irq_handler_t IRQ_Free(u32 nIrq); - /*! \fn raw_irq_handler_t IRQ_GetHandler(u32 nIrq) \brief Get the handler from interrupt number \param[in] nIrq interrupt number for which to retrieve the handler @@ -162,7 +156,6 @@ raw_irq_handler_t IRQ_Free(u32 nIrq); */ raw_irq_handler_t IRQ_GetHandler(u32 nIrq); - /*! \fn u32 IRQ_Disable() \brief Disable the complete IRQ subsystem. No interrupts will be served. Multithreading kernel fully disabled. @@ -170,7 +163,6 @@ raw_irq_handler_t IRQ_GetHandler(u32 nIrq); */ u32 IRQ_Disable(void); - /*! \fn u32 IRQ_Restore(u32 level) \brief Restore the IRQ subsystem with the given level. This is function should be used together with IRQ_Disable() \param[in] level IRQ level to restore to. diff --git a/wii/libogc/include/ogc/lwp.h b/wii/libogc/include/ogc/lwp.h index 1e3c8cc398..6a1dcab2b2 100644 --- a/wii/libogc/include/ogc/lwp.h +++ b/wii/libogc/include/ogc/lwp.h @@ -25,11 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - - -------------------------------------------------------------*/ - #ifndef __LWP_H__ #define __LWP_H__ @@ -55,13 +52,11 @@ distribution. extern "C" { #endif - /*! \typedef u32 lwp_t \brief typedef for the thread context handle */ typedef u32 lwp_t; - /*! \typedef u32 lwpq_t \brief typedef for the thread queue's context handle */ @@ -80,7 +75,6 @@ typedef u32 lwpq_t; */ s32 LWP_CreateThread(lwp_t *thethread,void* (*entry)(void *),void *arg,void *stackbase,u32 stack_size,u8 prio); - /*! \fn s32 LWP_SuspendThread(lwp_t thethread) \brief Suspend the given thread. \param[in] thethread handle to the thread context which should be suspended. @@ -89,7 +83,6 @@ s32 LWP_CreateThread(lwp_t *thethread,void* (*entry)(void *),void *arg,void *sta */ s32 LWP_SuspendThread(lwp_t thethread); - /*! \fn s32 LWP_ResumeThread(lwp_t thethread) \brief Resume the given thread. \param[in] thethread handle to the thread context which should be resumed. @@ -98,7 +91,6 @@ s32 LWP_SuspendThread(lwp_t thethread); */ s32 LWP_ResumeThread(lwp_t thethread); - /*! \fn BOOL LWP_ThreadIsSuspended(lwp_t thethread) \brief Test whether the given thread is suspended or not \param[in] thethread handle to the thread context which should be tested. @@ -107,7 +99,6 @@ s32 LWP_ResumeThread(lwp_t thethread); */ BOOL LWP_ThreadIsSuspended(lwp_t thethread); - /*! \fn lwp_t LWP_GetSelf() \brief Return the handle to the current thread. @@ -115,7 +106,6 @@ BOOL LWP_ThreadIsSuspended(lwp_t thethread); */ lwp_t LWP_GetSelf(); - /*! \fn void LWP_SetThreadPriority(lwp_t thethread,u32 prio) \brief Set the priority of the given thread. \param[in] thethread handle to the thread context whos priority should be changed. If NULL, the current thread will be taken. @@ -125,7 +115,6 @@ lwp_t LWP_GetSelf(); */ void LWP_SetThreadPriority(lwp_t thethread,u32 prio); - /*! \fn void LWP_YieldThread() \brief Yield the current thread to another one with higher priority or if not running at the same priority which state is runnable. @@ -133,7 +122,6 @@ void LWP_SetThreadPriority(lwp_t thethread,u32 prio); */ void LWP_YieldThread(); - /*! \fn void LWP_Reschedule(u32 prio) \brief Reschedule all threads running at the given priority \param[in] prio priority level to reschedule @@ -142,7 +130,6 @@ void LWP_YieldThread(); */ void LWP_Reschedule(u32 prio); - /*! \fn s32 LWP_JoinThread(lwp_t thethread,void **value_ptr) \brief Join the given thread. \param[in] thethread handle to the thread's context which should be joined to wait on termination. @@ -152,7 +139,6 @@ void LWP_Reschedule(u32 prio); */ s32 LWP_JoinThread(lwp_t thethread,void **value_ptr); - /*! \fn void LWP_InitQueue(lwpq_t *thequeue) \brief Initialize the thread synchronization queue \param[in] thequeue pointer to a lwpq_t handle. @@ -161,7 +147,6 @@ s32 LWP_JoinThread(lwp_t thethread,void **value_ptr); */ s32 LWP_InitQueue(lwpq_t *thequeue); - /*! \fn void LWP_CloseQueue(lwpq_t thequeue) \brief Close the thread synchronization queue and releas the handle \param[in] thequeue handle to the thread's synchronization queue @@ -170,7 +155,6 @@ s32 LWP_InitQueue(lwpq_t *thequeue); */ void LWP_CloseQueue(lwpq_t thequeue); - /*! \fn s32 LWP_ThreadSleep(lwpq_t thequeue) \brief Pushes the current thread onto the given thread synchronization queue and sets the thread state to blocked. \param[in] thequeue handle to the thread's synchronization queue to push the thread on @@ -179,7 +163,6 @@ void LWP_CloseQueue(lwpq_t thequeue); */ s32 LWP_ThreadSleep(lwpq_t thequeue); - /*! \fn void LWP_ThreadSignal(lwpq_t thequeue) \brief Signals one thread to be revmoved from the thread synchronization queue and sets it back to running state. \param[in] thequeue handle to the thread's synchronization queue to pop the blocked thread off @@ -188,7 +171,6 @@ s32 LWP_ThreadSleep(lwpq_t thequeue); */ void LWP_ThreadSignal(lwpq_t thequeue); - /*! \fn void LWP_ThreadBroadcast(lwpq_t thequeue) \brief Removes all blocked threads from the thread synchronization queue and sets them back to running state. \param[in] thequeue handle to the thread's synchronization queue to pop the blocked threads off diff --git a/wii/libogc/include/ogc/lwp_config.h b/wii/libogc/include/ogc/lwp_config.h index beda421e54..ca938f3185 100644 --- a/wii/libogc/include/ogc/lwp_config.h +++ b/wii/libogc/include/ogc/lwp_config.h @@ -1,7 +1,6 @@ #ifndef __LWP_CONFIG_H__ #define __LWP_CONFIG_H__ - #define LWP_MAX_MQUEUES 64 #define LWP_MAX_MUTEXES 64 diff --git a/wii/libogc/include/ogc/lwp_watchdog.h b/wii/libogc/include/ogc/lwp_watchdog.h index ed49a06fb9..456aeadbdb 100644 --- a/wii/libogc/include/ogc/lwp_watchdog.h +++ b/wii/libogc/include/ogc/lwp_watchdog.h @@ -38,7 +38,6 @@ #define tick_microsecs(ticks) ((((u64)(ticks)*8)%(u64)(TB_TIMER_CLOCK/125))) #define tick_nanosecs(ticks) ((((u64)(ticks)*8000)%(u64)(TB_TIMER_CLOCK/125))) - #define secs_to_ticks(sec) ((u64)(sec)*(TB_TIMER_CLOCK*1000)) #define millisecs_to_ticks(msec) ((u64)(msec)*(TB_TIMER_CLOCK)) #define microsecs_to_ticks(usec) (((u64)(usec)*(TB_TIMER_CLOCK/125))/8) diff --git a/wii/libogc/include/ogc/machine/asm.h b/wii/libogc/include/ogc/machine/asm.h index ed28f7895b..8fe90ff114 100644 --- a/wii/libogc/include/ogc/machine/asm.h +++ b/wii/libogc/include/ogc/machine/asm.h @@ -13,7 +13,6 @@ #define cr6 6 #define cr7 7 - /* General Purpose Registers (GPRs) */ #define r0 0 @@ -51,7 +50,6 @@ #define r30 30 #define r31 31 - /* Floating Point Registers (FPRs) */ #define fr0 0 @@ -135,7 +133,6 @@ #define MMCR0 952 #define MMCR1 956 - #define LINK_REGISTER_CALLEE_UPDATE_ROOM 4 #define EXCEPTION_NUMBER 8 #define SRR0_OFFSET 12 diff --git a/wii/libogc/include/ogc/machine/spinlock.h b/wii/libogc/include/ogc/machine/spinlock.h index 3081ee145b..13251dde37 100644 --- a/wii/libogc/include/ogc/machine/spinlock.h +++ b/wii/libogc/include/ogc/machine/spinlock.h @@ -187,5 +187,4 @@ static __inline__ void write_unlock(rwlock_t *rw) rw->lock = 0; } - #endif diff --git a/wii/libogc/include/ogc/message.h b/wii/libogc/include/ogc/message.h index 1105446942..977d8cf330 100644 --- a/wii/libogc/include/ogc/message.h +++ b/wii/libogc/include/ogc/message.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __MESSAGE_H__ #define __MESSAGE_H__ @@ -46,25 +45,20 @@ distribution. #define MQ_MSG_BLOCK 0 #define MQ_MSG_NOBLOCK 1 - #ifdef __cplusplus extern "C" { #endif - /*! \typedef u32 mqbox_t \brief typedef for the message queue handle */ typedef u32 mqbox_t; - /*! \typedef void* mqmsg_t \brief typedef for the message pointer */ typedef void* mqmsg_t; - - /*! \fn u32 MQ_Init(mqbox_t *mqbox,u32 count) \brief Initializes a message queue \param[out] mqbox pointer to the mqbox_t handle. @@ -74,7 +68,6 @@ typedef void* mqmsg_t; */ s32 MQ_Init(mqbox_t *mqbox,u32 count); - /*! \fn void MQ_Close(mqbox_t mqbox) \brief Closes the message queue and releases all memory. \param[in] mqbox handle to the mqbox_t structure. @@ -83,7 +76,6 @@ s32 MQ_Init(mqbox_t *mqbox,u32 count); */ void MQ_Close(mqbox_t mqbox); - /*! \fn BOOL MQ_Send(mqbox_t mqbox,mqmsg_t msg,u32 flags) \brief Sends a message to the given message queue. \param[in] mqbox mqbox_t handle to the message queue @@ -94,7 +86,6 @@ void MQ_Close(mqbox_t mqbox); */ BOOL MQ_Send(mqbox_t mqbox,mqmsg_t msg,u32 flags); - /*! \fn BOOL MQ_Jam(mqbox_t mqbox,mqmsg_t msg,u32 flags) \brief Sends a message to the given message queue and jams it in front of the queue. \param[in] mqbox mqbox_t handle to the message queue @@ -105,7 +96,6 @@ BOOL MQ_Send(mqbox_t mqbox,mqmsg_t msg,u32 flags); */ BOOL MQ_Jam(mqbox_t mqbox,mqmsg_t msg,u32 flags); - /*! \fn BOOL MQ_Receive(mqbox_t mqbox,mqmsg_t *msg,u32 flags) \brief Sends a message to the given message queue. \param[in] mqbox mqbox_t handle to the message queue diff --git a/wii/libogc/include/ogc/mutex.h b/wii/libogc/include/ogc/mutex.h index e6dd1981b3..288fcd5c69 100644 --- a/wii/libogc/include/ogc/mutex.h +++ b/wii/libogc/include/ogc/mutex.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __MUTEX_H__ #define __MUTEX_H__ @@ -44,13 +43,11 @@ distribution. extern "C" { #endif - /*! \typedef u32 mutex_t \brief typedef for the mutex handle */ typedef u32 mutex_t; - /*! \fn s32 LWP_MutexInit(mutex_t *mutex,bool use_recursive) \brief Initializes a mutex lock. \param[out] mutex pointer to a mutex_t handle. @@ -60,7 +57,6 @@ typedef u32 mutex_t; */ s32 LWP_MutexInit(mutex_t *mutex,bool use_recursive); - /*! \fn s32 LWP_MutexDestroy(mutex_t mutex) \brief Close mutex lock, release all threads and handles locked on this mutex. \param[in] mutex handle to the mutex_t structure. @@ -69,7 +65,6 @@ s32 LWP_MutexInit(mutex_t *mutex,bool use_recursive); */ s32 LWP_MutexDestroy(mutex_t mutex); - /*! \fn s32 LWP_MutexLock(mutex_t mutex) \brief Enter the mutex lock. \param[in] mutex handle to the mutext_t structure. @@ -78,7 +73,6 @@ s32 LWP_MutexDestroy(mutex_t mutex); */ s32 LWP_MutexLock(mutex_t mutex); - /*! \fn s32 LWP_MutexTryLock(mutex_t mutex) \brief Try to enter the mutex lock. \param[in] mutex handle to the mutex_t structure. @@ -87,7 +81,6 @@ s32 LWP_MutexLock(mutex_t mutex); */ s32 LWP_MutexTryLock(mutex_t mutex); - /*! \fn s32 LWP_MutexUnlock(mutex_t mutex) \brief Release the mutex lock and let other threads process further on this mutex. \param[in] mutex handle to the mutex_t structure. diff --git a/wii/libogc/include/ogc/pad.h b/wii/libogc/include/ogc/pad.h index 3488c5c5b4..498dc39ff4 100644 --- a/wii/libogc/include/ogc/pad.h +++ b/wii/libogc/include/ogc/pad.h @@ -85,7 +85,6 @@ s8 PAD_StickY(int pad); u8 PAD_TriggerL(int pad); u8 PAD_TriggerR(int pad); - sampling_callback PAD_SetSamplingCallback(sampling_callback cb); /*+----------------------------------------------------------------------------------------------+*/ diff --git a/wii/libogc/include/ogc/semaphore.h b/wii/libogc/include/ogc/semaphore.h index bae6d4c514..854be37dde 100644 --- a/wii/libogc/include/ogc/semaphore.h +++ b/wii/libogc/include/ogc/semaphore.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __SEMAPHORE_H__ #define __SEMAPHORE_H__ @@ -36,7 +35,6 @@ distribution. */ - #include #define LWP_SEM_NULL 0xffffffff @@ -45,13 +43,11 @@ distribution. extern "C" { #endif - /*! \typedef u32 sem_t \brief typedef for the semaphore handle */ typedef u32 sem_t; - /*! \fn s32 LWP_SemInit(sem_t *sem,u32 start,u32 max) \brief Initializes a semaphore. \param[out] sem pointer to a sem_t handle. @@ -62,7 +58,6 @@ typedef u32 sem_t; */ s32 LWP_SemInit(sem_t *sem,u32 start,u32 max); - /*! \fn s32 LWP_SemDestroy(sem_t sem) \brief Close and destroy a semaphore, release all threads and handles locked on this semaphore. \param[in] sem handle to the sem_t structure. @@ -71,7 +66,6 @@ s32 LWP_SemInit(sem_t *sem,u32 start,u32 max); */ s32 LWP_SemDestroy(sem_t sem); - /*! \fn s32 LWP_SemWait(sem_t sem) \brief Count down semaphore counter and enter lock if counter <=0 \param[in] sem handle to the sem_t structure. @@ -80,7 +74,6 @@ s32 LWP_SemDestroy(sem_t sem); */ s32 LWP_SemWait(sem_t sem); - /*! \fn s32 LWP_SemPost(sem_t sem) \brief Count up semaphore counter and release lock if counter >0 \param[in] sem handle to the sem_t structure. diff --git a/wii/libogc/include/ogc/system.h b/wii/libogc/include/ogc/system.h index b82e251438..0beb00023b 100644 --- a/wii/libogc/include/ogc/system.h +++ b/wii/libogc/include/ogc/system.h @@ -25,14 +25,11 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #ifndef __SYSTEM_H__ #define __SYSTEM_H__ - /*! \file system.h \brief OS functions and initialization @@ -67,7 +64,6 @@ distribution. *@} */ - /*! * \addtogroup sys_mprotchans OS memory protection channels * @{ @@ -83,7 +79,6 @@ distribution. *@} */ - /*! * \addtogroup sys_mprotmodes OS memory protection modes * @{ @@ -101,8 +96,6 @@ distribution. #define SYS_FONTSIZE_ANSI (288 + 131072) #define SYS_FONTSIZE_SJIS (3840 + 1179648) - - /*! * \addtogroup sys_mcastmacros OS memory casting macros * @{ @@ -130,14 +123,12 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! * \typedef u32 syswd_t * \brief handle typedef for the alarm context */ typedef u32 syswd_t; - /*! * \typedef struct _syssram syssram * \brief holds the stored configuration value from the system SRAM area @@ -165,7 +156,6 @@ struct _syssram { u8 flags; } ATTRIBUTE_PACKED; - /*! * \typedef struct _syssramex syssramex * \brief holds the stored configuration value from the extended SRAM area @@ -237,7 +227,6 @@ struct _sys_resetinfo { */ void SYS_Init(); - /*! * \fn void* SYS_AllocateFramebuffer(GXRModeObj *rmode) * \brief Allocate cacheline aligned memory for the external framebuffer based on the rendermode object. @@ -247,13 +236,11 @@ void SYS_Init(); */ void* SYS_AllocateFramebuffer(GXRModeObj *rmode); - void SYS_ProtectRange(u32 chan,void *addr,u32 bytes,u32 cntrl); void SYS_StartPMC(u32 mcr0val,u32 mcr1val); void SYS_DumpPMC(); void SYS_StopPMC(); - /*! \fn s32 SYS_CreateAlarm(syswd_t *thealarm) \brief Create/initialize sysalarm structure \param[in] thealarm pointer to the handle to store the created alarm context identifier @@ -262,7 +249,6 @@ void SYS_StopPMC(); */ s32 SYS_CreateAlarm(syswd_t *thealarm); - /*! \fn s32 SYS_SetAlarm(syswd_t thealarm,const struct timespec *tp,alarmcallback cb) \brief Set the alarm parameters for a one-shot alarm, add to the list of alarms and start. \param[in] thealarm identifier to the alarm context to be initialize for a one-shot alarm @@ -273,7 +259,6 @@ s32 SYS_CreateAlarm(syswd_t *thealarm); */ s32 SYS_SetAlarm(syswd_t thealarm,const struct timespec *tp,alarmcallback cb,void *cbarg); - /*! \fn s32 SYS_SetPeriodicAlarm(syswd_t thealarm,const struct timespec *tp_start,const struct timespec *tp_period,alarmcallback cb) \brief Set the alarm parameters for a periodioc alarm, add to the list of alarms and start. The alarm and interval persists as long as SYS_CancelAlarm() isn't called. \param[in] thealarm identifier to the alarm context to be initialized for a periodic alarm @@ -285,7 +270,6 @@ s32 SYS_SetAlarm(syswd_t thealarm,const struct timespec *tp,alarmcallback cb,voi */ s32 SYS_SetPeriodicAlarm(syswd_t thealarm,const struct timespec *tp_start,const struct timespec *tp_period,alarmcallback cb,void *cbarg); - /*! \fn s32 SYS_RemoveAlarm(syswd_t thealarm) \brief Remove the given alarm context from the list of contexts and destroy it \param[in] thealarm identifier to the alarm context to be removed and destroyed @@ -294,7 +278,6 @@ s32 SYS_SetPeriodicAlarm(syswd_t thealarm,const struct timespec *tp_start,const */ s32 SYS_RemoveAlarm(syswd_t thealarm); - /*! \fn s32 SYS_CancelAlarm(syswd_t thealarm) \brief Cancel the alarm, but do not remove from the list of contexts. \param[in] thealarm identifier to the alram context to be canceled @@ -303,7 +286,6 @@ s32 SYS_RemoveAlarm(syswd_t thealarm); */ s32 SYS_CancelAlarm(syswd_t thealarm); - void SYS_SetWirelessID(u32 chan,u32 id); u32 SYS_GetWirelessID(u32 chan); u32 SYS_GetFontEncoding(); diff --git a/wii/libogc/include/ogc/texconv.h b/wii/libogc/include/ogc/texconv.h index 3a07ee0ca7..1c20fe1926 100644 --- a/wii/libogc/include/ogc/texconv.h +++ b/wii/libogc/include/ogc/texconv.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __TEXCONV_H__ #define __TEXTCONV_H__ diff --git a/wii/libogc/include/ogc/video.h b/wii/libogc/include/ogc/video.h index 866bd910cf..b8347e87fb 100644 --- a/wii/libogc/include/ogc/video.h +++ b/wii/libogc/include/ogc/video.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __VIDEO_H__ #define __VIDEO_H__ @@ -45,7 +44,6 @@ distribution. extern "C" { #endif /* __cplusplus */ - /*! * \typedef void (*VIRetraceCallback)(u32 retraceCnt) * \brief function pointer typedef for the user's retrace callback @@ -58,7 +56,6 @@ typedef void (*VIPositionCallback)(u32 posX,u32 posY); void* VIDEO_GetNextFramebuffer(); void* VIDEO_GetCurrentFramebuffer(); - /*! * \fn void VIDEO_Init() * \brief Initializes the VIDEO subsystem. This call should be done in the early stages of your main() @@ -67,7 +64,6 @@ void* VIDEO_GetCurrentFramebuffer(); */ void VIDEO_Init(); - /*! * \fn void VIDEO_Flush() * \brief Flush the shadow registers to the drivers video registers. @@ -76,7 +72,6 @@ void VIDEO_Init(); */ void VIDEO_Flush(); - /*! * \fn void VIDEO_SetBlack(bool black) * \brief Blackout the VIDEO interface. @@ -87,7 +82,6 @@ void VIDEO_Flush(); */ void VIDEO_SetBlack(bool black); - /*! * \fn u32 VIDEO_GetNextField() * \brief Get the next field in DS mode. @@ -96,7 +90,6 @@ void VIDEO_SetBlack(bool black); */ u32 VIDEO_GetNextField(); - /*! * \fn u32 VIDEO_GetCurrentLine() * \brief Get current video line @@ -105,7 +98,6 @@ u32 VIDEO_GetNextField(); */ u32 VIDEO_GetCurrentLine(); - /*! * \fn u32 VIDEO_GetCurrentTvMode() * \brief Get current configured TV mode @@ -114,7 +106,6 @@ u32 VIDEO_GetCurrentLine(); */ u32 VIDEO_GetCurrentTvMode(); - /*! * \fn void VIDEO_Configure(GXRModeObj *rmode) * \brief Configure the VI with the given render mode object @@ -139,7 +130,6 @@ u32 VIDEO_GetFrameBufferSize(GXRModeObj *rmode); */ void VIDEO_ClearFrameBuffer(GXRModeObj *rmode,void *fb,u32 color); - /*! * \fn void VIDEO_WaitVSync(void) * \brief Wait on the next vertical retrace @@ -148,7 +138,6 @@ void VIDEO_ClearFrameBuffer(GXRModeObj *rmode,void *fb,u32 color); */ void VIDEO_WaitVSync(void); - /*! * \fn void VIDEO_SetNextFramebuffer(void *fb) * \brief Set the framebuffer for the next VI register update. @@ -157,7 +146,6 @@ void VIDEO_WaitVSync(void); */ void VIDEO_SetNextFramebuffer(void *fb); - /*! * \fn void VIDEO_SetNextRightFramebuffer(void *fb) * \brief Set the right framebuffer for the next VI register update. This is used for 3D Gloves for instance. @@ -166,7 +154,6 @@ void VIDEO_SetNextFramebuffer(void *fb); */ void VIDEO_SetNextRightFramebuffer(void *fb); - /*! * \fn VIRetraceCallback VIDEO_SetPreRetraceCallback(VIRetraceCallback callback) * \brief Set the Pre-Retrace callback function. This function is called within the video interrupt handler before the VI registers will be updated. @@ -177,7 +164,6 @@ void VIDEO_SetNextRightFramebuffer(void *fb); */ VIRetraceCallback VIDEO_SetPreRetraceCallback(VIRetraceCallback callback); - /*! * \fn VIRetraceCallback VIDEO_SetPostRetraceCallback(VIRetraceCallback callback) * \brief Set the Post-Retrace callback function. This function is called within the video interrupt handler after the VI registers are updated. @@ -188,7 +174,6 @@ VIRetraceCallback VIDEO_SetPreRetraceCallback(VIRetraceCallback callback); */ VIRetraceCallback VIDEO_SetPostRetraceCallback(VIRetraceCallback callback); - /*! * \fn u32 VIDEO_HaveComponentCable(void) * \brief Check for a component cable. This function returns 1 when a Component (YPbPr) cable is connected. diff --git a/wii/libogc/include/ogc/video_types.h b/wii/libogc/include/ogc/video_types.h index 9a03873d82..a3669eff54 100644 --- a/wii/libogc/include/ogc/video_types.h +++ b/wii/libogc/include/ogc/video_types.h @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #ifndef __VIDEO_TYPES_H__ #define __VIDEO_TYPES_H__ @@ -43,7 +42,6 @@ distribution. * @{ */ - #define VI_DISPLAY_PIX_SZ 2 /*!< multiplier to get real pixel size in bytes */ /*! @@ -59,7 +57,6 @@ distribution. * @} */ - /*! * \addtogroup vi_standardtypedef VIDEO standard types * @{ @@ -76,11 +73,9 @@ distribution. * @} */ - #define VI_XFBMODE_SF 0 #define VI_XFBMODE_DF 1 - /*! * \addtogroup vi_fielddef VIDEO field types * @{ @@ -93,7 +88,6 @@ distribution. * @} */ - // Maximum screen space #define VI_MAX_WIDTH_NTSC 720 #define VI_MAX_HEIGHT_NTSC 480 @@ -113,7 +107,6 @@ distribution. * @} */ - #define VI_TVMODE(fmt, mode) ( ((fmt) << 2) + (mode) ) #define VI_TVMODE_NTSC_INT VI_TVMODE(VI_NTSC, VI_INTERLACE) @@ -137,13 +130,11 @@ distribution. #define VI_TVMODE_DEBUG_PAL_INT VI_TVMODE(VI_DEBUG_PAL, VI_INTERLACE) #define VI_TVMODE_DEBUG_PAL_DS VI_TVMODE(VI_DEBUG_PAL, VI_NON_INTERLACE) - /*! * \addtogroup vi_defines List of defines used for the VIDEO subsystem * @{ */ - /*! * \addtogroup gxrmode_obj VIDEO render modes * @{ diff --git a/wii/libogc/include/samplerate.h b/wii/libogc/include/samplerate.h index 9232dc29da..1c82a40c27 100644 --- a/wii/libogc/include/samplerate.h +++ b/wii/libogc/include/samplerate.h @@ -28,7 +28,6 @@ extern "C" { #endif /* __cplusplus */ - /* Opaque data type SRC_STATE. */ typedef struct SRC_STATE_tag SRC_STATE ; @@ -179,7 +178,6 @@ enum void src_short_to_float_array (const short *in, float *out, int len) ; void src_float_to_short_array (const float *in, short *out, int len) ; - #ifdef __cplusplus } /* extern "C" */ #endif /* __cplusplus */ diff --git a/wii/libogc/include/sdcard/card_io.h b/wii/libogc/include/sdcard/card_io.h index 265947b55f..3953984d55 100644 --- a/wii/libogc/include/sdcard/card_io.h +++ b/wii/libogc/include/sdcard/card_io.h @@ -27,7 +27,6 @@ extern u8 g_CID[MAX_DRIVE][16]; extern u8 g_mCode[MAX_MI_NUM]; extern u16 g_dCode[MAX_MI_NUM][MAX_DI_NUM]; - void sdgecko_initIODefault(); s32 sdgecko_initIO(s32 drv_no); s32 sdgecko_preIO(s32 drv_no); @@ -43,7 +42,6 @@ s32 sdgecko_doUnmount(s32 drv_no); void sdgecko_insertedCB(s32 drv_no); void sdgecko_ejectedCB(s32 drv_no); - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/wii/libogc/include/sdcard/wiisd_io.h b/wii/libogc/include/sdcard/wiisd_io.h index 8c1e62b6ac..ceca2ee9e4 100644 --- a/wii/libogc/include/sdcard/wiisd_io.h +++ b/wii/libogc/include/sdcard/wiisd_io.h @@ -8,7 +8,6 @@ Michael Wiedenbauer (shagkur) Dave Murphy (WinterMute) - Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: diff --git a/wii/libogc/include/smb.h b/wii/libogc/include/smb.h index 579f1979c4..749576ff44 100644 --- a/wii/libogc/include/smb.h +++ b/wii/libogc/include/smb.h @@ -81,7 +81,6 @@ #define SMB_DENY_READ 0x30 #define SMB_DENY_NONE 0x40 - #ifdef __cplusplus extern "C" { #endif diff --git a/wii/libogc/include/wiikeyboard/keyboard.h b/wii/libogc/include/wiikeyboard/keyboard.h index 150086f291..0afc1898ae 100644 --- a/wii/libogc/include/wiikeyboard/keyboard.h +++ b/wii/libogc/include/wiikeyboard/keyboard.h @@ -83,7 +83,6 @@ s32 KEYBOARD_Deinit(void); s32 KEYBOARD_GetEvent(keyboard_event *event); s32 KEYBOARD_FlushEvents(void); - #ifdef __cplusplus } #endif /* __cplusplus */ diff --git a/wii/libogc/include/wiiuse/wiiuse.h b/wii/libogc/include/wiiuse/wiiuse.h index 649e5a6dd9..68becb3931 100644 --- a/wii/libogc/include/wiiuse/wiiuse.h +++ b/wii/libogc/include/wiiuse/wiiuse.h @@ -191,7 +191,6 @@ typedef short sword; typedef unsigned int uint; typedef char sint; - struct wiimote_t; struct vec3b_t; struct orient_t; @@ -258,7 +257,6 @@ struct cmd_blk_t struct cmd_blk_t *next; }; - /** * @struct vec2b_t * @brief Unsigned x,y byte vector. @@ -267,7 +265,6 @@ typedef struct vec2b_t { ubyte x, y; } vec2b_t; - /** * @struct vec3b_t * @brief Unsigned x,y,z byte vector. @@ -284,7 +281,6 @@ typedef struct vec3w_t { uword x, y, z; } vec3w_t; - /** * @struct vec3f_t * @brief Signed x,y,z float struct. @@ -293,7 +289,6 @@ typedef struct vec3f_t { float x, y, z; } vec3f_t; - /** * @struct orient_t * @brief Orientation struct. @@ -309,7 +304,6 @@ typedef struct orient_t { float a_pitch; /**< absolute pitch, unsmoothed */ } orient_t; - /** * @struct gforce_t * @brief Gravity force struct. @@ -318,7 +312,6 @@ typedef struct gforce_t { float x, y, z; } gforce_t; - /** * @struct accel_t * @brief Accelerometer struct. For any device with an accelerometer. @@ -332,7 +325,6 @@ typedef struct accel_t { float st_alpha; /**< alpha value for smoothing [0-1] */ } accel_t; - /** * @struct ir_dot_t * @brief A single IR source. @@ -346,7 +338,6 @@ typedef struct ir_dot_t { ubyte size; /**< size of the IR dot (0-15) */ } ir_dot_t; - typedef struct fdot_t { float x,y; } fdot_t; @@ -369,7 +360,6 @@ typedef enum aspect_t { WIIUSE_ASPECT_16_9 } aspect_t; - /** * @struct ir_t * @brief IR struct. Hold all data related to the IR tracking. @@ -404,7 +394,6 @@ typedef struct ir_t { } ir_t; - /** * @struct joystick_t * @brief Joystick calibration structure. @@ -430,7 +419,6 @@ typedef struct joystick_t { float mag; /**< magnitude of the joystick (range 0-1) */ } joystick_t; - /** * @struct nunchuk_t * @brief Nunchuk expansion device. @@ -451,7 +439,6 @@ typedef struct nunchuk_t { struct gforce_t gforce; /**< current gravity forces on each axis */ } nunchuk_t; - /** * @struct classic_ctrl_t * @brief Classic controller expansion device. @@ -473,7 +460,6 @@ typedef struct classic_ctrl_t { ubyte type; /**< original, pro, wiiu pro */ } classic_ctrl_t; - /** * @struct guitar_hero_3_t * @brief Guitar Hero 3 expansion device. @@ -537,7 +523,6 @@ typedef struct expansion_t { }; } expansion_t; - /** * @enum win32_bt_stack_t * @brief Available bluetooth stacks for Windows. @@ -548,7 +533,6 @@ typedef enum win_bt_stack_t { WIIUSE_STACK_BLUESOLEIL } win_bt_stack_t; - /** * @struct wiimote_state_t * @brief Significant data from the previous event. @@ -561,7 +545,6 @@ typedef struct wiimote_state_t { struct expansion_t exp; } wiimote_state_t; - /** * @enum WIIUSE_EVENT_TYPE * @brief Events that wiiuse can generate from a poll. diff --git a/wii/libogc/libdb/debug.c b/wii/libogc/libdb/debug.c index d30351d7a3..676a784b19 100644 --- a/wii/libogc/libdb/debug.c +++ b/wii/libogc/libdb/debug.c @@ -426,7 +426,6 @@ static void gdbstub_report_exception(frame_context *frame,s32 thread) } - void c_debug_handler(frame_context *frame) { char *ptr; diff --git a/wii/libogc/libdb/geckousb.c b/wii/libogc/libdb/geckousb.c index fed8f3424d..f0b936e612 100644 --- a/wii/libogc/libdb/geckousb.c +++ b/wii/libogc/libdb/geckousb.c @@ -89,7 +89,6 @@ static void __usb_flush(s32 chn) EXI_Unlock(chn); } - static int __usb_isgeckoalive(s32 chn) { s32 ret; diff --git a/wii/libogc/libdb/tcpip.c b/wii/libogc/libdb/tcpip.c index 0b88c0794d..e48298d3ac 100644 --- a/wii/libogc/libdb/tcpip.c +++ b/wii/libogc/libdb/tcpip.c @@ -176,7 +176,6 @@ static s8_t tcpip_recved(void *arg,struct uip_tcp_pcb *pcb,struct uip_pbuf *p,s8 return UIP_ERR_OK; } - static s8_t tcpip_accept_func(void *arg,struct uip_tcp_pcb *newpcb,s8_t err) { s32_t s; diff --git a/wii/libogc/libdb/uIP/bba.c b/wii/libogc/libdb/uIP/bba.c index a228f61f1b..e34576f64a 100644 --- a/wii/libogc/libdb/uIP/bba.c +++ b/wii/libogc/libdb/uIP/bba.c @@ -346,7 +346,6 @@ static inline void bba_insdata(void *val,u32 len) EXI_ImmEx(EXI_CHANNEL_0,val,len,EXI_READ); } - static inline void bba_outsregister(u32 reg) { u32 req; @@ -373,14 +372,12 @@ static u32 __bba_getlink_state_async() { u32 ret; - if(EXI_Lock(EXI_CHANNEL_0,EXI_DEVICE_2,NULL)==0) return 0; ret = __linkstate(); EXI_Unlock(EXI_CHANNEL_0); return ret; } - static u32 __bba_read_cid() { u16 cmd = 0; diff --git a/wii/libogc/libdb/uIP/uip.h b/wii/libogc/libdb/uIP/uip.h index 06790c4129..5e8a3e485a 100644 --- a/wii/libogc/libdb/uIP/uip.h +++ b/wii/libogc/libdb/uIP/uip.h @@ -14,7 +14,6 @@ * */ - /* * Copyright (c) 2001-2003, Adam Dunkels. * All rights reserved. @@ -171,6 +170,5 @@ u16_t htons(u16_t val); #endif /* __UIP_H__ */ - /** @} */ diff --git a/wii/libogc/libdb/uIP/uip_arch.c b/wii/libogc/libdb/uIP/uip_arch.c index 17432a8f8e..060b129412 100644 --- a/wii/libogc/libdb/uIP/uip_arch.c +++ b/wii/libogc/libdb/uIP/uip_arch.c @@ -41,7 +41,6 @@ #include "uip_tcp.h" #include "uip_pbuf.h" - /*-----------------------------------------------------------------------------------*/ u16_t uip_chksum(u16_t *sdata, u32_t len) { diff --git a/wii/libogc/libdb/uIP/uip_arch.h b/wii/libogc/libdb/uIP/uip_arch.h index e90744cb02..1ab9d0ca83 100644 --- a/wii/libogc/libdb/uIP/uip_arch.h +++ b/wii/libogc/libdb/uIP/uip_arch.h @@ -133,8 +133,6 @@ u16_t uip_ipchksum_pbuf(struct uip_pbuf *p); */ u16_t uip_chksum_pseudo(struct uip_pbuf *p,struct uip_ip_addr *src,struct uip_ip_addr *dst,u8_t proto,u16_t proto_len); - - extern void tcpip_tmr_needed(); #define tcp_tmr_needed tcpip_tmr_needed diff --git a/wii/libogc/libdb/uIP/uip_arp.c b/wii/libogc/libdb/uIP/uip_arp.c index 1c7d43827a..c1baebbbe5 100644 --- a/wii/libogc/libdb/uIP/uip_arp.c +++ b/wii/libogc/libdb/uIP/uip_arp.c @@ -57,7 +57,6 @@ * */ - #include "uip_pbuf.h" #include "uip_netif.h" #include "uip_arp.h" @@ -78,7 +77,6 @@ struct uip_stats uip_stat; #define UIP_STAT(s) #endif /* UIP_STATISTICS == 1 */ - #define ARP_TRY_HARD 0x01 #define ARP_MAXAGE 240 diff --git a/wii/libogc/libdb/uIP/uip_arp.h b/wii/libogc/libdb/uIP/uip_arp.h index 40ae3c69ea..3efae1d01e 100644 --- a/wii/libogc/libdb/uIP/uip_arp.h +++ b/wii/libogc/libdb/uIP/uip_arp.h @@ -14,7 +14,6 @@ * \author Adam Dunkels */ - /* * Copyright (c) 2001-2003, Adam Dunkels. * All rights reserved. @@ -100,7 +99,6 @@ struct uip_ethip_hdr { } PACK_STRUCT_STRUCT; PACK_STRUCT_END - extern struct uip_eth_addr uip_ethaddr; struct uip_pbuf; @@ -147,4 +145,3 @@ s8_t uip_arp_arprequest(struct uip_netif *netif,struct uip_ip_addr *ipaddr); #endif /* __UIP_ARP_H__ */ - diff --git a/wii/libogc/libdb/uIP/uip_icmp.h b/wii/libogc/libdb/uIP/uip_icmp.h index 42928a0fab..0a8e29b30f 100644 --- a/wii/libogc/libdb/uIP/uip_icmp.h +++ b/wii/libogc/libdb/uIP/uip_icmp.h @@ -53,7 +53,6 @@ PACK_STRUCT_END struct uip_pbuf; struct uip_netif; - void uip_icmpinput(struct uip_pbuf *p,struct uip_netif *inp); void uip_icmp_destunreach(struct uip_pbuf *p,enum uip_icmp_dur_type t); diff --git a/wii/libogc/libdb/uIP/uip_ip.h b/wii/libogc/libdb/uIP/uip_ip.h index 5a2c6f9e92..adf9af3974 100644 --- a/wii/libogc/libdb/uIP/uip_ip.h +++ b/wii/libogc/libdb/uIP/uip_ip.h @@ -120,7 +120,6 @@ struct uip_pbuf; struct uip_netif; struct ip_addr; - void uip_ipinit(); u32_t uip_ipaddr(const u8_t *cp); @@ -131,5 +130,4 @@ s8_t uip_ipoutput_if(struct uip_pbuf *p,struct uip_ip_addr *src,struct uip_ip_ad struct uip_netif* uip_iproute(struct uip_ip_addr *dst); u8_t uip_ipaddr_isbroadcast(struct uip_ip_addr *addr,struct uip_netif *netif); - #endif diff --git a/wii/libogc/libdb/uIP/uip_netif.c b/wii/libogc/libdb/uIP/uip_netif.c index bfcbf0c914..383b7d2b1a 100644 --- a/wii/libogc/libdb/uIP/uip_netif.c +++ b/wii/libogc/libdb/uIP/uip_netif.c @@ -27,7 +27,6 @@ struct uip_stats uip_stat; #define UIP_STAT(s) #endif /* UIP_STATISTICS == 1 */ - struct uip_netif *uip_netif_list; struct uip_netif *uip_netif_default; diff --git a/wii/libogc/libdb/uIP/uip_pbuf.c b/wii/libogc/libdb/uIP/uip_pbuf.c index a5c4ee5cbe..c71190d407 100644 --- a/wii/libogc/libdb/uIP/uip_pbuf.c +++ b/wii/libogc/libdb/uIP/uip_pbuf.c @@ -186,7 +186,6 @@ u8_t uip_pbuf_header(struct uip_pbuf *p,s16_t hdr_size_inc) if(hdr_size_inc==0 || p==NULL) return 0; - payload = p->payload; if(p->flags==UIP_PBUF_FLAG_POOL || p->flags==UIP_PBUF_FLAG_RAM) { p->payload = (u8_t*)p->payload-hdr_size_inc; diff --git a/wii/libogc/libdb/uIP/uipopt.h b/wii/libogc/libdb/uIP/uipopt.h index d282e1d492..b6f8fbe91a 100644 --- a/wii/libogc/libdb/uIP/uipopt.h +++ b/wii/libogc/libdb/uIP/uipopt.h @@ -258,7 +258,6 @@ typedef u16 uip_stats_t; #define UIP_TCP_SEGS 32 - /** * Determines if support for TCP urgent data notification should be * compiled in. @@ -301,7 +300,6 @@ typedef u16 uip_stats_t; */ #define UIP_TCP_MSS (1460) - #define UIP_TCP_SND_BUF (4*UIP_TCP_MSS) #define UIP_TCP_SND_QUEUELEN (4*UIP_TCP_SND_BUF/UIP_TCP_MSS) @@ -316,7 +314,6 @@ typedef u16 uip_stats_t; */ #define UIP_TIME_WAIT_TIMEOUT 120 - /** @} */ /*------------------------------------------------------------------------------*/ /** @@ -367,7 +364,6 @@ typedef u16 uip_stats_t; #define UIP_PBUF_ROM_NUM 128 - /** * Determines if statistics support should be compiled in. * diff --git a/wii/libogc/libfat/cache.c b/wii/libogc/libfat/cache.c index 07576b9cbf..1cf425452b 100644 --- a/wii/libogc/libfat/cache.c +++ b/wii/libogc/libfat/cache.c @@ -70,7 +70,6 @@ CACHE* _FAT_cache_constructor (unsigned int numberOfPages, unsigned int sectorsP cache->sectorsPerPage = sectorsPerPage; cache->bytesPerSector = bytesPerSector; - cacheEntries = (CACHE_ENTRY*) _FAT_mem_allocate ( sizeof(CACHE_ENTRY) * numberOfPages); if (cacheEntries == NULL) { _FAT_mem_free (cache); @@ -103,7 +102,6 @@ void _FAT_cache_destructor (CACHE* cache) { _FAT_mem_free (cache); } - static u32 accessCounter = 0; static u32 accessTime(){ @@ -111,7 +109,6 @@ static u32 accessTime(){ return accessCounter; } - static CACHE_ENTRY* _FAT_cache_getPage(CACHE *cache,sec_t sector) { unsigned int i; @@ -265,7 +262,6 @@ bool _FAT_cache_eraseWritePartialSector (CACHE* cache, const void* buffer, sec_t return true; } - bool _FAT_cache_writeSectors (CACHE* cache, sec_t sector, sec_t numSectors, const void* buffer) { sec_t sec; diff --git a/wii/libogc/libfat/directory.c b/wii/libogc/libfat/directory.c index 65906d844b..2f9b1650e5 100644 --- a/wii/libogc/libfat/directory.c +++ b/wii/libogc/libfat/directory.c @@ -200,7 +200,6 @@ static int _FAT_directory_mbsncasecmp (const char* s1, const char* s2, size_t le return towlower(wc1) - towlower(wc2); } - static bool _FAT_directory_entryGetAlias (const u8* entryData, char* destName) { char c; bool caseInfo; @@ -525,8 +524,6 @@ bool _FAT_directory_entryFromPosition (PARTITION* partition, DIR_ENTRY* entry) { return true; } - - bool _FAT_directory_entryFromPath (PARTITION* partition, DIR_ENTRY* entry, const char* path, const char* pathEnd) { size_t dirnameLength; const char* pathPosition; diff --git a/wii/libogc/libfat/fatdir.c b/wii/libogc/libfat/fatdir.c index 1ef5aec6d5..1113d6aecf 100644 --- a/wii/libogc/libfat/fatdir.c +++ b/wii/libogc/libfat/fatdir.c @@ -44,7 +44,6 @@ #include "filetime.h" #include "lock.h" - int _FAT_stat_r (struct _reent *r, const char *path, struct stat *st) { PARTITION* partition = NULL; DIR_ENTRY dirEntry; @@ -127,7 +126,6 @@ int _FAT_unlink_r (struct _reent *r, const char *path) { cluster = _FAT_directory_entryGetCluster (partition, dirEntry.entryData); - // If this is a directory, make sure it is empty if (_FAT_directory_isDirectory (&dirEntry)) { nextEntry = _FAT_directory_getFirstEntry (partition, &dirContents, cluster); @@ -425,7 +423,6 @@ int _FAT_mkdir_r (struct _reent *r, const char *path, int mode) { _FAT_cache_eraseWritePartialSector ( partition->cache, newEntryData, _FAT_fat_clusterToSector (partition, dirCluster), 0, DIR_ENTRY_DATA_SIZE); - // Create the double dot entry within the directory // if ParentDir == Rootdir then ".."" always link to Cluster 0 diff --git a/wii/libogc/libfat/fatdir.h b/wii/libogc/libfat/fatdir.h index 79fd2df90e..508cad78d7 100644 --- a/wii/libogc/libfat/fatdir.h +++ b/wii/libogc/libfat/fatdir.h @@ -28,7 +28,6 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #ifndef _FATDIR_H #define _FATDIR_H @@ -69,5 +68,4 @@ extern int _FAT_dirreset_r (struct _reent *r, DIR_ITER *dirState); extern int _FAT_dirnext_r (struct _reent *r, DIR_ITER *dirState, char *filename, struct stat *filestat); extern int _FAT_dirclose_r (struct _reent *r, DIR_ITER *dirState); - #endif // _FATDIR_H diff --git a/wii/libogc/libfat/fatfile.c b/wii/libogc/libfat/fatfile.c index 06c2ca7c1e..054b4675bf 100644 --- a/wii/libogc/libfat/fatfile.c +++ b/wii/libogc/libfat/fatfile.c @@ -30,7 +30,6 @@ 2009-10-23 oggzee: fixes for cluster aligned file size (write, truncate, seek) */ - #include "fatfile.h" #include @@ -102,7 +101,6 @@ int FAT_setAttr(const char *file, uint8_t attr) { // Lock Partition _FAT_lock(&partition->lock); - // Write Data _FAT_cache_writePartialSector ( partition->cache // Cache to write @@ -124,7 +122,6 @@ int FAT_setAttr(const char *file, uint8_t attr) { return 0; } - int _FAT_open_r (struct _reent *r, void *fileStruct, const char *path, int flags, int mode) { PARTITION* partition = NULL; bool fileExists; @@ -381,7 +378,6 @@ int _FAT_syncToDisc (FILE_STRUCT* file) { return 0; } - int _FAT_close_r (struct _reent *r, void *fd) { FILE_STRUCT* file = (FILE_STRUCT*) fd; int ret = 0; @@ -807,7 +803,6 @@ ssize_t _FAT_write_r (struct _reent *r, void *fd, const char *ptr, size_t len) { ptr += tempVar; position.byte += tempVar; - // Move onto next sector if (position.byte >= partition->bytesPerSector) { position.byte = 0; @@ -917,7 +912,6 @@ ssize_t _FAT_write_r (struct _reent *r, void *fd, const char *ptr, size_t len) { remain = 0; } - // Amount written is the originally requested amount minus stuff remaining len = len - remain; @@ -940,7 +934,6 @@ ssize_t _FAT_write_r (struct _reent *r, void *fd, const char *ptr, size_t len) { return len; } - off_t _FAT_seek_r (struct _reent *r, void *fd, off_t pos, int dir) { FILE_STRUCT* file = (FILE_STRUCT*) fd; PARTITION* partition; @@ -1041,8 +1034,6 @@ off_t _FAT_seek_r (struct _reent *r, void *fd, off_t pos, int dir) { return position; } - - int _FAT_fstat_r (struct _reent *r, void *fd, struct stat *st) { FILE_STRUCT* file = (FILE_STRUCT*) fd; PARTITION* partition; diff --git a/wii/libogc/libfat/fatfile.h b/wii/libogc/libfat/fatfile.h index d2ae24ce52..b84bdc9c58 100644 --- a/wii/libogc/libfat/fatfile.h +++ b/wii/libogc/libfat/fatfile.h @@ -28,7 +28,6 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #ifndef _FATFILE_H #define _FATFILE_H diff --git a/wii/libogc/libfat/file_allocation_table.c b/wii/libogc/libfat/file_allocation_table.c index 72f8aa74aa..40302c724c 100644 --- a/wii/libogc/libfat/file_allocation_table.c +++ b/wii/libogc/libfat/file_allocation_table.c @@ -27,7 +27,6 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #include "file_allocation_table.h" #include "partition.h" #include "mem_allocate.h" @@ -58,7 +57,6 @@ uint32_t _FAT_fat_nextCluster(PARTITION* partition, uint32_t cluster) sector = partition->fat.fatStart + (((cluster * 3) / 2) / partition->bytesPerSector); offset = ((cluster * 3) / 2) % partition->bytesPerSector; - _FAT_cache_readLittleEndianValue (partition->cache, &nextCluster, sector, offset, sizeof(u8)); offset++; @@ -294,7 +292,6 @@ uint32_t _FAT_fat_linkFreeClusterCleared (PARTITION* partition, uint32_t cluster return newCluster; } - /*----------------------------------------------------------------- _FAT_fat_clearLinks frees any cluster used by a file diff --git a/wii/libogc/libfat/file_allocation_table.h b/wii/libogc/libfat/file_allocation_table.h index 4ba181130e..d5076ffe63 100644 --- a/wii/libogc/libfat/file_allocation_table.h +++ b/wii/libogc/libfat/file_allocation_table.h @@ -43,7 +43,6 @@ #define CLUSTERS_PER_FAT12 4085 #define CLUSTERS_PER_FAT16 65525 - uint32_t _FAT_fat_nextCluster(PARTITION* partition, uint32_t cluster); uint32_t _FAT_fat_linkFreeCluster(PARTITION* partition, uint32_t cluster); diff --git a/wii/libogc/libfat/filetime.c b/wii/libogc/libfat/filetime.c index a3c1c591b0..13ee2c8453 100644 --- a/wii/libogc/libfat/filetime.c +++ b/wii/libogc/libfat/filetime.c @@ -26,7 +26,6 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - #include #include "filetime.h" #include "common.h" @@ -66,7 +65,6 @@ uint16_t _FAT_filetime_getTimeFromRTC (void) { #endif } - uint16_t _FAT_filetime_getDateFromRTC (void) { #ifdef USE_RTC_TIME struct tm timeParts; diff --git a/wii/libogc/libfat/filetime.h b/wii/libogc/libfat/filetime.h index 9d6e70c93d..bc6149252a 100644 --- a/wii/libogc/libfat/filetime.h +++ b/wii/libogc/libfat/filetime.h @@ -37,5 +37,4 @@ uint16_t _FAT_filetime_getDateFromRTC (void); time_t _FAT_filetime_to_time_t (uint16_t t, uint16_t d); - #endif // _FILETIME_H diff --git a/wii/libogc/libfat/lock.h b/wii/libogc/libfat/lock.h index de5723a9cb..65235c93b7 100644 --- a/wii/libogc/libfat/lock.h +++ b/wii/libogc/libfat/lock.h @@ -67,6 +67,5 @@ void _FAT_unlock(mutex_t *mutex); #endif // USE_LWP_LOCK - #endif // _LOCK_H diff --git a/wii/libogc/libfat/partition.c b/wii/libogc/libfat/partition.c index 1584e0ed59..b06aec6fc8 100644 --- a/wii/libogc/libfat/partition.c +++ b/wii/libogc/libfat/partition.c @@ -169,7 +169,6 @@ sec_t FindFirstValidPartition(const DISC_INTERFACE* disc) return ret; } - PARTITION* _FAT_partition_constructor_buf (const DISC_INTERFACE* disc, uint32_t cacheSize, uint32_t sectorsPerPage, sec_t startSector, uint8_t *sectorBuffer) { PARTITION* partition; @@ -309,7 +308,6 @@ PARTITION* _FAT_partition_constructor (const DISC_INTERFACE* disc, uint32_t cach return ret; } - void _FAT_partition_destructor (PARTITION* partition) { FILE_STRUCT* nextFile; diff --git a/wii/libogc/libogc/aram.c b/wii/libogc/libogc/aram.c index a306c4564b..cf095ac0c1 100644 --- a/wii/libogc/libogc/aram.c +++ b/wii/libogc/libogc/aram.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include @@ -296,7 +295,6 @@ static void __ARCheckSize() static u32 dummy_data[8] ATTRIBUTE_ALIGN(32); static u32 buffer[8] ATTRIBUTE_ALIGN(32); - while(!(_dspReg[11]&0x0001)); __ARSize = __ARInternalSize = arsize = 0x1000000; diff --git a/wii/libogc/libogc/arqmgr.c b/wii/libogc/libogc/arqmgr.c index 21dbf2d97a..e04a848c9d 100644 --- a/wii/libogc/libogc/arqmgr.c +++ b/wii/libogc/libogc/arqmgr.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include "asm.h" diff --git a/wii/libogc/libogc/arqueue.c b/wii/libogc/libogc/arqueue.c index 04e5c2a54b..4214258100 100644 --- a/wii/libogc/libogc/arqueue.c +++ b/wii/libogc/libogc/arqueue.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include diff --git a/wii/libogc/libogc/audio.c b/wii/libogc/libogc/audio.c index 037688660a..5c2ae1e45c 100644 --- a/wii/libogc/libogc/audio.c +++ b/wii/libogc/libogc/audio.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include "asm.h" #include "processor.h" diff --git a/wii/libogc/libogc/cache.c b/wii/libogc/libogc/cache.c index e9b35ade13..2e0846f6f2 100644 --- a/wii/libogc/libogc/cache.c +++ b/wii/libogc/libogc/cache.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include "cache.h" diff --git a/wii/libogc/libogc/card.c b/wii/libogc/libogc/card.c index 2d47a074db..0ed29626fe 100644 --- a/wii/libogc/libogc/card.c +++ b/wii/libogc/libogc/card.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include @@ -419,7 +418,6 @@ static void __card_updateiconoffsets(struct card_direntry *entry,card_stat *stat stats->offset_icon_tlut[i] = -1; break; - } } // stats->offset_data = iconaddr; @@ -894,7 +892,6 @@ static void __timeouthandler(syswd_t alarm,void *cbarg) } if(chn=EXI_CHANNEL_2) return; - if(card->attached) { EXI_RegisterEXICallback(chn,NULL); cb = card->card_exi_cb; @@ -2050,7 +2047,6 @@ static s32 __dounlock(s32 chn,u32 *key) if(__card_readarrayunlock(chn,array_addr,tmp_buffer,len,0)<0) return CARD_ERROR_NOCARD; - val = exnor_1st(array_addr,(len<<3)+1); { u32 a,b,c,r1,r2,r3; diff --git a/wii/libogc/libogc/cond.c b/wii/libogc/libogc/cond.c index 2e8904084e..9733926765 100644 --- a/wii/libogc/libogc/cond.c +++ b/wii/libogc/libogc/cond.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include "asm.h" @@ -99,7 +98,6 @@ static s32 __lwp_cond_waitsupp(cond_t cond,mutex_t mutex,u64 timeout,u8 timedout return EINVAL; } - LWP_MutexUnlock(mutex); if(!timedout) { thecond->lock = mutex; diff --git a/wii/libogc/libogc/conf.c b/wii/libogc/libogc/conf.c index 3f26fdf15a..91fd50df6f 100644 --- a/wii/libogc/libogc/conf.c +++ b/wii/libogc/libogc/conf.c @@ -36,7 +36,6 @@ distribution. #include "processor.h" #include "conf.h" - static int __conf_inited = 0; static u8 __conf_buffer[0x4000] ATTRIBUTE_ALIGN(32); static char __conf_txt_buffer[0x101] ATTRIBUTE_ALIGN(32); diff --git a/wii/libogc/libogc/console.c b/wii/libogc/libogc/console.c index 8d7550aff1..f1ae008843 100644 --- a/wii/libogc/libogc/console.c +++ b/wii/libogc/libogc/console.c @@ -99,7 +99,6 @@ void __console_vipostcb(u32 retraceCnt) do_xfb_copy = FALSE; } - static void __console_drawc(int c) { console_data_s *con; diff --git a/wii/libogc/libogc/console.h b/wii/libogc/libogc/console.h index df05b1e798..fd0275589d 100644 --- a/wii/libogc/libogc/console.h +++ b/wii/libogc/libogc/console.h @@ -1,7 +1,6 @@ #ifndef __CONSOLE_H__ #define __CONSOLE_H__ - #define FONT_XSIZE 8 #define FONT_YSIZE 16 #define FONT_XFACTOR 1 diff --git a/wii/libogc/libogc/console_font_8x16.c b/wii/libogc/libogc/console_font_8x16.c index 21ef8da057..b43887afa6 100644 --- a/wii/libogc/libogc/console_font_8x16.c +++ b/wii/libogc/libogc/console_font_8x16.c @@ -4610,4 +4610,3 @@ unsigned char console_font_8x16[] = { }; - diff --git a/wii/libogc/libogc/decrementer.c b/wii/libogc/libogc/decrementer.c index eb1c962c33..12f1cef1ca 100644 --- a/wii/libogc/libogc/decrementer.c +++ b/wii/libogc/libogc/decrementer.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include #include "asm.h" diff --git a/wii/libogc/libogc/dsp.c b/wii/libogc/libogc/dsp.c index 01b16f8013..20a0044df0 100644 --- a/wii/libogc/libogc/dsp.c +++ b/wii/libogc/libogc/dsp.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include #include "asm.h" diff --git a/wii/libogc/libogc/dvd.c b/wii/libogc/libogc/dvd.c index 823e14e78c..a751dcd50d 100644 --- a/wii/libogc/libogc/dvd.c +++ b/wii/libogc/libogc/dvd.c @@ -31,7 +31,6 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ #include #include @@ -1346,7 +1345,6 @@ static void __dvd_patchdrivecb(s32 result) DVD_LowFuncCall(0x0040d000,__dvd_finalpatchcb); } - static void __dvd_unlockdrivecb(s32 result) { u32 i; diff --git a/wii/libogc/libogc/es.c b/wii/libogc/libogc/es.c index df4bd501e8..29ecc79946 100644 --- a/wii/libogc/libogc/es.c +++ b/wii/libogc/libogc/es.c @@ -100,7 +100,6 @@ distribution. #define IOCTL_ES_GETSHAREDCONTENTCNT 0x36 #define IOCTL_ES_GETSHAREDCONTENTS 0x37 - #define ES_HEAP_SIZE 0x800 #define ISALIGNED(x) ((((u32)x)&0x1F)==0) @@ -130,7 +129,6 @@ s32 __ES_Init(void) __es_fd = ret; } - __ES_InitFS(); return 0; @@ -927,7 +925,6 @@ static int _ES_read_r (struct _reent *r, void *fd, char *ptr, size_t len) { int read = 0; int res; - LWP_MutexLock(file->mutex); if(file->cfd < 0) { LWP_MutexUnlock(file->mutex); diff --git a/wii/libogc/libogc/exception.c b/wii/libogc/libogc/exception.c index e79a4fcdbf..9656f4173c 100644 --- a/wii/libogc/libogc/exception.c +++ b/wii/libogc/libogc/exception.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include diff --git a/wii/libogc/libogc/exi.c b/wii/libogc/libogc/exi.c index 961fd46592..c9e8b71e8b 100644 --- a/wii/libogc/libogc/exi.c +++ b/wii/libogc/libogc/exi.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include @@ -56,7 +55,6 @@ distribution. #define _SHIFTR(v, s, w) \ ((u32)(((u32)(v) >> (s)) & ((0x01 << (w)) - 1))) - struct _lck_dev { lwp_node node; u32 dev; @@ -730,7 +728,6 @@ void __ext_irq_handler(u32 nIrq,void *pCtx) if(exi->CallbackEXT) exi->CallbackEXT(chan,dev); } - /* EXI UART stuff */ static s32 __probebarnacle(s32 chn,u32 dev,u32 *rev) { @@ -795,7 +792,6 @@ void __SYS_EnableBarnacle(s32 chn,u32 dev) if(__probebarnacle(chn,dev,&rev)==0) return; - exi_uart_chan = chn; exi_uart_dev = dev; exi_uart_barnacle_enabled = 0xa5ff005a; diff --git a/wii/libogc/libogc/gcsd.c b/wii/libogc/libogc/gcsd.c index 5d41f048d7..5c9fb97721 100644 --- a/wii/libogc/libogc/gcsd.c +++ b/wii/libogc/libogc/gcsd.c @@ -55,7 +55,6 @@ static bool __gcsd_startup(int n) return __gcsd_isInserted(n); } - static bool __gcsd_readSectors(int n, u32 sector, u32 numSectors, void *buffer) { s32 ret; @@ -89,7 +88,6 @@ static bool __gcsd_shutdown(int n) return true; } - static bool __gcsda_startup(void) { return __gcsd_startup(0); @@ -120,8 +118,6 @@ static bool __gcsda_shutdown(void) return __gcsd_shutdown(0); } - - static bool __gcsdb_startup(void) { return __gcsd_startup(1); diff --git a/wii/libogc/libogc/gu.c b/wii/libogc/libogc/gu.c index 2c906ffb92..672b0ac1c1 100644 --- a/wii/libogc/libogc/gu.c +++ b/wii/libogc/libogc/gu.c @@ -410,16 +410,13 @@ u32 c_guMtxInverse(Mtx src,Mtx inv) else m = inv; - // compute the determinant of the upper 3x3 submatrix det = src[0][0]*src[1][1]*src[2][2] + src[0][1]*src[1][2]*src[2][0] + src[0][2]*src[1][0]*src[2][1] - src[2][0]*src[1][1]*src[0][2] - src[1][0]*src[0][1]*src[2][2] - src[0][0]*src[2][1]*src[1][2]; - // check if matrix is singular if(det==0.0f)return 0; - // compute the inverse of the upper submatrix: // find the transposed matrix of cofactors of the upper submatrix @@ -427,7 +424,6 @@ u32 c_guMtxInverse(Mtx src,Mtx inv) det = 1.0f / det; - m[0][0] = (src[1][1]*src[2][2] - src[2][1]*src[1][2]) * det; m[0][1] = -(src[0][1]*src[2][2] - src[2][1]*src[0][2]) * det; m[0][2] = (src[0][1]*src[1][2] - src[1][1]*src[0][2]) * det; @@ -440,7 +436,6 @@ u32 c_guMtxInverse(Mtx src,Mtx inv) m[2][1] = -(src[0][0]*src[2][1] - src[2][0]*src[0][1]) * det; m[2][2] = (src[0][0]*src[1][1] - src[1][0]*src[0][1]) * det; - // compute (invA)*(-C) m[0][3] = -m[0][0]*src[0][3] - m[0][1]*src[1][3] - m[0][2]*src[2][3]; m[1][3] = -m[1][0]*src[0][3] - m[1][1]*src[1][3] - m[1][2]*src[2][3]; @@ -463,12 +458,10 @@ void c_guMtxTranspose(Mtx src,Mtx xPose) else m = xPose; - m[0][0] = src[0][0]; m[0][1] = src[1][0]; m[0][2] = src[2][0]; m[0][3] = 0.0f; m[1][0] = src[0][1]; m[1][1] = src[1][1]; m[1][2] = src[2][1]; m[1][3] = 0.0f; m[2][0] = src[0][2]; m[2][1] = src[1][2]; m[2][2] = src[2][2]; m[2][3] = 0.0f; - // copy back if needed if(m==mTmp) c_guMtxCopy(mTmp,xPose); @@ -511,7 +504,6 @@ u32 c_guMtxInvXpose(Mtx src, Mtx xPose) m[2][1] = -(src[0][0]*src[1][2] - src[1][0]*src[0][2]) * det; m[2][2] = (src[0][0]*src[1][1] - src[1][0]*src[0][1]) * det; - // The 4th columns should be zero m[0][3] = 0.0F; m[1][3] = 0.0F; @@ -549,7 +541,6 @@ void c_guMtxReflect(Mtx m,guVector *p,guVector *n) m[2][3] = pdotn * n->z; } - void c_guVecAdd(guVector *a,guVector *b,guVector *ab) { ab->x = a->x + b->x; @@ -571,7 +562,6 @@ void c_guVecScale(guVector *src,guVector *dst,f32 scale) dst->z = src->z * scale; } - void c_guVecNormalize(guVector *v) { f32 m; diff --git a/wii/libogc/libogc/gx.c b/wii/libogc/libogc/gx.c index ff9b413e78..e69478afa1 100644 --- a/wii/libogc/libogc/gx.c +++ b/wii/libogc/libogc/gx.c @@ -15,7 +15,6 @@ #define TEXCACHE_TESTING - #define GX_FINISH 2 #if defined(HW_DOL) @@ -129,7 +128,6 @@ static u32 _gxtexregionaddrtable[48] = }; #endif - extern u8 __gxregs[]; static struct __gx_regdef *__gx = (struct __gx_regdef*)__gxregs; static u8 _gx_saved_data[STRUCT_REGDEF_SIZE] ATTRIBUTE_ALIGN(32); @@ -1652,7 +1650,6 @@ void GX_SetDrawDone() _CPU_ISR_Restore(level); } - void GX_WaitDrawDone() { u32 level; @@ -2963,7 +2960,6 @@ u16 GX_GetTexObjWidth(GXTexObj* obj) return (((struct __gx_texobj*)obj)->tex_size & 0x3ff) + 1; } - void GX_GetTexObjAll(GXTexObj* obj, void** image_ptr, u16* width, u16* height, u8* format, u8* wrap_s, u8* wrap_t, u8* mipmap) { diff --git a/wii/libogc/libogc/ipc.c b/wii/libogc/libogc/ipc.c index 10fed37bce..9e145f0c77 100644 --- a/wii/libogc/libogc/ipc.c +++ b/wii/libogc/libogc/ipc.c @@ -1101,7 +1101,6 @@ s32 IOS_Ioctlv(s32 fd,s32 ioctl,s32 cnt_in,s32 cnt_io,ioctlv *argv) return ret; } - s32 IOS_IoctlvAsync(s32 fd,s32 ioctl,s32 cnt_in,s32 cnt_io,ioctlv *argv,ipccallback ipc_cb,void *usrdata) { s32 i; diff --git a/wii/libogc/libogc/irq.c b/wii/libogc/libogc/irq.c index 0e59f51e2b..36e25e3038 100644 --- a/wii/libogc/libogc/irq.c +++ b/wii/libogc/libogc/irq.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include "asm.h" diff --git a/wii/libogc/libogc/isfs.c b/wii/libogc/libogc/isfs.c index b08ca977d0..44f79443a1 100644 --- a/wii/libogc/libogc/isfs.c +++ b/wii/libogc/libogc/isfs.c @@ -108,7 +108,6 @@ struct isfs_cb void *funcargv[8]; }; - static s32 hId = -1; static s32 _fs_fd = -1; static char _dev_fs[] ATTRIBUTE_ALIGN(32) = "/dev/fs"; @@ -840,5 +839,4 @@ s32 ISFS_GetUsageAsync(const char* filepath, u32* usage1, u32* usage2,isfscallba return IOS_IoctlvAsync(_fs_fd,ISFS_IOCTL_GETUSAGE,1,2,param->fsusage.vector,__isfsFunctionCB,param); } - #endif /* defined(HW_RVL) */ diff --git a/wii/libogc/libogc/kprintf.c b/wii/libogc/libogc/kprintf.c index 976a756704..d3a7e232db 100644 --- a/wii/libogc/libogc/kprintf.c +++ b/wii/libogc/libogc/kprintf.c @@ -214,7 +214,6 @@ int kvsprintf(char *buf, const char *fmt, va_list args) field_width, precision, flags); continue; - case 'n': if (qualifier == 'l') { long * ip = va_arg(args, long *); diff --git a/wii/libogc/libogc/lock_supp.c b/wii/libogc/libogc/lock_supp.c index 82ceabbbca..cff6f6835b 100644 --- a/wii/libogc/libogc/lock_supp.c +++ b/wii/libogc/libogc/lock_supp.c @@ -12,7 +12,6 @@ #include "processor.h" #include "mutex.h" - int __libogc_lock_init(int *lock,int recursive) { s32 ret; @@ -51,7 +50,6 @@ int __libogc_lock_acquire(int *lock) return LWP_MutexLock(plock); } - int __libogc_lock_release(int *lock) { mutex_t plock; diff --git a/wii/libogc/libogc/lwp.c b/wii/libogc/libogc/lwp.c index 678792adb7..0f338203e4 100644 --- a/wii/libogc/libogc/lwp.c +++ b/wii/libogc/libogc/lwp.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include "asm.h" @@ -301,7 +300,6 @@ BOOL LWP_ThreadIsSuspended(lwp_t thethread) return state; } - s32 LWP_JoinThread(lwp_t thethread,void **value_ptr) { u32 level; diff --git a/wii/libogc/libogc/lwp_heap.c b/wii/libogc/libogc/lwp_heap.c index a6d76498ce..905fea16c8 100644 --- a/wii/libogc/libogc/lwp_heap.c +++ b/wii/libogc/libogc/lwp_heap.c @@ -6,7 +6,6 @@ #include "lwp_heap.h" - u32 __lwp_heap_init(heap_cntrl *theheap,void *start_addr,u32 size,u32 pg_size) { u32 dsize,level; @@ -48,7 +47,6 @@ void* __lwp_heap_allocate(heap_cntrl *theheap,u32 size) void *ptr; u32 offset,level; - if(size>=(-1-HEAP_BLOCK_USED_OVERHEAD)) return NULL; _CPU_ISR_Disable(level); diff --git a/wii/libogc/libogc/message.c b/wii/libogc/libogc/message.c index 4a529de321..c3ff9ca4a0 100644 --- a/wii/libogc/libogc/message.c +++ b/wii/libogc/libogc/message.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include #include diff --git a/wii/libogc/libogc/mutex.c b/wii/libogc/libogc/mutex.c index 57a83f61fb..8148028b45 100644 --- a/wii/libogc/libogc/mutex.c +++ b/wii/libogc/libogc/mutex.c @@ -27,7 +27,6 @@ distribution. -------------------------------------------------------------*/ - #include #include #include "asm.h" @@ -71,7 +70,6 @@ void __lwp_mutex_init() __lwp_objmgr_initinfo(&_lwp_mutex_objects,LWP_MAX_MUTEXES,sizeof(mutex_st)); } - static __inline__ mutex_st* __lwp_mutex_open(mutex_t lock) { LWP_CHECK_MUTEX(lock); diff --git a/wii/libogc/libogc/network_common.c b/wii/libogc/libogc/network_common.c index 4ab126d2ff..5cd6a1bc7b 100644 --- a/wii/libogc/libogc/network_common.c +++ b/wii/libogc/libogc/network_common.c @@ -11,7 +11,6 @@ #define isspace(c) (c == ' ' || c == '\f' || c == '\n' || c == '\r' || c == '\t' || c == '\v') #endif - /* * Ascii internet address interpretation routine. * The value returned is in network order. @@ -162,7 +161,6 @@ char *inet_ntoa(struct in_addr addr) return str; } - #ifndef BYTE_ORDER #error BYTE_ORDER is not defined #endif diff --git a/wii/libogc/libogc/network_wii.c b/wii/libogc/libogc/network_wii.c index 5c76cd8f49..5ac1f409d9 100644 --- a/wii/libogc/libogc/network_wii.c +++ b/wii/libogc/libogc/network_wii.c @@ -27,7 +27,6 @@ distribution. #if defined(HW_RVL) - #define MAX_IP_RETRIES 100 #define MAX_INIT_RETRIES 32 @@ -1046,7 +1045,6 @@ s32 net_fcntl(s32 s, u32 cmd, u32 flags) if (net_ip_top_fd < 0) return -ENXIO; if (cmd != F_GETFL && cmd != F_SETFL) return -EINVAL; - params[0] = s; params[1] = cmd; params[2] = flags; @@ -1058,7 +1056,6 @@ s32 net_fcntl(s32 s, u32 cmd, u32 flags) return ret; } - /*! * \fn s32 net_poll(struct pollsd *sds, u32 nsds, s64 timeout) * \brief Poll a set of sockets for a set of events. diff --git a/wii/libogc/libogc/newlibc.c b/wii/libogc/libogc/newlibc.c index 4677607e71..d9b17e3b85 100644 --- a/wii/libogc/libogc/newlibc.c +++ b/wii/libogc/libogc/newlibc.c @@ -69,4 +69,3 @@ void __libc_wrapup() } } - diff --git a/wii/libogc/libogc/pad.c b/wii/libogc/libogc/pad.c index 57726e8fb0..6210dc75ef 100644 --- a/wii/libogc/libogc/pad.c +++ b/wii/libogc/libogc/pad.c @@ -700,7 +700,6 @@ u32 PAD_ScanPads() return connected; } - u16 PAD_ButtonsUp(int pad) { if(padPAD_CHAN3 || __pad_keys[pad].chan==-1) return 0; diff --git a/wii/libogc/libogc/sdgecko_io.c b/wii/libogc/libogc/sdgecko_io.c index 19e469b5cf..b491aa08a2 100644 --- a/wii/libogc/libogc/sdgecko_io.c +++ b/wii/libogc/libogc/sdgecko_io.c @@ -310,7 +310,6 @@ static s32 __card_writecmd0(s32 drv_no) return CARDIO_ERROR_NOCARD; } - cnt = 0; while(cnt<20) { if(EXI_ImmEx(drv_no,dummy,128,EXI_WRITE)==0) { @@ -1222,7 +1221,6 @@ s32 sdgecko_readSectors(s32 drv_no,u32 sector_no,u32 num_sectors,void *buf) if(num_sectors<1) return CARDIO_ERROR_INTERNAL; - // Must be 512b, otherwise fail! if(PAGE_SIZE512!=_ioPageSize[drv_no]) { _ioPageSize[drv_no] = PAGE_SIZE512; @@ -1258,7 +1256,6 @@ s32 sdgecko_writeSectors(s32 drv_no,u32 sector_no,u32 num_sectors,const void *bu if(num_sectors<1) return CARDIO_ERROR_INTERNAL; - if(PAGE_SIZE512!=_ioPageSize[drv_no]) { _ioPageSize[drv_no] = PAGE_SIZE512; if((ret=__card_setblocklen(drv_no,_ioPageSize[drv_no]))!=0) return ret; diff --git a/wii/libogc/libogc/semaphore.c b/wii/libogc/libogc/semaphore.c index 9cb7e605c4..0f132531ed 100644 --- a/wii/libogc/libogc/semaphore.c +++ b/wii/libogc/libogc/semaphore.c @@ -25,10 +25,8 @@ must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. - -------------------------------------------------------------*/ - #include #include #include @@ -45,7 +43,6 @@ distribution. return NULL; \ } - typedef struct _sema_st { lwp_obj object; diff --git a/wii/libogc/libogc/stm.c b/wii/libogc/libogc/stm.c index 6bc9066ad5..bcb06752b3 100644 --- a/wii/libogc/libogc/stm.c +++ b/wii/libogc/libogc/stm.c @@ -238,6 +238,4 @@ s32 STM_RebootSystem() return res; } - - #endif /* defined(HW_RVL) */ diff --git a/wii/libogc/libogc/system.c b/wii/libogc/libogc/system.c index 9e76ae3e07..e6519743f4 100644 --- a/wii/libogc/libogc/system.c +++ b/wii/libogc/libogc/system.c @@ -195,7 +195,6 @@ extern void __console_init_ex(void *conbuffer,int tgt_xstart,int tgt_ystart,int extern int clock_gettime(struct timespec *tp); extern void timespec_subtract(const struct timespec *tp_start,const struct timespec *tp_end,struct timespec *result); - extern int __libogc_lock_init(int *lock,int recursive); extern int __libogc_lock_close(int *lock); extern int __libogc_lock_release(int *lock); @@ -1410,7 +1409,6 @@ void SYS_ProtectRange(u32 chan,void *addr,u32 bytes,u32 cntrl) if(cntrl==SYS_PROTECTRDWR) __MaskIrq(IRQMASK(chan)); - _CPU_ISR_Restore(level); } } diff --git a/wii/libogc/libogc/timesupp.c b/wii/libogc/libogc/timesupp.c index 8ca1be8ee9..c8a7413050 100644 --- a/wii/libogc/libogc/timesupp.c +++ b/wii/libogc/libogc/timesupp.c @@ -21,8 +21,6 @@ extern u32 __SYS_GetRTC(u32 *gctime); extern syssram* __SYS_LockSram(); extern u32 __SYS_UnlockSram(u32 write); - - u32 _DEFUN(gettick,(), _NOARGS) @@ -35,7 +33,6 @@ u32 _DEFUN(gettick,(), return result; } - u64 _DEFUN(gettime,(), _NOARGS) { diff --git a/wii/libogc/libogc/usb.c b/wii/libogc/libogc/usb.c index f48c6ff2e4..a0021ce6ba 100644 --- a/wii/libogc/libogc/usb.c +++ b/wii/libogc/libogc/usb.c @@ -28,7 +28,6 @@ distribution. -------------------------------------------------------------*/ - /* Note: There are 3 types of USB interfaces here, the early ones * (V0: /dev/usb/oh0 and /dev/usb/oh1) and two later ones (V5: /dev/usb/ven * and /dev/usb/hid) which are similar but have some small @@ -1346,7 +1345,6 @@ s32 USB_DeviceChangeNotifyAsync(u8 interface_class, usbcallback cb, void* userda else if (interface_class==USB_CLASS_HID && hid_host) ret = add_devicechange_cb(&hid_host->device_change_notify, cb, userdata); - return ret; } diff --git a/wii/libogc/libogc/usbgecko.c b/wii/libogc/libogc/usbgecko.c index c00630a207..6c86ec64d1 100644 --- a/wii/libogc/libogc/usbgecko.c +++ b/wii/libogc/libogc/usbgecko.c @@ -14,7 +14,6 @@ #define _SHIFTR(v, s, w) \ ((u32)(((u32)(v) >> (s)) & ((0x01 << (w)) - 1))) - static u32 usbgecko_inited = 0; static lwpq_t wait_exi_queue[2]; diff --git a/wii/libogc/libogc/video.c b/wii/libogc/libogc/video.c index 9012530ea2..cb88c190e7 100644 --- a/wii/libogc/libogc/video.c +++ b/wii/libogc/libogc/video.c @@ -29,7 +29,6 @@ video.c -- VIDEO subsystem -------------------------------------------------------------*/ - #include #include #include @@ -328,7 +327,6 @@ GXRModeObj TVNtsc480IntAa = } }; - GXRModeObj TVNtsc480Prog = { VI_TVMODE_NTSC_PROG, // viDisplayMode @@ -1234,7 +1232,6 @@ GXRModeObj TVEurgb60Hz480ProgAa = } }; - static const u16 taps[26] = { 0x01F0,0x01DC,0x01AE,0x0174,0x0129,0x00DB, 0x008E,0x0046,0x000C,0x00E2,0x00CB,0x00C0, @@ -2534,7 +2531,6 @@ GXRModeObj *rmode = NULL; return mode; - } u32 VIDEO_GetCurrentLine() diff --git a/wii/libogc/libogc/wiilaunch.c b/wii/libogc/libogc/wiilaunch.c index 1acbffa8b6..367a957e20 100644 --- a/wii/libogc/libogc/wiilaunch.c +++ b/wii/libogc/libogc/wiilaunch.c @@ -76,7 +76,6 @@ typedef struct { #define RETURN_TO_SETTINGS 1 #define RETURN_TO_ARGS 2 - static NANDBootInfo nandboot ATTRIBUTE_ALIGN(32); static StateFlags stateflags ATTRIBUTE_ALIGN(32); diff --git a/wii/libogc/libogc/wiisd.c b/wii/libogc/libogc/wiisd.c index 51c629a20f..de143570de 100644 --- a/wii/libogc/libogc/wiisd.c +++ b/wii/libogc/libogc/wiisd.c @@ -239,7 +239,6 @@ static s32 __sdio_gethcr(u8 reg, u8 size, u32 *val) ret = IOS_Ioctl(__sd0_fd,IOCTL_SDIO_READHCREG,(void*)hcr_query,24,hcr_value,sizeof(u32)); *val = *hcr_value; - return ret; } @@ -256,7 +255,6 @@ static s32 __sdio_sethcr(u8 reg, u8 size, u32 data) hcr_query[5] = 0; ret = IOS_Ioctl(__sd0_fd,IOCTL_SDIO_WRITEHCREG,(void*)hcr_query,24,NULL,0); - return ret; } @@ -356,7 +354,6 @@ static s32 __sd0_getcid() return ret; } - static bool __sd0_initio() { s32 ret; @@ -513,8 +510,6 @@ bool sdio_Startup() return true; } - - bool sdio_Shutdown() { if(__sd0_initialized==0) return false; diff --git a/wii/libogc/libwiikeyboard/ukbdmap.c b/wii/libogc/libwiikeyboard/ukbdmap.c index 56163df230..db11bc912a 100644 --- a/wii/libogc/libwiikeyboard/ukbdmap.c +++ b/wii/libogc/libwiikeyboard/ukbdmap.c @@ -568,7 +568,6 @@ static const keysym_t ukbd_keydesc_be[] = { KC(230), KS_Mode_switch, KS_Multi_key, }; - static const keysym_t ukbd_keydesc_us_dvorak[] = { /* pos command normal shifted */ KC(5), KS_x, diff --git a/wii/libogc/lwbt/bt.h b/wii/libogc/lwbt/bt.h index 475bc6f894..4a506f95cb 100644 --- a/wii/libogc/lwbt/bt.h +++ b/wii/libogc/lwbt/bt.h @@ -14,7 +14,6 @@ * */ - /* * Copyright (c) 2001-2003, Adam Dunkels. * All rights reserved. @@ -98,7 +97,6 @@ # endif /* BYTE_ORDER == BIG_ENDIAN */ #endif /* HTONS */ - /** * Convert 16-bit quantity from host byte order to network byte order. * @@ -114,6 +112,5 @@ u16_t htons(u16_t val); #endif /* __UIP_H__ */ - /** @} */ diff --git a/wii/libogc/lwbt/btarch.h b/wii/libogc/lwbt/btarch.h index 34feb08160..226d0ed118 100644 --- a/wii/libogc/lwbt/btarch.h +++ b/wii/libogc/lwbt/btarch.h @@ -63,7 +63,6 @@ #define MEM_ALIGN(mem) ((void*)(((u32_t)(mem)+MEM_ALIGNMENT-1)&~(u32_t)(MEM_ALIGNMENT-1))) #define MEM_ALIGN_SIZE(size) (((size)+MEM_ALIGNMENT-1)&~(u32_t)(MEM_ALIGNMENT-1)) - #if BYTE_ORDER == BIG_ENDIAN #ifndef htole16 #define htole16 bswap16 diff --git a/wii/libogc/lwbt/bte.c b/wii/libogc/lwbt/bte.c index 9e3ae4e11e..4e7c1d053c 100644 --- a/wii/libogc/lwbt/bte.c +++ b/wii/libogc/lwbt/bte.c @@ -13,7 +13,6 @@ #include "btmemb.h" #include "physbusif.h" - #define STACKSIZE 32768 #define MQ_BOX_SIZE 256 @@ -112,7 +111,6 @@ err_t bte_inquiry_complete(void *arg,struct hci_pcb *pcb,struct hci_inq_res *ire err_t bte_read_stored_link_key_complete(void *arg,struct hci_pcb *pcb,u8_t ogf,u8_t ocf,u8_t result); err_t bte_read_bd_addr_complete(void *arg,struct hci_pcb *pcb,u8_t ogf,u8_t ocf,u8_t result); - MEMB(bte_pcbs,sizeof(struct bte_pcb),MEMP_NUM_BTE_PCB); MEMB(bte_ctrl_reqs,sizeof(struct ctrl_req_t),MEMP_NUM_BTE_CTRLS); diff --git a/wii/libogc/lwbt/btopt.h b/wii/libogc/lwbt/btopt.h index a411fc1da7..90e6df09d8 100644 --- a/wii/libogc/lwbt/btopt.h +++ b/wii/libogc/lwbt/btopt.h @@ -161,7 +161,6 @@ typedef s8 err_t; #define PBUF_ROM_NUM 45 - /** * Determines if statistics support should be compiled in. * @@ -348,5 +347,4 @@ void bt_log(const char *filename,int line_nb,char *msg); outgoing packets. Only the first packet sent when out of credits will be queued */ #define RFCOMM_FLOW_QUEUEING 0 /* Default: 0 */ - #endif /* __BTOPT_H__ */ diff --git a/wii/libogc/lwbt/btpbuf.c b/wii/libogc/lwbt/btpbuf.c index 67be97c152..5b39ec00e8 100644 --- a/wii/libogc/lwbt/btpbuf.c +++ b/wii/libogc/lwbt/btpbuf.c @@ -174,7 +174,6 @@ u8_t btpbuf_header(struct pbuf *p,s16_t hdr_size_inc) if(hdr_size_inc==0 || p==NULL) return 0; - payload = p->payload; if(p->flags==PBUF_FLAG_POOL || p->flags==PBUF_FLAG_RAM) { p->payload = (u8_t*)p->payload-hdr_size_inc; diff --git a/wii/libogc/lwbt/hci.c b/wii/libogc/lwbt/hci.c index b0a4a07f5e..95abae37a7 100644 --- a/wii/libogc/lwbt/hci.c +++ b/wii/libogc/lwbt/hci.c @@ -368,7 +368,6 @@ err_t hci_read_stored_link_key() btmemb_free(&hci_link_key_results,tmpres); } - if((p=btpbuf_alloc(PBUF_RAW,HCI_R_STORED_LINK_KEY_PLEN,PBUF_RAM))==NULL) { ERROR("hci_read_stored_link_keys: Could not allocate memory for pbuf\n"); return ERR_MEM; @@ -905,7 +904,6 @@ err_t hci_link_key_req_reply(struct bd_addr *bdaddr, unsigned char *link_key) return ERR_OK; } - /*-----------------------------------------------------------------------------------*/ /* hci_pin_code_request_neg_reply(): * @@ -1324,7 +1322,6 @@ err_t lp_connect_req(struct bd_addr *bdaddr, u8_t allow_role_switch) bd_addr_set(&(link->bdaddr), bdaddr); HCI_REG(&(hci_active_links), link); - /* Check if module has been discovered in a recent inquiry */ for(inqres = hci_dev->ires; inqres != NULL; inqres = inqres->next) { if(bd_addr_cmp(&inqres->bdaddr, bdaddr)) { diff --git a/wii/libogc/lwbt/hci.h b/wii/libogc/lwbt/hci.h index 6f3010851d..84c370b420 100644 --- a/wii/libogc/lwbt/hci.h +++ b/wii/libogc/lwbt/hci.h @@ -419,7 +419,6 @@ err_t lp_acl_write(struct bd_addr *bdaddr,struct pbuf *p,u16_t len,u8_t pb); err_t lp_connect_req(struct bd_addr *bdaddr, u8_t allow_role_switch); err_t lp_write_flush_timeout(struct bd_addr *bdaddr, u16_t flushto); - #define HCI_EVENT_PIN_REQ(pcb,bdaddr,ret) \ if((pcb)->pin_req != NULL) { \ (ret = (pcb)->pin_req((pcb)->cbarg,(bdaddr))); \ diff --git a/wii/libogc/lwbt/l2cap.c b/wii/libogc/lwbt/l2cap.c index 5fa9c38d56..0ca056eaf6 100644 --- a/wii/libogc/lwbt/l2cap.c +++ b/wii/libogc/lwbt/l2cap.c @@ -413,7 +413,6 @@ void l2cap_process_sig(struct pbuf *q, struct l2cap_hdr *l2caphdr, struct bd_add siglen -= 4; btpbuf_header(p, -4); - LOG("l2cap_process_sig: Congfiguration request, flags = %d\n", flags); /* Find PCB with matching cid */ diff --git a/wii/libogc/lwbt/physbusif.c b/wii/libogc/lwbt/physbusif.c index 669b6a6548..dbed6244a5 100644 --- a/wii/libogc/lwbt/physbusif.c +++ b/wii/libogc/lwbt/physbusif.c @@ -277,7 +277,6 @@ void __ntd_set_pid_vid(u16 vid,u16 pid) __ntd_vid_pid_specified = 1; } - void physbusif_init() { s32 ret; diff --git a/wii/libogc/lwip/arch/gc/netif/gcif.c b/wii/libogc/lwip/arch/gc/netif/gcif.c index 31cbb90257..a2db3c8389 100644 --- a/wii/libogc/lwip/arch/gc/netif/gcif.c +++ b/wii/libogc/lwip/arch/gc/netif/gcif.c @@ -171,7 +171,6 @@ #define BBA_NAPI_WEIGHT 16 - #define X(a,b) b,a struct bba_descr { u32 X(X(next_packet_ptr:12, packet_len:12), status:8); @@ -182,7 +181,6 @@ struct bba_descr { #define _SHIFTR(v, s, w) \ ((u32)(((u32)(v) >> (s)) & ((0x01 << (w)) - 1))) - struct bba_priv { u8 flag; u8 revid; @@ -402,7 +400,6 @@ static inline void bba_ins(u32 reg,void *val,u32 len) bba_deselect(); } - static inline void bba_outs(u32 reg,void *val,u32 len) { bba_select(); diff --git a/wii/libogc/lwip/core/dhcp.c b/wii/libogc/lwip/core/dhcp.c index b79d4e2f2a..0238888edc 100644 --- a/wii/libogc/lwip/core/dhcp.c +++ b/wii/libogc/lwip/core/dhcp.c @@ -697,7 +697,6 @@ static err_t dhcp_decline(struct netif *netif) } #endif - /** * Start the DHCP process, discover a DHCP server. * @@ -751,7 +750,6 @@ static err_t dhcp_discover(struct netif *netif) return result; } - /** * Bind the interface to the offered IP address. * @@ -1146,7 +1144,6 @@ static void dhcp_free_reply(struct dhcp *dhcp) LWIP_DEBUGF(DHCP_DEBUG, ("dhcp_free_reply(): free'd\n")); } - /** * If an incoming DHCP message is in response to us, then trigger the state machine */ @@ -1250,7 +1247,6 @@ static void dhcp_recv(void *arg, struct udp_pcb *pcb, struct pbuf *p, struct ip_ dhcp->p = NULL; } - static err_t dhcp_create_request(struct netif *netif) { struct dhcp *dhcp = netif->dhcp; diff --git a/wii/libogc/lwip/core/inet.c b/wii/libogc/lwip/core/inet.c index 16edc8e937..33557d1e06 100644 --- a/wii/libogc/lwip/core/inet.c +++ b/wii/libogc/lwip/core/inet.c @@ -30,7 +30,6 @@ * */ - /* inet.c * * Functions common to all TCP/IP modules, such as the Internet checksum and the @@ -38,7 +37,6 @@ * */ - #include "lwip/opt.h" #include "lwip/arch.h" diff --git a/wii/libogc/lwip/core/inet6.c b/wii/libogc/lwip/core/inet6.c index 0864a9dd54..2f850d254b 100644 --- a/wii/libogc/lwip/core/inet6.c +++ b/wii/libogc/lwip/core/inet6.c @@ -30,7 +30,6 @@ * */ - /* inet6.c * * Functions common to all TCP/IP modules, such as the Internet checksum and the @@ -38,14 +37,11 @@ * */ - #include "lwip/opt.h" #include "lwip/def.h" #include "lwip/inet.h" - - /* chksum: * * Sums up all 16 bit words in a memory portion. Also includes any odd byte. @@ -61,7 +57,6 @@ chksum(void *dataptr, u16_t len) u16_t *sdataptr = dataptr; u32_t acc; - for(acc = 0; len > 1; len -= 2) { acc += *sdataptr++; } diff --git a/wii/libogc/lwip/core/ipv4/icmp.c b/wii/libogc/lwip/core/ipv4/icmp.c index 02d467e43c..626f2ec620 100644 --- a/wii/libogc/lwip/core/ipv4/icmp.c +++ b/wii/libogc/lwip/core/ipv4/icmp.c @@ -56,7 +56,6 @@ icmp_input(struct pbuf *p, struct netif *inp) ICMP_STATS_INC(icmp.recv); snmp_inc_icmpinmsgs(); - iphdr = p->payload; hlen = IPH_HL(iphdr) * 4; if (pbuf_header(p, -((s16_t)hlen)) || (p->tot_len < sizeof(u16_t)*2)) { @@ -195,9 +194,3 @@ icmp_time_exceeded(struct pbuf *p, enum icmp_te_type t) #endif /* IP_FORWARD */ - - - - - - diff --git a/wii/libogc/lwip/core/ipv4/ip.c b/wii/libogc/lwip/core/ipv4/ip.c index 0746c40094..9de9554d70 100644 --- a/wii/libogc/lwip/core/ipv4/ip.c +++ b/wii/libogc/lwip/core/ipv4/ip.c @@ -59,7 +59,6 @@ # include "lwip/dhcp.h" #endif /* LWIP_DHCP */ - /** * Initializes the IP layer. */ @@ -501,8 +500,3 @@ ip_debug_print(struct pbuf *p) } #endif /* IP_DEBUG */ - - - - - diff --git a/wii/libogc/lwip/core/ipv4/ip_frag.c b/wii/libogc/lwip/core/ipv4/ip_frag.c index f132789229..929fa20d20 100644 --- a/wii/libogc/lwip/core/ipv4/ip_frag.c +++ b/wii/libogc/lwip/core/ipv4/ip_frag.c @@ -46,7 +46,6 @@ #include "lwip/netif.h" #include "lwip/stats.h" - /* * Copy len bytes from offset in pbuf to buffer * diff --git a/wii/libogc/lwip/core/memp.c b/wii/libogc/lwip/core/memp.c index 44fc2531c9..9ca5d24cfb 100644 --- a/wii/libogc/lwip/core/memp.c +++ b/wii/libogc/lwip/core/memp.c @@ -49,8 +49,6 @@ struct memp { struct memp *next; }; - - static struct memp *memp_tab[MEMP_MAX]; static const u16_t memp_sizes[MEMP_MAX] = { @@ -115,7 +113,6 @@ static u8_t memp_memory[(MEMP_NUM_PBUF * MEM_ALIGN_SIZE(sizeof(struct sys_timeout) + sizeof(struct memp)))]; - #if !SYS_LIGHTWEIGHT_PROT static sys_sem mutex; #endif @@ -180,7 +177,6 @@ memp_init(void) LWP_SemInit(&mutex,1,1); #endif - } void * diff --git a/wii/libogc/lwip/core/pbuf.c b/wii/libogc/lwip/core/pbuf.c index bca6792059..ee43ef82e7 100644 --- a/wii/libogc/lwip/core/pbuf.c +++ b/wii/libogc/lwip/core/pbuf.c @@ -178,7 +178,6 @@ pbuf_pool_alloc(void) return p; } - /** * Allocates a pbuf of the given type (possibly a chain for PBUF_POOL type). * @@ -342,7 +341,6 @@ pbuf_alloc(pbuf_layer l, u16_t length, pbuf_flag flag) return p; } - #if PBUF_STATS #define DEC_PBUF_STATS do { --lwip_stats.pbuf.used; } while (0) #else /* PBUF_STATS */ diff --git a/wii/libogc/lwip/core/raw.c b/wii/libogc/lwip/core/raw.c index b378c94c4a..4d554a4903 100644 --- a/wii/libogc/lwip/core/raw.c +++ b/wii/libogc/lwip/core/raw.c @@ -157,7 +157,6 @@ raw_connect(struct raw_pcb *pcb, struct ip_addr *ipaddr) return ERR_OK; } - /** * Set the callback function for received packets that match the * raw PCB's protocol and binding. diff --git a/wii/libogc/lwip/core/stats.c b/wii/libogc/lwip/core/stats.c index 1413b6d82e..148f7b8ac4 100644 --- a/wii/libogc/lwip/core/stats.c +++ b/wii/libogc/lwip/core/stats.c @@ -39,7 +39,6 @@ #include "lwip/stats.h" #include "lwip/mem.h" - #if LWIP_STATS struct stats_ lwip_stats; diff --git a/wii/libogc/lwip/core/sys.c b/wii/libogc/lwip/core/sys.c index a7dbf34dab..e9af1ab751 100644 --- a/wii/libogc/lwip/core/sys.c +++ b/wii/libogc/lwip/core/sys.c @@ -43,8 +43,6 @@ struct sswt_cb sys_sem_t *psem; }; - - void sys_mbox_fetch(sys_mbox_t mbox, void **msg) { @@ -54,7 +52,6 @@ sys_mbox_fetch(sys_mbox_t mbox, void **msg) sys_timeout_handler h; void *arg; - again: timeouts = sys_arch_timeouts(); @@ -136,7 +133,6 @@ sys_sem_wait(sys_sem_t sem) h(arg); } - /* We try again to fetch a message from the mbox. */ goto again; } else { @@ -235,10 +231,6 @@ sys_untimeout(sys_timeout_handler h, void *arg) return; } - - - - static void sswt_handler(void *arg) { @@ -279,7 +271,6 @@ sys_sem_wait_timeout(sys_sem_t sem, u32_t timeout) } - void sys_msleep(u32_t ms) { @@ -290,5 +281,4 @@ sys_msleep(u32_t ms) sys_sem_free(delaysem); } - #endif /* NO_SYS */ diff --git a/wii/libogc/lwip/core/tcp.c b/wii/libogc/lwip/core/tcp.c index 69d10a88e1..4028648bab 100644 --- a/wii/libogc/lwip/core/tcp.c +++ b/wii/libogc/lwip/core/tcp.c @@ -189,7 +189,6 @@ tcp_abort(struct tcp_pcb *pcb) #endif /* LWIP_CALLBACK_API */ void *errf_arg; - /* Figure out on which TCP PCB list we are, and remove us. If we are in an active state, call the receive function associated with the PCB with a NULL argument, and send an RST to the remote end. */ @@ -605,7 +604,6 @@ tcp_slowtmr(void) } } - /* Steps through all of the TIME-WAIT PCBs. */ prev = NULL; pcb = tcp_tw_pcbs; @@ -618,8 +616,6 @@ tcp_slowtmr(void) ++pcb_remove; } - - /* If the PCB should be removed, do it. */ if (pcb_remove) { tcp_pcb_purge(pcb); @@ -749,7 +745,6 @@ tcp_kill_prio(u8_t prio) u32_t inactivity; u8_t mprio; - mprio = TCP_PRIO_MAX; /* We kill the oldest active connection that has lower priority than @@ -772,7 +767,6 @@ tcp_kill_prio(u8_t prio) } } - static void tcp_kill_timewait(void) { @@ -794,8 +788,6 @@ tcp_kill_timewait(void) } } - - struct tcp_pcb * tcp_alloc(u8_t prio) { @@ -928,7 +920,6 @@ tcp_accept(struct tcp_pcb *pcb, } #endif /* LWIP_CALLBACK_API */ - /** * Used to specify the function that should be called periodically * from TCP. The interval is specified in terms of the TCP coarse @@ -1160,12 +1151,3 @@ tcp_pcbs_sane(void) #endif /* TCP_DEBUG */ #endif /* LWIP_TCP */ - - - - - - - - - diff --git a/wii/libogc/lwip/core/tcp_in.c b/wii/libogc/lwip/core/tcp_in.c index 9acf172707..08946aea5c 100644 --- a/wii/libogc/lwip/core/tcp_in.c +++ b/wii/libogc/lwip/core/tcp_in.c @@ -80,7 +80,6 @@ static void tcp_parseopt(struct tcp_pcb *pcb); static err_t tcp_listen_input(struct tcp_pcb_listen *pcb); static err_t tcp_timewait_input(struct tcp_pcb *pcb); - /* tcp_input: * * The initial input processing of TCP. It verifies the TCP header, demultiplexes @@ -163,7 +162,6 @@ tcp_input(struct pbuf *p, struct netif *inp) for an active connection. */ prev = NULL; - for(pcb = tcp_active_pcbs; pcb != NULL; pcb = pcb->next) { LWIP_ASSERT("tcp_input: active pcb->state != CLOSED", pcb->state != CLOSED); LWIP_ASSERT("tcp_input: active pcb->state != TIME-WAIT", pcb->state != TIME_WAIT); @@ -241,7 +239,6 @@ tcp_input(struct pbuf *p, struct netif *inp) LWIP_DEBUGF(TCP_INPUT_DEBUG, ("-+-+-+-+-+-+-+-+-+-+-+-+-+-+\n")); #endif /* TCP_INPUT_DEBUG */ - if (pcb != NULL) { /* The incoming segment belongs to a connection. */ #if TCP_INPUT_DEBUG @@ -305,7 +302,6 @@ tcp_input(struct pbuf *p, struct netif *inp) } } - /* We deallocate the incoming pbuf. If it was buffered by the application, the application should have called pbuf_ref() to increase the reference counter in the pbuf. If so, the buffer @@ -437,7 +433,6 @@ tcp_process(struct tcp_pcb *pcb) u8_t acceptable = 0; err_t err; - err = ERR_OK; /* Process incoming RST segments. */ @@ -631,7 +626,6 @@ tcp_receive(struct tcp_pcb *pcb) u32_t right_wnd_edge; u16_t new_tot_len; - if (flags & TCP_ACK) { right_wnd_edge = pcb->snd_wnd + pcb->snd_wl1; @@ -652,7 +646,6 @@ tcp_receive(struct tcp_pcb *pcb) #endif /* TCP_WND_DEBUG */ } - if (pcb->lastack == ackno) { pcb->acked = 0; @@ -1002,13 +995,11 @@ tcp_receive(struct tcp_pcb *pcb) recv_flags = TF_GOT_FIN; } - pcb->ooseq = cseg->next; tcp_seg_free(cseg); } #endif /* TCP_QUEUE_OOSEQ */ - /* Acknowledge the segment(s). */ tcp_ack(pcb); @@ -1196,4 +1187,3 @@ tcp_parseopt(struct tcp_pcb *pcb) } #endif /* LWIP_TCP */ - diff --git a/wii/libogc/lwip/core/tcp_out.c b/wii/libogc/lwip/core/tcp_out.c index 3437c008f9..0977862ab6 100644 --- a/wii/libogc/lwip/core/tcp_out.c +++ b/wii/libogc/lwip/core/tcp_out.c @@ -666,7 +666,6 @@ tcp_rexmit(struct tcp_pcb *pcb) } - void tcp_keepalive(struct tcp_pcb *pcb) { @@ -711,11 +710,3 @@ tcp_keepalive(struct tcp_pcb *pcb) #endif /* LWIP_TCP */ - - - - - - - - diff --git a/wii/libogc/lwip/core/udp.c b/wii/libogc/lwip/core/udp.c index 7fbc6ec454..e100f3a9f2 100644 --- a/wii/libogc/lwip/core/udp.c +++ b/wii/libogc/lwip/core/udp.c @@ -35,7 +35,6 @@ * */ - /* udp.c * * The code for the User Datagram Protocol UDP. @@ -624,7 +623,6 @@ udp_new(void) { pcb->ttl = UDP_TTL; } - return pcb; } @@ -645,11 +643,3 @@ udp_debug_print(struct udp_hdr *udphdr) #endif /* LWIP_UDP */ - - - - - - - - diff --git a/wii/libogc/lwip/netif/etharp.c b/wii/libogc/lwip/netif/etharp.c index 959f7ba6d0..0295cacf94 100644 --- a/wii/libogc/lwip/netif/etharp.c +++ b/wii/libogc/lwip/netif/etharp.c @@ -448,7 +448,6 @@ etharp_ip_input(struct netif *netif, struct pbuf *p) update_arp_entry(netif, &(hdr->ip.src), &(hdr->eth.src), 0); } - /** * Responds to ARP requests to us. Upon ARP replies to us, add entry to cache * send out queued IP packets. Updates cache with snooped address pairs. diff --git a/wii/libogc/lwip/netif/loopif.c b/wii/libogc/lwip/netif/loopif.c index c83e9f8ed3..ac79615fc6 100644 --- a/wii/libogc/lwip/netif/loopif.c +++ b/wii/libogc/lwip/netif/loopif.c @@ -131,9 +131,3 @@ loopif_init(struct netif *netif) #endif /* LWIP_HAVE_LOOPIF */ - - - - - - diff --git a/wii/libogc/lwip/netif/skeleton/ethernetif.c b/wii/libogc/lwip/netif/skeleton/ethernetif.c index b02d595dac..3ef7d281a9 100644 --- a/wii/libogc/lwip/netif/skeleton/ethernetif.c +++ b/wii/libogc/lwip/netif/skeleton/ethernetif.c @@ -61,7 +61,6 @@ static void ethernetif_input(struct netif *netif); static err_t ethernetif_output(struct netif *netif, struct pbuf *p, struct ip_addr *ipaddr); - static void low_level_init(struct netif *netif) { @@ -95,7 +94,6 @@ low_level_init(struct netif *netif) * */ - static err_t low_level_output(struct ethernetif *ethernetif, struct pbuf *p) { diff --git a/wii/libogc/lwip/network.c b/wii/libogc/lwip/network.c index 0bf282ac0e..74be92da9e 100644 --- a/wii/libogc/lwip/network.c +++ b/wii/libogc/lwip/network.c @@ -559,7 +559,6 @@ static err_t netconn_write(struct netconn *conn,const void *dataptr,u32 size,u8 struct api_msg *msg; u16 len,snd_buf; - LWIP_DEBUGF(API_LIB_DEBUG, ("netconn_write(%d)\n",conn->err)); if(conn==NULL) return ERR_VAL; @@ -1310,7 +1309,6 @@ static void* net_thread(void *arg) udp_init(); tcp_init(); - tb.tv_sec = ARP_TMR_INTERVAL/TB_MSPERSEC; tb.tv_nsec = 0; net_arp_ticks = __lwp_wd_calc_ticks(&tb); @@ -1481,7 +1479,6 @@ s32 if_configex(struct in_addr *local_ip,struct in_addr *netmask,struct in_addr mask.addr = 0; gw.addr = 0; - if(use_dhcp==FALSE) { if( !gateway || gateway->s_addr==0 || !local_ip || local_ip->s_addr==0 @@ -1575,7 +1572,6 @@ s32 if_config(char *local_ip, char *netmask, char *gateway,bool use_dhcp, int ma return ret; } - s32 net_init() { sys_sem sem; diff --git a/wii/libogc/wiiuse/classic.c b/wii/libogc/wiiuse/classic.c index 671522c21c..957c23bad9 100644 --- a/wii/libogc/wiiuse/classic.c +++ b/wii/libogc/wiiuse/classic.c @@ -133,7 +133,6 @@ int classic_ctrl_handshake(struct wiimote_t* wm, struct classic_ctrl_t* cc, ubyt return 1; } - /** * @brief The classic controller disconnected. * @@ -144,8 +143,6 @@ void classic_ctrl_disconnected(struct classic_ctrl_t* cc) memset(cc, 0, sizeof(struct classic_ctrl_t)); } - - /** * @brief Handle classic controller event. * @@ -200,7 +197,6 @@ void classic_ctrl_event(struct classic_ctrl_t* cc, ubyte* msg) { #endif } - /** * @brief Find what buttons are pressed. * diff --git a/wii/libogc/wiiuse/definitions.h b/wii/libogc/wiiuse/definitions.h index 04dc5be6d8..e34e8e7cbc 100644 --- a/wii/libogc/wiiuse/definitions.h +++ b/wii/libogc/wiiuse/definitions.h @@ -40,7 +40,6 @@ #define WII_DEBUG(fmt, ...) #endif - /* Convert between radians and degrees */ #define RAD_TO_DEGREE(r) ((r * 180.0f) / WIIMOTE_PI) #define DEGREE_TO_RAD(d) (d * (WIIMOTE_PI / 180.0f)) diff --git a/wii/libogc/wiiuse/dynamics.c b/wii/libogc/wiiuse/dynamics.c index 3ead4055c2..0a8b08dfa2 100644 --- a/wii/libogc/wiiuse/dynamics.c +++ b/wii/libogc/wiiuse/dynamics.c @@ -117,7 +117,6 @@ void calculate_orientation(struct accel_t* ac, struct vec3w_t* accel, struct ori } } - /** * @brief Calculate the gravity forces on each axis. * @@ -199,7 +198,6 @@ void calc_joystick_state(struct joystick_t* js, float x, float y) { js->mag = hypotf(rx, ry); } - void apply_smoothing(struct accel_t* ac, struct orient_t* orient, int type) { switch (type) { case SMOOTH_ROLL: diff --git a/wii/libogc/wiiuse/events.c b/wii/libogc/wiiuse/events.c index 6f7a547f52..1fd2276a45 100644 --- a/wii/libogc/wiiuse/events.c +++ b/wii/libogc/wiiuse/events.c @@ -26,7 +26,6 @@ #include "ir.h" #include "io.h" - static void event_data_read(struct wiimote_t *wm,ubyte *msg) { ubyte err; diff --git a/wii/libogc/wiiuse/io_wii.c b/wii/libogc/wiiuse/io_wii.c index 34fafc108c..2c579a0aa9 100644 --- a/wii/libogc/wiiuse/io_wii.c +++ b/wii/libogc/wiiuse/io_wii.c @@ -155,7 +155,6 @@ void wiiuse_sensorbar_enable(int enable) __wiiuse_sensorbar_enable(enable); } - void wiiuse_init_cmd_queue(struct wiimote_t *wm) { u32 size; diff --git a/wii/libogc/wiiuse/ir.c b/wii/libogc/wiiuse/ir.c index 33171f48c8..6fa99ddafa 100644 --- a/wii/libogc/wiiuse/ir.c +++ b/wii/libogc/wiiuse/ir.c @@ -124,7 +124,6 @@ static int ir_correct_for_bounds(float* x, float* y, enum aspect_t aspect, int o return 0; } - /** * @brief Interpolate the point to the user defined virtual screen resolution. */ @@ -303,7 +302,6 @@ void wiiuse_set_aspect_ratio(struct wiimote_t* wm, enum aspect_t aspect) { wiiuse_set_ir_position(wm, wm->ir.pos); } - /** * @brief Set the IR sensitivity. * @@ -359,7 +357,6 @@ void wiiuse_set_ir_sensitivity(struct wiimote_t* wm, int level) { WIIUSE_DEBUG("Set IR sensitivity to level %i (unid %i)", level, wm->unid); } - /** * @brief Calculate the data from the IR spots. Basic IR mode. * diff --git a/wii/libogc/wiiuse/motion_plus.c b/wii/libogc/wiiuse/motion_plus.c index 77022314ac..7700b41da4 100644 --- a/wii/libogc/wiiuse/motion_plus.c +++ b/wii/libogc/wiiuse/motion_plus.c @@ -56,7 +56,6 @@ static void wiiuse_set_motion_plus_clear1(struct wiimote_t *wm,ubyte *data,uword wiiuse_write_data(wm,WM_EXP_MEM_ENABLE1,&val,1,wiiuse_set_motion_plus_clear2); } - void wiiuse_set_motion_plus(struct wiimote_t *wm, int status) { ubyte val; diff --git a/wii/libogc/wiiuse/speaker.c b/wii/libogc/wiiuse/speaker.c index 167252391d..1d30453ccb 100644 --- a/wii/libogc/wiiuse/speaker.c +++ b/wii/libogc/wiiuse/speaker.c @@ -93,7 +93,6 @@ void wiiuse_set_speaker(struct wiimote_t *wm,int status) } } - buf = 0x04; wiiuse_sendcmd(wm,WM_CMD_SPEAKER_MUTE,&buf,1,NULL); diff --git a/wii/libogc/wiiuse/wiiuse_internal.h b/wii/libogc/wiiuse/wiiuse_internal.h index cfe343e493..72f27dc786 100644 --- a/wii/libogc/wiiuse/wiiuse_internal.h +++ b/wii/libogc/wiiuse/wiiuse_internal.h @@ -160,7 +160,6 @@ #define WM_ASPECT_4_3_X 560 #define WM_ASPECT_4_3_Y 420 - /** * Expansion stuff */ diff --git a/wiiu/fs/sd_fat_devoptab.c b/wiiu/fs/sd_fat_devoptab.c index 9bc16f8e20..3d0c0587ff 100644 --- a/wiiu/fs/sd_fat_devoptab.c +++ b/wiiu/fs/sd_fat_devoptab.c @@ -203,7 +203,6 @@ static int sd_fat_open_r (struct _reent *r, void *fileStruct, const char *path, return -1; } - static int sd_fat_close_r (struct _reent *r, void* fd) { sd_fat_file_state_t *file = (sd_fat_file_state_t *)fd; @@ -383,7 +382,6 @@ static ssize_t sd_fat_read_r (struct _reent *r, void* fd, char *ptr, size_t len) return done; } - static int sd_fat_fstat_r (struct _reent *r, void* fd, struct stat *st) { sd_fat_file_state_t *file = (sd_fat_file_state_t *)fd; @@ -540,7 +538,6 @@ static int sd_fat_unlink_r (struct _reent *r, const char *name) return -1; } - int result = FSRemove(dev->pClient, dev->pCmd, real_path, -1); free(real_path); diff --git a/wiiu/gx2_shader_inl.h b/wiiu/gx2_shader_inl.h index d788777068..80f5889f4e 100644 --- a/wiiu/gx2_shader_inl.h +++ b/wiiu/gx2_shader_inl.h @@ -47,7 +47,6 @@ #define CF_ALLOC_EXPORT_WORD1_BUF(arraySize, writeMask, inst) \ to_LE(arraySize | (writeMask << 12) | (inst << 23) | (1 << 31)) - #define ALU_SRC_KCACHE0_BASE 0x80 #define ALU_SRC_KCACHE1_BASE 0xA0 #define CF_KCACHE_BANK_LOCK_1 0x1 @@ -69,7 +68,6 @@ #define KCACHE0(bank, mode) | to_QWORD(CF_ALU_WORD0(0, bank, 0, mode), 0) #define KCACHE1(bank, mode) | to_QWORD(CF_ALU_WORD0(0, 0, bank, 0), CF_ALU_WORD1(mode,0, 0, 0, 0, 0)) - #define DEACTIVATE 1 #define UPDATE_EXEC_MASK(mode) | to_QWORD(0, to_LE(mode << 2)) #define UPDATE_PRED | to_QWORD(0, to_LE(1ull << 3)) @@ -176,7 +174,6 @@ #define SCL_212 | to_QWORD(0, to_LE(ALU_SCL_212 << 18)) #define SCL_221 | to_QWORD(0, to_LE(ALU_SCL_221 << 18)) - #define FETCH_TYPE(x) x #define MINI(x) ((x) - 1) #define MEGA(x) (MINI(x) | 0x80000000) @@ -186,7 +183,6 @@ #define INSTANCE_DATA 1 #define NO_INDEX_OFFSET 2 - /* CF defines */ #define CF_COND_ACTIVE 0x0 #define CF_COND_FALSE 0x1 @@ -295,7 +291,6 @@ #define _R126 _R(0x7E) #define _R127 _R(0x7F) - /* texture */ #define _t(x) x #define _t0 _t(0x0) @@ -306,7 +301,6 @@ #define _b(x) x - #define CALL_FS to_QWORD(CF_DWORD0(0), CF_DWORD1(0,0,0,0,0,CF_INST_CALL_FS)) #define TEX(addr, cnt) to_QWORD(CF_DWORD0(addr), CF_DWORD1(0x0, 0x0, CF_COND_ACTIVE, (cnt - 1), 0x0, CF_INST_TEX)) @@ -458,7 +452,6 @@ TEX_WORD1(dstReg, 0x0, dstSelX, dstSelY, dstSelZ, dstSelW, 0x0, TEX_NORMALIZED, TEX_NORMALIZED, TEX_NORMALIZED, TEX_NORMALIZED)), \ to_QWORD(TEX_WORD2(0x0, 0x0, 0x0, samplerID, _x, _y, _z, _x), 0x00000000) - #define VTX_FETCH(dstReg, dstSelX, dstSelY, dstSelZ, dstSelW, srcReg, srcSelX, buffer_id, type, mega, offset) \ to_QWORD(VTX_WORD0(VTX_INST_FETCH, type, buffer_id, srcReg, srcSelX, mega), VTX_WORD1(dstReg, dstSelX, dstSelY, dstSelZ, dstSelW)) , \ to_QWORD(VTX_WORD2(offset, (mega >> 31)), 0x00000000) diff --git a/wiiu/hbl.h b/wiiu/hbl.h index 939bbba9e3..bb35d8d8e6 100644 --- a/wiiu/hbl.h +++ b/wiiu/hbl.h @@ -13,7 +13,6 @@ extern "C" { #define ARGV_PTR (*(void* volatile *)(MEM_BASE + 0x1300 + 0x80)) - #define MAKE_MAGIC(c0, c1, c2, c3) (((c0) << 24) |((c1) << 16) |((c2) << 8) | c3) #define ARGV_MAGIC MAKE_MAGIC('_', 'a', 'r', 'g') diff --git a/wiiu/include/netdb.h b/wiiu/include/netdb.h index 3fb5898849..c6ee9e25a7 100644 --- a/wiiu/include/netdb.h +++ b/wiiu/include/netdb.h @@ -17,7 +17,6 @@ typedef uint32_t socklen_t; #define NI_MAXHOST 1025 #define NI_MAXSERV 32 - struct addrinfo { int ai_flags; /* AI_PASSIVE, AI_CANONNAME, AI_NUMERICHOST, .. */ @@ -34,7 +33,6 @@ int getaddrinfo(const char *node, const char *service, struct addrinfo *hints, s void freeaddrinfo(struct addrinfo *__ai); int getnameinfo(const struct sockaddr *sa, socklen_t salen, char *host, socklen_t hostlen, char *serv, socklen_t servlen, int flags); - #ifdef __cplusplus } #endif diff --git a/wiiu/include/sys/socket.h b/wiiu/include/sys/socket.h index 322d6bb905..24eabff7f1 100644 --- a/wiiu/include/sys/socket.h +++ b/wiiu/include/sys/socket.h @@ -24,7 +24,6 @@ extern "C" { #define SO_NBIO 0x1014 #define SO_NONBLOCK 0x1016 - /* return codes */ #define SO_SUCCESS 0 #define SO_EWOULDBLOCK 6 diff --git a/wiiu/include/wiiu/ac.h b/wiiu/include/wiiu/ac.h index 962b3ad8f0..c58fab8470 100644 --- a/wiiu/include/wiiu/ac.h +++ b/wiiu/include/wiiu/ac.h @@ -6,7 +6,6 @@ * System Preferences. */ - typedef int ACResult; enum { AC_FAILED = -1, diff --git a/wiiu/include/wiiu/gx2/draw.h b/wiiu/include/wiiu/gx2/draw.h index 85f2ff4c59..7235e73044 100644 --- a/wiiu/include/wiiu/gx2/draw.h +++ b/wiiu/include/wiiu/gx2/draw.h @@ -2,7 +2,6 @@ #include #include "enum.h" - #ifdef __cplusplus extern "C" { #endif diff --git a/wiiu/include/wiiu/gx2/sampler.h b/wiiu/include/wiiu/gx2/sampler.h index 8b7f23db13..622bd637b5 100644 --- a/wiiu/include/wiiu/gx2/sampler.h +++ b/wiiu/include/wiiu/gx2/sampler.h @@ -6,7 +6,6 @@ extern "C" { #endif - typedef struct GX2Sampler { uint32_t regs[3]; diff --git a/wiiu/include/wiiu/gx2/shaders.h b/wiiu/include/wiiu/gx2/shaders.h index ceb883e7af..d0e5ccee3b 100644 --- a/wiiu/include/wiiu/gx2/shaders.h +++ b/wiiu/include/wiiu/gx2/shaders.h @@ -94,7 +94,6 @@ typedef struct GX2VertexShader unsigned enable: 1; } vgt_primitiveid_en; - struct { unsigned : 18; diff --git a/wiiu/include/wiiu/gx2r/resource.h b/wiiu/include/wiiu/gx2r/resource.h index 89be225214..dd945372f6 100644 --- a/wiiu/include/wiiu/gx2r/resource.h +++ b/wiiu/include/wiiu/gx2r/resource.h @@ -36,7 +36,6 @@ typedef enum GX2R_RESOURCE_LOCKED = 1 << 30, } GX2RResourceFlags; - #ifdef __cplusplus } #endif diff --git a/wiiu/include/wiiu/kpad.h b/wiiu/include/wiiu/kpad.h index 27988fba26..799ad8b64f 100644 --- a/wiiu/include/wiiu/kpad.h +++ b/wiiu/include/wiiu/kpad.h @@ -63,7 +63,6 @@ typedef struct _KPADData u32 unused_7[16]; } KPADData; - void KPADInit (void); void KPADShutdown(void); s32 KPADRead(s32 chan, void * data, u32 size); @@ -93,7 +92,6 @@ enum { typedef void (*WPADConnectCallback) (WPADChannel channel, WPADError reason); - #ifdef __cplusplus } #endif diff --git a/wiiu/include/wiiu/mp/taskqueue.h b/wiiu/include/wiiu/mp/taskqueue.h index 700393d29f..c38bbed947 100644 --- a/wiiu/include/wiiu/mp/taskqueue.h +++ b/wiiu/include/wiiu/mp/taskqueue.h @@ -24,7 +24,6 @@ typedef enum MP_TASK_QUEUE_STATE_FINISHED = 1 << 4, } MPTaskQueueState; - typedef uint32_t (*MPTaskFunc)(uint32_t, uint32_t); #pragma pack(push, 1) diff --git a/wiiu/include/wiiu/os/thread.h b/wiiu/include/wiiu/os/thread.h index a21eef07aa..b962b1acc5 100644 --- a/wiiu/include/wiiu/os/thread.h +++ b/wiiu/include/wiiu/os/thread.h @@ -111,7 +111,6 @@ typedef struct OSFastMutexQueue OSFastMutex *tail; } OSFastMutexQueue; - typedef struct { OSThread *prev; diff --git a/wiiu/include/wiiu/os/time.h b/wiiu/include/wiiu/os/time.h index 79349b0d7b..e8ff34254a 100644 --- a/wiiu/include/wiiu/os/time.h +++ b/wiiu/include/wiiu/os/time.h @@ -37,7 +37,6 @@ typedef struct int32_t tm_year; }OSCalendarTime; - OSTime OSGetTime(); OSTime OSGetSystemTime(); OSTick OSGetTick(); diff --git a/wiiu/include/wiiu/syshid.h b/wiiu/include/wiiu/syshid.h index 664e52eef6..354df86f0e 100644 --- a/wiiu/include/wiiu/syshid.h +++ b/wiiu/include/wiiu/syshid.h @@ -35,7 +35,6 @@ typedef void (*HIDCallback)(uint32_t handle,int32_t error,uint8_t *p_buffer,uint extern "C" { #endif - int32_t HIDSetup(void); diff --git a/wiiu/include/wiiu/vpad.h b/wiiu/include/wiiu/vpad.h index 2c6765cbc3..60d27deaa1 100644 --- a/wiiu/include/wiiu/vpad.h +++ b/wiiu/include/wiiu/vpad.h @@ -96,7 +96,6 @@ typedef enum VPADTouchPadValidity VPAD_INVALID_Y = 0x2, } VPADTouchPadValidity; - typedef enum VPADReadError { VPAD_READ_SUCCESS = 0, diff --git a/wiiu/shader_utils.c b/wiiu/shader_utils.c index f4c7b98058..402a414e3b 100644 --- a/wiiu/shader_utils.c +++ b/wiiu/shader_utils.c @@ -98,7 +98,6 @@ void GX2SetShader(GX2Shader *shader) GX2SetGeometryShader(&shader->gs); } - void dump_vs_data(GX2VertexShader* vs) { @@ -233,7 +232,6 @@ void check_shader(const void *shader_, u32 shader_size, const void *org_, u32 or printf("\nsize mismatch : 0x%08X should be 0x%08X", shader_size, org_size); } - for (int i = 0; i < shader_size / 4; i++) { if (shader[i] != org[i]) diff --git a/wiiu/shader_utils.h b/wiiu/shader_utils.h index e03b3af704..10f5da367b 100644 --- a/wiiu/shader_utils.h +++ b/wiiu/shader_utils.h @@ -45,7 +45,6 @@ __attribute__((scalar_storage_order ("little-endian"))) }; }GX2_vec4; - typedef union { struct @@ -77,7 +76,6 @@ void GX2SetShader(GX2Shader* shader); void check_shader(const void* shader_, u32 shader_size, const void* org_, u32 org_size, const char* name); void check_shader_verbose(u32* shader, u32 shader_size, u32* org, u32 org_size, const char* name); - typedef struct { GX2VertexShader* vs; diff --git a/wiiu/slang/Makefile b/wiiu/slang/Makefile index 64ad2fe4ff..2a0c6ba139 100644 --- a/wiiu/slang/Makefile +++ b/wiiu/slang/Makefile @@ -44,9 +44,6 @@ SLANG_SHADERS := $(call rwildcard,$(SLANG_DIR)/,*.slang) SLANG_SHADERS := $(filter-out $(BLACKLIST),$(SLANG_SHADERS)) SLANG_SHADERS := $(SLANG_SHADERS:.slang=.gsh) - - - all: $(SLANG_SHADERS) parser: $(SLANG_PARSER) diff --git a/wiiu/slang/main.c b/wiiu/slang/main.c index 025495feaa..54a05afddf 100644 --- a/wiiu/slang/main.c +++ b/wiiu/slang/main.c @@ -29,7 +29,6 @@ int main(int argc, const char** argv) ps_out = argv[i + 1]; } - if(!slang || !vs_out || !ps_out || (!vs_asm && ps_asm) || (vs_asm && !ps_asm)) { printf("Usage :\n"); @@ -97,7 +96,6 @@ int main(int argc, const char** argv) continue; } - char* layout = strstr(line, "layout("); if(layout) { @@ -113,10 +111,6 @@ int main(int argc, const char** argv) line = layout; } - - - - if(vson) { fwrite(line, 1, strlen(line),vs_out_fp); @@ -139,4 +133,3 @@ int main(int argc, const char** argv) return 0; } - diff --git a/wiiu/slang/slang-parse.cpp b/wiiu/slang/slang-parse.cpp index 582f0e8375..f5bdfef3c6 100644 --- a/wiiu/slang/slang-parse.cpp +++ b/wiiu/slang/slang-parse.cpp @@ -1,11 +1,9 @@ - #include #include #include #include - int main(int argc, const char** argv) { const char* slang_fn = NULL; @@ -31,7 +29,6 @@ int main(int argc, const char** argv) verbose = true; } - if(!slang_fn || !vs_out_fn || !ps_out_fn || (!vs_asm_fn && ps_asm_fn) || (vs_asm_fn && !ps_asm_fn)) { printf("Usage :\n"); @@ -265,7 +262,5 @@ int main(int argc, const char** argv) fs << ps.str(); } - - return 0; } diff --git a/wiiu/system/memory.c b/wiiu/system/memory.c index d0269411d1..aa19aeedb5 100644 --- a/wiiu/system/memory.c +++ b/wiiu/system/memory.c @@ -111,7 +111,6 @@ void * _valloc_r(struct _reent *r, size_t size) return _memalign_r(r, 64, size); } - /* some wrappers */ void * MEM2_alloc(unsigned int size, unsigned int align)