mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-13 16:08:50 +01:00
54ed8f0bb0
Co-authored-by: Philip Rebohle <philip.rebohle@tu-dortmund.de> Co-authored-by: Robin Kertels <robin.kertels@gmail.com> Co-authored-by: pchome <pchome@users.noreply.github.com> Co-authored-by: Christopher Egert <cme3000@gmail.com> Co-authored-by: Derek Lesho <dereklesho52@Gmail.com> Co-authored-by: Luis Cáceres <lacaceres97@gmail.com> Co-authored-by: Nelson Chen <crazysim@gmail.com> Co-authored-by: Edmondo Tommasina <edmondo.tommasina@gmail.com> Co-authored-by: Riesi <riesi@opentrash.com> Co-authored-by: gbMichelle <gbmichelle.dev@gmail.com>
87 lines
2.0 KiB
C++
87 lines
2.0 KiB
C++
#include "../dxvk/dxvk_instance.h"
|
|
|
|
#include "d3d9_interface.h"
|
|
#include "d3d9_shader_validator.h"
|
|
|
|
class D3DFE_PROCESSVERTICES;
|
|
using PSGPERRORID = UINT;
|
|
|
|
namespace dxvk {
|
|
Logger Logger::s_instance("d3d9.log");
|
|
|
|
HRESULT CreateD3D9(
|
|
bool Extended,
|
|
IDirect3D9Ex** ppDirect3D9Ex) {
|
|
if (!ppDirect3D9Ex)
|
|
return D3DERR_INVALIDCALL;
|
|
|
|
*ppDirect3D9Ex = ref(new D3D9InterfaceEx( Extended ));
|
|
return D3D_OK;
|
|
}
|
|
}
|
|
|
|
extern "C" {
|
|
|
|
DLLEXPORT IDirect3D9* __stdcall Direct3DCreate9(UINT nSDKVersion) {
|
|
IDirect3D9Ex* pDirect3D = nullptr;
|
|
dxvk::CreateD3D9(false, &pDirect3D);
|
|
|
|
return pDirect3D;
|
|
}
|
|
|
|
DLLEXPORT HRESULT __stdcall Direct3DCreate9Ex(UINT nSDKVersion, IDirect3D9Ex** ppDirect3D9Ex) {
|
|
return dxvk::CreateD3D9(true, ppDirect3D9Ex);
|
|
}
|
|
|
|
DLLEXPORT int __stdcall D3DPERF_BeginEvent(D3DCOLOR col, LPCWSTR wszName) {
|
|
return 0;
|
|
}
|
|
|
|
DLLEXPORT int __stdcall D3DPERF_EndEvent(void) {
|
|
return 0;
|
|
}
|
|
|
|
DLLEXPORT void __stdcall D3DPERF_SetMarker(D3DCOLOR col, LPCWSTR wszName) {
|
|
}
|
|
|
|
DLLEXPORT void __stdcall D3DPERF_SetRegion(D3DCOLOR col, LPCWSTR wszName) {
|
|
}
|
|
|
|
DLLEXPORT BOOL __stdcall D3DPERF_QueryRepeatFrame(void) {
|
|
return FALSE;
|
|
}
|
|
|
|
DLLEXPORT void __stdcall D3DPERF_SetOptions(DWORD dwOptions) {
|
|
}
|
|
|
|
DLLEXPORT DWORD __stdcall D3DPERF_GetStatus(void) {
|
|
return 0;
|
|
}
|
|
|
|
|
|
DLLEXPORT void __stdcall DebugSetMute(void) {
|
|
}
|
|
|
|
DLLEXPORT int __stdcall DebugSetLevel(void) {
|
|
return 0;
|
|
}
|
|
|
|
// Processor Specific Geometry Pipeline
|
|
// for P3 SIMD/AMD 3DNow.
|
|
|
|
DLLEXPORT void __stdcall PSGPError(D3DFE_PROCESSVERTICES* a, PSGPERRORID b, UINT c) {
|
|
}
|
|
|
|
DLLEXPORT void __stdcall PSGPSampleTexture(D3DFE_PROCESSVERTICES* a, UINT b, float(*const c)[4], UINT d, float(*const e)[4]) {
|
|
}
|
|
|
|
DLLEXPORT dxvk::D3D9ShaderValidator* __stdcall Direct3DShaderValidatorCreate9(void) {
|
|
return ref(new dxvk::D3D9ShaderValidator());
|
|
}
|
|
|
|
DLLEXPORT int __stdcall Direct3D9EnableMaximizedWindowedModeShim(UINT a) {
|
|
return 0;
|
|
}
|
|
|
|
}
|