shadow$provide.module$node_modules$pixi_DOT_js$lib$rendering$renderers$gl$shader$program$ensureAttributes = function(global, require, module, exports) {
  var warn = require("module$node_modules$pixi_DOT_js$lib$utils$logging$warn"), getAttributeInfoFromFormat = require("module$node_modules$pixi_DOT_js$lib$rendering$renderers$shared$geometry$utils$getAttributeInfoFromFormat");
  "use strict";
  exports.ensureAttributes = function(geometry, extractedData) {
    for (var i in geometry.attributes) {
      const attribute = geometry.attributes[i], attributeData = extractedData[i];
      attributeData ? (attribute.format ?? (attribute.format = attributeData.format), attribute.offset ?? (attribute.offset = attributeData.offset), attribute.instance ?? (attribute.instance = attributeData.instance)) : warn.warn(`Attribute ${i} is not present in the shader, but is present in the geometry. Unable to infer attribute details.`);
    }
    const {buffers, attributes} = geometry;
    geometry = {};
    extractedData = {};
    for (var j in buffers) {
      i = buffers[j], geometry[i.uid] = 0, extractedData[i.uid] = 0;
    }
    for (var j$jscomp$0 in attributes) {
      j = attributes[j$jscomp$0], geometry[j.buffer.uid] += getAttributeInfoFromFormat.getAttributeInfoFromFormat(j.format).stride;
    }
    for (const j in attributes) {
      j$jscomp$0 = attributes[j], j$jscomp$0.stride ?? (j$jscomp$0.stride = geometry[j$jscomp$0.buffer.uid]), j$jscomp$0.start ?? (j$jscomp$0.start = extractedData[j$jscomp$0.buffer.uid]), extractedData[j$jscomp$0.buffer.uid] += getAttributeInfoFromFormat.getAttributeInfoFromFormat(j$jscomp$0.format).stride;
    }
  };
};

//# sourceMappingURL=module$node_modules$pixi_DOT_js$lib$rendering$renderers$gl$shader$program$ensureAttributes.js.map
