public static DataSeries AddNewCurrentDataSeries(PersistentVector initialPoints, string name, Color? color) { DataSeries ds = new DataSeries(Utility.PVtoGPList(initialPoints), name, color); CurrentDataSeries = AllDataSeries.Count - 1; UpdateSeriesInfoInUI(); return ds; }
public static DataSeries AddNewCurrentDataSeries(string name, Color? color) { DataSeries ds = new DataSeries(name, color); CurrentDataSeries = AllDataSeries.Count - 1; UpdateSeriesInfoInUI(); return ds; }
public static GraphPoint SeriesAverage(DataSeries series) { Vector3 averageCoord = new Vector3(); int pointCount = series.GetPointCount(); List<GraphPoint> points = series.GetDataPoints(); foreach (object point in points) { averageCoord.X += ((GraphPoint)point).x; averageCoord.Y += ((GraphPoint)point).y; averageCoord.Z += ((GraphPoint)point).z; } averageCoord /= pointCount; return new GraphPoint(averageCoord); }
public static DataSeries SetSeriesColor(DataSeries series, Color col) { series.SetColor(col); return series; }
public static DataSeries SetSeriesColorMode(DataSeries series, ColorMode mode) { series.SetColorMode(mode); return series; }
public static DataSeries TransformSeries(DataSeries series, float tX, float tY, float tZ, float scale, float pitch, float yaw, float roll) { return TransformSeries(series, tX, tY, tZ, scale, scale, scale, pitch, yaw, roll); }
public static DataSeries OffsetSeries(DataSeries series, float x, float y, float z) { return series.TranslatePoints(new Vector3(x, y, z)); }
public static DataSeries SetSeriesPollHistory(DataSeries series, bool enabled, double offset, int limit) { return series.SetSeriesPollHistory(enabled, offset, limit); }
public static DataSeries StartSeriesPollTimer(DataSeries series, double interval) { return series.StartDataSourcePoll(interval); }
public static DataSeries SetCurrentSeries(DataSeries newCurrentSeries) { int indexOf = AllDataSeries.IndexOf(newCurrentSeries); if (indexOf < 0) { AllDataSeries.Add(newCurrentSeries); CurrentDataSeries = AllDataSeries.Count - 1; } else { CurrentDataSeries = indexOf; } return newCurrentSeries; }
public static DataSeries SetSeriesPollHistory(DataSeries series, bool enabled) { return SetSeriesPollHistory(series, enabled, 1, 10); }
public static DataSeries ScaleSeries(DataSeries series, float scale) { return ScaleSeries(series, scale, scale, scale); }
public static DataSeries ScaleSeries(DataSeries series, float x, float y, float z) { return series.ScalePoints(new Vector3(x, y, z)); }
public static DataSeries RotateSeries(DataSeries series, float pitch, float yaw, float roll) { return series.RotatePoints(new Vector3(pitch, yaw, roll)); }
public static DataSeries ResetSeriesTransforms(DataSeries series) { return series.ResetTransforms(); }
public static DataSeries RenameSeries(DataSeries series, string newname) { series.SetName(newname); return series; }
public static DataSeries SetSeriesDrawMode(DataSeries series, DrawMode mode) { series.SetDrawMode(mode); return series; }
public static DataSeries SetDataSource(DataSeries series, string sourceName) { return SetDataSource(series, sourceName, 0); }
public static DataSeries SetSeriesLineWidth(DataSeries series, float width) { series.SetLineWidth(width); return series; }
public static DataSeries SetDataSource(DataSeries series, string sourceName, int channel) { return series.SetDataSource(sourceName, channel); }
public static DataSeries SetSeriesPollHistory(DataSeries series, bool enabled, int offset) { return SetSeriesPollHistory(series, enabled, offset, 10); }
public static DataSeries SetDataSourceChannel(DataSeries series, int channel) { return series.SetDataSourceChannel(channel); }
public static DataSeries SetSeriesTransparencyMode(DataSeries series, TransparencyMode mode) { series.SetTransparencyMode(mode); return series; }
public static DataSeries GetSeries(DataSeries ds) { return ds; }
public static DataSeries StopSeriesPollTimer(DataSeries series) { return series.StopDataSourcePoll(); }
public static int GetDataSeriesID(DataSeries series) { for (int i = 0; i < AllDataSeries.Count; i++) { if (AllDataSeries[i] == series) return i + 1; } return 0; }
public static DataSeries TransformSeries(DataSeries series, float tX, float tY, float tZ, float sX, float sY, float sZ, float pitch, float yaw, float roll) { return series.TransformPoints( Matrix4.CreateScale(sX, sY, sZ) * Matrix4.CreateRotationZ(roll) * Matrix4.CreateRotationY(yaw) * Matrix4.CreateRotationX(pitch) * Matrix4.CreateTranslation(tX, tY, tZ)); }
public static int GetSeriesPointCount(DataSeries series) { return series.GetPointCount(); }
public static DataSeries AddNewSeries(string name, Color? color) { DataSeries ds = new DataSeries(name, color); UpdateSeriesInfoInUI(); return ds; }
public static DataSeries SetSeriesColor(DataSeries series, int r, int g, int b) { return SetSeriesColor(series, Color.FromArgb(r, g, b)); }