mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2025-06-28 22:00:47 -07:00
GPU: Discard data when getting texture before full clear (#5719)
* GPU: Discard data when getting texture before full clear * Fix rules and order of clear checks * Fix formatting
This commit is contained in:
@ -570,6 +570,18 @@ namespace Ryujinx.Graphics.Gpu.Image
|
||||
return Group.CheckDirty(this, consume);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Discards all data for this texture.
|
||||
/// This clears all dirty flags, modified flags, and pending copies from other textures.
|
||||
/// It should be used if the texture data will be fully overwritten by the next use.
|
||||
/// </summary>
|
||||
public void DiscardData()
|
||||
{
|
||||
Group.DiscardData(this);
|
||||
|
||||
_dirty = false;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Synchronizes guest and host memory.
|
||||
/// This will overwrite the texture data with the texture data on the guest memory, if a CPU
|
||||
|
Reference in New Issue
Block a user