Fix some embarrassing typos

This commit is contained in:
2025-06-17 16:46:06 +10:00
parent 2247d9a31c
commit cd9c04ac08
3 changed files with 4 additions and 4 deletions

View File

@@ -245,7 +245,7 @@ SDL_GPUTexture* NeHe_CreateGPUTextureFromSurface(NeHeContext* restrict ctx, cons
bool needsConvert = false;
switch (surface->format)
{
// FIMXE: I'm not sure that these are endian-safe
// FIXME: I'm not sure that these are endian-safe
case SDL_PIXELFORMAT_RGBA32: info.format = SDL_GPU_TEXTUREFORMAT_R8G8B8A8_UNORM; break;
case SDL_PIXELFORMAT_RGBA64: info.format = SDL_GPU_TEXTUREFORMAT_R16G16B16A16_UNORM; break;
case SDL_PIXELFORMAT_RGB565: info.format = SDL_GPU_TEXTUREFORMAT_B5G6R5_UNORM; break;
@@ -284,7 +284,7 @@ SDL_GPUTexture* NeHe_CreateGPUTextureFromSurface(NeHeContext* restrict ctx, cons
if (genMipmaps)
{
info.usage |= SDL_GPU_TEXTUREUSAGE_COLOR_TARGET;
// floor(log₂(max(𝑤,)) + 1
// floor(log₂(max(𝑤,))) + 1
info.num_levels = (Uint32)SDL_MostSignificantBitIndex32(SDL_max(info.width, info.height)) + 1;
}

View File

@@ -163,7 +163,7 @@ impl NeHeCopyPass<'_>
if gen_mipmaps
{
info.usage |= SDL_GPU_TEXTUREUSAGE_COLOR_TARGET;
info.num_levels = max(info.width, info.height).ilog2() + 1; // floor(log₂(max(𝑤,)) + 1
info.num_levels = max(info.width, info.height).ilog2() + 1; // floor(log₂(max(𝑤,))) + 1
}
if needs_convert

View File

@@ -194,7 +194,7 @@ public extension NeHeCopyPass
if genMipmaps
{
info.usage |= SDL_GPU_TEXTUREUSAGE_COLOR_TARGET
// floor(log₂(max(𝑤,)) + 1
// floor(log₂(max(𝑤,))) + 1
info.num_levels = 31 - UInt32(max(info.width, info.height).leadingZeroBitCount) + 1
}