Spaces:
Running
Running
Update viewer.js
Browse files
viewer.js
CHANGED
|
@@ -231,11 +231,11 @@ export async function initializeViewer(config, instanceId) {
|
|
| 231 |
let matSol = new pc.StandardMaterial();
|
| 232 |
matSol.blendType = pc.BLEND_NONE;
|
| 233 |
matSol.emissive = new pc.Color(color_bg);
|
| 234 |
-
|
| 235 |
matSol.emissiveIntensity = 1;
|
| 236 |
matSol.update();
|
| 237 |
|
| 238 |
-
const bgPlane = new pc.Entity("Plane");
|
| 239 |
bgPlane.addComponent("model", { type: "plane" });
|
| 240 |
bgPlane.setLocalPosition(0, 0.1, 0);
|
| 241 |
const mat = new pc.StandardMaterial();
|
|
@@ -246,7 +246,7 @@ export async function initializeViewer(config, instanceId) {
|
|
| 246 |
mat.useLighting = false;
|
| 247 |
mat.update();
|
| 248 |
bgPlane.model.material = mat;
|
| 249 |
-
app.root.addChild(bgPlane);
|
| 250 |
|
| 251 |
traverse(presentoirEntity, node => {
|
| 252 |
if (node.render && node.render.meshInstances) {
|
|
|
|
| 231 |
let matSol = new pc.StandardMaterial();
|
| 232 |
matSol.blendType = pc.BLEND_NONE;
|
| 233 |
matSol.emissive = new pc.Color(color_bg);
|
| 234 |
+
matSol.emissiveMap = grilleTex;
|
| 235 |
matSol.emissiveIntensity = 1;
|
| 236 |
matSol.update();
|
| 237 |
|
| 238 |
+
/*const bgPlane = new pc.Entity("Plane");
|
| 239 |
bgPlane.addComponent("model", { type: "plane" });
|
| 240 |
bgPlane.setLocalPosition(0, 0.1, 0);
|
| 241 |
const mat = new pc.StandardMaterial();
|
|
|
|
| 246 |
mat.useLighting = false;
|
| 247 |
mat.update();
|
| 248 |
bgPlane.model.material = mat;
|
| 249 |
+
app.root.addChild(bgPlane);*/
|
| 250 |
|
| 251 |
traverse(presentoirEntity, node => {
|
| 252 |
if (node.render && node.render.meshInstances) {
|