shadow$provide.module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$utils$convertFillInputToFillStyle = function(global, require, module, exports) {
  function handleFillPattern(fill, value, defaultStyle) {
    fill.fill = value;
    fill.color = 16777215;
    fill.texture = value.texture;
    fill.matrix = value.transform;
    fill.textureSpace = value.textureSpace;
    return {...defaultStyle, ...fill};
  }
  function handleFillGradient(fill, value, defaultStyle) {
    value.buildGradient();
    fill.fill = value;
    fill.color = 16777215;
    fill.texture = value.texture;
    fill.matrix = value.transform;
    fill.textureSpace = value.textureSpace;
    return {...defaultStyle, ...fill};
  }
  function toFillStyle(value, defaultStyle) {
    if (void 0 === value || null === value) {
      return null;
    }
    var fill = {};
    if (Color.Color.isColorLike(value)) {
      return value = Color.Color.shared.setValue(value ?? 0), fill.color = value.toNumber(), fill.alpha = 1 === value.alpha ? defaultStyle.alpha : value.alpha, fill.texture = Texture.Texture.WHITE, {...defaultStyle, ...fill};
    }
    if (value instanceof Texture.Texture) {
      return fill.texture = value, {...defaultStyle, ...fill};
    }
    if (value instanceof FillPattern.FillPattern) {
      return handleFillPattern(fill, value, defaultStyle);
    }
    if (value instanceof FillGradient.FillGradient) {
      return handleFillGradient(fill, value, defaultStyle);
    }
    if (value.fill && value.fill instanceof FillPattern.FillPattern) {
      return handleFillPattern(value, value.fill, defaultStyle);
    }
    if (value.fill && value.fill instanceof FillGradient.FillGradient) {
      return handleFillGradient(value, value.fill, defaultStyle);
    }
    defaultStyle = {...defaultStyle, ...value};
    fill = Color.Color.shared.setValue(defaultStyle.color);
    defaultStyle.alpha *= fill.alpha;
    defaultStyle.color = fill.toNumber();
    return defaultStyle;
  }
  var Color = require("module$node_modules$pixi_DOT_js$lib$color$Color"), Texture = require("module$node_modules$pixi_DOT_js$lib$rendering$renderers$shared$texture$Texture"), FillGradient = require("module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$fill$FillGradient"), FillPattern = require("module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$fill$FillPattern");
  "use strict";
  exports.toFillStyle = toFillStyle;
  exports.toStrokeStyle = function(value, defaultStyle) {
    const {width, alignment, miterLimit, cap, join, pixelLine, ...rest} = defaultStyle;
    return (value = toFillStyle(value, rest)) ? {width, alignment, miterLimit, cap, join, pixelLine, ...value} : null;
  };
};

//# sourceMappingURL=module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$utils$convertFillInputToFillStyle.js.map
