Update exporterbim.js force color to integer (#430)

This commit is contained in:
Luiz Henrique Cassettari 2023-10-24 13:06:47 -03:00 committed by GitHub
parent e89e7a0e1d
commit 97333a932a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -83,9 +83,9 @@ export class ExporterBim extends ExporterBase
let triangle = mesh.GetTriangle (i);
let material = exporterModel.GetMaterial (triangle.mat);
let faceColor = {
r : material.color.r,
g : material.color.g,
b : material.color.b,
r : Math.round (material.color.r),
g : Math.round (material.color.g),
b : Math.round (material.color.b),
a : ColorComponentFromFloat (material.opacity),
};
faceColors.push (faceColor.r, faceColor.g, faceColor.b, faceColor.a);