gl: Do not overwrite texture-cache image dimensions when updating format
- The code was an outdated relic from the early days. The calculated pitch was wrong as it did not take subregions (incomplete rows) into account.
This commit is contained in:
@@ -669,8 +669,8 @@ namespace gl
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//TODO: More tests on byte order
|
// TODO: More tests on byte order
|
||||||
//ARGB8+native+unswizzled is confirmed with Dark Souls II character preview
|
// ARGB8+native+unswizzled is confirmed with Dark Souls II character preview
|
||||||
switch (gcm_format)
|
switch (gcm_format)
|
||||||
{
|
{
|
||||||
case CELL_GCM_TEXTURE_A8R8G8B8:
|
case CELL_GCM_TEXTURE_A8R8G8B8:
|
||||||
@@ -697,8 +697,7 @@ namespace gl
|
|||||||
fmt::throw_exception("Unexpected gcm format 0x%X", gcm_format);
|
fmt::throw_exception("Unexpected gcm format 0x%X", gcm_format);
|
||||||
}
|
}
|
||||||
|
|
||||||
//NOTE: Protection is handled by the caller
|
// NOTE: Protection is handled by the caller
|
||||||
cached.set_dimensions(width, height, depth, (rsx_range.length() / height));
|
|
||||||
no_access_range = cached.get_min_max(no_access_range, rsx::section_bounds::locked_range);
|
no_access_range = cached.get_min_max(no_access_range, rsx::section_bounds::locked_range);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user