/* COPYRIGHT Esri - https://js.arcgis.com/5.0.18/LICENSE.txt */
import r from"../../core/Error.js";import{throwIfAborted as e}from"../../core/promiseUtils.js";async function t(t,o,a){let c;try{c=await createImageBitmap(t)}catch(l){throw new r("request:server",`Unable to load ${o}`,{url:o,error:l})}return e(a),c}async function o(t,o,a,c,l){let n;try{n=await createImageBitmap(t)}catch(i){throw new r("request:server",`Unable to load tile ${o}/${a}/${c}`,{error:i,level:o,row:a,col:c})}return e(l),n}export{t as createBitmap,o as createTileBitmap};
