Further UWP fixes

This commit is contained in:
Henrik Rydgard 2017-02-25 01:38:48 +01:00
parent b8757e3e31
commit c219ae9e63
7 changed files with 21 additions and 8 deletions

View File

@ -808,9 +808,8 @@ void VirtualDiscFileSystem::HandlerLogger(void *arg, HandlerHandle handle, LogTy
}
}
#if !PPSSPP_PLATFORM(UWP)
VirtualDiscFileSystem::Handler::Handler(const char *filename, VirtualDiscFileSystem *const sys) {
#if !PPSSPP_PLATFORM(UWP)
#ifdef _WIN32
#define dlopen(name, ignore) (void *)LoadLibrary(ConvertUTF8ToWString(name).c_str())
#define dlsym(mod, name) GetProcAddress((HMODULE)mod, name)
@ -843,18 +842,20 @@ VirtualDiscFileSystem::Handler::Handler(const char *filename, VirtualDiscFileSys
#undef dlsym
#undef dlclose
#endif
#endif
}
VirtualDiscFileSystem::Handler::~Handler() {
if (library != NULL) {
Shutdown();
#if !PPSSPP_PLATFORM(UWP)
#ifdef _WIN32
FreeLibrary((HMODULE)library);
#else
dlclose(library);
#endif
#endif
}
}
#endif

View File

@ -621,6 +621,7 @@ void InitSysDirectories() {
#if PPSSPP_PLATFORM(UWP)
const std::string myDocsPath = ""; // TODO UWP
const HRESULT result = E_FAIL;
#else
wchar_t myDocumentsPath[MAX_PATH];
const HRESULT result = SHGetFolderPath(NULL, CSIDL_PERSONAL, NULL, SHGFP_TYPE_CURRENT, myDocumentsPath);

View File

@ -1,9 +1,17 @@
#include "ppsspp_config.h"
#include <cstdint>
#include <vector>
#include <d3d11.h>
#include <D3Dcompiler.h>
#if PPSSPP_PLATFORM(UWP)
#define ptr_D3DCompile D3DCompile
#else
#include "thin3d/d3d11_loader.h"
#endif
#include "base/logging.h"
#include "base/stringutil.h"

View File

@ -50,14 +50,10 @@
#include "Windows/WindowsHost.h"
#include "Windows/MainWindow.h"
#if PPSSPP_PLATFORM(UWP)
#include "Windows/GPU/D3D11Context.h"
#else
#include "Windows/GPU/WindowsGLContext.h"
#include "Windows/GPU/WindowsVulkanContext.h"
#include "Windows/GPU/D3D9Context.h"
#include "Windows/GPU/D3D11Context.h"
#endif
#include "Windows/Debugger/DebuggerShared.h"
#include "Windows/Debugger/Debugger_Disasm.h"

View File

@ -219,6 +219,7 @@ EXEC_AND_LIB_FILES := \
$(SRC)/GPU/Common/VertexDecoderCommon.cpp.arm \
$(SRC)/GPU/Common/TextureCacheCommon.cpp.arm \
$(SRC)/GPU/Common/TextureScalerCommon.cpp.arm \
$(SRC)/GPU/Common/ShaderCommon.cpp \
$(SRC)/GPU/Common/SplineCommon.cpp.arm \
$(SRC)/GPU/Common/DrawEngineCommon.cpp.arm \
$(SRC)/GPU/Common/TransformCommon.cpp.arm \

View File

@ -1,5 +1,7 @@
#pragma once
#include "ppsspp_config.h"
// Standard Windows includes
#include <windows.h>
#include <initguid.h>
@ -23,4 +25,4 @@ enum class LoadD3D11Error {
};
LoadD3D11Error LoadD3D11();
bool UnloadD3D11();
bool UnloadD3D11();

View File

@ -1,7 +1,11 @@
#include "ppsspp_config.h"
#include "thin3d/thin3d.h"
#if PPSSPP_PLATFORM(UWP)
#define ptr_D3DCompile D3DCompile
#else
#include "thin3d/d3d11_loader.h"
#endif
#include "math/dataconv.h"
#include "util/text/utf8.h"