Handle mesh names.
This commit is contained in:
parent
984c900189
commit
dc0fdbbc5d
@ -207,6 +207,9 @@ OV.ThreeImporter = class extends OV.ImporterBase
|
||||
materialIndex = FindMatchingMaterialIndex (this.model, child.material, materialIdToIndex, textureNames);
|
||||
mesh = OV.ConvertThreeGeometryToMesh (child.geometry, materialIndex);
|
||||
}
|
||||
if (child.name !== undefined && child.name !== null) {
|
||||
mesh.SetName (child.name);
|
||||
}
|
||||
|
||||
if (child.matrixWorld !== undefined && child.matrixWorld !== null) {
|
||||
const matrix = new OV.Matrix (child.matrixWorld.elements);
|
||||
|
||||
@ -58,9 +58,6 @@ OV.HasHighpDriverIssue = function ()
|
||||
OV.ConvertThreeGeometryToMesh = function (threeGeometry, materialIndex)
|
||||
{
|
||||
let mesh = new OV.Mesh ();
|
||||
if (threeGeometry.name !== undefined && threeGeometry.name !== null) {
|
||||
mesh.SetName (threeGeometry.name);
|
||||
}
|
||||
let vertices = threeGeometry.attributes.position.array;
|
||||
for (let i = 0; i < vertices.length; i += 3) {
|
||||
let x = vertices[i];
|
||||
|
||||
Loading…
Reference in New Issue
Block a user