private void RemoveActorLayer(VisualizationDataSource dataSource) { MeshLayer meshLayer = meshLayers.Find(ml => ml.Guid == dataSource.Guid); if (meshLayer != null) { meshLayers.Remove(meshLayer); } }
public void AddLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.Trajectories) { if (dataSource.Data is PointSet) { AddDataSource(dataSource.Data as PointSet, dataSource.Guid); } } }
private void AddColorMapLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.ColorMap && !dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D <double> ) { AddDataSource(dataSource.Data, dataSource.Guid, double.MinValue, double.MaxValue); } } }
private void AddIsolinesLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.IsolineMap) { if (dataSource.Data is IDataSource2D <double> ) { AddDataSource(dataSource.Data as IDataSource2D <double>, dataSource.Guid); } } }
private void RemoveIsolinesLayer(VisualizationDataSource removedDataSource) { IsolinesLayer layer = layers.Find(il => il.Guid == removedDataSource.Guid); if (layer != null) { RemoveLayerFromHost(layer); layers.Remove(layer); } }
public void RemoveLayer(VisualizationDataSource dataSource) { ProbesLayer probesLayer = probesLayers.Find(pl => pl.Guid == dataSource.Guid); if (probesLayer != null) { host.DataSources.Remove(probesLayer.LayerID, probesLayer.LayerName); probesLayers.Remove(probesLayer); } }
private void AddActorLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.ColorMap && dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D <double> ) { AddDataSource(dataSource.Data as IDataSource2D <double>, dataSource.Guid); } host.NeedUpdate(); } }
private void RemoveColorMapLayer(VisualizationDataSource dataSource) { ColorMapLayer colorMapLayer = colorMapLayers.Find(cml => cml.Guid == dataSource.Guid); if (colorMapLayer != null) { if (colorMapLayer.IsVisible) { host.DataSources.Remove(colorMapLayer.LayerName, colorMapLayer.LayerID); } colorMapLayers.Remove(colorMapLayer); } }
public void RemoveLayer(VisualizationDataSource dataSource) { TrajectoriesLayer trLayer = trajectoriesLayers.Find(tl => tl.Guid == dataSource.Guid); if (trLayer != null) { if (trLayer.IsVisible) { RemoveLayerFromHost(trLayer); } trajectoriesLayers.Remove(trLayer); } }
private void AddProbesLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.Probes && !dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D<double>) { AddDataSource(dataSource.Data as IDataSource2D<double>, dataSource.Guid); } else if (dataSource.Data is PointSet) { AddDataSource(dataSource.Data as PointSet, dataSource.Guid); } } }
private void AddProbesLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.Probes && !dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D <double> ) { AddDataSource(dataSource.Data as IDataSource2D <double>, dataSource.Guid); } else if (dataSource.Data is PointSet) { AddDataSource(dataSource.Data as PointSet, dataSource.Guid); } } }
protected virtual void dataSources_CollectionChanged(object sender, NotifyCollectionChangedEventArgs e) { switch (e.Action) { case NotifyCollectionChangedAction.Add: foreach (object newItem in e.NewItems) { VisualizationDataSource newDataSource = newItem as VisualizationDataSource; if (newDataSource == null) { throw new ArgumentException("Something strange has happened"); } else if (newDataSource.Algorithm == Algorithms.Probes) { AddProbesLayer(newDataSource); } } break; case NotifyCollectionChangedAction.Remove: foreach (object removedItem in e.OldItems) { VisualizationDataSource removedDataSource = removedItem as VisualizationDataSource; if (removedDataSource == null) { throw new ArgumentException("Something strange has happened"); } else if (removedDataSource.Algorithm == Algorithms.Probes) { RemoveProbesLayer(removedDataSource); } } break; default: break; } }
public void AddLayer(VisualizationDataSource dataSource) { AddColorMapLayer(dataSource); }
void IVisualizationProvider.AddLayer(VisualizationDataSource dataSource) { AddActorLayer(dataSource); }
public void RemoveLayer(VisualizationDataSource dataSource) { RemoveIsolinesLayer(dataSource); }
public void RemoveLayer(VisualizationDataSource dataSource) { RemoveActorLayer(dataSource); }
public void AddLayer(VisualizationDataSource dataSource) { AddActorLayer(dataSource); }
private void AddColorMapLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.ColorMap && !dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D<double>) { AddDataSource(dataSource.Data, dataSource.Guid, double.MinValue, double.MaxValue); } } }
public void RemoveLayer(VisualizationDataSource dataSource) { RemoveColorMapLayer(dataSource); }
private void RemoveProbesLayer(VisualizationDataSource removedDataSource) { RemoveLayer(removedDataSource); }
public void RemoveLayer(VisualizationDataSource dataSource) { TrajectoriesLayer trLayer = trajectoriesLayers.Find(tl => tl.Guid == dataSource.Guid); if (trLayer != null) { if (trLayer.IsVisible) RemoveLayerFromHost(trLayer); trajectoriesLayers.Remove(trLayer); } }
private void AddActorLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.ColorMap && dataSource.IsDynamic) { if (dataSource.Data is IDataSource2D<double>) AddDataSource(dataSource.Data as IDataSource2D<double>, dataSource.Guid); host.NeedUpdate(); } }
void IVisualizationProvider.RemoveLayer(VisualizationDataSource dataSource) { RemoveActorLayer(dataSource); }
public void AddLayer(VisualizationDataSource dataSource) { AddProbesLayer(dataSource); }
public void AddLayer(VisualizationDataSource dataSource) { AddIsolinesLayer(dataSource); }
private void AddIsolinesLayer(VisualizationDataSource dataSource) { if (dataSource.Algorithm == Algorithms.IsolineMap) { if (dataSource.Data is IDataSource2D<double>) AddDataSource(dataSource.Data as IDataSource2D<double>, dataSource.Guid); } }