GPUTexture: Remove data_format from 3D texture creation function

For every other texture types this is expected to be implicitly
`GPU_DATA_FLOAT`. There is only one case where this is not the case.

I believe this was previously needed because the data type was
conditionning the texture creation. This is not the case anymore.
This commit is contained in:
2023-02-25 01:19:44 +01:00
committed by Gitea
parent 75e3371aef
commit e01b140fb2
11 changed files with 17 additions and 47 deletions

View File

@@ -340,12 +340,11 @@ GPUTexture *GPU_texture_create_3d_ex(const char *name,
int d,
int mip_len,
eGPUTextureFormat texture_format,
eGPUDataFormat data_format,
eGPUTextureUsage usage,
const void *data)
{
return gpu_texture_create(
name, w, h, d, GPU_TEXTURE_3D, mip_len, texture_format, data_format, usage, data);
name, w, h, d, GPU_TEXTURE_3D, mip_len, texture_format, GPU_DATA_FLOAT, usage, data);
}
GPUTexture *GPU_texture_create_cube_ex(const char *name,
@@ -441,11 +440,10 @@ GPUTexture *GPU_texture_create_3d(const char *name,
int d,
int mip_len,
eGPUTextureFormat texture_format,
eGPUDataFormat data_format,
const void *data)
{
return GPU_texture_create_3d_ex(
name, w, h, d, mip_len, texture_format, data_format, GPU_TEXTURE_USAGE_GENERAL, data);
name, w, h, d, mip_len, texture_format, GPU_TEXTURE_USAGE_GENERAL, data);
}
GPUTexture *GPU_texture_create_cube(