mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-07-31 10:09:42 -06:00
misc: Replace references to IntPtr/UIntPtr with nint/nuint + code cleanups.
This commit is contained in:
@ -13,13 +13,13 @@ namespace Ryujinx.Graphics.Vulkan
|
||||
private readonly struct HostMemoryAllocation
|
||||
{
|
||||
public readonly Auto<MemoryAllocation> Allocation;
|
||||
public readonly IntPtr Pointer;
|
||||
public readonly nint Pointer;
|
||||
public readonly ulong Size;
|
||||
|
||||
public ulong Start => (ulong)Pointer;
|
||||
public ulong End => (ulong)Pointer + Size;
|
||||
|
||||
public HostMemoryAllocation(Auto<MemoryAllocation> allocation, IntPtr pointer, ulong size)
|
||||
public HostMemoryAllocation(Auto<MemoryAllocation> allocation, nint pointer, ulong size)
|
||||
{
|
||||
Allocation = allocation;
|
||||
Pointer = pointer;
|
||||
@ -50,7 +50,7 @@ namespace Ryujinx.Graphics.Vulkan
|
||||
public unsafe bool TryImport(
|
||||
MemoryRequirements requirements,
|
||||
MemoryPropertyFlags flags,
|
||||
IntPtr pointer,
|
||||
nint pointer,
|
||||
ulong size)
|
||||
{
|
||||
lock (_lock)
|
||||
@ -139,7 +139,7 @@ namespace Ryujinx.Graphics.Vulkan
|
||||
return true;
|
||||
}
|
||||
|
||||
public (Auto<MemoryAllocation>, ulong) GetExistingAllocation(IntPtr pointer, ulong size)
|
||||
public (Auto<MemoryAllocation>, ulong) GetExistingAllocation(nint pointer, ulong size)
|
||||
{
|
||||
lock (_lock)
|
||||
{
|
||||
|
Reference in New Issue
Block a user