mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-11-24 00:52:03 +00:00
Fix WidthInGobs on the GPU
This commit is contained in:
parent
fee4b0eb8a
commit
0381a09227
1 changed files with 3 additions and 1 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
using System;
|
||||||
|
|
||||||
namespace Ryujinx.Core.Gpu
|
namespace Ryujinx.Core.Gpu
|
||||||
{
|
{
|
||||||
class BlockLinearSwizzle : ISwizzle
|
class BlockLinearSwizzle : ISwizzle
|
||||||
|
@ -16,7 +18,7 @@ namespace Ryujinx.Core.Gpu
|
||||||
BhShift = CountLsbZeros(BlockHeight * 8);
|
BhShift = CountLsbZeros(BlockHeight * 8);
|
||||||
BppShift = CountLsbZeros(Bpp);
|
BppShift = CountLsbZeros(Bpp);
|
||||||
|
|
||||||
int WidthInGobs = Width * Bpp / 64;
|
int WidthInGobs = (int)MathF.Ceiling(Width * Bpp / 64f);
|
||||||
|
|
||||||
GobStride = 512 * BlockHeight * WidthInGobs;
|
GobStride = 512 * BlockHeight * WidthInGobs;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue