@luma.gl/webgl 9.0.0-beta.1 → 9.0.0-beta.3
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/dist/adapter/webgl-device.d.ts +10 -1
- package/dist/adapter/webgl-device.d.ts.map +1 -1
- package/dist/adapter/webgl-device.js +16 -1
- package/dist/adapter/webgl-device.js.map +1 -1
- package/dist/dist.dev.js +73 -115
- package/dist/index.cjs +69 -153
- package/dist/index.d.ts +2 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -4
- package/dist/index.js.map +1 -1
- package/dist.min.js +38 -38
- package/package.json +5 -5
- package/src/adapter/webgl-device.ts +21 -1
- package/src/index.ts +9 -35
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@luma.gl/webgl",
|
|
3
|
-
"version": "9.0.0-beta.
|
|
3
|
+
"version": "9.0.0-beta.3",
|
|
4
4
|
"description": "WebGL2 adapter for the luma.gl API",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -44,12 +44,12 @@
|
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
46
|
"@babel/runtime": "^7.0.0",
|
|
47
|
-
"@luma.gl/constants": "9.0.0-beta.
|
|
48
|
-
"@luma.gl/core": "9.0.0-beta.
|
|
47
|
+
"@luma.gl/constants": "9.0.0-beta.3",
|
|
48
|
+
"@luma.gl/core": "9.0.0-beta.3",
|
|
49
49
|
"@probe.gl/env": "^4.0.2"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
|
-
"@luma.gl/test-utils": "9.0.0-beta.
|
|
52
|
+
"@luma.gl/test-utils": "9.0.0-beta.3"
|
|
53
53
|
},
|
|
54
|
-
"gitHead": "
|
|
54
|
+
"gitHead": "236a5e51ca79fe11f9cb9fd7b0af6520e9c52e87"
|
|
55
55
|
}
|
|
@@ -28,6 +28,7 @@ import {
|
|
|
28
28
|
createHeadlessContext,
|
|
29
29
|
isHeadlessGLRegistered
|
|
30
30
|
} from '../context/context/create-headless-context';
|
|
31
|
+
|
|
31
32
|
import {getDeviceInfo} from './device-helpers/get-device-info';
|
|
32
33
|
import {getDeviceFeatures} from './device-helpers/device-features';
|
|
33
34
|
import {getDeviceLimits, getWebGLLimits, WebGLLimits} from './device-helpers/device-limits';
|
|
@@ -75,6 +76,9 @@ import {WEBGLVertexArray} from './resources/webgl-vertex-array';
|
|
|
75
76
|
import {WEBGLTransformFeedback} from './resources/webgl-transform-feedback';
|
|
76
77
|
|
|
77
78
|
import {readPixelsToArray, readPixelsToBuffer} from '../classic/copy-and-blit';
|
|
79
|
+
import {setGLParameters, getGLParameters} from '../context/parameters/unified-parameter-api';
|
|
80
|
+
import {withGLParameters} from '../context/state-tracker/with-parameters';
|
|
81
|
+
import {clear} from '../classic/clear';
|
|
78
82
|
|
|
79
83
|
const LOG_LEVEL = 1;
|
|
80
84
|
|
|
@@ -405,7 +409,7 @@ ${device.info.vendor}, ${device.info.renderer} for canvas: ${device.canvasContex
|
|
|
405
409
|
}
|
|
406
410
|
|
|
407
411
|
/** @deprecated - should use command encoder */
|
|
408
|
-
override
|
|
412
|
+
override readPixelsToBufferWebGL(
|
|
409
413
|
source: Framebuffer | Texture,
|
|
410
414
|
options?: {
|
|
411
415
|
sourceX?: number;
|
|
@@ -422,6 +426,22 @@ ${device.info.vendor}, ${device.info.renderer} for canvas: ${device.canvasContex
|
|
|
422
426
|
return readPixelsToBuffer(source, options);
|
|
423
427
|
}
|
|
424
428
|
|
|
429
|
+
override setParametersWebGL(parameters: any): void {
|
|
430
|
+
setGLParameters(this, parameters);
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
override getParametersWebGL(parameters: any): any {
|
|
434
|
+
return getGLParameters(this, parameters);
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
override withParametersWebGL(parameters: any, func: any): any {
|
|
438
|
+
withGLParameters(this, parameters, func);
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
override clearWebGL(options?: {framebuffer?: Framebuffer; color?: any; depth?: any; stencil?: any}): void {
|
|
442
|
+
clear(this, options);
|
|
443
|
+
}
|
|
444
|
+
|
|
425
445
|
//
|
|
426
446
|
// WebGL-only API (not part of `Device` API)
|
|
427
447
|
//
|
package/src/index.ts
CHANGED
|
@@ -36,7 +36,7 @@ export {WEBGLVertexArray} from './adapter/resources/webgl-vertex-array';
|
|
|
36
36
|
export type {RenderbufferProps} from './adapter/objects/webgl-renderbuffer';
|
|
37
37
|
export {WEBGLRenderbuffer} from './adapter/objects/webgl-renderbuffer';
|
|
38
38
|
|
|
39
|
-
// WebGL adapter classes
|
|
39
|
+
// WebGL adapter classes
|
|
40
40
|
export {WEBGLTransformFeedback} from './adapter/resources/webgl-transform-feedback';
|
|
41
41
|
|
|
42
42
|
// WebGL adapter classes
|
|
@@ -55,15 +55,6 @@ export {
|
|
|
55
55
|
|
|
56
56
|
export {setDeviceParameters, withDeviceParameters} from './adapter/converters/device-parameters';
|
|
57
57
|
|
|
58
|
-
export type {GLParameters} from '@luma.gl/constants';
|
|
59
|
-
export {
|
|
60
|
-
getGLParameters,
|
|
61
|
-
setGLParameters,
|
|
62
|
-
resetGLParameters
|
|
63
|
-
} from './context/parameters/unified-parameter-api';
|
|
64
|
-
|
|
65
|
-
export {withGLParameters} from './context/state-tracker/with-parameters';
|
|
66
|
-
|
|
67
58
|
// HELPERS - EXPERIMENTAL
|
|
68
59
|
export {getShaderLayout} from './adapter/helpers/get-shader-layout';
|
|
69
60
|
export {
|
|
@@ -74,9 +65,7 @@ export {
|
|
|
74
65
|
// TEST EXPORTS
|
|
75
66
|
export {TEXTURE_FORMATS as _TEXTURE_FORMATS} from './adapter/converters/texture-formats';
|
|
76
67
|
|
|
77
|
-
// DEPRECATED EXPORTS
|
|
78
|
-
export {clear} from './classic/clear';
|
|
79
|
-
export {readPixelsToBuffer, readPixelsToArray, copyToTexture} from './classic/copy-and-blit';
|
|
68
|
+
// DEPRECATED TEST EXPORTS
|
|
80
69
|
// State tracking
|
|
81
70
|
export {
|
|
82
71
|
trackContextState,
|
|
@@ -86,25 +75,10 @@ export {
|
|
|
86
75
|
// Polyfills (supports a subset of WebGL2 APIs on WebGL1 contexts)
|
|
87
76
|
export {polyfillContext} from './context/polyfill/polyfill-context';
|
|
88
77
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
// GLDrawMode,
|
|
97
|
-
// GLPrimitive,
|
|
98
|
-
// GLDataType,
|
|
99
|
-
// GLPixelType,
|
|
100
|
-
// GLUniformType,
|
|
101
|
-
// GLSamplerType,
|
|
102
|
-
// GLCompositeType,
|
|
103
|
-
// GLFunction,
|
|
104
|
-
// GLBlendEquation,
|
|
105
|
-
// GLBlendFunction,
|
|
106
|
-
// GLStencilOp,
|
|
107
|
-
// GLSamplerParameters,
|
|
108
|
-
// GLValueParameters,
|
|
109
|
-
// GLFunctionParameters
|
|
110
|
-
// } from '@luma.gl/constants';
|
|
78
|
+
export {
|
|
79
|
+
resetGLParameters,
|
|
80
|
+
setGLParameters,
|
|
81
|
+
getGLParameters
|
|
82
|
+
} from './context/parameters/unified-parameter-api';
|
|
83
|
+
|
|
84
|
+
export {withGLParameters} from './context/state-tracker/with-parameters';
|