@luma.gl/core 9.1.0-beta.9 → 9.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luma.gl/core",
3
- "version": "9.1.0-beta.9",
3
+ "version": "9.1.1",
4
4
  "description": "The luma.gl core Device API",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -46,5 +46,5 @@
46
46
  "@probe.gl/stats": "^4.0.8",
47
47
  "@types/offscreencanvas": "^2019.6.4"
48
48
  },
49
- "gitHead": "ce90c649e27184c399eaeab814ec21a46f45677b"
49
+ "gitHead": "16a8a01740728ea0735d7d86fab21a677c3df0ce"
50
50
  }
@@ -195,7 +195,8 @@ export abstract class CanvasContext {
195
195
  // For headless gl we might have used custom width and height
196
196
  // hence use cached clientWidth
197
197
  const [drawingBufferWidth] = this.getDrawingBufferSize();
198
- const {clientWidth} = this._canvasSizeInfo;
198
+ // _canvasSizeInfo may not be populated if `setDevicePixelRatio` is never called
199
+ const clientWidth = this._canvasSizeInfo.clientWidth || this.htmlCanvas?.clientWidth;
199
200
  return clientWidth ? drawingBufferWidth / clientWidth : 1;
200
201
  } catch {
201
202
  return 1;