metal: initial texel buffer Shader:send implementation

This commit is contained in:
Alex Szpakowski
2021-03-31 23:02:36 -03:00
parent 1b9b32c7a7
commit 5fa570b9a6
7 changed files with 114 additions and 26 deletions
+1 -1
View File
@@ -77,7 +77,7 @@ Buffer::Buffer(love::graphics::Graphics *gfx, id<MTLDevice> device, const Settin
{
MTLPixelFormat pixformat = getMTLPixelFormat(getDataMember(0).decl.format);
auto desc = [MTLTextureDescriptor textureBufferDescriptorWithPixelFormat:pixformat
width:size
width:arraylength
resourceOptions:opts
usage:MTLTextureUsageShaderRead];
texture = [buffer newTextureWithDescriptor:desc offset:0 bytesPerRow:size];