mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-26 23:10:38 +00:00
Global: Remove some unused variables.
This commit is contained in:
parent
0c876754a6
commit
f32f89dd90
@ -3833,8 +3833,6 @@ bool ARM64XEmitter::TryEORI2R(ARM64Reg Rd, ARM64Reg Rn, u64 imm) {
|
||||
}
|
||||
|
||||
float FPImm8ToFloat(uint8_t bits) {
|
||||
int E = 8;
|
||||
int F = 32 - 8 - 1;
|
||||
int sign = bits >> 7;
|
||||
uint32_t f = 0;
|
||||
f |= (sign << 31);
|
||||
|
@ -114,6 +114,7 @@ CPUInfo::CPUInfo() {
|
||||
Detect();
|
||||
}
|
||||
|
||||
#if PPSSPP_PLATFORM(LINUX)
|
||||
static std::vector<int> ParseCPUList(const std::string &filename) {
|
||||
std::string data;
|
||||
std::vector<int> results;
|
||||
@ -135,6 +136,7 @@ static std::vector<int> ParseCPUList(const std::string &filename) {
|
||||
|
||||
return results;
|
||||
}
|
||||
#endif
|
||||
|
||||
// Detects the various cpu features
|
||||
void CPUInfo::Detect() {
|
||||
|
@ -517,8 +517,6 @@ void ConsoleListener::PixelSpace(int Left, int Top, int Width, int Height, bool
|
||||
// Check size
|
||||
if (Width < 8 || Height < 12) return;
|
||||
|
||||
bool DBef = true;
|
||||
bool DAft = true;
|
||||
std::string SLog = "";
|
||||
|
||||
// Get console info
|
||||
|
@ -1023,7 +1023,6 @@ Pipeline *D3D11DrawContext::CreateGraphicsPipeline(const PipelineDesc &desc) {
|
||||
|
||||
// Can finally create the input layout
|
||||
if (dPipeline->input) {
|
||||
auto &inputDesc = dPipeline->input->desc;
|
||||
const std::vector<D3D11_INPUT_ELEMENT_DESC> &elements = dPipeline->input->elements;
|
||||
HRESULT hr = device_->CreateInputLayout(elements.data(), (UINT)elements.size(), vshader->byteCode_.data(), vshader->byteCode_.size(), &dPipeline->il);
|
||||
if (!SUCCEEDED(hr)) {
|
||||
@ -1488,7 +1487,6 @@ bool D3D11DrawContext::CopyFramebufferToMemorySync(Framebuffer *src, int channel
|
||||
packDesc.MipLevels = 1;
|
||||
packDesc.Usage = D3D11_USAGE_STAGING;
|
||||
packDesc.SampleDesc.Count = 1;
|
||||
D3D11_BOX srcBox{ (UINT)bx, (UINT)by, 0, (UINT)(bx + bw), (UINT)(by + bh), 1 };
|
||||
switch (channelBits) {
|
||||
case FB_COLOR_BIT:
|
||||
packDesc.Format = DXGI_FORMAT_R8G8B8A8_UNORM; // TODO: fb->colorFormat;
|
||||
|
@ -271,7 +271,7 @@ private:
|
||||
|
||||
class D3D9Pipeline : public Pipeline {
|
||||
public:
|
||||
D3D9Pipeline(LPDIRECT3DDEVICE9 device) : device_(device) {}
|
||||
D3D9Pipeline() {}
|
||||
~D3D9Pipeline() {
|
||||
if (depthStencil) depthStencil->Release();
|
||||
if (blend) blend->Release();
|
||||
@ -294,8 +294,6 @@ public:
|
||||
UniformBufferDesc dynamicUniforms;
|
||||
|
||||
void Apply(LPDIRECT3DDEVICE9 device);
|
||||
private:
|
||||
LPDIRECT3DDEVICE9 device_;
|
||||
};
|
||||
|
||||
class D3D9Texture : public Texture {
|
||||
@ -695,7 +693,7 @@ Pipeline *D3D9Context::CreateGraphicsPipeline(const PipelineDesc &desc) {
|
||||
ERROR_LOG(G3D, "Pipeline requires at least one shader");
|
||||
return NULL;
|
||||
}
|
||||
D3D9Pipeline *pipeline = new D3D9Pipeline(device_);
|
||||
D3D9Pipeline *pipeline = new D3D9Pipeline();
|
||||
for (auto iter : desc.shaders) {
|
||||
if (!iter) {
|
||||
ERROR_LOG(G3D, "NULL shader passed to CreateGraphicsPipeline");
|
||||
@ -971,9 +969,6 @@ void D3D9Context::Draw(int vertexCount, int offset) {
|
||||
}
|
||||
|
||||
void D3D9Context::DrawIndexed(int vertexCount, int offset) {
|
||||
D3D9Buffer *vbuf = static_cast<D3D9Buffer *>(curVBuffers_[0]);
|
||||
D3D9Buffer *ibuf = static_cast<D3D9Buffer *>(curIBuffer_);
|
||||
|
||||
curPipeline_->Apply(device_);
|
||||
curPipeline_->inputLayout->Apply(device_);
|
||||
device_->SetStreamSource(0, curVBuffers_[0]->vbuffer_, curVBufferOffsets_[0], curPipeline_->inputLayout->GetStride(0));
|
||||
@ -1032,7 +1027,6 @@ void D3D9Context::SetStencilRef(uint8_t ref) {
|
||||
bool D3D9ShaderModule::Compile(LPDIRECT3DDEVICE9 device, const uint8_t *data, size_t size) {
|
||||
LPD3D_SHADER_MACRO defines = nullptr;
|
||||
LPD3DINCLUDE includes = nullptr;
|
||||
DWORD flags = 0;
|
||||
LPD3DBLOB codeBuffer = nullptr;
|
||||
LPD3DBLOB errorBuffer = nullptr;
|
||||
const char *source = (const char *)data;
|
||||
|
@ -1001,7 +1001,6 @@ bool VulkanContext::InitSwapchain() {
|
||||
std::string currentTransform = surface_transforms_to_string(surfCapabilities_.currentTransform);
|
||||
g_display_rotation = DisplayRotation::ROTATE_0;
|
||||
g_display_rot_matrix.setIdentity();
|
||||
bool swapChainExtentSwap = false;
|
||||
if (surfCapabilities_.currentTransform & (VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR | VK_SURFACE_TRANSFORM_INHERIT_BIT_KHR)) {
|
||||
preTransform = VK_SURFACE_TRANSFORM_IDENTITY_BIT_KHR;
|
||||
} else if (surfCapabilities_.currentTransform & (VK_SURFACE_TRANSFORM_ROTATE_90_BIT_KHR | VK_SURFACE_TRANSFORM_ROTATE_180_BIT_KHR | VK_SURFACE_TRANSFORM_ROTATE_270_BIT_KHR)) {
|
||||
@ -1429,7 +1428,6 @@ bool IsHashMaliDriverVersion(const VkPhysicalDeviceProperties &props) {
|
||||
// ARM used to put a hash in place of the driver version.
|
||||
// Now they only use major versions. We'll just make a bad heuristic.
|
||||
uint32_t major = VK_VERSION_MAJOR(props.driverVersion);
|
||||
uint32_t minor = VK_VERSION_MINOR(props.driverVersion);
|
||||
uint32_t branch = VK_VERSION_PATCH(props.driverVersion);
|
||||
if (branch > 0)
|
||||
return true;
|
||||
|
@ -43,7 +43,6 @@ VKAPI_ATTR VkBool32 VKAPI_CALL VulkanDebugUtilsCallback(
|
||||
return false;
|
||||
}
|
||||
|
||||
const char *pLayerPrefix = "";
|
||||
if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_ERROR_BIT_EXT) {
|
||||
message << "ERROR(";
|
||||
} else if (messageSeverity & VK_DEBUG_UTILS_MESSAGE_SEVERITY_WARNING_BIT_EXT) {
|
||||
|
@ -235,6 +235,7 @@ static const char *device_name_blacklist[] = {
|
||||
"SDL:Horizon",
|
||||
};
|
||||
|
||||
#ifndef _WIN32
|
||||
static const char *so_names[] = {
|
||||
#ifdef IOS
|
||||
"@executable_path/Frameworks/libMoltenVK.dylib",
|
||||
@ -247,6 +248,7 @@ static const char *so_names[] = {
|
||||
#endif
|
||||
#endif
|
||||
};
|
||||
#endif
|
||||
|
||||
void VulkanSetAvailable(bool available) {
|
||||
g_vulkanAvailabilityChecked = true;
|
||||
|
@ -246,7 +246,6 @@ size_t VulkanDeviceAllocator::Allocate(const VkMemoryRequirements &reqs, VkDevic
|
||||
|
||||
bool VulkanDeviceAllocator::AllocateFromSlab(Slab &slab, size_t &start, size_t blocks, const char *tag) {
|
||||
_assert_(!destroyed_);
|
||||
bool matched = true;
|
||||
|
||||
if (start + blocks > slab.usage.size()) {
|
||||
start = slab.usage.size();
|
||||
|
@ -302,7 +302,6 @@ u32 DisassemblyManager::getNthPreviousAddress(u32 address, int n)
|
||||
{
|
||||
DisassemblyEntry* entry = it->second;
|
||||
int oldLineNum = entry->getLineNum(address,true);
|
||||
int oldNumLines = entry->getNumLines();
|
||||
if (n <= oldLineNum)
|
||||
{
|
||||
return entry->getLineAddress(oldLineNum-n);
|
||||
@ -420,7 +419,6 @@ int DisassemblyFunction::getLineNum(u32 address, bool findStart)
|
||||
int last = (int)lineAddresses.size() - 1;
|
||||
for (int i = 0; i < last; i++)
|
||||
{
|
||||
u32 next = lineAddresses[i + 1];
|
||||
if (lineAddresses[i] == address)
|
||||
return i;
|
||||
}
|
||||
|
@ -1045,7 +1045,6 @@ void SymbolMap::FillSymbolListBox(HWND listbox,SymbolType symType) {
|
||||
SendMessage(listbox, LB_INITSTORAGE, (WPARAM)activeFunctions.size(), (LPARAM)activeFunctions.size() * 30);
|
||||
|
||||
for (auto it = activeFunctions.begin(), end = activeFunctions.end(); it != end; ++it) {
|
||||
const FunctionEntry& entry = it->second;
|
||||
const char* name = GetLabelName(it->first);
|
||||
if (name != NULL)
|
||||
wsprintf(temp, L"%S", name);
|
||||
@ -1069,7 +1068,6 @@ void SymbolMap::FillSymbolListBox(HWND listbox,SymbolType symType) {
|
||||
}
|
||||
|
||||
for (auto it = activeData.begin(), end = activeData.end(); it != end; ++it) {
|
||||
const DataEntry& entry = it->second;
|
||||
const char* name = GetLabelName(it->first);
|
||||
|
||||
if (name != NULL)
|
||||
|
@ -431,7 +431,7 @@ size_t DirectoryFileHandle::Seek(s32 position, FileMove type)
|
||||
LARGE_INTEGER distance;
|
||||
distance.QuadPart = position;
|
||||
LARGE_INTEGER cursor;
|
||||
DWORD newPos = SetFilePointerEx(hFile, distance, &cursor, moveMethod);
|
||||
SetFilePointerEx(hFile, distance, &cursor, moveMethod);
|
||||
result = (size_t)cursor.QuadPart;
|
||||
#else
|
||||
int moveMethod = 0;
|
||||
|
@ -157,7 +157,6 @@ static const int frameTimeHistorySize = (int)ARRAY_SIZE(frameTimeHistory);
|
||||
static int frameTimeHistoryPos = 0;
|
||||
static int frameTimeHistoryValid = 0;
|
||||
static double lastFrameTimeHistory = 0.0;
|
||||
static double monitorFpsUntil = 0.0;
|
||||
static int lastNumFlips = 0;
|
||||
static float flips = 0.0f;
|
||||
static int actualFlips = 0; // taking frameskip into account
|
||||
@ -599,7 +598,6 @@ static void DoFrameTiming(bool &throttle, bool &skipFrame, float timestep) {
|
||||
}
|
||||
|
||||
// Auto-frameskip automatically if speed limit is set differently than the default.
|
||||
bool useAutoFrameskip = g_Config.bAutoFrameSkip && g_Config.iRenderingMode != FB_NON_BUFFERED_MODE;
|
||||
bool forceFrameskip = fpsLimit > 60 && unthrottleNeedsSkip;
|
||||
int frameSkipNum = CalculateFrameSkip();
|
||||
if (g_Config.bAutoFrameSkip || forceFrameskip) {
|
||||
|
@ -1207,7 +1207,6 @@ static int sceFontFindFont(u32 libHandle, u32 fontStylePtr, u32 errorCodePtr) {
|
||||
|
||||
// Find the closest exact match for the fields specified.
|
||||
float hRes = requestedStyle->fontHRes > 0.0f ? requestedStyle->fontHRes : fontLib->FontHRes();
|
||||
float vRes = requestedStyle->fontVRes > 0.0f ? requestedStyle->fontVRes : fontLib->FontVRes();
|
||||
for (size_t i = 0; i < internalFonts.size(); i++) {
|
||||
if (internalFonts[i]->MatchesStyle(*requestedStyle) != MATCH_NONE) {
|
||||
auto matchStyle = internalFonts[i]->GetFontStyle();
|
||||
|
@ -610,7 +610,6 @@ static bool __KernelCheckResumeMsgPipeReceive(MsgPipe *m, MsgPipeWaitingThread &
|
||||
static void __KernelMsgPipeEndCallback(SceUID threadID, SceUID prevCallbackId) {
|
||||
u32 error;
|
||||
u32 waitValue = __KernelGetWaitValue(threadID, error);
|
||||
u32 timeoutPtr = __KernelGetWaitTimeoutPtr(threadID, error);
|
||||
SceUID uid = __KernelGetWaitID(threadID, WAITTYPE_MSGPIPE, error);
|
||||
MsgPipe *ko = uid == 0 ? NULL : kernelObjects.Get<MsgPipe>(uid, error);
|
||||
|
||||
|
@ -757,8 +757,6 @@ u32 __KernelInterruptReturnAddress() {
|
||||
}
|
||||
|
||||
static void __KernelDelayBeginCallback(SceUID threadID, SceUID prevCallbackId) {
|
||||
SceUID pauseKey = prevCallbackId == 0 ? threadID : prevCallbackId;
|
||||
|
||||
u32 error;
|
||||
SceUID waitID = __KernelGetWaitID(threadID, WAITTYPE_DELAY, error);
|
||||
if (waitID == threadID) {
|
||||
|
@ -795,7 +795,6 @@ static u32 scePsmfGetNumberOfSpecificStreams(u32 psmfStruct, int streamType) {
|
||||
|
||||
int streamNum = 0;
|
||||
for (auto it : psmf->streamMap) {
|
||||
bool match = false;
|
||||
if (it.second->matchesType(streamType)) {
|
||||
streamNum++;
|
||||
}
|
||||
|
@ -324,7 +324,6 @@ void ArmRegCacheFPU::FlushArmReg(ARMReg r) {
|
||||
} else if (r >= D0 && r <= D31) {
|
||||
// TODO: Convert to S regs and flush them individually.
|
||||
} else if (r >= Q0 && r <= Q15) {
|
||||
int quad = r - Q0;
|
||||
QFlush(r);
|
||||
}
|
||||
}
|
||||
@ -732,8 +731,6 @@ void ArmRegCacheFPU::QFlush(int quad) {
|
||||
|
||||
int ArmRegCacheFPU::QGetFreeQuad(int start, int count, const char *reason) {
|
||||
// Search for a free quad. A quad is free if the first register in it is free.
|
||||
int quad = -1;
|
||||
|
||||
for (int i = 0; i < count; i++) {
|
||||
int q = (i + start) & 15;
|
||||
|
||||
|
@ -1502,7 +1502,6 @@ namespace MIPSComp {
|
||||
memcpy(srcregs, sregs, sizeof(sregs));
|
||||
memcpy(tempregs, dregs, sizeof(dregs));
|
||||
|
||||
int n = GetNumVectorElements(sz);
|
||||
int nOut = GetNumVectorElements(outsize);
|
||||
|
||||
// If src registers aren't contiguous, make them.
|
||||
@ -1818,7 +1817,7 @@ namespace MIPSComp {
|
||||
int n = GetNumVectorElements(sz);
|
||||
|
||||
u8 dregs[4];
|
||||
GetVectorRegsPrefixD(dregs, sz, _VD);
|
||||
GetVectorRegsPrefixD(dregs, sz, vd);
|
||||
for (int i = 0; i < n; i++) {
|
||||
ir.Write(IROp::SetConstF, dregs[i], ir.AddConstantFloat(cst_constants[conNum]));
|
||||
}
|
||||
|
@ -42,7 +42,7 @@
|
||||
namespace MIPSComp {
|
||||
|
||||
IRJit::IRJit(MIPSState *mips) : frontend_(mips->HasDefaultPrefix()), mips_(mips) {
|
||||
u32 size = 128 * 1024;
|
||||
// u32 size = 128 * 1024;
|
||||
// blTrampolines_ = kernelMemory.Alloc(size, true, "trampoline");
|
||||
InitIR();
|
||||
|
||||
|
@ -164,7 +164,6 @@ bool ThreeOpToTwoOp(const IRWriter &in, IRWriter &out, const IROptions &opts) {
|
||||
bool logBlocks = false;
|
||||
for (int i = 0; i < (int)in.GetInstructions().size(); i++) {
|
||||
IRInst inst = in.GetInstructions()[i];
|
||||
const IRMeta *meta = GetIRMeta(inst.op);
|
||||
switch (inst.op) {
|
||||
case IROp::Sub:
|
||||
case IROp::Slt:
|
||||
|
@ -364,7 +364,6 @@ namespace MIPSInt
|
||||
int rt = _RT;
|
||||
int rs = _RS;
|
||||
int rd = _RD;
|
||||
static bool has_warned = false;
|
||||
|
||||
// Don't change $zr.
|
||||
if (rd == 0)
|
||||
|
@ -720,7 +720,6 @@ namespace MIPSInt
|
||||
u32 tprefixAdd = VFPU_MAKE_CONSTANTS(VFPUConst::ONE, VFPUConst::ZERO, VFPUConst::ONE, VFPUConst::ZERO);
|
||||
ApplyPrefixST(t, VFPURewritePrefix(VFPU_CTRL_TPREFIX, tprefixRemove, tprefixAdd), outSize);
|
||||
|
||||
int n = GetNumVectorElements(sz);
|
||||
// Essentially D prefix saturation is forced.
|
||||
d[0] = nanclamp(t[0] + s[0], 0.0f, 1.0f);
|
||||
d[1] = nanclamp(t[1] + s[1], 0.0f, 1.0f);
|
||||
@ -1226,7 +1225,6 @@ namespace MIPSInt
|
||||
ReadVector(s, sz, vs);
|
||||
ReadVector(t, sz, vs);
|
||||
|
||||
int n = GetNumVectorElements(sz);
|
||||
if (op & 0x10000) {
|
||||
// vbfy2
|
||||
// S prefix forces the negate flags (so z and w are negative.)
|
||||
@ -1973,7 +1971,7 @@ namespace MIPSInt
|
||||
ApplySwizzleS(s, sz);
|
||||
ReadVector(t, sz, vt);
|
||||
ApplySwizzleT(t, sz);
|
||||
for (int i = 0; i < GetNumVectorElements(sz); i++) {
|
||||
for (int i = 0; i < numElements; i++) {
|
||||
if ( my_isnan(s[i]) || my_isnan(t[i]) )
|
||||
d[i] = 0.0f;
|
||||
else
|
||||
@ -1998,7 +1996,7 @@ namespace MIPSInt
|
||||
ApplySwizzleS(s, sz);
|
||||
ReadVector(t, sz, vt);
|
||||
ApplySwizzleT(t, sz);
|
||||
for (int i = 0; i < GetNumVectorElements(sz); i++) {
|
||||
for (int i = 0; i < numElements; i++) {
|
||||
if ( my_isnan(s[i]) || my_isnan(t[i]) )
|
||||
d[i] = 0.0f;
|
||||
else
|
||||
|
@ -964,7 +964,6 @@ int MIPSInterpret_RunUntil(u64 globalTicks)
|
||||
while (coreState == CORE_RUNNING)
|
||||
{
|
||||
CoreTiming::Advance();
|
||||
u32 lastPC = 0;
|
||||
|
||||
// NEVER stop in a delay slot!
|
||||
while (curMips->downcount >= 0 && coreState == CORE_RUNNING)
|
||||
@ -974,17 +973,6 @@ int MIPSInterpret_RunUntil(u64 globalTicks)
|
||||
again:
|
||||
MIPSOpcode op = MIPSOpcode(Memory::Read_U32(curMips->pc));
|
||||
//MIPSOpcode op = Memory::Read_Opcode_JIT(mipsr4k.pc);
|
||||
/*
|
||||
// Choke on VFPU
|
||||
MIPSInfo info = MIPSGetInfo(op);
|
||||
if (info & IS_VFPU)
|
||||
{
|
||||
if (!Core_IsStepping() && !GetAsyncKeyState(VK_LSHIFT))
|
||||
{
|
||||
Core_EnableStepping(true);
|
||||
return;
|
||||
}
|
||||
}*/
|
||||
|
||||
//2: check for breakpoint (VERY SLOW)
|
||||
#if defined(_DEBUG)
|
||||
@ -1002,18 +990,6 @@ int MIPSInterpret_RunUntil(u64 globalTicks)
|
||||
#endif
|
||||
|
||||
bool wasInDelaySlot = curMips->inDelaySlot;
|
||||
|
||||
/*
|
||||
if (curMips->pc != lastPC + 4) {
|
||||
if (blockCount > 0) {
|
||||
MIPSState *mips_ = curMips;
|
||||
fprintf(f, "BLOCK : %08x v0: %08x v1: %08x a0: %08x s0: %08x s4: %08x\n", mips_->pc, mips_->r[MIPS_REG_V0], mips_->r[MIPS_REG_V1], mips_->r[MIPS_REG_A0], mips_->r[MIPS_REG_S0], mips_->r[MIPS_REG_S4]);
|
||||
fflush(f);
|
||||
blockCount--;
|
||||
}
|
||||
}
|
||||
lastPC = curMips->pc;
|
||||
*/
|
||||
MIPSInterpret(op);
|
||||
|
||||
if (curMips->inDelaySlot)
|
||||
|
@ -873,7 +873,6 @@ float vfpu_rsqrt(float a) {
|
||||
uint32_t z = 0x00800000 >> less_bits;
|
||||
uint32_t halfsp = sp >> (1 + less_bits);
|
||||
for (int i = 0; i < 6; ++i) {
|
||||
uint32_t oldz = z;
|
||||
uint32_t zsq = mant_mul(z, z);
|
||||
uint32_t correction = 0x00C00000 - mant_mul(halfsp, zsq);
|
||||
z = mant_mul(z, correction);
|
||||
|
@ -66,7 +66,7 @@ void ImHere() {
|
||||
}
|
||||
|
||||
void Jit::GenerateFixedCode(JitOptions &jo) {
|
||||
const u8 *start = AlignCodePage();
|
||||
AlignCodePage();
|
||||
BeginWrite();
|
||||
|
||||
restoreRoundingMode = AlignCode16(); {
|
||||
|
@ -138,7 +138,6 @@ namespace MIPSComp {
|
||||
void Jit::CompITypeMemUnpairedLR(MIPSOpcode op, bool isStore)
|
||||
{
|
||||
CONDITIONAL_DISABLE(LSU);
|
||||
int o = op>>26;
|
||||
int offset = _IMM16;
|
||||
MIPSGPReg rt = _RT;
|
||||
MIPSGPReg rs = _RS;
|
||||
@ -288,7 +287,6 @@ namespace MIPSComp {
|
||||
CONDITIONAL_DISABLE(LSU);
|
||||
int offset = _IMM16;
|
||||
MIPSGPReg rt = _RT;
|
||||
MIPSGPReg rs = _RS;
|
||||
int o = op>>26;
|
||||
if (((op >> 29) & 1) == 0 && rt == MIPS_REG_ZERO) {
|
||||
// Don't load anything into $zr
|
||||
@ -395,7 +393,7 @@ namespace MIPSComp {
|
||||
|
||||
default:
|
||||
Comp_Generic(op);
|
||||
return ;
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -238,8 +238,6 @@ bool IsOverlapSafe(int dreg, int di, int sn, u8 sregs[], int tn = 0, u8 tregs[]
|
||||
return IsOverlapSafeAllowS(dreg, di, sn, sregs, tn, tregs) && sregs[di] != dreg;
|
||||
}
|
||||
|
||||
alignas(16) static u32 ssLoadStoreTemp;
|
||||
|
||||
void Jit::Comp_SV(MIPSOpcode op) {
|
||||
CONDITIONAL_DISABLE(LSU_VFPU);
|
||||
|
||||
@ -796,7 +794,6 @@ void Jit::Comp_VCrossQuat(MIPSOpcode op) {
|
||||
DISABLE;
|
||||
|
||||
VectorSize sz = GetVecSize(op);
|
||||
int n = GetNumVectorElements(sz);
|
||||
|
||||
u8 sregs[4], tregs[4], dregs[4];
|
||||
GetVectorRegs(sregs, sz, _VS);
|
||||
@ -1808,8 +1805,6 @@ extern const double mulTableVf2i[32] = {
|
||||
(1ULL<<28),(1ULL<<29),(1ULL<<30),(1ULL<<31),
|
||||
};
|
||||
|
||||
static const float half = 0.5f;
|
||||
|
||||
static const double maxMinIntAsDouble[2] = { (double)0x7fffffff, (double)(int)0x80000000 }; // that's not equal to 0x80000000
|
||||
|
||||
void Jit::Comp_Vf2i(MIPSOpcode op) {
|
||||
@ -1934,7 +1929,7 @@ void Jit::Comp_Vcst(MIPSOpcode op) {
|
||||
int n = GetNumVectorElements(sz);
|
||||
|
||||
u8 dregs[4];
|
||||
GetVectorRegsPrefixD(dregs, sz, _VD);
|
||||
GetVectorRegsPrefixD(dregs, sz, vd);
|
||||
|
||||
if (RipAccessible(cst_constants)) {
|
||||
MOVSS(XMM0, M(&cst_constants[conNum])); // rip accessible
|
||||
|
@ -236,7 +236,6 @@ namespace Reporting
|
||||
|
||||
bool SendReportRequest(const char *uri, const std::string &data, const std::string &mimeType, Buffer *output = NULL)
|
||||
{
|
||||
bool result = false;
|
||||
http::Client http;
|
||||
Buffer theVoid;
|
||||
|
||||
|
@ -85,7 +85,6 @@ int HighestSetBit(int value) {
|
||||
}
|
||||
|
||||
int LowestSetBit(int value, int maximum = 32) {
|
||||
int lowest = 0;
|
||||
for (int i = 0; i < maximum; i++) {
|
||||
if (value & (1 << i))
|
||||
return i;
|
||||
|
@ -36,7 +36,6 @@ private:
|
||||
File::IOFile file;
|
||||
bool skip_silence = false;
|
||||
uint32_t audio_size = 0;
|
||||
std::array<short, BUFFER_SIZE> conv_buffer{};
|
||||
void Write(uint32_t value);
|
||||
void Write4(const char* ptr);
|
||||
};
|
||||
|
@ -518,7 +518,6 @@ void DrawEngineCommon::DecodeVertsStep(u8 *dest, int &i, int &decodedVerts) {
|
||||
int indexLowerBound = dc.indexLowerBound;
|
||||
int indexUpperBound = dc.indexUpperBound;
|
||||
|
||||
void *inds = dc.inds;
|
||||
if (dc.indexType == GE_VTYPE_IDX_NONE >> GE_VTYPE_IDX_SHIFT) {
|
||||
// Decode the verts and apply morphing. Simple.
|
||||
dec_->DecodeVerts(dest + decodedVerts * (int)dec_->GetDecVtxFmt().stride,
|
||||
|
@ -471,7 +471,6 @@ void PresentationCommon::DestroyPostShader() {
|
||||
|
||||
Draw::ShaderModule *PresentationCommon::CompileShaderModule(ShaderStage stage, ShaderLanguage lang, const std::string &src, std::string *errorString) {
|
||||
std::string translated = src;
|
||||
bool translationFailed = false;
|
||||
if (lang != lang_) {
|
||||
// Gonna have to upconvert the shader.
|
||||
if (!TranslateShader(&translated, lang_, draw_->GetShaderLanguageDesc(), nullptr, src, lang, stage, errorString)) {
|
||||
|
@ -251,7 +251,6 @@ void BaseUpdateUniforms(UB_VS_FS_Base *ub, uint64_t dirtyUniforms, bool flipView
|
||||
viewZInvScale = 0.0;
|
||||
}
|
||||
|
||||
float data[4] = { viewZScale, viewZCenter, viewZCenter, viewZInvScale };
|
||||
ub->depthRange[0] = viewZScale;
|
||||
ub->depthRange[1] = viewZCenter;
|
||||
ub->depthRange[2] = viewZCenter;
|
||||
|
@ -564,7 +564,6 @@ TexCacheEntry *TextureCacheCommon::SetTexture() {
|
||||
|
||||
std::vector<AttachCandidate> TextureCacheCommon::GetFramebufferCandidates(const TextureDefinition &entry, u32 texAddrOffset) {
|
||||
gpuStats.numFramebufferEvaluations++;
|
||||
bool success = false;
|
||||
|
||||
std::vector<AttachCandidate> candidates;
|
||||
|
||||
@ -884,8 +883,6 @@ FramebufferMatchInfo TextureCacheCommon::MatchFramebuffer(
|
||||
(channel == NOTIFY_FB_COLOR && framebuffer->format == GE_FORMAT_8888 && entry.format == GE_TFMT_CLUT32) ||
|
||||
(channel == NOTIFY_FB_COLOR && framebuffer->format != GE_FORMAT_8888 && entry.format == GE_TFMT_CLUT16);
|
||||
|
||||
const bool clutFormat = IsClutFormat((GETextureFormat)(entry.format));
|
||||
|
||||
// To avoid ruining git blame, kept the same name as the old struct.
|
||||
FramebufferMatchInfo fbInfo{ FramebufferMatch::VALID };
|
||||
|
||||
|
@ -231,7 +231,6 @@ JittedVertexDecoder VertexDecoderJitCache::Compile(const VertexDecoder &dec, int
|
||||
|
||||
// Add code to convert matrices to 4x4.
|
||||
// Later we might want to do this when the matrices are loaded instead.
|
||||
int boneCount = 0;
|
||||
if (NEONSkinning && dec.weighttype && g_Config.bSoftwareSkinning) {
|
||||
// Copying from R3 to R4
|
||||
MOVP2R(R3, gstate.boneMatrix);
|
||||
|
@ -190,7 +190,6 @@ JittedVertexDecoder VertexDecoderJitCache::Compile(const VertexDecoder &dec, int
|
||||
|
||||
// Add code to convert matrices to 4x4.
|
||||
// Later we might want to do this when the matrices are loaded instead.
|
||||
int boneCount = 0;
|
||||
if (dec.weighttype && g_Config.bSoftwareSkinning) {
|
||||
// Copying from R3 to R4
|
||||
MOVP2R(X3, gstate.boneMatrix);
|
||||
|
@ -219,7 +219,6 @@ JittedVertexDecoder VertexDecoderJitCache::Compile(const VertexDecoder &dec, int
|
||||
|
||||
// Add code to convert matrices to 4x4.
|
||||
// Later we might want to do this when the matrices are loaded instead.
|
||||
int boneCount = 0;
|
||||
if (dec.weighttype && g_Config.bSoftwareSkinning) {
|
||||
MOV(PTRBITS, R(tempReg1), ImmPtr(&threeMasks));
|
||||
MOVAPS(XMM4, MatR(tempReg1));
|
||||
|
@ -317,10 +317,6 @@ VertexArrayInfoD3D11::~VertexArrayInfoD3D11() {
|
||||
ebo->Release();
|
||||
}
|
||||
|
||||
static uint32_t SwapRB(uint32_t c) {
|
||||
return (c & 0xFF00FF00) | ((c >> 16) & 0xFF) | ((c << 16) & 0xFF0000);
|
||||
}
|
||||
|
||||
// The inline wrapper in the header checks for numDrawCalls == 0
|
||||
void DrawEngineD3D11::DoFlush() {
|
||||
gpuStats.numFlushes++;
|
||||
@ -603,8 +599,6 @@ rotateVBO:
|
||||
framebufferManager_->SetSafeSize(result.safeWidth, result.safeHeight);
|
||||
|
||||
if (result.action == SW_DRAW_PRIMITIVES) {
|
||||
const int vertexSize = sizeof(transformed[0]);
|
||||
|
||||
ApplyDrawStateLate(result.setStencil, result.stencilValue);
|
||||
|
||||
D3D11VertexShader *vshader;
|
||||
|
@ -184,8 +184,6 @@ void FramebufferManagerD3D11::DrawActiveTexture(float x, float y, float w, float
|
||||
{{x, y + h, 0}, u0, v1},
|
||||
};
|
||||
|
||||
static const short indices[4] = { 0, 1, 3, 2 };
|
||||
|
||||
if (uvRotation != ROTATION_LOCKED_HORIZONTAL) {
|
||||
float temp[8];
|
||||
int rotation = 0;
|
||||
|
@ -578,9 +578,6 @@ rotateVBO:
|
||||
// TODO: Add a post-transform cache here for multi-RECTANGLES only.
|
||||
// Might help for text drawing.
|
||||
|
||||
// these spam the gDebugger log.
|
||||
const int vertexSize = sizeof(transformed[0]);
|
||||
|
||||
device_->SetVertexDeclaration(transformedVertexDecl_);
|
||||
if (result.drawIndexed) {
|
||||
device_->DrawIndexedPrimitiveUP(d3d_prim[prim], 0, maxIndex, D3DPrimCount(d3d_prim[prim], result.drawNumTrans), inds, D3DFMT_INDEX16, result.drawBuffer, sizeof(TransformedVertex));
|
||||
|
@ -164,8 +164,6 @@ static const D3DVERTEXELEMENT9 g_FramebufferVertexElements[] = {
|
||||
x,y+h,0, u0,v1,
|
||||
};
|
||||
|
||||
static const short indices[4] = { 0, 1, 3, 2 };
|
||||
|
||||
if (uvRotation != ROTATION_LOCKED_HORIZONTAL) {
|
||||
float temp[8];
|
||||
int rotation = 0;
|
||||
@ -405,7 +403,6 @@ static const D3DVERTEXELEMENT9 g_FramebufferVertexElements[] = {
|
||||
HRESULT hr = tex->LockRect(0, &locked, &rect, D3DLOCK_READONLY);
|
||||
|
||||
if (SUCCEEDED(hr)) {
|
||||
const int dstByteOffset = y * vfb->fb_stride * sizeof(s16);
|
||||
const u32 *packed = (const u32 *)locked.pBits;
|
||||
u16 *depth = (u16 *)Memory::GetPointer(z_address);
|
||||
|
||||
|
@ -685,8 +685,6 @@ void TextureCacheDX9::LoadTextureLevel(TexCacheEntry &entry, ReplacedTexture &re
|
||||
bool TextureCacheDX9::GetCurrentTextureDebug(GPUDebugBuffer &buffer, int level) {
|
||||
SetTexture();
|
||||
ApplyTexture();
|
||||
int w = gstate.getTextureWidth(level);
|
||||
int h = gstate.getTextureHeight(level);
|
||||
|
||||
LPDIRECT3DBASETEXTURE9 baseTex;
|
||||
LPDIRECT3DTEXTURE9 tex;
|
||||
|
@ -86,7 +86,6 @@ private:
|
||||
LPDIRECT3DTEXTURE9 lastBoundTexture;
|
||||
float maxAnisotropyLevel;
|
||||
|
||||
int decimationCounter_;
|
||||
int texelsScaledThisFrame_;
|
||||
int timesInvalidatedAllThisFrame_;
|
||||
|
||||
|
@ -594,13 +594,9 @@ void DrawEngineGLES::DoFlush() {
|
||||
|
||||
ApplyDrawStateLate(result.setStencil, result.stencilValue);
|
||||
|
||||
LinkedShader *program = shaderManager_->ApplyFragmentShader(vsid, vshader, lastVType_, framebufferManager_->UseBufferedRendering());
|
||||
shaderManager_->ApplyFragmentShader(vsid, vshader, lastVType_, framebufferManager_->UseBufferedRendering());
|
||||
|
||||
if (result.action == SW_DRAW_PRIMITIVES) {
|
||||
const int vertexSize = sizeof(transformed[0]);
|
||||
|
||||
bool doTextureProjection = gstate.getUVGenMode() == GE_TEXMAP_TEXTURE_MATRIX;
|
||||
|
||||
if (result.drawIndexed) {
|
||||
vertexBufferOffset = (uint32_t)frameData.pushVertex->Push(result.drawBuffer, maxIndex * sizeof(TransformedVertex), &vertexBuffer);
|
||||
indexBufferOffset = (uint32_t)frameData.pushIndex->Push(inds, sizeof(uint16_t) * result.drawNumTrans, &indexBuffer);
|
||||
|
@ -172,8 +172,6 @@ void FramebufferManagerGLES::DrawActiveTexture(float x, float y, float w, float
|
||||
u0,v1,
|
||||
};
|
||||
|
||||
static const GLushort indices[4] = { 0,1,3,2 };
|
||||
|
||||
if (uvRotation != ROTATION_LOCKED_HORIZONTAL) {
|
||||
float temp[8];
|
||||
int rotation = 0;
|
||||
|
@ -327,7 +327,6 @@ public:
|
||||
}
|
||||
|
||||
void Shade(GLRenderManager *render) {
|
||||
static const GLubyte indices[4] = { 0, 1, 3, 2 };
|
||||
render->SetViewport(GLRViewport{ 0, 0, (float)renderW_, (float)renderH_, 0.0f, 1.0f });
|
||||
render->Draw(GL_TRIANGLE_STRIP, 0, 4);
|
||||
}
|
||||
|
@ -2248,7 +2248,6 @@ void GPUCommon::Execute_ImmVertexAlphaPrim(u32 op, u32 diff) {
|
||||
return;
|
||||
}
|
||||
|
||||
uint32_t data = op & 0xFFFFFF;
|
||||
TransformedVertex &v = immBuffer_[immCount_++];
|
||||
|
||||
// Formula deduced from ThrillVille's clear.
|
||||
|
@ -105,7 +105,6 @@ inline float clip_dotprod(const VertexData &vert, float A, float B, float C, flo
|
||||
if (mask & PLANE_BIT) { \
|
||||
float dp0 = clip_dotprod(*Vertices[0], A, B, C, D ); \
|
||||
float dp1 = clip_dotprod(*Vertices[1], A, B, C, D ); \
|
||||
int numVertices = 0; \
|
||||
\
|
||||
if (mask0 & PLANE_BIT) { \
|
||||
if (dp0 < 0) { \
|
||||
|
@ -1661,7 +1661,6 @@ void DrawLine(const VertexData &v0, const VertexData &v1)
|
||||
if (gstate.isAntiAliasEnabled()) {
|
||||
// TODO: This is a niave and wrong implementation.
|
||||
DrawingCoords p0 = TransformUnit::ScreenToDrawing(ScreenCoords((int)x, (int)y, (int)z));
|
||||
DrawingCoords p1 = TransformUnit::ScreenToDrawing(ScreenCoords((int)(x + xinc), (int)(y + yinc), (int)(z + zinc)));
|
||||
s = ((float)p0.x + xinc / 32.0f) / 512.0f;
|
||||
t = ((float)p0.y + yinc / 32.0f) / 512.0f;
|
||||
|
||||
|
@ -116,7 +116,6 @@ void DrawGPUProfilerVis(UIContext *ui, GPUInterface *gpu) {
|
||||
|
||||
std::string text = gpuVulkan->GetGpuProfileString();
|
||||
|
||||
Draw::DrawContext *draw = ui->GetDrawContext();
|
||||
ui->SetFontScale(0.4f, 0.4f);
|
||||
ui->DrawTextShadow(text.c_str(), x, y, 0xFFFFFFFF, FLAG_DYNAMIC_ASCII);
|
||||
ui->SetFontScale(1.0f, 1.0f);
|
||||
|
@ -866,8 +866,6 @@ void DrawEngineVulkan::DoFlush() {
|
||||
baseUBOOffset, lightUBOOffset, boneUBOOffset,
|
||||
};
|
||||
|
||||
int stride = dec_->GetDecVtxFmt().stride;
|
||||
|
||||
if (useElements) {
|
||||
if (!ibuf) {
|
||||
ibOffset = (uint32_t)frame->pushIndex->Push(decIndex, sizeof(uint16_t) * indexGen.VertexCount(), &ibuf);
|
||||
@ -996,12 +994,10 @@ void DrawEngineVulkan::DoFlush() {
|
||||
VkBuffer vbuf, ibuf;
|
||||
vbOffset = (uint32_t)frame->pushVertex->Push(result.drawBuffer, maxIndex * sizeof(TransformedVertex), &vbuf);
|
||||
ibOffset = (uint32_t)frame->pushIndex->Push(inds, sizeof(short) * result.drawNumTrans, &ibuf);
|
||||
VkDeviceSize offsets[1] = { vbOffset };
|
||||
renderManager->DrawIndexed(pipelineLayout_, ds, ARRAY_SIZE(dynamicUBOOffsets), dynamicUBOOffsets, vbuf, vbOffset, ibuf, ibOffset, result.drawNumTrans, 1, VK_INDEX_TYPE_UINT16);
|
||||
} else {
|
||||
VkBuffer vbuf;
|
||||
vbOffset = (uint32_t)frame->pushVertex->Push(result.drawBuffer, result.drawNumTrans * sizeof(TransformedVertex), &vbuf);
|
||||
VkDeviceSize offsets[1] = { vbOffset };
|
||||
renderManager->Draw(pipelineLayout_, ds, ARRAY_SIZE(dynamicUBOOffsets), dynamicUBOOffsets, vbuf, vbOffset, result.drawNumTrans);
|
||||
}
|
||||
} else if (result.action == SW_CLEAR) {
|
||||
|
@ -246,7 +246,6 @@ static VulkanPipeline *CreateVulkanPipeline(VkDevice device, VkPipelineCache pip
|
||||
inputAssembly.primitiveRestartEnable = false;
|
||||
int vertexStride = 0;
|
||||
|
||||
int offset = 0;
|
||||
VkVertexInputAttributeDescription attrs[8];
|
||||
int attributeCount;
|
||||
if (useHwTransform) {
|
||||
@ -616,7 +615,6 @@ void PipelineManagerVulkan::SaveCache(FILE *file, bool saveRawPipelineCache, Sha
|
||||
|
||||
bool failed = false;
|
||||
bool writeFailed = false;
|
||||
int count = 0;
|
||||
// Since we don't include the full pipeline key, there can be duplicates,
|
||||
// caused by things like switching from buffered to non-buffered rendering.
|
||||
// Make sure the set of pipelines we write is "unique".
|
||||
@ -724,6 +722,9 @@ bool PipelineManagerVulkan::LoadCache(FILE *file, bool loadRawPipelineCache, Sha
|
||||
if (!pipelineCache_) {
|
||||
VkPipelineCacheCreateInfo pc{ VK_STRUCTURE_TYPE_PIPELINE_CACHE_CREATE_INFO };
|
||||
VkResult res = vkCreatePipelineCache(vulkan_->GetDevice(), &pc, nullptr, &pipelineCache_);
|
||||
if (res != VK_SUCCESS) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1073,7 +1073,6 @@ TexCacheEntry::TexStatus TextureCacheVulkan::CheckAlpha(const u32 *pixelData, Vk
|
||||
}
|
||||
|
||||
void TextureCacheVulkan::LoadTextureLevel(TexCacheEntry &entry, uint8_t *writePtr, int rowPitch, int level, int scaleFactor, VkFormat dstFmt) {
|
||||
VulkanTexture *tex = entry.vkTex;
|
||||
int w = gstate.getTextureWidth(level);
|
||||
int h = gstate.getTextureHeight(level);
|
||||
|
||||
|
@ -47,7 +47,6 @@ void Vulkan2D::DestroyDeviceObjects() {
|
||||
}
|
||||
keptPipelines_.clear();
|
||||
|
||||
VkDevice device = vulkan_->GetDevice();
|
||||
if (descriptorSetLayout_ != VK_NULL_HANDLE) {
|
||||
vulkan_->Delete().QueueDeleteDescriptorSetLayout(descriptorSetLayout_);
|
||||
}
|
||||
|
@ -109,8 +109,6 @@ void ControlMapper::Refresh() {
|
||||
LinearLayout *root = Add(new LinearLayout(ORIENT_HORIZONTAL, new LinearLayoutParams(550, WRAP_CONTENT)));
|
||||
root->SetSpacing(3.0f);
|
||||
|
||||
const int padding = 4;
|
||||
|
||||
auto iter = keyImages.find(keyName_);
|
||||
// First, look among images.
|
||||
if (iter != keyImages.end()) {
|
||||
@ -138,7 +136,6 @@ void ControlMapper::Refresh() {
|
||||
for (size_t i = 0; i < mappings.size(); i++) {
|
||||
std::string deviceName = GetDeviceName(mappings[i].deviceId);
|
||||
std::string keyName = KeyMap::GetKeyOrAxisName(mappings[i].keyCode);
|
||||
int image = -1;
|
||||
|
||||
LinearLayout *row = rightColumn->Add(new LinearLayout(ORIENT_HORIZONTAL, new LinearLayoutParams(FILL_PARENT, WRAP_CONTENT)));
|
||||
row->SetSpacing(1.0f);
|
||||
|
@ -188,7 +188,7 @@ UI::EventReturn CwCheatScreen::OnImportCheat(UI::EventParams ¶ms) {
|
||||
}
|
||||
std::string line;
|
||||
std::vector<std::string> title;
|
||||
bool finished = false, skip = false;
|
||||
bool finished = false;
|
||||
std::vector<std::string> newList;
|
||||
|
||||
std::string cheatFile = GetSysDirectory(DIRECTORY_CHEATS) + "cheat.db";
|
||||
|
@ -252,8 +252,6 @@ void EmuScreen::bootGame(const std::string &filename) {
|
||||
coreParam.printfEmuLog = false;
|
||||
coreParam.headLess = false;
|
||||
|
||||
const Bounds &bounds = screenManager()->getUIContext()->GetBounds();
|
||||
|
||||
if (g_Config.iInternalResolution == 0) {
|
||||
coreParam.renderWidth = pixel_xres;
|
||||
coreParam.renderHeight = pixel_yres;
|
||||
|
@ -233,7 +233,6 @@ bool GameInfo::DeleteAllSaveData() {
|
||||
std::vector<FileInfo> fileInfo;
|
||||
getFilesInDir(saveDataDir[j].c_str(), &fileInfo);
|
||||
|
||||
u64 totalSize = 0;
|
||||
for (size_t i = 0; i < fileInfo.size(); i++) {
|
||||
File::Delete(fileInfo[i].fullName.c_str());
|
||||
}
|
||||
|
@ -899,7 +899,7 @@ void GameSettingsScreen::CreateViews() {
|
||||
rewindFreq->SetZeroLabel(sy->T("Off"));
|
||||
|
||||
systemSettings->Add(new CheckBox(&g_Config.bMemStickInserted, sy->T("Memory Stick inserted")));
|
||||
PopupSliderChoice *memStickSize = systemSettings->Add(new PopupSliderChoice(&g_Config.iMemStickSizeGB, 1, 32, sy->T("Change Memory Stick Size", "Change Memory Stick Size(GB)"), screenManager(), "GB"));
|
||||
systemSettings->Add(new PopupSliderChoice(&g_Config.iMemStickSizeGB, 1, 32, sy->T("Change Memory Stick Size", "Change Memory Stick Size(GB)"), screenManager(), "GB"));
|
||||
|
||||
systemSettings->Add(new ItemHeader(sy->T("General")));
|
||||
|
||||
|
@ -273,7 +273,6 @@ void PSPDpad::GetContentDimensions(const UIContext &dc, float &w, float &h) cons
|
||||
}
|
||||
|
||||
void PSPDpad::Touch(const TouchInput &input) {
|
||||
int lastDown = down_;
|
||||
GamepadView::Touch(input);
|
||||
|
||||
if (input.flags & TOUCH_DOWN) {
|
||||
@ -412,7 +411,6 @@ void PSPStick::Draw(UIContext &dc) {
|
||||
|
||||
uint32_t colorBg = colorAlpha(GetButtonColor(), opacity);
|
||||
uint32_t downBg = colorAlpha(0x00FFFFFF, opacity * 0.5f);
|
||||
uint32_t color = colorAlpha(0x808080, opacity);
|
||||
|
||||
if (centerX_ < 0.0f) {
|
||||
centerX_ = bounds_.centerX();
|
||||
@ -511,7 +509,6 @@ void PSPCustomStick::Draw(UIContext &dc) {
|
||||
|
||||
uint32_t colorBg = colorAlpha(GetButtonColor(), opacity);
|
||||
uint32_t downBg = colorAlpha(0x00FFFFFF, opacity * 0.5f);
|
||||
uint32_t color = colorAlpha(0x808080, opacity);
|
||||
|
||||
if (centerX_ < 0.0f) {
|
||||
centerX_ = bounds_.centerX();
|
||||
|
@ -517,9 +517,6 @@ void LogoScreen::render() {
|
||||
|
||||
const Bounds &bounds = dc.GetBounds();
|
||||
|
||||
float xres = bounds.w;
|
||||
float yres = bounds.h;
|
||||
|
||||
dc.Begin();
|
||||
|
||||
float t = (float)sinceStart_ / (logoScreenSeconds / 3.0f);
|
||||
@ -545,13 +542,13 @@ void LogoScreen::render() {
|
||||
dc.Draw()->DrawImage(ImageID("I_ICON"), bounds.centerX() - 120, bounds.centerY() - 30, 1.2f, textColor, ALIGN_CENTER);
|
||||
}
|
||||
dc.Draw()->DrawImage(ImageID("I_LOGO"), bounds.centerX() + 40, bounds.centerY() - 30, 1.5f, textColor, ALIGN_CENTER);
|
||||
//dc.Draw()->DrawTextShadow(UBUNTU48, "PPSSPP", xres / 2, yres / 2 - 30, textColor, ALIGN_CENTER);
|
||||
//dc.Draw()->DrawTextShadow(UBUNTU48, "PPSSPP", bounds.w / 2, bounds.h / 2 - 30, textColor, ALIGN_CENTER);
|
||||
dc.SetFontScale(1.0f, 1.0f);
|
||||
dc.SetFontStyle(dc.theme->uiFont);
|
||||
dc.DrawText(temp, bounds.centerX(), bounds.centerY() + 40, textColor, ALIGN_CENTER);
|
||||
dc.DrawText(cr->T("license", "Free Software under GPL 2.0+"), bounds.centerX(), bounds.centerY() + 70, textColor, ALIGN_CENTER);
|
||||
|
||||
int ppsspp_org_y = yres / 2 + 130;
|
||||
int ppsspp_org_y = bounds.h / 2 + 130;
|
||||
dc.DrawText("www.ppsspp.org", bounds.centerX(), ppsspp_org_y, textColor, ALIGN_CENTER);
|
||||
|
||||
#if (defined(_WIN32) && !PPSSPP_PLATFORM(UWP)) || PPSSPP_PLATFORM(ANDROID) || PPSSPP_PLATFORM(LINUX)
|
||||
|
@ -149,7 +149,6 @@ static bool isOuya;
|
||||
static bool resized = false;
|
||||
static bool restarting = false;
|
||||
|
||||
static bool askedForStoragePermission = false;
|
||||
static int renderCounter = 0;
|
||||
|
||||
struct PendingMessage {
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include "Common/UI/View.h"
|
||||
#include "Common/Profiler/Profiler.h"
|
||||
|
||||
#ifdef USE_PROFILER
|
||||
static const uint32_t nice_colors[] = {
|
||||
0xFF8040,
|
||||
0x80FF40,
|
||||
@ -44,6 +45,7 @@ static const uint32_t nice_colors[] = {
|
||||
0xF8F8F8,
|
||||
0x33FFFF,
|
||||
};
|
||||
#endif
|
||||
|
||||
enum ProfileCatStatus {
|
||||
PROFILE_CAT_VISIBLE = 0,
|
||||
|
@ -348,7 +348,6 @@ void ControlLayoutView::CreateViews() {
|
||||
|
||||
ImageID rectImage = g_Config.iTouchButtonStyle ? ImageID("I_RECT_LINE") : ImageID("I_RECT");
|
||||
ImageID shoulderImage = g_Config.iTouchButtonStyle ? ImageID("I_SHOULDER_LINE") : ImageID("I_SHOULDER");
|
||||
ImageID dirImage = g_Config.iTouchButtonStyle ? ImageID("I_DIR_LINE") : ImageID("I_DIR");
|
||||
ImageID stickImage = g_Config.iTouchButtonStyle ? ImageID("I_STICK_LINE") : ImageID("I_STICK");
|
||||
ImageID stickBg = g_Config.iTouchButtonStyle ? ImageID("I_STICK_BG_LINE") : ImageID("I_STICK_BG");
|
||||
ImageID roundImage = g_Config.iTouchButtonStyle ? ImageID("I_ROUND_LINE") : ImageID("I_ROUND");
|
||||
|
@ -20,9 +20,6 @@
|
||||
|
||||
#include "DSoundStream.h"
|
||||
|
||||
// TODO: Get rid of this
|
||||
static DSoundAudioBackend *g_dsound;
|
||||
|
||||
inline int RoundDown128(int x) {
|
||||
return x & (~127);
|
||||
}
|
||||
|
@ -866,7 +866,6 @@ void CtrlDisAsmView::toggleBreakpoint(bool toggleEnabled)
|
||||
void CtrlDisAsmView::onMouseDown(WPARAM wParam, LPARAM lParam, int button)
|
||||
{
|
||||
dontRedraw = false;
|
||||
int x = LOWORD(lParam);
|
||||
int y = HIWORD(lParam);
|
||||
|
||||
u32 newAddress = yToAddress(y);
|
||||
@ -921,7 +920,6 @@ void CtrlDisAsmView::onMouseUp(WPARAM wParam, LPARAM lParam, int button)
|
||||
{
|
||||
if (button == 1)
|
||||
{
|
||||
int x = LOWORD(lParam);
|
||||
int y = HIWORD(lParam);
|
||||
setCurAddress(yToAddress(y), KeyDownAsync(VK_SHIFT));
|
||||
redraw();
|
||||
@ -1076,7 +1074,6 @@ void CtrlDisAsmView::onMouseMove(WPARAM wParam, LPARAM lParam, int button)
|
||||
{
|
||||
if ((button & 1) != 0)
|
||||
{
|
||||
int x = LOWORD(lParam);
|
||||
int y = HIWORD(lParam);
|
||||
setCurAddress(yToAddress(y), KeyDownAsync(VK_SHIFT));
|
||||
// TODO: Perhaps don't do this every time, but on a timer?
|
||||
|
@ -312,7 +312,6 @@ void CtrlRegisterList::onKeyDown(WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
RECT rect;
|
||||
GetClientRect(this->wnd, &rect);
|
||||
int page=(rect.bottom/rowHeight)/2-1;
|
||||
|
||||
if (ctrlDown && tolower(wParam) == 'c')
|
||||
{
|
||||
|
@ -28,15 +28,12 @@ class CtrlRegisterList
|
||||
|
||||
int rowHeight;
|
||||
int selection = 0;
|
||||
int marker = 0;
|
||||
int category = 0;
|
||||
|
||||
int oldSelection = 0;
|
||||
|
||||
bool selectionChanged = false;
|
||||
bool selecting = false;
|
||||
bool hasFocus = false;
|
||||
bool showHex = false;
|
||||
DebugInterface *cpu = nullptr;
|
||||
static TCHAR szClassName[];
|
||||
|
||||
|
@ -384,7 +384,6 @@ BOOL CDisasm::DlgProc(UINT message, WPARAM wParam, LPARAM lParam)
|
||||
case WM_COMMAND:
|
||||
{
|
||||
CtrlDisAsmView *ptr = CtrlDisAsmView::getFrom(GetDlgItem(m_hDlg,IDC_DISASMVIEW));
|
||||
CtrlRegisterList *reglist = CtrlRegisterList::getFrom(GetDlgItem(m_hDlg,IDC_REGLIST));
|
||||
switch (LOWORD(wParam)) {
|
||||
case ID_TOGGLE_BREAK:
|
||||
SendMessage(MainWindow::GetHWND(), WM_COMMAND, ID_TOGGLE_BREAK, 0);
|
||||
@ -880,8 +879,8 @@ void CDisasm::Goto(u32 addr)
|
||||
|
||||
void CDisasm::UpdateDialog(bool _bComplete)
|
||||
{
|
||||
HWND gotoInt = GetDlgItem(m_hDlg, IDC_GOTOINT);
|
||||
/*
|
||||
HWND gotoInt = GetDlgItem(m_hDlg, IDC_GOTOINT);
|
||||
ComboBox_ResetContent(gotoInt);
|
||||
for (int i=0; i<numRegions; i++)
|
||||
{
|
||||
|
@ -188,7 +188,6 @@ void CtrlDisplayListView::onPaint(WPARAM wParam, LPARAM lParam)
|
||||
bool stall = address == list.stall;
|
||||
|
||||
int rowY1 = rowHeight*i;
|
||||
int rowY2 = rowHeight*(i+1);
|
||||
|
||||
// draw background
|
||||
COLORREF backgroundColor = stall ? 0xCCCCFF : 0xFFFFFF;
|
||||
@ -270,7 +269,6 @@ void CtrlDisplayListView::toggleBreakpoint()
|
||||
|
||||
void CtrlDisplayListView::onMouseDown(WPARAM wParam, LPARAM lParam, int button)
|
||||
{
|
||||
int x = LOWORD(lParam);
|
||||
int y = HIWORD(lParam);
|
||||
|
||||
int line = y/rowHeight;
|
||||
|
@ -535,15 +535,6 @@ namespace MainWindow {
|
||||
osm.Show(messageStream.str());
|
||||
}
|
||||
|
||||
static void enableCheats(bool cheats) {
|
||||
g_Config.bEnableCheats = cheats;
|
||||
}
|
||||
|
||||
static void setDisplayOptions(int options) {
|
||||
g_Config.iSmallDisplayZoomType = options;
|
||||
NativeMessageReceived("gpu_resized", "");
|
||||
}
|
||||
|
||||
static void RestartApp() {
|
||||
if (IsDebuggerPresent()) {
|
||||
PostMessage(MainWindow::GetHWND(), WM_USER_RESTART_EMUTHREAD, 0, 0);
|
||||
@ -559,7 +550,6 @@ namespace MainWindow {
|
||||
auto gr = GetI18NCategory("Graphics");
|
||||
|
||||
int wmId = LOWORD(wParam);
|
||||
int wmEvent = HIWORD(wParam);
|
||||
// Parse the menu selections:
|
||||
switch (wmId) {
|
||||
case ID_FILE_LOAD:
|
||||
|
@ -104,7 +104,7 @@ int TabControl::AppendPageToControl(const wchar_t *title)
|
||||
tcItem.iImage = 0;
|
||||
|
||||
int index = TabCtrl_GetItemCount(hwnd);
|
||||
int result = TabCtrl_InsertItem(hwnd,index,&tcItem);
|
||||
TabCtrl_InsertItem(hwnd, index, &tcItem);
|
||||
return index;
|
||||
}
|
||||
|
||||
|
@ -417,6 +417,7 @@ static std::string GetDefaultLangRegion() {
|
||||
|
||||
static const int EXIT_CODE_VULKAN_WORKS = 42;
|
||||
|
||||
#ifndef _DEBUG
|
||||
static bool DetectVulkanInExternalProcess() {
|
||||
std::wstring workingDirectory;
|
||||
std::wstring moduleFilename;
|
||||
@ -447,6 +448,7 @@ static bool DetectVulkanInExternalProcess() {
|
||||
|
||||
return exitCode == EXIT_CODE_VULKAN_WORKS;
|
||||
}
|
||||
#endif
|
||||
|
||||
std::vector<std::wstring> GetWideCmdLine() {
|
||||
wchar_t **wargv;
|
||||
@ -656,7 +658,6 @@ int WINAPI WinMain(HINSTANCE _hInstance, HINSTANCE hPrevInstance, LPSTR szCmdLin
|
||||
MainWindow::Show(_hInstance);
|
||||
|
||||
HWND hwndMain = MainWindow::GetHWND();
|
||||
HWND hwndDisplay = MainWindow::GetDisplayHWND();
|
||||
|
||||
//initialize custom controls
|
||||
CtrlDisAsmView::init();
|
||||
|
Loading…
Reference in New Issue
Block a user