Skip to content

Commit 1c4f9a9

Browse files
feat: Remove webgl-legacy (#8043)
Co-authored-by: Xiaoji Chen <cxiaoji@gmail.com>
1 parent bf8484c commit 1c4f9a9

File tree

172 files changed

+1510
-1468
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

172 files changed

+1510
-1468
lines changed

.ocularrc.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,10 @@ const nodeModules = join(packageRoot, 'node_modules');
55
const lumaModules = join(packageRoot, '../luma.gl/modules');
66

77
const LUMA_ALIASES_LOCAL = {
8-
'luma.gl': `${lumaModules}/main/src`,
98
'@luma.gl/constants': `${lumaModules}/constants/src`,
109
'@luma.gl/core': `${lumaModules}/core/src`,
11-
'@luma.gl/debug': `${lumaModules}/debug/src`,
1210
'@luma.gl/engine': `${lumaModules}/engine/src`,
1311
'@luma.gl/webgl': `${lumaModules}/webgl/src`,
14-
'@luma.gl/gltools': `${lumaModules}/gltools/src`,
1512
'@luma.gl/shadertools': `${lumaModules}/shadertools/src`,
1613
'@luma.gl/test-utils': `${lumaModules}/test-utils/src`,
1714
'@luma.gl/experimental': `${lumaModules}/experimental/src`

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3016,13 +3016,13 @@ For Earlier Beta Releases see below
30163016

30173017
### deck.gl v4.2 Beta Releases
30183018

3019-
#### [4.2.0-alpha.31] - Dec 14
3019+
#### [4.2.0-alpha.32] - Dec 14
30203020
- API Audit: remove initWebGLParameters and move pure-js example (#1235)
30213021
- Fix for invalid triggerName in attribute-manager.invalidate(triggerName) function (#1238)
30223022
- Add polygonLayer geojsonLayer elevationScale prop to whats-new.md (#1237)
30233023
- OrbitController pure-js support (#1234)
30243024

3025-
#### [4.2.0-alpha.30] - Dec 12
3025+
#### [4.2.0-alpha.32] - Dec 12
30263026
- DOCS: updates to clarify what is experimental in 4.2, in "What's New" and "API Reference".
30273027
- DOCS: New Roadmap doc, linking to RFCs.
30283028
- DOCS: List experimental 4.2 features in Roadmap doc.

docs/developer-guide/custom-layers/primitive-layers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ export default class MyLayer extends Layer {
6969
id: this.props.id,
7070
geometry: new Geometry({
7171
id: this.props.id,
72-
drawMode: gl.LINES
72+
topology: 'line-list',
7373
}),
7474
vertexCount: 0,
7575
isIndexed: true

examples/experimental/bezier/src/bezier-curve-layer/bezier-curve-layer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ export default class BezierCurveLayer extends Layer {
112112
Object.assign({}, this.getShaders(), {
113113
id: this.props.id,
114114
geometry: new Geometry({
115-
drawMode: GL.TRIANGLE_STRIP,
115+
topology: 'triangle-strip',
116116
attributes: {
117117
positions: new Float32Array(positions)
118118
}

examples/layer-browser/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
"dependencies": {
1010
"@loaders.gl/ply": "^3.4.13",
1111
"@loaders.gl/gltf": "^3.4.13",
12-
"@luma.gl/experimental": "^8.5.2",
1312
"@luma.gl/debug": "^8.5.2",
1413
"colorbrewer": "^1.0.0",
1514
"d3-request": "^1.0.6",

examples/layer-browser/src/app.jsx

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -165,14 +165,14 @@ export default class App extends PureComponent {
165165
let index = 1;
166166
const layers = [
167167
// the ground - for shadows to drop on
168-
new SolidPolygonLayer({
169-
id: 'ground',
170-
data: LAND_COVER,
171-
getPolygon: f => f,
172-
extruded: false,
173-
filled: true,
174-
getFillColor: [0, 0, 0, 0]
175-
})
168+
// new SolidPolygonLayer({
169+
// id: 'ground',
170+
// data: LAND_COVER,
171+
// getPolygon: f => f,
172+
// extruded: false,
173+
// filled: true,
174+
// getFillColor: [0, 0, 0, 0]
175+
// })
176176
];
177177
const {activeExamples} = this.state;
178178

@@ -185,7 +185,7 @@ export default class App extends PureComponent {
185185
const layer = this._renderExampleLayer(example, settings, index++);
186186

187187
if (typeof settings !== 'object') {
188-
activeExamples[exampleName] = LayerControls.getSettings(layer.props);
188+
activeExamples[exampleName] = LayerControls.getSettings(layer.props, example.props);
189189
}
190190

191191
layers.push(layer);

examples/layer-browser/src/components/layer-controls.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function isAccessor(settingName) {
3636
}
3737

3838
export default class LayerControls extends PureComponent {
39-
static getSettings(props) {
39+
static getSettings(props, defaults) {
4040
const keys = [];
4141
for (const key in props) {
4242
if (!PROP_BLACK_LIST.has(key)) {
@@ -47,7 +47,7 @@ export default class LayerControls extends PureComponent {
4747

4848
const settings = {};
4949
for (const key of keys) {
50-
settings[key] = props[key];
50+
settings[key] = key in defaults ? defaults[key] : props[key];
5151
}
5252
return settings;
5353
}
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
import coreLayerExamples from './core-layers';
2-
import meshLayerExamples from './mesh-layers';
2+
// import meshLayerExamples from './mesh-layers';
33
import aggregationLayerExamples from './aggregation-layers';
44
import additionalLayerExamples from './additional-layers';
5-
import infovisLayerExamples from './infovis-layers';
5+
// import infovisLayerExamples from './infovis-layers';
66
import perfLayerExamples from './perf-layers';
77

88
export default {
99
...coreLayerExamples,
10-
...meshLayerExamples,
10+
// ...meshLayerExamples,
1111
...aggregationLayerExamples,
1212
...additionalLayerExamples,
13-
...infovisLayerExamples,
13+
// ...infovisLayerExamples,
1414
...perfLayerExamples
1515
};

examples/layer-browser/src/examples/mesh-layers.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import {SimpleMeshLayer, ScenegraphLayer} from '@deck.gl/mesh-layers';
22
import {registerLoaders} from '@loaders.gl/core';
33
import {GLTFLoader} from '@loaders.gl/gltf';
44
import {GLTFEnvironment} from '@luma.gl/experimental';
5-
import GL from '@luma.gl/constants';
5+
import {GL} from '@luma.gl/constants';
66

77
import * as dataSamples from '../data-samples';
88

examples/playground/json-examples/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import usMap from './us-map.json';
1414
import dotText from './dot-text.json';
1515

1616
export default {
17+
'website/Scatterplot (ScatterplotLayer)': scatterplot,
1718
// WEBSITE EXAMPLES AS JSON PAYLOADS
1819
'website/3D Heatmap (HexagonLayer)': heatmap,
1920
'website/3D Heatmap (wth Minimap)': heatmapMinimap,

0 commit comments

Comments
 (0)