mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-07 23:41:26 +12:00
rsx/common/d3d12/gl: Support for CMP/non pow of 2 size vertex formats.
Also use class enum for base_vertex_type everywhere. Fix Bomberman Ultra color and Cubixx HD geometry.
This commit is contained in:
parent
3afc62e525
commit
d153575e59
10 changed files with 179 additions and 91 deletions
|
@ -14,10 +14,10 @@ namespace rsx
|
|||
rsx_method_t methods[0x10000 >> 2]{};
|
||||
|
||||
template<typename Type> struct vertex_data_type_from_element_type;
|
||||
template<> struct vertex_data_type_from_element_type<float> { enum { type = CELL_GCM_VERTEX_F }; };
|
||||
template<> struct vertex_data_type_from_element_type<f16> { enum { type = CELL_GCM_VERTEX_SF }; };
|
||||
template<> struct vertex_data_type_from_element_type<u8> { enum { type = CELL_GCM_VERTEX_UB }; };
|
||||
template<> struct vertex_data_type_from_element_type<u16> { enum { type = CELL_GCM_VERTEX_S1 }; };
|
||||
template<> struct vertex_data_type_from_element_type<float> { static const Vertex_base_type type = Vertex_base_type::f; };
|
||||
template<> struct vertex_data_type_from_element_type<f16> { static const Vertex_base_type type = Vertex_base_type::sf; };
|
||||
template<> struct vertex_data_type_from_element_type<u8> { static const Vertex_base_type type = Vertex_base_type::ub; };
|
||||
template<> struct vertex_data_type_from_element_type<u16> { static const Vertex_base_type type = Vertex_base_type::s1; };
|
||||
|
||||
namespace nv406e
|
||||
{
|
||||
|
@ -248,7 +248,7 @@ namespace rsx
|
|||
continue;
|
||||
|
||||
u32 count = u32(rsx->register_vertex_data[i].size()) /
|
||||
rsx::get_vertex_type_size(rsx->register_vertex_info[i].type) * rsx->register_vertex_info[i].size;
|
||||
rsx::get_vertex_type_size_on_host(rsx->register_vertex_info[i].type, rsx->register_vertex_info[i].size);
|
||||
|
||||
if (count < min_count)
|
||||
min_count = count;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue