DataViewerHelpers
DataViewerHelpers
Classes
| Name | |
|---|---|
| struct | DataViewerHelpers::AnalogBatchParams Parameters for building an analog series batch. |
| struct | DataViewerHelpers::EventBatchParams Parameters for building a digital event series batch. |
| struct | DataViewerHelpers::IntervalBatchParams Parameters for building a digital interval series batch. |
Types
| Name | |
|---|---|
| enum class | AnalogRenderMode { Line, Markers} Rendering mode for analog series. |
Functions
| Name | |
|---|---|
| CorePlotting::RenderablePolyLineBatch | buildAnalogSeriesBatchSimplified(AnalogTimeSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, AnalogBatchParams const & params, glm::mat4 const & model_matrix) Build a RenderablePolyLineBatch from an AnalogTimeSeries. |
| CorePlotting::RenderableGlyphBatch | buildAnalogSeriesMarkerBatchSimplified(AnalogTimeSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, AnalogBatchParams const & params, glm::mat4 const & model_matrix) Build a RenderableGlyphBatch for an AnalogTimeSeries in marker mode. |
| CorePlotting::RenderableGlyphBatch | buildEventSeriesBatchSimplified(DigitalEventSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, EventBatchParams const & params, glm::mat4 const & model_matrix) Build a RenderableGlyphBatch from a DigitalEventSeries. |
| CorePlotting::RenderableRectangleBatch | buildEventSeriesBoxBatchSimplified(DigitalEventSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, EventBatchParams const & params, glm::mat4 const & model_matrix, float box_width_world) Build a RenderableRectangleBatch from digital events drawn as time-axis boxes. |
| CorePlotting::RenderableRectangleBatch | buildIntervalSeriesBatchSimplified(DigitalIntervalSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, IntervalBatchParams const & params, glm::mat4 const & model_matrix) Build a RenderableRectangleBatch from a DigitalIntervalSeries. |
| std::vector< DataViewer::CachedAnalogVertex > | generateVerticesForRange(AnalogTimeSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, TimeFrameIndex start_time, TimeFrameIndex end_time) Generate vertices for a specific time range (helper for cache population). |
| CorePlotting::RenderablePolyLineBatch | buildAnalogSeriesBatchCached(AnalogTimeSeries const & series, std::shared_ptr< TimeFrame > const & master_time_frame, AnalogBatchParams const & params, glm::mat4 const & model_matrix, DataViewer::AnalogVertexCache & cache, std::vector< float > * scratch_buffer =[nullptr]) Build analog batch using vertex cache for efficient scrolling. |
Types Documentation
enum AnalogRenderMode
| Enumerator | Value | Description |
|---|---|---|
| Line | Render as connected line strip (default). | |
| Markers | Render as individual point markers. |
Rendering mode for analog series.
Functions Documentation
function buildAnalogSeriesBatchSimplified
CorePlotting::RenderablePolyLineBatch buildAnalogSeriesBatchSimplified(
AnalogTimeSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
AnalogBatchParams const & params,
glm::mat4 const & model_matrix
)Build a RenderablePolyLineBatch from an AnalogTimeSeries.
Parameters:
- series The analog time series data
- master_time_frame The master time frame for coordinate conversion
- params Batch building parameters (time range, gap config, style)
- model_matrix Pre-computed Model matrix
Return: A batch ready for upload to PolyLineRenderer
Converts the analog data into GPU-ready vertex data. If gap detection is enabled, the batch will contain multiple line segments broken at gaps.
function buildAnalogSeriesMarkerBatchSimplified
CorePlotting::RenderableGlyphBatch buildAnalogSeriesMarkerBatchSimplified(
AnalogTimeSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
AnalogBatchParams const & params,
glm::mat4 const & model_matrix
)Build a RenderableGlyphBatch for an AnalogTimeSeries in marker mode.
Parameters:
- series The analog time series data
- master_time_frame The master time frame for coordinate conversion
- params Batch building parameters
- model_matrix Pre-computed Model matrix
Return: A batch ready for upload to GlyphRenderer
Converts the analog data into individual point markers instead of a connected line. Used when gap_handling is set to ShowMarkers.
function buildEventSeriesBatchSimplified
CorePlotting::RenderableGlyphBatch buildEventSeriesBatchSimplified(
DigitalEventSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
EventBatchParams const & params,
glm::mat4 const & model_matrix
)Build a RenderableGlyphBatch from a DigitalEventSeries.
Parameters:
- series The digital event series data
- master_time_frame The master time frame for coordinate conversion
- params Batch building parameters
- model_matrix Pre-computed Model matrix
Return: A batch ready for upload to GlyphRenderer
For events rendered as ticks (vertical lines), we use glyphs positioned at the event times. The Model matrix handles vertical positioning.
function buildEventSeriesBoxBatchSimplified
CorePlotting::RenderableRectangleBatch buildEventSeriesBoxBatchSimplified(
DigitalEventSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
EventBatchParams const & params,
glm::mat4 const & model_matrix,
float box_width_world
)Build a RenderableRectangleBatch from digital events drawn as time-axis boxes.
Parameters:
- series Event series
- master_time_frame Master clock for X mapping and range filtering
- params Time window, origin subtraction, and RGBA color (shared with glyph batch params)
- model_matrix Lane model matrix (same as glyph/interval batches for that series)
- box_width_world Full width along the time axis (e.g. option box_width_ticks as float)
Each event becomes a rectangle spanning the full lane height in local Y ([-1, 1] → height 2) with X extent box_width_world centered on the event time (same X units as mapEventsInRange).
function buildIntervalSeriesBatchSimplified
CorePlotting::RenderableRectangleBatch buildIntervalSeriesBatchSimplified(
DigitalIntervalSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
IntervalBatchParams const & params,
glm::mat4 const & model_matrix
)Build a RenderableRectangleBatch from a DigitalIntervalSeries.
Parameters:
- series The digital interval series data
- master_time_frame The master time frame for coordinate conversion
- params Batch building parameters
- model_matrix Pre-computed Model matrix
Return: A batch ready for upload to RectangleRenderer
Converts intervals to rectangles with X coordinates from interval bounds and Y coordinates normalized to [-1, 1] for the Model matrix to position.
function generateVerticesForRange
std::vector< DataViewer::CachedAnalogVertex > generateVerticesForRange(
AnalogTimeSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
TimeFrameIndex start_time,
TimeFrameIndex end_time
)Generate vertices for a specific time range (helper for cache population).
Parameters:
- series The analog time series data
- master_time_frame The master time frame for coordinate conversion
- start_time Start of range to generate (master
[TimeFrameIndex](/api_generated/Classes/structTimeFrameIndex.md)) - end_time End of range to generate (master
[TimeFrameIndex](/api_generated/Classes/structTimeFrameIndex.md))
Return: Vector of CachedAnalogVertex with x = integer absolute physical time; AnalogVertexCache::getVerticesForRange subtracts the live view origin.
This is the core vertex generation logic extracted for use by the cache.
function buildAnalogSeriesBatchCached
CorePlotting::RenderablePolyLineBatch buildAnalogSeriesBatchCached(
AnalogTimeSeries const & series,
std::shared_ptr< TimeFrame > const & master_time_frame,
AnalogBatchParams const & params,
glm::mat4 const & model_matrix,
DataViewer::AnalogVertexCache & cache,
std::vector< float > * scratch_buffer =nullptr
)Build analog batch using vertex cache for efficient scrolling.
Parameters:
- series The analog time series data
- master_time_frame The master time frame for coordinate conversion
- params Batch building parameters (time range, gap config, style)
- model_matrix Pre-computed Model matrix
- cache Vertex cache (will be updated with new data)
Return: A batch ready for upload to PolyLineRenderer
This function implements the ring buffer optimization strategy:
- Check if cache covers the requested range
- If not, generate only the missing edge data
- Update the cache with new vertices
- Return batch built from cached vertices
For typical scrolling (scroll by 10-100 points out of 100K visible), this is ~26-130x faster than regenerating all vertices.
Updated on 2026-11-13 at 20:25:42 +0000