Rename result to output.
This commit is contained in:
parent
ec4bc495a2
commit
009925c4b6
10
source/external/threeconverter.js
vendored
10
source/external/threeconverter.js
vendored
@ -6,7 +6,7 @@ OV.ModelToThreeConversionParams = class
|
||||
}
|
||||
};
|
||||
|
||||
OV.ModelToThreeConversionResult = class
|
||||
OV.ModelToThreeConversionOutput = class
|
||||
{
|
||||
constructor ()
|
||||
{
|
||||
@ -14,9 +14,9 @@ OV.ModelToThreeConversionResult = class
|
||||
}
|
||||
};
|
||||
|
||||
OV.ConvertModelToThreeMeshes = function (model, params, result, callbacks)
|
||||
OV.ConvertModelToThreeMeshes = function (model, params, output, callbacks)
|
||||
{
|
||||
function CreateThreeMaterial (model, materialIndex, params, result)
|
||||
function CreateThreeMaterial (model, materialIndex, params, output)
|
||||
{
|
||||
function SetTextureParameters (texture, threeTexture)
|
||||
{
|
||||
@ -91,7 +91,7 @@ OV.ConvertModelToThreeMeshes = function (model, params, result, callbacks)
|
||||
});
|
||||
|
||||
if (material.isDefault) {
|
||||
result.defaultMaterial = threeMaterial;
|
||||
output.defaultMaterial = threeMaterial;
|
||||
}
|
||||
|
||||
return threeMaterial;
|
||||
@ -195,7 +195,7 @@ OV.ConvertModelToThreeMeshes = function (model, params, result, callbacks)
|
||||
|
||||
let modelThreeMaterials = [];
|
||||
for (let materialIndex = 0; materialIndex < model.MaterialCount (); materialIndex++) {
|
||||
let threeMaterial = CreateThreeMaterial (model, materialIndex, params, result);
|
||||
let threeMaterial = CreateThreeMaterial (model, materialIndex, params, output);
|
||||
modelThreeMaterials.push (threeMaterial);
|
||||
}
|
||||
|
||||
|
||||
6
source/external/threemodelloader.js
vendored
6
source/external/threemodelloader.js
vendored
@ -63,13 +63,13 @@ OV.ThreeModelLoader = class
|
||||
this.callbacks.onVisualizationStart ();
|
||||
let params = new OV.ModelToThreeConversionParams ();
|
||||
params.forceMediumpForMaterials = this.hasHighpDriverIssue;
|
||||
let result = new OV.ModelToThreeConversionResult ();
|
||||
OV.ConvertModelToThreeMeshes (importResult.model, params, result, {
|
||||
let output = new OV.ModelToThreeConversionOutput ();
|
||||
OV.ConvertModelToThreeMeshes (importResult.model, params, output, {
|
||||
onTextureLoaded : () => {
|
||||
this.callbacks.onTextureLoaded ();
|
||||
},
|
||||
onModelLoaded : (meshes) => {
|
||||
this.defaultMaterial = result.defaultMaterial;
|
||||
this.defaultMaterial = output.defaultMaterial;
|
||||
this.callbacks.onModelFinished (importResult, meshes);
|
||||
this.inProgress = false;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user