Skip to content

Commit

Permalink
Rename TransferBufferImage to TextureTransferInfo
Browse files Browse the repository at this point in the history
  • Loading branch information
flibitijibibo committed Jun 21, 2024
1 parent e4a36f2 commit bf015fc
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
8 changes: 4 additions & 4 deletions include/SDL3/SDL_gpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -420,13 +420,13 @@ typedef struct SDL_GpuViewport
float maxDepth;
} SDL_GpuViewport;

typedef struct SDL_GpuTransferBufferImage
typedef struct SDL_GpuTextureTransferInfo
{
SDL_GpuTransferBuffer *transferBuffer;
Uint32 offset; /* starting location of the image data */
Uint32 imagePitch; /* number of pixels from one row to the next */
Uint32 imageHeight; /* number of rows from one layer/depth-slice to the next */
} SDL_GpuTransferBufferImage;
} SDL_GpuTextureTransferInfo;

typedef struct SDL_GpuTransferBufferLocation
{
Expand Down Expand Up @@ -1737,7 +1737,7 @@ extern SDL_DECLSPEC SDL_GpuCopyPass *SDLCALL SDL_GpuBeginCopyPass(
*/
extern SDL_DECLSPEC void SDLCALL SDL_GpuUploadToTexture(
SDL_GpuCopyPass *copyPass,
SDL_GpuTransferBufferImage *source,
SDL_GpuTextureTransferInfo *source,
SDL_GpuTextureRegion *destination,
SDL_bool cycle);

Expand Down Expand Up @@ -1832,7 +1832,7 @@ extern SDL_DECLSPEC void SDLCALL SDL_GpuGenerateMipmaps(
extern SDL_DECLSPEC void SDLCALL SDL_GpuDownloadFromTexture(
SDL_GpuCopyPass *copyPass,
SDL_GpuTextureRegion *source,
SDL_GpuTransferBufferImage *destination);
SDL_GpuTextureTransferInfo *destination);

/**
* Copies data from a buffer to a transfer buffer on the GPU timeline.
Expand Down
4 changes: 2 additions & 2 deletions src/dynapi/SDL_dynapi_procs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1104,12 +1104,12 @@ SDL_DYNAPI_PROC(void,SDL_GpuUnmapTransferBuffer,(SDL_GpuDevice *a, SDL_GpuTransf
SDL_DYNAPI_PROC(void,SDL_GpuSetTransferData,(SDL_GpuDevice *a, const void *b, SDL_GpuTransferBufferRegion *c, SDL_bool d),(a,b,c,d),)
SDL_DYNAPI_PROC(void,SDL_GpuGetTransferData,(SDL_GpuDevice *a, SDL_GpuTransferBufferRegion *b, void *c),(a,b,c),)
SDL_DYNAPI_PROC(SDL_GpuCopyPass*,SDL_GpuBeginCopyPass,(SDL_GpuCommandBuffer *a),(a),return)
SDL_DYNAPI_PROC(void,SDL_GpuUploadToTexture,(SDL_GpuCopyPass *a, SDL_GpuTransferBufferImage *b, SDL_GpuTextureRegion *c, SDL_bool d),(a,b,c,d),)
SDL_DYNAPI_PROC(void,SDL_GpuUploadToTexture,(SDL_GpuCopyPass *a, SDL_GpuTextureTransferInfo *b, SDL_GpuTextureRegion *c, SDL_bool d),(a,b,c,d),)
SDL_DYNAPI_PROC(void,SDL_GpuUploadToBuffer,(SDL_GpuCopyPass *a, SDL_GpuTransferBufferLocation *b, SDL_GpuBufferRegion *c, SDL_bool d),(a,b,c,d),)
SDL_DYNAPI_PROC(void,SDL_GpuCopyTextureToTexture,(SDL_GpuCopyPass *a, SDL_GpuTextureLocation *b, SDL_GpuTextureLocation *c, Uint32 d, Uint32 e, Uint32 f, SDL_bool g),(a,b,c,d,e,f,g),)
SDL_DYNAPI_PROC(void,SDL_GpuCopyBufferToBuffer,(SDL_GpuCopyPass *a, SDL_GpuBufferLocation *b, SDL_GpuBufferLocation *c, Uint32 d, SDL_bool e),(a,b,c,d,e),)
SDL_DYNAPI_PROC(void,SDL_GpuGenerateMipmaps,(SDL_GpuCopyPass *a, SDL_GpuTexture *b),(a,b),)
SDL_DYNAPI_PROC(void,SDL_GpuDownloadFromTexture,(SDL_GpuCopyPass *a, SDL_GpuTextureRegion *b, SDL_GpuTransferBufferImage *c),(a,b,c),)
SDL_DYNAPI_PROC(void,SDL_GpuDownloadFromTexture,(SDL_GpuCopyPass *a, SDL_GpuTextureRegion *b, SDL_GpuTextureTransferInfo *c),(a,b,c),)
SDL_DYNAPI_PROC(void,SDL_GpuDownloadFromBuffer,(SDL_GpuCopyPass *a, SDL_GpuBufferRegion *b, SDL_GpuTransferBufferLocation *c),(a,b,c),)
SDL_DYNAPI_PROC(void,SDL_GpuEndCopyPass,(SDL_GpuCopyPass *a),(a),)
SDL_DYNAPI_PROC(void,SDL_GpuBlit,(SDL_GpuCommandBuffer *a, SDL_GpuTextureRegion *b, SDL_GpuTextureRegion *c, SDL_GpuFilter d, SDL_bool e),(a,b,c,d,e),)
Expand Down
4 changes: 2 additions & 2 deletions src/gpu/SDL_gpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -1078,7 +1078,7 @@ SDL_GpuCopyPass *SDL_GpuBeginCopyPass(

void SDL_GpuUploadToTexture(
SDL_GpuCopyPass *copyPass,
SDL_GpuTransferBufferImage *source,
SDL_GpuTextureTransferInfo *source,
SDL_GpuTextureRegion *destination,
SDL_bool cycle)
{
Expand Down Expand Up @@ -1154,7 +1154,7 @@ void SDL_GpuGenerateMipmaps(
void SDL_GpuDownloadFromTexture(
SDL_GpuCopyPass *copyPass,
SDL_GpuTextureRegion *source,
SDL_GpuTransferBufferImage *destination)
SDL_GpuTextureTransferInfo *destination)
{
NULL_ASSERT(copyPass);
COPYPASS_DEVICE->DownloadFromTexture(
Expand Down
4 changes: 2 additions & 2 deletions src/gpu/SDL_gpu_driver.h
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ struct SDL_GpuDevice

void (*UploadToTexture)(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTransferBufferImage *source,
SDL_GpuTextureTransferInfo *source,
SDL_GpuTextureRegion *destination,
SDL_bool cycle);

Expand Down Expand Up @@ -498,7 +498,7 @@ struct SDL_GpuDevice
void (*DownloadFromTexture)(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTextureRegion *source,
SDL_GpuTransferBufferImage *destination);
SDL_GpuTextureTransferInfo *destination);

void (*DownloadFromBuffer)(
SDL_GpuCommandBuffer *commandBuffer,
Expand Down
4 changes: 2 additions & 2 deletions src/gpu/d3d11/SDL_gpu_d3d11.c
Original file line number Diff line number Diff line change
Expand Up @@ -2798,7 +2798,7 @@ static void D3D11_BeginCopyPass(

static void D3D11_UploadToTexture(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTransferBufferImage *source,
SDL_GpuTextureTransferInfo *source,
SDL_GpuTextureRegion *destination,
SDL_bool cycle)
{
Expand Down Expand Up @@ -2945,7 +2945,7 @@ static void D3D11_UploadToBuffer(
static void D3D11_DownloadFromTexture(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTextureRegion *source,
SDL_GpuTransferBufferImage *destination)
SDL_GpuTextureTransferInfo *destination)
{
D3D11CommandBuffer *d3d11CommandBuffer = (D3D11CommandBuffer *)commandBuffer;
D3D11Renderer *renderer = d3d11CommandBuffer->renderer;
Expand Down
4 changes: 2 additions & 2 deletions src/gpu/vulkan/SDL_gpu_vulkan.c
Original file line number Diff line number Diff line change
Expand Up @@ -8531,7 +8531,7 @@ static void VULKAN_BeginCopyPass(

static void VULKAN_UploadToTexture(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTransferBufferImage *source,
SDL_GpuTextureTransferInfo *source,
SDL_GpuTextureRegion *destination,
SDL_bool cycle)
{
Expand Down Expand Up @@ -8632,7 +8632,7 @@ static void VULKAN_UploadToBuffer(
static void VULKAN_DownloadFromTexture(
SDL_GpuCommandBuffer *commandBuffer,
SDL_GpuTextureRegion *source,
SDL_GpuTransferBufferImage *destination)
SDL_GpuTextureTransferInfo *destination)
{
VulkanCommandBuffer *vulkanCommandBuffer = (VulkanCommandBuffer *)commandBuffer;
VulkanRenderer *renderer = vulkanCommandBuffer->renderer;
Expand Down

0 comments on commit bf015fc

Please sign in to comment.