Initial support for GPU channels (#2372)
* Ground work for separate GPU channels * Rename TextureManager to TextureCache * Decouple texture bindings management from the texture cache * Rename BufferManager to BufferCache * Decouple buffer bindings management from the buffer cache * More comments and proper disposal * PR feedback * Force host state update on channel switch * Typo * PR feedback * Missing using
This commit is contained in:
parent
12a7a2ead8
commit
a10b2c5ff2
24 changed files with 1745 additions and 1456 deletions
|
@ -35,7 +35,8 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
|
|||
/// Creates a new instance of the GPU General Purpose FIFO command processor.
|
||||
/// </summary>
|
||||
/// <param name="context">GPU context</param>
|
||||
public GPFifoProcessor(GpuContext context)
|
||||
/// <param name="channel">Channel that the GPFIFO processor belongs to</param>
|
||||
public GPFifoProcessor(GpuContext context, GpuChannel channel)
|
||||
{
|
||||
_context = context;
|
||||
|
||||
|
@ -44,7 +45,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
|
|||
|
||||
for (int index = 0; index < _subChannels.Length; index++)
|
||||
{
|
||||
_subChannels[index] = new GpuState();
|
||||
_subChannels[index] = new GpuState(channel);
|
||||
|
||||
_context.Methods.RegisterCallbacks(_subChannels[index]);
|
||||
}
|
||||
|
@ -186,5 +187,17 @@ namespace Ryujinx.Graphics.Gpu.Engine.GPFifo
|
|||
_subChannels[i].ShadowRamControl = control;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Forces a full host state update by marking all state as modified,
|
||||
/// and also requests all GPU resources in use to be rebound.
|
||||
/// </summary>
|
||||
public void ForceAllDirty()
|
||||
{
|
||||
for (int index = 0; index < _subChannels.Length; index++)
|
||||
{
|
||||
_subChannels[index].ForceAllDirty();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue