gs-merge: remove initial plugin subsystem

This commit is contained in:
Gauvain 'GovanifY' Roussel-Tarbouriech 2021-04-30 06:05:13 +02:00 committed by Kojin
parent fbffa1c7bc
commit 587a893a0e
205 changed files with 0 additions and 4397 deletions

View File

@ -28,9 +28,7 @@ check_compiler_version("7.0" "7.0")
include(GNUInstallDirs)
# BuildParameters Must be done before SearchForStuff
include(BuildParameters)
# SearchForStuff be done before SelectPcsx2Plugins
include(SearchForStuff)
include(SelectPcsx2Plugins)
# Must be done after SearchForStuff
get_git_version_info()

View File

@ -27,8 +27,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tools", "Tools", "{2D6F0A62
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "pcsx2", "pcsx2\windows\VCprojects\pcsx2.vcxproj", "{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GSdx", "plugins\GSdx\GSdx.vcxproj", "{18E42F6F-3A62-41EE-B42F-79366C4F1E95}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SoundTouch", "3rdparty\soundtouch\SoundTouch.vcxproj", "{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "zlib", "3rdparty\zlib\zlib.vcxproj", "{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}"
@ -97,22 +95,6 @@ Global
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|Win32.Build.0 = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|x64.ActiveCfg = Release|x64
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|x64.Build.0 = Release|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.ActiveCfg = Debug|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.Build.0 = Debug|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|x64.ActiveCfg = Debug|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|x64.Build.0 = Debug|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Devel|Win32.ActiveCfg = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Devel|Win32.Build.0 = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Devel|x64.ActiveCfg = Release|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Devel|x64.Build.0 = Release|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release AVX2|Win32.ActiveCfg = Release AVX2|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release AVX2|Win32.Build.0 = Release AVX2|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release AVX2|x64.ActiveCfg = Release AVX2|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release AVX2|x64.Build.0 = Release AVX2|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|Win32.ActiveCfg = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|Win32.Build.0 = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|x64.ActiveCfg = Release|x64
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|x64.Build.0 = Release|x64
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.ActiveCfg = Debug|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.Build.0 = Debug|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|x64.ActiveCfg = Debug|x64
@ -439,7 +421,6 @@ Global
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{0FADC26C-0E9D-4DD7-84B1-BF4F7754E90C} = {88F517F9-CE1C-4005-9BDF-4481FEB55053}
{18E42F6F-3A62-41EE-B42F-79366C4F1E95} = {703FD00B-D7A0-41E3-BD03-CEC86B385DAF}
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{A51123F5-9505-4EAE-85E7-D320290A272C} = {88F517F9-CE1C-4005-9BDF-4481FEB55053}

View File

@ -21,7 +21,6 @@ find_package(OpenGL)
find_package(PNG)
find_package(Vtune)
# The requirement of wxWidgets is checked in SelectPcsx2Plugins module
# Does not require the module (allow to compile non-wx plugins)
# Force the unicode build (the variable is only supported on cmake 2.8.3 and above)
# Warning do not put any double-quote for the argument...

View File

@ -1,100 +0,0 @@
#-------------------------------------------------------------------------------
# Dependency message print
#-------------------------------------------------------------------------------
set(msg_dep_common_libs "check these libraries -> wxWidgets (>=3.0), aio")
set(msg_dep_pcsx2 "check these libraries -> wxWidgets (>=3.0), gtk2, zlib (>=1.2.4), pcsx2 common libs")
set(msg_dep_gsdx "check these libraries -> opengl, png (>=1.2), zlib (>=1.2.4), X11, liblzma")
macro(print_dep str dep)
if (PACKAGE_MODE)
message(FATAL_ERROR "${str}:${dep}")
else()
message(STATUS "${str}:${dep}")
endif()
endmacro(print_dep)
#-------------------------------------------------------------------------------
# Pcsx2 core & common libs
#-------------------------------------------------------------------------------
# Check for additional dependencies.
# If all dependencies are available, including OS, build it
#-------------------------------------------------------------------------------
if (GTK2_FOUND OR GTK3_FOUND)
set(GTKn_FOUND TRUE)
elseif(APPLE) # Not we have but that we don't change all if(gtkn) entries
set(GTKn_FOUND TRUE)
else()
set(GTKn_FOUND FALSE)
endif()
if(SDL_FOUND OR SDL2_FOUND)
set(SDLn_FOUND TRUE)
else()
set(SDLn_FOUND FALSE)
endif()
#---------------------------------------
# Common libs
# requires: -wx
#---------------------------------------
if(wxWidgets_FOUND)
set(common_libs TRUE)
elseif(NOT EXISTS "${CMAKE_SOURCE_DIR}/common/src")
set(common_libs FALSE)
else()
set(common_libs FALSE)
print_dep("Skip build of common libraries: missing dependencies" "${msg_dep_common_libs}")
endif()
#---------------------------------------
# Pcsx2 core
# requires: -wx
# -gtk2 (linux)
# -zlib
# -common_libs
# -aio
#---------------------------------------
# Common dependancy
if(wxWidgets_FOUND AND ZLIB_FOUND AND common_libs AND NOT (Linux AND NOT AIO_FOUND))
set(pcsx2_core TRUE)
elseif(NOT EXISTS "${CMAKE_SOURCE_DIR}/pcsx2")
set(pcsx2_core FALSE)
else()
set(pcsx2_core FALSE)
print_dep("Skip build of pcsx2 core: missing dependencies" "${msg_dep_pcsx2}")
endif()
# Linux, BSD, use gtk2, but not OSX
if(UNIX AND pcsx2_core AND NOT GTKn_FOUND AND NOT APPLE)
set(pcsx2_core FALSE)
print_dep("Skip build of pcsx2 core: missing dependencies" "${msg_dep_pcsx2}")
endif()
#-------------------------------------------------------------------------------
# Plugins
#-------------------------------------------------------------------------------
# Check all plugins for additional dependencies.
# If all dependencies of a plugin are available, including OS, the plugin will
# be build.
#-------------------------------------------------------------------------------
#---------------------------------------
# GSdx
#---------------------------------------
# requires: -OpenGL
# -PNG
# -X11
# -zlib
#---------------------------------------
if(OPENGL_FOUND AND X11_FOUND AND GTKn_FOUND AND ZLIB_FOUND AND PNG_FOUND AND FREETYPE_FOUND AND LIBLZMA_FOUND AND ((EGL_FOUND AND X11_XCB_FOUND) OR APPLE))
set(GSdx TRUE)
elseif(NOT EXISTS "${CMAKE_SOURCE_DIR}/plugins/GSdx")
set(GSdx FALSE)
else()
set(GSdx FALSE)
print_dep("Skip build of GSdx: missing dependencies" "${msg_dep_gsdx}")
endif()
#---------------------------------------
#-------------------------------------------------------------------------------

View File

@ -1,237 +0,0 @@
/* PCSX2 - PS2 Emulator for PCs
* Copyright (C) 2002-2010 PCSX2 Dev Team
*
* PCSX2 is free software: you can redistribute it and/or modify it under the terms
* of the GNU Lesser General Public License as published by the Free Software Found-
* ation, either version 3 of the License, or (at your option) any later version.
*
* PCSX2 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 PCSX2.
* If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef __PS2EDEFS_H__
#define __PS2EDEFS_H__
/*
* PS2E Definitions v0.6.2 (beta)
*
* Author: linuzappz@hotmail.com
* shadowpcsx2@yahoo.gr
* florinsasu@hotmail.com
*/
/*
Notes:
* Since this is still beta things may change.
* OSflags:
__linux__ (linux OS)
_WIN32 (win32 OS)
* common return values (for ie. GSinit):
0 - success
-1 - error
* reserved keys:
F1 to F10 are reserved for the emulator
* plugins should NOT change the current
working directory.
(on win32, add flag OFN_NOCHANGEDIR for
GetOpenFileName)
*/
#include "Pcsx2Defs.h"
///////////////////////////////////////////////////////////////////////
// freeze modes:
#define FREEZE_LOAD 0
#define FREEZE_SAVE 1
#define FREEZE_SIZE 2
// event values:
#define KEYPRESS 1
#define KEYRELEASE 2
typedef struct
{
int size;
s8 *data;
} freezeData;
typedef struct _keyEvent
{
u32 key;
u32 evt;
} keyEvent;
///////////////////////////////////////////////////////////////////////
// PS2EgetLibType returns (may be OR'd)
#define PS2E_LT_GS 0x01
// PS2EgetLibVersion2 (high 16 bits)
#define PS2E_GS_VERSION 0x0006
// key values:
/* key values must be OS dependant:
win32: the VK_XXX will be used (WinUser)
linux: the XK_XXX will be used (XFree86)
*/
// for 64bit compilers
typedef char __keyEvent_Size__[(sizeof(keyEvent) == 8) ? 1 : -1];
#ifdef __cplusplus
extern "C" {
#endif
/* GS plugin API */
// if this file is included with this define
// the next api will not be skipped by the compiler
#if defined(GSdefs) || defined(BUILTIN_GS_PLUGIN)
// basic funcs
s32 CALLBACK GSinit();
s32 CALLBACK GSopen(void *pDsp, const char *Title, int multithread);
void CALLBACK GSclose();
void CALLBACK GSshutdown();
void CALLBACK GSsetSettingsDir(const char *dir);
void CALLBACK GSsetLogDir(const char *dir);
void CALLBACK GSvsync(int field);
void CALLBACK GSgifTransfer(const u32 *pMem, u32 addr);
void CALLBACK GSgifTransfer1(u32 *pMem, u32 addr);
void CALLBACK GSgifTransfer2(u32 *pMem, u32 size);
void CALLBACK GSgifTransfer3(u32 *pMem, u32 size);
void CALLBACK GSgetLastTag(u64 *ptag); // returns the last tag processed (64 bits)
void CALLBACK GSgifSoftReset(u32 mask);
void CALLBACK GSreadFIFO(u64 *mem);
void CALLBACK GSinitReadFIFO(u64 *mem);
void CALLBACK GSreadFIFO2(u64 *mem, int qwc);
void CALLBACK GSinitReadFIFO2(u64 *mem, int qwc);
// extended funcs
// GSkeyEvent gets called when there is a keyEvent from the PAD plugin
void CALLBACK GSkeyEvent(keyEvent *ev);
void CALLBACK GSchangeSaveState(int, const char *filename);
void CALLBACK GSmakeSnapshot(char *path);
void CALLBACK GSmakeSnapshot2(char *pathname, int *snapdone, int savejpg);
void CALLBACK GSirqCallback(void (*callback)());
void CALLBACK GSsetBaseMem(void *);
void CALLBACK GSsetGameCRC(int crc, int gameoptions);
// controls frame skipping in the GS, if this routine isn't present, frame skipping won't be done
void CALLBACK GSsetFrameSkip(int frameskip);
// Starts recording GS frame data
// returns true if successful
bool CALLBACK GSsetupRecording(std::string& filename);
// Stops recording GS frame data
void CALLBACK GSendRecording();
void CALLBACK GSreset();
//deprecated: GSgetTitleInfo was used in PCSX2 but no plugin supported it prior to r4070:
//void CALLBACK GSgetTitleInfo( char dest[128] );
void CALLBACK GSgetTitleInfo2(char *dest, size_t length);
void CALLBACK GSwriteCSR(u32 value);
s32 CALLBACK GSfreeze(int mode, freezeData *data);
void CALLBACK GSconfigure();
void CALLBACK GSabout();
s32 CALLBACK GStest();
#endif
// might be useful for emulators
#ifdef PLUGINtypedefs
typedef u32(CALLBACK *_PS2EgetLibType)(void);
typedef u32(CALLBACK *_PS2EgetLibVersion2)(u32 type);
typedef char *(CALLBACK *_PS2EgetLibName)(void);
// GS
// NOTE: GSreadFIFOX/GSwriteCSR functions CANNOT use XMM/MMX regs
// If you want to use them, need to save and restore current ones
typedef void(CALLBACK *_GSosdLog)(const char *utf8, u32 color);
typedef void(CALLBACK *_GSosdMonitor)(const char *key, const char *value, u32 color);
typedef s32(CALLBACK *_GSopen)(void *pDsp, const char *Title, int multithread);
typedef s32(CALLBACK *_GSopen2)(void *pDsp, u32 flags);
typedef void(CALLBACK *_GSvsync)(int field);
typedef void(CALLBACK *_GSgifTransfer)(const u32 *pMem, u32 size);
typedef void(CALLBACK *_GSgifTransfer1)(u32 *pMem, u32 addr);
typedef void(CALLBACK *_GSgifTransfer2)(u32 *pMem, u32 size);
typedef void(CALLBACK *_GSgifTransfer3)(u32 *pMem, u32 size);
typedef void(CALLBACK *_GSgifSoftReset)(u32 mask);
typedef void(CALLBACK *_GSreadFIFO)(u64 *pMem);
typedef void(CALLBACK *_GSreadFIFO2)(u64 *pMem, int qwc);
typedef void(CALLBACK *_GSinitReadFIFO)(u64 *pMem);
typedef void(CALLBACK *_GSinitReadFIFO2)(u64 *pMem, int qwc);
typedef void(CALLBACK *_GSchangeSaveState)(int, const char *filename);
typedef void(CALLBACK *_GSgetTitleInfo2)(char *dest, size_t length);
typedef void(CALLBACK *_GSirqCallback)(void (*callback)());
typedef void(CALLBACK *_GSsetBaseMem)(void *);
typedef void(CALLBACK *_GSsetGameCRC)(int, int);
typedef void(CALLBACK *_GSsetFrameSkip)(int frameskip);
typedef void(CALLBACK *_GSsetVsync)(int enabled);
typedef void(CALLBACK *_GSsetExclusive)(int isExclusive);
typedef bool(CALLBACK* _GSsetupRecording)(std::string&);
typedef void(CALLBACK* _GSendRecording)();
typedef void(CALLBACK *_GSreset)();
typedef void(CALLBACK *_GSwriteCSR)(u32 value);
typedef bool(CALLBACK *_GSmakeSnapshot)(const char *path);
typedef void(CALLBACK *_GSmakeSnapshot2)(const char *path, int *, int);
#endif
#ifdef PLUGINfuncs
// GS
#ifndef BUILTIN_GS_PLUGIN
extern _GSosdLog GSosdLog;
extern _GSosdMonitor GSosdMonitor;
extern _GSopen GSopen;
extern _GSopen2 GSopen2;
extern _GSvsync GSvsync;
extern _GSgifTransfer GSgifTransfer;
extern _GSgifTransfer1 GSgifTransfer1;
extern _GSgifTransfer2 GSgifTransfer2;
extern _GSgifTransfer3 GSgifTransfer3;
extern _GSgifSoftReset GSgifSoftReset;
extern _GSreadFIFO GSreadFIFO;
extern _GSinitReadFIFO GSinitReadFIFO;
extern _GSreadFIFO2 GSreadFIFO2;
extern _GSinitReadFIFO2 GSinitReadFIFO2;
extern _GSchangeSaveState GSchangeSaveState;
extern _GSgetTitleInfo2 GSgetTitleInfo2;
extern _GSmakeSnapshot GSmakeSnapshot;
extern _GSmakeSnapshot2 GSmakeSnapshot2;
extern _GSirqCallback GSirqCallback;
extern _GSsetBaseMem GSsetBaseMem;
extern _GSsetGameCRC GSsetGameCRC;
extern _GSsetFrameSkip GSsetFrameSkip;
extern _GSsetVsync GSsetVsync;
extern _GSsetupRecording GSsetupRecording;
extern _GSendRecording GSendRecording;
extern _GSreset GSreset;
extern _GSwriteCSR GSwriteCSR;
#endif
#endif
#ifdef __cplusplus
} // End extern "C"
#endif
#endif /* __PS2EDEFS_H__ */

View File

@ -1,358 +0,0 @@
/* PCSX2 - PS2 Emulator for PCs
* Copyright (C) 2002-2010 PCSX2 Dev Team
*
* PCSX2 is free software: you can redistribute it and/or modify it under the terms
* of the GNU Lesser General Public License as published by the Free Software Found-
* ation, either version 3 of the License, or (at your option) any later version.
*
* PCSX2 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 PCSX2.
* If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef PS2EEXT_H_INCLUDED
#define PS2EEXT_H_INCLUDED
#include <stdio.h>
#include <string>
#include <cstdarg>
#include <mutex>
#include <condition_variable>
#if defined(_MSC_VER)
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0600
#endif
#include <windows.h>
#include <windowsx.h>
#include <commctrl.h>
#define EXPORT_C_(type) extern "C" type CALLBACK
#elif defined(__unix__)
#include <cstring>
#include <wx/msgdlg.h>
#include <wx/app.h>
#define EXPORT_C_(type) extern "C" __attribute__((stdcall, externally_visible, visibility("default"))) type
#else
#define EXPORT_C_(type) extern "C" __attribute__((stdcall, externally_visible, visibility("default"))) type
#endif
#include <PluginCompatibility.h>
//#include "PS2Edefs.h"
#if !defined(_MSC_VER) || !defined(UNICODE)
static void SysMessage(const char* fmt, ...);
static void __forceinline PluginNullConfigure(std::string desc, s32& log);
#else
static void SysMessage(const wchar_t* fmt, ...);
static void __forceinline PluginNullConfigure(std::wstring desc, s32& log);
#endif
enum FileMode
{
READ_FILE = 0,
WRITE_FILE
};
struct PluginLog
{
bool WriteToFile, WriteToConsole;
FILE* LogFile;
bool Open(std::string logname)
{
LogFile = px_fopen(logname, "w");
if (LogFile)
{
setvbuf(LogFile, NULL, _IONBF, 0);
return true;
}
return false;
}
void Close()
{
if (LogFile)
{
fclose(LogFile);
LogFile = NULL;
}
}
void Write(const char* fmt, ...)
{
if (LogFile == NULL)
return;
va_list list;
if (WriteToFile)
{
va_start(list, fmt);
vfprintf(LogFile, fmt, list);
va_end(list);
}
if (WriteToConsole)
{
va_start(list, fmt);
vfprintf(stdout, fmt, list);
va_end(list);
}
}
void WriteLn(const char* fmt, ...)
{
if (LogFile == NULL)
return;
va_list list;
if (WriteToFile)
{
va_start(list, fmt);
vfprintf(LogFile, fmt, list);
va_end(list);
fprintf(LogFile, "\n");
}
if (WriteToConsole)
{
va_start(list, fmt);
vfprintf(stdout, fmt, list);
va_end(list);
fprintf(stdout, "\n");
}
}
#if !defined(_MSC_VER) || !defined(UNICODE)
void Message(const char* fmt, ...)
{
va_list list;
char buf[256];
if (LogFile == NULL)
return;
va_start(list, fmt);
vsprintf(buf, fmt, list);
va_end(list);
SysMessage(buf);
}
#else
void Message(const wchar_t* fmt, ...)
{
va_list list;
wchar_t buf[256];
if (LogFile == NULL)
return;
va_start(list, fmt);
vswprintf(buf, 256, fmt, list);
va_end(list);
SysMessage(buf);
}
#endif
};
struct PluginConf
{
FILE* ConfFile;
char* PluginName;
bool Open(std::string name, FileMode mode = READ_FILE)
{
if (mode == READ_FILE)
{
ConfFile = px_fopen(name, "r");
}
else
{
ConfFile = px_fopen(name, "w");
}
if (ConfFile == NULL)
return false;
return true;
}
void Close()
{
if (ConfFile)
{
fclose(ConfFile);
ConfFile = NULL;
}
}
int ReadInt(const std::string& item, int defval)
{
int value = defval;
std::string buf = item + " = %d\n";
if (ConfFile)
if (fscanf(ConfFile, buf.c_str(), &value) < 0)
fprintf(stderr, "Error reading %s\n", item.c_str());
return value;
}
void WriteInt(std::string item, int value)
{
std::string buf = item + " = %d\n";
if (ConfFile)
fprintf(ConfFile, buf.c_str(), value);
}
};
#if defined(__unix__)
static void SysMessage(const char* fmt, ...)
{
va_list list;
char msg[512];
va_start(list, fmt);
vsprintf(msg, fmt, list);
va_end(list);
if (msg[strlen(msg) - 1] == '\n')
msg[strlen(msg) - 1] = 0;
if (!wxIsMainThread())
{
std::mutex dialogMutex;
std::condition_variable dialogCV;
bool dialogClosed = false;
wxTheApp->CallAfter([&] {
wxMessageDialog dialog(nullptr, msg, "Info", wxOK);
dialog.ShowModal();
{
std::lock_guard dialogLock1(dialogMutex);
dialogClosed = true;
}
dialogCV.notify_all();
});
//Block until done
std::unique_lock dialogLock2(dialogMutex);
dialogCV.wait(dialogLock2, [&] { return dialogClosed; });
}
else
{
wxMessageDialog dialog(nullptr, msg, "Info", wxOK);
dialog.ShowModal();
}
}
#define ENTRY_POINT /* We don't need no stinkin' entry point! */
#elif defined(__WXMAC__) || defined(__APPLE__)
static void SysMessage(const char* fmt, ...)
{
va_list list;
char msg[512];
va_start(list, fmt);
vsprintf(msg, fmt, list);
va_end(list);
if (msg[strlen(msg) - 1] == '\n')
msg[strlen(msg) - 1] = 0;
// TODO OSX can we use WX MessageBox here or should Cocoa MessageBox used?
}
static void SysMessage(const wchar_t* fmt, ...)
{
va_list list;
wchar_t msg[512];
va_start(list, fmt);
//vsprintf(msg, fmt, list);
va_end(list);
// TODO OSX can we use WX MessageBox here or should Cocoa MessageBox used?
}
static void __forceinline PluginNullConfigure(std::string desc, int& log)
{
SysMessage("This space is intentionally left blank.");
}
#define ENTRY_POINT /* We don't need no stinkin' entry point! */ // TODO OSX WTF is this anyway?
#else
#define usleep(x) Sleep(x / 1000)
#ifndef UNICODE
static void __forceinline SysMessage(const char* fmt, ...)
{
va_list list;
char tmp[512];
va_start(list, fmt);
vsprintf(tmp, fmt, list);
va_end(list);
MessageBox(GetActiveWindow(), tmp, "Message", MB_SETFOREGROUND | MB_OK);
}
static void __forceinline PluginNullConfigure(std::string desc, s32& log)
{
/* To do: Write a dialog box that displays a dialog box with the text in desc,
and a check box that says "Logging", checked if log !=0, and set log to
1 if it is checked on return, and 0 if it isn't. */
SysMessage("This space is intentionally left blank.");
}
#else
static void __forceinline SysMessage(const wchar_t* fmt, ...)
{
va_list list;
wchar_t tmp[512];
va_start(list, fmt);
vswprintf(tmp, 512, fmt, list);
va_end(list);
MessageBox(GetActiveWindow(), tmp, L"Message", MB_SETFOREGROUND | MB_OK);
}
static void __forceinline PluginNullConfigure(std::string desc, s32& log)
{
/* To do: Write a dialog box that displays a dialog box with the text in desc,
and a check box that says "Logging", checked if log !=0, and set log to
1 if it is checked on return, and 0 if it isn't. */
SysMessage(L"This space is intentionally left blank.");
}
#endif
#define ENTRY_POINT \
HINSTANCE hInst; \
\
BOOL APIENTRY DllMain(HANDLE hModule, /* DLL INIT*/ \
DWORD dwReason, \
LPVOID lpReserved) \
{ \
hInst = (HINSTANCE)hModule; \
return TRUE; /* very quick :)*/ \
}
#endif
#endif // PS2EEXT_H_INCLUDED

File diff suppressed because it is too large Load Diff

View File

@ -1,50 +0,0 @@
/* PCSX2 - PS2 Emulator for PCs
* Copyright (C) 2018 PCSX2 Dev Team
*
* PCSX2 is free software: you can redistribute it and/or modify it under the terms
* of the GNU Lesser General Public License as published by the Free Software Found-
* ation, either version 3 of the License, or (at your option) any later version.
*
* PCSX2 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 PCSX2.
* If not, see <http://www.gnu.org/licenses/>.
*/
#ifdef _WIN32
#include <windows.h>
#endif
#include <string>
#include <vector>
#include <cstdio>
#ifdef _WIN32
inline std::string convert_utf16_to_utf8(const std::wstring& utf16_string)
{
const int size = WideCharToMultiByte(CP_UTF8, 0, utf16_string.c_str(), utf16_string.size(), nullptr, 0, nullptr, nullptr);
std::string converted_string(size, 0);
WideCharToMultiByte(CP_UTF8, 0, utf16_string.c_str(), utf16_string.size(), converted_string.data(), converted_string.size(), nullptr, nullptr);
return converted_string;
}
inline std::wstring convert_utf8_to_utf16(const std::string &utf8_string)
{
int size = MultiByteToWideChar(CP_UTF8, 0, utf8_string.c_str(), -1, nullptr, 0);
std::vector<wchar_t> converted_string(size);
MultiByteToWideChar(CP_UTF8, 0, utf8_string.c_str(), -1, converted_string.data(), converted_string.size());
return {converted_string.data()};
}
#endif
// _wfopen has to be used on Windows for pathnames containing non-ASCII characters.
inline FILE *px_fopen(const std::string &filename, const std::string &mode)
{
#ifdef _WIN32
return _wfopen(convert_utf8_to_utf16(filename).c_str(), convert_utf8_to_utf16(mode).c_str());
#else
return fopen(filename.c_str(), mode.c_str());
#endif
}

View File

@ -1103,10 +1103,6 @@ if(PULSEAUDIO_FOUND)
set(pcsx2FinalLibs ${pcsx2FinalLibs} ${PULSEAUDIO_LIBRARIES})
endif()
if(BUILTIN_GS)
set(pcsx2FinalLibs "${pcsx2FinalLibs} GSdx")
endif()
# additonal include directories
include_directories(
gui

View File

@ -23,19 +23,6 @@
class IniInterface;
enum PluginsEnum_t
{
PluginId_GS = 0,
PluginId_Count,
// Memorycard plugin support is preliminary, and is only hacked/hardcoded in at this
// time. So it's placed afer PluginId_Count so that it doesn't show up in the conf
// screens or other plugin tables.
PluginId_Mcd,
PluginId_AllocCount // Extra value for correct array allocation
};
enum GamefixId
{
GamefixId_FIRST = 0,

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