private void FVmeshVertexColor(FigureDataStruct fv) { GameObject meshInstance = BuilderFunctions.InstantiateMesh(fv.Vertices, fv.Faces, transform, fv.shootability[0], fv.id[0]); BuilderFunctions.AddMat(fv.Opacity, meshInstance, _vertexColors, _opaqueVertexColors); meshInstance.GetComponent <MeshFilter>().mesh.colors = fv.VertColorList[0]; }
private void FVmeshSingleColor(FigureDataStruct fv) { GameObject meshInstance = BuilderFunctions.InstantiateMesh(fv.Vertices, fv.Faces, transform, fv.shootability[0], fv.id[0]); BuilderFunctions.AddMat(fv.Opacity, meshInstance, _singleColor, _opaqueSingleColor); meshInstance.GetComponent <MeshRenderer>().material.SetColor("_color", fv.SingleColor); }
private void FVmeshMultiVertColor(FigureDataStruct fv) { GameObject meshInstance = BuilderFunctions.InstantiateMesh(fv.Vertices, fv.Faces, multiMeshContainer, fv.shootability[0], fv.id[0]); List <Color[]> _multiVertColorList = fv.VertColorList; multiMeshContainer.GetComponent <MultiVertColUpdater>().SetStuff(_multiVertColorList, meshInstance); meshInstance.GetComponent <MeshFilter>().mesh.colors = _multiVertColorList[0]; BuilderFunctions.AddMat(fv.Opacity, meshInstance, _vertexColors, _opaqueVertexColors); }
public void UpdateMatlabFigure() { string _path = Application.streamingAssetsPath + System.IO.Path.DirectorySeparatorChar + fileSelectionDropDown.Text; List <FigureDataStruct> _figureDataList = new FigureDataStructList(_path).DataStructList; for (int i = 0; i < _figureDataList.Count; i++) { FigureDataStruct _figureData = _figureDataList[i]; _matTypes[_figureData.Type](_figureData); } }
public void UpdateMatlabFigure() { string _path = Application.streamingAssetsPath + System.IO.Path.DirectorySeparatorChar + fileSelectionDropDown.Text; List <FigureDataStruct> h2 = new FigureDataStructList(_path).DataStructList; for (int i = 0; i < h2.Count; i++) { FigureDataStruct temp = h2[i]; _matTypes[temp.Type](temp); } }
private void HandleShootConnections(FigureDataStruct d) { // do nothing. This void only exists to fit the dictionary pattern. }
private void CamDistSetter(FigureDataStruct cd) => CamOrbit.functions.SetCamDistance(cd.CamDistance);
private void drawGraph(FigureDataStruct gr) => graphContainer.GetComponent <GraphController>().BuildGraph(gr.GraphPointList, gr.SingleColor);
private void scatter3(FigureDataStruct sc) => BuilderFunctions.SpawnScatterSpheres(sc.Vertices, sc.PointSize, sc.SingleColor, _opaqueSingleColor, transform, sc.shootability, sc.id);