Bugfixes, nw

This commit is contained in:
therealmogminer@gmail.com 2016-03-18 18:56:29 +01:00
parent 00f83c15ae
commit 50e3b68924
2 changed files with 5 additions and 8 deletions

View File

@ -44,7 +44,11 @@ bgfx_chain* chain_manager::chain(std::string name, running_machine& machine, uin
bgfx_chain* chain_manager::load_chain(std::string name, running_machine& machine, uint32_t window_index)
{
std::string path = std::string(m_options.bgfx_path()) + "/chains/" + name + ".json";
if (name.length() < 5 || (name.compare(name.length() - 5, 5, ".json")!= 0))
{
name = name + ".json";
}
std::string path = std::string(m_options.bgfx_path()) + "/chains/" + name;
bx::CrtFileReader reader;
bx::open(&reader, path.c_str());

View File

@ -271,13 +271,6 @@ void renderer_bgfx::put_packed_quad(render_primitive *prim, UINT32 hash, ScreenV
float u[4] = { u0, u1, u0, u1 };
float v[4] = { v0, v0, v1, v1 };
bgfx::RendererType::Enum renderer_type = bgfx::getRendererType();
if (renderer_type == bgfx::RendererType::OpenGL || renderer_type == bgfx::RendererType::OpenGLES)
{
v[0] = v[1] = v1;
v[2] = v[3] = v0;
}
if (PRIMFLAG_GET_TEXORIENT(prim->flags) & ORIENTATION_SWAP_XY)
{
std::swap(u[1], u[2]);