Updated source to match SDL function prototype style

This commit is contained in:
Sam Lantinga
2023-05-23 09:37:07 -07:00
parent a828f5897e
commit 737aa881fa
39 changed files with 95 additions and 191 deletions

View File

@@ -196,8 +196,7 @@ static const GUID SDL_IID_ID3D11DeviceContext1 = { 0xbb2c6faa, 0xb5fb, 0x4082, {
#pragma GCC diagnostic pop
#endif
Uint32
D3D11_DXGIFormatToSDLPixelFormat(DXGI_FORMAT dxgiFormat)
Uint32 D3D11_DXGIFormatToSDLPixelFormat(DXGI_FORMAT dxgiFormat)
{
switch (dxgiFormat) {
case DXGI_FORMAT_B8G8R8A8_UNORM:

View File

@@ -272,8 +272,7 @@ UINT D3D12_Align(UINT location, UINT alignment)
return (location + (alignment - 1)) & ~(alignment - 1);
}
Uint32
D3D12_DXGIFormatToSDLPixelFormat(DXGI_FORMAT dxgiFormat)
Uint32 D3D12_DXGIFormatToSDLPixelFormat(DXGI_FORMAT dxgiFormat)
{
switch (dxgiFormat) {
case DXGI_FORMAT_B8G8R8A8_UNORM:

View File

@@ -25,8 +25,7 @@
#include "SDL_render_vita_gxm_memory.h"
void *
vita_mem_alloc(unsigned int type, unsigned int size, unsigned int alignment, unsigned int attribs, SceUID *uid)
void *vita_mem_alloc(unsigned int type, unsigned int size, unsigned int alignment, unsigned int attribs, SceUID *uid)
{
void *mem;
@@ -63,8 +62,7 @@ void vita_mem_free(SceUID uid)
sceKernelFreeMemBlock(uid);
}
void *
vita_gpu_mem_alloc(VITA_GXM_RenderData *data, unsigned int size)
void *vita_gpu_mem_alloc(VITA_GXM_RenderData *data, unsigned int size)
{
void *mem;
@@ -122,8 +120,7 @@ void vita_gpu_mem_destroy(VITA_GXM_RenderData *data)
}
}
void *
vita_mem_vertex_usse_alloc(unsigned int size, SceUID *uid, unsigned int *usse_offset)
void *vita_mem_vertex_usse_alloc(unsigned int size, SceUID *uid, unsigned int *usse_offset)
{
void *mem = NULL;
@@ -150,8 +147,7 @@ void vita_mem_vertex_usse_free(SceUID uid)
sceKernelFreeMemBlock(uid);
}
void *
vita_mem_fragment_usse_alloc(unsigned int size, SceUID *uid, unsigned int *usse_offset)
void *vita_mem_fragment_usse_alloc(unsigned int size, SceUID *uid, unsigned int *usse_offset)
{
void *mem = NULL;

View File

@@ -79,8 +79,7 @@ static void patcher_host_free(void *user_data, void *mem)
SDL_free(mem);
}
void *
pool_malloc(VITA_GXM_RenderData *data, unsigned int size)
void *pool_malloc(VITA_GXM_RenderData *data, unsigned int size)
{
if ((data->pool_index + size) < VITA_GXM_POOL_SIZE) {
@@ -92,8 +91,7 @@ pool_malloc(VITA_GXM_RenderData *data, unsigned int size)
return NULL;
}
void *
pool_memalign(VITA_GXM_RenderData *data, unsigned int size, unsigned int alignment)
void *pool_memalign(VITA_GXM_RenderData *data, unsigned int size, unsigned int alignment)
{
unsigned int new_index = (data->pool_index + alignment - 1) & ~(alignment - 1);
if ((new_index + size) < VITA_GXM_POOL_SIZE) {
@@ -957,8 +955,7 @@ gxm_texture_get_format(const gxm_texture *texture)
return sceGxmTextureGetFormat(&texture->gxm_tex);
}
void *
gxm_texture_get_datap(const gxm_texture *texture)
void *gxm_texture_get_datap(const gxm_texture *texture)
{
return sceGxmTextureGetData(&texture->gxm_tex);
}