Use explicit buffer and texture bindings on shaders (#1666)

* Use explicit buffer and texture bindings on shaders

* More XML docs and other nits
This commit is contained in:
gdkchan 2020-11-08 08:10:00 -03:00 committed by GitHub
parent 5561a3b95e
commit 8d168574eb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 496 additions and 551 deletions

View file

@ -2,79 +2,79 @@
{
public interface IGpuAccessor
{
public void Log(string message)
void Log(string message)
{
// No default log output.
}
T MemoryRead<T>(ulong address) where T : unmanaged;
public bool MemoryMapped(ulong address)
bool MemoryMapped(ulong address)
{
return true;
}
public int QueryComputeLocalSizeX()
int QueryComputeLocalSizeX()
{
return 1;
}
public int QueryComputeLocalSizeY()
int QueryComputeLocalSizeY()
{
return 1;
}
public int QueryComputeLocalSizeZ()
int QueryComputeLocalSizeZ()
{
return 1;
}
public int QueryComputeLocalMemorySize()
int QueryComputeLocalMemorySize()
{
return 0x1000;
}
public int QueryComputeSharedMemorySize()
int QueryComputeSharedMemorySize()
{
return 0xc000;
}
public uint QueryConstantBufferUse()
uint QueryConstantBufferUse()
{
return 0xffff;
}
public bool QueryIsTextureBuffer(int handle)
bool QueryIsTextureBuffer(int handle)
{
return false;
}
public bool QueryIsTextureRectangle(int handle)
bool QueryIsTextureRectangle(int handle)
{
return false;
}
public InputTopology QueryPrimitiveTopology()
InputTopology QueryPrimitiveTopology()
{
return InputTopology.Points;
}
public int QueryStorageBufferOffsetAlignment()
int QueryStorageBufferOffsetAlignment()
{
return 16;
}
public bool QuerySupportsImageLoadFormatted()
bool QuerySupportsImageLoadFormatted()
{
return true;
}
public bool QuerySupportsNonConstantTextureOffset()
bool QuerySupportsNonConstantTextureOffset()
{
return true;
}
public TextureFormat QueryTextureFormat(int handle)
TextureFormat QueryTextureFormat(int handle)
{
return TextureFormat.R8G8B8A8Unorm;
}