mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-03-29 22:20:48 +00:00
rsx: Fixup vertex enums in shaders
This commit is contained in:
parent
eae1ac6558
commit
38402e78c0
@ -184,13 +184,13 @@ namespace glsl
|
|||||||
|
|
||||||
//Actually decode a vertex attribute from a raw byte stream
|
//Actually decode a vertex attribute from a raw byte stream
|
||||||
OS <<
|
OS <<
|
||||||
"#define VTX_FMT_SNORM16 0\n"
|
"#define VTX_FMT_SNORM16 " << RSX_VERTEX_BASE_TYPE_SNORM16 << "\n"
|
||||||
"#define VTX_FMT_FLOAT32 1\n"
|
"#define VTX_FMT_FLOAT32 " << RSX_VERTEX_BASE_TYPE_FLOAT << "\n"
|
||||||
"#define VTX_FMT_FLOAT16 2\n"
|
"#define VTX_FMT_FLOAT16 " << RSX_VERTEX_BASE_TYPE_HALF_FLOAT << "\n"
|
||||||
"#define VTX_FMT_UNORM8 3\n"
|
"#define VTX_FMT_UNORM8 " << RSX_VERTEX_BASE_TYPE_UNORM8 << "\n"
|
||||||
"#define VTX_FMT_SINT16 4\n"
|
"#define VTX_FMT_SINT16 " << RSX_VERTEX_BASE_TYPE_SINT16 << "\n"
|
||||||
"#define VTX_FMT_COMP32 5\n"
|
"#define VTX_FMT_COMP32 " << RSX_VERTEX_BASE_TYPE_CMP32 << "\n"
|
||||||
"#define VTX_FMT_UINT8 6\n\n";
|
"#define VTX_FMT_UINT8 " << RSX_VERTEX_BASE_TYPE_UINT8 << "\n\n";
|
||||||
|
|
||||||
// For intel GPUs which cannot access vectors in indexed mode (driver bug? or glsl version too low?)
|
// For intel GPUs which cannot access vectors in indexed mode (driver bug? or glsl version too low?)
|
||||||
// Note: Tested on Mesa iris with HD 530 and compilant path works fine, may be a bug on Windows proprietary drivers
|
// Note: Tested on Mesa iris with HD 530 and compilant path works fine, may be a bug on Windows proprietary drivers
|
||||||
|
@ -955,7 +955,7 @@ namespace gcm
|
|||||||
RSX_VERTEX_BASE_TYPE_UNORM8,
|
RSX_VERTEX_BASE_TYPE_UNORM8,
|
||||||
RSX_VERTEX_BASE_TYPE_SINT16,
|
RSX_VERTEX_BASE_TYPE_SINT16,
|
||||||
RSX_VERTEX_BASE_TYPE_CMP32,
|
RSX_VERTEX_BASE_TYPE_CMP32,
|
||||||
RSX_VERTEX_BASE_TYPE_INT8,
|
RSX_VERTEX_BASE_TYPE_UINT8,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1012,7 +1012,7 @@ namespace rsx
|
|||||||
ub = RSX_VERTEX_BASE_TYPE_UNORM8, ///< unsigned byte interpreted as 0.f and 1.f
|
ub = RSX_VERTEX_BASE_TYPE_UNORM8, ///< unsigned byte interpreted as 0.f and 1.f
|
||||||
s32k = RSX_VERTEX_BASE_TYPE_SINT16, ///< signed 16bits int
|
s32k = RSX_VERTEX_BASE_TYPE_SINT16, ///< signed 16bits int
|
||||||
cmp = RSX_VERTEX_BASE_TYPE_CMP32, ///< compressed aka X11G11Z10 and always 1. W.
|
cmp = RSX_VERTEX_BASE_TYPE_CMP32, ///< compressed aka X11G11Z10 and always 1. W.
|
||||||
ub256 = RSX_VERTEX_BASE_TYPE_INT8, ///< unsigned byte interpreted as between 0 and 255.
|
ub256 = RSX_VERTEX_BASE_TYPE_UINT8, ///< unsigned byte interpreted as between 0 and 255.
|
||||||
};
|
};
|
||||||
|
|
||||||
static inline auto to_vertex_base_type(u32 in)
|
static inline auto to_vertex_base_type(u32 in)
|
||||||
@ -1021,7 +1021,7 @@ namespace rsx
|
|||||||
? gcm_enum_cast<
|
? gcm_enum_cast<
|
||||||
vertex_base_type,
|
vertex_base_type,
|
||||||
RSX_VERTEX_BASE_TYPE_SNORM16,
|
RSX_VERTEX_BASE_TYPE_SNORM16,
|
||||||
RSX_VERTEX_BASE_TYPE_INT8>(in)
|
RSX_VERTEX_BASE_TYPE_UINT8>(in)
|
||||||
: expected(vertex_base_type::ub256);
|
: expected(vertex_base_type::ub256);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user