Expand gpu features flags to 64-bit.

This commit is contained in:
xebra 2017-01-31 23:18:27 +09:00
parent d6fe5d4ba0
commit ce27f7b0b5
2 changed files with 5 additions and 5 deletions

View File

@ -491,7 +491,7 @@ GPU_GLES::~GPU_GLES() {
// Take the raw GL extension and versioning data and turn into feature flags.
void GPU_GLES::CheckGPUFeatures() {
u32 features = 0;
u64 features = 0;
if (gl_extensions.ARB_blend_func_extended || gl_extensions.EXT_blend_func_extended) {
if (gl_extensions.gpuVendor == GPU_VENDOR_INTEL || !gl_extensions.VersionGEThan(3, 0, 0)) {
// Don't use this extension to off on sub 3.0 OpenGL versions as it does not seem reliable

View File

@ -441,11 +441,11 @@ struct UVScale {
float uOff, vOff;
};
#define FLAG_BIT(x) (1 << x)
#define FLAG_BIT(x) (1ULL << x)
// Some of these are OpenGL-specific even though this file is neutral, unfortunately.
// Might want to move this mechanism into the backend later.
enum {
enum : u64 {
GPU_SUPPORTS_DUALSOURCE_BLEND = FLAG_BIT(0),
GPU_SUPPORTS_GLSL_ES_300 = FLAG_BIT(1),
GPU_SUPPORTS_GLSL_330 = FLAG_BIT(2),
@ -482,7 +482,7 @@ struct KnownVertexBounds {
};
struct GPUStateCache {
bool Supports(int flag) { return (featureFlags & flag) != 0; }
bool Supports(u64 flag) { return (featureFlags & flag) != 0; }
uint64_t GetDirtyUniforms() { return dirty & DIRTY_ALL_UNIFORMS; }
void Dirty(u64 what) {
dirty |= what;
@ -497,7 +497,7 @@ struct GPUStateCache {
return (dirty & what) != 0ULL;
}
u32 featureFlags;
u64 featureFlags;
u32 vertexAddr;
u32 indexAddr;