update some stuff

This commit is contained in:
Gregory Wells
2025-08-03 14:40:06 -04:00
parent acfc32656f
commit 590365c4a6
3 changed files with 6 additions and 6 deletions

View File

@@ -22,7 +22,7 @@ gnBool gnIsSurfaceFormatSupported(
) {
uint32_t formatCount = 0;
gnSurfaceFormat* formats = gnGetSupportedSurfaceFormats(windowSurface, device, &formatCount);
for (int i = 0; i < formatCount; i++) {
for (uint32_t i = 0; i < formatCount; i++) {
if (formats[i].format == format.format && formats[i].colorSpace == format.colorSpace) {
return GN_TRUE;
}
@@ -37,14 +37,14 @@ gnSurfaceFormat gnGetPreferredSurfaceFormat(
) {
uint32_t formatCount = 0;
gnSurfaceFormat* formats = gnGetSupportedSurfaceFormats(windowSurface, device, &formatCount);
for (int i = 0; i < formatCount; i++) {
for (uint32_t i = 0; i < formatCount; i++) {
if (formats[i].format == format.format && formats[i].colorSpace == format.colorSpace) {
return formats[i];
}
}
// will attempt to give you a simmilar format that either matches the Image format and the Color space
for (int i = 0; i < formatCount; i++) {
for (uint32_t i = 0; i < formatCount; i++) {
if (formats[i].format == format.format || formats[i].colorSpace == format.colorSpace) {
return formats[i];
}