function rePositionFilterTypeFillImage(shapeObj) {
  const { angle, flipX, flipY } = shapeObj;
  const fillImage = getFillImageFromShape(shapeObj);
  const rotatedShapeCornerDimension = getRotatedDimension(shapeObj);
  const { right, bottom } = rotatedShapeCornerDimension;
  let { width, height } = rotatedShapeCornerDimension;
  const diffLeft = (width - shapeObj.width) / 2;
  const diffTop = (height - shapeObj.height) / 2;
  const cropX = shapeObj.left - shapeObj.width / 2 - diffLeft;
  const cropY = shapeObj.top - shapeObj.height / 2 - diffTop;
  let left = width / 2 - diffLeft;
  let top = height / 2 - diffTop;
  const fillImageMaxSize = Math.max(width, height) + Math.max(diffLeft, diffTop);

  [left, top, width, height] = calculateFillImageDimensionOutsideCanvas({
    shapeObj,
    left,
    top,
    width,
    height,
    cropX,
    cropY,
    flipX,
    flipY,
    right,
    bottom,
  });

  fillImage.set({
    angle: flipX === flipY ? -angle : angle,
    left,
    top,
    width,
    height,
    cropX,
    cropY,
    flipX,
    flipY,
  });

  setCustomProperty(fillImage, { fillImageMaxSize });
}
Reset the image position in the filter type fill area.
@param {fabric.Object} shapeObj - Shape object
@private