function readBoundingBox(node, objectStack, withCrs = true) {
  const extent = [
    readDecimalString(node.getAttribute('minx')),
    readDecimalString(node.getAttribute('miny')),
    readDecimalString(node.getAttribute('maxx')),
    readDecimalString(node.getAttribute('maxy')),
  ];

  const resolutions = [
    readDecimalString(node.getAttribute('resx')),
    readDecimalString(node.getAttribute('resy')),
  ];

  const result = {
    extent,
    res: resolutions,
  };
  if (!withCrs) {
    return result;
  }

  /** @type {RootObject} */
  if (isV13(objectStack)) {
    result.crs = node.getAttribute('CRS');
  } else {
    result.srs = node.getAttribute('SRS');
  }

  return result;
}
@param {Element} node Node.
@param {Array<*>} objectStack Object stack.
@param {boolean} withCrs Whether to include the CRS attribute.
@return {Object} Bounding box object.