1 | import { NormalMapTypes } from "../constants.js";
|
2 | import { Color, ColorRepresentation } from "../math/Color.js";
|
3 | import { Euler } from "../math/Euler.js";
|
4 | import { Vector2 } from "../math/Vector2.js";
|
5 | import { Texture } from "../textures/Texture.js";
|
6 | import { Material, MaterialParameters } from "./Material.js";
|
7 |
|
8 | export interface MeshStandardMaterialParameters extends MaterialParameters {
|
9 | color?: ColorRepresentation | undefined;
|
10 | roughness?: number | undefined;
|
11 | metalness?: number | undefined;
|
12 | map?: Texture | null | undefined;
|
13 | lightMap?: Texture | null | undefined;
|
14 | lightMapIntensity?: number | undefined;
|
15 | aoMap?: Texture | null | undefined;
|
16 | aoMapIntensity?: number | undefined;
|
17 | emissive?: ColorRepresentation | undefined;
|
18 | emissiveIntensity?: number | undefined;
|
19 | emissiveMap?: Texture | null | undefined;
|
20 | bumpMap?: Texture | null | undefined;
|
21 | bumpScale?: number | undefined;
|
22 | normalMap?: Texture | null | undefined;
|
23 | normalMapType?: NormalMapTypes | undefined;
|
24 | normalScale?: Vector2 | undefined;
|
25 | displacementMap?: Texture | null | undefined;
|
26 | displacementScale?: number | undefined;
|
27 | displacementBias?: number | undefined;
|
28 | roughnessMap?: Texture | null | undefined;
|
29 | metalnessMap?: Texture | null | undefined;
|
30 | alphaMap?: Texture | null | undefined;
|
31 | envMap?: Texture | null | undefined;
|
32 | envMapRotation?: Euler | undefined;
|
33 | envMapIntensity?: number | undefined;
|
34 | wireframe?: boolean | undefined;
|
35 | wireframeLinewidth?: number | undefined;
|
36 | fog?: boolean | undefined;
|
37 | flatShading?: boolean | undefined;
|
38 | }
|
39 |
|
40 | export class MeshStandardMaterial extends Material {
|
41 | constructor(parameters?: MeshStandardMaterialParameters);
|
42 |
|
43 | /**
|
44 | * Read-only flag to check if a given object is of type {@link MeshStandardMaterial}.
|
45 | * @remarks This is a _constant_ value
|
46 | * @defaultValue `true`
|
47 | */
|
48 | readonly isMeshStandardMaterial: true;
|
49 |
|
50 | |
51 |
|
52 |
|
53 | defines: { [key: string]: any };
|
54 |
|
55 | |
56 |
|
57 |
|
58 | color: Color;
|
59 |
|
60 | |
61 |
|
62 |
|
63 | roughness: number;
|
64 |
|
65 | |
66 |
|
67 |
|
68 | metalness: number;
|
69 |
|
70 | |
71 |
|
72 |
|
73 | map: Texture | null;
|
74 |
|
75 | |
76 |
|
77 |
|
78 | lightMap: Texture | null;
|
79 |
|
80 | |
81 |
|
82 |
|
83 | lightMapIntensity: number;
|
84 |
|
85 | |
86 |
|
87 |
|
88 | aoMap: Texture | null;
|
89 |
|
90 | |
91 |
|
92 |
|
93 | aoMapIntensity: number;
|
94 |
|
95 | |
96 |
|
97 |
|
98 | emissive: Color;
|
99 |
|
100 | |
101 |
|
102 |
|
103 | emissiveIntensity: number;
|
104 |
|
105 | |
106 |
|
107 |
|
108 | emissiveMap: Texture | null;
|
109 |
|
110 | |
111 |
|
112 |
|
113 | bumpMap: Texture | null;
|
114 |
|
115 | |
116 |
|
117 |
|
118 | bumpScale: number;
|
119 |
|
120 | |
121 |
|
122 |
|
123 | normalMap: Texture | null;
|
124 |
|
125 | |
126 |
|
127 |
|
128 | normalMapType: NormalMapTypes;
|
129 |
|
130 | |
131 |
|
132 |
|
133 | normalScale: Vector2;
|
134 |
|
135 | |
136 |
|
137 |
|
138 | displacementMap: Texture | null;
|
139 |
|
140 | |
141 |
|
142 |
|
143 | displacementScale: number;
|
144 |
|
145 | |
146 |
|
147 |
|
148 | displacementBias: number;
|
149 |
|
150 | |
151 |
|
152 |
|
153 | roughnessMap: Texture | null;
|
154 |
|
155 | |
156 |
|
157 |
|
158 | metalnessMap: Texture | null;
|
159 |
|
160 | |
161 |
|
162 |
|
163 | alphaMap: Texture | null;
|
164 |
|
165 | |
166 |
|
167 |
|
168 | envMap: Texture | null;
|
169 |
|
170 | |
171 |
|
172 |
|
173 | envMapRotation: Euler;
|
174 |
|
175 | |
176 |
|
177 |
|
178 | envMapIntensity: number;
|
179 |
|
180 | |
181 |
|
182 |
|
183 | wireframe: boolean;
|
184 |
|
185 | |
186 |
|
187 |
|
188 | wireframeLinewidth: number;
|
189 |
|
190 | |
191 |
|
192 |
|
193 | wireframeLinecap: string;
|
194 |
|
195 | |
196 |
|
197 |
|
198 | wireframeLinejoin: string;
|
199 |
|
200 | |
201 |
|
202 |
|
203 |
|
204 | flatShading: boolean;
|
205 |
|
206 | |
207 |
|
208 |
|
209 |
|
210 | fog: boolean;
|
211 |
|
212 | setValues(parameters: MeshStandardMaterialParameters): void;
|
213 | }
|