function mapTypeAndFormatToInternalFormat(gl) {
    var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;
    var table;
    if ('WebGL2RenderingContext' in globalThis && gl instanceof globalThis.WebGL2RenderingContext) {
        table = (_a = {},
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_BYTE] = (_b = {},
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA8,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB8,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG] = gl.RG8,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED] = gl.R8,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA8UI,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB8UI,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG8UI,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R8UI,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.ALPHA] = gl.ALPHA,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.LUMINANCE] = gl.LUMINANCE,
                _b[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,
                _b),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.BYTE] = (_c = {},
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA8_SNORM,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB8_SNORM,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG] = gl.RG8_SNORM,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED] = gl.R8_SNORM,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA8I,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB8I,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG8I,
                _c[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R8I,
                _c),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT] = (_d = {},
                _d[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA16UI,
                _d[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB16UI,
                _d[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG16UI,
                _d[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R16UI,
                _d[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT16,
                _d),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.SHORT] = (_e = {},
                _e[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA16I,
                _e[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB16I,
                _e[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG16I,
                _e[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R16I,
                _e),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_INT] = (_f = {},
                _f[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA32UI,
                _f[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB32UI,
                _f[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG32UI,
                _f[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R32UI,
                _f[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT24,
                _f),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.INT] = (_g = {},
                _g[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGBA32I,
                _g[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB_INTEGER] = gl.RGB32I,
                _g[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG_INTEGER] = gl.RG32I,
                _g[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED_INTEGER] = gl.R32I,
                _g),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.FLOAT] = (_h = {},
                _h[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA32F,
                _h[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB32F,
                _h[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG] = gl.RG32F,
                _h[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED] = gl.R32F,
                _h[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.DEPTH_COMPONENT] = gl.DEPTH_COMPONENT32F,
                _h),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.HALF_FLOAT] = (_j = {},
                _j[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA16F,
                _j[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB16F,
                _j[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RG] = gl.RG16F,
                _j[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RED] = gl.R16F,
                _j),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_5_6_5] = (_k = {},
                _k[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB565,
                _k),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_4_4_4_4] = (_l = {},
                _l[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA4,
                _l),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_5_5_5_1] = (_m = {},
                _m[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGB5_A1,
                _m),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_INT_2_10_10_10_REV] = (_o = {},
                _o[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGB10_A2,
                _o[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA_INTEGER] = gl.RGB10_A2UI,
                _o),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_INT_10F_11F_11F_REV] = (_p = {},
                _p[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.R11F_G11F_B10F,
                _p),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_INT_5_9_9_9_REV] = (_q = {},
                _q[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB9_E5,
                _q),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_INT_24_8] = (_r = {},
                _r[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.DEPTH_STENCIL] = gl.DEPTH24_STENCIL8,
                _r),
            _a[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.FLOAT_32_UNSIGNED_INT_24_8_REV] = (_s = {},
                _s[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.DEPTH_STENCIL] = gl.DEPTH32F_STENCIL8,
                _s),
            _a);
    }
    else {
        table = (_t = {},
            _t[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_BYTE] = (_u = {},
                _u[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA,
                _u[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB,
                _u[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.ALPHA] = gl.ALPHA,
                _u[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.LUMINANCE] = gl.LUMINANCE,
                _u[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.LUMINANCE_ALPHA] = gl.LUMINANCE_ALPHA,
                _u),
            _t[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_5_6_5] = (_v = {},
                _v[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGB] = gl.RGB,
                _v),
            _t[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_4_4_4_4] = (_w = {},
                _w[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA,
                _w),
            _t[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.TYPES.UNSIGNED_SHORT_5_5_5_1] = (_x = {},
                _x[_pixi_constants__WEBPACK_IMPORTED_MODULE_1__.FORMATS.RGBA] = gl.RGBA,
                _x),
            _t);
    }
    return table;
}
Returns a lookup table that maps each type-format pair to a compatible internal format.
@memberof PIXI
@function mapTypeAndFormatToInternalFormat
@private
@param {WebGLRenderingContext} gl - The rendering context.
@returns Lookup table.