2020-09-14 22:57:11 +08:00
|
|
|
import { MeshStandardMaterial } from 'three';
|
|
|
|
import Material from './Material';
|
|
|
|
|
|
|
|
export default {
|
|
|
|
extends: Material,
|
2020-09-17 03:11:23 +08:00
|
|
|
props: {
|
|
|
|
emissive: {
|
|
|
|
type: [Number, String],
|
|
|
|
default: 0,
|
|
|
|
},
|
|
|
|
emissiveIntensity: {
|
|
|
|
type: Number,
|
|
|
|
default: 1,
|
|
|
|
},
|
|
|
|
metalness: {
|
|
|
|
type: Number,
|
|
|
|
default: 0,
|
|
|
|
},
|
|
|
|
roughness: {
|
|
|
|
type: Number,
|
|
|
|
default: 1,
|
|
|
|
},
|
|
|
|
},
|
2020-09-14 22:57:11 +08:00
|
|
|
created() {
|
2020-09-17 03:11:23 +08:00
|
|
|
this.material = new MeshStandardMaterial(this.propsValues());
|
2020-09-14 22:57:11 +08:00
|
|
|
},
|
2020-09-19 23:00:29 +08:00
|
|
|
__hmrId: 'StandardMaterial',
|
2020-09-14 22:57:11 +08:00
|
|
|
};
|