Support texture rectangle targets (non-normalized coords)
This commit is contained in:
parent
2eccc7023a
commit
9d7a142a48
23 changed files with 473 additions and 356 deletions
|
@ -199,6 +199,21 @@ namespace Ryujinx.Graphics.Gpu.Image
|
|||
}
|
||||
}
|
||||
|
||||
public TextureDescriptor GetTextureDescriptor(GpuState state, int stageIndex, int handle)
|
||||
{
|
||||
int packedId = ReadPackedId(stageIndex, handle);
|
||||
|
||||
int textureId = UnpackTextureId(packedId);
|
||||
|
||||
var poolState = state.Get<PoolState>(MethodOffset.TexturePoolState);
|
||||
|
||||
ulong poolAddress = _context.MemoryManager.Translate(poolState.Address.Pack());
|
||||
|
||||
TexturePool texturePool = _texturePoolCache.FindOrCreate(poolAddress, poolState.MaximumId);
|
||||
|
||||
return texturePool.GetDescriptor(textureId);
|
||||
}
|
||||
|
||||
private int ReadPackedId(int stage, int wordOffset)
|
||||
{
|
||||
ulong address;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue