Skip to content

Commit

Permalink
fix: heatmap grid3d in webgpu
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaoiver committed Jan 2, 2024
1 parent ac0e64c commit 7969712
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/layers/src/utils/load-image.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
export async function loadImage(
url: string,
): Promise<HTMLImageElement | ImageBitmap> {
if (!!window.createImageBitmap) {
// @ts-ignore
if (window.createImageBitmap) {
const response = await fetch(url);
const imageBitmap = await createImageBitmap(await response.blob());
return imageBitmap;
Expand Down

0 comments on commit 7969712

Please sign in to comment.