mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-02-10 03:40:04 +00:00
GL: ignore texture upload if invalid dimension found (#2097)
This commit is contained in:
parent
8ebe9d7dc2
commit
5b225ad59f
@ -497,6 +497,12 @@ namespace gl
|
|||||||
obj->gl_id = 0;
|
obj->gl_id = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!tex.width() || !tex.height())
|
||||||
|
{
|
||||||
|
LOG_ERROR(RSX, "Texture upload requested but invalid texture dimensions passed");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
__glcheck gl_texture.init(index, tex);
|
__glcheck gl_texture.init(index, tex);
|
||||||
gl_cached_texture &_obj = create_obj_for_params(gl_texture.id(), texaddr, tex.width(), tex.height(), tex.get_exact_mipmap_count());
|
gl_cached_texture &_obj = create_obj_for_params(gl_texture.id(), texaddr, tex.width(), tex.height(), tex.get_exact_mipmap_count());
|
||||||
|
|
||||||
@ -669,4 +675,4 @@ namespace gl
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user