mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-01 14:58:14 +00:00
Global: Cleanup some unreferenced warnings.
This commit is contained in:
1 parent
ca4a0a848a
commit
cf030c3bce
7 files changed
+13
-19
No files matched your search
@@ -101,6 +101,10 @@ public:
|
||||
return offset_;
|
||||
}
|
||||
|
||||
const char *Name() const {
|
||||
return name_;
|
||||
}
|
||||
|
||||
// "Zero-copy" variant - you can write the data directly as you compute it.
|
||||
// Recommended.
|
||||
void *Push(size_t size, uint32_t *bindOffset, VkBuffer *vkbuf) {
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#include <cstdint>
|
||||
#include <zstd.h>
|
||||
|
||||
#include "Common/Log.h"
|
||||
#include "Common/Render/TextureAtlas.h"
|
||||
|
||||
class ByteReader {
|
||||
@@ -10,6 +11,7 @@ public:
|
||||
|
||||
template<class T>
|
||||
T Read() {
|
||||
_dbg_assert_(offset_ + sizeof(T) <= size_);
|
||||
T x;
|
||||
memcpy(&x, data_ + offset_, sizeof(T));
|
||||
offset_ += sizeof(T);
|
||||
@@ -18,6 +20,7 @@ public:
|
||||
|
||||
template<class T>
|
||||
void ReadInto(T *t) {
|
||||
_dbg_assert_(offset_ + sizeof(T) <= size_);
|
||||
memcpy(t, data_ + offset_, sizeof(T));
|
||||
offset_ += sizeof(T);
|
||||
}
|
||||
@@ -26,13 +29,16 @@ public:
|
||||
T *ReadMultipleAlloc(size_t count, bool compressed) {
|
||||
T *t = new T[count];
|
||||
if (!compressed) {
|
||||
_dbg_assert_(offset_ + sizeof(T) * count <= size_);
|
||||
memcpy(t, data_ + offset_, sizeof(T) * count);
|
||||
offset_ += sizeof(T) * count;
|
||||
} else {
|
||||
_dbg_assert_(offset_ + sizeof(uint32_t) <= size_);
|
||||
uint32_t compressed_size = 0;
|
||||
memcpy(&compressed_size, data_ + offset_, sizeof(uint32_t));
|
||||
offset_ += sizeof(uint32_t);
|
||||
|
||||
_dbg_assert_(offset_ + compressed_size <= size_);
|
||||
ZSTD_decompress(t, sizeof(T) * count, data_ + offset_, compressed_size);
|
||||
offset_ += compressed_size;
|
||||
}
|
||||
|
||||
@@ -217,7 +217,7 @@ u32 GetTextureBufw(int level, u32 texaddr, GETextureFormat format) {
|
||||
return bufw;
|
||||
}
|
||||
|
||||
// Is this compatible with QuickTexHashNEON/SSE?
|
||||
// Matches QuickTexHashNEON/SSE, see #7029.
|
||||
static u32 QuickTexHashNonSSE(const void *checkp, u32 size) {
|
||||
u32 check = 0;
|
||||
|
||||
@@ -269,20 +269,6 @@ static u32 QuickTexHashNonSSE(const void *checkp, u32 size) {
|
||||
return check;
|
||||
}
|
||||
|
||||
static u32 QuickTexHashBasic(const void *checkp, u32 size) {
|
||||
u32 check = 0;
|
||||
const u32 size_u32 = size / 4;
|
||||
const u32 *p = (const u32 *)checkp;
|
||||
for (u32 i = 0; i < size_u32; i += 4) {
|
||||
check += p[i + 0];
|
||||
check ^= p[i + 1];
|
||||
check += p[i + 2];
|
||||
check ^= p[i + 3];
|
||||
}
|
||||
|
||||
return check;
|
||||
}
|
||||
|
||||
u32 StableQuickTexHash(const void *checkp, u32 size) {
|
||||
#if defined(_M_SSE)
|
||||
return QuickTexHashSSE2(checkp, size);
|
||||
|
||||
@@ -209,7 +209,7 @@ static void load_sample(ptrdiff_t w, ptrdiff_t h, ptrdiff_t s, const u8 *pixels,
|
||||
// Check if the sample is inside. NOTE: for b>=0
|
||||
// the expression (UNSIGNED)a<(UNSIGNED)b is
|
||||
// equivalent to a>=0&&a<b.
|
||||
typedef int static_assert_size_matches[sizeof(ptrdiff_t)==sizeof(size_t)?1:-1];
|
||||
static_assert(sizeof(ptrdiff_t) == sizeof(size_t), "Assumes ptrdiff_t same width as size_t");
|
||||
|
||||
if((size_t)x >= (size_t)w||(size_t)y >= (size_t)h) {
|
||||
switch(wrap_mode) {
|
||||
|
||||
@@ -79,7 +79,6 @@ private:
|
||||
GLRTexture *lastBoundTexture = nullptr;
|
||||
|
||||
FramebufferManagerGLES *framebufferManagerGL_;
|
||||
ShaderManagerGLES *shaderManagerGL_;
|
||||
DrawEngineGLES *drawEngine_;
|
||||
|
||||
enum { INVALID_TEX = -1 };
|
||||
|
||||
@@ -72,7 +72,7 @@ private:
|
||||
|
||||
struct FrameData {
|
||||
FrameData() : descPool("VulkanComputeShaderManager", true) {
|
||||
descPool.Setup([this] { });
|
||||
descPool.Setup([] { });
|
||||
}
|
||||
|
||||
VulkanDescSetPool descPool;
|
||||
|
||||
@@ -39,7 +39,6 @@ private:
|
||||
|
||||
bool array[ARRAY_SIZE(CustomKey::comboKeyList)];
|
||||
int id_;
|
||||
UI::ChoiceStrip *comboselect;
|
||||
UI::ScrollView *rightScroll_;
|
||||
class ChoiceEventHandler{
|
||||
public:
|
||||
|
||||
Reference in new issue
Block a user