scichart 2.0.0-alpha.1971 → 2.0.0-alpha.1991

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. package/Builder/buildAxis.d.ts +3 -3
  2. package/Builder/buildDataSeries.d.ts +44 -4
  3. package/Builder/buildDataSeries.js +66 -0
  4. package/Builder/buildSeries.d.ts +1 -1
  5. package/Builder/buildSeries.js +1 -2
  6. package/Builder/buildSurface.d.ts +14 -6
  7. package/Builder/buildSurface.js +13 -8
  8. package/Builder/chartBuilder.d.ts +12 -6
  9. package/Builder/chartBuilder.js +6 -6
  10. package/Charting/ChartModifiers/LegendModifier.d.ts +4 -0
  11. package/Charting/ChartModifiers/LegendModifier.js +2 -1
  12. package/Charting/ChartModifiers/SeriesSelectionModifier.d.ts +14 -6
  13. package/Charting/ChartModifiers/SeriesSelectionModifier.js +10 -10
  14. package/Charting/ChartModifiers/ZoomExtentsModifier.d.ts +13 -0
  15. package/Charting/ChartModifiers/ZoomExtentsModifier.js +16 -4
  16. package/Charting/Drawing/BrushCache.js +6 -8
  17. package/Charting/LayoutManager/BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy.js +1 -0
  18. package/Charting/LayoutManager/LeftAlignedOuterVerticallyStackedAxisLayoutStrategy.js +1 -0
  19. package/Charting/LayoutManager/RightAlignedOuterVerticallyStackedAxisLayoutStrategy.js +1 -0
  20. package/Charting/LayoutManager/TopAlignedOuterHorizontallyStackedAxisLayoutStrategy.js +1 -0
  21. package/Charting/Model/BaseDataSeries.d.ts +61 -53
  22. package/Charting/Model/BaseDataSeries.js +145 -81
  23. package/Charting/Model/BaseHeatmapDataSeries.d.ts +2 -2
  24. package/Charting/Model/DataPointSelectionPaletteProvider.d.ts +6 -4
  25. package/Charting/Model/DataPointSelectionPaletteProvider.js +10 -1
  26. package/Charting/Model/Filters/OhlcScaleOffsetFilter.d.ts +106 -0
  27. package/Charting/Model/Filters/OhlcScaleOffsetFilter.js +21 -0
  28. package/Charting/Model/Filters/XyLinearTrendFilter.d.ts +112 -1
  29. package/Charting/Model/Filters/XyLinearTrendFilter.js +21 -0
  30. package/Charting/Model/Filters/XyMovingAverageFilter.d.ts +110 -1
  31. package/Charting/Model/Filters/XyMovingAverageFilter.js +21 -0
  32. package/Charting/Model/Filters/XyRatioFilter.d.ts +111 -2
  33. package/Charting/Model/Filters/XyRatioFilter.js +34 -3
  34. package/Charting/Model/Filters/XyScaleOffsetFilter.d.ts +112 -1
  35. package/Charting/Model/Filters/XyScaleOffsetFilter.js +21 -0
  36. package/Charting/Model/Filters/XyyScaleOffsetFilter.d.ts +116 -0
  37. package/Charting/Model/Filters/XyyScaleOffsetFilter.js +21 -0
  38. package/Charting/Model/Filters/XyzScaleOffsetFilter.d.ts +116 -0
  39. package/Charting/Model/Filters/XyzScaleOffsetFilter.js +21 -0
  40. package/Charting/Model/IDataSeries.d.ts +18 -3
  41. package/Charting/Model/IDataSeries.js +12 -1
  42. package/Charting/Model/IPaletteProvider.d.ts +8 -8
  43. package/Charting/Model/OhlcDataSeries.d.ts +39 -10
  44. package/Charting/Model/OhlcDataSeries.js +106 -19
  45. package/Charting/Model/UniformHeatmapDataSeries.d.ts +2 -2
  46. package/Charting/Model/XyyDataSeries.d.ts +21 -12
  47. package/Charting/Model/XyyDataSeries.js +70 -16
  48. package/Charting/Model/XyzDataSeries.d.ts +20 -5
  49. package/Charting/Model/XyzDataSeries.js +62 -6
  50. package/Charting/Services/SciChartRenderer.js +3 -1
  51. package/Charting/Visuals/Annotations/AnnotationBase.js +5 -9
  52. package/Charting/Visuals/Annotations/AxisMarkerAnnotation.js +0 -3
  53. package/Charting/Visuals/Annotations/HorizontalLineAnnotation.js +0 -3
  54. package/Charting/Visuals/Annotations/LineAnnotation.js +0 -3
  55. package/Charting/Visuals/Annotations/VerticalLineAnnotation.js +0 -3
  56. package/Charting/Visuals/Axis/AxisBase2D.d.ts +20 -0
  57. package/Charting/Visuals/Axis/AxisBase2D.js +57 -5
  58. package/Charting/Visuals/Axis/AxisCore.js +16 -13
  59. package/Charting/Visuals/Axis/IAxisCoreOptions.d.ts +13 -0
  60. package/Charting/Visuals/Axis/constants.d.ts +2 -1
  61. package/Charting/Visuals/Axis/constants.js +1 -0
  62. package/Charting/Visuals/Legend/SciChartLegend.js +1 -1
  63. package/Charting/Visuals/Legend/SciChartLegendBase.d.ts +11 -0
  64. package/Charting/Visuals/Legend/SciChartLegendBase.js +45 -17
  65. package/Charting/Visuals/RenderableSeries/Animations/animationHelpers.d.ts +9 -2
  66. package/Charting/Visuals/RenderableSeries/Animations/animationHelpers.js +65 -4
  67. package/Charting/Visuals/RenderableSeries/BaseBandRenderableSeries.d.ts +0 -11
  68. package/Charting/Visuals/RenderableSeries/BaseBandRenderableSeries.js +0 -29
  69. package/Charting/Visuals/RenderableSeries/BaseMountainRenderableSeries.js +1 -1
  70. package/Charting/Visuals/RenderableSeries/BaseOhlcRenderableSeries.d.ts +0 -37
  71. package/Charting/Visuals/RenderableSeries/BaseOhlcRenderableSeries.js +0 -120
  72. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.d.ts +4 -24
  73. package/Charting/Visuals/RenderableSeries/BaseRenderableSeries.js +44 -72
  74. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.d.ts +2 -1
  75. package/Charting/Visuals/RenderableSeries/DrawingProviders/MountainSeriesDrawingProvider.js +6 -6
  76. package/Charting/Visuals/RenderableSeries/FastBandRenderableSeries.d.ts +0 -6
  77. package/Charting/Visuals/RenderableSeries/FastBandRenderableSeries.js +0 -42
  78. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.d.ts +0 -17
  79. package/Charting/Visuals/RenderableSeries/FastBubbleRenderableSeries.js +0 -71
  80. package/Charting/Visuals/RenderableSeries/FastOhlcRenderableSeries.js +1 -1
  81. package/Charting/Visuals/RenderableSeries/IBaseRenderableSeriesOptions.d.ts +12 -4
  82. package/Charting/Visuals/RenderableSeries/SplineBandRenderableSeries.d.ts +3 -0
  83. package/Charting/Visuals/RenderableSeries/SplineBandRenderableSeries.js +10 -32
  84. package/Charting/Visuals/RenderableSeries/SplineLineRenderableSeries.d.ts +4 -0
  85. package/Charting/Visuals/RenderableSeries/SplineLineRenderableSeries.js +11 -21
  86. package/Charting/Visuals/RenderableSeries/SplineMountainRenderableSeries.d.ts +3 -0
  87. package/Charting/Visuals/RenderableSeries/SplineMountainRenderableSeries.js +10 -21
  88. package/Charting/Visuals/SciChartOverview.d.ts +1 -1
  89. package/Charting/Visuals/SciChartOverview.js +1 -1
  90. package/Charting/Visuals/SciChartSurface.d.ts +2 -2
  91. package/Charting/Visuals/SciChartSurface.js +4 -4
  92. package/Charting/Visuals/SciChartSurfaceBase.d.ts +2 -3
  93. package/Charting/Visuals/SciChartSurfaceBase.js +2 -6
  94. package/Charting/Visuals/TextureManager/DpiHelper.js +2 -1
  95. package/Charting/Visuals/TextureManager/TextureManager.js +3 -2
  96. package/Charting3D/Visuals/SciChart3DSurface.d.ts +1 -1
  97. package/Charting3D/Visuals/SciChart3DSurface.js +1 -1
  98. package/_wasm/scichart.browser.js +1 -1
  99. package/_wasm/scichart2d.js +95 -95
  100. package/_wasm/scichart2d.wasm +0 -0
  101. package/_wasm/scichart3d.js +1 -1
  102. package/_wasm/scichart3d.wasm +0 -0
  103. package/package.json +1 -1
  104. package/types/BaseType.d.ts +3 -1
  105. package/types/BaseType.js +2 -0
  106. package/types/DataFilterType.d.ts +9 -0
  107. package/types/DataFilterType.js +13 -0
  108. package/types/SeriesType.d.ts +17 -17
  109. package/types/SeriesType.js +17 -17
  110. package/utils/font.d.ts +8 -0
  111. package/utils/font.js +15 -0
@@ -1,9 +1,9 @@
1
1
  import { TSciChart } from "../../../../types/TSciChart";
2
2
  import { WebGlRenderContext2D } from "../../../Drawing/WebGlRenderContext2D";
3
3
  import { RenderPassData } from "../../../Services/RenderPassData";
4
+ import { TDpiChangedEventArgs } from "../../TextureManager/DpiHelper";
4
5
  import { BaseMountainRenderableSeries } from "../BaseMountainRenderableSeries";
5
6
  import { BaseSeriesDrawingProvider } from "./BaseSeriesDrawingProvider";
6
- import { TDpiChangedEventArgs } from "../../TextureManager/DpiHelper";
7
7
  /**
8
8
  * Used internally - a drawing provider performs drawing for a {@link BaseMountainRenderableSeries} using
9
9
  * our WebAssembly WebGL rendering engine
@@ -40,4 +40,5 @@ export declare class MountainSeriesDrawingProvider extends BaseSeriesDrawingProv
40
40
  */
41
41
  onAttachSeries(): void;
42
42
  private createBrush;
43
+ private createPen;
43
44
  }
@@ -21,8 +21,6 @@ var Pen2DCache_1 = require("../../../Drawing/Pen2DCache");
21
21
  var WebGlRenderContext2D_1 = require("../../../Drawing/WebGlRenderContext2D");
22
22
  var constants_1 = require("../constants");
23
23
  var BaseSeriesDrawingProvider_1 = require("./BaseSeriesDrawingProvider");
24
- /** @ignore */
25
- var TEXTURE_SIZE = 256;
26
24
  /**
27
25
  * Used internally - a drawing provider performs drawing for a {@link BaseMountainRenderableSeries} using
28
26
  * our WebAssembly WebGL rendering engine
@@ -123,8 +121,7 @@ var MountainSeriesDrawingProvider = /** @class */ (function (_super) {
123
121
  propertyName === constants_1.PROPERTY.STROKE_DASH_ARRAY ||
124
122
  propertyName === constants_1.PROPERTY.STROKE_THICKNESS ||
125
123
  propertyName === constants_1.PROPERTY.OPACITY) {
126
- var _a = this.parentSeries, stroke = _a.stroke, strokeThickness = _a.strokeThickness, fill = _a.fill, opacity = _a.opacity, strokeDashArray = _a.strokeDashArray;
127
- Pen2DCache_1.createPenInCache(this.strokePenCache, stroke, strokeThickness, opacity, strokeDashArray);
124
+ this.createPen();
128
125
  }
129
126
  if (propertyName === constants_1.PROPERTY.FILL ||
130
127
  propertyName === constants_1.PROPERTY.OPACITY ||
@@ -138,14 +135,17 @@ var MountainSeriesDrawingProvider = /** @class */ (function (_super) {
138
135
  MountainSeriesDrawingProvider.prototype.onAttachSeries = function () {
139
136
  _super.prototype.onAttachSeries.call(this);
140
137
  this.nativeDrawingProvider = new this.webAssemblyContext.SCRTMountainSeriesDrawingProvider();
141
- var _a = this.parentSeries, stroke = _a.stroke, strokeThickness = _a.strokeThickness, opacity = _a.opacity, strokeDashArray = _a.strokeDashArray;
142
- Pen2DCache_1.createPenInCache(this.strokePenCache, stroke, strokeThickness, opacity, strokeDashArray);
138
+ this.createPen();
143
139
  this.createBrush();
144
140
  };
145
141
  MountainSeriesDrawingProvider.prototype.createBrush = function () {
146
142
  var _a = this.parentSeries, fill = _a.fill, opacity = _a.opacity, fillLinearGradient = _a.fillLinearGradient;
147
143
  return BrushCache_1.createBrushInCache(this.fillBrushCache, fill, opacity, fillLinearGradient);
148
144
  };
145
+ MountainSeriesDrawingProvider.prototype.createPen = function () {
146
+ var _a = this.parentSeries, stroke = _a.stroke, strokeThickness = _a.strokeThickness, opacity = _a.opacity, strokeDashArray = _a.strokeDashArray;
147
+ return Pen2DCache_1.createPenInCache(this.strokePenCache, stroke, strokeThickness, opacity, strokeDashArray);
148
+ };
149
149
  return MountainSeriesDrawingProvider;
150
150
  }(BaseSeriesDrawingProvider_1.BaseSeriesDrawingProvider));
151
151
  exports.MountainSeriesDrawingProvider = MountainSeriesDrawingProvider;
@@ -1,7 +1,5 @@
1
- import { AnimationFiniteStateMachine } from "../../../Core/Animations/AnimationFiniteStateMachine";
2
1
  import { ESeriesType } from "../../../types/SeriesType";
3
2
  import { TSciChart } from "../../../types/TSciChart";
4
- import { BaseAnimation } from "./Animations/BaseAnimation";
5
3
  import { BaseBandRenderableSeries, IBaseBandRenderableSeriesOptions } from "./BaseBandRenderableSeries";
6
4
  /**
7
5
  * Optional parameters passed to the constructor of {@link FastBandRenderableSeries}
@@ -38,8 +36,4 @@ export declare class FastBandRenderableSeries extends BaseBandRenderableSeries {
38
36
  * @param options optional parameters of type {@link IBandRenderableSeriesOptions} applied when constructing the series type
39
37
  */
40
38
  constructor(webAssemblyContext: TSciChart, options?: IBandRenderableSeriesOptions);
41
- /** @inheritDoc */
42
- protected setAnimationVectors(animation: BaseAnimation): void;
43
- /** @inheritDoc */
44
- protected updateAnimationProperties(progress: number, animationFSM: AnimationFiniteStateMachine): void;
45
39
  }
@@ -15,7 +15,6 @@ var __extends = (this && this.__extends) || (function () {
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.FastBandRenderableSeries = void 0;
17
17
  var SeriesType_1 = require("../../../types/SeriesType");
18
- var IDataSeries_1 = require("../../Model/IDataSeries");
19
18
  var BaseBandRenderableSeries_1 = require("./BaseBandRenderableSeries");
20
19
  /**
21
20
  * Defines a JavaScript Band-series or High-Low polygon fill chart type in the SciChart's High Performance Real-time
@@ -51,47 +50,6 @@ var FastBandRenderableSeries = /** @class */ (function (_super) {
51
50
  _this.type = SeriesType_1.ESeriesType.BandSeries;
52
51
  return _this;
53
52
  }
54
- /** @inheritDoc */
55
- FastBandRenderableSeries.prototype.setAnimationVectors = function (animation) {
56
- if (animation.isOnStartAnimation) {
57
- this.setXFinalAnimationValues(this.getNativeXValues());
58
- this.setYFinalAnimationValues(this.getNativeYValues());
59
- this.setY1FinalAnimationValues(this.getNativeY1Values());
60
- }
61
- else if (animation.isDataSeriesAnimation) {
62
- var xyyDataSeries = animation.dataSeries;
63
- if (xyyDataSeries.type !== IDataSeries_1.EDataSeriesType.Xyy) {
64
- throw Error("to animate band chart animation.dataSeries type should be Xyy, but the type is " + xyyDataSeries.type);
65
- }
66
- this.setXInitialAnimationValues(this.getNativeXValues());
67
- this.setYInitialAnimationValues(this.getNativeYValues());
68
- this.setY1InitialAnimationValues(this.getNativeY1Values());
69
- this.setXFinalAnimationValues(xyyDataSeries.getNativeXValues());
70
- this.setYFinalAnimationValues(xyyDataSeries.getNativeYValues());
71
- this.setY1FinalAnimationValues(xyyDataSeries.getNativeY1Values());
72
- this.validateAnimationValues();
73
- }
74
- };
75
- /** @inheritDoc */
76
- FastBandRenderableSeries.prototype.updateAnimationProperties = function (progress, animationFSM) {
77
- var animation = animationFSM.animation;
78
- animation.updateSeriesProperties(this, animationFSM.initialStyles, animationFSM.animationProgress);
79
- if (animation.isOnStartAnimation) {
80
- var dataSeries = this.dataSeries;
81
- if (dataSeries) {
82
- animation.calculateAnimationValues(this.webAssemblyContext, this.yFinalAnimationValues, dataSeries.getNativeYValues(), progress);
83
- animation.calculateAnimationValues(this.webAssemblyContext, this.y1FinalAnimationValues, dataSeries.getNativeY1Values(), progress);
84
- }
85
- }
86
- else if (animation.isDataSeriesAnimation) {
87
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.xInitialAnimationValues, this.xFinalAnimationValues, this.getNativeXValues(), progress);
88
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.yInitialAnimationValues, this.yFinalAnimationValues, this.getNativeYValues(), progress);
89
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.y1InitialAnimationValues, this.y1FinalAnimationValues, this.getNativeY1Values(), progress);
90
- }
91
- if (this.invalidateParentCallback) {
92
- this.invalidateParentCallback();
93
- }
94
- };
95
53
  return FastBandRenderableSeries;
96
54
  }(BaseBandRenderableSeries_1.BaseBandRenderableSeries));
97
55
  exports.FastBandRenderableSeries = FastBandRenderableSeries;
@@ -1,8 +1,6 @@
1
- import { AnimationFiniteStateMachine } from "../../../Core/Animations/AnimationFiniteStateMachine";
2
1
  import { ESeriesType } from "../../../types/SeriesType";
3
2
  import { DoubleVector, TSciChart } from "../../../types/TSciChart";
4
3
  import { IThemeProvider } from "../../Themes/IThemeProvider";
5
- import { BaseAnimation } from "./Animations/BaseAnimation";
6
4
  import { BaseRenderableSeries } from "./BaseRenderableSeries";
7
5
  import { IHitTestProvider } from "./HitTest/IHitTestProvider";
8
6
  import { IBaseRenderableSeriesOptions } from "./IBaseRenderableSeriesOptions";
@@ -35,14 +33,6 @@ export interface IBubbleRenderableSeriesOptions extends IBaseRenderableSeriesOpt
35
33
  export declare class FastBubbleRenderableSeries extends BaseRenderableSeries {
36
34
  /** @inheritDoc */
37
35
  readonly type = ESeriesType.BubbleSeries;
38
- /**
39
- * Z vector with initial animation values
40
- */
41
- protected zInitialAnimationValues: DoubleVector;
42
- /**
43
- * Z vector with final animation values
44
- */
45
- protected zFinalAnimationValues: DoubleVector;
46
36
  /**
47
37
  * Creates an instance of the {@link FastBubbleRenderableSeries}
48
38
  * @param webAssemblyContext The {@link TSciChart | SciChart WebAssembly Context} containing
@@ -66,11 +56,4 @@ export declare class FastBubbleRenderableSeries extends BaseRenderableSeries {
66
56
  getNativeZValues(): DoubleVector;
67
57
  /** @inheritDoc */
68
58
  protected newHitTestProvider(): IHitTestProvider;
69
- /** @inheritDoc */
70
- protected setAnimationVectors(animation: BaseAnimation): void;
71
- /** @inheritDoc */
72
- protected updateAnimationProperties(progress: number, animationFSM: AnimationFiniteStateMachine): void;
73
- protected setZInitialAnimationValues(values: DoubleVector): void;
74
- protected setZFinalAnimationValues(values: DoubleVector): void;
75
- protected validateAnimationValues(): void;
76
59
  }
@@ -14,9 +14,7 @@ var __extends = (this && this.__extends) || (function () {
14
14
  })();
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.FastBubbleRenderableSeries = void 0;
17
- var Deleter_1 = require("../../../Core/Deleter");
18
17
  var SeriesType_1 = require("../../../types/SeriesType");
19
- var IDataSeries_1 = require("../../Model/IDataSeries");
20
18
  var BaseRenderableSeries_1 = require("./BaseRenderableSeries");
21
19
  var BubbleSeriesDrawingProvider_1 = require("./DrawingProviders/BubbleSeriesDrawingProvider");
22
20
  var BubbleSeriesHitTestProvider_1 = require("./HitTest/BubbleSeriesHitTestProvider");
@@ -53,8 +51,6 @@ var FastBubbleRenderableSeries = /** @class */ (function (_super) {
53
51
  var _this = _super.call(this, webAssemblyContext, options) || this;
54
52
  /** @inheritDoc */
55
53
  _this.type = SeriesType_1.ESeriesType.BubbleSeries;
56
- _this.zInitialAnimationValues = new webAssemblyContext.DoubleVector();
57
- _this.zFinalAnimationValues = new webAssemblyContext.DoubleVector();
58
54
  _this.drawingProviders = [];
59
55
  _this.drawingProviders.push(new BubbleSeriesDrawingProvider_1.BubbleSeriesDrawingProvider(webAssemblyContext, _this));
60
56
  if (options === null || options === void 0 ? void 0 : options.animation) {
@@ -80,8 +76,6 @@ var FastBubbleRenderableSeries = /** @class */ (function (_super) {
80
76
  };
81
77
  /** @inheritDoc */
82
78
  FastBubbleRenderableSeries.prototype.delete = function () {
83
- this.zInitialAnimationValues = Deleter_1.deleteSafe(this.zInitialAnimationValues);
84
- this.zFinalAnimationValues = Deleter_1.deleteSafe(this.zFinalAnimationValues);
85
79
  _super.prototype.delete.call(this);
86
80
  };
87
81
  /**
@@ -94,71 +88,6 @@ var FastBubbleRenderableSeries = /** @class */ (function (_super) {
94
88
  FastBubbleRenderableSeries.prototype.newHitTestProvider = function () {
95
89
  return new BubbleSeriesHitTestProvider_1.BubbleSeriesHitTestProvider(this, this.webAssemblyContext);
96
90
  };
97
- /** @inheritDoc */
98
- FastBubbleRenderableSeries.prototype.setAnimationVectors = function (animation) {
99
- if (animation.isOnStartAnimation) {
100
- this.setXFinalAnimationValues(this.getNativeXValues());
101
- this.setYFinalAnimationValues(this.getNativeYValues());
102
- this.setZFinalAnimationValues(this.getNativeZValues());
103
- }
104
- else if (animation.isDataSeriesAnimation) {
105
- var dataSeries = animation.dataSeries;
106
- if (dataSeries.type !== IDataSeries_1.EDataSeriesType.Xyz) {
107
- throw Error("to animate bubble chart animation.dataSeries type should be Xyz, but the type is " + dataSeries.type);
108
- }
109
- this.setXInitialAnimationValues(this.getNativeXValues());
110
- this.setYInitialAnimationValues(this.getNativeYValues());
111
- this.setZInitialAnimationValues(this.getNativeZValues());
112
- this.setXFinalAnimationValues(dataSeries.getNativeXValues());
113
- this.setYFinalAnimationValues(dataSeries.getNativeYValues());
114
- this.setZFinalAnimationValues(dataSeries.getNativeZValues());
115
- this.validateAnimationValues();
116
- }
117
- };
118
- /** @inheritDoc */
119
- FastBubbleRenderableSeries.prototype.updateAnimationProperties = function (progress, animationFSM) {
120
- var animation = animationFSM.animation;
121
- animation.updateSeriesProperties(this, animationFSM.initialStyles, animationFSM.animationProgress);
122
- if (animation.isOnStartAnimation) {
123
- var dataSeries = this.dataSeries;
124
- if (dataSeries) {
125
- animation.calculateAnimationValues(this.webAssemblyContext, this.yFinalAnimationValues, dataSeries.getNativeYValues(), progress);
126
- animation.calculateAnimationValues(this.webAssemblyContext, this.zFinalAnimationValues, dataSeries.getNativeZValues(), progress, true);
127
- }
128
- }
129
- else if (animation.isDataSeriesAnimation) {
130
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.xInitialAnimationValues, this.xFinalAnimationValues, this.getNativeXValues(), progress);
131
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.yInitialAnimationValues, this.yFinalAnimationValues, this.getNativeYValues(), progress);
132
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.zInitialAnimationValues, this.zFinalAnimationValues, this.getNativeZValues(), progress);
133
- }
134
- if (this.invalidateParentCallback) {
135
- this.invalidateParentCallback();
136
- }
137
- };
138
- FastBubbleRenderableSeries.prototype.setZInitialAnimationValues = function (values) {
139
- var size = values.size();
140
- this.zInitialAnimationValues.resize(size, 0);
141
- for (var i = 0; i < size; i++) {
142
- this.zInitialAnimationValues.set(i, values.get(i));
143
- }
144
- };
145
- FastBubbleRenderableSeries.prototype.setZFinalAnimationValues = function (values) {
146
- var size = values.size();
147
- this.zFinalAnimationValues.resize(size, 0);
148
- for (var i = 0; i < size; i++) {
149
- this.zFinalAnimationValues.set(i, values.get(i));
150
- }
151
- };
152
- FastBubbleRenderableSeries.prototype.validateAnimationValues = function () {
153
- var size = this.xInitialAnimationValues.size();
154
- if (size !== this.yInitialAnimationValues.size() ||
155
- size !== this.zInitialAnimationValues.size() ||
156
- size !== this.xFinalAnimationValues.size() ||
157
- size !== this.yFinalAnimationValues.size() ||
158
- size !== this.zFinalAnimationValues.size()) {
159
- throw Error("initialAnimationValues and finalAnimationValues must have the same length");
160
- }
161
- };
162
91
  return FastBubbleRenderableSeries;
163
92
  }(BaseRenderableSeries_1.BaseRenderableSeries));
164
93
  exports.FastBubbleRenderableSeries = FastBubbleRenderableSeries;
@@ -15,8 +15,8 @@ var __extends = (this && this.__extends) || (function () {
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.FastOhlcRenderableSeries = void 0;
17
17
  var SeriesType_1 = require("../../../types/SeriesType");
18
- var OhlcSeriesDrawingProvider_1 = require("./DrawingProviders/OhlcSeriesDrawingProvider");
19
18
  var BaseOhlcRenderableSeries_1 = require("./BaseOhlcRenderableSeries");
19
+ var OhlcSeriesDrawingProvider_1 = require("./DrawingProviders/OhlcSeriesDrawingProvider");
20
20
  /**
21
21
  * Defines a JavaScript OHLC stock-chart series in the SciChart's High Performance Real-time
22
22
  * {@link https://www.scichart.com/javascript-chart-features | JavaScript Charts}
@@ -1,4 +1,4 @@
1
- import { TAnimationDefinition, TEffectDefinition, TPalletProviderDefinition, TPointMarkerDefinition } from "../../../Builder/buildSeries";
1
+ import { TAnimationDefinition, TEffectDefinition, TPaletteProviderDefinition, TPointMarkerDefinition } from "../../../Builder/buildSeries";
2
2
  import { ELineDrawMode } from "../../Drawing/WebGlRenderContext2D";
3
3
  import { IDataSeries } from "../../Model/IDataSeries";
4
4
  import { IPaletteProvider } from "../../Model/IPaletteProvider";
@@ -6,6 +6,14 @@ import { IPointMarker } from "../PointMarkers/IPointMarker";
6
6
  import { BaseAnimation } from "./Animations/BaseAnimation";
7
7
  import { IRenderableSeries } from "./IRenderableSeries";
8
8
  import { ShaderEffect } from "./ShaderEffect";
9
+ /**
10
+ * The type of the {@link IBaseRenderableSeriesOptions.onSelectedChanged } callback
11
+ */
12
+ export declare type TSeriesSelectionChangedCallback = (sourceSeries: IRenderableSeries, isSelected: boolean) => void;
13
+ /**
14
+ * The type of the {@link IBaseRenderableSeriesOptions.onHoveredChanged } callback
15
+ */
16
+ export declare type TSeriesHoverChangedCallback = (sourceSeries: IRenderableSeries, isHovered: boolean) => void;
9
17
  /**
10
18
  * Options to pass to the {@link BaseRenderableSeries} constructor
11
19
  */
@@ -123,7 +131,7 @@ export interface IBaseRenderableSeriesOptions {
123
131
  * per data-point coloring of fills or series bodies, and {@link IPointMarkerPaletteProvider} for per data-point coloring of
124
132
  * point-markers
125
133
  */
126
- paletteProvider?: IPaletteProvider | TPalletProviderDefinition;
134
+ paletteProvider?: IPaletteProvider | TPaletteProviderDefinition;
127
135
  /**
128
136
  * How to treat NAN (Not a number) values in the input {@link dataSeries}. See {@link ELineDrawMode} for a list of values.
129
137
  */
@@ -143,9 +151,9 @@ export interface IBaseRenderableSeriesOptions {
143
151
  /**
144
152
  * Optional callback function when selected changed. Also see {@link IRenderableSeries.selected} event handler
145
153
  */
146
- onSelectedChanged?: ((sourceSeries: IRenderableSeries, isSelected: boolean) => void) | string;
154
+ onSelectedChanged?: TSeriesSelectionChangedCallback | string;
147
155
  /**
148
156
  * Optional callback function when hovered changed. Also see {@link IRenderableSeries.hovered} event handler
149
157
  */
150
- onHoveredChanged?: ((sourceSeries: IRenderableSeries, isHovered: boolean) => void) | string;
158
+ onHoveredChanged?: TSeriesHoverChangedCallback | string;
151
159
  }
@@ -1,4 +1,5 @@
1
1
  import { AnimationFiniteStateMachine } from "../../../Core/Animations/AnimationFiniteStateMachine";
2
+ import { NumberRange } from "../../../Core/NumberRange";
2
3
  import { ESeriesType } from "../../../types/SeriesType";
3
4
  import { DoubleVector, TSciChart } from "../../../types/TSciChart";
4
5
  import { BaseAnimation } from "./Animations/BaseAnimation";
@@ -66,6 +67,8 @@ export declare class SplineBandRenderableSeries extends BaseBandRenderableSeries
66
67
  */
67
68
  updateSplineValues(): void;
68
69
  /** @inheritDoc */
70
+ getYRange(xVisibleRange: NumberRange, isXCategoryAxis?: boolean): NumberRange;
71
+ /** @inheritDoc */
69
72
  toJSON(excludeData?: boolean): import("../../../Builder/buildSeries").TSeriesDefinition;
70
73
  /** @inheritDoc */
71
74
  protected setAnimationVectors(animation: BaseAnimation): void;
@@ -16,7 +16,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.SplineBandRenderableSeries = void 0;
17
17
  var Deleter_1 = require("../../../Core/Deleter");
18
18
  var SeriesType_1 = require("../../../types/SeriesType");
19
- var IDataSeries_1 = require("../../Model/IDataSeries");
19
+ var animationHelpers_1 = require("./Animations/animationHelpers");
20
20
  var BaseBandRenderableSeries_1 = require("./BaseBandRenderableSeries");
21
21
  var constants_1 = require("./constants");
22
22
  /**
@@ -103,6 +103,11 @@ var SplineBandRenderableSeries = /** @class */ (function (_super) {
103
103
  this.recalculateSpline = false;
104
104
  };
105
105
  /** @inheritDoc */
106
+ SplineBandRenderableSeries.prototype.getYRange = function (xVisibleRange, isXCategoryAxis) {
107
+ if (isXCategoryAxis === void 0) { isXCategoryAxis = false; }
108
+ return this.dataSeries.getWindowedYRange(xVisibleRange, true, isXCategoryAxis);
109
+ };
110
+ /** @inheritDoc */
106
111
  SplineBandRenderableSeries.prototype.toJSON = function (excludeData) {
107
112
  if (excludeData === void 0) { excludeData = false; }
108
113
  var json = _super.prototype.toJSON.call(this, excludeData);
@@ -115,42 +120,15 @@ var SplineBandRenderableSeries = /** @class */ (function (_super) {
115
120
  /** @inheritDoc */
116
121
  SplineBandRenderableSeries.prototype.setAnimationVectors = function (animation) {
117
122
  this.updateSplineValues();
118
- if (animation.isOnStartAnimation) {
119
- this.setXFinalAnimationValues(this.xSplineValues);
120
- this.setYFinalAnimationValues(this.ySplineValues);
121
- this.setY1FinalAnimationValues(this.y1SplineValues);
122
- }
123
- else if (animation.isDataSeriesAnimation) {
124
- var xyyDataSeries = animation.dataSeries;
125
- if (xyyDataSeries.type !== IDataSeries_1.EDataSeriesType.Xyy) {
126
- throw Error("to animate band chart animation.dataSeries type should be Xyy, but the type is " + xyyDataSeries.type);
127
- }
128
- this.setXInitialAnimationValues(this.xSplineValues);
129
- this.setYInitialAnimationValues(this.ySplineValues);
130
- this.setY1InitialAnimationValues(this.y1SplineValues);
131
- // set final animation values for the spline
132
- var dataSeries = animation.dataSeries;
133
- var xValues = this.xAxis.isCategoryAxis ? dataSeries.getNativeIndexes() : dataSeries.getNativeXValues();
134
- this.webAssemblyContext.SCRTSplineHelperCubicSpline(xValues, dataSeries.getNativeYValues(), this.xFinalAnimationValues, this.yFinalAnimationValues, xValues.size(), this.interpolationPoints, dataSeries.containsNaN);
135
- this.webAssemblyContext.SCRTSplineHelperCubicSpline(xValues, dataSeries.getNativeY1Values(), this.xFinalAnimationValues, this.y1FinalAnimationValues, xValues.size(), this.interpolationPoints, dataSeries.containsNaN);
136
- this.validateAnimationValues();
137
- }
123
+ animationHelpers_1.animationHelpers.setSplineBandAnimationVectors(this.webAssemblyContext, animation, this.dataSeries, animation.dataSeries, this.xSplineValues, this.ySplineValues, this.y1SplineValues, this.xAxis.isCategoryAxis, this.interpolationPoints);
138
124
  };
139
125
  /** @inheritDoc */
140
126
  SplineBandRenderableSeries.prototype.updateAnimationProperties = function (progress, animationFSM) {
141
127
  var animation = animationFSM.animation;
142
128
  animation.updateSeriesProperties(this, animationFSM.initialStyles, animationFSM.animationProgress);
143
- if (animation.isOnStartAnimation) {
144
- var dataSeries = this.dataSeries;
145
- if (dataSeries) {
146
- animation.calculateAnimationValues(this.webAssemblyContext, this.yFinalAnimationValues, this.ySplineValues, progress);
147
- animation.calculateAnimationValues(this.webAssemblyContext, this.y1FinalAnimationValues, this.y1SplineValues, progress);
148
- }
149
- }
150
- else if (animation.isDataSeriesAnimation) {
151
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.xInitialAnimationValues, this.xFinalAnimationValues, this.xSplineValues, progress);
152
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.yInitialAnimationValues, this.yFinalAnimationValues, this.ySplineValues, progress);
153
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.y1InitialAnimationValues, this.y1FinalAnimationValues, this.y1SplineValues, progress);
129
+ var dataSeries = this.dataSeries;
130
+ if (dataSeries) {
131
+ animationHelpers_1.animationHelpers.updateSplineBandAnimationProperties(this.webAssemblyContext, animation, progress, dataSeries, this.xSplineValues, this.ySplineValues, this.y1SplineValues);
154
132
  }
155
133
  if (this.invalidateParentCallback) {
156
134
  this.invalidateParentCallback();
@@ -1,4 +1,5 @@
1
1
  import { AnimationFiniteStateMachine } from "../../../Core/Animations/AnimationFiniteStateMachine";
2
+ import { NumberRange } from "../../../Core/NumberRange";
2
3
  import { ESeriesType } from "../../../types/SeriesType";
3
4
  import { DoubleVector, TSciChart } from "../../../types/TSciChart";
4
5
  import { BaseAnimation } from "./Animations/BaseAnimation";
@@ -61,6 +62,9 @@ export declare class SplineLineRenderableSeries extends BaseLineRenderableSeries
61
62
  * Updates spline values
62
63
  */
63
64
  updateSplineValues(): void;
65
+ /** @inheritDoc */
66
+ getYRange(xVisibleRange: NumberRange, isXCategoryAxis?: boolean): NumberRange;
67
+ /** @inheritDoc */
64
68
  toJSON(excludeData?: boolean): import("../../../Builder/buildSeries").TSeriesDefinition;
65
69
  /**
66
70
  * @param color The color for palette
@@ -16,6 +16,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
16
16
  exports.SplineLineRenderableSeries = void 0;
17
17
  var Deleter_1 = require("../../../Core/Deleter");
18
18
  var SeriesType_1 = require("../../../types/SeriesType");
19
+ var animationHelpers_1 = require("./Animations/animationHelpers");
19
20
  var BaseLineRenderableSeries_1 = require("./BaseLineRenderableSeries");
20
21
  var constants_1 = require("./constants");
21
22
  /**
@@ -95,6 +96,12 @@ var SplineLineRenderableSeries = /** @class */ (function (_super) {
95
96
  this.webAssemblyContext.SCRTSplineHelperCubicSpline(xValues, yValues, this.xSplineValues, this.ySplineValues, initialSize, this.interpolationPoints, dataSeries.containsNaN);
96
97
  this.recalculateSpline = false;
97
98
  };
99
+ /** @inheritDoc */
100
+ SplineLineRenderableSeries.prototype.getYRange = function (xVisibleRange, isXCategoryAxis) {
101
+ if (isXCategoryAxis === void 0) { isXCategoryAxis = false; }
102
+ return this.dataSeries.getWindowedYRange(xVisibleRange, true, isXCategoryAxis);
103
+ };
104
+ /** @inheritDoc */
98
105
  SplineLineRenderableSeries.prototype.toJSON = function (excludeData) {
99
106
  if (excludeData === void 0) { excludeData = false; }
100
107
  var json = _super.prototype.toJSON.call(this, excludeData);
@@ -116,32 +123,15 @@ var SplineLineRenderableSeries = /** @class */ (function (_super) {
116
123
  /** @inheritDoc */
117
124
  SplineLineRenderableSeries.prototype.setAnimationVectors = function (animation) {
118
125
  this.updateSplineValues();
119
- if (animation.isOnStartAnimation) {
120
- this.setXFinalAnimationValues(this.xSplineValues);
121
- this.setYFinalAnimationValues(this.ySplineValues);
122
- }
123
- else if (animation.isDataSeriesAnimation) {
124
- this.setXInitialAnimationValues(this.xSplineValues);
125
- this.setYInitialAnimationValues(this.ySplineValues);
126
- // set final animation values for the spline
127
- var dataSeries = animation.dataSeries;
128
- var xValues = this.xAxis.isCategoryAxis ? dataSeries.getNativeIndexes() : dataSeries.getNativeXValues();
129
- this.webAssemblyContext.SCRTSplineHelperCubicSpline(xValues, dataSeries.getNativeYValues(), this.xFinalAnimationValues, this.yFinalAnimationValues, xValues.size(), this.interpolationPoints, dataSeries.containsNaN);
130
- }
126
+ animationHelpers_1.animationHelpers.setSplineAnimationVectors(this.webAssemblyContext, animation, this.dataSeries, animation.dataSeries, this.xSplineValues, this.ySplineValues, this.xAxis.isCategoryAxis, this.interpolationPoints);
131
127
  };
132
128
  /** @inheritDoc */
133
129
  SplineLineRenderableSeries.prototype.updateAnimationProperties = function (progress, animationFSM) {
134
130
  var animation = animationFSM.animation;
135
131
  animation.updateSeriesProperties(this, animationFSM.initialStyles, animationFSM.animationProgress);
136
- if (animation.isOnStartAnimation) {
137
- var dataSeries = this.dataSeries;
138
- if (dataSeries) {
139
- animation.calculateAnimationValues(this.webAssemblyContext, this.yFinalAnimationValues, this.ySplineValues, progress);
140
- }
141
- }
142
- else if (animation.isDataSeriesAnimation) {
143
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.xInitialAnimationValues, this.xFinalAnimationValues, this.xSplineValues, progress);
144
- animation.calculateDataSeriesAnimationValues(this.webAssemblyContext, this.yInitialAnimationValues, this.yFinalAnimationValues, this.ySplineValues, progress);
132
+ var dataSeries = this.dataSeries;
133
+ if (dataSeries) {
134
+ animationHelpers_1.animationHelpers.updateSplineAnimationProperties(this.webAssemblyContext, animation, progress, dataSeries, this.xSplineValues, this.ySplineValues);
145
135
  }
146
136
  if (this.invalidateParentCallback) {
147
137
  this.invalidateParentCallback();