mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-30 01:29:42 -06:00
Second and final pass of clearing out tabs.
This commit is contained in:
@ -2,7 +2,7 @@
|
||||
// Licensed under GPLv2
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#pragma once
|
||||
#pragma once
|
||||
|
||||
#include <d3d11.h>
|
||||
#include <MathUtil.h>
|
||||
|
@ -465,9 +465,9 @@ u32 Renderer::AccessEFB(EFBAccessType type, u32 x, u32 y, u32 poke_data)
|
||||
|
||||
D3D::context->OMSetRenderTargets(1, &FramebufferManager::GetEFBColorTexture()->GetRTV(), NULL);
|
||||
D3D::drawColorQuad(rgbaColor, (float)RectToLock.left * 2.f / (float)Renderer::GetTargetWidth() - 1.f,
|
||||
- (float)RectToLock.top * 2.f / (float)Renderer::GetTargetHeight() + 1.f,
|
||||
(float)RectToLock.right * 2.f / (float)Renderer::GetTargetWidth() - 1.f,
|
||||
- (float)RectToLock.bottom * 2.f / (float)Renderer::GetTargetHeight() + 1.f);
|
||||
- (float)RectToLock.top * 2.f / (float)Renderer::GetTargetHeight() + 1.f,
|
||||
(float)RectToLock.right * 2.f / (float)Renderer::GetTargetWidth() - 1.f,
|
||||
- (float)RectToLock.bottom * 2.f / (float)Renderer::GetTargetHeight() + 1.f);
|
||||
|
||||
RestoreAPIState();
|
||||
return 0;
|
||||
@ -514,10 +514,9 @@ void Renderer::SetViewport()
|
||||
Ht = (Y + Ht <= GetTargetHeight()) ? Ht : (GetTargetHeight() - Y);
|
||||
|
||||
// Some games set invalid values for z-min and z-max so fix them to the max and min allowed and let the shaders do this work
|
||||
D3D11_VIEWPORT vp = CD3D11_VIEWPORT(X, Y,
|
||||
Wd, Ht,
|
||||
0.f, // (xfregs.viewport.farZ - xfregs.viewport.zRange) / 16777216.0f;
|
||||
1.f); // xfregs.viewport.farZ / 16777216.0f;
|
||||
D3D11_VIEWPORT vp = CD3D11_VIEWPORT(X, Y, Wd, Ht,
|
||||
0.f, // (xfregs.viewport.farZ - xfregs.viewport.zRange) / 16777216.0f;
|
||||
1.f); // xfregs.viewport.farZ / 16777216.0f;
|
||||
D3D::context->RSSetViewports(1, &vp);
|
||||
}
|
||||
|
||||
|
@ -1571,9 +1571,9 @@ namespace GLExtensions
|
||||
bool _isES;
|
||||
u32 _GLVersion;
|
||||
std::unordered_map<std::string, bool> m_extension_list;
|
||||
|
||||
|
||||
// Private initialization functions
|
||||
bool InitFunctionPointers();
|
||||
bool InitFunctionPointers();
|
||||
|
||||
// Initializes the extension list the old way
|
||||
void InitExtensionList21()
|
||||
@ -1767,7 +1767,7 @@ namespace GLExtensions
|
||||
// Grab a few functions for initial checking
|
||||
// We need them to grab the extension list
|
||||
// Also to check if there is an error grabbing the version
|
||||
// If it fails then the user's drivers don't support GL 3.0
|
||||
// If it fails then the user's drivers don't support GL 3.0
|
||||
if (GetFuncAddress ("glGetIntegerv", (void**)&glGetIntegerv) == NULL)
|
||||
return false;
|
||||
if (GetFuncAddress("glGetString", (void**)&glGetString) == NULL)
|
||||
@ -1781,7 +1781,7 @@ namespace GLExtensions
|
||||
InitExtensionList();
|
||||
|
||||
return InitFunctionPointers();
|
||||
}
|
||||
}
|
||||
|
||||
// Private initialization functions
|
||||
bool HasFeatures(const std::string& extensions)
|
||||
|
@ -924,15 +924,15 @@ void Renderer::UpdateEFBCache(EFBAccessType type, u32 cacheRectIdx, const EFBRec
|
||||
// and EFB pokes (which will change the color or depth of a pixel).
|
||||
//
|
||||
// The behavior of EFB peeks can only be modified by:
|
||||
// - GX_PokeAlphaRead
|
||||
// - GX_PokeAlphaRead
|
||||
// The behavior of EFB pokes can be modified by:
|
||||
// - GX_PokeAlphaMode (TODO)
|
||||
// - GX_PokeAlphaUpdate (TODO)
|
||||
// - GX_PokeBlendMode (TODO)
|
||||
// - GX_PokeColorUpdate (TODO)
|
||||
// - GX_PokeDither (TODO)
|
||||
// - GX_PokeDstAlpha (TODO)
|
||||
// - GX_PokeZMode (TODO)
|
||||
// - GX_PokeAlphaMode (TODO)
|
||||
// - GX_PokeAlphaUpdate (TODO)
|
||||
// - GX_PokeBlendMode (TODO)
|
||||
// - GX_PokeColorUpdate (TODO)
|
||||
// - GX_PokeDither (TODO)
|
||||
// - GX_PokeDstAlpha (TODO)
|
||||
// - GX_PokeZMode (TODO)
|
||||
u32 Renderer::AccessEFB(EFBAccessType type, u32 x, u32 y, u32 poke_data)
|
||||
{
|
||||
u32 cacheRectIdx = (y / EFB_CACHE_RECT_SIZE) * EFB_CACHE_WIDTH
|
||||
|
@ -26,8 +26,8 @@ namespace TextureConverter
|
||||
using OGL::TextureCache;
|
||||
|
||||
static GLuint s_texConvFrameBuffer[2] = {0,0};
|
||||
static GLuint s_srcTexture = 0; // for decoding from RAM
|
||||
static GLuint s_dstTexture = 0; // for encoding to RAM
|
||||
static GLuint s_srcTexture = 0; // for decoding from RAM
|
||||
static GLuint s_dstTexture = 0; // for encoding to RAM
|
||||
|
||||
const int renderBufferWidth = 1024;
|
||||
const int renderBufferHeight = 1024;
|
||||
|
@ -151,7 +151,7 @@ void SWBPWritten(int address, int newvalue)
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
break;
|
||||
|
||||
case BPMEM_TEV_REGISTER_L: // Reg 1
|
||||
case BPMEM_TEV_REGISTER_L+2: // Reg 2
|
||||
|
@ -72,9 +72,9 @@ namespace EfbInterface
|
||||
u32 src = *(u32*)rgb;
|
||||
u32 *dst = (u32*)&efb[offset];
|
||||
u32 val = *dst & 0xff00003f;
|
||||
val |= (src >> 4) & 0x00000fc0; // blue
|
||||
val |= (src >> 6) & 0x0003f000; // green
|
||||
val |= (src >> 8) & 0x00fc0000; // red
|
||||
val |= (src >> 4) & 0x00000fc0; // blue
|
||||
val |= (src >> 6) & 0x0003f000; // green
|
||||
val |= (src >> 8) & 0x00fc0000; // red
|
||||
*dst = val;
|
||||
}
|
||||
break;
|
||||
@ -112,10 +112,10 @@ namespace EfbInterface
|
||||
u32 src = *(u32*)color;
|
||||
u32 *dst = (u32*)&efb[offset];
|
||||
u32 val = *dst & 0xff000000;
|
||||
val |= (src >> 2) & 0x0000003f; // alpha
|
||||
val |= (src >> 4) & 0x00000fc0; // blue
|
||||
val |= (src >> 6) & 0x0003f000; // green
|
||||
val |= (src >> 8) & 0x00fc0000; // red
|
||||
val |= (src >> 2) & 0x0000003f; // alpha
|
||||
val |= (src >> 4) & 0x00000fc0; // blue
|
||||
val |= (src >> 6) & 0x0003f000; // green
|
||||
val |= (src >> 8) & 0x00fc0000; // red
|
||||
*dst = val;
|
||||
}
|
||||
break;
|
||||
|
@ -191,8 +191,8 @@ void DecodeStandard(u32 bufferSize)
|
||||
// zelda 4 swords calls it and checks the metrics registers after that
|
||||
break;
|
||||
|
||||
case GX_CMD_INVL_VC:// Invalidate (vertex cache?)
|
||||
DEBUG_LOG(VIDEO, "Invalidate (vertex cache?)");
|
||||
case GX_CMD_INVL_VC:// Invalidate (vertex cache?)
|
||||
DEBUG_LOG(VIDEO, "Invalidate (vertex cache?)");
|
||||
break;
|
||||
|
||||
case GX_LOAD_BP_REG: //0x61
|
||||
|
@ -78,13 +78,13 @@ void RegisterMMIO(MMIO::Mapping* mmio, u32 base)
|
||||
MMIO::ComplexWrite<u16>([](u32, u16 val) {
|
||||
UPECtrlReg tmpCtrl(val);
|
||||
|
||||
if (tmpCtrl.PEToken) g_bSignalTokenInterrupt = false;
|
||||
if (tmpCtrl.PEFinish) g_bSignalFinishInterrupt = false;
|
||||
if (tmpCtrl.PEToken) g_bSignalTokenInterrupt = false;
|
||||
if (tmpCtrl.PEFinish) g_bSignalFinishInterrupt = false;
|
||||
|
||||
pereg.ctrl.PETokenEnable = tmpCtrl.PETokenEnable;
|
||||
pereg.ctrl.PEFinishEnable = tmpCtrl.PEFinishEnable;
|
||||
pereg.ctrl.PEToken = 0; // this flag is write only
|
||||
pereg.ctrl.PEFinish = 0; // this flag is write only
|
||||
pereg.ctrl.PEToken = 0; // this flag is write only
|
||||
pereg.ctrl.PEFinish = 0; // this flag is write only
|
||||
|
||||
UpdateInterrupts();
|
||||
})
|
||||
@ -99,7 +99,7 @@ bool AllowIdleSkipping()
|
||||
void UpdateInterrupts()
|
||||
{
|
||||
// check if there is a token-interrupt
|
||||
if (g_bSignalTokenInterrupt & pereg.ctrl.PETokenEnable)
|
||||
if (g_bSignalTokenInterrupt & pereg.ctrl.PETokenEnable)
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_TOKEN, true);
|
||||
else
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_TOKEN, false);
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include "Thread.h"
|
||||
|
||||
namespace SWRenderer
|
||||
{
|
||||
{
|
||||
void Init();
|
||||
void Prepare();
|
||||
void Shutdown();
|
||||
|
Reference in New Issue
Block a user