Fix textures in Turok Evolution
This commit is contained in:
parent
c0ccf190bc
commit
06516410a6
|
@ -723,7 +723,6 @@ void *GetDataFromXboxResource(XTL::X_D3DResource *pXboxResource)
|
|||
case X_D3DCOMMON_TYPE_PALETTE:
|
||||
case X_D3DCOMMON_TYPE_TEXTURE:
|
||||
case X_D3DCOMMON_TYPE_SURFACE:
|
||||
pData |= MM_SYSTEM_PHYSICAL_MAP;
|
||||
pData |= MM_SYSTEM_PHYSICAL_MAP;
|
||||
break;
|
||||
case X_D3DCOMMON_TYPE_PUSHBUFFER:
|
||||
|
@ -6533,6 +6532,7 @@ void EmuUpdateActiveTextureStages()
|
|||
}
|
||||
|
||||
XTL::IDirect3DTexture8 *pHostTexture = GetHostTexture(pBaseTexture);
|
||||
|
||||
if (pHostTexture != nullptr) {
|
||||
HRESULT hRet = g_pD3DDevice8->SetTexture(i, pHostTexture);
|
||||
DEBUG_D3DRESULT(hRet, "g_pD3DDevice8->SetTexture");
|
||||
|
|
|
@ -40,6 +40,9 @@
|
|||
#include "CxbxKrnl/EmuD3D8Types.h" // For X_D3DFORMAT
|
||||
#include "CxbxKrnl/ResourceTracker.h"
|
||||
|
||||
// TODO: Find somewhere to put this that doesn't conflict with XTL::
|
||||
extern void EmuUpdateActiveTextureStages();
|
||||
|
||||
uint32 XTL::g_dwPrimaryPBCount = 0;
|
||||
uint32 *XTL::g_pPrimaryPB = 0;
|
||||
|
||||
|
@ -98,6 +101,7 @@ extern void XTL::EmuExecutePushBufferRaw
|
|||
|
||||
// TODO: This technically should be enabled
|
||||
XTL::EmuUpdateDeferredStates();
|
||||
EmuUpdateActiveTextureStages();
|
||||
|
||||
#ifdef _DEBUG_TRACK_PB
|
||||
bool bShowPB = false;
|
||||
|
|
|
@ -446,4 +446,6 @@ void XTL::EmuUpdateDeferredStates()
|
|||
g_pD3DDevice8->SetRenderState(D3DRS_AMBIENT, 0xFFFFFFFF);
|
||||
//*/
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -42,6 +42,9 @@
|
|||
#include "CxbxKrnl/EmuXTL.h"
|
||||
#include "CxbxKrnl/ResourceTracker.h"
|
||||
|
||||
// TODO: Find somewhere to put this that doesn't conflict with XTL::
|
||||
extern void EmuUpdateActiveTextureStages();
|
||||
|
||||
#include <ctime>
|
||||
|
||||
#define HASH_SEED 0
|
||||
|
@ -1081,6 +1084,7 @@ bool XTL::VertexPatcher::Restore()
|
|||
VOID XTL::EmuFlushIVB()
|
||||
{
|
||||
XTL::EmuUpdateDeferredStates();
|
||||
EmuUpdateActiveTextureStages();
|
||||
|
||||
DWORD *pdwVB = (DWORD*)g_pIVBVertexBuffer;
|
||||
|
||||
|
|
Loading…
Reference in New Issue