@luma.gl/webgl 9.0.11 → 9.0.14

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/webgl",
3
- "version": "9.0.11",
3
+ "version": "9.0.14",
4
4
  "description": "WebGL2 adapter for the luma.gl core API",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -43,8 +43,8 @@
43
43
  "@luma.gl/core": "^9.0.0"
44
44
  },
45
45
  "dependencies": {
46
- "@luma.gl/constants": "9.0.11",
46
+ "@luma.gl/constants": "9.0.14",
47
47
  "@probe.gl/env": "^4.0.2"
48
48
  },
49
- "gitHead": "82c56392f73c3f7b258e2928d687a4beca2e2838"
49
+ "gitHead": "0b466762e8255ed11b00c6bc518049d3b54c4009"
50
50
  }
@@ -56,7 +56,7 @@ export class WEBGLTransformFeedback extends TransformFeedback {
56
56
 
57
57
  end(): void {
58
58
  this.gl.endTransformFeedback();
59
- if (!this.bindOnUse) {
59
+ if (this.bindOnUse) {
60
60
  this._unbindBuffers();
61
61
  }
62
62
  this.gl.bindTransformFeedback(GL.TRANSFORM_FEEDBACK, null);
@@ -96,6 +96,9 @@ export class WEBGLVertexArray extends VertexArray {
96
96
  // Attaches ARRAY_BUFFER with specified buffer format to location
97
97
  this.device.gl.vertexAttribPointer(location, size, type, normalized, stride, offset);
98
98
  }
99
+ // Clear binding - keeping it may cause [.WebGL-0x12804417100]
100
+ // GL_INVALID_OPERATION: A transform feedback buffer that would be written to is also bound to a non-transform-feedback target
101
+ this.device.gl.bindBuffer(GL.ARRAY_BUFFER, null);
99
102
 
100
103
  // Mark as non-constant
101
104
  this.device.gl.enableVertexAttribArray(location);
@@ -229,6 +229,10 @@ ${device.info.vendor}, ${device.info.renderer} for canvas: ${device.canvasContex
229
229
  (this.gl as any).device = this; // Update GL context: Link webgl context back to device
230
230
  (this.gl as any)._version = 2; // Update GL context: Store WebGL version field on gl context (HACK to identify debug contexts)
231
231
 
232
+ if (props.spector) {
233
+ this.spectorJS = initializeSpectorJS({...this.props, canvas: this.handle.canvas});
234
+ }
235
+
232
236
  // luma Device fields
233
237
  this.info = getDeviceInfo(this.gl, this._extensions);
234
238
  this.limits = new WebGLDeviceLimits(this.gl);
@@ -255,10 +259,6 @@ ${device.info.vendor}, ${device.info.renderer} for canvas: ${device.canvasContex
255
259
  log.level = Math.max(log.level, 1);
256
260
  log.warn('WebGL debug mode activated. Performance reduced.')();
257
261
  }
258
-
259
- if (props.spector) {
260
- this.spectorJS = initializeSpectorJS({...this.props, canvas: this.handle.canvas});
261
- }
262
262
  }
263
263
 
264
264
  /**
@@ -15,11 +15,11 @@ type SpectorProps = {
15
15
  };
16
16
 
17
17
  const DEFAULT_SPECTOR_PROPS: SpectorProps = {
18
- spector: log.get('spector') || log.get('inspect')
18
+ spector: log.get('spector') || log.get('spectorjs')
19
19
  };
20
20
 
21
21
  // https://github.com/BabylonJS/Spector.js#basic-usage
22
- const SPECTOR_CDN_URL = 'https://spectorcdn.babylonjs.com/spector.bundle.js';
22
+ const SPECTOR_CDN_URL = 'https://cdn.jsdelivr.net/npm/spectorjs@0.9.30/dist/spector.bundle.js';
23
23
  const LOG_LEVEL = 1;
24
24
 
25
25
  let spector: any = null;