Files
nothoughts/node_modules/pixi.js/lib/compressed-textures/ktx2/utils/getTextureFormatFromKTXTexture.mjs
2025-08-04 18:57:35 +02:00

14 lines
455 B
JavaScript

import { glFormatToGPUFormat } from './glFormatToGPUFormat.mjs';
import { vkFormatToGPUFormat } from './vkFormatToGPUFormat.mjs';
"use strict";
function getTextureFormatFromKTXTexture(ktxTexture) {
if (ktxTexture.classId === 2) {
return vkFormatToGPUFormat(ktxTexture.vkFormat);
}
return glFormatToGPUFormat(ktxTexture.glInternalformat);
}
export { getTextureFormatFromKTXTexture };
//# sourceMappingURL=getTextureFormatFromKTXTexture.mjs.map