shadow$provide.module$node_modules$pixi_DOT_js$lib$rendering$renderers$gl$texture$uploaders$glUploadCompressedTextureResource = function(global, require, module, exports) {
  const compressedFormatMap = {"bc1-rgba-unorm":!0, "bc1-rgba-unorm-srgb":!0, "bc2-rgba-unorm":!0, "bc2-rgba-unorm-srgb":!0, "bc3-rgba-unorm":!0, "bc3-rgba-unorm-srgb":!0, "bc4-r-unorm":!0, "bc4-r-snorm":!0, "bc5-rg-unorm":!0, "bc5-rg-snorm":!0, "bc6h-rgb-ufloat":!0, "bc6h-rgb-float":!0, "bc7-rgba-unorm":!0, "bc7-rgba-unorm-srgb":!0, "etc2-rgb8unorm":!0, "etc2-rgb8unorm-srgb":!0, "etc2-rgb8a1unorm":!0, "etc2-rgb8a1unorm-srgb":!0, "etc2-rgba8unorm":!0, "etc2-rgba8unorm-srgb":!0, "eac-r11unorm":!0, 
  "eac-r11snorm":!0, "eac-rg11unorm":!0, "eac-rg11snorm":!0, "astc-4x4-unorm":!0, "astc-4x4-unorm-srgb":!0, "astc-5x4-unorm":!0, "astc-5x4-unorm-srgb":!0, "astc-5x5-unorm":!0, "astc-5x5-unorm-srgb":!0, "astc-6x5-unorm":!0, "astc-6x5-unorm-srgb":!0, "astc-6x6-unorm":!0, "astc-6x6-unorm-srgb":!0, "astc-8x5-unorm":!0, "astc-8x5-unorm-srgb":!0, "astc-8x6-unorm":!0, "astc-8x6-unorm-srgb":!0, "astc-8x8-unorm":!0, "astc-8x8-unorm-srgb":!0, "astc-10x5-unorm":!0, "astc-10x5-unorm-srgb":!0, "astc-10x6-unorm":!0, 
  "astc-10x6-unorm-srgb":!0, "astc-10x8-unorm":!0, "astc-10x8-unorm-srgb":!0, "astc-10x10-unorm":!0, "astc-10x10-unorm-srgb":!0, "astc-12x10-unorm":!0, "astc-12x10-unorm-srgb":!0, "astc-12x12-unorm":!0, "astc-12x12-unorm-srgb":!0};
  exports.glUploadCompressedTextureResource = {id:"compressed", upload(source, glTexture, gl, _webGLVersion, targetOverride, _forceAllocation) {
    _webGLVersion = targetOverride ?? glTexture.target;
    gl.pixelStorei(gl.UNPACK_ALIGNMENT, 4);
    targetOverride = source.pixelWidth;
    _forceAllocation = source.pixelHeight;
    const compressed = !!compressedFormatMap[source.format];
    for (let i = 0; i < source.resource.length; i++) {
      const levelBuffer = source.resource[i];
      compressed ? gl.compressedTexImage2D(_webGLVersion, i, glTexture.internalFormat, targetOverride, _forceAllocation, 0, levelBuffer) : gl.texImage2D(_webGLVersion, i, glTexture.internalFormat, targetOverride, _forceAllocation, 0, glTexture.format, glTexture.type, levelBuffer);
      targetOverride = Math.max(targetOverride >> 1, 1);
      _forceAllocation = Math.max(_forceAllocation >> 1, 1);
    }
  }};
};

//# sourceMappingURL=module$node_modules$pixi_DOT_js$lib$rendering$renderers$gl$texture$uploaders$glUploadCompressedTextureResource.js.map
