Merge pull request #1040 from LukeUsher/various-experiments
This seems to fix the .bik hang
This commit is contained in:
commit
ccb9ae1309
|
@ -3972,6 +3972,10 @@ DWORD WINAPI XTL::EMUPATCH(D3DDevice_Swap)
|
|||
DEBUG_D3DRESULT(hRet, "g_pD3DDevice8->Present");
|
||||
hRet = g_pD3DDevice8->BeginScene();
|
||||
|
||||
UpdateFPSCounter();
|
||||
|
||||
if (Flags == CXBX_SWAP_PRESENT_FORWARD) // Only do this when forwarded from Present
|
||||
{
|
||||
if (!g_UncapFramerate) {
|
||||
// If the last frame completed faster than the Xbox VBlank period, wait for it
|
||||
// TODO: Read the frame rate target from the Xbox display mode
|
||||
|
@ -3986,10 +3990,6 @@ DWORD WINAPI XTL::EMUPATCH(D3DDevice_Swap)
|
|||
frameStartTime = std::chrono::high_resolution_clock::now();
|
||||
}
|
||||
|
||||
UpdateFPSCounter();
|
||||
|
||||
if (Flags == CXBX_SWAP_PRESENT_FORWARD) // Only do this when forwarded from Present
|
||||
{
|
||||
// Put primitives per frame in the title
|
||||
/*{
|
||||
char szString[64];
|
||||
|
|
|
@ -144,8 +144,7 @@ static BOOL TryEnterHostCriticalSection(xboxkrnl::PRTL_CRITICAL_SECTION xbox_cri
|
|||
|
||||
DWORD WINAPI RtlAnsiStringToUnicodeSize(const xboxkrnl::STRING *str)
|
||||
{
|
||||
DWORD ret = mbstowcs(nullptr, str->Buffer, str->Length);
|
||||
return ret + sizeof(WCHAR); // + for the terminating null character
|
||||
return (str->Length + sizeof(ANSI_NULL)) * sizeof(WCHAR);
|
||||
}
|
||||
|
||||
// ******************************************************************
|
||||
|
|
|
@ -954,7 +954,7 @@ DWORD WINAPI XTL::EMUPATCH(QueueUserAPC)
|
|||
DWORD dwData
|
||||
)
|
||||
{
|
||||
FUNC_EXPORTS
|
||||
//FUNC_EXPORTS
|
||||
|
||||
LOG_FUNC_BEGIN
|
||||
LOG_FUNC_ARG_TYPE(PVOID, pfnAPC)
|
||||
|
|
Loading…
Reference in New Issue