public void StructureByEnvelopeTest() { var envModel = Model.FromJson(System.IO.File.ReadAllText(INPUT + "Envelope.json")); var lvlModel = Model.FromJson(System.IO.File.ReadAllText(INPUT + "Levels.json")); var inputs = new StructureByEnvelopeInputs( gridXAxisInterval: 4.0, gridYAxisInterval: 5.0, slabEdgeOffset: 1.0, displayGrid: false, typeOfConstruction: StructureByEnvelopeInputsTypeOfConstruction.Steel, bucketName: "", uploadsBucket: "", modelInputKeys: new Dictionary <string, string>(), gltfKey: "", elementsKey: "", ifcKey: ""); var outputs = StructureByEnvelope.Execute( new Dictionary <string, Model> { { "Envelope", envModel }, { "Levels", lvlModel } }, inputs); System.IO.File.WriteAllText(OUTPUT + "StructureByEnvelope.json", outputs.Model.ToJson()); outputs.Model.AddElements(envModel.Elements.Values); outputs.Model.AddElements(lvlModel.Elements.Values); outputs.Model.ToGlTF(OUTPUT + "StructureByEnvelope.glb"); }
public void StructureByEnvelopeTest() { var model = Model.FromJson(System.IO.File.ReadAllText("../../../../core.json")); var inputs = new StructureByEnvelopeInputs(4.0, 5.0, "", "", new Dictionary <string, string>(), "", "", ""); var outputs = StructureByEnvelope.Execute(new Dictionary <string, Model> { { "envelope", model } }, inputs); System.IO.File.WriteAllText("../../../../structureCore.json", outputs.Model.ToJson()); outputs.Model.ToGlTF("../../../../structureCore.glb"); model = Model.FromJson(System.IO.File.ReadAllText("../../../../mass.json")); inputs = new StructureByEnvelopeInputs(4.0, 5.0, "", "", new Dictionary <string, string>(), "", "", ""); outputs = StructureByEnvelope.Execute(new Dictionary <string, Model> { { "envelope", model } }, inputs); System.IO.File.WriteAllText("../../../../structureMass.json", outputs.Model.ToJson()); outputs.Model.ToGlTF("../../../../structureMass.glb"); model = Model.FromJson(System.IO.File.ReadAllText("../../../../story.json")); inputs = new StructureByEnvelopeInputs(4.0, 5.0, "", "", new Dictionary <string, string>(), "", "", ""); outputs = StructureByEnvelope.Execute(new Dictionary <string, Model> { { "envelope", model } }, inputs); System.IO.File.WriteAllText("../../../../structureStory.json", outputs.Model.ToJson()); outputs.Model.ToGlTF("../../../../structureStory.glb"); }
public void StructureByEnvelopeTest() { var envModel = Model.FromJson(System.IO.File.ReadAllText(INPUT + "Envelope.json")); var lvlModel = Model.FromJson(System.IO.File.ReadAllText(INPUT + "Levels.json")); var inputs = new StructureByEnvelopeInputs( gridXAxisInterval: 4.0, gridYAxisInterval: 5.0, "", "", new Dictionary <string, string>(), "", "", ""); var outputs = StructureByEnvelope.Execute( new Dictionary <string, Model> { { "Envelope", envModel }, { "Levels", lvlModel } }, inputs); System.IO.File.WriteAllText(OUTPUT + "StructureByEnvelope.json", outputs.Model.ToJson()); outputs.Model.AddElements(envModel.Elements.Values); outputs.Model.AddElements(lvlModel.Elements.Values); outputs.Model.ToGlTF(OUTPUT + "StructureByEnvelope.glb"); }