/// <summary> /// Imports browse artefact's mesh and texture, assigns object info /// </summary> /// <param name="browseIdentifiers">array of identifiers to browse</param> public void ImportArtefacts(string[] browseIdentifiers) { ResetInstances(); importedObjects = new GameObject[browseIdentifiers.Length]; progressBar.SetActive(true); ProgressBarCont.SetMaxVal(browseIdentifiers.Length * 2); for (int i = 0; i < browseIdentifiers.Length; i++) { string meshLocation = Paths.PathToFile(DublinCoreReader.GetMeshLocationForArtefactWithIdentifier(browseIdentifiers [i])); string texLocation = Paths.PathToFile(DublinCoreReader.GetTextureLocationForArtefactWithIdentifier(browseIdentifiers [i])); StartCoroutine(ImportModel(i, browseIdentifiers[i], meshLocation, texLocation)); } }
private void GetIdentifiers(string collectId) { collectionId = collectId; string[] collectionIdentifiers = CollectionReader.GetIdentifiersForArtefactsInCollectionWithIdentifier(collectId); importedObjects = new GameObject[collectionIdentifiers.Length]; progressBar.SetActive(true); ProgressBarCont.SetMaxVal(collectionIdentifiers.Length * 2); for (int i = 0; i < collectionIdentifiers.Length; i++) { string meshLocation = Paths.PathToFile(DublinCoreReader.GetMeshLocationForArtefactWithIdentifier(collectionIdentifiers [i])); string texLocation = Paths.PathToFile(DublinCoreReader.GetTextureLocationForArtefactWithIdentifier(collectionIdentifiers [i])); StartCoroutine(ImportModel(i, collectionIdentifiers[i], meshLocation, texLocation)); } }
public void TestGetMeshLocationForArtefactWithIdentifier_Invalid() { string meshLocation = DublinCoreReader.GetMeshLocationForArtefactWithIdentifier("DOES NOT EXIST"); }
public void TestGetMeshLocationForArtefactWithIdentifier_NoAssets() { string meshLocation = DublinCoreReader.GetMeshLocationForArtefactWithIdentifier("NoAssets"); }
public void TestGetMeshLocationForArtefactWithIdentifier() { string meshLocation = DublinCoreReader.GetMeshLocationForArtefactWithIdentifier("TestMonk"); Assert.That(meshLocation == "/VerticeArchive/TEST/Doog.obj"); }