Skip to content
This repository was archived by the owner on Dec 12, 2022. It is now read-only.

Commit d8d27bc

Browse files
committed
Do not display side/shadowSide for line materials
1 parent e524af7 commit d8d27bc

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

src/app/data/materials.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,15 @@ const base = [
3030
polygonOffset
3131
];
3232

33+
const lineBase = [
34+
// Remove 'side', 'shadowSide' from line materials
35+
Object.assign({}, common, {
36+
props: [...common.props.filter(({ prop }) => ['side', 'shadowSide'].indexOf(prop) === -1)],
37+
}),
38+
blending,
39+
polygonOffset
40+
];
41+
3342
const GenericMaterial = {
3443
type: 'material',
3544
props: base,
@@ -253,7 +262,7 @@ export default {
253262
props: [
254263
prop.color,
255264
line,
256-
...base
265+
...lineBase
257266
],
258267
},
259268
LineDashedMaterial: {
@@ -262,7 +271,7 @@ export default {
262271
prop.color,
263272
line,
264273
...lineDashed,
265-
...base
274+
...lineBase
266275
],
267276
},
268277
};

0 commit comments

Comments
 (0)